refactor: rename features to room-based directory structure
- Rename features/dashboard → features/front_hall - Update routes: /, /control-room, /parlor, /settings - Update navigation to 4 rooms (removed chat tab - will be omnipresent dock) - Add docs/UI_LAYOUT.md with wireframes and responsive specs - Update ARCHITECTURE.md and PLAN.md to reflect room structure Directory structure now mirrors "Rooms of the Estate" UI navigation: - front_hall/ (dashboard) - control_room/ (infrastructure - containers, stacks, etc.) - parlor/ (home automation) - library/ (future) - study/ (future, hidden) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -12,29 +12,27 @@ class AppScaffold extends StatelessWidget {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
// TODO: Replace AdaptiveScaffold with custom layout per UI_LAYOUT.md
|
||||
// - Header with room tabs (not bottom/rail nav)
|
||||
// - Chat dock on right side
|
||||
return AdaptiveScaffold(
|
||||
selectedIndex: _selectedIndex(context),
|
||||
onSelectedIndexChange: (index) => _onNavSelected(context, index),
|
||||
destinations: const [
|
||||
NavigationDestination(
|
||||
icon: Icon(Icons.dashboard_outlined),
|
||||
selectedIcon: Icon(Icons.dashboard),
|
||||
label: 'Dashboard',
|
||||
),
|
||||
NavigationDestination(
|
||||
icon: Icon(Icons.chat_outlined),
|
||||
selectedIcon: Icon(Icons.chat),
|
||||
label: 'Tatlock',
|
||||
icon: Icon(Icons.door_front_door_outlined),
|
||||
selectedIcon: Icon(Icons.door_front_door),
|
||||
label: 'Front Hall',
|
||||
),
|
||||
NavigationDestination(
|
||||
icon: Icon(Icons.dns_outlined),
|
||||
selectedIcon: Icon(Icons.dns),
|
||||
label: 'Containers',
|
||||
label: 'Control Room',
|
||||
),
|
||||
NavigationDestination(
|
||||
icon: Icon(Icons.home_outlined),
|
||||
selectedIcon: Icon(Icons.home),
|
||||
label: 'Housekeeping',
|
||||
icon: Icon(Icons.weekend_outlined),
|
||||
selectedIcon: Icon(Icons.weekend),
|
||||
label: 'Parlor',
|
||||
),
|
||||
NavigationDestination(
|
||||
icon: Icon(Icons.settings_outlined),
|
||||
@@ -51,21 +49,19 @@ class AppScaffold extends StatelessWidget {
|
||||
int _selectedIndex(BuildContext context) {
|
||||
final location = GoRouterState.of(context).matchedLocation;
|
||||
|
||||
if (location.startsWith(AppRoutes.containers)) return 2;
|
||||
if (location.startsWith(AppRoutes.chat)) return 1;
|
||||
if (location.startsWith(AppRoutes.housekeeping)) return 3;
|
||||
if (location.startsWith(AppRoutes.settings)) return 4;
|
||||
return 0; // Dashboard
|
||||
if (location.startsWith(AppRoutes.controlRoom)) return 1;
|
||||
if (location.startsWith(AppRoutes.parlor)) return 2;
|
||||
if (location.startsWith(AppRoutes.settings)) return 3;
|
||||
return 0; // Front Hall
|
||||
}
|
||||
|
||||
void _onNavSelected(BuildContext context, int index) {
|
||||
final route = switch (index) {
|
||||
0 => AppRoutes.dashboard,
|
||||
1 => AppRoutes.chat,
|
||||
2 => AppRoutes.containers,
|
||||
3 => AppRoutes.housekeeping,
|
||||
4 => AppRoutes.settings,
|
||||
_ => AppRoutes.dashboard,
|
||||
0 => AppRoutes.frontHall,
|
||||
1 => AppRoutes.controlRoom,
|
||||
2 => AppRoutes.parlor,
|
||||
3 => AppRoutes.settings,
|
||||
_ => AppRoutes.frontHall,
|
||||
};
|
||||
context.go(route);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user