palash-signoz f1f606844a
chore: Eslint fix config (#882)
* chore: eslint config is updated

* chore: eslint auto fix is added
2022-03-22 12:10:31 +05:30

51 lines
1.1 KiB
TypeScript

import { Tabs } from 'antd';
import React from 'react';
import { Widgets } from 'types/api/dashboard/getAll';
import Application from './Tabs/Application';
import DBCall from './Tabs/DBCall';
import External from './Tabs/External';
const { TabPane } = Tabs;
function ServiceMetrics(): JSX.Element {
const getWidget = (query: Widgets['query']): Widgets => {
return {
description: '',
id: '',
isStacked: false,
nullZeroValues: '',
opacity: '0',
panelTypes: 'TIME_SERIES',
query,
queryData: {
data: [],
error: false,
errorMessage: '',
loading: false,
},
timePreferance: 'GLOBAL_TIME',
title: '',
stepSize: 60,
};
};
return (
<Tabs defaultActiveKey="1">
<TabPane animated destroyInactiveTabPane tab="Application Metrics" key="1">
<Application getWidget={getWidget} />
</TabPane>
<TabPane animated destroyInactiveTabPane tab="External Calls" key="2">
<External getWidget={getWidget} />
</TabPane>
<TabPane animated destroyInactiveTabPane tab="Database Calls" key="3">
<DBCall getWidget={getWidget} />
</TabPane>
</Tabs>
);
}
export default ServiceMetrics;