Date picker and date range picker text styling is not possible. We can only provide the colors. Has anyone copied the source and modified the styling. Our designers have come up with custom styling. I tried copying the source code but some pieces are internal. So has any one tried this??
s
Sudhanshu Singh
05/30/2024, 6:24 AM
it takes color from your theme, so provide those colors in your theme. If the Date colors don't match your overall theme, create a new theme just for Date
r
raghunandan
05/30/2024, 6:24 AM
i have a custom theme as well. Colors i can customize. I want the font styling customization
s
Sudhanshu Singh
05/30/2024, 6:28 AM
typography also is taken from theme. so customize it in your theme
s
Sujit Panda
05/30/2024, 6:43 AM
DateRangePicker is using ProvideTextStyle. You can pass any TextStyle to that.
r
raghunandan
05/30/2024, 4:57 PM
Thanks will try that
raghunandan
05/31/2024, 1:38 AM
MaterialTheme(
typography = MaterialTheme.typography.copy(
bodyLarge = TextStyle(fontSize = 10.sp)
)
) {
// Date picker code
} this worked