Skip to content

Commit 6ad3b20

Browse files
ALai57claude
andcommitted
docs(recipes): update shape comments for sectioned RecipeContent
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
1 parent dfaffae commit 6ad3b20

2 files changed

Lines changed: 9 additions & 4 deletions

File tree

plans/2026-07-10-recipes-feature/PLAN.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# Recipes Feature — Scrape, Edit, Search, Share
22

3+
> **Superseded in part:** `RecipeContent` was reshaped to paired sections with
4+
> steps-as-data (no `instructions-html`) before first release — see
5+
> `plans/2026-07-11-recipe-sections/DESIGN.md`. Shape details below are historical.
6+
37
> **Implementation status (2026-07-11)** — built on branch `plans/recipes-feature` in both repos.
48
> **Backend (kaleidoscope), done + tested:** migration (5 tables, one-per-group + composite-tenant constraints), `api/access` shared visibility, `api/recipes` (CRUD, labels/groups, one-per-group validation, ingredient search, audiences), `api/recipe_scraper` (SSRF-guarded fetch, JSON-LD, LLM fallback), `http_api/recipes` routes + ACL. Full suite green (196 tests). Phases 1, 3, 4, 5 complete.
59
> **Frontend (kaleidoscope-ui), done + tested:** `types/recipe`, `api/recipes` (+13 tests), `LabelPicker` (+7 tests), `RecipesPage`/`RecipePage`/`RecipeEditorPage` (+ list-filter and scrape→save tests), routes/nav/manager card. Typecheck + lint clean; 24 recipe tests green. Phase 2 complete.

resources/migrations/20260711000001-add-recipes.up.sql

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
11
-- Recipes: scrape/edit/search/share domain. See plans/2026-07-10-recipes-feature/PLAN.md.
22
--
33
-- Identity is a single opaque UUID; recipe_url is the address (slug), not a
4-
-- second identity. Recipe content (title, ingredients, instructions, servings,
5-
-- times) is one JSONB value shape; `content` is the current recipe and
6-
-- `original_content` is the immutable scrape — same shape, cannot drift.
4+
-- second identity. Recipe content is one JSONB value shape: {title, sections
5+
-- [{name?, ingredients [string], steps [string]}], servings?, times?} (see
6+
-- plans/2026-07-11-recipe-sections/DESIGN.md); `content` is the current recipe
7+
-- and `original_content` is the immutable scrape — same shape, cannot drift.
78
CREATE TABLE recipes (
89
id UUID DEFAULT gen_random_uuid() PRIMARY KEY,
910
recipe_url VARCHAR NOT NULL, -- address (slug)
1011
hostname VARCHAR NOT NULL, -- tenant
11-
content JSONB NOT NULL, -- {title, ingredients[], instructions_html, servings?, prep_time_minutes?, cook_time_minutes?}
12+
content JSONB NOT NULL, -- {title, sections[{name?, ingredients[], steps[]}], servings?, prep_time_minutes?, cook_time_minutes?}
1213
original_content JSONB, -- immutable scrape; same shape as `content`
1314
source_url VARCHAR,
1415
author VARCHAR,

0 commit comments

Comments
 (0)