@veritone-ce/design-system 2.5.12 → 2.5.13
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.
|
@@ -22,7 +22,7 @@ class ErrorBoundary extends React.Component {
|
|
|
22
22
|
this.setState({ hasError: true, error, info });
|
|
23
23
|
}
|
|
24
24
|
render() {
|
|
25
|
-
if (this.state.hasError) {
|
|
25
|
+
if (this.state.hasError || this.props.error) {
|
|
26
26
|
return this.props.fallback ?? /* @__PURE__ */ jsxRuntime.jsx(
|
|
27
27
|
index.default,
|
|
28
28
|
{
|
|
@@ -32,6 +32,8 @@ class ErrorBoundary extends React.Component {
|
|
|
32
32
|
alignItems: "center",
|
|
33
33
|
padding: "20px"
|
|
34
34
|
},
|
|
35
|
+
style: this.props.style,
|
|
36
|
+
className: this.props.className,
|
|
35
37
|
children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: styles_module.default.customMessageContainer, children: [
|
|
36
38
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
37
39
|
iconsMaterial.ErrorOutline,
|
|
@@ -18,7 +18,7 @@ class ErrorBoundary extends React__default.Component {
|
|
|
18
18
|
this.setState({ hasError: true, error, info });
|
|
19
19
|
}
|
|
20
20
|
render() {
|
|
21
|
-
if (this.state.hasError) {
|
|
21
|
+
if (this.state.hasError || this.props.error) {
|
|
22
22
|
return this.props.fallback ?? /* @__PURE__ */ jsx(
|
|
23
23
|
Box,
|
|
24
24
|
{
|
|
@@ -28,6 +28,8 @@ class ErrorBoundary extends React__default.Component {
|
|
|
28
28
|
alignItems: "center",
|
|
29
29
|
padding: "20px"
|
|
30
30
|
},
|
|
31
|
+
style: this.props.style,
|
|
32
|
+
className: this.props.className,
|
|
31
33
|
children: /* @__PURE__ */ jsxs("div", { className: styles.customMessageContainer, children: [
|
|
32
34
|
/* @__PURE__ */ jsx(
|
|
33
35
|
ErrorOutline,
|