mirror of
https://github.com/penpot/penpot.git
synced 2025-02-01 20:09:04 -05:00
Add theme creation
This commit is contained in:
parent
8482a128de
commit
7406af2e79
2 changed files with 8 additions and 4 deletions
|
@ -108,7 +108,7 @@
|
||||||
:name "Token Set"
|
:name "Token Set"
|
||||||
:tokens []}
|
:tokens []}
|
||||||
token-set)]
|
token-set)]
|
||||||
(ptk/reify ::update-create-token
|
(ptk/reify ::create-token-set
|
||||||
ptk/WatchEvent
|
ptk/WatchEvent
|
||||||
(watch [it _ _]
|
(watch [it _ _]
|
||||||
(let [changes (-> (pcb/empty-changes it)
|
(let [changes (-> (pcb/empty-changes it)
|
||||||
|
|
|
@ -155,10 +155,14 @@
|
||||||
:flex-direction "column"
|
:flex-direction "column"
|
||||||
:gap "10px"}}
|
:gap "10px"}}
|
||||||
[:& labeled-input {:label "Group name"
|
[:& labeled-input {:label "Group name"
|
||||||
:input-props {:value @group}}]
|
:input-props {:value @group
|
||||||
|
:on-change #(reset! group (dom/event->value %))}}]
|
||||||
[:& labeled-input {:label "Theme name"
|
[:& labeled-input {:label "Theme name"
|
||||||
:input-props {:value @name}}]
|
:input-props {:value @name
|
||||||
[:button "Create"]]))
|
:on-change #(reset! name (dom/event->value %))}}]
|
||||||
|
[:button {:on-click #(st/emit! (wdt/create-token-theme {:group @group
|
||||||
|
:name @name}))}
|
||||||
|
"Create"]]))
|
||||||
|
|
||||||
(mf/defc token-sets
|
(mf/defc token-sets
|
||||||
[_props]
|
[_props]
|
||||||
|
|
Loading…
Add table
Reference in a new issue