Skip to content

Commit

Permalink
Use material 3 page transitions [android] (#267)
Browse files Browse the repository at this point in the history
The latest version of flutter (3.29, which we're already using) finally added a decent page transition matching up with the native material 3 transition. (main-api.flutter.dev/flutter/material/FadeForwardsPageTransitionsBuilder-class.html)

To test, fire up the app in android, and navigate around.
  • Loading branch information
IanVS authored Feb 25, 2025
1 parent 330c834 commit bcfcade
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions lib/services/theme.dart
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,12 @@ class MaterialTheme {
textTheme: textTheme.apply(bodyColor: colorScheme.onSurface, displayColor: colorScheme.onSurface),
scaffoldBackgroundColor: colorScheme.surface,
canvasColor: colorScheme.surface,
pageTransitionsTheme: PageTransitionsTheme(
builders: Map<TargetPlatform, PageTransitionsBuilder>.fromIterable(
TargetPlatform.values,
value: (_) => const FadeForwardsPageTransitionsBuilder(),
),
),
);

List<ExtendedColor> get extendedColors => [];
Expand Down

0 comments on commit bcfcade

Please sign in to comment.