@salesforcedevs/docs-components 1.3.296 → 1.3.300

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salesforcedevs/docs-components",
3
- "version": "1.3.296",
3
+ "version": "1.3.300",
4
4
  "description": "Docs Lightning web components for DSC",
5
5
  "license": "MIT",
6
6
  "main": "index.js",
@@ -24,5 +24,5 @@
24
24
  "@types/lodash.orderby": "^4.6.7",
25
25
  "@types/lodash.uniqby": "^4.7.7"
26
26
  },
27
- "gitHead": "7a3e47bb11802dbded4c5bd3814b408cbeedecd7"
27
+ "gitHead": "f38c6bd9c9360f64cd7ed0e61184e4685049c673"
28
28
  }
@@ -112,16 +112,23 @@ export default class Breadcrumbs extends LightningElement {
112
112
 
113
113
  renderedCallback(): void {
114
114
  if (!this.observer) {
115
- this.observer = new ResizeObserver((entries) => {
116
- const [nav] = entries;
117
- if (this.navWidth === nav.contentRect.width) {
118
- return;
119
- }
120
- this.navWidth = nav.contentRect.width;
121
- this.updateDropdownOptionAmount();
122
- });
123
-
124
- this.observer.observe(this.template.querySelector("nav")!);
115
+ try {
116
+ this.observer = new ResizeObserver((entries) => {
117
+ const [nav] = entries;
118
+ if (this.navWidth === nav.contentRect.width) {
119
+ return;
120
+ }
121
+ this.navWidth = nav.contentRect.width;
122
+ this.updateDropdownOptionAmount();
123
+ });
124
+
125
+ this.observer.observe(this.template.querySelector("nav")!);
126
+ } catch (error) {
127
+ console.error(
128
+ "Error occured while setting up ResizeObserver on breadcrumbs",
129
+ error
130
+ );
131
+ }
125
132
  }
126
133
  }
127
134