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

Make calendar bigger and dataSource colors as gradients #17

Open
ImInYourPie opened this issue Mar 22, 2021 · 1 comment
Open

Make calendar bigger and dataSource colors as gradients #17

ImInYourPie opened this issue Mar 22, 2021 · 1 comment

Comments

@ImInYourPie
Copy link

ImInYourPie commented Mar 22, 2021

I would like to make the calendar bigger and pass gradients has the color of each element in dataSource.

All I have been able to do for now is set the style="custom" and modify each dayElement in customDayRenderer, setting the width and height ,for example, to 50px, overlaps the month labels over the days.

And I can't figure out how to have access to the elements in dataSoruce for each dayElement.

@ImInYourPie ImInYourPie changed the title Make calendar bigger and dataSource colors has gradients Make calendar bigger and dataSource colors as gradients Mar 22, 2021
@rubenprodev
Copy link

rubenprodev commented Mar 26, 2021

I'd like dataSource colors as gradients too.

I've been able to set custom colors just adding { color: "#thecolor" } in the dataSource object but it's only prepared for background-color when we set style="background".

I looked up the code and I guess we could achieve that by changing parent.style.backgroundColor for parent.style.background and passing it as a string like linear-gradient(#color1, #color2) or whatever.

I've also tried to not use colors and adding { className: 'theclassname' } and then applying those classes in the customDataSourceRenderer to apply my custom styles from my css file but it renders before dataSource update...

It's a little weird because it works with style="border" but not prepared for backgrounds.

I'm still trying to find the right way to make it.

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