Overhaul extraction pipeline with new TradeItem model, conversation flow, and dedicated extraction endpoint. Add sidebar navigation with NavMenu component and landing page. Introduce few-shot prompting service and tests. Add prompt settings and email upload specs. Update OpenSpec tooling with improved export-spec and extract-feature commands. Archive completed changes and export full specs. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
43 lines
2.2 KiB
Markdown
43 lines
2.2 KiB
Markdown
## Context
|
|
|
|
The app currently uses a minimal MudLayout with just MudAppBar (Dense) + MudMainContent, and a single page at `/`. To support multiple pages, we need standard MudBlazor navigation: a collapsible MudDrawer with a NavMenu component.
|
|
|
|
## Goals / Non-Goals
|
|
|
|
**Goals:**
|
|
- Add collapsible MudDrawer with hamburger toggle in the AppBar
|
|
- Create a NavMenu component with a "Sales Assistant" link
|
|
- Move chat page to `/sales-assistant` route
|
|
- Maintain the Blazor tutorial style with inline comments
|
|
|
|
**Non-Goals:**
|
|
- Adding multiple pages beyond the existing chat (just the navigation structure)
|
|
- Changing the AppBar from Dense to regular
|
|
- Adding a default landing page (redirect `/` → `/sales-assistant` instead)
|
|
|
|
## Decisions
|
|
|
|
### MudDrawer configuration
|
|
- **Variant**: `DrawerVariant.Mini` — collapses to icon-width rather than fully hiding, so the user always sees the nav rail
|
|
- **Alternative considered**: `DrawerVariant.Responsive` — auto-hides on small screens. Rejected because Mini gives a more consistent desktop experience and the app is desktop-first.
|
|
- **ClipMode**: `DrawerClipMode.Always` — drawer sits below the AppBar, not beside it
|
|
|
|
### NavMenu as separate component
|
|
- Extract `NavMenu.razor` into `Layout/` alongside MainLayout rather than inlining nav links
|
|
- This is standard Blazor project structure and keeps MainLayout focused on shell layout
|
|
- The NavMenu will use `MudNavMenu` with `MudNavLink` items
|
|
|
|
### Route change: `/` → `/sales-assistant`
|
|
- The chat page moves to `/sales-assistant` to match navigation naming
|
|
- Add a redirect component at `/` that navigates to `/sales-assistant` on init
|
|
- This avoids a blank landing page while keeping the URL structure clean
|
|
|
|
### AppBar hamburger toggle
|
|
- Add `MudIconButton` with `Icons.Material.Filled.Menu` as the first element in the AppBar
|
|
- Toggle `_drawerOpen` bool that binds to `MudDrawer.Open`
|
|
|
|
## Risks / Trade-offs
|
|
|
|
- **Chat container height**: Currently uses `calc(100vh - 48px)` assuming Dense AppBar (48px). MudDrawer with ClipMode.Always doesn't affect vertical calc, so this should remain correct. Verify after implementation.
|
|
- **Breaking bookmarks**: Anyone bookmarking `/` will need to update to `/sales-assistant`. Mitigated by the redirect at `/`.
|