mirror of
https://github.com/penpot/penpot.git
synced 2025-05-31 22:31:40 +02:00
✨ Normalize token name on creation
This commit is contained in:
parent
a9e8d8f8f7
commit
559dcabf0e
2 changed files with 26 additions and 9 deletions
|
@ -251,6 +251,12 @@
|
|||
[name]
|
||||
(split-path name set-separator))
|
||||
|
||||
(defn normalize-set-name
|
||||
[name]
|
||||
(->> (split-token-set-name name)
|
||||
(map str/trim)
|
||||
(str/join set-separator)))
|
||||
|
||||
(defn get-token-set-path [token-set]
|
||||
(let [path (get-path token-set set-separator)]
|
||||
(add-token-set-paths-prefix path)))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue