Skip to content

Commit f4c1fa4

Browse files
committed
set label cursor to text only when the item is selected
1 parent ed59ea4 commit f4c1fa4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/renderer/tree/views.cljs

+2-2
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@
4848

4949
(defn item-label
5050
[el]
51-
(let [{:keys [id label visible tag]} el
51+
(let [{:keys [id label visible selected tag]} el
5252
properties (element.hierarchy/properties tag)
5353
tag-label (or (:label properties) (str/capitalize (name tag)))]
5454
(ra/with-let [edit-mode? (ra/atom false)]
@@ -67,7 +67,7 @@
6767
[:div.truncate
6868
{:class [(when-not visible "opacity-60")
6969
(when (= :svg tag) "font-bold")]
70-
:style {:cursor "text"}
70+
:style {:cursor (when selected "text")}
7171
:on-double-click (fn [e]
7272
(.stopPropagation e)
7373
(reset! edit-mode? true))}

0 commit comments

Comments
 (0)