From 571e80d9754370fb30dc88e73b7b36f10edbc541 Mon Sep 17 00:00:00 2001 From: Olive Vaughn Date: Sun, 11 Oct 2026 00:07:34 -0400 Subject: [PATCH] - and = are on the bar for a drawing, not a lane With a lane's row selected they lengthened the whole lane, which is not what holding a drawing longer means. They show for a cel or a symbol, and not for the row that places a lane. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_011FLuCjp9kNH6ovwJVXSbq9 --- frontend/src/arthur/ui/timeline.cljs | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/frontend/src/arthur/ui/timeline.cljs b/frontend/src/arthur/ui/timeline.cljs index 0d6450c..72eac76 100644 --- a/frontend/src/arthur/ui/timeline.cljs +++ b/frontend/src/arthur/ui/timeline.cljs @@ -540,12 +540,23 @@ [delta] (fn [db] (when-let [p (ui/span-path db)] [::ui/slide p delta :out true]))) +(defn- places-lane? + "Does the row at `path` in the open symbol place a lane? Holding a lane + longer is not lengthening a drawing, which is what = and − are on the bar for." + [db path] + (let [{document :clip st :store} (store/entry (:clip/current db)) + f (ui/editing-frame db document) + host (nest/inside document st (get-in db [:ui :open]) (pop path) f) + n (get-in document [:symbols (:sid host) :nodes (peek path)])] + (boolean (some->> (node/source n) (clip/symbol document) symbol/lane?)))) + (rf/reg-sub ::here ;; Which of the toolbar's commands mean something for the selection right now. (fn [db _] - {:lane? (some? (ui/lane-here db)) - :span? (some? (ui/span-path db))})) + (let [p (ui/span-path db)] + {:lane? (some? (ui/lane-here db)) + :span? (and (some? p) (not (places-lane? db p)))}))) ;; --------------------------------------------------------------------------- ;; the panes