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

Conditional styling for the days in timeline #64

Open
rosanzheng opened this issue Nov 6, 2020 · 1 comment
Open

Conditional styling for the days in timeline #64

rosanzheng opened this issue Nov 6, 2020 · 1 comment

Comments

@rosanzheng
Copy link

Hello, is there a way to style a single day of the timeline individually?
In my use case, I am required to mark holidays / non-working days in the timeline by coloring the background differently. Is there a way to do this?
So far as I understand, I can only change the background color for all days but not for a single day.
Also, as it is shown in the demo (https://codesandbox.io/s/brave-rgb-c72g7) the today-date is colored red. This is not the case for the "basic" demo (https://codesandbox.io/s/1y2on87jj) but I cannot figure out how you did that. Can you help?
Thanks!

@guiqui
Copy link
Owner

guiqui commented Nov 6, 2020

Hi there,
We need to add a getHeaderItemColor to the HeaderItem class, so we can change colors. The function will send 2 params, the value of the label and the type of item('month','week','day','hour'). It should be pretty straight forward.
You can do a pull request for your contribution, I will review the code and added to the next release.

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

No branches or pull requests

2 participants