[Uptime] Added loading for certificates page on initial load (#111526)
This commit is contained in:
parent
b36ffc98fc
commit
032810e46a
2 changed files with 12 additions and 2 deletions
|
@ -15,7 +15,7 @@ import { CertMonitors } from './cert_monitors';
|
|||
import * as labels from './translations';
|
||||
import { Cert, CertMonitor } from '../../../common/runtime_types';
|
||||
import { FingerprintCol } from './fingerprint_col';
|
||||
import { NO_CERTS_AVAILABLE } from './translations';
|
||||
import { LOADING_CERTIFICATES, NO_CERTS_AVAILABLE } from './translations';
|
||||
|
||||
interface Page {
|
||||
index: number;
|
||||
|
@ -111,7 +111,13 @@ export const CertificateList: React.FC<Props> = ({ page, sort, onChange }) => {
|
|||
direction: sort.direction,
|
||||
},
|
||||
}}
|
||||
noItemsMessage={<span data-test-subj="uptimeCertsEmptyMessage">{NO_CERTS_AVAILABLE}</span>}
|
||||
noItemsMessage={
|
||||
loading ? (
|
||||
LOADING_CERTIFICATES
|
||||
) : (
|
||||
<span data-test-subj="uptimeCertsEmptyMessage">{NO_CERTS_AVAILABLE}</span>
|
||||
)
|
||||
}
|
||||
/>
|
||||
);
|
||||
};
|
||||
|
|
|
@ -70,3 +70,7 @@ export const COPY_FINGERPRINT = i18n.translate('xpack.uptime.certs.list.copyFing
|
|||
export const NO_CERTS_AVAILABLE = i18n.translate('xpack.uptime.certs.list.empty', {
|
||||
defaultMessage: 'No Certificates found. Note: Certificates are only visible for Heartbeat 7.8+',
|
||||
});
|
||||
|
||||
export const LOADING_CERTIFICATES = i18n.translate('xpack.uptime.certificates.loading', {
|
||||
defaultMessage: 'Loading certificates ...',
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue