- projects/page.tsx: add aria-label="Import project" to the import
button so screen readers have a name when the visible label is
hidden on small screens.
- project-manager.ts: tighten import schema validation — accept only
formatVersion === SUPPORTED_FORMAT_VERSION (1), reject non-string
metadata.id/name (previously a numeric value passed the truthy
check), require non-empty trimmed strings, and reject arrays/null
payloads. Constant shared with the export path.
- storage/service.ts: await ensureMigrations() at the top of
importProjectFromJSON so an import can't race with the memoized
migration run and land in a half-migrated store.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- Add shortcut hints to toolbar buttons via tooltip text
- Integrate useKeyboardShortcutsHelp hook for consistent shortcut retrieval
- Timeline toolbar: split, duplicate, delete, snapping, bookmark buttons
- Preview toolbar: play/pause button
- Format: tooltip text appended with '(Key)' or '(Key1 or Key2)'
- Gracefully handle actions without defined shortcuts
The freeform mask was assembled on every getMaskDefinition("freeform") call,
re-spreading params and injecting a wrong SquareIcon placeholder, with a type
cast to suppress the structural mismatch. Root cause: MasksRegistry was keyed
on BuiltinMaskType, so freeform had no entry.
- Re-key MasksRegistry from BuiltinMaskType to MaskType
- Register freeform alongside builtins in registerDefaultMasks, with
PenToolAddIcon as its menu icon
- getMaskDefinition and getMaskDefinitionsForMenu become plain registry
lookups with no branching, no manual spreading, no cast
- Rename RegisteredBuiltinMaskDefinition to RegisteredMaskDefinition and
tighten computeParamUpdate return type to Partial<BaseMaskParams>
Co-authored-by: Cursor <cursoragent@cursor.com>
The { kind: "tangent" } MaskHandleId variant was never constructed — neither
getFreeformDisplayHandles nor any other code ever produced a tangent handle
object. The in/out control-arm branches in computeFreeformParamUpdate, the
tangent case in maskHandleIdKey, and the CUSTOM_MASK_TANGENT_SIZE rendering
path in mask-handles.tsx were all unreachable. Removed all four dead paths
and removed "tangent" from MaskHandleKind.
Co-authored-by: Cursor <cursoragent@cursor.com>
- Remove dead ternary in getPreferredEdges (always returned undefined; the
all-false object was never reached by Object.values().some(Boolean))
- Document why drawWithFeather descriptors zero the feather field in the
compositor (analytical renderer handles softness itself; zeroing prevents
a second JFA feather pass)
- Remove legacyType from V30→V31 migration (not consumed anywhere; a
down-migration can map type:"freeform" back to "custom" directly)
- Add V30→V31 test coverage: skip-guard branches, freeform passthrough,
elements without a masks array
- Add snap tests for vertical-edge (bottom) and uniform-scale handle paths
Co-authored-by: Cursor <cursoragent@cursor.com>
Move timeline and preview gestures into dedicated controllers so hooks stay thin around editor state and DOM events.
This also routes drag and playback synchronization through manager APIs and reuses persistent wasm surfaces so scrubbing, seeking, and preview rendering stay in sync.
Made-with: Cursor