Enable use_colored_box lint (#117370)
This commit is contained in:
committed by
GitHub
parent
46bb85376b
commit
81bc54be75
@@ -30,10 +30,10 @@ class DividerExample extends StatelessWidget {
|
||||
return Center(
|
||||
child: Column(
|
||||
children: <Widget>[
|
||||
Expanded(
|
||||
child: Container(
|
||||
const Expanded(
|
||||
child: ColoredBox(
|
||||
color: Colors.amber,
|
||||
child: const Center(
|
||||
child: Center(
|
||||
child: Text('Above'),
|
||||
),
|
||||
),
|
||||
@@ -59,7 +59,7 @@ class DividerExample extends StatelessWidget {
|
||||
),
|
||||
),
|
||||
Expanded(
|
||||
child: Container(
|
||||
child: ColoredBox(
|
||||
color: Theme.of(context).colorScheme.primary,
|
||||
child: const Center(
|
||||
child: Text('Below'),
|
||||
|
||||
@@ -42,7 +42,7 @@ class _ReorderableExampleState extends State<ReorderableExample> {
|
||||
buildDefaultDragHandles: false,
|
||||
children: <Widget>[
|
||||
for (int index = 0; index < _items.length; index++)
|
||||
Container(
|
||||
ColoredBox(
|
||||
key: Key('$index'),
|
||||
color: _items[index].isOdd ? oddItemColor : evenItemColor,
|
||||
child: Row(
|
||||
|
||||
Reference in New Issue
Block a user