import 'package:flutter/material.dart'; import 'package:go_router/go_router.dart'; import 'package:remixicon/remixicon.dart'; import '../../router/config/route_paths.dart'; import '../my/my_page.dart'; import 'widget/plan_form_card.dart'; import 'widget/quote_card.dart'; class HomePage extends StatefulWidget { const HomePage({super.key}); @override State createState() => _HomePageState(); } class _HomePageState extends State { final GlobalKey _scaffoldKey = GlobalKey(); @override Widget build(BuildContext context) { return Scaffold( key: _scaffoldKey, backgroundColor: Colors.white, appBar: AppBar( leading: IconButton( onPressed: () { _scaffoldKey.currentState?.openDrawer(); }, icon: Icon(RemixIcons.user_fill), ), actions: [ IconButton( color: Colors.black, onPressed: () { context.push(RoutePaths.planHistory); }, icon: Icon(RemixIcons.time_fill), ), ], ), body: ListView( padding: EdgeInsets.symmetric(horizontal: 15), children: [ QuoteCard(), PlanFormCard(), ], ), drawer: Drawer( backgroundColor: Colors.white, width: double.infinity, elevation: 0, shape: RoundedRectangleBorder(), child: MyPage( scaffoldKey: _scaffoldKey, ), ), ); } }