@schukai/monster 3.101.1 → 3.101.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,14 @@
2
2
 
3
3
 
4
4
 
5
+ ## [3.101.2] - 2025-01-23
6
+
7
+ ### Bug Fixes
8
+
9
+ - **transformer:** add escape html
10
+
11
+
12
+
5
13
  ## [3.101.1] - 2025-01-23
6
14
 
7
15
  ### Bug Fixes
package/package.json CHANGED
@@ -1 +1 @@
1
- {"author":"schukai GmbH","dependencies":{"@floating-ui/dom":"^1.6.13","@popperjs/core":"^2.11.8"},"description":"Monster is a simple library for creating fast, robust and lightweight websites.","homepage":"https://monsterjs.org/","keywords":["framework","web","dom","css","sass","mobile-first","app","front-end","templates","schukai","core","shopcloud","alvine","monster","buildmap","stack","observer","observable","uuid","node","nodelist","css-in-js","logger","log","theme"],"license":"AGPL 3.0","main":"source/monster.mjs","module":"source/monster.mjs","name":"@schukai/monster","repository":{"type":"git","url":"https://gitlab.schukai.com/oss/libraries/javascript/monster.git"},"type":"module","version":"3.101.1"}
1
+ {"author":"schukai GmbH","dependencies":{"@floating-ui/dom":"^1.6.13","@popperjs/core":"^2.11.8"},"description":"Monster is a simple library for creating fast, robust and lightweight websites.","homepage":"https://monsterjs.org/","keywords":["framework","web","dom","css","sass","mobile-first","app","front-end","templates","schukai","core","shopcloud","alvine","monster","buildmap","stack","observer","observable","uuid","node","nodelist","css-in-js","logger","log","theme"],"license":"AGPL 3.0","main":"source/monster.mjs","module":"source/monster.mjs","name":"@schukai/monster","repository":{"type":"git","url":"https://gitlab.schukai.com/oss/libraries/javascript/monster.git"},"type":"module","version":"3.101.2"}
@@ -196,6 +196,17 @@ function transform(value) {
196
196
  validateString(value);
197
197
  return value.toLowerCase();
198
198
 
199
+ case "escape-html":
200
+ case "escapehtml":
201
+ validateString(value);
202
+
203
+ return value.replace(/&/g, "&").
204
+ replace(/</g, "&lt;").
205
+ replace(/>/g, "&gt;").
206
+ replace(/"/g, "&quot;").
207
+ replace(/'/g, '&#39;');
208
+
209
+
199
210
  case "contains":
200
211
  if (isString(value)) {
201
212
  return value.includes(args[0]);