Support for color
prop on DatePicker
#7221
mattdenkers
started this conversation in
Feature requests
Replies: 1 comment 1 reply
-
What is wrong with applying these styles with css? You've said that this method worked for you and it is less than 20 lines of code. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi there! First of all, amazing work on Mantine, it's a fantastic library. Everything below is related to version 7.12 btw.
I have a use case where it would be great to have separately themed DatePickers. The default behavior is for selected days to be the theme's primary color, and for days in the range to be a variant of that primary color, etc.
Similar to other Mantine components where it's possible to specify color, i.e.
<Button color="green">Green button</Button>
, my use case would be simplified by being able to specify<DatePicker color="green">
for example.Here's an example of my current CSS workaround, where the primary theme color is a shade of purple, and this CSS ensures the datepicker uses custom shades of blue instead:
I hope this request makes sense! It's also possible I'm missing something in the docs and there's a simpler workaround - if that's the case, please let me know.
Thank you!
Beta Was this translation helpful? Give feedback.
All reactions