Editor's Path Properties has 'Path Properties' but no 'Path metadata' (created at, modified at, author) — user wanting to know when a path was created has no timestamp display #377

Closed
opened 2026-10-04 03:59:53 +00:00 by Mark · 1 comment
Owner

Closed via commit 4f41537 on main. The Path Properties section now has Created + Modified rows that surface path metadata via formatRelativeTime; legacy paths render an em-dash fallback. See the issue-comment above for the full scope of the change.

Closed via commit 4f41537 on main. The Path Properties section now has Created + Modified rows that surface path metadata via formatRelativeTime; legacy paths render an em-dash fallback. See the issue-comment above for the full scope of the change.
Author
Owner

Fixed in commit 4f41537.

Shipped (#377):

  • createdAt and modifiedAt (both optional) added to StitchPath
  • Editor stamps createdAt = modifiedAt = Date.now() in handleFinishPath and draftsToStitchPaths (SVG import)
  • New updatePaths helper in Editor centralizes history-push + modifiedAt-stamping for the panel-driven mutation handlers (stitch type / density / color / satin width / pull comp / fill angle / fill spacing / fabric / stitch direction / lock / color lock / favorite / background / closed / attachments / transform / etc.). The helper short-circuits no-op updates so no spurious modifiedAt stamps land on re-renders, and live slider ticks (density / satin-width) use pushHistory: false to keep the existing one-undo-per-drag contract.
  • Path Info in EditorRightPanel now renders two new rows "Created" and "Modified" using the existing path-info-<field>-<id> data-testid pattern. Format helper is formatRelativeTime from the workspace RightPanel (#322) — single source of truth for time-bucket labels.
  • Legacy paths (no metadata fields) render em-dash so the user is never misled by a fabricated timestamp.

Tests: 6 new cases in src/components/editor/issue-377.test.tsx pin the panel render contract (presence of rows, time-bucket output, em-dash fallback, divergent timestamps, one-sided legacy). All 6 pass; 91 related tests pass; full Editor + pages suite passes.

Fixed in commit 4f41537. Shipped (#377): - `createdAt` and `modifiedAt` (both optional) added to StitchPath - Editor stamps `createdAt = modifiedAt = Date.now()` in `handleFinishPath` and `draftsToStitchPaths` (SVG import) - New `updatePaths` helper in Editor centralizes history-push + modifiedAt-stamping for the panel-driven mutation handlers (stitch type / density / color / satin width / pull comp / fill angle / fill spacing / fabric / stitch direction / lock / color lock / favorite / background / closed / attachments / transform / etc.). The helper short-circuits no-op updates so no spurious modifiedAt stamps land on re-renders, and live slider ticks (density / satin-width) use `pushHistory: false` to keep the existing one-undo-per-drag contract. - Path Info in EditorRightPanel now renders two new rows "Created" and "Modified" using the existing `path-info-<field>-<id>` data-testid pattern. Format helper is `formatRelativeTime` from the workspace RightPanel (#322) — single source of truth for time-bucket labels. - Legacy paths (no metadata fields) render em-dash so the user is never misled by a fabricated timestamp. Tests: 6 new cases in `src/components/editor/issue-377.test.tsx` pin the panel render contract (presence of rows, time-bucket output, em-dash fallback, divergent timestamps, one-sided legacy). All 6 pass; 91 related tests pass; full Editor + pages suite passes.
Mark closed this issue 2026-10-05 17:24:15 +00:00
Sign in to join this conversation.
No description provided.