mirror of
https://github.com/penpot/penpot.git
synced 2025-05-31 03:36:17 +02:00
✨ Adapt page creation to model changes.
This commit is contained in:
parent
9bb5be306f
commit
433d8cee9a
3 changed files with 19 additions and 18 deletions
|
@ -21,11 +21,11 @@
|
|||
[uxbox.util.i18n :refer [tr]]))
|
||||
|
||||
(s/def ::id ::us/uuid)
|
||||
(s/def ::project-id ::us/uuid)
|
||||
(s/def ::file-id ::us/uuid)
|
||||
(s/def ::name ::us/not-empty-string)
|
||||
|
||||
(s/def ::page-form
|
||||
(s/keys :req-un [::project-id ::name]
|
||||
(s/keys :req-un [::file-id ::name]
|
||||
:opt-un [::id]))
|
||||
|
||||
(defn- on-submit
|
||||
|
@ -40,7 +40,7 @@
|
|||
(defn- initial-data
|
||||
[page]
|
||||
(merge {:name ""}
|
||||
(select-keys page [:name :id :project-id])))
|
||||
(select-keys page [:name :id :file-id])))
|
||||
|
||||
(mf/defc page-form
|
||||
[{:keys [page] :as props}]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue