mirror of
https://github.com/JGeek00/adguard-home-manager.git
synced 2025-05-16 23:12:50 +00:00
Fixed most of the warnings
This commit is contained in:
parent
715ca0ab3f
commit
f7c3ba0374
87 changed files with 252 additions and 250 deletions
|
@ -9,14 +9,14 @@ class ThemeModeButton extends StatelessWidget {
|
|||
final bool? disabled;
|
||||
|
||||
const ThemeModeButton({
|
||||
Key? key,
|
||||
super.key,
|
||||
required this.icon,
|
||||
required this.value,
|
||||
required this.selected,
|
||||
required this.label,
|
||||
required this.onChanged,
|
||||
this.disabled
|
||||
}) : super(key: key);
|
||||
});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -32,19 +32,19 @@ class ThemeModeButton extends StatelessWidget {
|
|||
? () => onChanged(value)
|
||||
: null,
|
||||
style: ButtonStyle(
|
||||
elevation: MaterialStateProperty.all(0),
|
||||
shape: MaterialStateProperty.all(
|
||||
elevation: WidgetStateProperty.all(0),
|
||||
shape: WidgetStateProperty.all(
|
||||
RoundedRectangleBorder(
|
||||
borderRadius: BorderRadius.circular(30),
|
||||
)
|
||||
),
|
||||
backgroundColor: MaterialStateProperty.all(
|
||||
backgroundColor: WidgetStateProperty.all(
|
||||
value == selected
|
||||
? disabled == null || disabled == false
|
||||
? Theme.of(context).colorScheme.primary
|
||||
: greyBackgroundColor
|
||||
: disabled == null || disabled == false
|
||||
? Theme.of(context).colorScheme.surfaceVariant
|
||||
? Theme.of(context).colorScheme.surfaceContainerHighest
|
||||
: greyBackgroundColor,
|
||||
)
|
||||
),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue