Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

fix: explicitly add fill colour for textFields with filled flag set to true for it to remain the same as before using material 3

ashilkn813782569354
diff --git a/mobile/lib/ui/account/email_entry_page.dart b/mobile/lib/ui/account/email_entry_page.dart
index 888542f160..143f593ef3 100644
--- a/mobile/lib/ui/account/email_entry_page.dart
+++ b/mobile/lib/ui/account/email_entry_page.dart
@@ -148,7 +148,9 @@ class _EmailEntryPageState extends State<EmailEntryPage> {
style: Theme.of(context).textTheme.titleMedium,
autofillHints: const [AutofillHints.email],
decoration: InputDecoration(
- fillColor: _emailIsValid ? _validFieldValueColor : null,
+ fillColor: _emailIsValid
+ ? _validFieldValueColor
+ : getEnteColorScheme(context).fillFaint,
filled: true,
hintText: S.of(context).email,
contentPadding: const EdgeInsets.symmetric(
@@ -195,8 +197,9 @@ class _EmailEntryPageState extends State<EmailEntryPage> {
enableSuggestions: true,
autofillHints: const [AutofillHints.newPassword],
decoration: InputDecoration(
- fillColor:
- _passwordIsValid ? _validFieldValueColor : null,
+ fillColor: _passwordIsValid
+ ? _validFieldValueColor
+ : getEnteColorScheme(context).fillFaint,
filled: true,
hintText: S.of(context).password,
contentPadding: const EdgeInsets.symmetric(
@@ -265,7 +268,7 @@ class _EmailEntryPageState extends State<EmailEntryPage> {
decoration: InputDecoration(
fillColor: _passwordsMatch && _passwordIsValid
? _validFieldValueColor
- : null,
+ : getEnteColorScheme(context).fillFaint,
filled: true,
hintText: S.of(context).confirmPassword,
contentPadding: const EdgeInsets.symmetric(
@@ -343,7 +346,7 @@ class _EmailEntryPageState extends State<EmailEntryPage> {
child: TextFormField(
style: Theme.of(context).textTheme.titleMedium,
decoration: InputDecoration(
- fillColor: null,
+ fillColor: getEnteColorScheme(context).fillFaint,
filled: true,
contentPadding: const EdgeInsets.symmetric(
horizontal: 16,
diff --git a/mobile/lib/ui/account/login_page.dart b/mobile/lib/ui/account/login_page.dart
index 546a5f3b92..28b48a125f 100644
--- a/mobile/lib/ui/account/login_page.dart
+++ b/mobile/lib/ui/account/login_page.dart
@@ -237,7 +237,7 @@ class _LoginPageState extends State<LoginPage> {
if (_emailIsValid) {
_emailInputFieldColor = const Color.fromRGBO(45, 194, 98, 0.2);
} else {
- _emailInputFieldColor = null;
+ _emailInputFieldColor = getEnteColorScheme(context).fillFaint;
}
}
}
diff --git a/mobile/lib/ui/account/login_pwd_verification_page.dart b/mobile/lib/ui/account/login_pwd_verification_page.dart
index 884a5a4c7e..ac974c20da 100644
--- a/mobile/lib/ui/account/login_pwd_verification_page.dart
+++ b/mobile/lib/ui/account/login_pwd_verification_page.dart
@@ -251,6 +251,7 @@ class _LoginPasswordVerificationPageState
borderSide: BorderSide.none,
borderRadius: BorderRadius.circular(6),
),
+ fillColor: getEnteColorScheme(context).fillFaint,
suffixIcon: _passwordInFocus
? IconButton(
icon: Icon(
diff --git a/mobile/lib/ui/account/ott_verification_page.dart b/mobile/lib/ui/account/ott_verification_page.dart
index 9dee22e160..d03861055c 100644
--- a/mobile/lib/ui/account/ott_verification_page.dart
+++ b/mobile/lib/ui/account/ott_verification_page.dart
@@ -171,6 +171,7 @@ class _OTTVerificationPageState extends State<OTTVerificationPage> {
borderSide: BorderSide.none,
borderRadius: BorderRadius.circular(6),
),
+ fillColor: getEnteColorScheme(context).fillFaint,
),
controller: _verificationCodeController,
autofocus: false,
diff --git a/mobile/lib/ui/account/password_entry_page.dart b/mobile/lib/ui/account/password_entry_page.dart
index a5099e333e..54b7af8507 100644
--- a/mobile/lib/ui/account/password_entry_page.dart
+++ b/mobile/lib/ui/account/password_entry_page.dart
@@ -12,6 +12,7 @@ import "package:photos/generated/l10n.dart";
import "package:photos/l10n/l10n.dart";
import "package:photos/models/key_gen_result.dart";
import 'package:photos/services/user_service.dart';
+import "package:photos/theme/ente_theme.dart";
import 'package:photos/ui/account/recovery_key_page.dart';
import 'package:photos/ui/common/dynamic_fab.dart';
import 'package:photos/ui/common/web_page.dart';
@@ -218,8 +219,9 @@ class _PasswordEntryPageState extends State<PasswordEntryPage> {
child: TextFormField(
autofillHints: const [AutofillHints.newPassword],
decoration: InputDecoration(
- fillColor:
- _isPasswordValid ? _validFieldValueColor : null,
+ fillColor: _isPasswordValid
+ ? _validFieldValueColor
+ : getEnteColorScheme(context).fillFaint,
filled: true,
hintText: S.of(context).password,
contentPadding: const EdgeInsets.all(20),
@@ -282,7 +284,9 @@ class _PasswordEntryPageState extends State<PasswordEntryPage> {
autofillHints: const [AutofillHints.newPassword],
onEditingComplete: () => TextInput.finishAutofillContext(),
decoration: InputDecoration(
- fillColor: _passwordsMatch ? _validFieldValueColor : null,
+ fillColor: _passwordsMatch
+ ? _validFieldValueColor
+ : getEnteColorScheme(context).fillFaint,
filled: true,
hintText: S.of(context).confirmPassword,
contentPadding: const EdgeInsets.symmetric(
diff --git a/mobile/lib/ui/account/password_reentry_page.dart b/mobile/lib/ui/account/password_reentry_page.dart
index cfbc30c10f..d3f6be5644 100644
--- a/mobile/lib/ui/account/password_reentry_page.dart
+++ b/mobile/lib/ui/account/password_reentry_page.dart
@@ -222,6 +222,7 @@ class _PasswordReentryPageState extends State<PasswordReentryPage> {
decoration: InputDecoration(
hintText: S.of(context).enterYourPassword,
filled: true,
+ fillColor: getEnteColorScheme(context).fillFaint,
contentPadding: const EdgeInsets.all(20),
border: UnderlineInputBorder(
borderSide: BorderSide.none,
diff --git a/mobile/lib/ui/account/recovery_page.dart b/mobile/lib/ui/account/recovery_page.dart
index d5c651f92f..4b3d499955 100644
--- a/mobile/lib/ui/account/recovery_page.dart
+++ b/mobile/lib/ui/account/recovery_page.dart
@@ -103,6 +103,7 @@ class _RecoveryPageState extends State<RecoveryPage> {
child: TextFormField(
decoration: InputDecoration(
filled: true,
+ fillColor: getEnteColorScheme(context).fillFaint,
hintText: S.of(context).enterYourRecoveryKey,
contentPadding: const EdgeInsets.all(20),
border: UnderlineInputBorder(
diff --git a/mobile/lib/ui/account/request_pwd_verification_page.dart b/mobile/lib/ui/account/request_pwd_verification_page.dart
index 9da169dea6..e29d568867 100644
--- a/mobile/lib/ui/account/request_pwd_verification_page.dart
+++ b/mobile/lib/ui/account/request_pwd_verification_page.dart
@@ -174,6 +174,7 @@ class _RequestPasswordVerificationPageState
decoration: InputDecoration(
hintText: context.l10n.enterYourPassword,
filled: true,
+ fillColor: getEnteColorScheme(context).fillFaint,
contentPadding: const EdgeInsets.all(20),
border: UnderlineInputBorder(
borderSide: BorderSide.none,
diff --git a/mobile/lib/ui/account/verify_recovery_page.dart b/mobile/lib/ui/account/verify_recovery_page.dart
index 063d5f4b15..f4acc47385 100644
--- a/mobile/lib/ui/account/verify_recovery_page.dart
+++ b/mobile/lib/ui/account/verify_recovery_page.dart
@@ -11,6 +11,7 @@ import "package:photos/generated/l10n.dart";
import 'package:photos/services/local_authentication_service.dart';
import 'package:photos/services/user_remote_flag_service.dart';
import 'package:photos/services/user_service.dart';
+import "package:photos/theme/ente_theme.dart";
import 'package:photos/ui/account/recovery_key_page.dart';
import 'package:photos/ui/common/gradient_button.dart';
import 'package:photos/ui/components/buttons/button_widget.dart';
@@ -162,6 +163,7 @@ class _VerifyRecoveryPageState extends State<VerifyRecoveryPage> {
TextFormField(
decoration: InputDecoration(
filled: true,
+ fillColor: getEnteColorScheme(context).fillFaint,
hintText: S.of(context).enterYourRecoveryKey,
contentPadding: const EdgeInsets.all(20),
border: UnderlineInputBorder(
diff --git a/mobile/lib/ui/viewer/search/search_widget.dart b/mobile/lib/ui/viewer/search/search_widget.dart
index c624a78b32..2beaa1ec19 100644
--- a/mobile/lib/ui/viewer/search/search_widget.dart
+++ b/mobile/lib/ui/viewer/search/search_widget.dart
@@ -142,6 +142,7 @@ class SearchWidgetState extends State<SearchWidget> {
//TODO: Extract string
hintText: "Search",
filled: true,
+ fillColor: getEnteColorScheme(context).fillFaint,
border: const UnderlineInputBorder(
borderSide: BorderSide.none,
),