diff --git a/Code Snapshots/05 Interactivity & Theming/20 Using Theme in Widgets/lib/widgets/expenses_list/expenses_list.dart b/Code Snapshots/05 Interactivity & Theming/20 Using Theme in Widgets/lib/widgets/expenses_list/expenses_list.dart index fda0d2ac..1e41838d 100644 --- a/Code Snapshots/05 Interactivity & Theming/20 Using Theme in Widgets/lib/widgets/expenses_list/expenses_list.dart +++ b/Code Snapshots/05 Interactivity & Theming/20 Using Theme in Widgets/lib/widgets/expenses_list/expenses_list.dart @@ -20,7 +20,7 @@ class ExpensesList extends StatelessWidget { itemBuilder: (ctx, index) => Dismissible( key: ValueKey(expenses[index]), background: Container( - color: Theme.of(context).colorScheme.error.withOpacity(0.75), + color: Theme.of(context).colorScheme.error.withValues(alpha: 0.75), margin: EdgeInsets.symmetric( horizontal: Theme.of(context).cardTheme.margin!.horizontal, ), diff --git a/Code Snapshots/05 Interactivity & Theming/21 Dark Mode/lib/widgets/expenses_list/expenses_list.dart b/Code Snapshots/05 Interactivity & Theming/21 Dark Mode/lib/widgets/expenses_list/expenses_list.dart index fda0d2ac..1e41838d 100644 --- a/Code Snapshots/05 Interactivity & Theming/21 Dark Mode/lib/widgets/expenses_list/expenses_list.dart +++ b/Code Snapshots/05 Interactivity & Theming/21 Dark Mode/lib/widgets/expenses_list/expenses_list.dart @@ -20,7 +20,7 @@ class ExpensesList extends StatelessWidget { itemBuilder: (ctx, index) => Dismissible( key: ValueKey(expenses[index]), background: Container( - color: Theme.of(context).colorScheme.error.withOpacity(0.75), + color: Theme.of(context).colorScheme.error.withValues(alpha: 0.75), margin: EdgeInsets.symmetric( horizontal: Theme.of(context).cardTheme.margin!.horizontal, ), diff --git a/Code Snapshots/05 Interactivity & Theming/22 Adding Alternative Constructor Functions/lib/widgets/expenses_list/expenses_list.dart b/Code Snapshots/05 Interactivity & Theming/22 Adding Alternative Constructor Functions/lib/widgets/expenses_list/expenses_list.dart index fda0d2ac..1e41838d 100644 --- a/Code Snapshots/05 Interactivity & Theming/22 Adding Alternative Constructor Functions/lib/widgets/expenses_list/expenses_list.dart +++ b/Code Snapshots/05 Interactivity & Theming/22 Adding Alternative Constructor Functions/lib/widgets/expenses_list/expenses_list.dart @@ -20,7 +20,7 @@ class ExpensesList extends StatelessWidget { itemBuilder: (ctx, index) => Dismissible( key: ValueKey(expenses[index]), background: Container( - color: Theme.of(context).colorScheme.error.withOpacity(0.75), + color: Theme.of(context).colorScheme.error.withValues(alpha: 0.75), margin: EdgeInsets.symmetric( horizontal: Theme.of(context).cardTheme.margin!.horizontal, ), diff --git a/Code Snapshots/05 Interactivity & Theming/23 Added Chart Widgets/lib/widgets/chart/chart.dart b/Code Snapshots/05 Interactivity & Theming/23 Added Chart Widgets/lib/widgets/chart/chart.dart index d97c89b7..6949c0de 100644 --- a/Code Snapshots/05 Interactivity & Theming/23 Added Chart Widgets/lib/widgets/chart/chart.dart +++ b/Code Snapshots/05 Interactivity & Theming/23 Added Chart Widgets/lib/widgets/chart/chart.dart @@ -45,8 +45,8 @@ class Chart extends StatelessWidget { borderRadius: BorderRadius.circular(8), gradient: LinearGradient( colors: [ - Theme.of(context).colorScheme.primary.withOpacity(0.3), - Theme.of(context).colorScheme.primary.withOpacity(0.0) + Theme.of(context).colorScheme.primary.withValues(alpha: 0.3), + Theme.of(context).colorScheme.primary.withValues(alpha: 0.0) ], begin: Alignment.bottomCenter, end: Alignment.topCenter, @@ -81,7 +81,7 @@ class Chart extends StatelessWidget { : Theme.of(context) .colorScheme .primary - .withOpacity(0.7), + .withValues(alpha: 0.7), ), ), ), diff --git a/Code Snapshots/05 Interactivity & Theming/23 Added Chart Widgets/lib/widgets/chart/chart_bar.dart b/Code Snapshots/05 Interactivity & Theming/23 Added Chart Widgets/lib/widgets/chart/chart_bar.dart index b4c3e5f1..dacc35c4 100644 --- a/Code Snapshots/05 Interactivity & Theming/23 Added Chart Widgets/lib/widgets/chart/chart_bar.dart +++ b/Code Snapshots/05 Interactivity & Theming/23 Added Chart Widgets/lib/widgets/chart/chart_bar.dart @@ -24,7 +24,7 @@ class ChartBar extends StatelessWidget { const BorderRadius.vertical(top: Radius.circular(8)), color: isDarkMode ? Theme.of(context).colorScheme.secondary - : Theme.of(context).colorScheme.primary.withOpacity(0.65), + : Theme.of(context).colorScheme.primary.withValues(alpha: 0.65), ), ), ), diff --git a/Code Snapshots/05 Interactivity & Theming/23 Added Chart Widgets/lib/widgets/expenses_list/expenses_list.dart b/Code Snapshots/05 Interactivity & Theming/23 Added Chart Widgets/lib/widgets/expenses_list/expenses_list.dart index fda0d2ac..1e41838d 100644 --- a/Code Snapshots/05 Interactivity & Theming/23 Added Chart Widgets/lib/widgets/expenses_list/expenses_list.dart +++ b/Code Snapshots/05 Interactivity & Theming/23 Added Chart Widgets/lib/widgets/expenses_list/expenses_list.dart @@ -20,7 +20,7 @@ class ExpensesList extends StatelessWidget { itemBuilder: (ctx, index) => Dismissible( key: ValueKey(expenses[index]), background: Container( - color: Theme.of(context).colorScheme.error.withOpacity(0.75), + color: Theme.of(context).colorScheme.error.withValues(alpha: 0.75), margin: EdgeInsets.symmetric( horizontal: Theme.of(context).cardTheme.margin!.horizontal, ), diff --git a/Code Snapshots/05 Interactivity & Theming/24 Finished/lib/widgets/chart/chart.dart b/Code Snapshots/05 Interactivity & Theming/24 Finished/lib/widgets/chart/chart.dart index 827a9105..d7ebe699 100644 --- a/Code Snapshots/05 Interactivity & Theming/24 Finished/lib/widgets/chart/chart.dart +++ b/Code Snapshots/05 Interactivity & Theming/24 Finished/lib/widgets/chart/chart.dart @@ -45,8 +45,8 @@ class Chart extends StatelessWidget { borderRadius: BorderRadius.circular(8), gradient: LinearGradient( colors: [ - Theme.of(context).colorScheme.primary.withOpacity(0.3), - Theme.of(context).colorScheme.primary.withOpacity(0.0) + Theme.of(context).colorScheme.primary.withValues(alpha: 0.3), + Theme.of(context).colorScheme.primary.withValues(alpha: 0.0) ], begin: Alignment.bottomCenter, end: Alignment.topCenter, @@ -81,7 +81,7 @@ class Chart extends StatelessWidget { : Theme.of(context) .colorScheme .primary - .withOpacity(0.7), + .withValues(alpha: 0.7), ), ), ), diff --git a/Code Snapshots/05 Interactivity & Theming/24 Finished/lib/widgets/chart/chart_bar.dart b/Code Snapshots/05 Interactivity & Theming/24 Finished/lib/widgets/chart/chart_bar.dart index a2e35418..9c93f16c 100644 --- a/Code Snapshots/05 Interactivity & Theming/24 Finished/lib/widgets/chart/chart_bar.dart +++ b/Code Snapshots/05 Interactivity & Theming/24 Finished/lib/widgets/chart/chart_bar.dart @@ -24,7 +24,7 @@ class ChartBar extends StatelessWidget { const BorderRadius.vertical(top: Radius.circular(8)), color: isDarkMode ? Theme.of(context).colorScheme.secondary - : Theme.of(context).colorScheme.primary.withOpacity(0.65), + : Theme.of(context).colorScheme.primary.withValues(alpha: 0.65), ), ), ), diff --git a/Code Snapshots/05 Interactivity & Theming/24 Finished/lib/widgets/expenses_list/expenses_list.dart b/Code Snapshots/05 Interactivity & Theming/24 Finished/lib/widgets/expenses_list/expenses_list.dart index fda0d2ac..1e41838d 100644 --- a/Code Snapshots/05 Interactivity & Theming/24 Finished/lib/widgets/expenses_list/expenses_list.dart +++ b/Code Snapshots/05 Interactivity & Theming/24 Finished/lib/widgets/expenses_list/expenses_list.dart @@ -20,7 +20,7 @@ class ExpensesList extends StatelessWidget { itemBuilder: (ctx, index) => Dismissible( key: ValueKey(expenses[index]), background: Container( - color: Theme.of(context).colorScheme.error.withOpacity(0.75), + color: Theme.of(context).colorScheme.error.withValues(alpha: 0.75), margin: EdgeInsets.symmetric( horizontal: Theme.of(context).cardTheme.margin!.horizontal, ), diff --git a/Code Snapshots/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart.dart b/Code Snapshots/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart.dart index 827a9105..d7ebe699 100644 --- a/Code Snapshots/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart.dart +++ b/Code Snapshots/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart.dart @@ -45,8 +45,8 @@ class Chart extends StatelessWidget { borderRadius: BorderRadius.circular(8), gradient: LinearGradient( colors: [ - Theme.of(context).colorScheme.primary.withOpacity(0.3), - Theme.of(context).colorScheme.primary.withOpacity(0.0) + Theme.of(context).colorScheme.primary.withValues(alpha: 0.3), + Theme.of(context).colorScheme.primary.withValues(alpha: 0.0) ], begin: Alignment.bottomCenter, end: Alignment.topCenter, @@ -81,7 +81,7 @@ class Chart extends StatelessWidget { : Theme.of(context) .colorScheme .primary - .withOpacity(0.7), + .withValues(alpha: 0.7), ), ), ), diff --git a/Code Snapshots/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart_bar.dart b/Code Snapshots/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart_bar.dart index a2e35418..9c93f16c 100644 --- a/Code Snapshots/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart_bar.dart +++ b/Code Snapshots/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart_bar.dart @@ -24,7 +24,7 @@ class ChartBar extends StatelessWidget { const BorderRadius.vertical(top: Radius.circular(8)), color: isDarkMode ? Theme.of(context).colorScheme.secondary - : Theme.of(context).colorScheme.primary.withOpacity(0.65), + : Theme.of(context).colorScheme.primary.withValues(alpha: 0.65), ), ), ), diff --git a/Code Snapshots/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/expenses_list/expenses_list.dart b/Code Snapshots/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/expenses_list/expenses_list.dart index fda0d2ac..1e41838d 100644 --- a/Code Snapshots/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/expenses_list/expenses_list.dart +++ b/Code Snapshots/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/expenses_list/expenses_list.dart @@ -20,7 +20,7 @@ class ExpensesList extends StatelessWidget { itemBuilder: (ctx, index) => Dismissible( key: ValueKey(expenses[index]), background: Container( - color: Theme.of(context).colorScheme.error.withOpacity(0.75), + color: Theme.of(context).colorScheme.error.withValues(alpha: 0.75), margin: EdgeInsets.symmetric( horizontal: Theme.of(context).cardTheme.margin!.horizontal, ), diff --git a/Code Snapshots/06 Responsive & Adaptive/02 Locking Device Orientation/lib/widgets/chart/chart.dart b/Code Snapshots/06 Responsive & Adaptive/02 Locking Device Orientation/lib/widgets/chart/chart.dart index 827a9105..d7ebe699 100644 --- a/Code Snapshots/06 Responsive & Adaptive/02 Locking Device Orientation/lib/widgets/chart/chart.dart +++ b/Code Snapshots/06 Responsive & Adaptive/02 Locking Device Orientation/lib/widgets/chart/chart.dart @@ -45,8 +45,8 @@ class Chart extends StatelessWidget { borderRadius: BorderRadius.circular(8), gradient: LinearGradient( colors: [ - Theme.of(context).colorScheme.primary.withOpacity(0.3), - Theme.of(context).colorScheme.primary.withOpacity(0.0) + Theme.of(context).colorScheme.primary.withValues(alpha: 0.3), + Theme.of(context).colorScheme.primary.withValues(alpha: 0.0) ], begin: Alignment.bottomCenter, end: Alignment.topCenter, @@ -81,7 +81,7 @@ class Chart extends StatelessWidget { : Theme.of(context) .colorScheme .primary - .withOpacity(0.7), + .withValues(alpha: 0.7), ), ), ), diff --git a/Code Snapshots/06 Responsive & Adaptive/02 Locking Device Orientation/lib/widgets/chart/chart_bar.dart b/Code Snapshots/06 Responsive & Adaptive/02 Locking Device Orientation/lib/widgets/chart/chart_bar.dart index a2e35418..9c93f16c 100644 --- a/Code Snapshots/06 Responsive & Adaptive/02 Locking Device Orientation/lib/widgets/chart/chart_bar.dart +++ b/Code Snapshots/06 Responsive & Adaptive/02 Locking Device Orientation/lib/widgets/chart/chart_bar.dart @@ -24,7 +24,7 @@ class ChartBar extends StatelessWidget { const BorderRadius.vertical(top: Radius.circular(8)), color: isDarkMode ? Theme.of(context).colorScheme.secondary - : Theme.of(context).colorScheme.primary.withOpacity(0.65), + : Theme.of(context).colorScheme.primary.withValues(alpha: 0.65), ), ), ), diff --git a/Code Snapshots/06 Responsive & Adaptive/02 Locking Device Orientation/lib/widgets/expenses_list/expenses_list.dart b/Code Snapshots/06 Responsive & Adaptive/02 Locking Device Orientation/lib/widgets/expenses_list/expenses_list.dart index fda0d2ac..1e41838d 100644 --- a/Code Snapshots/06 Responsive & Adaptive/02 Locking Device Orientation/lib/widgets/expenses_list/expenses_list.dart +++ b/Code Snapshots/06 Responsive & Adaptive/02 Locking Device Orientation/lib/widgets/expenses_list/expenses_list.dart @@ -20,7 +20,7 @@ class ExpensesList extends StatelessWidget { itemBuilder: (ctx, index) => Dismissible( key: ValueKey(expenses[index]), background: Container( - color: Theme.of(context).colorScheme.error.withOpacity(0.75), + color: Theme.of(context).colorScheme.error.withValues(alpha: 0.75), margin: EdgeInsets.symmetric( horizontal: Theme.of(context).cardTheme.margin!.horizontal, ), diff --git a/Code Snapshots/06 Responsive & Adaptive/03 Updating the UI Based on Available Space/lib/widgets/chart/chart.dart b/Code Snapshots/06 Responsive & Adaptive/03 Updating the UI Based on Available Space/lib/widgets/chart/chart.dart index 827a9105..d7ebe699 100644 --- a/Code Snapshots/06 Responsive & Adaptive/03 Updating the UI Based on Available Space/lib/widgets/chart/chart.dart +++ b/Code Snapshots/06 Responsive & Adaptive/03 Updating the UI Based on Available Space/lib/widgets/chart/chart.dart @@ -45,8 +45,8 @@ class Chart extends StatelessWidget { borderRadius: BorderRadius.circular(8), gradient: LinearGradient( colors: [ - Theme.of(context).colorScheme.primary.withOpacity(0.3), - Theme.of(context).colorScheme.primary.withOpacity(0.0) + Theme.of(context).colorScheme.primary.withValues(alpha: 0.3), + Theme.of(context).colorScheme.primary.withValues(alpha: 0.0) ], begin: Alignment.bottomCenter, end: Alignment.topCenter, @@ -81,7 +81,7 @@ class Chart extends StatelessWidget { : Theme.of(context) .colorScheme .primary - .withOpacity(0.7), + .withValues(alpha: 0.7), ), ), ), diff --git a/Code Snapshots/06 Responsive & Adaptive/03 Updating the UI Based on Available Space/lib/widgets/chart/chart_bar.dart b/Code Snapshots/06 Responsive & Adaptive/03 Updating the UI Based on Available Space/lib/widgets/chart/chart_bar.dart index a2e35418..9c93f16c 100644 --- a/Code Snapshots/06 Responsive & Adaptive/03 Updating the UI Based on Available Space/lib/widgets/chart/chart_bar.dart +++ b/Code Snapshots/06 Responsive & Adaptive/03 Updating the UI Based on Available Space/lib/widgets/chart/chart_bar.dart @@ -24,7 +24,7 @@ class ChartBar extends StatelessWidget { const BorderRadius.vertical(top: Radius.circular(8)), color: isDarkMode ? Theme.of(context).colorScheme.secondary - : Theme.of(context).colorScheme.primary.withOpacity(0.65), + : Theme.of(context).colorScheme.primary.withValues(alpha: 0.65), ), ), ), diff --git a/Code Snapshots/06 Responsive & Adaptive/03 Updating the UI Based on Available Space/lib/widgets/expenses_list/expenses_list.dart b/Code Snapshots/06 Responsive & Adaptive/03 Updating the UI Based on Available Space/lib/widgets/expenses_list/expenses_list.dart index fda0d2ac..1e41838d 100644 --- a/Code Snapshots/06 Responsive & Adaptive/03 Updating the UI Based on Available Space/lib/widgets/expenses_list/expenses_list.dart +++ b/Code Snapshots/06 Responsive & Adaptive/03 Updating the UI Based on Available Space/lib/widgets/expenses_list/expenses_list.dart @@ -20,7 +20,7 @@ class ExpensesList extends StatelessWidget { itemBuilder: (ctx, index) => Dismissible( key: ValueKey(expenses[index]), background: Container( - color: Theme.of(context).colorScheme.error.withOpacity(0.75), + color: Theme.of(context).colorScheme.error.withValues(alpha: 0.75), margin: EdgeInsets.symmetric( horizontal: Theme.of(context).cardTheme.margin!.horizontal, ), diff --git a/Code Snapshots/06 Responsive & Adaptive/04 Handling Screen Overlays/lib/widgets/chart/chart.dart b/Code Snapshots/06 Responsive & Adaptive/04 Handling Screen Overlays/lib/widgets/chart/chart.dart index 827a9105..d7ebe699 100644 --- a/Code Snapshots/06 Responsive & Adaptive/04 Handling Screen Overlays/lib/widgets/chart/chart.dart +++ b/Code Snapshots/06 Responsive & Adaptive/04 Handling Screen Overlays/lib/widgets/chart/chart.dart @@ -45,8 +45,8 @@ class Chart extends StatelessWidget { borderRadius: BorderRadius.circular(8), gradient: LinearGradient( colors: [ - Theme.of(context).colorScheme.primary.withOpacity(0.3), - Theme.of(context).colorScheme.primary.withOpacity(0.0) + Theme.of(context).colorScheme.primary.withValues(alpha: 0.3), + Theme.of(context).colorScheme.primary.withValues(alpha: 0.0) ], begin: Alignment.bottomCenter, end: Alignment.topCenter, @@ -81,7 +81,7 @@ class Chart extends StatelessWidget { : Theme.of(context) .colorScheme .primary - .withOpacity(0.7), + .withValues(alpha: 0.7), ), ), ), diff --git a/Code Snapshots/06 Responsive & Adaptive/04 Handling Screen Overlays/lib/widgets/chart/chart_bar.dart b/Code Snapshots/06 Responsive & Adaptive/04 Handling Screen Overlays/lib/widgets/chart/chart_bar.dart index a2e35418..9c93f16c 100644 --- a/Code Snapshots/06 Responsive & Adaptive/04 Handling Screen Overlays/lib/widgets/chart/chart_bar.dart +++ b/Code Snapshots/06 Responsive & Adaptive/04 Handling Screen Overlays/lib/widgets/chart/chart_bar.dart @@ -24,7 +24,7 @@ class ChartBar extends StatelessWidget { const BorderRadius.vertical(top: Radius.circular(8)), color: isDarkMode ? Theme.of(context).colorScheme.secondary - : Theme.of(context).colorScheme.primary.withOpacity(0.65), + : Theme.of(context).colorScheme.primary.withValues(alpha: 0.65), ), ), ), diff --git a/Code Snapshots/06 Responsive & Adaptive/04 Handling Screen Overlays/lib/widgets/expenses_list/expenses_list.dart b/Code Snapshots/06 Responsive & Adaptive/04 Handling Screen Overlays/lib/widgets/expenses_list/expenses_list.dart index fda0d2ac..1e41838d 100644 --- a/Code Snapshots/06 Responsive & Adaptive/04 Handling Screen Overlays/lib/widgets/expenses_list/expenses_list.dart +++ b/Code Snapshots/06 Responsive & Adaptive/04 Handling Screen Overlays/lib/widgets/expenses_list/expenses_list.dart @@ -20,7 +20,7 @@ class ExpensesList extends StatelessWidget { itemBuilder: (ctx, index) => Dismissible( key: ValueKey(expenses[index]), background: Container( - color: Theme.of(context).colorScheme.error.withOpacity(0.75), + color: Theme.of(context).colorScheme.error.withValues(alpha: 0.75), margin: EdgeInsets.symmetric( horizontal: Theme.of(context).cardTheme.margin!.horizontal, ), diff --git a/Code Snapshots/06 Responsive & Adaptive/05 SafeArea/lib/widgets/chart/chart.dart b/Code Snapshots/06 Responsive & Adaptive/05 SafeArea/lib/widgets/chart/chart.dart index 827a9105..d7ebe699 100644 --- a/Code Snapshots/06 Responsive & Adaptive/05 SafeArea/lib/widgets/chart/chart.dart +++ b/Code Snapshots/06 Responsive & Adaptive/05 SafeArea/lib/widgets/chart/chart.dart @@ -45,8 +45,8 @@ class Chart extends StatelessWidget { borderRadius: BorderRadius.circular(8), gradient: LinearGradient( colors: [ - Theme.of(context).colorScheme.primary.withOpacity(0.3), - Theme.of(context).colorScheme.primary.withOpacity(0.0) + Theme.of(context).colorScheme.primary.withValues(alpha: 0.3), + Theme.of(context).colorScheme.primary.withValues(alpha: 0.0) ], begin: Alignment.bottomCenter, end: Alignment.topCenter, @@ -81,7 +81,7 @@ class Chart extends StatelessWidget { : Theme.of(context) .colorScheme .primary - .withOpacity(0.7), + .withValues(alpha: 0.7), ), ), ), diff --git a/Code Snapshots/06 Responsive & Adaptive/05 SafeArea/lib/widgets/chart/chart_bar.dart b/Code Snapshots/06 Responsive & Adaptive/05 SafeArea/lib/widgets/chart/chart_bar.dart index a2e35418..9c93f16c 100644 --- a/Code Snapshots/06 Responsive & Adaptive/05 SafeArea/lib/widgets/chart/chart_bar.dart +++ b/Code Snapshots/06 Responsive & Adaptive/05 SafeArea/lib/widgets/chart/chart_bar.dart @@ -24,7 +24,7 @@ class ChartBar extends StatelessWidget { const BorderRadius.vertical(top: Radius.circular(8)), color: isDarkMode ? Theme.of(context).colorScheme.secondary - : Theme.of(context).colorScheme.primary.withOpacity(0.65), + : Theme.of(context).colorScheme.primary.withValues(alpha: 0.65), ), ), ), diff --git a/Code Snapshots/06 Responsive & Adaptive/05 SafeArea/lib/widgets/expenses_list/expenses_list.dart b/Code Snapshots/06 Responsive & Adaptive/05 SafeArea/lib/widgets/expenses_list/expenses_list.dart index fda0d2ac..1e41838d 100644 --- a/Code Snapshots/06 Responsive & Adaptive/05 SafeArea/lib/widgets/expenses_list/expenses_list.dart +++ b/Code Snapshots/06 Responsive & Adaptive/05 SafeArea/lib/widgets/expenses_list/expenses_list.dart @@ -20,7 +20,7 @@ class ExpensesList extends StatelessWidget { itemBuilder: (ctx, index) => Dismissible( key: ValueKey(expenses[index]), background: Container( - color: Theme.of(context).colorScheme.error.withOpacity(0.75), + color: Theme.of(context).colorScheme.error.withValues(alpha: 0.75), margin: EdgeInsets.symmetric( horizontal: Theme.of(context).cardTheme.margin!.horizontal, ), diff --git a/Code Snapshots/06 Responsive & Adaptive/06 LayoutBuilder/lib/widgets/chart/chart.dart b/Code Snapshots/06 Responsive & Adaptive/06 LayoutBuilder/lib/widgets/chart/chart.dart index 827a9105..d7ebe699 100644 --- a/Code Snapshots/06 Responsive & Adaptive/06 LayoutBuilder/lib/widgets/chart/chart.dart +++ b/Code Snapshots/06 Responsive & Adaptive/06 LayoutBuilder/lib/widgets/chart/chart.dart @@ -45,8 +45,8 @@ class Chart extends StatelessWidget { borderRadius: BorderRadius.circular(8), gradient: LinearGradient( colors: [ - Theme.of(context).colorScheme.primary.withOpacity(0.3), - Theme.of(context).colorScheme.primary.withOpacity(0.0) + Theme.of(context).colorScheme.primary.withValues(alpha: 0.3), + Theme.of(context).colorScheme.primary.withValues(alpha: 0.0) ], begin: Alignment.bottomCenter, end: Alignment.topCenter, @@ -81,7 +81,7 @@ class Chart extends StatelessWidget { : Theme.of(context) .colorScheme .primary - .withOpacity(0.7), + .withValues(alpha: 0.7), ), ), ), diff --git a/Code Snapshots/06 Responsive & Adaptive/06 LayoutBuilder/lib/widgets/chart/chart_bar.dart b/Code Snapshots/06 Responsive & Adaptive/06 LayoutBuilder/lib/widgets/chart/chart_bar.dart index a2e35418..9c93f16c 100644 --- a/Code Snapshots/06 Responsive & Adaptive/06 LayoutBuilder/lib/widgets/chart/chart_bar.dart +++ b/Code Snapshots/06 Responsive & Adaptive/06 LayoutBuilder/lib/widgets/chart/chart_bar.dart @@ -24,7 +24,7 @@ class ChartBar extends StatelessWidget { const BorderRadius.vertical(top: Radius.circular(8)), color: isDarkMode ? Theme.of(context).colorScheme.secondary - : Theme.of(context).colorScheme.primary.withOpacity(0.65), + : Theme.of(context).colorScheme.primary.withValues(alpha: 0.65), ), ), ), diff --git a/Code Snapshots/06 Responsive & Adaptive/06 LayoutBuilder/lib/widgets/expenses_list/expenses_list.dart b/Code Snapshots/06 Responsive & Adaptive/06 LayoutBuilder/lib/widgets/expenses_list/expenses_list.dart index fda0d2ac..1e41838d 100644 --- a/Code Snapshots/06 Responsive & Adaptive/06 LayoutBuilder/lib/widgets/expenses_list/expenses_list.dart +++ b/Code Snapshots/06 Responsive & Adaptive/06 LayoutBuilder/lib/widgets/expenses_list/expenses_list.dart @@ -20,7 +20,7 @@ class ExpensesList extends StatelessWidget { itemBuilder: (ctx, index) => Dismissible( key: ValueKey(expenses[index]), background: Container( - color: Theme.of(context).colorScheme.error.withOpacity(0.75), + color: Theme.of(context).colorScheme.error.withValues(alpha: 0.75), margin: EdgeInsets.symmetric( horizontal: Theme.of(context).cardTheme.margin!.horizontal, ), diff --git a/Code Snapshots/06 Responsive & Adaptive/07 Adaptive Apps & Widgets/lib/widgets/chart/chart.dart b/Code Snapshots/06 Responsive & Adaptive/07 Adaptive Apps & Widgets/lib/widgets/chart/chart.dart index 827a9105..d7ebe699 100644 --- a/Code Snapshots/06 Responsive & Adaptive/07 Adaptive Apps & Widgets/lib/widgets/chart/chart.dart +++ b/Code Snapshots/06 Responsive & Adaptive/07 Adaptive Apps & Widgets/lib/widgets/chart/chart.dart @@ -45,8 +45,8 @@ class Chart extends StatelessWidget { borderRadius: BorderRadius.circular(8), gradient: LinearGradient( colors: [ - Theme.of(context).colorScheme.primary.withOpacity(0.3), - Theme.of(context).colorScheme.primary.withOpacity(0.0) + Theme.of(context).colorScheme.primary.withValues(alpha: 0.3), + Theme.of(context).colorScheme.primary.withValues(alpha: 0.0) ], begin: Alignment.bottomCenter, end: Alignment.topCenter, @@ -81,7 +81,7 @@ class Chart extends StatelessWidget { : Theme.of(context) .colorScheme .primary - .withOpacity(0.7), + .withValues(alpha: 0.7), ), ), ), diff --git a/Code Snapshots/06 Responsive & Adaptive/07 Adaptive Apps & Widgets/lib/widgets/chart/chart_bar.dart b/Code Snapshots/06 Responsive & Adaptive/07 Adaptive Apps & Widgets/lib/widgets/chart/chart_bar.dart index a2e35418..9c93f16c 100644 --- a/Code Snapshots/06 Responsive & Adaptive/07 Adaptive Apps & Widgets/lib/widgets/chart/chart_bar.dart +++ b/Code Snapshots/06 Responsive & Adaptive/07 Adaptive Apps & Widgets/lib/widgets/chart/chart_bar.dart @@ -24,7 +24,7 @@ class ChartBar extends StatelessWidget { const BorderRadius.vertical(top: Radius.circular(8)), color: isDarkMode ? Theme.of(context).colorScheme.secondary - : Theme.of(context).colorScheme.primary.withOpacity(0.65), + : Theme.of(context).colorScheme.primary.withValues(alpha: 0.65), ), ), ), diff --git a/Code Snapshots/06 Responsive & Adaptive/07 Adaptive Apps & Widgets/lib/widgets/expenses_list/expenses_list.dart b/Code Snapshots/06 Responsive & Adaptive/07 Adaptive Apps & Widgets/lib/widgets/expenses_list/expenses_list.dart index fda0d2ac..1e41838d 100644 --- a/Code Snapshots/06 Responsive & Adaptive/07 Adaptive Apps & Widgets/lib/widgets/expenses_list/expenses_list.dart +++ b/Code Snapshots/06 Responsive & Adaptive/07 Adaptive Apps & Widgets/lib/widgets/expenses_list/expenses_list.dart @@ -20,7 +20,7 @@ class ExpensesList extends StatelessWidget { itemBuilder: (ctx, index) => Dismissible( key: ValueKey(expenses[index]), background: Container( - color: Theme.of(context).colorScheme.error.withOpacity(0.75), + color: Theme.of(context).colorScheme.error.withValues(alpha: 0.75), margin: EdgeInsets.symmetric( horizontal: Theme.of(context).cardTheme.margin!.horizontal, ), diff --git a/Code Snapshots/08 Navigation/03 Displaying Category Items/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/03 Displaying Category Items/lib/widgets/category_grid_item.dart index 59fa347b..ba0a2e1f 100644 --- a/Code Snapshots/08 Navigation/03 Displaying Category Items/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/03 Displaying Category Items/lib/widgets/category_grid_item.dart @@ -17,8 +17,8 @@ class CategoryGridItem extends StatelessWidget { decoration: BoxDecoration( gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -26,7 +26,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); diff --git a/Code Snapshots/08 Navigation/04 InkWell/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/04 InkWell/lib/widgets/category_grid_item.dart index 6ea952d4..68e758e0 100644 --- a/Code Snapshots/08 Navigation/04 InkWell/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/04 InkWell/lib/widgets/category_grid_item.dart @@ -22,8 +22,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -31,7 +31,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/05 Loading Meals Data/lib/screens/meals.dart b/Code Snapshots/08 Navigation/05 Loading Meals Data/lib/screens/meals.dart index a1f52f75..37e93228 100644 --- a/Code Snapshots/08 Navigation/05 Loading Meals Data/lib/screens/meals.dart +++ b/Code Snapshots/08 Navigation/05 Loading Meals Data/lib/screens/meals.dart @@ -21,14 +21,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/08 Navigation/05 Loading Meals Data/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/05 Loading Meals Data/lib/widgets/category_grid_item.dart index 6ea952d4..68e758e0 100644 --- a/Code Snapshots/08 Navigation/05 Loading Meals Data/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/05 Loading Meals Data/lib/widgets/category_grid_item.dart @@ -22,8 +22,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -31,7 +31,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/06 Adding Cross-Screen Navigation/lib/screens/meals.dart b/Code Snapshots/08 Navigation/06 Adding Cross-Screen Navigation/lib/screens/meals.dart index a1f52f75..37e93228 100644 --- a/Code Snapshots/08 Navigation/06 Adding Cross-Screen Navigation/lib/screens/meals.dart +++ b/Code Snapshots/08 Navigation/06 Adding Cross-Screen Navigation/lib/screens/meals.dart @@ -21,14 +21,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/08 Navigation/06 Adding Cross-Screen Navigation/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/06 Adding Cross-Screen Navigation/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/08 Navigation/06 Adding Cross-Screen Navigation/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/06 Adding Cross-Screen Navigation/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/07 Passing Data to Routes/lib/screens/meals.dart b/Code Snapshots/08 Navigation/07 Passing Data to Routes/lib/screens/meals.dart index a1f52f75..37e93228 100644 --- a/Code Snapshots/08 Navigation/07 Passing Data to Routes/lib/screens/meals.dart +++ b/Code Snapshots/08 Navigation/07 Passing Data to Routes/lib/screens/meals.dart @@ -21,14 +21,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/08 Navigation/07 Passing Data to Routes/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/07 Passing Data to Routes/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/08 Navigation/07 Passing Data to Routes/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/07 Passing Data to Routes/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/08 Added MealItems/lib/screens/meals.dart b/Code Snapshots/08 Navigation/08 Added MealItems/lib/screens/meals.dart index 0ead03a9..a4e4dbb3 100644 --- a/Code Snapshots/08 Navigation/08 Added MealItems/lib/screens/meals.dart +++ b/Code Snapshots/08 Navigation/08 Added MealItems/lib/screens/meals.dart @@ -22,14 +22,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/08 Navigation/08 Added MealItems/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/08 Added MealItems/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/08 Navigation/08 Added MealItems/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/08 Added MealItems/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/09 Navigating to MealDetailScreen/lib/screens/meals.dart b/Code Snapshots/08 Navigation/09 Navigating to MealDetailScreen/lib/screens/meals.dart index 8de64705..a474c285 100644 --- a/Code Snapshots/08 Navigation/09 Navigating to MealDetailScreen/lib/screens/meals.dart +++ b/Code Snapshots/08 Navigation/09 Navigating to MealDetailScreen/lib/screens/meals.dart @@ -33,14 +33,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/08 Navigation/09 Navigating to MealDetailScreen/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/09 Navigating to MealDetailScreen/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/08 Navigation/09 Navigating to MealDetailScreen/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/09 Navigating to MealDetailScreen/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/10 Updating the MealDetailsScreen/lib/screens/meal_details.dart b/Code Snapshots/08 Navigation/10 Updating the MealDetailsScreen/lib/screens/meal_details.dart index 6dc6d2d7..6f046018 100644 --- a/Code Snapshots/08 Navigation/10 Updating the MealDetailsScreen/lib/screens/meal_details.dart +++ b/Code Snapshots/08 Navigation/10 Updating the MealDetailsScreen/lib/screens/meal_details.dart @@ -38,7 +38,7 @@ class MealDetailsScreen extends StatelessWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -60,7 +60,7 @@ class MealDetailsScreen extends StatelessWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/10 Updating the MealDetailsScreen/lib/screens/meals.dart b/Code Snapshots/08 Navigation/10 Updating the MealDetailsScreen/lib/screens/meals.dart index 8de64705..a474c285 100644 --- a/Code Snapshots/08 Navigation/10 Updating the MealDetailsScreen/lib/screens/meals.dart +++ b/Code Snapshots/08 Navigation/10 Updating the MealDetailsScreen/lib/screens/meals.dart @@ -33,14 +33,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/08 Navigation/10 Updating the MealDetailsScreen/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/10 Updating the MealDetailsScreen/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/08 Navigation/10 Updating the MealDetailsScreen/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/10 Updating the MealDetailsScreen/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/11 Tab Navigation/lib/screens/meal_details.dart b/Code Snapshots/08 Navigation/11 Tab Navigation/lib/screens/meal_details.dart index 6dc6d2d7..6f046018 100644 --- a/Code Snapshots/08 Navigation/11 Tab Navigation/lib/screens/meal_details.dart +++ b/Code Snapshots/08 Navigation/11 Tab Navigation/lib/screens/meal_details.dart @@ -38,7 +38,7 @@ class MealDetailsScreen extends StatelessWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -60,7 +60,7 @@ class MealDetailsScreen extends StatelessWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/11 Tab Navigation/lib/screens/meals.dart b/Code Snapshots/08 Navigation/11 Tab Navigation/lib/screens/meals.dart index 73287bfc..3a2664c6 100644 --- a/Code Snapshots/08 Navigation/11 Tab Navigation/lib/screens/meals.dart +++ b/Code Snapshots/08 Navigation/11 Tab Navigation/lib/screens/meals.dart @@ -33,14 +33,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/08 Navigation/11 Tab Navigation/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/11 Tab Navigation/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/08 Navigation/11 Tab Navigation/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/11 Tab Navigation/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/12 Passing Functions Through Widget Layers/lib/screens/meal_details.dart b/Code Snapshots/08 Navigation/12 Passing Functions Through Widget Layers/lib/screens/meal_details.dart index 426c322a..95690891 100644 --- a/Code Snapshots/08 Navigation/12 Passing Functions Through Widget Layers/lib/screens/meal_details.dart +++ b/Code Snapshots/08 Navigation/12 Passing Functions Through Widget Layers/lib/screens/meal_details.dart @@ -45,7 +45,7 @@ class MealDetailsScreen extends StatelessWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -67,7 +67,7 @@ class MealDetailsScreen extends StatelessWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/12 Passing Functions Through Widget Layers/lib/screens/meals.dart b/Code Snapshots/08 Navigation/12 Passing Functions Through Widget Layers/lib/screens/meals.dart index 884dfbc9..1c924cd6 100644 --- a/Code Snapshots/08 Navigation/12 Passing Functions Through Widget Layers/lib/screens/meals.dart +++ b/Code Snapshots/08 Navigation/12 Passing Functions Through Widget Layers/lib/screens/meals.dart @@ -36,14 +36,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/08 Navigation/12 Passing Functions Through Widget Layers/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/12 Passing Functions Through Widget Layers/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/08 Navigation/12 Passing Functions Through Widget Layers/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/12 Passing Functions Through Widget Layers/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/13 Managing App-wide State/lib/screens/meal_details.dart b/Code Snapshots/08 Navigation/13 Managing App-wide State/lib/screens/meal_details.dart index 426c322a..95690891 100644 --- a/Code Snapshots/08 Navigation/13 Managing App-wide State/lib/screens/meal_details.dart +++ b/Code Snapshots/08 Navigation/13 Managing App-wide State/lib/screens/meal_details.dart @@ -45,7 +45,7 @@ class MealDetailsScreen extends StatelessWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -67,7 +67,7 @@ class MealDetailsScreen extends StatelessWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/13 Managing App-wide State/lib/screens/meals.dart b/Code Snapshots/08 Navigation/13 Managing App-wide State/lib/screens/meals.dart index 884dfbc9..1c924cd6 100644 --- a/Code Snapshots/08 Navigation/13 Managing App-wide State/lib/screens/meals.dart +++ b/Code Snapshots/08 Navigation/13 Managing App-wide State/lib/screens/meals.dart @@ -36,14 +36,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/08 Navigation/13 Managing App-wide State/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/13 Managing App-wide State/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/08 Navigation/13 Managing App-wide State/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/13 Managing App-wide State/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/14 Drawer/lib/screens/meal_details.dart b/Code Snapshots/08 Navigation/14 Drawer/lib/screens/meal_details.dart index 426c322a..95690891 100644 --- a/Code Snapshots/08 Navigation/14 Drawer/lib/screens/meal_details.dart +++ b/Code Snapshots/08 Navigation/14 Drawer/lib/screens/meal_details.dart @@ -45,7 +45,7 @@ class MealDetailsScreen extends StatelessWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -67,7 +67,7 @@ class MealDetailsScreen extends StatelessWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/14 Drawer/lib/screens/meals.dart b/Code Snapshots/08 Navigation/14 Drawer/lib/screens/meals.dart index 884dfbc9..1c924cd6 100644 --- a/Code Snapshots/08 Navigation/14 Drawer/lib/screens/meals.dart +++ b/Code Snapshots/08 Navigation/14 Drawer/lib/screens/meals.dart @@ -36,14 +36,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/08 Navigation/14 Drawer/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/14 Drawer/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/08 Navigation/14 Drawer/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/14 Drawer/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/14 Drawer/lib/widgets/main_drawer.dart b/Code Snapshots/08 Navigation/14 Drawer/lib/widgets/main_drawer.dart index a23f9309..0936854e 100644 --- a/Code Snapshots/08 Navigation/14 Drawer/lib/widgets/main_drawer.dart +++ b/Code Snapshots/08 Navigation/14 Drawer/lib/widgets/main_drawer.dart @@ -17,7 +17,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -44,12 +44,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -59,12 +59,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/08 Navigation/15 Replacing Screens/lib/screens/filters.dart b/Code Snapshots/08 Navigation/15 Replacing Screens/lib/screens/filters.dart index b2cabdb6..df64f118 100644 --- a/Code Snapshots/08 Navigation/15 Replacing Screens/lib/screens/filters.dart +++ b/Code Snapshots/08 Navigation/15 Replacing Screens/lib/screens/filters.dart @@ -44,13 +44,13 @@ class _FiltersScreenState extends State { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/08 Navigation/15 Replacing Screens/lib/screens/meal_details.dart b/Code Snapshots/08 Navigation/15 Replacing Screens/lib/screens/meal_details.dart index 426c322a..95690891 100644 --- a/Code Snapshots/08 Navigation/15 Replacing Screens/lib/screens/meal_details.dart +++ b/Code Snapshots/08 Navigation/15 Replacing Screens/lib/screens/meal_details.dart @@ -45,7 +45,7 @@ class MealDetailsScreen extends StatelessWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -67,7 +67,7 @@ class MealDetailsScreen extends StatelessWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/15 Replacing Screens/lib/screens/meals.dart b/Code Snapshots/08 Navigation/15 Replacing Screens/lib/screens/meals.dart index 884dfbc9..1c924cd6 100644 --- a/Code Snapshots/08 Navigation/15 Replacing Screens/lib/screens/meals.dart +++ b/Code Snapshots/08 Navigation/15 Replacing Screens/lib/screens/meals.dart @@ -36,14 +36,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/08 Navigation/15 Replacing Screens/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/15 Replacing Screens/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/08 Navigation/15 Replacing Screens/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/15 Replacing Screens/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/15 Replacing Screens/lib/widgets/main_drawer.dart b/Code Snapshots/08 Navigation/15 Replacing Screens/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/08 Navigation/15 Replacing Screens/lib/widgets/main_drawer.dart +++ b/Code Snapshots/08 Navigation/15 Replacing Screens/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/08 Navigation/16 Filters Screen/lib/screens/filters.dart b/Code Snapshots/08 Navigation/16 Filters Screen/lib/screens/filters.dart index 1327e410..e0b33062 100644 --- a/Code Snapshots/08 Navigation/16 Filters Screen/lib/screens/filters.dart +++ b/Code Snapshots/08 Navigation/16 Filters Screen/lib/screens/filters.dart @@ -48,13 +48,13 @@ class _FiltersScreenState extends State { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -70,13 +70,13 @@ class _FiltersScreenState extends State { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -92,13 +92,13 @@ class _FiltersScreenState extends State { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -114,13 +114,13 @@ class _FiltersScreenState extends State { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/08 Navigation/16 Filters Screen/lib/screens/meal_details.dart b/Code Snapshots/08 Navigation/16 Filters Screen/lib/screens/meal_details.dart index 426c322a..95690891 100644 --- a/Code Snapshots/08 Navigation/16 Filters Screen/lib/screens/meal_details.dart +++ b/Code Snapshots/08 Navigation/16 Filters Screen/lib/screens/meal_details.dart @@ -45,7 +45,7 @@ class MealDetailsScreen extends StatelessWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -67,7 +67,7 @@ class MealDetailsScreen extends StatelessWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/16 Filters Screen/lib/screens/meals.dart b/Code Snapshots/08 Navigation/16 Filters Screen/lib/screens/meals.dart index 884dfbc9..1c924cd6 100644 --- a/Code Snapshots/08 Navigation/16 Filters Screen/lib/screens/meals.dart +++ b/Code Snapshots/08 Navigation/16 Filters Screen/lib/screens/meals.dart @@ -36,14 +36,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/08 Navigation/16 Filters Screen/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/16 Filters Screen/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/08 Navigation/16 Filters Screen/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/16 Filters Screen/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/16 Filters Screen/lib/widgets/main_drawer.dart b/Code Snapshots/08 Navigation/16 Filters Screen/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/08 Navigation/16 Filters Screen/lib/widgets/main_drawer.dart +++ b/Code Snapshots/08 Navigation/16 Filters Screen/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/08 Navigation/17 Finished/lib/screens/filters.dart b/Code Snapshots/08 Navigation/17 Finished/lib/screens/filters.dart index b87e8700..2bcc1ab3 100644 --- a/Code Snapshots/08 Navigation/17 Finished/lib/screens/filters.dart +++ b/Code Snapshots/08 Navigation/17 Finished/lib/screens/filters.dart @@ -76,13 +76,13 @@ class _FiltersScreenState extends State { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -98,13 +98,13 @@ class _FiltersScreenState extends State { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -120,13 +120,13 @@ class _FiltersScreenState extends State { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -142,13 +142,13 @@ class _FiltersScreenState extends State { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/08 Navigation/17 Finished/lib/screens/meal_details.dart b/Code Snapshots/08 Navigation/17 Finished/lib/screens/meal_details.dart index 426c322a..95690891 100644 --- a/Code Snapshots/08 Navigation/17 Finished/lib/screens/meal_details.dart +++ b/Code Snapshots/08 Navigation/17 Finished/lib/screens/meal_details.dart @@ -45,7 +45,7 @@ class MealDetailsScreen extends StatelessWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -67,7 +67,7 @@ class MealDetailsScreen extends StatelessWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/17 Finished/lib/screens/meals.dart b/Code Snapshots/08 Navigation/17 Finished/lib/screens/meals.dart index 884dfbc9..1c924cd6 100644 --- a/Code Snapshots/08 Navigation/17 Finished/lib/screens/meals.dart +++ b/Code Snapshots/08 Navigation/17 Finished/lib/screens/meals.dart @@ -36,14 +36,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/08 Navigation/17 Finished/lib/widgets/category_grid_item.dart b/Code Snapshots/08 Navigation/17 Finished/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/08 Navigation/17 Finished/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/08 Navigation/17 Finished/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/08 Navigation/17 Finished/lib/widgets/main_drawer.dart b/Code Snapshots/08 Navigation/17 Finished/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/08 Navigation/17 Finished/lib/widgets/main_drawer.dart +++ b/Code Snapshots/08 Navigation/17 Finished/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/09 State Management/01 Starting Setup/lib/screens/filters.dart b/Code Snapshots/09 State Management/01 Starting Setup/lib/screens/filters.dart index b87e8700..2bcc1ab3 100644 --- a/Code Snapshots/09 State Management/01 Starting Setup/lib/screens/filters.dart +++ b/Code Snapshots/09 State Management/01 Starting Setup/lib/screens/filters.dart @@ -76,13 +76,13 @@ class _FiltersScreenState extends State { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -98,13 +98,13 @@ class _FiltersScreenState extends State { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -120,13 +120,13 @@ class _FiltersScreenState extends State { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -142,13 +142,13 @@ class _FiltersScreenState extends State { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/09 State Management/01 Starting Setup/lib/screens/meal_details.dart b/Code Snapshots/09 State Management/01 Starting Setup/lib/screens/meal_details.dart index 426c322a..95690891 100644 --- a/Code Snapshots/09 State Management/01 Starting Setup/lib/screens/meal_details.dart +++ b/Code Snapshots/09 State Management/01 Starting Setup/lib/screens/meal_details.dart @@ -45,7 +45,7 @@ class MealDetailsScreen extends StatelessWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -67,7 +67,7 @@ class MealDetailsScreen extends StatelessWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/09 State Management/01 Starting Setup/lib/screens/meals.dart b/Code Snapshots/09 State Management/01 Starting Setup/lib/screens/meals.dart index 884dfbc9..1c924cd6 100644 --- a/Code Snapshots/09 State Management/01 Starting Setup/lib/screens/meals.dart +++ b/Code Snapshots/09 State Management/01 Starting Setup/lib/screens/meals.dart @@ -36,14 +36,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/09 State Management/01 Starting Setup/lib/widgets/category_grid_item.dart b/Code Snapshots/09 State Management/01 Starting Setup/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/09 State Management/01 Starting Setup/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/09 State Management/01 Starting Setup/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/09 State Management/01 Starting Setup/lib/widgets/main_drawer.dart b/Code Snapshots/09 State Management/01 Starting Setup/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/09 State Management/01 Starting Setup/lib/widgets/main_drawer.dart +++ b/Code Snapshots/09 State Management/01 Starting Setup/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/09 State Management/02 Using a Provider/lib/screens/filters.dart b/Code Snapshots/09 State Management/02 Using a Provider/lib/screens/filters.dart index b87e8700..2bcc1ab3 100644 --- a/Code Snapshots/09 State Management/02 Using a Provider/lib/screens/filters.dart +++ b/Code Snapshots/09 State Management/02 Using a Provider/lib/screens/filters.dart @@ -76,13 +76,13 @@ class _FiltersScreenState extends State { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -98,13 +98,13 @@ class _FiltersScreenState extends State { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -120,13 +120,13 @@ class _FiltersScreenState extends State { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -142,13 +142,13 @@ class _FiltersScreenState extends State { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/09 State Management/02 Using a Provider/lib/screens/meal_details.dart b/Code Snapshots/09 State Management/02 Using a Provider/lib/screens/meal_details.dart index 426c322a..95690891 100644 --- a/Code Snapshots/09 State Management/02 Using a Provider/lib/screens/meal_details.dart +++ b/Code Snapshots/09 State Management/02 Using a Provider/lib/screens/meal_details.dart @@ -45,7 +45,7 @@ class MealDetailsScreen extends StatelessWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -67,7 +67,7 @@ class MealDetailsScreen extends StatelessWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/09 State Management/02 Using a Provider/lib/screens/meals.dart b/Code Snapshots/09 State Management/02 Using a Provider/lib/screens/meals.dart index 884dfbc9..1c924cd6 100644 --- a/Code Snapshots/09 State Management/02 Using a Provider/lib/screens/meals.dart +++ b/Code Snapshots/09 State Management/02 Using a Provider/lib/screens/meals.dart @@ -36,14 +36,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/09 State Management/02 Using a Provider/lib/widgets/category_grid_item.dart b/Code Snapshots/09 State Management/02 Using a Provider/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/09 State Management/02 Using a Provider/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/09 State Management/02 Using a Provider/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/09 State Management/02 Using a Provider/lib/widgets/main_drawer.dart b/Code Snapshots/09 State Management/02 Using a Provider/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/09 State Management/02 Using a Provider/lib/widgets/main_drawer.dart +++ b/Code Snapshots/09 State Management/02 Using a Provider/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/screens/filters.dart b/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/screens/filters.dart index b87e8700..2bcc1ab3 100644 --- a/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/screens/filters.dart +++ b/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/screens/filters.dart @@ -76,13 +76,13 @@ class _FiltersScreenState extends State { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -98,13 +98,13 @@ class _FiltersScreenState extends State { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -120,13 +120,13 @@ class _FiltersScreenState extends State { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -142,13 +142,13 @@ class _FiltersScreenState extends State { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/screens/meal_details.dart b/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/screens/meal_details.dart index 9a33f6c9..4e31ba94 100644 --- a/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/screens/meal_details.dart +++ b/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/screens/meal_details.dart @@ -54,7 +54,7 @@ class MealDetailsScreen extends ConsumerWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -76,7 +76,7 @@ class MealDetailsScreen extends ConsumerWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/screens/meals.dart b/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/screens/meals.dart index 73287bfc..3a2664c6 100644 --- a/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/screens/meals.dart +++ b/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/screens/meals.dart @@ -33,14 +33,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/widgets/category_grid_item.dart b/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/widgets/main_drawer.dart b/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/widgets/main_drawer.dart +++ b/Code Snapshots/09 State Management/03 Triggering a Notifier Method/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/screens/filters.dart b/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/screens/filters.dart index d96af7b0..d66600a4 100644 --- a/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/screens/filters.dart +++ b/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/screens/filters.dart @@ -71,13 +71,13 @@ class _FiltersScreenState extends ConsumerState { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -93,13 +93,13 @@ class _FiltersScreenState extends ConsumerState { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -115,13 +115,13 @@ class _FiltersScreenState extends ConsumerState { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -137,13 +137,13 @@ class _FiltersScreenState extends ConsumerState { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/screens/meal_details.dart b/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/screens/meal_details.dart index 9a33f6c9..4e31ba94 100644 --- a/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/screens/meal_details.dart +++ b/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/screens/meal_details.dart @@ -54,7 +54,7 @@ class MealDetailsScreen extends ConsumerWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -76,7 +76,7 @@ class MealDetailsScreen extends ConsumerWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/screens/meals.dart b/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/screens/meals.dart index 73287bfc..3a2664c6 100644 --- a/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/screens/meals.dart +++ b/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/screens/meals.dart @@ -33,14 +33,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/widgets/category_grid_item.dart b/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/widgets/main_drawer.dart b/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/widgets/main_drawer.dart +++ b/Code Snapshots/09 State Management/04 Combining Local & Provider State/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/screens/filters.dart b/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/screens/filters.dart index 27b19e18..619a17e1 100644 --- a/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/screens/filters.dart +++ b/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/screens/filters.dart @@ -28,13 +28,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -50,13 +50,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -72,13 +72,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -94,13 +94,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/screens/meal_details.dart b/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/screens/meal_details.dart index 9a33f6c9..4e31ba94 100644 --- a/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/screens/meal_details.dart +++ b/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/screens/meal_details.dart @@ -54,7 +54,7 @@ class MealDetailsScreen extends ConsumerWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -76,7 +76,7 @@ class MealDetailsScreen extends ConsumerWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/screens/meals.dart b/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/screens/meals.dart index 73287bfc..3a2664c6 100644 --- a/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/screens/meals.dart +++ b/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/screens/meals.dart @@ -33,14 +33,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/widgets/category_grid_item.dart b/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/widgets/main_drawer.dart b/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/widgets/main_drawer.dart +++ b/Code Snapshots/09 State Management/05 Outsourcing State to a Provider/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/screens/filters.dart b/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/screens/filters.dart index 27b19e18..619a17e1 100644 --- a/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/screens/filters.dart +++ b/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/screens/filters.dart @@ -28,13 +28,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -50,13 +50,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -72,13 +72,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -94,13 +94,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/screens/meal_details.dart b/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/screens/meal_details.dart index 9a33f6c9..4e31ba94 100644 --- a/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/screens/meal_details.dart +++ b/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/screens/meal_details.dart @@ -54,7 +54,7 @@ class MealDetailsScreen extends ConsumerWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -76,7 +76,7 @@ class MealDetailsScreen extends ConsumerWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/screens/meals.dart b/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/screens/meals.dart index 73287bfc..3a2664c6 100644 --- a/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/screens/meals.dart +++ b/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/screens/meals.dart @@ -33,14 +33,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/widgets/category_grid_item.dart b/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/widgets/main_drawer.dart b/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/widgets/main_drawer.dart +++ b/Code Snapshots/09 State Management/06 Connecting Multiple Providers/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/09 State Management/07 Finished/lib/screens/filters.dart b/Code Snapshots/09 State Management/07 Finished/lib/screens/filters.dart index 27b19e18..619a17e1 100644 --- a/Code Snapshots/09 State Management/07 Finished/lib/screens/filters.dart +++ b/Code Snapshots/09 State Management/07 Finished/lib/screens/filters.dart @@ -28,13 +28,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -50,13 +50,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -72,13 +72,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -94,13 +94,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/09 State Management/07 Finished/lib/screens/meal_details.dart b/Code Snapshots/09 State Management/07 Finished/lib/screens/meal_details.dart index 2910480f..e0b12662 100644 --- a/Code Snapshots/09 State Management/07 Finished/lib/screens/meal_details.dart +++ b/Code Snapshots/09 State Management/07 Finished/lib/screens/meal_details.dart @@ -58,7 +58,7 @@ class MealDetailsScreen extends ConsumerWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -80,7 +80,7 @@ class MealDetailsScreen extends ConsumerWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/09 State Management/07 Finished/lib/screens/meals.dart b/Code Snapshots/09 State Management/07 Finished/lib/screens/meals.dart index 73287bfc..3a2664c6 100644 --- a/Code Snapshots/09 State Management/07 Finished/lib/screens/meals.dart +++ b/Code Snapshots/09 State Management/07 Finished/lib/screens/meals.dart @@ -33,14 +33,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/09 State Management/07 Finished/lib/widgets/category_grid_item.dart b/Code Snapshots/09 State Management/07 Finished/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/09 State Management/07 Finished/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/09 State Management/07 Finished/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/09 State Management/07 Finished/lib/widgets/main_drawer.dart b/Code Snapshots/09 State Management/07 Finished/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/09 State Management/07 Finished/lib/widgets/main_drawer.dart +++ b/Code Snapshots/09 State Management/07 Finished/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/10 Animations/01 Starting Setup/lib/screens/filters.dart b/Code Snapshots/10 Animations/01 Starting Setup/lib/screens/filters.dart index 27b19e18..619a17e1 100644 --- a/Code Snapshots/10 Animations/01 Starting Setup/lib/screens/filters.dart +++ b/Code Snapshots/10 Animations/01 Starting Setup/lib/screens/filters.dart @@ -28,13 +28,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -50,13 +50,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -72,13 +72,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -94,13 +94,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/10 Animations/01 Starting Setup/lib/screens/meal_details.dart b/Code Snapshots/10 Animations/01 Starting Setup/lib/screens/meal_details.dart index 2910480f..e0b12662 100644 --- a/Code Snapshots/10 Animations/01 Starting Setup/lib/screens/meal_details.dart +++ b/Code Snapshots/10 Animations/01 Starting Setup/lib/screens/meal_details.dart @@ -58,7 +58,7 @@ class MealDetailsScreen extends ConsumerWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -80,7 +80,7 @@ class MealDetailsScreen extends ConsumerWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/10 Animations/01 Starting Setup/lib/screens/meals.dart b/Code Snapshots/10 Animations/01 Starting Setup/lib/screens/meals.dart index 73287bfc..3a2664c6 100644 --- a/Code Snapshots/10 Animations/01 Starting Setup/lib/screens/meals.dart +++ b/Code Snapshots/10 Animations/01 Starting Setup/lib/screens/meals.dart @@ -33,14 +33,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/10 Animations/01 Starting Setup/lib/widgets/category_grid_item.dart b/Code Snapshots/10 Animations/01 Starting Setup/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/10 Animations/01 Starting Setup/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/10 Animations/01 Starting Setup/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/10 Animations/01 Starting Setup/lib/widgets/main_drawer.dart b/Code Snapshots/10 Animations/01 Starting Setup/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/10 Animations/01 Starting Setup/lib/widgets/main_drawer.dart +++ b/Code Snapshots/10 Animations/01 Starting Setup/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/10 Animations/02 First explicit animation/lib/screens/filters.dart b/Code Snapshots/10 Animations/02 First explicit animation/lib/screens/filters.dart index 27b19e18..619a17e1 100644 --- a/Code Snapshots/10 Animations/02 First explicit animation/lib/screens/filters.dart +++ b/Code Snapshots/10 Animations/02 First explicit animation/lib/screens/filters.dart @@ -28,13 +28,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -50,13 +50,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -72,13 +72,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -94,13 +94,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/10 Animations/02 First explicit animation/lib/screens/meal_details.dart b/Code Snapshots/10 Animations/02 First explicit animation/lib/screens/meal_details.dart index 2910480f..e0b12662 100644 --- a/Code Snapshots/10 Animations/02 First explicit animation/lib/screens/meal_details.dart +++ b/Code Snapshots/10 Animations/02 First explicit animation/lib/screens/meal_details.dart @@ -58,7 +58,7 @@ class MealDetailsScreen extends ConsumerWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -80,7 +80,7 @@ class MealDetailsScreen extends ConsumerWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/10 Animations/02 First explicit animation/lib/screens/meals.dart b/Code Snapshots/10 Animations/02 First explicit animation/lib/screens/meals.dart index 73287bfc..3a2664c6 100644 --- a/Code Snapshots/10 Animations/02 First explicit animation/lib/screens/meals.dart +++ b/Code Snapshots/10 Animations/02 First explicit animation/lib/screens/meals.dart @@ -33,14 +33,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/10 Animations/02 First explicit animation/lib/widgets/category_grid_item.dart b/Code Snapshots/10 Animations/02 First explicit animation/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/10 Animations/02 First explicit animation/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/10 Animations/02 First explicit animation/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/10 Animations/02 First explicit animation/lib/widgets/main_drawer.dart b/Code Snapshots/10 Animations/02 First explicit animation/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/10 Animations/02 First explicit animation/lib/widgets/main_drawer.dart +++ b/Code Snapshots/10 Animations/02 First explicit animation/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/10 Animations/03 finished explicit/lib/screens/filters.dart b/Code Snapshots/10 Animations/03 finished explicit/lib/screens/filters.dart index 27b19e18..619a17e1 100644 --- a/Code Snapshots/10 Animations/03 finished explicit/lib/screens/filters.dart +++ b/Code Snapshots/10 Animations/03 finished explicit/lib/screens/filters.dart @@ -28,13 +28,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -50,13 +50,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -72,13 +72,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -94,13 +94,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/10 Animations/03 finished explicit/lib/screens/meal_details.dart b/Code Snapshots/10 Animations/03 finished explicit/lib/screens/meal_details.dart index 2910480f..e0b12662 100644 --- a/Code Snapshots/10 Animations/03 finished explicit/lib/screens/meal_details.dart +++ b/Code Snapshots/10 Animations/03 finished explicit/lib/screens/meal_details.dart @@ -58,7 +58,7 @@ class MealDetailsScreen extends ConsumerWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -80,7 +80,7 @@ class MealDetailsScreen extends ConsumerWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/10 Animations/03 finished explicit/lib/screens/meals.dart b/Code Snapshots/10 Animations/03 finished explicit/lib/screens/meals.dart index 73287bfc..3a2664c6 100644 --- a/Code Snapshots/10 Animations/03 finished explicit/lib/screens/meals.dart +++ b/Code Snapshots/10 Animations/03 finished explicit/lib/screens/meals.dart @@ -33,14 +33,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/10 Animations/03 finished explicit/lib/widgets/category_grid_item.dart b/Code Snapshots/10 Animations/03 finished explicit/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/10 Animations/03 finished explicit/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/10 Animations/03 finished explicit/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/10 Animations/03 finished explicit/lib/widgets/main_drawer.dart b/Code Snapshots/10 Animations/03 finished explicit/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/10 Animations/03 finished explicit/lib/widgets/main_drawer.dart +++ b/Code Snapshots/10 Animations/03 finished explicit/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/10 Animations/04 implicit/lib/screens/filters.dart b/Code Snapshots/10 Animations/04 implicit/lib/screens/filters.dart index 27b19e18..619a17e1 100644 --- a/Code Snapshots/10 Animations/04 implicit/lib/screens/filters.dart +++ b/Code Snapshots/10 Animations/04 implicit/lib/screens/filters.dart @@ -28,13 +28,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -50,13 +50,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -72,13 +72,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -94,13 +94,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/10 Animations/04 implicit/lib/screens/meal_details.dart b/Code Snapshots/10 Animations/04 implicit/lib/screens/meal_details.dart index 5a3dfc41..3bc14e6d 100644 --- a/Code Snapshots/10 Animations/04 implicit/lib/screens/meal_details.dart +++ b/Code Snapshots/10 Animations/04 implicit/lib/screens/meal_details.dart @@ -70,7 +70,7 @@ class MealDetailsScreen extends ConsumerWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -92,7 +92,7 @@ class MealDetailsScreen extends ConsumerWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/10 Animations/04 implicit/lib/screens/meals.dart b/Code Snapshots/10 Animations/04 implicit/lib/screens/meals.dart index 73287bfc..3a2664c6 100644 --- a/Code Snapshots/10 Animations/04 implicit/lib/screens/meals.dart +++ b/Code Snapshots/10 Animations/04 implicit/lib/screens/meals.dart @@ -33,14 +33,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/10 Animations/04 implicit/lib/widgets/category_grid_item.dart b/Code Snapshots/10 Animations/04 implicit/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/10 Animations/04 implicit/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/10 Animations/04 implicit/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/10 Animations/04 implicit/lib/widgets/main_drawer.dart b/Code Snapshots/10 Animations/04 implicit/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/10 Animations/04 implicit/lib/widgets/main_drawer.dart +++ b/Code Snapshots/10 Animations/04 implicit/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/10 Animations/05 Finished/lib/screens/filters.dart b/Code Snapshots/10 Animations/05 Finished/lib/screens/filters.dart index 27b19e18..619a17e1 100644 --- a/Code Snapshots/10 Animations/05 Finished/lib/screens/filters.dart +++ b/Code Snapshots/10 Animations/05 Finished/lib/screens/filters.dart @@ -28,13 +28,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -50,13 +50,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -72,13 +72,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -94,13 +94,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Code Snapshots/10 Animations/05 Finished/lib/screens/meal_details.dart b/Code Snapshots/10 Animations/05 Finished/lib/screens/meal_details.dart index 47dc2101..89e58022 100644 --- a/Code Snapshots/10 Animations/05 Finished/lib/screens/meal_details.dart +++ b/Code Snapshots/10 Animations/05 Finished/lib/screens/meal_details.dart @@ -73,7 +73,7 @@ class MealDetailsScreen extends ConsumerWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -95,7 +95,7 @@ class MealDetailsScreen extends ConsumerWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/10 Animations/05 Finished/lib/screens/meals.dart b/Code Snapshots/10 Animations/05 Finished/lib/screens/meals.dart index 73287bfc..3a2664c6 100644 --- a/Code Snapshots/10 Animations/05 Finished/lib/screens/meals.dart +++ b/Code Snapshots/10 Animations/05 Finished/lib/screens/meals.dart @@ -33,14 +33,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Code Snapshots/10 Animations/05 Finished/lib/widgets/category_grid_item.dart b/Code Snapshots/10 Animations/05 Finished/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Code Snapshots/10 Animations/05 Finished/lib/widgets/category_grid_item.dart +++ b/Code Snapshots/10 Animations/05 Finished/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/10 Animations/05 Finished/lib/widgets/main_drawer.dart b/Code Snapshots/10 Animations/05 Finished/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Code Snapshots/10 Animations/05 Finished/lib/widgets/main_drawer.dart +++ b/Code Snapshots/10 Animations/05 Finished/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Code Snapshots/13 Native Device Features/02 Adding a Places Screen/lib/widgets/places_list.dart b/Code Snapshots/13 Native Device Features/02 Adding a Places Screen/lib/widgets/places_list.dart index 2b83f416..9c1b8b87 100644 --- a/Code Snapshots/13 Native Device Features/02 Adding a Places Screen/lib/widgets/places_list.dart +++ b/Code Snapshots/13 Native Device Features/02 Adding a Places Screen/lib/widgets/places_list.dart @@ -14,7 +14,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -26,7 +26,7 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/13 Native Device Features/03 AddPlace Screen/lib/screens/add_place.dart b/Code Snapshots/13 Native Device Features/03 AddPlace Screen/lib/screens/add_place.dart index 8520e1b5..dd7eadf2 100644 --- a/Code Snapshots/13 Native Device Features/03 AddPlace Screen/lib/screens/add_place.dart +++ b/Code Snapshots/13 Native Device Features/03 AddPlace Screen/lib/screens/add_place.dart @@ -32,7 +32,7 @@ class _AddPlaceScreenState extends State { decoration: const InputDecoration(labelText: 'Title'), controller: _titleController, style: TextStyle( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), diff --git a/Code Snapshots/13 Native Device Features/03 AddPlace Screen/lib/widgets/places_list.dart b/Code Snapshots/13 Native Device Features/03 AddPlace Screen/lib/widgets/places_list.dart index 2b83f416..9c1b8b87 100644 --- a/Code Snapshots/13 Native Device Features/03 AddPlace Screen/lib/widgets/places_list.dart +++ b/Code Snapshots/13 Native Device Features/03 AddPlace Screen/lib/widgets/places_list.dart @@ -14,7 +14,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -26,7 +26,7 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/13 Native Device Features/04 Added riverpod/lib/screens/add_place.dart b/Code Snapshots/13 Native Device Features/04 Added riverpod/lib/screens/add_place.dart index 942d297f..4a4fb67f 100644 --- a/Code Snapshots/13 Native Device Features/04 Added riverpod/lib/screens/add_place.dart +++ b/Code Snapshots/13 Native Device Features/04 Added riverpod/lib/screens/add_place.dart @@ -47,7 +47,7 @@ class _AddPlaceScreenState extends ConsumerState { decoration: const InputDecoration(labelText: 'Title'), controller: _titleController, style: TextStyle( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), diff --git a/Code Snapshots/13 Native Device Features/04 Added riverpod/lib/widgets/places_list.dart b/Code Snapshots/13 Native Device Features/04 Added riverpod/lib/widgets/places_list.dart index 2b83f416..9c1b8b87 100644 --- a/Code Snapshots/13 Native Device Features/04 Added riverpod/lib/widgets/places_list.dart +++ b/Code Snapshots/13 Native Device Features/04 Added riverpod/lib/widgets/places_list.dart @@ -14,7 +14,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -26,7 +26,7 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/13 Native Device Features/05 PlaceDetail screen/lib/screens/add_place.dart b/Code Snapshots/13 Native Device Features/05 PlaceDetail screen/lib/screens/add_place.dart index 942d297f..4a4fb67f 100644 --- a/Code Snapshots/13 Native Device Features/05 PlaceDetail screen/lib/screens/add_place.dart +++ b/Code Snapshots/13 Native Device Features/05 PlaceDetail screen/lib/screens/add_place.dart @@ -47,7 +47,7 @@ class _AddPlaceScreenState extends ConsumerState { decoration: const InputDecoration(labelText: 'Title'), controller: _titleController, style: TextStyle( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), diff --git a/Code Snapshots/13 Native Device Features/05 PlaceDetail screen/lib/screens/place_detail.dart b/Code Snapshots/13 Native Device Features/05 PlaceDetail screen/lib/screens/place_detail.dart index 3c98321d..1c54cacc 100644 --- a/Code Snapshots/13 Native Device Features/05 PlaceDetail screen/lib/screens/place_detail.dart +++ b/Code Snapshots/13 Native Device Features/05 PlaceDetail screen/lib/screens/place_detail.dart @@ -17,7 +17,7 @@ class PlaceDetailScreen extends StatelessWidget { child: Text( place.title, style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/13 Native Device Features/05 PlaceDetail screen/lib/widgets/places_list.dart b/Code Snapshots/13 Native Device Features/05 PlaceDetail screen/lib/widgets/places_list.dart index ef19d8ae..51f38dc7 100644 --- a/Code Snapshots/13 Native Device Features/05 PlaceDetail screen/lib/widgets/places_list.dart +++ b/Code Snapshots/13 Native Device Features/05 PlaceDetail screen/lib/widgets/places_list.dart @@ -15,7 +15,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -27,7 +27,7 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), onTap: () { diff --git a/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/screens/add_place.dart b/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/screens/add_place.dart index d955a7e9..2a07a4b8 100644 --- a/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/screens/add_place.dart +++ b/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/screens/add_place.dart @@ -48,7 +48,7 @@ class _AddPlaceScreenState extends ConsumerState { decoration: const InputDecoration(labelText: 'Title'), controller: _titleController, style: TextStyle( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 10), diff --git a/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/screens/place_detail.dart b/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/screens/place_detail.dart index 3c98321d..1c54cacc 100644 --- a/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/screens/place_detail.dart +++ b/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/screens/place_detail.dart @@ -17,7 +17,7 @@ class PlaceDetailScreen extends StatelessWidget { child: Text( place.title, style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/widgets/image_input.dart b/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/widgets/image_input.dart index ade33b6e..a8e826e8 100644 --- a/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/widgets/image_input.dart +++ b/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/widgets/image_input.dart @@ -53,7 +53,7 @@ class _ImageInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), height: 250, diff --git a/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/widgets/places_list.dart b/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/widgets/places_list.dart index ef19d8ae..51f38dc7 100644 --- a/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/widgets/places_list.dart +++ b/Code Snapshots/13 Native Device Features/06 Using the Device Camera/lib/widgets/places_list.dart @@ -15,7 +15,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -27,7 +27,7 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), onTap: () { diff --git a/Code Snapshots/13 Native Device Features/07 Previewing the Picked Image/lib/screens/add_place.dart b/Code Snapshots/13 Native Device Features/07 Previewing the Picked Image/lib/screens/add_place.dart index 0cf4beca..49e7b5b6 100644 --- a/Code Snapshots/13 Native Device Features/07 Previewing the Picked Image/lib/screens/add_place.dart +++ b/Code Snapshots/13 Native Device Features/07 Previewing the Picked Image/lib/screens/add_place.dart @@ -53,7 +53,7 @@ class _AddPlaceScreenState extends ConsumerState { decoration: const InputDecoration(labelText: 'Title'), controller: _titleController, style: TextStyle( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 10), diff --git a/Code Snapshots/13 Native Device Features/07 Previewing the Picked Image/lib/widgets/image_input.dart b/Code Snapshots/13 Native Device Features/07 Previewing the Picked Image/lib/widgets/image_input.dart index 6562709c..4dbb3287 100644 --- a/Code Snapshots/13 Native Device Features/07 Previewing the Picked Image/lib/widgets/image_input.dart +++ b/Code Snapshots/13 Native Device Features/07 Previewing the Picked Image/lib/widgets/image_input.dart @@ -57,7 +57,7 @@ class _ImageInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), height: 250, diff --git a/Code Snapshots/13 Native Device Features/07 Previewing the Picked Image/lib/widgets/places_list.dart b/Code Snapshots/13 Native Device Features/07 Previewing the Picked Image/lib/widgets/places_list.dart index 777c00c4..2b599f03 100644 --- a/Code Snapshots/13 Native Device Features/07 Previewing the Picked Image/lib/widgets/places_list.dart +++ b/Code Snapshots/13 Native Device Features/07 Previewing the Picked Image/lib/widgets/places_list.dart @@ -15,7 +15,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -31,7 +31,7 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), onTap: () { diff --git a/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/screens/add_place.dart b/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/screens/add_place.dart index 68de6ee9..46c4ed68 100644 --- a/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/screens/add_place.dart +++ b/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/screens/add_place.dart @@ -54,7 +54,7 @@ class _AddPlaceScreenState extends ConsumerState { decoration: const InputDecoration(labelText: 'Title'), controller: _titleController, style: TextStyle( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 10), diff --git a/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/widgets/image_input.dart b/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/widgets/image_input.dart index 6562709c..4dbb3287 100644 --- a/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/widgets/image_input.dart +++ b/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/widgets/image_input.dart @@ -57,7 +57,7 @@ class _ImageInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), height: 250, diff --git a/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/widgets/location_input.dart b/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/widgets/location_input.dart index 868b0acc..a29ea8d7 100644 --- a/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/widgets/location_input.dart +++ b/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/widgets/location_input.dart @@ -21,14 +21,14 @@ class _LocationInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), child: Text( 'No location chosen', textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/widgets/places_list.dart b/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/widgets/places_list.dart index 777c00c4..2b599f03 100644 --- a/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/widgets/places_list.dart +++ b/Code Snapshots/13 Native Device Features/08 Adding the Location Package/lib/widgets/places_list.dart @@ -15,7 +15,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -31,7 +31,7 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), onTap: () { diff --git a/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/screens/add_place.dart b/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/screens/add_place.dart index 68de6ee9..46c4ed68 100644 --- a/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/screens/add_place.dart +++ b/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/screens/add_place.dart @@ -54,7 +54,7 @@ class _AddPlaceScreenState extends ConsumerState { decoration: const InputDecoration(labelText: 'Title'), controller: _titleController, style: TextStyle( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 10), diff --git a/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/widgets/image_input.dart b/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/widgets/image_input.dart index 6562709c..4dbb3287 100644 --- a/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/widgets/image_input.dart +++ b/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/widgets/image_input.dart @@ -57,7 +57,7 @@ class _ImageInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), height: 250, diff --git a/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/widgets/location_input.dart b/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/widgets/location_input.dart index c31d7b5f..33cea74f 100644 --- a/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/widgets/location_input.dart +++ b/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/widgets/location_input.dart @@ -57,7 +57,7 @@ class _LocationInputState extends State { 'No location chosen', textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ); @@ -74,7 +74,7 @@ class _LocationInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), child: previewContent, diff --git a/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/widgets/places_list.dart b/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/widgets/places_list.dart index 777c00c4..2b599f03 100644 --- a/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/widgets/places_list.dart +++ b/Code Snapshots/13 Native Device Features/09 Get Current Location/lib/widgets/places_list.dart @@ -15,7 +15,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -31,7 +31,7 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), onTap: () { diff --git a/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/screens/add_place.dart b/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/screens/add_place.dart index 68de6ee9..46c4ed68 100644 --- a/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/screens/add_place.dart +++ b/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/screens/add_place.dart @@ -54,7 +54,7 @@ class _AddPlaceScreenState extends ConsumerState { decoration: const InputDecoration(labelText: 'Title'), controller: _titleController, style: TextStyle( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 10), diff --git a/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/widgets/image_input.dart b/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/widgets/image_input.dart index 6562709c..4dbb3287 100644 --- a/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/widgets/image_input.dart +++ b/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/widgets/image_input.dart @@ -57,7 +57,7 @@ class _ImageInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), height: 250, diff --git a/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/widgets/location_input.dart b/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/widgets/location_input.dart index 148e7705..aa4c3678 100644 --- a/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/widgets/location_input.dart +++ b/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/widgets/location_input.dart @@ -85,7 +85,7 @@ class _LocationInputState extends State { 'No location chosen', textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ); @@ -111,7 +111,7 @@ class _LocationInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), child: previewContent, diff --git a/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/widgets/places_list.dart b/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/widgets/places_list.dart index 777c00c4..2b599f03 100644 --- a/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/widgets/places_list.dart +++ b/Code Snapshots/13 Native Device Features/10 Displaying a Location Preview/lib/widgets/places_list.dart @@ -15,7 +15,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -31,7 +31,7 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), onTap: () { diff --git a/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/screens/add_place.dart b/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/screens/add_place.dart index 55910376..26416780 100644 --- a/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/screens/add_place.dart +++ b/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/screens/add_place.dart @@ -58,7 +58,7 @@ class _AddPlaceScreenState extends ConsumerState { decoration: const InputDecoration(labelText: 'Title'), controller: _titleController, style: TextStyle( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 10), diff --git a/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/screens/place_detail.dart b/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/screens/place_detail.dart index 6a856c2e..efe28fa5 100644 --- a/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/screens/place_detail.dart +++ b/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/screens/place_detail.dart @@ -57,7 +57,7 @@ class PlaceDetailScreen extends StatelessWidget { place.location.address, textAlign: TextAlign.center, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/widgets/image_input.dart b/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/widgets/image_input.dart index 6562709c..4dbb3287 100644 --- a/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/widgets/image_input.dart +++ b/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/widgets/image_input.dart @@ -57,7 +57,7 @@ class _ImageInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), height: 250, diff --git a/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/widgets/location_input.dart b/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/widgets/location_input.dart index c393313b..7621c959 100644 --- a/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/widgets/location_input.dart +++ b/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/widgets/location_input.dart @@ -89,7 +89,7 @@ class _LocationInputState extends State { 'No location chosen', textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ); @@ -115,7 +115,7 @@ class _LocationInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), child: previewContent, diff --git a/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/widgets/places_list.dart b/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/widgets/places_list.dart index 9afce093..41f54204 100644 --- a/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/widgets/places_list.dart +++ b/Code Snapshots/13 Native Device Features/11 Outputting the Location Data/lib/widgets/places_list.dart @@ -15,7 +15,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -31,13 +31,13 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( places[index].location.address, style: Theme.of(context).textTheme.bodySmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), onTap: () { diff --git a/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/screens/add_place.dart b/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/screens/add_place.dart index 55910376..26416780 100644 --- a/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/screens/add_place.dart +++ b/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/screens/add_place.dart @@ -58,7 +58,7 @@ class _AddPlaceScreenState extends ConsumerState { decoration: const InputDecoration(labelText: 'Title'), controller: _titleController, style: TextStyle( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 10), diff --git a/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/screens/place_detail.dart b/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/screens/place_detail.dart index 93802a9c..6ef8ac44 100644 --- a/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/screens/place_detail.dart +++ b/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/screens/place_detail.dart @@ -70,7 +70,7 @@ class PlaceDetailScreen extends StatelessWidget { place.location.address, textAlign: TextAlign.center, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/widgets/image_input.dart b/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/widgets/image_input.dart index 6562709c..4dbb3287 100644 --- a/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/widgets/image_input.dart +++ b/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/widgets/image_input.dart @@ -57,7 +57,7 @@ class _ImageInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), height: 250, diff --git a/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/widgets/location_input.dart b/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/widgets/location_input.dart index c393313b..7621c959 100644 --- a/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/widgets/location_input.dart +++ b/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/widgets/location_input.dart @@ -89,7 +89,7 @@ class _LocationInputState extends State { 'No location chosen', textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ); @@ -115,7 +115,7 @@ class _LocationInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), child: previewContent, diff --git a/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/widgets/places_list.dart b/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/widgets/places_list.dart index 9afce093..41f54204 100644 --- a/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/widgets/places_list.dart +++ b/Code Snapshots/13 Native Device Features/12 Adding a Map Screen/lib/widgets/places_list.dart @@ -15,7 +15,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -31,13 +31,13 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( places[index].location.address, style: Theme.of(context).textTheme.bodySmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), onTap: () { diff --git a/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/screens/add_place.dart b/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/screens/add_place.dart index 55910376..26416780 100644 --- a/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/screens/add_place.dart +++ b/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/screens/add_place.dart @@ -58,7 +58,7 @@ class _AddPlaceScreenState extends ConsumerState { decoration: const InputDecoration(labelText: 'Title'), controller: _titleController, style: TextStyle( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 10), diff --git a/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/screens/place_detail.dart b/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/screens/place_detail.dart index 93802a9c..6ef8ac44 100644 --- a/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/screens/place_detail.dart +++ b/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/screens/place_detail.dart @@ -70,7 +70,7 @@ class PlaceDetailScreen extends StatelessWidget { place.location.address, textAlign: TextAlign.center, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/widgets/image_input.dart b/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/widgets/image_input.dart index 6562709c..4dbb3287 100644 --- a/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/widgets/image_input.dart +++ b/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/widgets/image_input.dart @@ -57,7 +57,7 @@ class _ImageInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), height: 250, diff --git a/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/widgets/location_input.dart b/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/widgets/location_input.dart index d80d7cb0..dff5060b 100644 --- a/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/widgets/location_input.dart +++ b/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/widgets/location_input.dart @@ -109,7 +109,7 @@ class _LocationInputState extends State { 'No location chosen', textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ); @@ -135,7 +135,7 @@ class _LocationInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), child: previewContent, diff --git a/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/widgets/places_list.dart b/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/widgets/places_list.dart index 9afce093..41f54204 100644 --- a/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/widgets/places_list.dart +++ b/Code Snapshots/13 Native Device Features/13 Using the Map Screen in the Form/lib/widgets/places_list.dart @@ -15,7 +15,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -31,13 +31,13 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( places[index].location.address, style: Theme.of(context).textTheme.bodySmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), onTap: () { diff --git a/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/screens/add_place.dart b/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/screens/add_place.dart index 55910376..26416780 100644 --- a/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/screens/add_place.dart +++ b/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/screens/add_place.dart @@ -58,7 +58,7 @@ class _AddPlaceScreenState extends ConsumerState { decoration: const InputDecoration(labelText: 'Title'), controller: _titleController, style: TextStyle( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 10), diff --git a/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/screens/place_detail.dart b/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/screens/place_detail.dart index 93802a9c..6ef8ac44 100644 --- a/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/screens/place_detail.dart +++ b/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/screens/place_detail.dart @@ -70,7 +70,7 @@ class PlaceDetailScreen extends StatelessWidget { place.location.address, textAlign: TextAlign.center, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/widgets/image_input.dart b/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/widgets/image_input.dart index 6562709c..4dbb3287 100644 --- a/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/widgets/image_input.dart +++ b/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/widgets/image_input.dart @@ -57,7 +57,7 @@ class _ImageInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), height: 250, diff --git a/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/widgets/location_input.dart b/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/widgets/location_input.dart index d80d7cb0..dff5060b 100644 --- a/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/widgets/location_input.dart +++ b/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/widgets/location_input.dart @@ -109,7 +109,7 @@ class _LocationInputState extends State { 'No location chosen', textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ); @@ -135,7 +135,7 @@ class _LocationInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), child: previewContent, diff --git a/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/widgets/places_list.dart b/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/widgets/places_list.dart index 9afce093..41f54204 100644 --- a/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/widgets/places_list.dart +++ b/Code Snapshots/13 Native Device Features/14 Storing the Picked Image Locally/lib/widgets/places_list.dart @@ -15,7 +15,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -31,13 +31,13 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( places[index].location.address, style: Theme.of(context).textTheme.bodySmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), onTap: () { diff --git a/Code Snapshots/13 Native Device Features/15 Finished/lib/screens/add_place.dart b/Code Snapshots/13 Native Device Features/15 Finished/lib/screens/add_place.dart index 55910376..26416780 100644 --- a/Code Snapshots/13 Native Device Features/15 Finished/lib/screens/add_place.dart +++ b/Code Snapshots/13 Native Device Features/15 Finished/lib/screens/add_place.dart @@ -58,7 +58,7 @@ class _AddPlaceScreenState extends ConsumerState { decoration: const InputDecoration(labelText: 'Title'), controller: _titleController, style: TextStyle( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 10), diff --git a/Code Snapshots/13 Native Device Features/15 Finished/lib/screens/place_detail.dart b/Code Snapshots/13 Native Device Features/15 Finished/lib/screens/place_detail.dart index 93802a9c..6ef8ac44 100644 --- a/Code Snapshots/13 Native Device Features/15 Finished/lib/screens/place_detail.dart +++ b/Code Snapshots/13 Native Device Features/15 Finished/lib/screens/place_detail.dart @@ -70,7 +70,7 @@ class PlaceDetailScreen extends StatelessWidget { place.location.address, textAlign: TextAlign.center, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Code Snapshots/13 Native Device Features/15 Finished/lib/widgets/image_input.dart b/Code Snapshots/13 Native Device Features/15 Finished/lib/widgets/image_input.dart index 6562709c..4dbb3287 100644 --- a/Code Snapshots/13 Native Device Features/15 Finished/lib/widgets/image_input.dart +++ b/Code Snapshots/13 Native Device Features/15 Finished/lib/widgets/image_input.dart @@ -57,7 +57,7 @@ class _ImageInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), height: 250, diff --git a/Code Snapshots/13 Native Device Features/15 Finished/lib/widgets/location_input.dart b/Code Snapshots/13 Native Device Features/15 Finished/lib/widgets/location_input.dart index d80d7cb0..dff5060b 100644 --- a/Code Snapshots/13 Native Device Features/15 Finished/lib/widgets/location_input.dart +++ b/Code Snapshots/13 Native Device Features/15 Finished/lib/widgets/location_input.dart @@ -109,7 +109,7 @@ class _LocationInputState extends State { 'No location chosen', textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ); @@ -135,7 +135,7 @@ class _LocationInputState extends State { decoration: BoxDecoration( border: Border.all( width: 1, - color: Theme.of(context).colorScheme.primary.withOpacity(0.2), + color: Theme.of(context).colorScheme.primary.withValues(alpha: 0.2), ), ), child: previewContent, diff --git a/Code Snapshots/13 Native Device Features/15 Finished/lib/widgets/places_list.dart b/Code Snapshots/13 Native Device Features/15 Finished/lib/widgets/places_list.dart index 9afce093..41f54204 100644 --- a/Code Snapshots/13 Native Device Features/15 Finished/lib/widgets/places_list.dart +++ b/Code Snapshots/13 Native Device Features/15 Finished/lib/widgets/places_list.dart @@ -15,7 +15,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -31,13 +31,13 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( places[index].location.address, style: Theme.of(context).textTheme.bodySmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), onTap: () { diff --git a/Lecture Attachments/05 Interactivity & Theming/chart/chart.dart b/Lecture Attachments/05 Interactivity & Theming/chart/chart.dart index d97c89b7..6949c0de 100644 --- a/Lecture Attachments/05 Interactivity & Theming/chart/chart.dart +++ b/Lecture Attachments/05 Interactivity & Theming/chart/chart.dart @@ -45,8 +45,8 @@ class Chart extends StatelessWidget { borderRadius: BorderRadius.circular(8), gradient: LinearGradient( colors: [ - Theme.of(context).colorScheme.primary.withOpacity(0.3), - Theme.of(context).colorScheme.primary.withOpacity(0.0) + Theme.of(context).colorScheme.primary.withValues(alpha: 0.3), + Theme.of(context).colorScheme.primary.withValues(alpha: 0.0) ], begin: Alignment.bottomCenter, end: Alignment.topCenter, @@ -81,7 +81,7 @@ class Chart extends StatelessWidget { : Theme.of(context) .colorScheme .primary - .withOpacity(0.7), + .withValues(alpha: 0.7), ), ), ), diff --git a/Lecture Attachments/05 Interactivity & Theming/chart/chart_bar.dart b/Lecture Attachments/05 Interactivity & Theming/chart/chart_bar.dart index b4c3e5f1..dacc35c4 100644 --- a/Lecture Attachments/05 Interactivity & Theming/chart/chart_bar.dart +++ b/Lecture Attachments/05 Interactivity & Theming/chart/chart_bar.dart @@ -24,7 +24,7 @@ class ChartBar extends StatelessWidget { const BorderRadius.vertical(top: Radius.circular(8)), color: isDarkMode ? Theme.of(context).colorScheme.secondary - : Theme.of(context).colorScheme.primary.withOpacity(0.65), + : Theme.of(context).colorScheme.primary.withValues(alpha: 0.65), ), ), ), diff --git a/Lecture Attachments/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart.dart b/Lecture Attachments/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart.dart index 827a9105..d7ebe699 100644 --- a/Lecture Attachments/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart.dart +++ b/Lecture Attachments/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart.dart @@ -45,8 +45,8 @@ class Chart extends StatelessWidget { borderRadius: BorderRadius.circular(8), gradient: LinearGradient( colors: [ - Theme.of(context).colorScheme.primary.withOpacity(0.3), - Theme.of(context).colorScheme.primary.withOpacity(0.0) + Theme.of(context).colorScheme.primary.withValues(alpha: 0.3), + Theme.of(context).colorScheme.primary.withValues(alpha: 0.0) ], begin: Alignment.bottomCenter, end: Alignment.topCenter, @@ -81,7 +81,7 @@ class Chart extends StatelessWidget { : Theme.of(context) .colorScheme .primary - .withOpacity(0.7), + .withValues(alpha: 0.7), ), ), ), diff --git a/Lecture Attachments/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart_bar.dart b/Lecture Attachments/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart_bar.dart index a2e35418..9c93f16c 100644 --- a/Lecture Attachments/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart_bar.dart +++ b/Lecture Attachments/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/chart/chart_bar.dart @@ -24,7 +24,7 @@ class ChartBar extends StatelessWidget { const BorderRadius.vertical(top: Radius.circular(8)), color: isDarkMode ? Theme.of(context).colorScheme.secondary - : Theme.of(context).colorScheme.primary.withOpacity(0.65), + : Theme.of(context).colorScheme.primary.withValues(alpha: 0.65), ), ), ), diff --git a/Lecture Attachments/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/expenses_list/expenses_list.dart b/Lecture Attachments/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/expenses_list/expenses_list.dart index fda0d2ac..1e41838d 100644 --- a/Lecture Attachments/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/expenses_list/expenses_list.dart +++ b/Lecture Attachments/06 Responsive & Adaptive/01 Starting Setup/lib/widgets/expenses_list/expenses_list.dart @@ -20,7 +20,7 @@ class ExpensesList extends StatelessWidget { itemBuilder: (ctx, index) => Dismissible( key: ValueKey(expenses[index]), background: Container( - color: Theme.of(context).colorScheme.error.withOpacity(0.75), + color: Theme.of(context).colorScheme.error.withValues(alpha: 0.75), margin: EdgeInsets.symmetric( horizontal: Theme.of(context).cardTheme.margin!.horizontal, ), diff --git a/Lecture Attachments/09 State Management/01 Starting Setup/lib/screens/filters.dart b/Lecture Attachments/09 State Management/01 Starting Setup/lib/screens/filters.dart index b87e8700..2bcc1ab3 100644 --- a/Lecture Attachments/09 State Management/01 Starting Setup/lib/screens/filters.dart +++ b/Lecture Attachments/09 State Management/01 Starting Setup/lib/screens/filters.dart @@ -76,13 +76,13 @@ class _FiltersScreenState extends State { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -98,13 +98,13 @@ class _FiltersScreenState extends State { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -120,13 +120,13 @@ class _FiltersScreenState extends State { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -142,13 +142,13 @@ class _FiltersScreenState extends State { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Lecture Attachments/09 State Management/01 Starting Setup/lib/screens/meal_details.dart b/Lecture Attachments/09 State Management/01 Starting Setup/lib/screens/meal_details.dart index 426c322a..95690891 100644 --- a/Lecture Attachments/09 State Management/01 Starting Setup/lib/screens/meal_details.dart +++ b/Lecture Attachments/09 State Management/01 Starting Setup/lib/screens/meal_details.dart @@ -45,7 +45,7 @@ class MealDetailsScreen extends StatelessWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -67,7 +67,7 @@ class MealDetailsScreen extends StatelessWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Lecture Attachments/09 State Management/01 Starting Setup/lib/screens/meals.dart b/Lecture Attachments/09 State Management/01 Starting Setup/lib/screens/meals.dart index 884dfbc9..1c924cd6 100644 --- a/Lecture Attachments/09 State Management/01 Starting Setup/lib/screens/meals.dart +++ b/Lecture Attachments/09 State Management/01 Starting Setup/lib/screens/meals.dart @@ -36,14 +36,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Lecture Attachments/09 State Management/01 Starting Setup/lib/widgets/category_grid_item.dart b/Lecture Attachments/09 State Management/01 Starting Setup/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Lecture Attachments/09 State Management/01 Starting Setup/lib/widgets/category_grid_item.dart +++ b/Lecture Attachments/09 State Management/01 Starting Setup/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Lecture Attachments/09 State Management/01 Starting Setup/lib/widgets/main_drawer.dart b/Lecture Attachments/09 State Management/01 Starting Setup/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Lecture Attachments/09 State Management/01 Starting Setup/lib/widgets/main_drawer.dart +++ b/Lecture Attachments/09 State Management/01 Starting Setup/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Lecture Attachments/10 Animations/01 Starting Setup/lib/screens/filters.dart b/Lecture Attachments/10 Animations/01 Starting Setup/lib/screens/filters.dart index 27b19e18..619a17e1 100644 --- a/Lecture Attachments/10 Animations/01 Starting Setup/lib/screens/filters.dart +++ b/Lecture Attachments/10 Animations/01 Starting Setup/lib/screens/filters.dart @@ -28,13 +28,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Gluten-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include gluten-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -50,13 +50,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Lactose-free', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include lactose-free meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -72,13 +72,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegetarian', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegetarian meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, @@ -94,13 +94,13 @@ class FiltersScreen extends ConsumerWidget { title: Text( 'Vegan', style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), subtitle: Text( 'Only include vegan meals.', style: Theme.of(context).textTheme.labelMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), activeColor: Theme.of(context).colorScheme.tertiary, diff --git a/Lecture Attachments/10 Animations/01 Starting Setup/lib/screens/meal_details.dart b/Lecture Attachments/10 Animations/01 Starting Setup/lib/screens/meal_details.dart index 2910480f..e0b12662 100644 --- a/Lecture Attachments/10 Animations/01 Starting Setup/lib/screens/meal_details.dart +++ b/Lecture Attachments/10 Animations/01 Starting Setup/lib/screens/meal_details.dart @@ -58,7 +58,7 @@ class MealDetailsScreen extends ConsumerWidget { Text( ingredient, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 24), @@ -80,7 +80,7 @@ class MealDetailsScreen extends ConsumerWidget { step, textAlign: TextAlign.center, style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Lecture Attachments/10 Animations/01 Starting Setup/lib/screens/meals.dart b/Lecture Attachments/10 Animations/01 Starting Setup/lib/screens/meals.dart index 73287bfc..3a2664c6 100644 --- a/Lecture Attachments/10 Animations/01 Starting Setup/lib/screens/meals.dart +++ b/Lecture Attachments/10 Animations/01 Starting Setup/lib/screens/meals.dart @@ -33,14 +33,14 @@ class MealsScreen extends StatelessWidget { Text( 'Uh oh ... nothing here!', style: Theme.of(context).textTheme.headlineLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), Text( 'Try selecting a different category!', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ], diff --git a/Lecture Attachments/10 Animations/01 Starting Setup/lib/widgets/category_grid_item.dart b/Lecture Attachments/10 Animations/01 Starting Setup/lib/widgets/category_grid_item.dart index 8b1563a3..cfd7e922 100644 --- a/Lecture Attachments/10 Animations/01 Starting Setup/lib/widgets/category_grid_item.dart +++ b/Lecture Attachments/10 Animations/01 Starting Setup/lib/widgets/category_grid_item.dart @@ -24,8 +24,8 @@ class CategoryGridItem extends StatelessWidget { borderRadius: BorderRadius.circular(16), gradient: LinearGradient( colors: [ - category.color.withOpacity(0.55), - category.color.withOpacity(0.9), + category.color.withValues(alpha: 0.55), + category.color.withValues(alpha: 0.9), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -33,7 +33,7 @@ class CategoryGridItem extends StatelessWidget { child: Text( category.title, style: Theme.of(context).textTheme.titleLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Lecture Attachments/10 Animations/01 Starting Setup/lib/widgets/main_drawer.dart b/Lecture Attachments/10 Animations/01 Starting Setup/lib/widgets/main_drawer.dart index f2f44ef4..4e3146de 100644 --- a/Lecture Attachments/10 Animations/01 Starting Setup/lib/widgets/main_drawer.dart +++ b/Lecture Attachments/10 Animations/01 Starting Setup/lib/widgets/main_drawer.dart @@ -19,7 +19,7 @@ class MainDrawer extends StatelessWidget { Theme.of(context) .colorScheme .primaryContainer - .withOpacity(0.8), + .withValues(alpha: 0.8), ], begin: Alignment.topLeft, end: Alignment.bottomRight, @@ -46,12 +46,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.restaurant, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Meals', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), @@ -63,12 +63,12 @@ class MainDrawer extends StatelessWidget { leading: Icon( Icons.settings, size: 26, - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), title: Text( 'Filters', style: Theme.of(context).textTheme.titleSmall!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, fontSize: 24, ), ), diff --git a/Lecture Attachments/13 Native Device Features/Finished Challenge/lib/screens/add_place.dart b/Lecture Attachments/13 Native Device Features/Finished Challenge/lib/screens/add_place.dart index 942d297f..4a4fb67f 100644 --- a/Lecture Attachments/13 Native Device Features/Finished Challenge/lib/screens/add_place.dart +++ b/Lecture Attachments/13 Native Device Features/Finished Challenge/lib/screens/add_place.dart @@ -47,7 +47,7 @@ class _AddPlaceScreenState extends ConsumerState { decoration: const InputDecoration(labelText: 'Title'), controller: _titleController, style: TextStyle( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), const SizedBox(height: 16), diff --git a/Lecture Attachments/13 Native Device Features/Finished Challenge/lib/screens/place_detail.dart b/Lecture Attachments/13 Native Device Features/Finished Challenge/lib/screens/place_detail.dart index 3c98321d..1c54cacc 100644 --- a/Lecture Attachments/13 Native Device Features/Finished Challenge/lib/screens/place_detail.dart +++ b/Lecture Attachments/13 Native Device Features/Finished Challenge/lib/screens/place_detail.dart @@ -17,7 +17,7 @@ class PlaceDetailScreen extends StatelessWidget { child: Text( place.title, style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ), diff --git a/Lecture Attachments/13 Native Device Features/Finished Challenge/lib/widgets/places_list.dart b/Lecture Attachments/13 Native Device Features/Finished Challenge/lib/widgets/places_list.dart index ef19d8ae..51f38dc7 100644 --- a/Lecture Attachments/13 Native Device Features/Finished Challenge/lib/widgets/places_list.dart +++ b/Lecture Attachments/13 Native Device Features/Finished Challenge/lib/widgets/places_list.dart @@ -15,7 +15,7 @@ class PlacesList extends StatelessWidget { child: Text( 'No places added yet', style: Theme.of(context).textTheme.bodyLarge!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), ); @@ -27,7 +27,7 @@ class PlacesList extends StatelessWidget { title: Text( places[index].title, style: Theme.of(context).textTheme.titleMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, + color: Theme.of(context).colorScheme.onSurface, ), ), onTap: () {