mirror of
https://github.com/penpot/penpot.git
synced 2026-06-10 17:32:38 +00:00
♻️ Migrate onboarding team-choice to modern component syntax (#9463)
Co-authored-by: Andrey Antukh <niwi@niwi.nz>
This commit is contained in:
parent
7fd4e35203
commit
32d974aa3e
@ -27,7 +27,7 @@
|
||||
[app.main.ui.nitrate.entry :as nitrate-entry]
|
||||
[app.main.ui.notifications :as notifications]
|
||||
[app.main.ui.onboarding.questions :refer [questions-modal]]
|
||||
[app.main.ui.onboarding.team-choice :refer [onboarding-team-modal]]
|
||||
[app.main.ui.onboarding.team-choice :refer [onboarding-team-modal*]]
|
||||
[app.main.ui.releases :refer [release-notes-modal]]
|
||||
[app.main.ui.static :as static]
|
||||
[app.util.dom :as dom]
|
||||
@ -238,14 +238,14 @@
|
||||
#_[:& app.main.ui.releases/release-notes-modal {:version "2.5"}]
|
||||
#_[:& app.main.ui.onboarding/onboarding-templates-modal]
|
||||
#_[:& app.main.ui.onboarding/onboarding-modal]
|
||||
#_[:& app.main.ui.onboarding.team-choice/onboarding-team-modal]
|
||||
#_[:> app.main.ui.onboarding.team-choice/onboarding-team-modal*]
|
||||
|
||||
(cond
|
||||
show-question-modal?
|
||||
[:& questions-modal]
|
||||
|
||||
show-team-modal?
|
||||
[:& onboarding-team-modal {:go-to-team true}]
|
||||
[:> onboarding-team-modal* {:go-to-team true}]
|
||||
|
||||
show-release-modal?
|
||||
[:& release-notes-modal {:version (:main cf/version)}])
|
||||
@ -272,7 +272,7 @@
|
||||
[:& questions-modal]
|
||||
|
||||
show-team-modal?
|
||||
[:& onboarding-team-modal {:go-to-team false}]
|
||||
[:> onboarding-team-modal* {:go-to-team false}]
|
||||
|
||||
show-release-modal?
|
||||
[:& release-notes-modal {:version (:main cf/version)}]))
|
||||
|
||||
@ -20,9 +20,8 @@
|
||||
[app.util.i18n :as i18n :refer [tr]]
|
||||
[rumext.v2 :as mf]))
|
||||
|
||||
(mf/defc left-sidebar
|
||||
{::mf/props :obj
|
||||
::mf/private true}
|
||||
(mf/defc left-sidebar*
|
||||
{::mf/private true}
|
||||
[]
|
||||
[:div {:class (stl/css :modal-left)}
|
||||
[:h2 {:class (stl/css :modal-subtitle)}
|
||||
@ -63,9 +62,8 @@
|
||||
[:role :keyword]
|
||||
[:emails {:optional true} [::sm/set ::sm/email]]])
|
||||
|
||||
(mf/defc team-form
|
||||
{::mf/props :obj
|
||||
::mf/private true}
|
||||
(mf/defc team-form*
|
||||
{::mf/private true}
|
||||
[{:keys [go-to-team]}]
|
||||
(let [initial (mf/with-memo []
|
||||
{:role "editor"})
|
||||
@ -228,8 +226,7 @@
|
||||
:on-click on-skip}
|
||||
(tr "onboarding.choice.team-up.continue-without-a-team")]]]]]))
|
||||
|
||||
(mf/defc onboarding-team-modal
|
||||
{::mf/props :obj}
|
||||
(mf/defc onboarding-team-modal*
|
||||
[{:keys [go-to-team]}]
|
||||
|
||||
[:div {:class (stl/css-case
|
||||
@ -239,7 +236,7 @@
|
||||
[:h1 {:class (stl/css :modal-title)}
|
||||
(tr "onboarding-v2.welcome.title")]
|
||||
[:div {:class (stl/css :modal-sections)}
|
||||
[:& left-sidebar]
|
||||
[:> left-sidebar*]
|
||||
[:div {:class (stl/css :separator)}]
|
||||
[:& team-form {:go-to-team go-to-team}]]]])
|
||||
[:> team-form* {:go-to-team go-to-team}]]]])
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user