mirror of
https://github.com/penpot/penpot.git
synced 2025-01-21 22:22:43 -05:00
Formatting
This commit is contained in:
parent
1ed692230b
commit
e181065bda
1 changed files with 9 additions and 6 deletions
|
@ -99,12 +99,15 @@
|
||||||
selection-parents (mf/deref selection-parents-ref)
|
selection-parents (mf/deref selection-parents-ref)
|
||||||
|
|
||||||
tokens (mf/deref refs/workspace-tokens)
|
tokens (mf/deref refs/workspace-tokens)
|
||||||
border-radius-tokens (mf/use-memo (mf/deps tokens) #(wtc/tokens-name-map-for-type :border-radius tokens))
|
border-radius-tokens (mf/use-memo
|
||||||
border-radius-options (mf/use-memo (mf/deps shape border-radius-tokens)
|
(mf/deps tokens)
|
||||||
#(map (fn [[_k {:keys [name] :as item}]]
|
#(wtc/tokens-name-map-for-type :border-radius tokens))
|
||||||
(cond-> (assoc item :label name)
|
border-radius-options (mf/use-memo
|
||||||
(wtc/token-applied? item shape (wtc/token-attributes :border-radius)) (assoc :selected? true)))
|
(mf/deps shape border-radius-tokens)
|
||||||
border-radius-tokens))
|
#(map (fn [[_k {:keys [name] :as item}]]
|
||||||
|
(cond-> (assoc item :label name)
|
||||||
|
(wtc/token-applied? item shape (wtc/token-attributes :border-radius)) (assoc :selected? true)))
|
||||||
|
border-radius-tokens))
|
||||||
|
|
||||||
flex-child? (->> selection-parents (some ctl/flex-layout?))
|
flex-child? (->> selection-parents (some ctl/flex-layout?))
|
||||||
absolute? (ctl/item-absolute? shape)
|
absolute? (ctl/item-absolute? shape)
|
||||||
|
|
Loading…
Add table
Reference in a new issue