maxkeppeler / sheets

⭐ ‎‎‎‏‏‎ ‎Offers a range of beautiful sheets (dialogs & bottom sheets) for quick use in your project. Includes many ways to customize sheets.
https://maxkeppeler.github.io/sheets/
Apache License 2.0
921 stars 77 forks source link

No custom styles for disabled options #10

Closed braydentraas closed 3 years ago

braydentraas commented 3 years ago

It would be really helpful to be able to style the disabled options, specifically the text color or opacity, icon color or opacity, and possibly remove the "selectableItemBackground" for disabled options.

When using the default android gray button colors (light mode), it's not immediately clear which option (white or gray) is enabled or disabled, because the disabled option looks similar to the default (enabled) android button style. Being able to change the disabled text color would make it more clear.

image

maxkeppeler commented 3 years ago

I agree with your suggestion.

I actually thought about giving the image and the text a lower opacity, as I did in the CalendarSheet for days when the past or future timelines, or individual dates, are disabled. On the other hand I'm not sure if a disabled option with lower opacity is distinguishable enough compared to the normal selectable options. How does that sound to you?

In short, providing the following style attributes would help you out:

In any way, I will disable the ripple animation for a disabled (or disabled & selected) option. This should be the standard behavior in my opinion.

maxkeppeler commented 3 years ago

Why is the buttons view in your OptionsSheet only white? Did you remove the text of the buttons? There is a method to hide the buttons view itself.

braydentraas commented 3 years ago

@maxkeppeler

My apologies, I didn't see this until now. Thanks for the update!

I've put this app on hold for now but the changes you made look very promising. Thanks!