@stack-spot/portal-layout 2.19.2 → 2.19.3

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
@@ -1,5 +1,12 @@
1
1
  # Changelog
2
2
 
3
+ ## [2.19.3](https://github.com/stack-spot/portal-commons/compare/portal-layout@v2.19.2...portal-layout@v2.19.3) (2024-12-20)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * add try catch ([645eaf5](https://github.com/stack-spot/portal-commons/commit/645eaf5c27b2df7fbed5c918646213d9b6ddb418))
9
+
3
10
  ## [2.19.2](https://github.com/stack-spot/portal-commons/compare/portal-layout@v2.19.1...portal-layout@v2.19.2) (2024-12-19)
4
11
 
5
12
 
@@ -1 +1 @@
1
- {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../src/components/Rate/utils.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,eAAe,UAAW,YAAY,SAOlD,CAAA"}
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../src/components/Rate/utils.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,eAAe,UAAW,YAAY,SAYlD,CAAA"}
@@ -3,7 +3,13 @@ export const checkVisibility = (event) => {
3
3
  if (event.key === 'RATED_US_IN') {
4
4
  const shouldShow = shouldShowNpsModal();
5
5
  if (!shouldShow) {
6
- document.getElementById('feedback-modal')?.remove();
6
+ try {
7
+ document.getElementById('feedback-modal')?.remove();
8
+ }
9
+ catch {
10
+ // eslint-disable-next-line no-console
11
+ console.warn('Error removing');
12
+ }
7
13
  }
8
14
  }
9
15
  };
@@ -1 +1 @@
1
- {"version":3,"file":"utils.js","sourceRoot":"","sources":["../../../src/components/Rate/utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,QAAQ,CAAA;AAE3C,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,KAAmB,EAAE,EAAE;IACrD,IAAI,KAAK,CAAC,GAAG,KAAK,aAAa,EAAE,CAAC;QAChC,MAAM,UAAU,GAAG,kBAAkB,EAAE,CAAA;QACvC,IAAI,CAAC,UAAU,EAAE,CAAC;YAChB,QAAQ,CAAC,cAAc,CAAC,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAA;QACrD,CAAC;IACH,CAAC;AACH,CAAC,CAAA"}
1
+ {"version":3,"file":"utils.js","sourceRoot":"","sources":["../../../src/components/Rate/utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,QAAQ,CAAA;AAE3C,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,KAAmB,EAAE,EAAE;IACrD,IAAI,KAAK,CAAC,GAAG,KAAK,aAAa,EAAE,CAAC;QAChC,MAAM,UAAU,GAAG,kBAAkB,EAAE,CAAA;QACvC,IAAI,CAAC,UAAU,EAAE,CAAC;YAChB,IAAI,CAAC;gBACH,QAAQ,CAAC,cAAc,CAAC,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAA;YACrD,CAAC;YAAC,MAAM,CAAC;gBACP,sCAAsC;gBACtC,OAAO,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAA;YAChC,CAAC;QACH,CAAC;IACH,CAAC;AACH,CAAC,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stack-spot/portal-layout",
3
- "version": "2.19.2",
3
+ "version": "2.19.3",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -4,7 +4,12 @@ export const checkVisibility = (event: StorageEvent) => {
4
4
  if (event.key === 'RATED_US_IN') {
5
5
  const shouldShow = shouldShowNpsModal()
6
6
  if (!shouldShow) {
7
- document.getElementById('feedback-modal')?.remove()
7
+ try {
8
+ document.getElementById('feedback-modal')?.remove()
9
+ } catch {
10
+ // eslint-disable-next-line no-console
11
+ console.warn('Error removing')
12
+ }
8
13
  }
9
14
  }
10
15
  }