0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-01-21 06:02:32 -05:00

Add back button

This commit is contained in:
Florian Schroedl 2024-08-23 17:20:20 +02:00
parent 3ce2531b42
commit 967fab416a
2 changed files with 18 additions and 1 deletions

View file

@ -96,7 +96,7 @@
"Create theme"]]]))
(mf/defc edit-theme
[{:keys [state]}]
[{:keys [state set-state]}]
(let [{:keys [theme-id]} @state
token-sets (mf/deref refs/workspace-token-sets)
theme (mf/deref (refs/workspace-token-theme theme-id))
@ -110,6 +110,10 @@
(st/emit! (wdt/toggle-token-set {:token-set-id token-set-id
:token-theme-id (:id theme)}))))]
[:div {:class (stl/css :edit-theme-wrapper)}
[:div
[:button {:class (stl/css :back-button)
:on-click #(set-state (constantly {:type :themes-overview}))}
chevron-icon "Back"]]
[:div {:class (stl/css :edit-theme-inputs-wrapper)}
[:& labeled-input {:label "Group"
:input-props {:value (:group theme)}}]

View file

@ -108,6 +108,19 @@ hr {
gap: $s-6;
}
.back-button {
@extend .button-tertiary;
padding: $s-6;
padding-left: 0;
display: flex;
svg {
scale: -1 1;
margin-left: 0;
@extend .button-icon;
stroke: var(--icon-foreground);
}
}
.sets-count-button {
@extend .button-secondary;
padding: $s-6;