diff --git a/apps/app_seeds/lib/ui/app_drawer.dart b/apps/app_seeds/lib/ui/app_drawer.dart index 98d4cb1..135878f 100644 --- a/apps/app_seeds/lib/ui/app_drawer.dart +++ b/apps/app_seeds/lib/ui/app_drawer.dart @@ -27,78 +27,90 @@ class AppDrawer extends StatelessWidget { crossAxisAlignment: CrossAxisAlignment.stretch, children: [ const _DrawerHeader(), - _DrawerItem( - icon: const SeedGlyph(SeedGlyphs.jars, size: 23), - label: t.menu.inventory, - onTap: () { - Navigator.of(context).pop(); - context.push('/inventory'); - }, - ), - // Local, works offline — a reproduction-commitment ledger. - _DrawerItem( - icon: const Icon(Icons.volunteer_activism_outlined), - label: t.menu.plantares, - onTap: () { - Navigator.of(context).pop(); - context.push('/plantares'); - }, - ), - // Local sales ledger — also offline. - _DrawerItem( - icon: const Icon(Icons.sell_outlined), - label: t.menu.sales, - onTap: () { - Navigator.of(context).pop(); - context.push('/sales'); - }, - ), - // "What's due this month" — the aggregate crop calendar, offline. - _DrawerItem( - icon: const Icon(Icons.calendar_month), - label: t.menu.calendar, - onTap: () { - Navigator.of(context).pop(); - context.push('/calendar'); - }, - ), - _DrawerItem( - icon: const Icon(Symbols.storefront), - label: t.menu.market, - divider: true, - onTap: marketEnabled - ? () { + // The destinations scroll; the header above and the utility footer + // below stay pinned, so Settings/About are always reachable even on + // a short screen (drawer used to overflow once Calendar was added). + Expanded( + child: ListView( + padding: EdgeInsets.zero, + children: [ + _DrawerItem( + icon: const SeedGlyph(SeedGlyphs.jars, size: 23), + label: t.menu.inventory, + onTap: () { Navigator.of(context).pop(); - context.push('/market'); - } - : null, - ), - _DrawerItem( - icon: const Icon(Icons.person), - label: t.menu.profile, - onTap: marketEnabled - ? () { + context.push('/inventory'); + }, + ), + // Local, works offline — a reproduction-commitment ledger. + _DrawerItem( + icon: const Icon(Icons.volunteer_activism_outlined), + label: t.menu.plantares, + onTap: () { Navigator.of(context).pop(); - context.push('/profile'); - } - : null, - ), - _DrawerItem( - icon: const UnreadBadge(child: Icon(Icons.chat_bubble)), - label: t.menu.chat, - onTap: marketEnabled - ? () { + context.push('/plantares'); + }, + ), + // Local sales ledger — also offline. + _DrawerItem( + icon: const Icon(Icons.sell_outlined), + label: t.menu.sales, + onTap: () { Navigator.of(context).pop(); - context.push('/messages'); - } - : null, + context.push('/sales'); + }, + ), + // "What's due this month" — the aggregate crop calendar. + _DrawerItem( + icon: const Icon(Icons.calendar_month), + label: t.menu.calendar, + onTap: () { + Navigator.of(context).pop(); + context.push('/calendar'); + }, + ), + _DrawerItem( + icon: const Icon(Symbols.storefront), + label: t.menu.market, + divider: true, + onTap: marketEnabled + ? () { + Navigator.of(context).pop(); + context.push('/market'); + } + : null, + ), + _DrawerItem( + icon: const Icon(Icons.person), + label: t.menu.profile, + onTap: marketEnabled + ? () { + Navigator.of(context).pop(); + context.push('/profile'); + } + : null, + ), + _DrawerItem( + icon: const UnreadBadge(child: Icon(Icons.chat_bubble)), + label: t.menu.chat, + onTap: marketEnabled + ? () { + Navigator.of(context).pop(); + context.push('/messages'); + } + : null, + ), + _DrawerItem( + icon: const Icon(Icons.favorite), + label: t.menu.wishlist, + ), + _DrawerItem( + icon: const Icon(Icons.group), + label: t.menu.following, + ), + ], + ), ), - _DrawerItem( - icon: const Icon(Icons.favorite), - label: t.menu.wishlist, - ), - _DrawerItem(icon: const Icon(Icons.group), label: t.menu.following), - const Spacer(), const Divider(height: 1), _DrawerItem( icon: const Icon(Icons.auto_stories_outlined),