diff --git a/exporter/src/app/browser.cljs b/exporter/src/app/browser.cljs index 612023fba..0f8f898ac 100644 --- a/exporter/src/app/browser.cljs +++ b/exporter/src/app/browser.cljs @@ -73,12 +73,14 @@ (defn pdf ([page] (pdf page {})) - ([page {:keys [scale save-path] - :or {scale 1}}] - (.pdf ^js page #js {:path save-path - :scale scale - :printBackground true - :preferCSSPageSize true}))) + ([page {:keys [scale save-path page-ranges] + :or {page-ranges "1" + scale 1}}] + (.pdf ^js page #js {:path save-path + :scale scale + :pageRanges page-ranges + :printBackground true + :preferCSSPageSize true}))) (defn eval! [frame f] (.evaluate ^js frame f)) diff --git a/frontend/src/app/main/ui/render.cljs b/frontend/src/app/main/ui/render.cljs index 2b5edf267..5572587d1 100644 --- a/frontend/src/app/main/ui/render.cljs +++ b/frontend/src/app/main/ui/render.cljs @@ -7,6 +7,7 @@ (ns app.main.ui.render (:require [app.common.data :as d] + [app.common.data.macros :as dm] [app.common.geom.matrix :as gmt] [app.common.geom.point :as gpt] [app.common.geom.shapes :as gsh] @@ -103,8 +104,8 @@ (mf/with-effect [width height] (dom/set-page-style! - {:size (str (mth/ceil width) "px " - (mth/ceil height) "px")})) + {:size (dm/str (mth/ceil width) "px " + (mth/ceil height) "px")})) [:& (mf/provider embed/context) {:value embed?} [:svg {:id "screenshot"