mirror of
https://github.com/Foundry376/Mailspring.git
synced 2024-11-15 06:06:35 +08:00
24 lines
621 B
JavaScript
24 lines
621 B
JavaScript
import { React } from 'mailspring-exports';
|
|
import { Notification } from 'mailspring-component-kit';
|
|
|
|
export default class DevModeNotification extends React.Component {
|
|
static displayName = 'DevModeNotification';
|
|
|
|
constructor() {
|
|
super();
|
|
// Don't need listeners to update this, since toggling dev mode reloads
|
|
// the entire window anyway
|
|
this.state = {
|
|
inDevMode: AppEnv.inDevMode(),
|
|
};
|
|
}
|
|
|
|
render() {
|
|
if (!this.state.inDevMode) {
|
|
return <span />;
|
|
}
|
|
return (
|
|
<Notification priority="0" title="Mailspring is running in dev mode and may be slower!" />
|
|
);
|
|
}
|
|
}
|