@marianmeres/stuic 3.71.0 → 3.71.1

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.
@@ -109,18 +109,16 @@
109
109
 
110
110
  onDestroy(clearTimers);
111
111
 
112
+ const HTML_ESCAPES: Record<string, string> = {
113
+ "&": "&amp;",
114
+ "<": "&lt;",
115
+ ">": "&gt;",
116
+ '"': "&quot;",
117
+ "'": "&#39;",
118
+ };
119
+
112
120
  function escapeHtml(s: string): string {
113
- return s.replace(/[&<>"']/g, (c) =>
114
- c === "&"
115
- ? "&amp;"
116
- : c === "<"
117
- ? "&lt;"
118
- : c === ">"
119
- ? "&gt;"
120
- : c === '"'
121
- ? "&quot;"
122
- : "&#39;"
123
- );
121
+ return s.replace(/[&<>"']/g, (c) => HTML_ESCAPES[c]);
124
122
  }
125
123
 
126
124
  let subheadingHtml = $derived(
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@marianmeres/stuic",
3
- "version": "3.71.0",
3
+ "version": "3.71.1",
4
4
  "files": [
5
5
  "dist",
6
6
  "!dist/**/*.test.*",