Skip to content

Commit 70f342c

Browse files
committed
enhance specs
1 parent f1e4310 commit 70f342c

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

src/renderer/app/db.cljs

+2-2
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,8 @@
7676
[:clicked-element {:optional true} [:or Element Handle]]
7777
[:copied-bounds {:optional true} Bounds]
7878
[:copied-elements {:optional true} [:* Element]]
79-
[:kdtree {:optional true} any?]
80-
[:viewbox-kdtree {:optional true} any?]
79+
[:kdtree {:optional true} [:maybe map?]]
80+
[:viewbox-kdtree {:optional true} [:maybe map?]]
8181
[:re-pressed.core/keydown {:optional true} map?]])
8282

8383
(def valid? (m/validator App))

src/renderer/document/handlers.cljs

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
[renderer.snap.handlers :as snap.h]
1212
[renderer.utils.vec :as vec]))
1313

14-
(m/=> path [:-> App [:* keyword?] vector?])
14+
(m/=> path [:-> App [:* [:or keyword? uuid?]] vector?])
1515
(defn path
1616
[db & more]
1717
(apply conj [:documents (:active-document db)] more))

src/renderer/element/handlers.cljs

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
[renderer.utils.path :as path :refer [PathManipulation PathBooleanOperation]]
2424
[renderer.utils.vec :as vec]))
2525

26-
(m/=> path [:-> App [:* any?] vector?])
26+
(m/=> path [:-> App [:* [:or keyword? uuid?]] vector?])
2727
(defn path
2828
[db & more]
2929
(apply conj [:documents (:active-document db) :elements] more))

src/renderer/history/handlers.cljs

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
[renderer.utils.math :refer [Vec2]]
1414
[renderer.utils.vec :as vec]))
1515

16-
(m/=> path [:-> App [:* any?] vector?])
16+
(m/=> path [:-> App [:* [:or keyword? uuid?]] vector?])
1717
(defn path
1818
[db & more]
1919
(apply conj [:documents (:active-document db) :history] more))

0 commit comments

Comments
 (0)