Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
cf9fa38
docs: add web UI token foundation design spec
dubadub Sep 4, 2026
90c7009
docs: add web UI token foundation implementation plan
dubadub Sep 4, 2026
2901588
feat(ui): add token layer and component vocabulary
dubadub Sep 4, 2026
b1b64df
fix(ui): tighten token foundation after review
dubadub Sep 4, 2026
8cc69ab
refactor(ui): move the nav card and search onto tokens
dubadub Sep 4, 2026
efb561d
fix(ui): keep overflow menu highlight and brand mark legible
dubadub Sep 4, 2026
e66afc1
refactor(ui): recipes index on tokens, sorter reads data-name
dubadub Sep 4, 2026
541f539
test(ui): tolerate identical seed mtimes in sort spec
dubadub Sep 4, 2026
af83ef6
fix(ui): recipes index review fixes
dubadub Sep 4, 2026
836ea30
test(ui): assert the sorter survives corrupt saved state
dubadub Sep 4, 2026
65e6a1f
refactor(ui): shared scripts on tokens, export adjustScale
dubadub Sep 4, 2026
4e4240b
refactor(ui): recipe page on tokens with scale stepper
dubadub Sep 4, 2026
108359b
fix(ui): build the scale URL safely and guard bad scale values
dubadub Sep 5, 2026
c421235
refactor(ui): shopping list on tokens
dubadub Sep 5, 2026
fd4f2a7
refactor(ui): pantry on tokens, stock state as one class
dubadub Sep 5, 2026
3ca61d1
fix(ui): pantry stock colour, compact inline buttons, smaller row icons
dubadub Sep 5, 2026
bd260a6
refactor(ui): menu page on tokens
dubadub Sep 5, 2026
015598d
refactor(ui): preferences on tokens, toggles expose data-active
dubadub Sep 5, 2026
944972c
fix(ui): safe scale navigation on menus, aria-pressed on preference t…
dubadub Sep 5, 2026
4fade5b
refactor(ui): editor and new-recipe form on tokens
dubadub Sep 5, 2026
7bc956c
refactor(ui): API docs and error page on tokens
dubadub Sep 5, 2026
1d310a4
fix(ui): show the new-recipe error border, ring its input, compact AP…
dubadub Sep 5, 2026
fcadc28
refactor(ui): delete the dark-mode override block
dubadub Sep 5, 2026
c5aa9c2
fix(ui): keep icon-only actions below lg, tidy print rules and docs
dubadub Sep 5, 2026
16293bb
fix(ui): white text on filled buttons via a darker accent fill
dubadub Sep 6, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 16 additions & 12 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -186,9 +186,9 @@ The web UI uses server-side rendering with Askama templates:

### Styling
- Tailwind CSS for utility-first styling
- Custom components defined in `static/css/input.css`
- Custom components defined in `static/css/components.css`
- Compiled CSS output in `static/css/output.css`
- Configuration in `tailwind.config.js`
- Tailwind is configured in `static/css/input.css` (`@source`, `@custom-variant`, `@theme`); components live in `static/css/components.css`

### Key Templates
- `base.html` - Common layout with navigation and search
Expand All @@ -206,14 +206,18 @@ The web UI uses server-side rendering with Askama templates:
- **Responsive Design**: Mobile-friendly layout with Tailwind

### CSS Component Classes
Custom Tailwind components for consistent styling:
- `.recipe-card` - Recipe cards with gradient top border
- `.ingredient-badge` - Orange gradient badges for ingredients
- `.cookware-badge` - Green gradient badges for cookware
- `.timer-badge` - Red gradient badges for timers
- `.metadata-pill` - Clean outline badges for metadata
- `.nav-pill` - Navigation items with hover effects
- `.step-number` - Circular step numbers with gradient
Component classes live in `static/css/components.css` and resolve every colour through the tokens in `static/css/input.css`:
- `.card` / `.card-head` - Bordered surface with hairline and 6px radius
- `.btn`, `.btn-primary`, `.btn-danger`, `.btn-sm` - 40px controls (32px compact); one accent-filled primary per view
- `.icon-btn` - 36px icon-only control
- `.nav-card`, `.nav-pill`, `.menu-item` - Navigation card, pills, and small-screen menu rows
- `.recipe-card`, `.recipe-card-icon`, `.recipe-card-title` - Index cards with a flat icon disc
- `.ingredient-badge`, `.cookware-badge`, `.timer-badge` - Inline recipe entities (tint, dotted underline, chip)
- `.metadata-pill`, `.tag` - Neutral bordered pills
- `.step-box`, `.step-number`, `.step-body`, `.step-refs` - Boxed recipe steps
- `.ingredient-row`, `.row`, `.row-value`, `.row-note` - List rows
- `.pantry-item`, `.pantry-actions`, `.item-status-dot` - Pantry blocks and stock state
- `.stepper`, `.select`, `.search-input` - Form controls

## Testing Approach

Expand Down Expand Up @@ -260,10 +264,10 @@ Output formatting is centralized in `src/util/` modules. Each format has its own
4. Add route in the UI router

### Modifying Styles
1. Edit component classes in `static/css/input.css`
1. Edit component classes in `static/css/components.css`
2. Run `make css` or `npm run build-css` to compile
3. For development, use `npm run watch-css` for auto-rebuild
4. Custom colors and utilities can be added to `tailwind.config.js`
4. Custom colors and utilities can be added to `static/css/input.css` (`@theme`) and component classes to `static/css/components.css`

### Frontend Development Workflow
1. Install dependencies: `npm install`
Expand Down
6 changes: 3 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -142,13 +142,13 @@ Custom component classes:
│ └── recipe.html # Single recipe view
├── static/ # Static assets
│ └── css/
│ ├── input.css # Tailwind input with custom classes
│ └── output.css # Compiled CSS (generated)
│ ├── input.css # Tailwind config (@source, @custom-variant, @theme) and tokens
│ ├── components.css # Component classes (.card, .btn, .nav-pill, ...)
│ └── output.css # Compiled CSS (generated)
├── src/server/
│ ├── mod.rs # Server setup and routing
│ ├── ui.rs # UI request handlers
│ └── templates.rs # Template data structures
├── tailwind.config.js # Tailwind configuration
└── package.json # NPM dependencies
```

Expand Down
Loading