(
-
-
- {status === 'up'
- ? i18n.translate('xpack.uptime.monitorList.statusColumn.upLabel', {
- defaultMessage: 'Up',
- })
- : i18n.translate('xpack.uptime.monitorList.statusColumn.downLabel', {
- defaultMessage: 'Down',
- })}
-
-
- {moment(get(monitor, 'ping.monitor.timestamp', undefined)).fromNow()}
-
-
- ),
- },
- {
- field: 'ping.monitor.id',
- name: i18n.translate('xpack.uptime.monitorList.idColumnLabel', {
- defaultMessage: 'ID',
- }),
- render: (id: string, monitor: LatestMonitor) => (
-
-
- {monitor.ping && monitor.ping.monitor && monitor.ping.monitor.name
- ? monitor.ping.monitor.name
- : id}
-
-
- ),
- },
- {
- field: 'ping.url.full',
- name: i18n.translate('xpack.uptime.monitorList.urlColumnLabel', {
- defaultMessage: 'URL',
- }),
- render: (url: string, monitor: LatestMonitor) => (
-
-
- {url}
-
- {monitor.ping && monitor.ping.monitor && monitor.ping.monitor.ip ? (
+export const MonitorListComponent = ({
+ basePath,
+ dangerColor,
+ dateRangeStart,
+ dateRangeEnd,
+ data,
+ linkParameters,
+ loading,
+}: Props) => {
+ return (
+
+
+
+
+
+
+
+ (
+
+
+ {status === 'up'
+ ? i18n.translate('xpack.uptime.monitorList.statusColumn.upLabel', {
+ defaultMessage: 'Up',
+ })
+ : i18n.translate('xpack.uptime.monitorList.statusColumn.downLabel', {
+ defaultMessage: 'Down',
+ })}
+
- {monitor.ping.monitor.ip}
+ {moment(get(monitor, 'ping.monitor.timestamp', undefined)).fromNow()}
- ) : null}
-
- ),
- },
- {
- field: 'upSeries',
- width: '180px',
- align: 'right',
- name: i18n.translate('xpack.uptime.monitorList.monitorHistoryColumnLabel', {
- defaultMessage: 'Downtime history',
- }),
- render: (downSeries: MonitorSeriesPoint, monitor: LatestMonitor) => (
-
- ),
- },
- ]}
- loading={loading}
- items={(data && data.monitorStatus && data.monitorStatus.monitors) || undefined}
- pagination={monitorListPagination}
- />
-
-);
+
+ ),
+ },
+ {
+ field: 'ping.monitor.id',
+ name: i18n.translate('xpack.uptime.monitorList.idColumnLabel', {
+ defaultMessage: 'ID',
+ }),
+ render: (id: string, monitor: LatestMonitor) => (
+
+
+ {monitor.ping && monitor.ping.monitor && monitor.ping.monitor.name
+ ? monitor.ping.monitor.name
+ : id}
+
+
+ ),
+ },
+ {
+ field: 'ping.url.full',
+ name: i18n.translate('xpack.uptime.monitorList.urlColumnLabel', {
+ defaultMessage: 'URL',
+ }),
+ render: (url: string, monitor: LatestMonitor) => (
+
+
+ {url}
+
+
+ ),
+ },
+ {
+ field: 'ping.url.full',
+ name: i18n.translate('xpack.uptime.monitorList.urlColumnLabel', {
+ defaultMessage: 'URL',
+ }),
+ render: (url: string, monitor: LatestMonitor) => (
+
+
+ {url}
+
+ {monitor.ping && monitor.ping.monitor && monitor.ping.monitor.ip ? (
+
+ {monitor.ping.monitor.ip}
+
+ ) : null}
+
+ ),
+ },
+ {
+ field: 'upSeries',
+ width: '180px',
+ align: 'right',
+ name: i18n.translate('xpack.uptime.monitorList.monitorHistoryColumnLabel', {
+ defaultMessage: 'Downtime history',
+ }),
+ render: (downSeries: MonitorSeriesPoint, monitor: LatestMonitor) => (
+
+ ),
+ },
+ {
+ align: 'right',
+ field: 'ping',
+ name: i18n.translate('xpack.uptime.monitorList.observabilityIntegrationsColumnLabel', {
+ defaultMessage: 'Integrations',
+ description:
+ 'The heading column of some action buttons that will take users to other Obsevability apps',
+ }),
+ render: (ping: Ping, monitor: LatestMonitor) => (
+
+ ),
+ },
+ ]}
+ loading={loading}
+ items={(data && data.monitorStatus && data.monitorStatus.monitors) || []}
+ pagination={monitorListPagination}
+ />
+