feat(pages): on-page editor with canvas, side panel, section tools, undo and refusals
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EFUzfiCVCgCVJZq4NDEqZs
This commit is contained in:
1 parent
d31661fd3e
commit
5f2ddf90ba
10 files changed
+660
-121
No files matched your search
@@ -25,20 +25,20 @@ Design: `design.md`. Every task is TDD. Work is serial in the main session, with
|
||||
- [x] 2.1 `PageCanvas`: the frame, the Desktop view (1280 px scaled) and the Phone view (390 px), live updates from the draft, and links and buttons inert.
|
||||
- [x] 2.2 Edit-mode hooks in `CmsBlocks`: `EditContext`, `EditableText` for every plain text field with its server limit, image spots, `Section` outline and `data-index`. Public rendering stays unchanged: the existing `CmsBlocks*.test.tsx` stay green.
|
||||
- [x] 2.3 Rich text in place: `RichTextEditor` bare mode with a floating toolbar (test: an unsafe link is refused with a message).
|
||||
- [ ] 2.4 Custom HTML on the canvas: the saved-draft frame, the "Save to update" mark, and a reload after save.
|
||||
- [x] 2.4 Custom HTML on the canvas: the saved-draft frame, the "Save to update" mark, and a reload after save.
|
||||
|
||||
## 3. Editor
|
||||
|
||||
- [ ] 3.1 `VisualEditor` layout:
|
||||
- [x] 3.1 `VisualEditor` layout:
|
||||
- The top bar: title, status, Desktop and Phone, undo and redo, Duplicate, Preview, View page, Delete, Save.
|
||||
- The change 2 banner with Publish changes and Discard changes.
|
||||
- The side panel: `BlockFields` for the selected block, or the page settings.
|
||||
- The editor is chosen by width, 1024 px and up.
|
||||
- [ ] 3.2 Selection and section actions: select, toolbar (up, down, duplicate, delete), "Add section" between sections and at the end, native drag reorder (reorder function unit-tested), and the keyboard path.
|
||||
- [ ] 3.3 Undo and redo: history of 50, one step per field edit and per action, Ctrl+Z and Ctrl+Shift+Z, kept across saves.
|
||||
- [ ] 3.4 Refusals on the canvas: select, outline, scroll into view, message at the panel field; page-field refusals in the page settings.
|
||||
- [ ] 3.5 Templates (`?template=`) and Duplicate (`?from=`) open in the visual editor.
|
||||
- [ ] 3.6 Labels in `defaultMessages.ts` and `zh_CN.seed.json`, `npm run i18n:sql`, `sql/01-visual-editor-labels.sql`, `sql/99-rollback.sql`.
|
||||
- [x] 3.2 Selection and section actions: select, toolbar (up, down, duplicate, delete), "Add section" between sections and at the end, native drag reorder (reorder function unit-tested), and the keyboard path.
|
||||
- [x] 3.3 Undo and redo: history of 50, one step per field edit and per action, Ctrl+Z and Ctrl+Shift+Z, kept across saves.
|
||||
- [x] 3.4 Refusals on the canvas: select, outline, scroll into view, message at the panel field; page-field refusals in the page settings.
|
||||
- [x] 3.5 Templates (`?template=`) and Duplicate (`?from=`) open in the visual editor.
|
||||
- [x] 3.6 Labels in `defaultMessages.ts` and `zh_CN.seed.json`, `npm run i18n:sql`, `sql/01-visual-editor-labels.sql`, `sql/99-rollback.sql`.
|
||||
|
||||
## 4. Release
|
||||
|
||||
|
||||
Reference in new issue
Block a user