@node-projects/web-component-designer 0.0.144 → 0.0.145

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.
@@ -6,14 +6,14 @@ export class DomConverter {
6
6
  value = value.toString();
7
7
  if (value) {
8
8
  if (useSingleQuotes)
9
- return value.replaceAll('\'', ''');
10
- return value.replaceAll('"', '"');
9
+ return value.replaceAll('\'', '&#39;').replaceAll('&', '&amp;').replaceAll('<', '&lt;').replaceAll('>', '&gt;');
10
+ return value.replaceAll('"', '&quot;').replaceAll('&', '&amp;').replaceAll('<', '&lt;').replaceAll('>', '&gt;');
11
11
  }
12
- return value;
12
+ return value.replaceAll('&', '&amp;').replaceAll('<', '&lt;').replaceAll('>', '&gt;');
13
13
  }
14
14
  static normalizeContentValue(value) {
15
15
  if (value)
16
- return value.replaceAll('<', '&lt;').replaceAll(' ', '&nbsp;'); // !caution! -> this is not normal space, it's nbsp
16
+ return value.replaceAll('<', '&lt;').replaceAll(' ', '&nbsp;').replaceAll('&', '&amp;'); // !caution! -> this is not normal space, it's nbsp
17
17
  return value;
18
18
  }
19
19
  static IsSelfClosingElement(tag) {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "description": "A UI designer for Polymer apps",
3
3
  "name": "@node-projects/web-component-designer",
4
- "version": "0.0.144",
4
+ "version": "0.0.145",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
7
7
  "author": "",