Skip to content

Commit

Permalink
shows instance details
Browse files Browse the repository at this point in the history
  • Loading branch information
cauemarcondes committed Apr 12, 2021
1 parent d67cabd commit ac9f697
Showing 1 changed file with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
* 2.0.
*/

import { EuiFlexGroup, EuiFlexItem, EuiLoadingSpinner } from '@elastic/eui';
import { EuiFlexGroup, EuiFlexItem, EuiLoadingContent } from '@elastic/eui';
import { i18n } from '@kbn/i18n';
import React from 'react';
import { isEmpty } from 'lodash';
import { useHistory } from 'react-router-dom';
import styled from 'styled-components';
import { pct } from '../../../../style/variables';
import { useApmServiceContext } from '../../../../context/apm_service/use_apm_service_context';
import { useUrlParams } from '../../../../context/url_params_context/use_url_params';
import { FETCH_STATUS, useFetcher } from '../../../../hooks/use_fetcher';
Expand All @@ -28,10 +28,6 @@ interface Props {
serviceNodeName: string;
}

const StyledEuiLoadingSpinner = styled(EuiLoadingSpinner)`
margin-left: 50%;
`;

export function InstanceDetails({ serviceName, serviceNodeName }: Props) {
const theme = useTheme();
const history = useHistory();
Expand Down Expand Up @@ -72,7 +68,11 @@ export function InstanceDetails({ serviceName, serviceNodeName }: Props) {
status === FETCH_STATUS.LOADING ||
status === FETCH_STATUS.NOT_INITIATED
) {
return <StyledEuiLoadingSpinner />;
return (
<div style={{ width: pct(50) }}>
<EuiLoadingContent />
</div>
);
}

if (!data) {
Expand Down

0 comments on commit ac9f697

Please sign in to comment.