File tree Expand file tree Collapse file tree
x-pack/plugins/uptime/public
components/overview/alerts/alerts_containers Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -21,13 +21,13 @@ interface Props {
2121 } ;
2222}
2323
24- export const AlertMonitorStatus = ( {
24+ export const AlertMonitorStatus : React . FC < Props > = ( {
2525 autocomplete,
2626 enabled,
2727 numTimes,
2828 setAlertParams,
2929 timerange,
30- } : Props ) => {
30+ } ) => {
3131 const { filters, locations } = useSelector ( selectMonitorStatusAlert ) ;
3232 return (
3333 < AlertMonitorStatusComponent
@@ -41,3 +41,6 @@ export const AlertMonitorStatus = ({
4141 />
4242 ) ;
4343} ;
44+
45+ // eslint-disable-next-line import/no-default-export
46+ export { AlertMonitorStatus as default } ;
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ import { AlertTlsComponent } from '../alert_tls';
1010import { setAlertFlyoutVisible } from '../../../../state/actions' ;
1111import { selectDynamicSettings } from '../../../../state/selectors' ;
1212
13- export const AlertTls = ( ) => {
13+ export const AlertTls : React . FC < { } > = ( ) => {
1414 const dispatch = useDispatch ( ) ;
1515 const setFlyoutVisible = useCallback ( ( value : boolean ) => dispatch ( setAlertFlyoutVisible ( value ) ) , [
1616 dispatch ,
@@ -24,3 +24,6 @@ export const AlertTls = () => {
2424 />
2525 ) ;
2626} ;
27+
28+ // eslint-disable-next-line import/no-default-export
29+ export { AlertTls as default } ;
Original file line number Diff line number Diff line change @@ -11,7 +11,6 @@ import { isRight } from 'fp-ts/lib/Either';
1111import { AlertTypeModel } from '../../../../triggers_actions_ui/public' ;
1212import { AlertTypeInitializer } from '.' ;
1313import { StatusCheckExecutorParamsType } from '../../../common/runtime_types' ;
14- import { AlertMonitorStatus } from '../../components/overview/alerts/alerts_containers' ;
1514import { MonitorStatusTitle } from './monitor_status_title' ;
1615import { CLIENT_ALERT_TYPES } from '../../../common/constants' ;
1716import { MonitorStatusTranslations } from './translations' ;
@@ -57,6 +56,10 @@ export const validate = (alertParams: any) => {
5756
5857const { defaultActionMessage } = MonitorStatusTranslations ;
5958
59+ const AlertMonitorStatus = React . lazy ( ( ) =>
60+ import ( '../../components/overview/alerts/alerts_containers/alert_monitor_status' )
61+ ) ;
62+
6063export const initMonitorStatusAlertType : AlertTypeInitializer = ( {
6164 autocomplete,
6265} ) : AlertTypeModel => ( {
Original file line number Diff line number Diff line change @@ -9,14 +9,15 @@ import { AlertTypeModel } from '../../../../triggers_actions_ui/public';
99import { CLIENT_ALERT_TYPES } from '../../../common/constants' ;
1010import { TlsTranslations } from './translations' ;
1111import { AlertTypeInitializer } from '.' ;
12- import { AlertTls } from '../../components/overview/alerts/alerts_containers/alert_tls' ;
1312
1413const { name, defaultActionMessage } = TlsTranslations ;
1514
1615export const initTlsAlertType : AlertTypeInitializer = ( ) : AlertTypeModel => ( {
1716 id : CLIENT_ALERT_TYPES . TLS ,
1817 iconClass : 'uptimeApp' ,
19- alertParamsExpression : ( ) => < AlertTls /> ,
18+ alertParamsExpression : React . lazy ( ( ) =>
19+ import ( '../../components/overview/alerts/alerts_containers/alert_tls' )
20+ ) ,
2021 name,
2122 validate : ( ) => ( { errors : { } } ) ,
2223 defaultActionMessage,
You can’t perform that action at this time.
0 commit comments