@douyinfe/semi-ui 2.52.1 → 2.52.2

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.
@@ -22686,13 +22686,17 @@ class ReactResizeObserver extends BaseComponent {
22686
22686
  ref.current = node;
22687
22687
  }
22688
22688
  };
22689
- this.observer = new ResizeObserver(props.onResize);
22689
+ if (globalThis['ResizeObserver']) {
22690
+ this.observer = new ResizeObserver(props.onResize);
22691
+ }
22690
22692
  }
22691
22693
  componentDidMount() {
22692
- this.observeElement();
22694
+ var _a;
22695
+ (_a = this.observeElement) === null || _a === void 0 ? void 0 : _a.call(this);
22693
22696
  }
22694
22697
  componentDidUpdate(prevProps) {
22695
- this.observeElement(this.props.observeParent !== prevProps.observeParent);
22698
+ var _a;
22699
+ (_a = this.observeElement) === null || _a === void 0 ? void 0 : _a.call(this, this.props.observeParent !== prevProps.observeParent);
22696
22700
  }
22697
22701
  componentWillUnmount() {
22698
22702
  if (this.observer) {