Add const MaterialStatePropertyAll class. (#104127)
This commit is contained in:
@@ -143,7 +143,7 @@ class ListPage extends StatelessWidget {
|
||||
padding: const EdgeInsets.symmetric(vertical: 4, horizontal: 8),
|
||||
child: OutlinedButton(
|
||||
style: buttonStyle.copyWith(
|
||||
backgroundColor: MaterialStateProperty.all<Color>(
|
||||
backgroundColor: MaterialStatePropertyAll<Color>(
|
||||
Color.lerp(destination.color[100], Colors.white, index / itemCount)!
|
||||
),
|
||||
),
|
||||
|
||||
@@ -101,7 +101,7 @@ class _SaveButtonState extends State<SaveButton> {
|
||||
icon: const Icon(Icons.save),
|
||||
label: Text('$savedValue'),
|
||||
style: ButtonStyle(
|
||||
foregroundColor: MaterialStateProperty.all<Color>(
|
||||
foregroundColor: MaterialStatePropertyAll<Color>(
|
||||
widget.valueNotifier.value ? Colors.red : Colors.green,
|
||||
),
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user