JetBrains / compose-multiplatform

Compose Multiplatform, a modern UI framework for Kotlin that makes building performant and beautiful user interfaces easy and enjoyable.
https://jetbrains.com/lp/compose-multiplatform
Apache License 2.0
15.73k stars 1.14k forks source link

Some DatePicker and TimePicker color values cannot be modified. #4259

Open xavimolloy opened 6 months ago

xavimolloy commented 6 months ago

Describe the bug A clear and concise description of what the bug is.

We are implementing our own custom calendar with some specific colors that differ from our theme but some colors from datePicker and TimePicker do not seem to be applied.

Example: image we would like the selected day text to be white selectedDayContentColor in TimePickerDefaults.color() is not modified when used, neither is selectedDayContainerColor all the disabledColors don't seem to be workink either.

the latter can be modified with a workaround to improve visibility by overriding the theme but is not an ideal solution as it also modifies other colors like the border and cursor of the input field in the calendar when focused. image image issue also occurs with TimePicker periodSelectorSelectedContentColor they seem to be detecting the Affected platforms Select one of the platforms below:

If the bug is Android-only, report it in the Jetpack Compose tracker

Versions

To Reproduce Steps and/or the code snippet to reproduce the behavior: DatePicker( state = rememberDatePickerState(), colors = DatePickerDefaults.colors( selectedDayContainerColor = Color.Red, selectedDayContentColor = Color.Red, ) )

Expected behavior A clear and concise description of what you expected to happen.

when setting a color it should be set correctly

Screenshots If applicable, add screenshots to help explain your problem.

Additional context Add any other context about the problem here.

okushnikov commented 1 month ago

Please check the following ticket on YouTrack for follow-ups to this issue. GitHub issues will be closed in the coming weeks.