part of home;

class HomePage extends StatefulWidget {
  const HomePage({Key? key}) : super(key: key);

  @override
  State<HomePage> createState() => _HomePageState();
}

class _HomePageState extends State<HomePage> {
  @override
  Widget build(BuildContext context) {
    SystemChrome.setSystemUIOverlayStyle(SystemUiOverlayStyle.light);
    return Scaffold(
      appBar: AppBar(title: const Text('首页'),),
      body: Column(
        mainAxisAlignment: MainAxisAlignment.start,
        crossAxisAlignment: CrossAxisAlignment.center,
        children: [
          GestureDetector(
            onTap: (){
              context.pushNamed(Routes.web);
            },
            child: Container(
              color: Colors.cyan,
              height: 40,
              // width: double.infinity,
              alignment: Alignment.center,
              child: const Text('read_web'),
            ),
          ),
          GestureDetector(
            onTap: (){
              context.pushNamed(Routes.about);
            },
            child: Container(
              color: Colors.indigo,
              height: 40,
              width: double.infinity,
              alignment: Alignment.center,
              child: const Text('关于我们'),
            ),
          )

        ],
      )
    );
  }
}
