enisn / UraniumUI

Uranium is a Free & Open-Source UI Kit for MAUI.
Apache License 2.0
983 stars 110 forks source link

[Feature Request] More control to adjust the color and opacity of ClearIcon and ShowPasswordIcon in TextFields #647

Open KonstantinKellermann opened 1 month ago

KonstantinKellermann commented 1 month ago

We've recently integrated UraniumUI into a new .NET Maui app and for now it looks really impressive and it feels great having material design back in it.

Building a login page I discovered some potential new features you could think about. Maybe it is just my opinion and others will think different about it, but it would be great having more control over changing the color and opacity of the icons for clearing a textfield and showing passwords.

I was able to change the colors of these icons using the keys "OnBackground" and "OnBackgroundDark" in our color resources. During my research I found that you are changing the color opacity using .WithAlpha(.5f).

https://github.com/enisn/UraniumUI/blob/962fc6a99ed22687687c61502d2b2408452e6588/src/UraniumUI.Material/Controls/TextFieldPasswordShowHideAttachment.cs#L61 https://github.com/enisn/UraniumUI/blob/962fc6a99ed22687687c61502d2b2408452e6588/src/UraniumUI.Material/Controls/TextField.cs#L33

This causes problems with the contrast in our app which is not perfect.

Is it possible to add BindableProperties or other solutions to adjust the opacity and colors of these icons?