Skip to content

Commit 5278ecd

Browse files
tharakawjthongdong7
authored andcommitted
Rename Overlay to ErrorOvelay (facebook#3051)
1 parent 76a4f80 commit 5278ecd

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

packages/react-error-overlay/src/components/Overlay.js packages/react-error-overlay/src/components/ErrorOverlay.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ const overlayStyle = {
3131
color: black,
3232
};
3333

34-
class Overlay extends Component {
34+
class ErrorOverlay extends Component {
3535
iframeWindow: window = null;
3636

3737
getIframeWindow = (element: HTMLDivElement) => {
@@ -71,4 +71,4 @@ class Overlay extends Component {
7171
}
7272
}
7373

74-
export default Overlay;
74+
export default ErrorOverlay;

packages/react-error-overlay/src/containers/CompileErrorContainer.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
/* @flow */
1111
import React, { PureComponent } from 'react';
12-
import Overlay from '../components/Overlay';
12+
import ErrorOverlay from '../components/ErrorOverlay';
1313
import Footer from '../components/Footer';
1414
import Header from '../components/Header';
1515
import CodeBlock from '../components/CodeBlock';
@@ -19,11 +19,11 @@ class CompileErrorContainer extends PureComponent {
1919
render() {
2020
const { error } = this.props;
2121
return (
22-
<Overlay>
22+
<ErrorOverlay>
2323
<Header headerText="Failed to compile" />
2424
<CodeBlock main={true} codeHTML={generateAnsiHTML(error)} />
2525
<Footer line1="This error occurred during the build time and cannot be dismissed." />
26-
</Overlay>
26+
</ErrorOverlay>
2727
);
2828
}
2929
}

packages/react-error-overlay/src/containers/RuntimeErrorContainer.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
/* @flow */
1111
import React, { PureComponent } from 'react';
12-
import Overlay from '../components/Overlay';
12+
import ErrorOverlay from '../components/ErrorOverlay';
1313
import CloseButton from '../components/CloseButton';
1414
import NavigationBar from '../components/NavigationBar';
1515
import RuntimeError from './RuntimeError';
@@ -52,7 +52,7 @@ class RuntimeErrorContainer extends PureComponent {
5252
const { errorRecords, close } = this.props;
5353
const totalErrors = errorRecords.length;
5454
return (
55-
<Overlay shortcutHandler={this.shortcutHandler}>
55+
<ErrorOverlay shortcutHandler={this.shortcutHandler}>
5656
<CloseButton close={close} />
5757
{totalErrors > 1 &&
5858
<NavigationBar
@@ -69,7 +69,7 @@ class RuntimeErrorContainer extends PureComponent {
6969
line1="This screen is visible only in development. It will not appear if the app crashes in production."
7070
line2="Open your browser’s developer console to further inspect this error."
7171
/>
72-
</Overlay>
72+
</ErrorOverlay>
7373
);
7474
}
7575
}

0 commit comments

Comments
 (0)