From dc813732c3bc5152c463a87405ca8ba15daffb7f Mon Sep 17 00:00:00 2001 From: Eva Date: Tue, 29 Aug 2023 08:15:38 +0200 Subject: [PATCH] :bug: Fix tooltip on toggle visibility and toggle lock buttons --- CHANGES.md | 1 + frontend/src/app/main/ui/workspace/sidebar/layer_item.cljs | 7 +++++++ 2 files changed, 8 insertions(+) diff --git a/CHANGES.md b/CHANGES.md index e9e98fa3a..b84fa73fb 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -12,6 +12,7 @@ - Fix unexpected output on get-page rpc method when invalid object-id is provided [Github #3546](https://github.com/penpot/penpot/issues/3546) - Fix Invalid files amount after moving file from Project to Drafts [Taiga #5638](https://tree.taiga.io/project/penpot/us/5638) - Fix deleted pages comments shown in right sidebar [Taiga #5648](https://tree.taiga.io/project/penpot/us/5648) +- Fix tooltip on toggle visibility and toggle lock buttons [Taiga #5141](https://tree.taiga.io/project/penpot/issue/5141) ## 1.19.1 diff --git a/frontend/src/app/main/ui/workspace/sidebar/layer_item.cljs b/frontend/src/app/main/ui/workspace/sidebar/layer_item.cljs index b4cc9c145..6fc02c876 100644 --- a/frontend/src/app/main/ui/workspace/sidebar/layer_item.cljs +++ b/frontend/src/app/main/ui/workspace/sidebar/layer_item.cljs @@ -22,6 +22,7 @@ [app.main.ui.icons :as i] [app.main.ui.workspace.sidebar.layer-name :refer [layer-name]] [app.util.dom :as dom] + [app.util.i18n :refer [tr]] [app.util.keyboard :as kbd] [app.util.timers :as ts] [beicon.core :as rx] @@ -269,10 +270,16 @@ (css :selected) (:blocked item))} [:button {:class (dom/classnames (css :toggle-element) true (css :selected) (:hidden item)) + :title (if (:hidden item) + (tr "workspace.shape.menu.show") + (tr "workspace.shape.menu.hide")) :on-click toggle-visibility} (if (:hidden item) i/hide-refactor i/shown-refactor)] [:button {:class (dom/classnames (css :block-element) true (css :selected) (:blocked item)) + :title (if (:blocked item) + (tr "workspace.shape.menu.unlock") + (tr "workspace.shape.menu.lock")) :on-click toggle-blocking} (if (:blocked item) i/lock-refactor i/unlock-refactor)]]]] (when (and (:shapes item) expanded?)