macro-clips slice 4c: button creation in sidebar + drag to clip tracks
- store.seedDefaultButtonClip(name) adds a button clip with a single shared rect asset and four pre-populated state stacks in blue shades (normal/hover/pressed/disabled). Layer name 'Face' is consistent so transitions can later pair layers by name. - AssetSidebar gets a Buttons section below Clips: create via prompt, rename, delete, drag-to-track. Drag uses a new dataTransfer type 'application/x-animatr-button-clip' to keep it distinct from animation-clip drops. - Timeline clip-lane drop accepts both types and dispatches addClipInstance / addButtonInstance accordingly; the new-track drop zone handles both too, so dragging a button to an empty area creates a fresh clip track + instance in one step. - i18n for the sidebar strings and three dialogs. - test covers seedDefaultButtonClip: four populated states, shared asset, consistent layer name. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
fb58cd18f7
commit
024883943b
5 files changed
+193
-6
No files matched your search
@@ -95,6 +95,25 @@ export const en = {
|
||||
message: 'The clip and all placed instances will be removed.',
|
||||
confirm: 'Delete',
|
||||
},
|
||||
buttons: 'Buttons',
|
||||
buttonSubtitle: 'Button · 4 states',
|
||||
noButtons: 'No buttons yet',
|
||||
createButtonTooltip: 'Create new button',
|
||||
newButtonDialog: {
|
||||
title: 'New button',
|
||||
message: 'Button name:',
|
||||
default: 'Button',
|
||||
confirm: 'Create',
|
||||
},
|
||||
renameButtonDialog: {
|
||||
title: 'Rename button',
|
||||
confirm: 'Apply',
|
||||
},
|
||||
deleteButtonDialog: {
|
||||
title: 'Delete button?',
|
||||
message: 'The button and all placed instances will be removed.',
|
||||
confirm: 'Delete',
|
||||
},
|
||||
},
|
||||
|
||||
properties: {
|
||||
|
||||
Reference in new issue
Block a user