@saltcorn/markup
Advanced tools
Comparing version 0.2.1-alpha.0 to 0.2.1
@@ -169,2 +169,41 @@ const { | ||
module.exports = { navbar, alert, logit, navbarSolidOnScroll, breadcrumbs }; | ||
const headersInHead = (headers) => | ||
headers | ||
.filter((h) => h.css) | ||
.map((h) => `<link href="${h.css}" rel="stylesheet">`) | ||
.join("") + | ||
headers | ||
.filter((h) => h.style) | ||
.map((h) => `<style>${h.style}</style>`) | ||
.join("") + | ||
headers | ||
.filter((h) => h.headerTag) | ||
.map((h) => h.headerTag) | ||
.join(""); | ||
const headersInBody = (headers) => | ||
headers | ||
.filter((h) => h.script) | ||
.map( | ||
(h) => | ||
`<script src="${h.script}" ${ | ||
h.integrity | ||
? `integrity="${h.integrity}" crossorigin="anonymous"` | ||
: "" | ||
}></script>` | ||
) | ||
.join("") + | ||
headers | ||
.filter((h) => h.scriptBody) | ||
.map((h) => `<script>${h.scriptBody}</script>`) | ||
.join(""); | ||
module.exports = { | ||
navbar, | ||
alert, | ||
logit, | ||
navbarSolidOnScroll, | ||
breadcrumbs, | ||
headersInHead, | ||
headersInBody, | ||
}; |
{ | ||
"name": "@saltcorn/markup", | ||
"version": "0.2.1-alpha.0", | ||
"version": "0.2.1", | ||
"description": "Markup for Saltcorn, open-source no-code platform", | ||
@@ -27,3 +27,3 @@ "homepage": "https://saltcorn.com", | ||
}, | ||
"gitHead": "0b9f7470e0c42789b3d6d579d3f49cf4e336003e" | ||
"gitHead": "635c3b3918130b48a7f817b8e3a2635a931ea5b0" | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
346306
2071