From 5d3c8fbada2e1fed32d6b93fafe24ba6d6a4ad4b Mon Sep 17 00:00:00 2001 From: chihlasm Date: Fri, 13 Mar 2026 17:06:09 -0400 Subject: [PATCH] =?UTF-8?q?docs:=20add=20lesson=2058=20=E2=80=94=20scriptG?= =?UTF-8?q?eneratorStore.generate()=20onClick=20footgun?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Sonnet 4.6 --- CLAUDE.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CLAUDE.md b/CLAUDE.md index 4c8a0e44..f16fd884 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -408,6 +408,8 @@ navigate(`/trees/${newTree.id}/edit`) **57. Node field priority for display/context:** Nodes use different label fields by type — procedural steps use `title`+`description`, decision nodes use `question`, action/solution nodes use `title`. When reading a node's label generically, check: `title` → `question` → `description` → `content` → `label`. See `copilot_service.py` `_build_flow_context()`. +**58. `scriptGeneratorStore.generate()` has an optional `sessionId` param:** `generate(sessionId?: string)` — do NOT pass it as a bare `onClick={generate}` handler (TypeScript error: MouseEvent not assignable to string). Always wrap: `onClick={() => generate()}`. + --- ## RBAC & Permissions