Skip to content

Commit e5d6a48

Browse files
committed
refactor: implement gallery mode and update shell architecture
This commit overhauls the app to support dual operating modes: workspace and gallery. Key changes include: - Added gallery mode sidebar with section navigation and editor panels - Refactored site header to support non-closable scene tabs - Updated component capability defaults and layout policies - Created new UI components: alert, alert-dialog, footer-menu-stack - Improved sidebar styling with tone variants and better spacing - Added project delete confirmation dialogs - Updated design documentation to reflect the new mode model - Refactored artifact profile storage validation - Swapped command separator usage and updated theme provider exports - Fixed test snapshots for new layout and component changes
1 parent 709c0e0 commit e5d6a48

29 files changed

Lines changed: 1960 additions & 237 deletions
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
1:03:50 PM [vite] (client) Pre-transform error: Failed to load url /src/components/nav-user.tsx (resolved id: D:/codes/Agent-HTML-Sandbox/apps/agent-html/src/components/nav-user.tsx) in D:/codes/Agent-HTML-Sandbox/apps/agent-html/src/components/app-sidebar.tsx. Does the file exist?
2+
2:10:47 PM [vite] (client) Pre-transform error: Failed to load url /src/components/theme-view.tsx (resolved id: D:/codes/Agent-HTML-Sandbox/apps/agent-html/src/components/theme-view.tsx) in D:/codes/Agent-HTML-Sandbox/apps/agent-html/src/App.tsx. Does the file exist?

apps/agent-html/.agent-html-dev.out

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,56 @@ Port 4173 is in use, trying another one...
2828
1:24:31 PM [vite] (client) hmr update /src/components/app-sidebar.tsx, /src/index.css
2929
1:24:31 PM [vite] (client) hmr update /src/components/nav-projects.tsx, /src/index.css
3030
1:27:08 PM [vite] (client) hmr update /src/index.css, /src/components/settings-menu.tsx
31+
1:37:48 PM [vite] (client) hmr update /src/index.css, /src/components/settings-menu.tsx
32+
1:37:48 PM [vite] (client) hmr update /src/index.css, /src/components/settings-menu.tsx
33+
1:38:34 PM [vite] (client) hmr update /src/components/nav-projects.tsx, /src/index.css
34+
1:38:54 PM [vite] (client) hmr update /src/components/search-command.tsx, /src/index.css
35+
1:39:56 PM [vite] (client) hmr update /src/components/nav-projects.tsx, /src/index.css
36+
1:42:51 PM [vite] (client) hmr update /src/index.css, /src/components/settings-menu.tsx
37+
1:42:51 PM [vite] (client) hmr update /src/components/app-sidebar.tsx, /src/index.css
38+
1:43:12 PM [vite] (client) hmr update /src/index.css, /src/components/theme-menu.tsx
39+
1:43:33 PM [vite] (client) hmr update /src/components/ui/sidebar.tsx, /src/index.css
40+
1:43:34 PM [vite] (client) hmr invalidate /src/components/ui/sidebar.tsx Could not Fast Refresh ("useSidebar" export is incompatible). Learn more at https://github.com/vitejs/vite-plugin-react/tree/main/packages/plugin-react#consistent-components-exports
41+
1:43:34 PM [vite] (client) hmr update /src/App.tsx, /src/components/app-sidebar.tsx, /src/components/site-header.tsx, /src/components/search-command.tsx, /src/components/nav-secondary.tsx, /src/components/nav-projects.tsx, /src/components/settings-menu.tsx, /src/components/theme-menu.tsx, /src/components/footer-menu-stack.tsx
42+
1:45:23 PM [vite] (client) hmr update /src/components/app-sidebar.tsx, /src/index.css
43+
1:55:22 PM [vite] (client) hmr update /src/components/ui/sidebar.tsx, /src/index.css
44+
1:55:22 PM [vite] (client) hmr invalidate /src/components/ui/sidebar.tsx Could not Fast Refresh ("useSidebar" export is incompatible). Learn more at https://github.com/vitejs/vite-plugin-react/tree/main/packages/plugin-react#consistent-components-exports
45+
1:55:22 PM [vite] (client) hmr update /src/App.tsx, /src/components/app-sidebar.tsx, /src/components/site-header.tsx, /src/components/search-command.tsx, /src/components/nav-secondary.tsx, /src/components/nav-projects.tsx, /src/components/settings-menu.tsx, /src/components/theme-menu.tsx, /src/components/footer-menu-stack.tsx
46+
1:55:30 PM [vite] (client) hmr update /src/index.css, /src/components/theme-menu.tsx
47+
1:59:16 PM [vite] (client) hmr update /src/components/ui/sidebar.tsx, /src/index.css
48+
1:59:16 PM [vite] (client) hmr invalidate /src/components/ui/sidebar.tsx Could not Fast Refresh ("useSidebar" export is incompatible). Learn more at https://github.com/vitejs/vite-plugin-react/tree/main/packages/plugin-react#consistent-components-exports
49+
1:59:16 PM [vite] (client) hmr update /src/App.tsx, /src/components/app-sidebar.tsx, /src/components/site-header.tsx, /src/components/search-command.tsx, /src/components/nav-secondary.tsx, /src/components/nav-projects.tsx, /src/components/settings-menu.tsx, /src/components/theme-menu.tsx, /src/components/footer-menu-stack.tsx
50+
2:02:16 PM [vite] (client) hmr update /src/index.css, /src/components/theme-menu.tsx
51+
2:02:16 PM [vite] (client) hmr update /src/components/app-sidebar.tsx, /src/index.css
52+
2:02:16 PM [vite] (client) hmr update /src/App.tsx, /src/index.css
53+
2:02:16 PM [vite] (client) hmr update /src/components/theme-provider.tsx, /src/index.css
54+
2:02:58 PM [vite] (client) hmr update /src/App.tsx, /src/index.css
55+
2:02:58 PM [vite] (client) hmr update /src/components/app-sidebar.tsx, /src/index.css
56+
2:08:01 PM [vite] (client) hmr update /src/components/app-sidebar.tsx, /src/index.css
57+
2:08:21 PM [vite] (client) hmr update /src/components/app-sidebar.tsx, /src/index.css
58+
2:10:47 PM [vite] (client) hmr update /src/index.css, /src/components/theme-view.tsx
59+
2:10:47 PM [vite] (client) hmr update /src/components/app-sidebar.tsx, /src/index.css
60+
2:10:47 PM [vite] (client) hmr update /src/App.tsx, /src/index.css
61+
2:17:06 PM [vite] (client) hmr update /src/components/ui/sidebar.tsx, /src/index.css
62+
2:17:07 PM [vite] (client) hmr invalidate /src/components/ui/sidebar.tsx Could not Fast Refresh ("useSidebar" export is incompatible). Learn more at https://github.com/vitejs/vite-plugin-react/tree/main/packages/plugin-react#consistent-components-exports
63+
2:17:07 PM [vite] (client) hmr update /src/App.tsx, /src/components/app-sidebar.tsx, /src/components/site-header.tsx, /src/components/search-command.tsx, /src/components/nav-secondary.tsx, /src/components/nav-projects.tsx, /src/components/settings-menu.tsx, /src/components/footer-menu-stack.tsx
64+
2:23:13 PM [vite] (client) hmr update /src/components/ui/sidebar.tsx, /src/index.css
65+
2:23:14 PM [vite] (client) hmr invalidate /src/components/ui/sidebar.tsx Could not Fast Refresh ("useSidebar" export is incompatible). Learn more at https://github.com/vitejs/vite-plugin-react/tree/main/packages/plugin-react#consistent-components-exports
66+
2:23:14 PM [vite] (client) hmr update /src/App.tsx, /src/components/app-sidebar.tsx, /src/components/site-header.tsx, /src/components/search-command.tsx, /src/components/nav-secondary.tsx, /src/components/nav-projects.tsx, /src/components/settings-menu.tsx, /src/components/footer-menu-stack.tsx
67+
2:24:52 PM [vite] (client) hmr update /src/index.css, /src/components/gallery-view.tsx
68+
2:24:53 PM [vite] (client) hmr update /src/components/app-sidebar.tsx, /src/index.css
69+
2:24:53 PM [vite] (client) hmr update /src/components/site-header.tsx, /src/index.css
70+
2:24:54 PM [vite] (client) hmr update /src/App.tsx, /src/index.css
71+
2:25:17 PM [vite] (client) hmr update /src/index.css, /src/components/gallery-view.tsx
72+
2:25:19 PM [vite] (client) hmr invalidate /src/components/gallery-view.tsx Could not Fast Refresh ("galleryScenes" export is incompatible). Learn more at https://github.com/vitejs/vite-plugin-react/tree/main/packages/plugin-react#consistent-components-exports
73+
2:25:19 PM [vite] (client) hmr update /src/App.tsx, /src/components/app-sidebar.tsx
74+
2:27:37 PM [vite] (client) hmr update /src/components/site-header.tsx, /src/index.css
75+
2:27:52 PM [vite] (client) hmr update /src/components/site-header.tsx, /src/index.css
76+
2:28:15 PM [vite] (client) hmr update /src/components/site-header.tsx, /src/index.css
77+
2:28:15 PM [vite] (client) hmr update /src/App.tsx, /src/index.css
78+
2:31:29 PM [vite] (client) hmr update /src/index.css
79+
2:32:07 PM [vite] (client) hmr update /src/index.css
80+
2:32:48 PM [vite] (client) hmr update /src/index.css
81+
2:33:23 PM [vite] (client) hmr update /src/index.css
82+
2:33:55 PM [vite] (client) hmr update /src/index.css
83+
2:34:34 PM [vite] (client) hmr update /src/index.css

