Commit Graph
4 Commits
Author SHA1 Message Date
haelyra 6edc259654 fix: preserve UI Canvas edits through delivery and reload 2026-11-19 17:40:32 -05:00
haelyra b5ff79c12f feat(ui-canvas): integrate hand-editable preview with safe resume and exports 2026-11-19 15:33:44 -05:00
haelyra 1da04b1d59 fix(ui-canvas): address review findings on gestures, exports, and replay
- Editor: pass the finished gesture to endResize/endDrag (mouseup cleared it
  first, so handle resize, reorder, and Alt-drag threw on release); compute
  the drop target on the move that starts a drag; report border-radius from
  the four real corner properties.
- Exports: refuse feedback for an ended session before writing any file; give
  each Apply batch its own <name>.apply-<batch>.* pair so a later batch never
  rewrites an earlier queued snapshot. Finish keeps <name>.edited.html.
- Replay: applied edits keep replaying on reload until the artifact changes
  on disk, instead of vanishing as soon as the request is queued.
- Stop hook: an ended UI session still delivers an undelivered Save and Finish.
- Shell: clamp viewports from the bootstrap and sessionStorage; `pending`
  next_step points at each session's resume command.
- Split ui.js (inspector.js, ui-css.js), editor.js (editor-gestures.js), and
  the UI routes out of plan-canvas/server.js (ui-canvas/server-routes.js) to
  keep every file under 800 lines.
- Docs: state the server-side Host/Origin checks behind the sandbox claim.
- Remove two unreferenced captured-export fixtures (one held a local path).
2026-10-25 19:22:17 -04:00
haelyra 283c16aa4e feat(ui-canvas): add hand-editable UI mockup canvas with slider inspector
Add UI Canvas: an agent writes a self-contained HTML mockup, the human edits
it directly in the browser (select, resize, reorder, nudge, edit text,
remove, restyle), checks mobile, desktop, and exact viewports, chats with the
agent, and clicks Save and Finish to export the edited markup and an edit log.

- skills/ui-canvas, commands/ui-canvas.md, bin ecc-ui-canvas
  (scripts/ui-canvas.js), a profile over the Plan Canvas server via a
  session mode of 'ui'.
- scripts/lib/ui-canvas/{editor,feedback,ui,fields}.js: in-page editor,
  feedback normalization, browser shell, and inspector field helpers.
- Inspector: grouped slider rows (size, fill, text, spacing, border,
  effects); double-click any value to type it, sanitized and clamped before
  it reaches the mockup; HSL plus alpha color sliders; per-property clear.
- ECC green accent on near-black, no gradient branding; selection overlay
  is green.
- Plan Canvas: agent identity in presence, mode-aware server and hooks.

Editing conventions credit VisBug and Onlook; the review loop credits
lavish-axi by @kunchenguid.
2026-10-25 18:21:28 -04:00