opt: get theme color

Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-04-28 21:32:30 +08:00
parent 451a84e696
commit ca993df0c6
149 changed files with 4415 additions and 4803 deletions

View File

@@ -24,8 +24,9 @@ class SearchText extends StatelessWidget {
@override
Widget build(BuildContext context) {
late final theme = Theme.of(context);
return Material(
color: bgColor ?? Theme.of(context).colorScheme.onInverseSurface,
color: bgColor ?? theme.colorScheme.onInverseSurface,
borderRadius: BorderRadius.circular(6),
child: InkWell(
onTap: () {
@@ -45,8 +46,7 @@ class SearchText extends StatelessWidget {
textAlign: textAlign,
style: TextStyle(
fontSize: fontSize,
color:
textColor ?? Theme.of(context).colorScheme.onSurfaceVariant,
color: textColor ?? theme.colorScheme.onSurfaceVariant,
),
),
),