mirror of
https://github.com/JGeek00/adguard-home-manager.git
synced 2025-04-24 07:46:06 +00:00
More UI changes
This commit is contained in:
parent
d8897f1d74
commit
22346362a6
56 changed files with 217 additions and 139 deletions
|
@ -33,8 +33,8 @@ ThemeData lightTheme(ColorScheme? dynamicColorScheme) => ThemeData(
|
|||
)
|
||||
),
|
||||
floatingActionButtonTheme: FloatingActionButtonThemeData(
|
||||
foregroundColor: Colors.white,
|
||||
backgroundColor: dynamicColorScheme != null ? dynamicColorScheme.primary : adguardGreenColor
|
||||
foregroundColor: dynamicColorScheme != null ? dynamicColorScheme.onPrimaryContainer : Colors.white,
|
||||
backgroundColor: dynamicColorScheme != null ? dynamicColorScheme.primaryContainer : adguardGreenColor
|
||||
),
|
||||
textButtonTheme: TextButtonThemeData(
|
||||
style: ButtonStyle(
|
||||
|
@ -47,9 +47,10 @@ ThemeData lightTheme(ColorScheme? dynamicColorScheme) => ThemeData(
|
|||
),
|
||||
),
|
||||
dividerColor: Colors.black12,
|
||||
listTileTheme: const ListTileThemeData(
|
||||
listTileTheme: ListTileThemeData(
|
||||
tileColor: Colors.transparent,
|
||||
iconColor: Color.fromRGBO(138, 138, 138, 1),
|
||||
textColor: dynamicColorScheme != null ? dynamicColorScheme.onSurfaceVariant : const Color.fromRGBO(117, 117, 117, 1),
|
||||
iconColor: dynamicColorScheme != null ? dynamicColorScheme.onSurfaceVariant : const Color.fromRGBO(117, 117, 117, 1),
|
||||
),
|
||||
checkboxTheme: CheckboxThemeData(
|
||||
checkColor: MaterialStateProperty.all(Colors.white),
|
||||
|
@ -102,8 +103,8 @@ ThemeData darkTheme(ColorScheme? dynamicColorScheme) => ThemeData(
|
|||
elevation: 4,
|
||||
),
|
||||
floatingActionButtonTheme: FloatingActionButtonThemeData(
|
||||
foregroundColor: Colors.white,
|
||||
backgroundColor: dynamicColorScheme != null ? dynamicColorScheme.primary : adguardGreenColor
|
||||
foregroundColor: dynamicColorScheme != null ? dynamicColorScheme.onPrimaryContainer : Colors.white,
|
||||
backgroundColor: dynamicColorScheme != null ? dynamicColorScheme.primaryContainer : adguardGreenColor
|
||||
),
|
||||
textButtonTheme: TextButtonThemeData(
|
||||
style: ButtonStyle(
|
||||
|
@ -125,14 +126,17 @@ ThemeData darkTheme(ColorScheme? dynamicColorScheme) => ThemeData(
|
|||
),
|
||||
),
|
||||
dividerColor: Colors.white12,
|
||||
listTileTheme: const ListTileThemeData(
|
||||
listTileTheme: ListTileThemeData(
|
||||
tileColor: Colors.transparent,
|
||||
iconColor: Color.fromRGBO(187, 187, 187, 1),
|
||||
textColor: dynamicColorScheme != null ? dynamicColorScheme.onSurfaceVariant : const Color.fromRGBO(187, 187, 187, 1),
|
||||
iconColor: dynamicColorScheme != null ? dynamicColorScheme.onSurfaceVariant : const Color.fromRGBO(187, 187, 187, 1),
|
||||
),
|
||||
checkboxTheme: CheckboxThemeData(
|
||||
checkColor: MaterialStateProperty.all(Colors.white),
|
||||
checkColor: MaterialStateProperty.all(
|
||||
dynamicColorScheme != null ? dynamicColorScheme.onPrimary : Colors.white
|
||||
),
|
||||
fillColor: MaterialStateProperty.all(
|
||||
dynamicColorScheme != null ? dynamicColorScheme.primary : adguardGreenColor
|
||||
dynamicColorScheme != null ? dynamicColorScheme.onSurface : adguardGreenColor
|
||||
),
|
||||
),
|
||||
tabBarTheme: TabBarTheme(
|
||||
|
@ -197,6 +201,9 @@ ThemeData lightThemeOldVersions(MaterialColor primaryColor) => ThemeData(
|
|||
overlayColor: MaterialStateProperty.all(primaryColor.shade50),
|
||||
)
|
||||
),
|
||||
cardTheme: CardTheme(
|
||||
surfaceTintColor: primaryColor
|
||||
),
|
||||
navigationBarTheme: NavigationBarThemeData(
|
||||
surfaceTintColor: primaryColor,
|
||||
indicatorColor: primaryColor
|
||||
|
@ -220,11 +227,12 @@ ThemeData lightThemeOldVersions(MaterialColor primaryColor) => ThemeData(
|
|||
dividerColor: Colors.black12,
|
||||
listTileTheme: const ListTileThemeData(
|
||||
tileColor: Colors.transparent,
|
||||
iconColor: Color.fromRGBO(138, 138, 138, 1),
|
||||
textColor: Color.fromRGBO(117, 117, 117, 1),
|
||||
iconColor: Color.fromRGBO(117, 117, 117, 1),
|
||||
),
|
||||
checkboxTheme: CheckboxThemeData(
|
||||
checkColor: MaterialStateProperty.all(Colors.white),
|
||||
fillColor: MaterialStateProperty.all(primaryColor),
|
||||
fillColor: MaterialStateProperty.all(primaryColor),
|
||||
),
|
||||
tabBarTheme: TabBarTheme(
|
||||
unselectedLabelColor: Colors.black,
|
||||
|
@ -260,7 +268,7 @@ ThemeData darkThemeOldVersions(MaterialColor primaryColor) => ThemeData(
|
|||
)
|
||||
),
|
||||
appBarTheme: AppBarTheme(
|
||||
color: Color.fromRGBO(18, 18, 18, 1),
|
||||
color: const Color.fromRGBO(18, 18, 18, 1),
|
||||
foregroundColor: Colors.white,
|
||||
elevation: 0,
|
||||
surfaceTintColor: primaryColor
|
||||
|
@ -293,6 +301,9 @@ ThemeData darkThemeOldVersions(MaterialColor primaryColor) => ThemeData(
|
|||
overlayColor: MaterialStateProperty.all(primaryColor.shade50),
|
||||
)
|
||||
),
|
||||
cardTheme: CardTheme(
|
||||
surfaceTintColor: primaryColor
|
||||
),
|
||||
inputDecorationTheme: InputDecorationTheme(
|
||||
floatingLabelStyle: TextStyle(
|
||||
color: primaryColor
|
||||
|
@ -305,6 +316,15 @@ ThemeData darkThemeOldVersions(MaterialColor primaryColor) => ThemeData(
|
|||
)
|
||||
)
|
||||
),
|
||||
checkboxTheme: CheckboxThemeData(
|
||||
checkColor: MaterialStateProperty.all(Colors.white),
|
||||
fillColor: MaterialStateProperty.all(primaryColor),
|
||||
),
|
||||
listTileTheme: const ListTileThemeData(
|
||||
tileColor: Colors.transparent,
|
||||
textColor: Color.fromRGBO(187, 187, 187, 1),
|
||||
iconColor: Color.fromRGBO(187, 187, 187, 1),
|
||||
),
|
||||
textSelectionTheme: TextSelectionThemeData(
|
||||
cursorColor: primaryColor
|
||||
),
|
||||
|
@ -318,14 +338,6 @@ ThemeData darkThemeOldVersions(MaterialColor primaryColor) => ThemeData(
|
|||
),
|
||||
),
|
||||
dividerColor: Colors.white12,
|
||||
listTileTheme: const ListTileThemeData(
|
||||
tileColor: Colors.transparent,
|
||||
iconColor: Color.fromRGBO(187, 187, 187, 1),
|
||||
),
|
||||
checkboxTheme: CheckboxThemeData(
|
||||
checkColor: MaterialStateProperty.all(Colors.white),
|
||||
fillColor: MaterialStateProperty.all(Colors.blue),
|
||||
),
|
||||
tabBarTheme: TabBarTheme(
|
||||
unselectedLabelColor: Colors.white,
|
||||
labelColor: primaryColor,
|
||||
|
|
|
@ -43,16 +43,18 @@ class _AppLogDetailsModalState extends State<AppLogDetailsModal> {
|
|||
return AlertDialog(
|
||||
title: Column(
|
||||
children: [
|
||||
const Icon(
|
||||
Icon(
|
||||
Icons.description_rounded,
|
||||
size: 26,
|
||||
size: 24,
|
||||
color: Theme.of(context).listTileTheme.iconColor,
|
||||
),
|
||||
const SizedBox(height: 20),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
AppLocalizations.of(context)!.logDetails,
|
||||
textAlign: TextAlign.center,
|
||||
style: const TextStyle(
|
||||
fontSize: 24
|
||||
style: TextStyle(
|
||||
fontSize: 24,
|
||||
color: Theme.of(context).colorScheme.onSurface
|
||||
),
|
||||
)
|
||||
],
|
||||
|
|
|
@ -50,8 +50,22 @@ class AppLogs extends StatelessWidget {
|
|||
padding: const EdgeInsets.only(top: 0),
|
||||
itemCount: appConfigProvider.logs.length,
|
||||
itemBuilder: (context, index) => ListTile(
|
||||
title: Text(appConfigProvider.logs[index].message),
|
||||
subtitle: Text(appConfigProvider.logs[index].dateTime.toString()),
|
||||
title: Text(
|
||||
appConfigProvider.logs[index].message,
|
||||
style: TextStyle(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.normal,
|
||||
color: Theme.of(context).colorScheme.onSurface
|
||||
),
|
||||
),
|
||||
subtitle: Text(
|
||||
appConfigProvider.logs[index].dateTime.toString(),
|
||||
style: TextStyle(
|
||||
fontSize: 14,
|
||||
fontWeight: FontWeight.normal,
|
||||
color: Theme.of(context).listTileTheme.textColor
|
||||
),
|
||||
),
|
||||
trailing: Text(appConfigProvider.logs[index].type),
|
||||
onTap: () => {
|
||||
showDialog(
|
||||
|
|
|
@ -220,7 +220,7 @@ class _AddedListState extends State<AddedList> {
|
|||
Text(
|
||||
widget.data[index].ids.toString().replaceAll(RegExp(r'^\[|\]$'), ''),
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant
|
||||
color: Theme.of(context).listTileTheme.textColor
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 7),
|
||||
|
|
|
@ -322,7 +322,7 @@ class _ClientScreenState extends State<ClientScreen> {
|
|||
children: [
|
||||
Icon(
|
||||
Icons.label_rounded,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
const SizedBox(width: 16),
|
||||
Column(
|
||||
|
@ -341,7 +341,7 @@ class _ClientScreenState extends State<ClientScreen> {
|
|||
? "${selectedTags.length} ${AppLocalizations.of(context)!.tagsSelected}"
|
||||
: AppLocalizations.of(context)!.noTagsSelected,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
)
|
||||
],
|
||||
|
@ -540,7 +540,7 @@ class _ClientScreenState extends State<ClientScreen> {
|
|||
Icon(
|
||||
Icons.public,
|
||||
color: useGlobalSettingsServices == false
|
||||
? Theme.of(context).colorScheme.onSurface
|
||||
? Theme.of(context).listTileTheme.iconColor
|
||||
: Theme.of(context).colorScheme.onSurface.withOpacity(0.38),
|
||||
),
|
||||
const SizedBox(width: 16),
|
||||
|
@ -563,7 +563,7 @@ class _ClientScreenState extends State<ClientScreen> {
|
|||
? "${blockedServices.length} ${AppLocalizations.of(context)!.servicesBlocked}"
|
||||
: AppLocalizations.of(context)!.noBlockedServicesSelected,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
)
|
||||
]
|
||||
|
|
|
@ -143,7 +143,7 @@ class _ClientsWidgetState extends State<ClientsWidget> with TickerProviderStateM
|
|||
color: Theme.of(context).scaffoldBackgroundColor,
|
||||
border: Border(
|
||||
top: BorderSide(
|
||||
color: Theme.of(context).colorScheme.surfaceVariant
|
||||
color: Theme.of(context).colorScheme.onSurface.withOpacity(0.1)
|
||||
)
|
||||
)
|
||||
),
|
||||
|
|
|
@ -69,10 +69,10 @@ class ClientsFab extends StatelessWidget {
|
|||
|
||||
return FloatingActionButton(
|
||||
onPressed: () => openAddClient(),
|
||||
backgroundColor: Theme.of(context).colorScheme.primaryContainer,
|
||||
backgroundColor: Theme.of(context).floatingActionButtonTheme.backgroundColor,
|
||||
child: Icon(
|
||||
Icons.add,
|
||||
color: Theme.of(context).colorScheme.onPrimaryContainer,
|
||||
color: Theme.of(context).floatingActionButtonTheme.foregroundColor,
|
||||
),
|
||||
);
|
||||
}
|
||||
|
|
|
@ -20,9 +20,17 @@ class OptionsModal extends StatelessWidget {
|
|||
),
|
||||
title: Column(
|
||||
children: [
|
||||
const Icon(Icons.more_horiz),
|
||||
Icon(
|
||||
Icons.more_horiz,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
Text(AppLocalizations.of(context)!.options)
|
||||
Text(
|
||||
AppLocalizations.of(context)!.options,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurface
|
||||
),
|
||||
)
|
||||
],
|
||||
),
|
||||
content: Column(
|
||||
|
@ -37,12 +45,13 @@ class OptionsModal extends StatelessWidget {
|
|||
title: Text(
|
||||
AppLocalizations.of(context)!.edit,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurface
|
||||
color: Theme.of(context).colorScheme.onSurface,
|
||||
fontWeight: FontWeight.normal
|
||||
),
|
||||
),
|
||||
leading: Icon(
|
||||
Icons.edit,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.iconColor,
|
||||
),
|
||||
),
|
||||
ListTile(
|
||||
|
@ -53,12 +62,13 @@ class OptionsModal extends StatelessWidget {
|
|||
title: Text(
|
||||
AppLocalizations.of(context)!.delete,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurface
|
||||
color: Theme.of(context).colorScheme.onSurface,
|
||||
fontWeight: FontWeight.normal
|
||||
),
|
||||
),
|
||||
leading: Icon(
|
||||
Icons.delete,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.iconColor,
|
||||
),
|
||||
),
|
||||
],
|
||||
|
|
|
@ -17,7 +17,7 @@ class RemoveClientModal extends StatelessWidget {
|
|||
Icon(
|
||||
Icons.delete_rounded,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
|
|
|
@ -51,7 +51,7 @@ class _ServicesModalState extends State<ServicesModal> {
|
|||
children: [
|
||||
Icon(
|
||||
Icons.public,
|
||||
color: Theme.of(context).colorScheme.onSurface,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
|
|
|
@ -51,7 +51,7 @@ class _TagsModalState extends State<TagsModal> {
|
|||
children: [
|
||||
Icon(
|
||||
Icons.label_rounded,
|
||||
color: Theme.of(context).colorScheme.onSurface
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
|
|
|
@ -17,9 +17,10 @@ class FabConnect extends StatelessWidget {
|
|||
|
||||
return FloatingActionButton(
|
||||
onPressed: openAddServerModal,
|
||||
backgroundColor: Theme.of(context).floatingActionButtonTheme.backgroundColor,
|
||||
child: Icon(
|
||||
Icons.add_rounded,
|
||||
color: Theme.of(context).primaryColor.computeLuminance() > 0.5 ? Colors.black : Colors.white,
|
||||
color: Theme.of(context).floatingActionButtonTheme.foregroundColor,
|
||||
),
|
||||
);
|
||||
}
|
||||
|
|
|
@ -1,9 +1,11 @@
|
|||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_gen/gen_l10n/app_localizations.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
import 'package:material_segmented_control/material_segmented_control.dart';
|
||||
import 'package:flutter_web_browser/flutter_web_browser.dart';
|
||||
|
||||
import 'package:adguard_home_manager/constants/urls.dart';
|
||||
import 'package:adguard_home_manager/providers/app_config_provider.dart';
|
||||
|
||||
class AddCustomRule extends StatefulWidget {
|
||||
final void Function(String) onConfirm;
|
||||
|
@ -88,11 +90,17 @@ class _AddCustomRuleState extends State<AddCustomRule> {
|
|||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final appConfigProvider = Provider.of<AppConfigProvider>(context);
|
||||
|
||||
Map<int, Widget> presets = {
|
||||
0: Text(
|
||||
AppLocalizations.of(context)!.block,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurface,
|
||||
color: appConfigProvider.useDynamicColor == true
|
||||
? Theme.of(context).floatingActionButtonTheme.foregroundColor!
|
||||
: preset == 0
|
||||
? Colors.white
|
||||
: Theme.of(context).primaryColor,
|
||||
fontSize: 14,
|
||||
fontWeight: FontWeight.w500
|
||||
),
|
||||
|
@ -100,7 +108,11 @@ class _AddCustomRuleState extends State<AddCustomRule> {
|
|||
1: Text(
|
||||
AppLocalizations.of(context)!.unblock,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurface,
|
||||
color: appConfigProvider.useDynamicColor == true
|
||||
? Theme.of(context).floatingActionButtonTheme.foregroundColor!
|
||||
: preset == 1
|
||||
? Colors.white
|
||||
: Theme.of(context).primaryColor,
|
||||
fontSize: 14,
|
||||
fontWeight: FontWeight.w500
|
||||
),
|
||||
|
@ -108,7 +120,11 @@ class _AddCustomRuleState extends State<AddCustomRule> {
|
|||
2: Text(
|
||||
AppLocalizations.of(context)!.custom,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurface,
|
||||
color: appConfigProvider.useDynamicColor == true
|
||||
? Theme.of(context).floatingActionButtonTheme.foregroundColor!
|
||||
: preset == 2
|
||||
? Colors.white
|
||||
: Theme.of(context).primaryColor,
|
||||
fontSize: 14,
|
||||
fontWeight: FontWeight.w500
|
||||
),
|
||||
|
@ -172,7 +188,7 @@ class _AddCustomRuleState extends State<AddCustomRule> {
|
|||
children: presets,
|
||||
selectionIndex: preset,
|
||||
onSegmentChosen: (value) => setState(() => preset = value),
|
||||
selectedColor: Theme.of(context).colorScheme.secondaryContainer,
|
||||
selectedColor: Theme.of(context).floatingActionButtonTheme.backgroundColor!,
|
||||
unselectedColor: Colors.transparent,
|
||||
borderColor: Theme.of(context).colorScheme.onSurface,
|
||||
),
|
||||
|
|
|
@ -92,7 +92,7 @@ class _AddListModalState extends State<AddListModal> {
|
|||
? Icons.verified_user_rounded
|
||||
: Icons.gpp_bad_rounded,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
|
|
|
@ -76,7 +76,7 @@ class _BlockedServicesModalState extends State<BlockedServicesModal> {
|
|||
child: Icon(
|
||||
Icons.block,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
|
|
|
@ -143,7 +143,7 @@ class _CheckHostModalState extends State<CheckHostModal> {
|
|||
child: Icon(
|
||||
Icons.shield_rounded,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
|
|
|
@ -17,7 +17,7 @@ class DeleteListModal extends StatelessWidget {
|
|||
Icon(
|
||||
Icons.delete_rounded,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
|
|
|
@ -168,10 +168,10 @@ class FiltersFab extends StatelessWidget {
|
|||
onPressed: type == 'blacklist' || type == 'whitelist'
|
||||
? () => openAddWhitelistBlacklist()
|
||||
: () => openAddCustomRule(),
|
||||
backgroundColor: Theme.of(context).colorScheme.primaryContainer,
|
||||
backgroundColor: Theme.of(context).floatingActionButtonTheme.backgroundColor,
|
||||
child: Icon(
|
||||
Icons.add,
|
||||
color: Theme.of(context).colorScheme.onPrimaryContainer,
|
||||
color: Theme.of(context).floatingActionButtonTheme.foregroundColor,
|
||||
),
|
||||
);
|
||||
}
|
||||
|
|
|
@ -26,7 +26,7 @@ class FilterListTile extends StatelessWidget {
|
|||
Icon(
|
||||
icon,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.iconColor,
|
||||
),
|
||||
const SizedBox(width: 16),
|
||||
Flexible(
|
||||
|
@ -46,7 +46,7 @@ class FilterListTile extends StatelessWidget {
|
|||
subtitle,
|
||||
style: TextStyle(
|
||||
fontSize: 14,
|
||||
color: color ?? Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: color ?? Theme.of(context).listTileTheme.textColor,
|
||||
fontWeight: bold == true ? FontWeight.bold : FontWeight.w400
|
||||
),
|
||||
),
|
||||
|
|
|
@ -393,7 +393,7 @@ class _FiltersWidgetState extends State<FiltersWidget> with TickerProviderStateM
|
|||
color: Theme.of(context).scaffoldBackgroundColor,
|
||||
border: Border(
|
||||
top: BorderSide(
|
||||
color: Theme.of(context).colorScheme.surfaceVariant
|
||||
color: Theme.of(context).colorScheme.onSurface.withOpacity(0.1)
|
||||
)
|
||||
)
|
||||
),
|
||||
|
|
|
@ -306,12 +306,12 @@ class _ListDetailsScreenState extends State<ListDetailsScreen> {
|
|||
right: 20,
|
||||
child: FloatingActionButton(
|
||||
onPressed: () => enableDisableList(widget.list, !enabled),
|
||||
backgroundColor: Theme.of(context).colorScheme.primaryContainer,
|
||||
backgroundColor: Theme.of(context).floatingActionButtonTheme.backgroundColor,
|
||||
child: Icon(
|
||||
enabled == true
|
||||
? Icons.gpp_bad_rounded
|
||||
: Icons.verified_user_rounded,
|
||||
color: Theme.of(context).colorScheme.onPrimaryContainer,
|
||||
color: Theme.of(context).floatingActionButtonTheme.foregroundColor,
|
||||
),
|
||||
),
|
||||
)
|
||||
|
|
|
@ -17,7 +17,7 @@ class RemoveCustomRule extends StatelessWidget {
|
|||
Icon(
|
||||
Icons.shield_rounded,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
|
|
|
@ -64,7 +64,7 @@ class _UpdateIntervalListsModalState extends State<UpdateIntervalListsModal> {
|
|||
child: Icon(
|
||||
Icons.update_rounded,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
),
|
||||
Container(
|
||||
|
|
|
@ -86,7 +86,7 @@ class HomeAppBar extends StatelessWidget with PreferredSizeWidget {
|
|||
"${server.connectionMethod}://${server.domain}${server.path ?? ""}${server.port != null ? ':${server.port}' : ""}",
|
||||
style: TextStyle(
|
||||
fontSize: 14,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant
|
||||
color: Theme.of(context).listTileTheme.textColor
|
||||
),
|
||||
)
|
||||
],
|
||||
|
|
|
@ -24,10 +24,10 @@ class HomeFab extends StatelessWidget {
|
|||
return serversProvider.serverStatus.loadStatus == 1
|
||||
? FloatingActionButton(
|
||||
onPressed: openManagementBottomSheet,
|
||||
backgroundColor: Theme.of(context).colorScheme.primaryContainer,
|
||||
backgroundColor: Theme.of(context).floatingActionButtonTheme.backgroundColor,
|
||||
child: Icon(
|
||||
Icons.shield_rounded,
|
||||
color: Theme.of(context).colorScheme.onPrimaryContainer,
|
||||
color: Theme.of(context).floatingActionButtonTheme.foregroundColor,
|
||||
),
|
||||
)
|
||||
: const SizedBox();
|
||||
|
|
|
@ -94,7 +94,7 @@ class ManagementModal extends StatelessWidget {
|
|||
Icon(
|
||||
icon,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.iconColor,
|
||||
),
|
||||
const SizedBox(width: 16),
|
||||
Text(
|
||||
|
@ -144,7 +144,7 @@ class ManagementModal extends StatelessWidget {
|
|||
child: Icon(
|
||||
Icons.shield_rounded,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
),
|
||||
Padding(
|
||||
|
|
|
@ -57,7 +57,7 @@ class _FilterStatusModalState extends State<FilterStatusModal> {
|
|||
Icon(
|
||||
icon,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
const SizedBox(width: 16),
|
||||
Text(
|
||||
|
@ -102,7 +102,7 @@ class _FilterStatusModalState extends State<FilterStatusModal> {
|
|||
child: Icon(
|
||||
Icons.shield_rounded,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
),
|
||||
Text(
|
||||
|
|
|
@ -141,14 +141,14 @@ class LogDetailsScreen extends StatelessWidget {
|
|||
vertical: 5
|
||||
),
|
||||
decoration: BoxDecoration(
|
||||
color: Theme.of(context).colorScheme.primaryContainer,
|
||||
color: Theme.of(context).floatingActionButtonTheme.backgroundColor,
|
||||
borderRadius: BorderRadius.circular(30)
|
||||
),
|
||||
child: Text(
|
||||
"CACHE",
|
||||
style: TextStyle(
|
||||
fontSize: 12,
|
||||
color: Theme.of(context).colorScheme.onPrimaryContainer,
|
||||
color: Theme.of(context).floatingActionButtonTheme.foregroundColor,
|
||||
fontWeight: FontWeight.w500
|
||||
),
|
||||
),
|
||||
|
@ -278,14 +278,14 @@ class LogDetailsScreen extends StatelessWidget {
|
|||
vertical: 5
|
||||
),
|
||||
decoration: BoxDecoration(
|
||||
color: Theme.of(context).colorScheme.primaryContainer,
|
||||
color: Theme.of(context).floatingActionButtonTheme.backgroundColor,
|
||||
borderRadius: BorderRadius.circular(30)
|
||||
),
|
||||
child: Text(
|
||||
a.type,
|
||||
style: TextStyle(
|
||||
fontSize: 12,
|
||||
color: Theme.of(context).colorScheme.onPrimaryContainer,
|
||||
color: Theme.of(context).floatingActionButtonTheme.foregroundColor,
|
||||
fontWeight: FontWeight.w500
|
||||
),
|
||||
),
|
||||
|
|
|
@ -29,7 +29,7 @@ class LogListTile extends StatelessWidget {
|
|||
Icon(
|
||||
icon,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.iconColor,
|
||||
),
|
||||
const SizedBox(width: 16),
|
||||
Flexible(
|
||||
|
@ -48,7 +48,7 @@ class LogListTile extends StatelessWidget {
|
|||
subtitle!,
|
||||
style: TextStyle(
|
||||
fontSize: 14,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor,
|
||||
),
|
||||
)
|
||||
],
|
||||
|
|
|
@ -97,7 +97,7 @@ class LogTile extends StatelessWidget {
|
|||
Icon(
|
||||
Icons.smartphone_rounded,
|
||||
size: 16,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor,
|
||||
),
|
||||
const SizedBox(width: 5),
|
||||
SizedBox(
|
||||
|
@ -105,7 +105,7 @@ class LogTile extends StatelessWidget {
|
|||
log.client,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor,
|
||||
fontSize: 14,
|
||||
height: 1.4,
|
||||
fontWeight: FontWeight.w400,
|
||||
|
@ -118,7 +118,7 @@ class LogTile extends StatelessWidget {
|
|||
Icon(
|
||||
Icons.schedule_rounded,
|
||||
size: 16,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor,
|
||||
),
|
||||
const SizedBox(width: 5),
|
||||
SizedBox(
|
||||
|
@ -126,7 +126,7 @@ class LogTile extends StatelessWidget {
|
|||
formatTimestampUTCFromAPI(log.time, 'HH:mm:ss'),
|
||||
overflow: TextOverflow.ellipsis,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor,
|
||||
fontSize: 13
|
||||
),
|
||||
),
|
||||
|
@ -141,7 +141,7 @@ class LogTile extends StatelessWidget {
|
|||
Icon(
|
||||
Icons.smartphone_rounded,
|
||||
size: 16,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor,
|
||||
),
|
||||
const SizedBox(width: 15),
|
||||
SizedBox(
|
||||
|
@ -149,7 +149,7 @@ class LogTile extends StatelessWidget {
|
|||
log.client,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor,
|
||||
fontSize: 13
|
||||
),
|
||||
),
|
||||
|
@ -171,7 +171,7 @@ class LogTile extends StatelessWidget {
|
|||
log.clientInfo!.name,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor,
|
||||
fontSize: 13
|
||||
),
|
||||
),
|
||||
|
@ -185,7 +185,7 @@ class LogTile extends StatelessWidget {
|
|||
Icon(
|
||||
Icons.schedule_rounded,
|
||||
size: 16,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor,
|
||||
),
|
||||
const SizedBox(width: 15),
|
||||
SizedBox(
|
||||
|
@ -193,7 +193,7 @@ class LogTile extends StatelessWidget {
|
|||
formatTimestampUTCFromAPI(log.time, 'HH:mm:ss'),
|
||||
overflow: TextOverflow.ellipsis,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor,
|
||||
fontSize: 13
|
||||
),
|
||||
),
|
||||
|
@ -207,7 +207,7 @@ class LogTile extends StatelessWidget {
|
|||
Icon(
|
||||
Icons.timer,
|
||||
size: 16,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor,
|
||||
),
|
||||
const SizedBox(width: 15),
|
||||
SizedBox(
|
||||
|
@ -215,7 +215,7 @@ class LogTile extends StatelessWidget {
|
|||
"${double.parse(log.elapsedMs).toStringAsFixed(2)} ms",
|
||||
overflow: TextOverflow.ellipsis,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor,
|
||||
fontSize: 13
|
||||
),
|
||||
),
|
||||
|
|
|
@ -131,7 +131,7 @@ class _LogsConfigModalWidgetState extends State<LogsConfigModalWidget> {
|
|||
child: Icon(
|
||||
Icons.settings,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
|
|
|
@ -195,7 +195,7 @@ class _LogsFiltersModalWidgetState extends State<LogsFiltersModalWidget> {
|
|||
child: Icon(
|
||||
Icons.filter_list_rounded,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
),
|
||||
Text(
|
||||
|
|
|
@ -88,10 +88,10 @@ class _ServersState extends State<Servers> {
|
|||
right: 20,
|
||||
child: FloatingActionButton(
|
||||
onPressed: openAddServerModal,
|
||||
backgroundColor: Theme.of(context).colorScheme.primaryContainer,
|
||||
backgroundColor: Theme.of(context).floatingActionButtonTheme.backgroundColor,
|
||||
child: Icon(
|
||||
Icons.add,
|
||||
color: Theme.of(context).colorScheme.onPrimaryContainer
|
||||
color: Theme.of(context).floatingActionButtonTheme.foregroundColor,
|
||||
),
|
||||
),
|
||||
),
|
||||
|
|
|
@ -117,9 +117,7 @@ class _AccessSettingsWidgetState extends State<AccessSettingsWidget> with Ticker
|
|||
color: Theme.of(context).scaffoldBackgroundColor,
|
||||
border: Border(
|
||||
top: BorderSide(
|
||||
color: Theme.of(context).brightness == Brightness.light
|
||||
? const Color.fromRGBO(220, 220, 220, 1)
|
||||
: const Color.fromRGBO(50, 50, 50, 1)
|
||||
color: Theme.of(context).colorScheme.onSurface.withOpacity(0.1)
|
||||
)
|
||||
)
|
||||
),
|
||||
|
|
|
@ -86,7 +86,7 @@ class _AddClientModalState extends State<AddClientModal> {
|
|||
Icon(
|
||||
icon(),
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
|
|
|
@ -246,7 +246,7 @@ class _ClientsListState extends State<ClientsList> {
|
|||
children: [
|
||||
Icon(
|
||||
Icons.info_rounded,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor,
|
||||
),
|
||||
const SizedBox(width: 20),
|
||||
Flexible(
|
||||
|
@ -267,7 +267,13 @@ class _ClientsListState extends State<ClientsList> {
|
|||
padding: const EdgeInsets.only(top: 0),
|
||||
itemCount: widget.data.length,
|
||||
itemBuilder: (context, index) => ListTile(
|
||||
title: Text(widget.data[index]),
|
||||
title: Text(
|
||||
widget.data[index],
|
||||
style: TextStyle(
|
||||
fontWeight: FontWeight.normal,
|
||||
color: Theme.of(context).colorScheme.onSurface
|
||||
),
|
||||
),
|
||||
trailing: IconButton(
|
||||
onPressed: () => {
|
||||
showDialog(
|
||||
|
@ -315,7 +321,7 @@ class _ClientsListState extends State<ClientsList> {
|
|||
: -70,
|
||||
right: 20,
|
||||
child: FloatingActionButton(
|
||||
backgroundColor: Theme.of(context).colorScheme.primaryContainer,
|
||||
backgroundColor: Theme.of(context).floatingActionButtonTheme.backgroundColor,
|
||||
onPressed: () {
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
|
@ -329,7 +335,7 @@ class _ClientsListState extends State<ClientsList> {
|
|||
},
|
||||
child: Icon(
|
||||
Icons.add,
|
||||
color: Theme.of(context).colorScheme.onPrimaryContainer
|
||||
color: Theme.of(context).floatingActionButtonTheme.foregroundColor,
|
||||
),
|
||||
),
|
||||
)
|
||||
|
|
|
@ -68,7 +68,7 @@ class _AddStaticLeaseModalState extends State<AddStaticLeaseModal> {
|
|||
return Padding(
|
||||
padding: MediaQuery.of(context).viewInsets,
|
||||
child: Container(
|
||||
height: 550,
|
||||
height: 510,
|
||||
decoration: BoxDecoration(
|
||||
color: Theme.of(context).dialogBackgroundColor,
|
||||
borderRadius: const BorderRadius.only(
|
||||
|
@ -84,22 +84,24 @@ class _AddStaticLeaseModalState extends State<AddStaticLeaseModal> {
|
|||
? const NeverScrollableScrollPhysics()
|
||||
: null,
|
||||
children: [
|
||||
const Padding(
|
||||
padding: EdgeInsets.only(top: 28),
|
||||
Padding(
|
||||
padding: const EdgeInsets.only(top: 24),
|
||||
child: Icon(
|
||||
Icons.add,
|
||||
size: 26,
|
||||
size: 24,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 20),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
AppLocalizations.of(context)!.addStaticLease,
|
||||
textAlign: TextAlign.center,
|
||||
style: const TextStyle(
|
||||
fontSize: 24
|
||||
style: TextStyle(
|
||||
fontSize: 24,
|
||||
color: Theme.of(context).colorScheme.onSurface
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 30),
|
||||
const SizedBox(height: 16),
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 28),
|
||||
child: TextFormField(
|
||||
|
|
|
@ -14,18 +14,27 @@ class DeleteStaticLeaseModal extends StatelessWidget {
|
|||
return AlertDialog(
|
||||
title: Column(
|
||||
children: [
|
||||
const Icon(
|
||||
Icon(
|
||||
Icons.delete_rounded,
|
||||
size: 26,
|
||||
size: 24,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
const SizedBox(height: 20),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
AppLocalizations.of(context)!.deleteStaticLease,
|
||||
textAlign: TextAlign.center,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurface
|
||||
),
|
||||
)
|
||||
],
|
||||
),
|
||||
content: Text(AppLocalizations.of(context)!.deleteStaticLeaseDescription),
|
||||
content: Text(
|
||||
AppLocalizations.of(context)!.deleteStaticLeaseDescription,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant
|
||||
),
|
||||
),
|
||||
actions: [
|
||||
TextButton(
|
||||
onPressed: () => Navigator.pop(context),
|
||||
|
|
|
@ -409,7 +409,7 @@ class _DhcpWidgetState extends State<DhcpWidget> {
|
|||
selectedInterface!.name,
|
||||
style: TextStyle(
|
||||
fontSize: 14,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor
|
||||
),
|
||||
)
|
||||
]
|
||||
|
|
|
@ -184,9 +184,10 @@ class DhcpLeases extends StatelessWidget {
|
|||
floatingActionButton: staticLeases == true
|
||||
? FloatingActionButton(
|
||||
onPressed: openAddStaticLease,
|
||||
backgroundColor: Theme.of(context).floatingActionButtonTheme.backgroundColor,
|
||||
child: Icon(
|
||||
Icons.add,
|
||||
color: Theme.of(context).primaryColor.computeLuminance() > 0.5 ? Colors.black : Colors.white,
|
||||
color: Theme.of(context).floatingActionButtonTheme.foregroundColor,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
@ -36,7 +36,7 @@ class SelectInterfaceModal extends StatelessWidget {
|
|||
child: Icon(
|
||||
Icons.settings_ethernet_rounded,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
|
|
|
@ -142,7 +142,7 @@ class _BootstrapDnsScreenState extends State<BootstrapDnsScreen> {
|
|||
children: [
|
||||
Icon(
|
||||
Icons.info_rounded,
|
||||
color: Theme.of(context).colorScheme.secondary
|
||||
color: Theme.of(context).listTileTheme.iconColor,
|
||||
),
|
||||
const SizedBox(width: 20),
|
||||
Flexible(
|
||||
|
|
|
@ -175,7 +175,7 @@ class _PrivateReverseDnsServersScreenState extends State<PrivateReverseDnsServer
|
|||
children: [
|
||||
Icon(
|
||||
Icons.info_rounded,
|
||||
color: Theme.of(context).colorScheme.secondary
|
||||
color: Theme.of(context).listTileTheme.iconColor,
|
||||
),
|
||||
const SizedBox(width: 20),
|
||||
Flexible(
|
||||
|
|
|
@ -72,7 +72,7 @@ class _AddDnsRewriteModalState extends State<AddDnsRewriteModal> {
|
|||
child: Icon(
|
||||
Icons.add,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
|
|
|
@ -286,6 +286,7 @@ class _DnsRewritesWidgetState extends State<DnsRewritesWidget> {
|
|||
),
|
||||
body: generateBody(),
|
||||
floatingActionButton: FloatingActionButton(
|
||||
backgroundColor: Theme.of(context).floatingActionButtonTheme.backgroundColor,
|
||||
onPressed: () => {
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
|
@ -298,7 +299,7 @@ class _DnsRewritesWidgetState extends State<DnsRewritesWidget> {
|
|||
},
|
||||
child: Icon(
|
||||
Icons.add,
|
||||
color: Theme.of(context).primaryColor.computeLuminance() > 0.5 ? Colors.black : Colors.white,
|
||||
color: Theme.of(context).floatingActionButtonTheme.foregroundColor,
|
||||
),
|
||||
),
|
||||
);
|
||||
|
|
|
@ -376,7 +376,7 @@ class _EncryptionSettingsWidgetState extends State<EncryptionSettingsWidget> {
|
|||
children: [
|
||||
Icon(
|
||||
Icons.info_rounded,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor,
|
||||
),
|
||||
const SizedBox(width: 20),
|
||||
Flexible(
|
||||
|
|
|
@ -49,7 +49,7 @@ class EncryptionMasterSwitch extends StatelessWidget {
|
|||
AppLocalizations.of(context)!.enableEncryptionTypes,
|
||||
style: TextStyle(
|
||||
fontSize: 14,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant
|
||||
color: Theme.of(context).listTileTheme.textColor
|
||||
),
|
||||
)
|
||||
],
|
||||
|
|
|
@ -16,7 +16,7 @@ class DnsAddressesModal extends StatelessWidget {
|
|||
children: [
|
||||
Icon(
|
||||
Icons.route_rounded,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
|
@ -37,7 +37,7 @@ class DnsAddressesModal extends StatelessWidget {
|
|||
address,
|
||||
style: TextStyle(
|
||||
fontWeight: FontWeight.normal,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant
|
||||
color: Theme.of(context).listTileTheme.textColor
|
||||
),
|
||||
),
|
||||
)).toList(),
|
||||
|
|
|
@ -180,7 +180,7 @@ class _TopItemsScreenState extends State<TopItemsScreen> {
|
|||
child: Text(
|
||||
"${doubleFormat((screenData[index].values.toList()[0]/total*100), Platform.localeName)}%",
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant
|
||||
color: Theme.of(context).listTileTheme.textColor
|
||||
),
|
||||
),
|
||||
),
|
||||
|
|
|
@ -252,7 +252,11 @@ class _AddServerModalState extends State<AddServerModal> {
|
|||
0: Text(
|
||||
'HTTP',
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurface,
|
||||
color: appConfigProvider.useDynamicColor == true
|
||||
? Theme.of(context).floatingActionButtonTheme.foregroundColor!
|
||||
: connectionType == 'http'
|
||||
? Colors.white
|
||||
: Theme.of(context).primaryColor,
|
||||
fontSize: 14,
|
||||
fontWeight: FontWeight.w500
|
||||
),
|
||||
|
@ -260,7 +264,11 @@ class _AddServerModalState extends State<AddServerModal> {
|
|||
1: Text(
|
||||
'HTTPS',
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurface,
|
||||
color: appConfigProvider.useDynamicColor == true
|
||||
? Theme.of(context).floatingActionButtonTheme.foregroundColor!
|
||||
: connectionType == 'https'
|
||||
? Colors.white
|
||||
: Theme.of(context).primaryColor,
|
||||
fontSize: 14,
|
||||
fontWeight: FontWeight.w500
|
||||
),
|
||||
|
@ -475,13 +483,11 @@ class _AddServerModalState extends State<AddServerModal> {
|
|||
);
|
||||
}
|
||||
}
|
||||
print(connectionType);
|
||||
|
||||
return Stack(
|
||||
children: [
|
||||
Scaffold(
|
||||
backgroundColor: Theme.of(context).dialogBackgroundColor,
|
||||
appBar: AppBar(
|
||||
systemOverlayStyle: systemUiOverlayStyleConfig(context),
|
||||
appBar: AppBar(
|
||||
title: Text(AppLocalizations.of(context)!.createConnection),
|
||||
actions: [
|
||||
Padding(
|
||||
|
@ -560,7 +566,7 @@ print(connectionType);
|
|||
connectionType = 'https';
|
||||
}
|
||||
}),
|
||||
selectedColor: Theme.of(context).colorScheme.secondaryContainer,
|
||||
selectedColor: Theme.of(context).floatingActionButtonTheme.backgroundColor!,
|
||||
unselectedColor: Colors.transparent,
|
||||
borderColor: Theme.of(context).colorScheme.onSurface,
|
||||
),
|
||||
|
|
|
@ -39,7 +39,7 @@ class CustomListTile extends StatelessWidget {
|
|||
Icon(
|
||||
icon,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.iconColor,
|
||||
),
|
||||
const SizedBox(width: 16),
|
||||
],
|
||||
|
@ -61,7 +61,7 @@ class CustomListTile extends StatelessWidget {
|
|||
if (subtitle != null && subtitleWidget == null) Text(
|
||||
subtitle!,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor,
|
||||
fontSize: 14,
|
||||
fontWeight: FontWeight.w400
|
||||
),
|
||||
|
|
|
@ -59,7 +59,7 @@ class CustomRadioListTile extends StatelessWidget {
|
|||
child: Text(
|
||||
subtitle!,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
color: Theme.of(context).listTileTheme.textColor,
|
||||
fontSize: 14
|
||||
),
|
||||
),
|
||||
|
|
|
@ -55,8 +55,8 @@ class CustomSwitchListTile extends StatelessWidget {
|
|||
style: TextStyle(
|
||||
fontSize: 14,
|
||||
color: disabled != null && disabled == true
|
||||
? Theme.of(context).colorScheme.onSurfaceVariant.withOpacity(0.38)
|
||||
: Theme.of(context).colorScheme.onSurfaceVariant
|
||||
? Theme.of(context).listTileTheme.textColor!.withOpacity(0.38)
|
||||
: Theme.of(context).listTileTheme.textColor
|
||||
),
|
||||
),
|
||||
),
|
||||
|
|
|
@ -49,7 +49,7 @@ class DeleteModal extends StatelessWidget {
|
|||
Icon(
|
||||
Icons.delete,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary
|
||||
color: Theme.of(context).listTileTheme.iconColor
|
||||
),
|
||||
Padding(
|
||||
padding: const EdgeInsets.only(top: 16),
|
||||
|
|
|
@ -187,12 +187,12 @@ class _ServersListState extends State<ServersList> with SingleTickerProviderStat
|
|||
Container(
|
||||
padding: const EdgeInsets.all(1),
|
||||
decoration: BoxDecoration(
|
||||
color: Theme.of(context).colorScheme.primaryContainer,
|
||||
color: Theme.of(context).floatingActionButtonTheme.backgroundColor,
|
||||
borderRadius: BorderRadius.circular(20)
|
||||
),
|
||||
child: Icon(
|
||||
Icons.star,
|
||||
color: Theme.of(context).colorScheme.onPrimaryContainer,
|
||||
color: Theme.of(context).floatingActionButtonTheme.foregroundColor,
|
||||
size: 10,
|
||||
),
|
||||
),
|
||||
|
|
|
@ -37,7 +37,7 @@ class _UpdateModalState extends State<UpdateModal> {
|
|||
Icon(
|
||||
Icons.system_update_rounded,
|
||||
size: 24,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
color: Theme.of(context).listTileTheme.iconColor,
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
|
|
Loading…
Add table
Reference in a new issue