fix: title of newly created pages are all lowered

This commit is contained in:
Tienson Qin
2022-05-08 22:19:30 +08:00
parent 3166da23e3
commit ca5745fc9b
4 changed files with 12 additions and 9 deletions

View File

@@ -658,12 +658,12 @@
new-block))))))
(defn insert-first-page-block-if-not-exists!
([page-name]
(insert-first-page-block-if-not-exists! page-name {}))
([page-name opts]
(when (and (string? page-name)
(not (string/blank? page-name)))
(state/pub-event! [:page/create page-name opts]))))
([page-title]
(insert-first-page-block-if-not-exists! page-title {}))
([page-title opts]
(when (and (string? page-title)
(not (string/blank? page-title)))
(state/pub-event! [:page/create page-title opts]))))
(defn properties-block
[properties format page]