Add JSR margins to speed print.

This commit is contained in:
Patrick Fic
2022-03-21 11:52:44 -06:00
parent 7ccd356f0a
commit d6924c2292

View File

@@ -135,7 +135,21 @@ export async function RenderTemplates(
name: rootTemplate.useShopSpecificTemplate
? `/${bodyshop.imexshopid}/${rootTemplate.templateObject.name}`
: `/${rootTemplate.templateObject.name}`,
...(renderAsHtml ? {} : { recipe: "chrome-pdf" }),
...(renderAsHtml
? {}
: {
recipe: "chrome-pdf",
chrome: {
marginTop:
(bodyshop.logo_img_path &&
bodyshop.logo_img_path.headerMargin) ||
"36px",
marginBottom:
(bodyshop.logo_img_path &&
bodyshop.logo_img_path.footerMargin) ||
"36px",
},
}),
pdfOperations: templateAndData.map((template) => {
return {
template: {