@contentful/experiences-sdk-react 1.0.5 → 1.0.6-beta.0

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/dist/index.js CHANGED
@@ -9,7 +9,7 @@ import * as Components from '@contentful/experiences-components-react';
9
9
  import { ContentfulContainer, Columns, SingleColumn } from '@contentful/experiences-components-react';
10
10
  import styleInject from 'style-inject';
11
11
 
12
- const SDK_VERSION = '1.0.5-beta.0';
12
+ const SDK_VERSION = '1.0.5';
13
13
 
14
14
  var util;
15
15
  (function (util) {
@@ -4962,8 +4962,6 @@ const PreviewDeliveryRoot = ({ locale, experience }) => {
4962
4962
  var css_248z = ".cf-error-message {\n margin: 24px;\n font-size: var(--exp-builder-font-size-m);\n font-family: var(--exp-builder-font-stack-primary);\n color: var(--exp-builder-red800);\n padding: 16px;\n background-color: var(--exp-builder-red200);\n}\n\n.cf-error-message .title {\n margin-top: 0;\n font-size: var(--exp-builder-font-size-l);\n}\n\n.cf-error-message .more-details {\n cursor: pointer;\n color: var(--exp-builder-blue700);\n}\n";
4963
4963
  styleInject(css_248z);
4964
4964
 
4965
- class ImportedComponentError extends Error {
4966
- }
4967
4965
  class ErrorBoundary extends React.Component {
4968
4966
  constructor(props) {
4969
4967
  super(props);
@@ -4974,7 +4972,7 @@ class ErrorBoundary extends React.Component {
4974
4972
  }
4975
4973
  componentDidCatch(error, errorInfo) {
4976
4974
  this.setState({ error, errorInfo });
4977
- if (!(error instanceof ImportedComponentError)) {
4975
+ if (error.name !== 'ImportedComponentError') {
4978
4976
  sendMessage(OUTGOING_EVENTS.CanvasError, error);
4979
4977
  }
4980
4978
  else {
@@ -4992,16 +4990,6 @@ class ErrorBoundary extends React.Component {
4992
4990
  return this.props.children;
4993
4991
  }
4994
4992
  }
4995
- class ImportedComponentErrorBoundary extends React.Component {
4996
- componentDidCatch(error, _errorInfo) {
4997
- const err = new ImportedComponentError(error.message);
4998
- err.stack = error.stack;
4999
- throw err;
5000
- }
5001
- render() {
5002
- return this.props.children;
5003
- }
5004
- }
5005
4993
 
5006
4994
  const useInitializeVisualEditor = (params) => {
5007
4995
  const { initialLocale, initialEntities } = params;