From 63042b284d8b069f42787fb9fa626c1a4c453220 Mon Sep 17 00:00:00 2001
From: th
Date: Mon, 20 Apr 2026 14:37:40 +0200
Subject: [PATCH] 0.5.5: inline lock toggle, proper lock indentation
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
- Track lock becomes a small inline icon toggle sitting next to the
track label, replacing the static badge and removing the context
menu's lock/unlock entry.
- Locked tracks are fully inert: the lane and name have pointer-events
disabled, only the lock button itself stays clickable. The pile of
hover-neutralizing CSS rules is gone.
- Lock button is icon-only (no background/border box) and swaps to the
opposite icon on hover (filled unlock when hovering a locked track,
so the click affordance is obvious).
- Locked tracks in groups keep their indentation — the drag-handle
switches from display:none to visibility:hidden so the reserved
space still aligns with unlocked sibling layers.
Co-Authored-By: Claude Opus 4.7 (1M context)
---
package.json | 2 +-
src/components/Timeline.vue | 208 +++++++++++++++++++++++-------------
src/version.ts | 2 +-
3 files changed, 134 insertions(+), 78 deletions(-)
diff --git a/package.json b/package.json
index c90e3e3..f9bd2f2 100644
--- a/package.json
+++ b/package.json
@@ -1,7 +1,7 @@
{
"name": "animatr",
"private": true,
- "version": "0.5.4",
+ "version": "0.5.5",
"type": "module",
"scripts": {
"dev": "vite",
diff --git a/src/components/Timeline.vue b/src/components/Timeline.vue
index 2721bef..99a5bb2 100644
--- a/src/components/Timeline.vue
+++ b/src/components/Timeline.vue
@@ -1338,12 +1338,6 @@ function onClipTrackContextMenu(e: MouseEvent, clipTrackId: string) {
}
}
-function toggleLocked() {
- if (!trackMenu.value) return
- store.setTrackLocked(trackMenu.value.trackId, !trackMenu.value.locked)
- trackMenu.value = null
-}
-
function applyTrackColor(color: string | null) {
if (!trackMenu.value) return
store.setTrackColor(trackMenu.value.trackId, color)
@@ -1613,18 +1607,21 @@ onBeforeUnmount(() => {
parent: track.isParent,
sub: !track.isParent,
}"
- :draggable="track.isParent"
- @click="store.selectLayer(track.layerId)"
- @contextmenu="track.isParent ? onTrackContextMenu($event, track.layerId) : null"
- @dragstart="track.isParent ? onTrackDragStart($event, track.layerId) : null"
+ :draggable="track.isParent && !track.layer.locked"
+ @click="!track.layer.locked ? store.selectLayer(track.layerId) : null"
+ @contextmenu="
+ track.isParent && !track.layer.locked
+ ? onTrackContextMenu($event, track.layerId)
+ : null
+ "
+ @dragstart="
+ track.isParent && !track.layer.locked
+ ? onTrackDragStart($event, track.layerId)
+ : null
+ "
@dragend="onTrackDragEnd"
>
-
{
:class="{ 'mask-negative': track.layer.maskMode === 'negative' }"
/>
↳
- {{ track.label }}
+ {{ track.label }}
+
{
>
-
- {{ track.name }}
+ {{ track.name }}
+
{
-
-
+
|