🐛 Fix exporter renderer URI path construction

Apply consistent path construction across bitmap, PDF, and SVG
renderers in the exporter. Use path join utilities instead of
hardcoding the render.html path, ensuring the path is properly
appended to the public URI base path.

- bitmap.cljs: Use u/ensure-path-slash and u/join for path
- pdf.cljs: Use u/join and ensure-path-slash on base-uri
- svg.cljs: Use u/ensure-path-slash and u/join for path
This commit is contained in:
Andrey Antukh 2026-03-31 21:41:46 +00:00
parent 98e8160875
commit 47b3667248
3 changed files with 7 additions and 4 deletions

View File

@ -60,6 +60,7 @@
:route "objects"
:skip-children skip-children}
uri (-> (cf/get :public-uri)
(assoc :path "/render.html")
(u/ensure-path-slash)
(u/join "render.html")
(assoc :query (u/map->query-string params)))]
(bw/exec! (prepare-options uri) (partial render uri)))))

View File

@ -35,7 +35,7 @@
:object-id object-id
:route "objects"}]
(-> base-uri
(assoc :path "/render.html")
(u/join "render.html")
(assoc :query (u/map->query-string params)))))
(sync-page-size! [dom]
@ -76,6 +76,7 @@
(on-object (assoc object :path path))
(p/recur (rest objects))))))]
(let [base-uri (cf/get :public-uri)]
(let [base-uri (-> (cf/get :public-uri)
(u/ensure-path-slash))]
(bw/exec! (prepare-options base-uri)
(partial render base-uri)))))

View File

@ -349,7 +349,8 @@
:object-id (mapv :id objects)
:route "objects"}
uri (-> (cf/get :public-uri)
(assoc :path "/render.html")
(u/ensure-path-slash)
(u/join "render.html")
(assoc :query (u/map->query-string params)))]
(bw/exec! (prepare-options uri)
(partial render uri)))))