mirror of
https://github.com/penpot/penpot.git
synced 2025-08-07 14:38:33 +02:00
💄 Rename token-component* to token-group*
This commit is contained in:
parent
ff34d1d5f9
commit
7a4d8b824e
1 changed files with 14 additions and 13 deletions
|
@ -72,7 +72,7 @@
|
||||||
:shape-ids shape-ids
|
:shape-ids shape-ids
|
||||||
:selected-pred #(seq (% ids-by-attributes))}))
|
:selected-pred #(seq (% ids-by-attributes))}))
|
||||||
|
|
||||||
(mf/defc token-component*
|
(mf/defc token-group*
|
||||||
{::mf/private true}
|
{::mf/private true}
|
||||||
[{:keys [type tokens selected-shapes token-type-props active-theme-tokens]}]
|
[{:keys [type tokens selected-shapes token-type-props active-theme-tokens]}]
|
||||||
(let [open? (mf/deref (-> (l/key type)
|
(let [open? (mf/deref (-> (l/key type)
|
||||||
|
@ -287,26 +287,27 @@
|
||||||
(mf/with-memo [tokens selected-token-set-tokens]
|
(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 (tr "workspace.token.tokens-section-title" selected-token-set-name)}]
|
:title (tr "workspace.token.tokens-section-title" selected-token-set-name)}]
|
||||||
|
|
||||||
(for [{:keys [token-key token-type-props tokens]} (:filled token-groups)]
|
(for [{:keys [token-key token-type-props tokens]} (:filled token-groups)]
|
||||||
[:> token-component* {:key token-key
|
[:> token-group* {:key token-key
|
||||||
:type token-key
|
:type token-key
|
||||||
:selected-shapes selected-shapes
|
:selected-shapes selected-shapes
|
||||||
:active-theme-tokens active-theme-tokens
|
:active-theme-tokens active-theme-tokens
|
||||||
:tokens tokens
|
:tokens tokens
|
||||||
:token-type-props token-type-props}])
|
:token-type-props token-type-props}])
|
||||||
|
|
||||||
(for [{:keys [token-key token-type-props tokens]} (:empty token-groups)]
|
(for [{:keys [token-key token-type-props tokens]} (:empty token-groups)]
|
||||||
[:> token-component* {:key token-key
|
[:> token-group* {:key token-key
|
||||||
:type token-key
|
:type token-key
|
||||||
:selected-shapes selected-shapes
|
:selected-shapes selected-shapes
|
||||||
:active-theme-tokens active-theme-tokens
|
:active-theme-tokens active-theme-tokens
|
||||||
:tokens tokens
|
:tokens tokens
|
||||||
:token-type-props token-type-props}])]))
|
:token-type-props token-type-props}])]))
|
||||||
|
|
||||||
(mf/defc import-export-button
|
(mf/defc import-export-button
|
||||||
{::mf/wrap-props false}
|
{::mf/wrap-props false}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue