mirror of
https://github.com/penpot/penpot.git
synced 2025-05-18 14:26:11 +02:00
✨ Add set name to tokens panel list
This commit is contained in:
parent
aa9f5fc18f
commit
ccbb233866
2 changed files with 6 additions and 2 deletions
|
@ -8,6 +8,7 @@
|
||||||
(:require-macros [app.main.style :as stl])
|
(:require-macros [app.main.style :as stl])
|
||||||
(:require
|
(:require
|
||||||
[app.common.data :as d]
|
[app.common.data :as d]
|
||||||
|
[app.common.data.macros :as dm]
|
||||||
[app.common.types.tokens-lib :as ctob]
|
[app.common.types.tokens-lib :as ctob]
|
||||||
[app.main.data.modal :as modal]
|
[app.main.data.modal :as modal]
|
||||||
[app.main.data.notifications :as ntf]
|
[app.main.data.notifications :as ntf]
|
||||||
|
@ -243,13 +244,16 @@
|
||||||
|
|
||||||
selected-token-set-tokens (mf/deref refs/workspace-selected-token-set-tokens)
|
selected-token-set-tokens (mf/deref refs/workspace-selected-token-set-tokens)
|
||||||
|
|
||||||
|
selected-token-set-path (mf/deref refs/workspace-selected-token-set-path)
|
||||||
|
|
||||||
token-groups (mf/with-memo [tokens selected-token-set-tokens]
|
token-groups (mf/with-memo [tokens selected-token-set-tokens]
|
||||||
(-> (select-keys tokens (keys selected-token-set-tokens))
|
(-> (select-keys tokens (keys selected-token-set-tokens))
|
||||||
(sorted-token-groups)))]
|
(sorted-token-groups)))]
|
||||||
[:*
|
[:*
|
||||||
[:& token-context-menu]
|
[:& token-context-menu]
|
||||||
[:& title-bar {:all-clickable true
|
[:& title-bar {:all-clickable true
|
||||||
:title "TOKENS"}]
|
:title (dm/str "TOKENS - " (ctob/set-path->set-name selected-token-set-path))}]
|
||||||
|
|
||||||
(for [{:keys [token-key token-type-props tokens]} (concat (:filled token-groups)
|
(for [{:keys [token-key token-type-props tokens]} (concat (:filled token-groups)
|
||||||
(:empty token-groups))]
|
(:empty token-groups))]
|
||||||
[:& token-component {:key token-key
|
[:& token-component {:key token-key
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue