1
0
mirror of https://github.com/flutter/samples.git synced 2026-05-16 20:08:51 +00:00

Adjust animations lint rules (#814)

This commit is contained in:
Brett Morgan
2021-06-08 09:00:06 +10:00
committed by GitHub
parent 12ba3b2245
commit b1a49c0afb
28 changed files with 75 additions and 46 deletions

View File

@@ -5,6 +5,7 @@
import 'package:flutter/material.dart';
class HeroAnimationDemo extends StatelessWidget {
const HeroAnimationDemo({Key? key}) : super(key: key);
static const String routeName = '/misc/hero_animation';
@override
@@ -21,14 +22,16 @@ class HeroAnimationDemo extends StatelessWidget {
color: Colors.grey.shade300,
),
),
onTap: () => Navigator.of(context)
.push<void>(MaterialPageRoute(builder: (context) => HeroPage())),
onTap: () => Navigator.of(context).push<void>(
MaterialPageRoute(builder: (context) => const HeroPage())),
),
);
}
}
class HeroPage extends StatelessWidget {
const HeroPage({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return Scaffold(