apps/agent-html/design/DESIGN.md

Lines changed: 43 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
# Design System: Agent HTML Workspace Shell
1+
# Design System: Agent HTML Operating Shell
22
**Project ID:** local-vite-react-shell
33

44
## 1. Visual Theme & Atmosphere
5-
This product uses a calm workspace-shell aesthetic rather than a marketing or editorial aesthetic.
6-
The interface should feel operational, neutral, and dependable. It is designed for scanning status,
7-
moving through tools, and staying oriented during longer sessions.
5+
This product uses a calm operating-shell aesthetic rather than a marketing or editorial aesthetic.
6+
The interface should feel operational, neutral, and dependable. It is designed for moving between
7+
working contexts, scanning structural cues, and staying oriented during longer sessions.
88

99
The emotional tone is intentionally low-drama:
1010

@@ -16,7 +16,23 @@ The emotional tone is intentionally low-drama:
1616
The left navigation rail is the strongest compositional signal.
1717
It makes the app read like a console or workbench, not a landing page.
1818

19-
## 2. Visual Character
19+
## 2. Operating Model
20+
The current product is organized around one durable shell with two operating modes:
21+
22+
- `workspace` mode for project navigation and project-backed work tabs
23+
- `gallery` mode for shell studies, scene tabs, and sidebar editor panels
24+
25+
The shell stays materially stable while the active work surface changes role.
26+
This is a mode swap, not a route-family fork.
27+
28+
The header, sidebar, and footer remain part of the same operational frame in both modes.
29+
What changes is the content they host:
30+
31+
- project tabs vs. scene tabs in the header
32+
- navigation list vs. editor panels in the sidebar body
33+
- utility footer vs. passive gallery footer content
34+
35+
## 3. Visual Character
2036
The shell is neutral-first.
2137
Light mode is paper-clean and border-led.
2238
Dark mode is control-room dark and low-glare.
@@ -26,12 +42,12 @@ The system should continue to feel:
2642
- border-defined rather than shadow-defined
2743
- utility-dense rather than airy
2844
- modular rather than narrative
29-
- consistent across screens rather than visually reinvented per route
45+
- consistent across modes rather than visually reinvented per view
3046

3147
Accent color should remain sparse and purposeful.
3248
It exists to support orientation and action priority, not to create a brand-saturated surface.
3349

34-
## 3. Typography Character
50+
## 4. Typography Character
3551
Typography should feel contemporary, technical, and restrained.
3652
It should support hierarchy through weight, scale, and contrast rather than through ornamental
3753
styling.
@@ -45,7 +61,7 @@ The preferred reading impression is:
4561

4662
Product screens should never feel like they are borrowing a marketing hero system.
4763

48-
## 4. Interaction Character
64+
## 5. Interaction Character
4965
Controls should feel compact, direct, and predictable.
5066
Hover, focus, active, invalid, and disabled states should remain clear without becoming loud.
5167

@@ -56,23 +72,27 @@ The interaction language should read as:
5672
- low ambiguity
5773
- low visual friction
5874

59-
## 5. Layout Character
75+
## 6. Layout Character
6076
Pages should inherit a clear shell hierarchy:
6177

6278
- sticky top chrome
6379
- left-side navigation spine
64-
- modular content well
80+
- mode-aware content well
6581
- responsive collapse through reflow, not redesign
6682

6783
The main content area should favor dashboard-like modules, panels, and structured sections over
6884
long, undifferentiated reading flows.
6985

70-
## 6. Spatial Philosophy
86+
In `gallery` mode, the main content area becomes a scene-preview surface rather than a standard
87+
project workspace, but it must still read as a hosted work plane inside the same shell.
88+
89+
## 7. Spatial Philosophy
7190
This product is organized around two spatial roles: `shell` and `workspace`.
7291

7392
The shell is the durable container for navigation, global actions, open-context tabs, and product
7493
orientation.
75-
The workspace is the focused surface where reading, editing, reviewing, and tool execution happen.
94+
The workspace is the focused surface where reading, editing, reviewing, scene inspection, and tool
95+
execution happen.
7696

7797
These roles must feel different:
7898

@@ -88,7 +108,7 @@ This is also why the main content well should feel inset rather than merely adja
88108
Rounded corners, margin offsets, and surface contrast should make the workspace feel placed into
89109
the shell, like a work board inside a chassis.
90110

91-
## 7. Surface Hierarchy
111+
## 8. Surface Hierarchy
92112
The product should establish hierarchy through surfaces before it relies on borders.
93113

94114
Preferred reading order:
@@ -102,14 +122,14 @@ Implications:
102122
- shell-level regions should share a base color family whenever possible
103123
- borders should organize local structure, not serve as the main tool for separating major zones
104124
- shadows should stay light and structural rather than theatrical
105-
- selected states may claim a stronger surface when they represent a focused workspace context
125+
- selected states may claim a stronger surface when they represent a focused context
106126

107127
In the current implementation, the shell reads from `background` while the main workspace surface
108128
reads from `card`.
109129

110130
The interface should feel assembled from calm planes rather than carved into many outlined boxes.
111131

112-
## 8. Interaction Philosophy
132+
## 9. Interaction Philosophy
113133
Interaction feedback should reinforce spatial roles instead of competing with them.
114134

115135
Shell interactions should stay stable and quiet.
@@ -122,13 +142,20 @@ than promotional.
122142
The goal is not visual excitement.
123143
The goal is durable orientation during long working sessions.
124144

125-
## 9. Design Philosophy
145+
In the current shell:
146+
147+
- secondary sidebar controls default to weakened text
148+
- hover may strengthen text without introducing a new background
149+
- active sidebar items should rely on background and foreground, not on heavier font weight
150+
151+
## 10. Design Philosophy
126152
The system should stay aligned with these principles:
127153

128154
- Prefer neutral surfaces over brand-colored surfaces.
129155
- Prefer thin borders over dramatic depth.
130156
- Prefer compact utility spacing over theatrical whitespace.
131157
- Prefer stable shell patterns over one-off page expression.
158+
- Prefer mode swaps inside the shell over fragmenting the product into unrelated frames.
132159
- Prefer compositional discipline over stylistic novelty.
133160

134161
Implementation rules, token structure, typography roles, layout standards, and component standards

apps/agent-html/design/README.md

Lines changed: 17 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,28 @@
11
# Design Standards
22

3-
This directory contains the working frontend design standards for the `agent-html` app.
3+
This directory contains the implementation-facing design standards for the `agent-html` app as it
4+
exists today.
5+
6+
The current product model is a dual-mode operating shell:
7+
8+
- `workspace` mode for project-backed work tabs and the main working surface
9+
- `gallery` mode for design-study scenes, scene tabs, and sidebar editor panels
10+
11+
These documents should describe the real shell, not a historical placeholder concept.
412

513
## Ownership
614

7-
This package owns the implementation-facing design rules for the app frontend.
15+
This package owns the frontend design rules for the app.
816
High-level visual philosophy is defined in [`DESIGN.md`](./DESIGN.md), while the rest of this
917
directory translates that philosophy into implementation-facing rules.
1018

1119
## Reading Order
1220

13-
1. [`DESIGN.md`](./DESIGN.md) for visual philosophy and product feel
21+
1. [`DESIGN.md`](./DESIGN.md) for product feel and operating-shell philosophy
1422
2. [`constitution.md`](./constitution.md) for global design-system law
15-
3. [`tokens.md`](./tokens.md) for token layers, naming, and consumption
23+
3. [`tokens.md`](./tokens.md) for token layers, semantic interfaces, and shell constants
1624
4. [`typography.md`](./typography.md) for text roles and hierarchy
17-
5. [`layout.md`](./layout.md) for shell, spacing, and responsive structure
25+
5. [`layout.md`](./layout.md) for shell modes, spacing, and responsive structure
1826
6. [`components.md`](./components.md) for component-family standards
1927
7. [`code-structure.md`](./code-structure.md) for implementation boundaries and review rules
2028

@@ -24,11 +32,14 @@ directory translates that philosophy into implementation-facing rules.
2432
- If the question is "what is globally allowed or forbidden," read `constitution.md`.
2533
- If the question is "where does this visual value come from," read `tokens.md`.
2634
- If the question is "what text role should this use," read `typography.md`.
27-
- If the question is "how should this page be structured," read `layout.md`.
35+
- If the question is "how should this shell or mode be structured," read `layout.md`.
2836
- If the question is "how should this component family behave," read `components.md`.
2937
- If the question is "where should this code live," read `code-structure.md`.
3038

3139
## Boundary Rule
3240

3341
Each file in this directory should answer one class of question.
3442
If a rule is fully specified in one file, other files should link to it rather than restate it.
43+
44+
When the operating shell changes, the corresponding rules in this directory should be updated in
45+
the same stream rather than left behind as aspirational design text.

0 commit comments

Comments
 (0)