Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added renderDay #375

Open
wants to merge 15 commits into
base: master
Choose a base branch
from
Open

Added renderDay #375

wants to merge 15 commits into from

Conversation

andrewmcd1
Copy link

This PR introduces a new prop, renderDay, to enhance the customization capabilities of react-native-calendar-picker. With this addition, users can now provide a custom component to render each day in the calendar according to their specific requirements.

Changes Introduced:

  • Added a new prop named renderDay.
  • This prop allows users to specify a custom component for rendering each day.
  • Provides greater flexibility in styling and functionality customization for calendar components.
  • Includes documentation updates to reflect the new prop and its usage.

Why is this change necessary?
The ability to customize the rendering of individual days in the calendar is a highly requested feature from our user community. By introducing the renderDay prop, we empower users to tailor the calendar's appearance and behavior to suit their unique application needs.

How to Use:
To utilize the new renderDay prop:

  1. Import the react-native-calendar-picker component.
  2. Pass a custom component to the renderDay prop, specifying how each day should be rendered.
  3. Customize the rendering logic within the provided component to achieve the desired visual appearance and functionality.

This enhancement enriches the versatility of react-native-calendar-picker, empowering developers to create more tailored and engaging calendar experiences within their React Native applications.

@andrewmcd1 andrewmcd1 closed this Apr 18, 2024
@andrewmcd1 andrewmcd1 reopened this Apr 18, 2024
@white-room
Copy link

any chance someone has had time to take a look at this?

@white-room
Copy link

@peacechen any chance you could take a look?

CalendarPicker/Day.js Outdated Show resolved Hide resolved
CalendarPicker/Day.js Outdated Show resolved Hide resolved
CalendarPicker/Day.js Outdated Show resolved Hide resolved
@peacechen
Copy link
Collaborator

Thanks @white-room for contributing this feature. Added a few comments. Please also resolve the conflicts in this PR.

README.md Outdated Show resolved Hide resolved
@peacechen
Copy link
Collaborator

Thanks @andrewmcd1 for making those changes.
I missed the Readme documenting the renderDay prop. The date param has changed.

CalendarPicker/Day.js Outdated Show resolved Hide resolved
@peacechen
Copy link
Collaborator

@andrewmcd1 A number of other PRs have recently been merged and a release needs to be done soon. Can you take a look at my comments? Please test this in the sample app too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants