Fix hide/show icon color.

This commit is contained in:
Dain Nilsson 2023-12-21 14:28:24 +01:00
parent 9f067b8f2a
commit a23e533ba5
No known key found for this signature in database
GPG Key ID: F04367096FBA95E8
4 changed files with 4 additions and 12 deletions

View File

@ -178,8 +178,7 @@ class _PinEntryFormState extends ConsumerState<_PinEntryForm> {
prefixIcon: const Icon(Icons.pin_outlined),
suffixIcon: IconButton(
icon: Icon(
_isObscure ? Icons.visibility : Icons.visibility_off,
color: !_pinIsWrong ? IconTheme.of(context).color : null),
_isObscure ? Icons.visibility : Icons.visibility_off),
onPressed: () {
setState(() {
_isObscure = !_isObscure;

View File

@ -88,10 +88,7 @@ class _UnlockFormState extends ConsumerState<UnlockForm> {
prefixIcon: const Icon(Icons.password_outlined),
suffixIcon: IconButton(
icon: Icon(
_isObscure ? Icons.visibility : Icons.visibility_off,
color: !_passwordIsWrong
? IconTheme.of(context).color
: null),
_isObscure ? Icons.visibility : Icons.visibility_off),
onPressed: () {
setState(() {
_isObscure = !_isObscure;

View File

@ -140,10 +140,7 @@ class _ConfigureHotpDialogState extends ConsumerState<ConfigureHotpDialog> {
prefixIcon: const Icon(Icons.key_outlined),
suffixIcon: IconButton(
icon: Icon(
_isObscure ? Icons.visibility : Icons.visibility_off,
color: !_validateSecret
? IconTheme.of(context).color
: null),
_isObscure ? Icons.visibility : Icons.visibility_off),
onPressed: () {
setState(() {
_isObscure = !_isObscure;

View File

@ -104,8 +104,7 @@ class _PinDialogState extends ConsumerState<PinDialog> {
prefixIcon: const Icon(Icons.pin_outlined),
suffixIcon: IconButton(
icon: Icon(
_isObscure ? Icons.visibility : Icons.visibility_off,
color: !_pinIsWrong ? IconTheme.of(context).color : null),
_isObscure ? Icons.visibility : Icons.visibility_off),
onPressed: () {
setState(() {
_isObscure = !_isObscure;