@etsoo/shared 1.2.67 → 1.2.68

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.
@@ -204,6 +204,11 @@ test("Tests for hasHtmlEntity", () => {
204
204
  expect(Utils.hasHtmlEntity("< >")).toBeTruthy();
205
205
  expect(Utils.hasHtmlEntity("&180;")).toBeFalsy();
206
206
  expect(Utils.hasHtmlEntity("&160;")).toBeTruthy();
207
+ expect(
208
+ Utils.hasHtmlEntity(
209
+ "<p>Hello, world! This is <b>BOLD</b>.</p>"
210
+ )
211
+ ).toBeTruthy();
207
212
  });
208
213
 
209
214
  test("Tests for hasHtmlTag", () => {
package/lib/cjs/Utils.js CHANGED
@@ -363,7 +363,7 @@ var Utils;
363
363
  * @returns Result
364
364
  */
365
365
  function hasHtmlEntity(input) {
366
- return /&(lt|gt|nbsp|60|62|160);/.test(input);
366
+ return /&(lt|gt|nbsp|60|62|160|#x3C|#x3E|#xA0);/i.test(input);
367
367
  }
368
368
  Utils.hasHtmlEntity = hasHtmlEntity;
369
369
  /**
package/lib/mjs/Utils.js CHANGED
@@ -357,7 +357,7 @@ export var Utils;
357
357
  * @returns Result
358
358
  */
359
359
  function hasHtmlEntity(input) {
360
- return /&(lt|gt|nbsp|60|62|160);/.test(input);
360
+ return /&(lt|gt|nbsp|60|62|160|#x3C|#x3E|#xA0);/i.test(input);
361
361
  }
362
362
  Utils.hasHtmlEntity = hasHtmlEntity;
363
363
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@etsoo/shared",
3
- "version": "1.2.67",
3
+ "version": "1.2.68",
4
4
  "description": "TypeScript shared utilities and functions",
5
5
  "main": "lib/cjs/index.js",
6
6
  "module": "lib/mjs/index.js",
package/src/Utils.ts CHANGED
@@ -540,7 +540,7 @@ export namespace Utils {
540
540
  * @returns Result
541
541
  */
542
542
  export function hasHtmlEntity(input: string) {
543
- return /&(lt|gt|nbsp|60|62|160);/.test(input);
543
+ return /&(lt|gt|nbsp|60|62|160|#x3C|#x3E|#xA0);/i.test(input);
544
544
  }
545
545
 
546
546
  /**