mirror of
https://github.com/penpot/penpot.git
synced 2026-02-20 08:10:51 -05:00
Compare commits
1 Commits
staging
...
alotor-fix
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2f294227e2 |
@@ -79,7 +79,7 @@
|
||||
Structured tokens are non-primitive token types like `typography` or `box-shadow`."
|
||||
[^js token-symbol]
|
||||
(if (instance? js/Array (.-value token-symbol))
|
||||
(mapv tokenscript-symbols->penpot-unit (.-value token-symbol))
|
||||
(mapv structured-token->penpot-map (.-value token-symbol))
|
||||
(let [entries (es6-iterator-seq (.entries (.-value token-symbol)))]
|
||||
(into {} (map (fn [[k v :as V]]
|
||||
[(keyword k) (tokenscript-symbols->penpot-unit v)])
|
||||
@@ -88,7 +88,7 @@
|
||||
(defn tokenscript-symbols->penpot-unit [^js v]
|
||||
(cond
|
||||
(structured-token? v) (structured-token->penpot-map v)
|
||||
(list-symbol? v) (structured-token->penpot-map v)
|
||||
(list-symbol? v) (tokenscript-symbols->penpot-unit (.nth 1 v))
|
||||
(color-symbol? v) (.-value (.to v "hex"))
|
||||
(rem-number-with-unit? v) (rem->px v)
|
||||
:else (.-value v)))
|
||||
|
||||
@@ -111,11 +111,6 @@
|
||||
:modifier modifier
|
||||
:zoom zoom}]))))
|
||||
|
||||
(defn- show-outline?
|
||||
[shape]
|
||||
(and (not (:hidden shape))
|
||||
(not (:blocked shape))))
|
||||
|
||||
(mf/defc shape-outlines
|
||||
{::mf/wrap-props false}
|
||||
[props]
|
||||
@@ -133,8 +128,7 @@
|
||||
|
||||
shapes (-> #{}
|
||||
(into (comp (remove edition?)
|
||||
(keep lookup)
|
||||
(filter show-outline?))
|
||||
(keep lookup))
|
||||
(set/union selected hover))
|
||||
(into (comp (remove edition?)
|
||||
(keep lookup))
|
||||
|
||||
Reference in New Issue
Block a user