diff --git a/openmetadata-ui/src/main/resources/ui/src/assets/svg/dollar-bag.svg b/openmetadata-ui/src/main/resources/ui/src/assets/svg/dollar-bag.svg
new file mode 100644
index 000000000000..1b1dcb0b66fd
--- /dev/null
+++ b/openmetadata-ui/src/main/resources/ui/src/assets/svg/dollar-bag.svg
@@ -0,0 +1,4 @@
+
\ No newline at end of file
diff --git a/openmetadata-ui/src/main/resources/ui/src/components/DataInsightDetail/AppAnalyticsTab/AppAnalyticsTab.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/DataInsightDetail/AppAnalyticsTab/AppAnalyticsTab.component.tsx
new file mode 100644
index 000000000000..d226023f50b9
--- /dev/null
+++ b/openmetadata-ui/src/main/resources/ui/src/components/DataInsightDetail/AppAnalyticsTab/AppAnalyticsTab.component.tsx
@@ -0,0 +1,48 @@
+/*
+ * Copyright 2023 Collate.
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+import { Col, Row } from 'antd';
+import React from 'react';
+import { useDataInsightProvider } from '../../../pages/DataInsightPage/DataInsightProvider';
+import DailyActiveUsersChart from '../DailyActiveUsersChart';
+import PageViewsByEntitiesChart from '../PageViewsByEntitiesChart';
+import TopActiveUsers from '../TopActiveUsers';
+import TopViewEntities from '../TopViewEntities';
+
+const AppAnalyticsTab = () => {
+ const { chartFilter, selectedDaysFilter } = useDataInsightProvider();
+
+ return (
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ );
+};
+
+export default AppAnalyticsTab;
diff --git a/openmetadata-ui/src/main/resources/ui/src/components/DataInsightDetail/DataAssetsTab/DataAssetsTab.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/DataInsightDetail/DataAssetsTab/DataAssetsTab.component.tsx
new file mode 100644
index 000000000000..86910c36ebaa
--- /dev/null
+++ b/openmetadata-ui/src/main/resources/ui/src/components/DataInsightDetail/DataAssetsTab/DataAssetsTab.component.tsx
@@ -0,0 +1,122 @@
+/*
+ * Copyright 2023 Collate.
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+import { Col, Row } from 'antd';
+import React, { useMemo } from 'react';
+import { useTranslation } from 'react-i18next';
+import { DataInsightChartType } from '../../../generated/dataInsight/dataInsightChartResult';
+import { useDataInsightProvider } from '../../../pages/DataInsightPage/DataInsightProvider';
+import Loader from '../../Loader/Loader';
+import DescriptionInsight from '../DescriptionInsight';
+import OwnerInsight from '../OwnerInsight';
+import TierInsight from '../TierInsight';
+import TotalEntityInsight from '../TotalEntityInsight';
+
+const DataAssetsTab = () => {
+ const {
+ chartFilter,
+ selectedDaysFilter,
+ kpi,
+ tierTag: tier,
+ } = useDataInsightProvider();
+ const { t } = useTranslation();
+ const { descriptionKpi, ownerKpi } = useMemo(() => {
+ return {
+ descriptionKpi: kpi.data.find(
+ (value) =>
+ value.dataInsightChart.name ===
+ DataInsightChartType.PercentageOfEntitiesWithDescriptionByType
+ ),
+ ownerKpi: kpi.data.find(
+ (value) =>
+ value.dataInsightChart.name ===
+ DataInsightChartType.PercentageOfEntitiesWithOwnerByType
+ ),
+ };
+ }, [kpi]);
+
+ if (kpi.isLoading) {
+ return ;
+ }
+
+ return (
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ );
+};
+
+export default DataAssetsTab;
diff --git a/openmetadata-ui/src/main/resources/ui/src/components/DataInsightDetail/DataAssetsTab/DataAssetsTab.interface.ts b/openmetadata-ui/src/main/resources/ui/src/components/DataInsightDetail/DataAssetsTab/DataAssetsTab.interface.ts
new file mode 100644
index 000000000000..cc8fc195b347
--- /dev/null
+++ b/openmetadata-ui/src/main/resources/ui/src/components/DataInsightDetail/DataAssetsTab/DataAssetsTab.interface.ts
@@ -0,0 +1,22 @@
+/*
+ * Copyright 2023 Collate.
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+import { Kpi } from '../../../generated/dataInsight/kpi/kpi';
+import { Tag } from '../../../generated/entity/classification/tag';
+import { ChartFilter } from '../../../interface/data-insight.interface';
+
+export interface DataAssetsTabProps {
+ chartFilter: ChartFilter;
+ selectedDaysFilter: number;
+ kpiList: Kpi[];
+ tier: { tags: Tag[]; isLoading: boolean };
+}
diff --git a/openmetadata-ui/src/main/resources/ui/src/components/DatePickerMenu/DatePickerMenu.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/DatePickerMenu/DatePickerMenu.component.tsx
index 03218926496f..21744b44afae 100644
--- a/openmetadata-ui/src/main/resources/ui/src/components/DatePickerMenu/DatePickerMenu.component.tsx
+++ b/openmetadata-ui/src/main/resources/ui/src/components/DatePickerMenu/DatePickerMenu.component.tsx
@@ -15,9 +15,11 @@ import { CloseCircleOutlined } from '@ant-design/icons';
import { Button, DatePicker, Dropdown, MenuProps, Space } from 'antd';
import { RangePickerProps } from 'antd/lib/date-picker';
import { isUndefined } from 'lodash';
+import { DateFilterType } from 'Models';
import { MenuInfo } from 'rc-menu/lib/interface';
-import React, { useState } from 'react';
+import React, { useMemo, useState } from 'react';
import { useTranslation } from 'react-i18next';
+
import { ReactComponent as DropdownIcon } from '../../assets/svg/DropDown.svg';
import { DateRangeObject } from '../../components/ProfilerDashboard/component/TestSummary';
import {
@@ -37,21 +39,56 @@ import './DatePickerMenu.style.less';
interface DatePickerMenuProps {
showSelectedCustomRange?: boolean;
handleDateRangeChange: (value: DateRangeObject, days?: number) => void;
+ options?: DateFilterType;
+ defaultValue?: string;
+ allowCustomRange?: boolean;
}
function DatePickerMenu({
showSelectedCustomRange,
handleDateRangeChange,
+ options,
+ defaultValue,
+ allowCustomRange = true,
}: DatePickerMenuProps) {
+ const { menuOptions, defaultOptions } = useMemo(() => {
+ let defaultOptions = DEFAULT_SELECTED_RANGE;
+
+ if (defaultValue) {
+ if (options && !isUndefined(options[defaultValue]?.title)) {
+ defaultOptions = {
+ title: options[defaultValue].title,
+ key: defaultValue,
+ days: options[defaultValue].days,
+ };
+ } else if (
+ !isUndefined(
+ PROFILER_FILTER_RANGE[defaultValue as keyof DateFilterType]?.title
+ )
+ ) {
+ defaultOptions = {
+ title: PROFILER_FILTER_RANGE[defaultValue].title,
+ key: defaultValue,
+ days: PROFILER_FILTER_RANGE[defaultValue].days,
+ };
+ }
+ }
+
+ return {
+ menuOptions: options ?? PROFILER_FILTER_RANGE,
+ defaultOptions,
+ };
+ }, [options]);
+
const { t } = useTranslation();
// State to display the label for selected range value
const [selectedTimeRange, setSelectedTimeRange] = useState(
- DEFAULT_SELECTED_RANGE.title
+ defaultOptions.title
);
// state to determine the selected value to highlight in the dropdown
- const [selectedTimeRangeKey, setSelectedTimeRangeKey] = useState<
- keyof typeof PROFILER_FILTER_RANGE
- >(DEFAULT_SELECTED_RANGE.key as keyof typeof PROFILER_FILTER_RANGE);
+ const [selectedTimeRangeKey, setSelectedTimeRangeKey] = useState(
+ defaultOptions.key
+ );
const [isMenuOpen, setIsMenuOpen] = useState(false);
@@ -73,62 +110,61 @@ function DatePickerMenu({
);
setSelectedTimeRange(selectedRangeLabel);
- setSelectedTimeRangeKey(
- 'customRange' as keyof typeof PROFILER_FILTER_RANGE
- );
+ setSelectedTimeRangeKey('customRange');
setIsMenuOpen(false);
handleDateRangeChange({ startTs, endTs }, daysCount);
}
};
const handleOptionClick = ({ key }: MenuInfo) => {
- const filterRange =
- PROFILER_FILTER_RANGE[key as keyof typeof PROFILER_FILTER_RANGE];
+ const filterRange = menuOptions[key];
if (isUndefined(filterRange)) {
return;
}
const selectedNumberOfDays = filterRange.days;
- const keyString = key as keyof typeof PROFILER_FILTER_RANGE;
const startTs = getEpochMillisForPastDays(selectedNumberOfDays);
const endTs = getCurrentMillis();
- setSelectedTimeRange(PROFILER_FILTER_RANGE[keyString].title);
- setSelectedTimeRangeKey(keyString);
+ setSelectedTimeRange(menuOptions[key].title);
+ setSelectedTimeRangeKey(key);
setIsMenuOpen(false);
handleDateRangeChange({ startTs, endTs }, selectedNumberOfDays);
};
const getMenuItems = () => {
- const items: MenuProps['items'] = Object.entries(PROFILER_FILTER_RANGE).map(
+ const items: MenuProps['items'] = Object.entries(menuOptions).map(
([key, value]) => ({
label: value.title,
key,
})
);
- items.push({
- label: t('label.custom-range'),
- key: 'customRange',
- children: [
- {
- label: (
- }
- format={(value) => value.utc().format('YYYY-MM-DD')}
- open={isMenuOpen}
- placement="bottomRight"
- suffixIcon={null}
- onChange={handleCustomDateChange}
- />
- ),
- key: 'datePicker',
- },
- ],
- popupClassName: 'date-picker-sub-menu-popup',
- });
+ {
+ allowCustomRange &&
+ items.push({
+ label: t('label.custom-range'),
+ key: 'customRange',
+ children: [
+ {
+ label: (
+ }
+ format={(value) => value.utc().format('YYYY-MM-DD')}
+ open={isMenuOpen}
+ placement="bottomRight"
+ suffixIcon={null}
+ onChange={handleCustomDateChange}
+ />
+ ),
+ key: 'datePicker',
+ },
+ ],
+ popupClassName: 'date-picker-sub-menu-popup',
+ });
+ }
return items;
};
diff --git a/openmetadata-ui/src/main/resources/ui/src/constants/LeftSidebar.constants.ts b/openmetadata-ui/src/main/resources/ui/src/constants/LeftSidebar.constants.ts
index fe3142ae2aa9..29a02c1a8f56 100644
--- a/openmetadata-ui/src/main/resources/ui/src/constants/LeftSidebar.constants.ts
+++ b/openmetadata-ui/src/main/resources/ui/src/constants/LeftSidebar.constants.ts
@@ -19,6 +19,7 @@ import { ReactComponent as DomainsIcon } from '../assets/svg/ic-domain.svg';
import { ReactComponent as QualityIcon } from '../assets/svg/ic-quality-v1.svg';
import { ReactComponent as SettingsIcon } from '../assets/svg/ic-settings-v1.svg';
import { ReactComponent as InsightsIcon } from '../assets/svg/lampcharge.svg';
+import { getDataInsightPathWithFqn } from '../utils/DataInsightUtils';
import { ROUTES } from './constants';
export const SIDEBAR_LIST = [
@@ -39,7 +40,7 @@ export const SIDEBAR_LIST = [
{
key: ROUTES.DATA_INSIGHT,
label: i18next.t('label.insight-plural'),
- redirect_url: ROUTES.DATA_INSIGHT,
+ redirect_url: getDataInsightPathWithFqn(),
icon: InsightsIcon,
dataTestId: 'app-bar-item-data-insight',
},
diff --git a/openmetadata-ui/src/main/resources/ui/src/constants/profiler.constant.ts b/openmetadata-ui/src/main/resources/ui/src/constants/profiler.constant.ts
index 1c30b0f4f61e..24376d3d3811 100644
--- a/openmetadata-ui/src/main/resources/ui/src/constants/profiler.constant.ts
+++ b/openmetadata-ui/src/main/resources/ui/src/constants/profiler.constant.ts
@@ -12,7 +12,7 @@
*/
import { t } from 'i18next';
-import { StepperStepType } from 'Models';
+import { DateFilterType, StepperStepType } from 'Models';
import { CSMode } from '../enums/codemirror.enum';
import { DMLOperationType } from '../generated/api/data/createTableProfile';
import {
@@ -71,7 +71,7 @@ export const PROFILER_METRIC = [
'customMetricsProfile',
];
-export const PROFILER_FILTER_RANGE = {
+export const PROFILER_FILTER_RANGE: DateFilterType = {
yesterday: {
days: 1,
title: t('label.yesterday'),
diff --git a/openmetadata-ui/src/main/resources/ui/src/enums/DataInsight.enum.ts b/openmetadata-ui/src/main/resources/ui/src/enums/DataInsight.enum.ts
new file mode 100644
index 000000000000..c186f50ac319
--- /dev/null
+++ b/openmetadata-ui/src/main/resources/ui/src/enums/DataInsight.enum.ts
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2023 Collate.
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+export enum DataInsightIndex {
+ AGGREGATED_COST_ANALYSIS_REPORT_DATA = 'aggregated_cost_analysis_report_data_index',
+}
diff --git a/openmetadata-ui/src/main/resources/ui/src/interface/data-insight.interface.ts b/openmetadata-ui/src/main/resources/ui/src/interface/data-insight.interface.ts
index 9b3c682d0816..55e01ce7537c 100644
--- a/openmetadata-ui/src/main/resources/ui/src/interface/data-insight.interface.ts
+++ b/openmetadata-ui/src/main/resources/ui/src/interface/data-insight.interface.ts
@@ -12,15 +12,21 @@
*/
import { TooltipProps } from 'recharts';
+import { DataInsightIndex } from '../enums/DataInsight.enum';
+import { ReportData } from '../generated/analytics/reportData';
import { DataReportIndex } from '../generated/dataInsight/dataInsightChart';
import { DataInsightChartType } from '../generated/dataInsight/dataInsightChartResult';
import { KpiResult, KpiTargetType } from '../generated/dataInsight/kpi/kpi';
+import { KeysOfUnion } from './search.interface';
export interface ChartAggregateParam {
dataInsightChartName: DataInsightChartType;
dataReportIndex: DataReportIndex;
- startTs: number;
- endTs: number;
+ startTs?: number;
+ endTs?: number;
+ from?: number;
+ size?: number;
+ queryFilter?: string;
tier?: string;
team?: string;
}
@@ -36,6 +42,7 @@ export interface DataInsightChartTooltipProps extends TooltipProps {
isPercentage?: boolean;
isTier?: boolean;
kpiTooltipRecord?: Record;
+ valueFormatter?: (value: number | string) => string;
}
export interface UIKpiResult extends KpiResult {
@@ -50,6 +57,7 @@ export enum DataInsightTabs {
DATA_ASSETS = 'data-assets',
APP_ANALYTICS = 'app-analytics',
KPIS = 'kpi',
+ COST_ANALYSIS = 'cost-analysis',
}
export enum KpiDate {
@@ -62,3 +70,31 @@ export type KpiDates = {
};
export type ChartValue = string | number | undefined;
+
+export type AggregatedCostAnalysisReportDataSearchSource = ReportData; // extends EntityInterface
+
+export type DataInsightSearchSourceMapping = {
+ [DataInsightIndex.AGGREGATED_COST_ANALYSIS_REPORT_DATA]: AggregatedCostAnalysisReportDataSearchSource;
+};
+
+export type DataInsightSearchRequest = {
+ pageNumber?: number;
+ pageSize?: number;
+ searchIndex?: DataInsightIndex.AGGREGATED_COST_ANALYSIS_REPORT_DATA;
+ query?: string;
+ queryFilter?: Record;
+ postFilter?: Record;
+ sortField?: string;
+ sortOrder?: string;
+ includeDeleted?: boolean;
+ trackTotalHits?: boolean;
+ filters?: string;
+} & (
+ | {
+ fetchSource: true;
+ includeFields?: KeysOfUnion[];
+ }
+ | {
+ fetchSource?: false;
+ }
+);
diff --git a/openmetadata-ui/src/main/resources/ui/src/interface/search.interface.ts b/openmetadata-ui/src/main/resources/ui/src/interface/search.interface.ts
index b7e8bc0e977a..9e5ec99dabda 100644
--- a/openmetadata-ui/src/main/resources/ui/src/interface/search.interface.ts
+++ b/openmetadata-ui/src/main/resources/ui/src/interface/search.interface.ts
@@ -11,6 +11,7 @@
* limitations under the License.
*/
+import { DataInsightIndex } from '../enums/DataInsight.enum';
import { SearchIndex } from '../enums/search.enum';
import { Tag } from '../generated/entity/classification/tag';
import { Container } from '../generated/entity/data/container';
@@ -39,6 +40,7 @@ import { User } from '../generated/entity/teams/user';
import { TestCase } from '../generated/tests/testCase';
import { TestSuite } from '../generated/tests/testSuite';
import { TagLabel } from '../generated/type/tagLabel';
+import { AggregatedCostAnalysisReportDataSearchSource } from './data-insight.interface';
/**
* The `keyof` operator, when applied to a union type, expands to the keys are common for
@@ -252,7 +254,7 @@ export type SuggestRequest<
}
);
-export interface SearchHitBody {
+export interface SearchHitBody {
_index: SI;
_type?: string;
_id?: string;
@@ -296,6 +298,22 @@ export interface SearchResponse<
export type Aggregations = Record;
+export type DataInsightSearchResponse = {
+ took?: number;
+ timed_out?: boolean;
+ hits: {
+ total: {
+ value: number;
+ relation?: string;
+ };
+ hits: SearchHitBody<
+ DataInsightIndex,
+ AggregatedCostAnalysisReportDataSearchSource
+ >[];
+ };
+ aggregations: Aggregations;
+};
+
/**
* Because we are using an older version of typescript-eslint, defining
* ```ts
diff --git a/openmetadata-ui/src/main/resources/ui/src/interface/types.d.ts b/openmetadata-ui/src/main/resources/ui/src/interface/types.d.ts
index 7fa1df763bf7..47328f892790 100644
--- a/openmetadata-ui/src/main/resources/ui/src/interface/types.d.ts
+++ b/openmetadata-ui/src/main/resources/ui/src/interface/types.d.ts
@@ -261,6 +261,8 @@ declare module 'Models' {
| Mlmodel
| Container;
+ export type DateFilterType = Record;
+
export type TagFilterOptions = {
text: string;
value: string;
diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/de-de.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/de-de.json
index b4df4dfa688b..6d3dc2d0aa32 100644
--- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/de-de.json
+++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/de-de.json
@@ -4,6 +4,7 @@
"accept": "Akzeptieren",
"accept-suggestion": "Vorschlag akzeptieren",
"access": "Zugriff",
+ "accessed": "Accessed",
"account": "Konto",
"account-email": "Konto-E-Mail",
"account-name": "Kontoname",
@@ -104,6 +105,7 @@
"back-to-login-lowercase": "Zurück zur Anmeldeseite",
"basic-configuration": "Grundkonfiguration",
"batch-size": "Batchgröße",
+ "before-number-of-day-plural": "Before {{numberOfDays}} days",
"beta": "Beta",
"bot": "Bot",
"bot-detail": "Bot-Details",
@@ -182,6 +184,7 @@
"conversation-plural": "Konversationen",
"copied": "Kopiert",
"copy": "Kopieren",
+ "cost-analysis": "Cost Analysis",
"count": "Anzahl",
"create": "Erstellen",
"create-entity": "{{entity}} erstellen",
@@ -530,6 +533,7 @@
"kpi-name": "KPI-Name",
"kpi-title": "Schlüsselindikatoren (KPI)",
"kpi-uppercase": "KPI",
+ "kpi-uppercase-plural": "KPIs",
"language": "Sprache",
"last": "Letzte",
"last-error": "Letzter Fehler",
@@ -905,6 +909,7 @@
"show-or-hide-advanced-config": "{{showAdv}} Erweiterte Konfiguration anzeigen/ausblenden",
"sign-in-with-sso": "Mit {{sso}} anmelden",
"size": "Größe",
+ "size-evolution-graph": "Size Evolution Graph",
"skew": "Verzerrung",
"skipped": "Übersprungen",
"slack": "Slack",
@@ -1483,6 +1488,7 @@
"service-with-space-not-allowed": "Dienstname mit Leerzeichen ist nicht zulässig",
"session-expired": "Ihre Sitzung ist abgelaufen! Bitte melden Sie sich erneut an, um auf OpenMetadata zuzugreifen.",
"setup-custom-property": "OpenMetadata unterstützt benutzerdefinierte Eigenschaften in der Tabellenentität. Erstellen Sie eine benutzerdefinierte Eigenschaft, indem Sie einen eindeutigen Eigenschaftsnamen hinzufügen. Der Name muss mit einem Kleinbuchstaben beginnen, wie im camelCase-Format bevorzugt. Großbuchstaben und Zahlen können im Feldnamen enthalten sein; Leerzeichen, Unterstriche und Punkte werden jedoch nicht unterstützt. Wählen Sie den bevorzugten Eigenschaftstyp aus den angebotenen Optionen aus. Beschreiben Sie Ihre benutzerdefinierte Eigenschaft, um Ihrem Team mehr Informationen zu geben.",
+ "size-evolution-description": "Size evolution of assets in organization.",
"soft-delete-message-for-entity": "Durch das Soft-Löschen wird {{entity}} deaktiviert. Dadurch werden alle Entdeckungs-, Lese- oder Schreibvorgänge auf {{entity}} deaktiviert.",
"something-went-wrong": "Etwas ist schiefgelaufen",
"special-character-not-allowed": "Sonderzeichen sind nicht erlaubt.",
diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/en-us.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/en-us.json
index fb997591b875..cf8747dcb4f5 100644
--- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/en-us.json
+++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/en-us.json
@@ -4,6 +4,7 @@
"accept": "Accept",
"accept-suggestion": "Accept Suggestion",
"access": "Access",
+ "accessed": "Accessed",
"account": "Account",
"account-email": "Account email",
"account-name": "Account Name",
@@ -104,6 +105,7 @@
"back-to-login-lowercase": "back to login",
"basic-configuration": "Basic Configuration",
"batch-size": "Batch Size",
+ "before-number-of-day-plural": "Before {{numberOfDays}} days",
"beta": "Beta",
"bot": "Bot",
"bot-detail": "Bot detail",
@@ -182,6 +184,7 @@
"conversation-plural": "Conversations",
"copied": "Copied",
"copy": "Copy",
+ "cost-analysis": "Cost Analysis",
"count": "Count",
"create": "Create",
"create-entity": "Create {{entity}}",
@@ -530,6 +533,7 @@
"kpi-name": "KPI Name",
"kpi-title": "Key Performance Indicators (KPI)",
"kpi-uppercase": "KPI",
+ "kpi-uppercase-plural": "KPIs",
"language": "Language",
"last": "Last",
"last-error": "Last error",
@@ -905,6 +909,7 @@
"show-or-hide-advanced-config": "{{showAdv}} Advanced Config",
"sign-in-with-sso": "Sign in with {{sso}}",
"size": "Size",
+ "size-evolution-graph": "Size Evolution Graph",
"skew": "Skew",
"skipped": "Skipped",
"slack": "Slack",
@@ -1483,6 +1488,7 @@
"service-with-space-not-allowed": "Service name with spaces are not allowed",
"session-expired": "Your session has timed out! Please sign in again to access OpenMetadata.",
"setup-custom-property": "OpenMetadata supports custom properties in the Table entity. Create a custom property by adding a unique property name. The name must start with a lowercase letter, as preferred in the camelCase format. Uppercase letters and numbers can be included in the field name; but spaces, underscores, and dots are not supported. Select the preferred property Type from among the options provided. Describe your custom property to provide more information to your team.",
+ "size-evolution-description": "Size evolution of assets in organization.",
"soft-delete-message-for-entity": "Soft deleting will deactivate the {{entity}}. This will disable any discovery, read or write operations on {{entity}}.",
"something-went-wrong": "Something went wrong",
"special-character-not-allowed": "Special characters are not allowed.",
diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/es-es.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/es-es.json
index 521db7ece44e..6d3bdc03d7c6 100644
--- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/es-es.json
+++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/es-es.json
@@ -4,6 +4,7 @@
"accept": "Accept",
"accept-suggestion": "Aceptar sugerencia",
"access": "Acceso",
+ "accessed": "Accessed",
"account": "Cuenta",
"account-email": "Correo electrónico de la cuenta",
"account-name": "Account Name",
@@ -104,6 +105,7 @@
"back-to-login-lowercase": "volver a iniciar sesión",
"basic-configuration": "Configuración básica",
"batch-size": "Tamaño del lote",
+ "before-number-of-day-plural": "Before {{numberOfDays}} days",
"beta": "Beta",
"bot": "Bot",
"bot-detail": "Detalles del bot",
@@ -182,6 +184,7 @@
"conversation-plural": "Conversaciones",
"copied": "Copied",
"copy": "Copiar",
+ "cost-analysis": "Cost Analysis",
"count": "Conteo",
"create": "Crear",
"create-entity": "Crear {{entity}}",
@@ -530,6 +533,7 @@
"kpi-name": "Nombre del KPI",
"kpi-title": "Indicadores clave de rendimiento (KPI)",
"kpi-uppercase": "KPI",
+ "kpi-uppercase-plural": "KPIs",
"language": "Idioma",
"last": "Último",
"last-error": "Último error",
@@ -905,6 +909,7 @@
"show-or-hide-advanced-config": "{{showAdv}} Configuración Avanzada",
"sign-in-with-sso": "Iniciar sesión con {{sso}}",
"size": "Tamaño",
+ "size-evolution-graph": "Size Evolution Graph",
"skew": "Sesgo",
"skipped": "Skipped",
"slack": "Slack",
@@ -1483,6 +1488,7 @@
"service-with-space-not-allowed": "No se permiten nombres de servicio con espacios",
"session-expired": "¡Tu sesión ha caducado! Por favor, inicia sesión de nuevo para acceder a OpenMetadata.",
"setup-custom-property": "OpenMetadata admite propiedades personalizadas en la entidad de Tabla. Crea una propiedad personalizada agregando un nombre de propiedad único. El nombre debe comenzar con una letra minúscula, como se prefiere en el formato camelCase. Las letras mayúsculas y los números pueden incluirse en el nombre del campo; pero no se admiten espacios, guiones bajos y puntos. Selecciona el tipo de propiedad preferido entre las opciones proporcionadas. Describe tu propiedad personalizada para proporcionar más información a tu equipo.",
+ "size-evolution-description": "Size evolution of assets in organization.",
"soft-delete-message-for-entity": "La eliminación suave desactivará la {{entity}}. Esto deshabilitará cualquier operación de descubrimiento, lectura o escritura en {{entity}}.",
"something-went-wrong": "Algo salió mal",
"special-character-not-allowed": "No se permiten caracteres especiales.",
diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/fr-fr.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/fr-fr.json
index 5385f8abb772..30e48013b751 100644
--- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/fr-fr.json
+++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/fr-fr.json
@@ -4,6 +4,7 @@
"accept": "Accepter",
"accept-suggestion": "Accepter la Suggestion",
"access": "Accès",
+ "accessed": "Accessed",
"account": "Compte",
"account-email": "Compte email",
"account-name": "Nom du Compte",
@@ -104,6 +105,7 @@
"back-to-login-lowercase": "Retour à la Page de Connexion",
"basic-configuration": "Configuration de Base",
"batch-size": "Taille du Lot",
+ "before-number-of-day-plural": "Before {{numberOfDays}} days",
"beta": "Bêta",
"bot": "Agent Numérique",
"bot-detail": "Détail de l'Agent Numérique",
@@ -182,6 +184,7 @@
"conversation-plural": "Conversations",
"copied": "Copié",
"copy": "Copier",
+ "cost-analysis": "Cost Analysis",
"count": "Décompte",
"create": "Créer",
"create-entity": "Créer {{entity}}",
@@ -530,6 +533,7 @@
"kpi-name": "Nom des KPI",
"kpi-title": "Indicateurs de Performance Clés (KPI)",
"kpi-uppercase": "KPI",
+ "kpi-uppercase-plural": "KPIs",
"language": "Langage",
"last": "Dernier·ère",
"last-error": "Dernière erreur",
@@ -905,6 +909,7 @@
"show-or-hide-advanced-config": "{{showAdv}} Configuration Avancée",
"sign-in-with-sso": "Se Connecter avec {{sso}}",
"size": "Taille",
+ "size-evolution-graph": "Size Evolution Graph",
"skew": "Déviation",
"skipped": "Passé",
"slack": "Slack",
@@ -1483,6 +1488,7 @@
"service-with-space-not-allowed": "Nom de service avec des espaces ne sont pas autorisés",
"session-expired": "Votre session a expiré! Veuillez vous connecter à nouveau pour accéder à OpenMetadata.",
"setup-custom-property": "OpenMetadata permet la création de propriétés custom dans les entités table. Créez une propriété custom en ajoutant un nom de propriété unique. Le nom doit commencer par une lettre minuscule, comme préféré dans le format camelCase. Les lettres majuscules et les chiffres peuvent être inclus dans le nom du champ; mais les espaces, les tirets bas et les points ne sont pas pris en charge. Sélectionnez le Type de propriété préféré parmi les options fournies. Décrivez votre propriété personnalisée pour fournir plus d'informations à votre équipe.",
+ "size-evolution-description": "Size evolution of assets in organization.",
"soft-delete-message-for-entity": "La suppression logique désactivera le {{entity}}. Cela désactivera toute découverte, lecture ou écriture sur le {{entity}}.",
"something-went-wrong": "Quelque chose s'est mal passé",
"special-character-not-allowed": "Les caractères spéciaux ne sont pas autorisés",
diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/ja-jp.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/ja-jp.json
index c933c71377ae..2ee867e92043 100644
--- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/ja-jp.json
+++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/ja-jp.json
@@ -4,6 +4,7 @@
"accept": "Accept",
"accept-suggestion": "提案を受け入れる",
"access": "アクセス",
+ "accessed": "Accessed",
"account": "アカウント",
"account-email": "アカウントのEmail",
"account-name": "Account Name",
@@ -104,6 +105,7 @@
"back-to-login-lowercase": "ログインに戻る",
"basic-configuration": "Basic Configuration",
"batch-size": "バッチサイズ",
+ "before-number-of-day-plural": "Before {{numberOfDays}} days",
"beta": "Beta",
"bot": "ボット",
"bot-detail": "ボットの詳細",
@@ -182,6 +184,7 @@
"conversation-plural": "会話",
"copied": "Copied",
"copy": "Copy",
+ "cost-analysis": "Cost Analysis",
"count": "Count",
"create": "作成",
"create-entity": "{{entity}}を作成",
@@ -530,6 +533,7 @@
"kpi-name": "KPI名",
"kpi-title": "Key Performance Indicators (KPI)",
"kpi-uppercase": "KPI",
+ "kpi-uppercase-plural": "KPIs",
"language": "言語",
"last": "最新",
"last-error": "最新のエラー",
@@ -905,6 +909,7 @@
"show-or-hide-advanced-config": "{{showAdv}} 高度な設定",
"sign-in-with-sso": "{{sso}}でサインインする",
"size": "Size",
+ "size-evolution-graph": "Size Evolution Graph",
"skew": "Skew",
"skipped": "Skipped",
"slack": "Slack",
@@ -1483,6 +1488,7 @@
"service-with-space-not-allowed": "サービス名に空白は使えません",
"session-expired": "セッションがタイムアウトしました。OpenMetadataにアクセスするには再度サインインしてください。",
"setup-custom-property": "OpenMetadataはテーブル要素のカスタムプロパティをサポートしています。カスタムプロパティを作成するにはユニークなプロパティ名を追加してください。プロパティ名は小文字のアルファベットから始め、かつキャメルケースであることが望ましいです。フィールド名に大文字と数字を含めることはできますが、スペースやアンダースコア、ドットはサポートされていません。提供されたオプションの中から適切なプロパティタイプを選択してください。カスタムプロパティの説明はチームにより多くの情報を提供します。",
+ "size-evolution-description": "Size evolution of assets in organization.",
"soft-delete-message-for-entity": "ソフトデリートは{{entity}}を非活性化します。これはデータの発見や、{{entity}}に対する読み込みや書き込みの操作を無効にします。",
"something-went-wrong": "何らかの問題が発生しました",
"special-character-not-allowed": "特殊文字は使用できません。",
diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-br.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-br.json
index fce398871efe..de64c6aac678 100644
--- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-br.json
+++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-br.json
@@ -4,6 +4,7 @@
"accept": "Accept",
"accept-suggestion": "Aceitar sugestão",
"access": "Acesso",
+ "accessed": "Accessed",
"account": "Conta",
"account-email": "E-mail da conta",
"account-name": "Account Name",
@@ -104,6 +105,7 @@
"back-to-login-lowercase": "voltar para login",
"basic-configuration": "Configuração básica",
"batch-size": "Tamanho do batch",
+ "before-number-of-day-plural": "Before {{numberOfDays}} days",
"beta": "Beta",
"bot": "Bot",
"bot-detail": "Detalhe do bot",
@@ -182,6 +184,7 @@
"conversation-plural": "Conversas",
"copied": "Copied",
"copy": "Copy",
+ "cost-analysis": "Cost Analysis",
"count": "Contar",
"create": "Criar",
"create-entity": "Criar {{entity}}",
@@ -530,6 +533,7 @@
"kpi-name": "Nome do KPI",
"kpi-title": "Título do KPI",
"kpi-uppercase": "KPI",
+ "kpi-uppercase-plural": "KPIs",
"language": "Idioma",
"last": "Último",
"last-error": "Último erro",
@@ -905,6 +909,7 @@
"show-or-hide-advanced-config": "{{showAdv}} Configuração Avançada",
"sign-in-with-sso": "Entrar com {{sso}}",
"size": "Size",
+ "size-evolution-graph": "Size Evolution Graph",
"skew": "Inclinação",
"skipped": "Skipped",
"slack": "Slack",
@@ -1483,6 +1488,7 @@
"service-with-space-not-allowed": "Nomes de serviços com espaços não são permitidos",
"session-expired": "Sua sessão expirou! Por favor, faça login novamente para acessar o OpenMetadata.",
"setup-custom-property": "O OpenMetadata suporta propriedades personalizadas na entidade Tabela. Crie uma propriedade personalizada adicionando um nome de propriedade exclusivo. O nome deve começar com uma letra minúscula, como preferido no formato camelCase. Letras maiúsculas e números podem ser incluídos no nome do campo; mas espaços, sublinhados e pontos não são suportados. Selecione o Tipo de propriedade preferido entre as opções fornecidas. Descreva sua propriedade personalizada para fornecer mais informações à sua equipe.",
+ "size-evolution-description": "Size evolution of assets in organization.",
"soft-delete-message-for-entity": "O soft delete desativará a {{entity}}. Isso desabilitará quaisquer operações de descoberta, leitura ou gravação na {{entity}}.",
"something-went-wrong": "Algo deu errado",
"special-character-not-allowed": "Caracteres especiais não são permitidos.",
diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/ru-ru.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/ru-ru.json
index c7c8abc2912f..3d24342e4370 100644
--- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/ru-ru.json
+++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/ru-ru.json
@@ -4,6 +4,7 @@
"accept": "Принять",
"accept-suggestion": "Согласовать предложение",
"access": "Доступ",
+ "accessed": "Accessed",
"account": "Аккаунт",
"account-email": "Адрес электронной почты",
"account-name": "Наименование аккаунта",
@@ -104,6 +105,7 @@
"back-to-login-lowercase": "Вернуться на страницу входа",
"basic-configuration": "Базовая конфигурация",
"batch-size": "Размер пакета",
+ "before-number-of-day-plural": "Before {{numberOfDays}} days",
"beta": "Бета",
"bot": "Бот",
"bot-detail": "Детали бота",
@@ -182,6 +184,7 @@
"conversation-plural": "Обсуждения",
"copied": "Скопировано",
"copy": "Скопировать",
+ "cost-analysis": "Cost Analysis",
"count": "Количество",
"create": "Создать",
"create-entity": "Создать {{entity}}",
@@ -530,6 +533,7 @@
"kpi-name": "Наименование KPI",
"kpi-title": "Ключевой показатель эффективности (KPI)",
"kpi-uppercase": "KPI",
+ "kpi-uppercase-plural": "KPIs",
"language": "Язык",
"last": "Последний",
"last-error": "Последняя ошибка",
@@ -905,6 +909,7 @@
"show-or-hide-advanced-config": "{{showAdv}} Расширенная конфигурация",
"sign-in-with-sso": "Войдите с помощью {{sso}}",
"size": "Размер",
+ "size-evolution-graph": "Size Evolution Graph",
"skew": "Перекос",
"skipped": "Пропущено",
"slack": "Slack",
@@ -1483,6 +1488,7 @@
"service-with-space-not-allowed": "Имя службы с пробелами не допускается",
"session-expired": "Время вашей сессии истекло! Пожалуйста, войдите снова, чтобы получить доступ к OpenMetadata.",
"setup-custom-property": "OpenMetadata поддерживает настраиваемые свойства в табличном объекте. Создайте пользовательское свойство, добавив уникальное имя свойства. Имя должно начинаться со строчной буквы, что является предпочтительным в формате camelCase. В имя поля можно включать прописные буквы и цифры; но пробелы, символы подчеркивания и точки не поддерживаются. Выберите предпочтительный тип свойства из предложенных вариантов. Опишите свое пользовательское свойство, чтобы предоставить больше информации вашей команде.",
+ "size-evolution-description": "Size evolution of assets in organization.",
"soft-delete-message-for-entity": "Мягкое удаление деактивирует {{entity}}. Это отключит любые операции обнаружения, чтения или записи для {{entity}}.",
"something-went-wrong": "Что-то пошло не так",
"special-character-not-allowed": "Спецсимволы не допустимы.",
diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-cn.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-cn.json
index 4dae6466e293..855a65d4658d 100644
--- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-cn.json
+++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-cn.json
@@ -4,6 +4,7 @@
"accept": "接受",
"accept-suggestion": "接受建议",
"access": "访问",
+ "accessed": "Accessed",
"account": "帐号",
"account-email": "帐号邮箱",
"account-name": "帐号名称",
@@ -104,6 +105,7 @@
"back-to-login-lowercase": "返回登录",
"basic-configuration": "基本配置",
"batch-size": "批大小",
+ "before-number-of-day-plural": "Before {{numberOfDays}} days",
"beta": "Beta",
"bot": "机器人",
"bot-detail": "机器人详情",
@@ -182,6 +184,7 @@
"conversation-plural": "对话",
"copied": "已复制",
"copy": "复制",
+ "cost-analysis": "Cost Analysis",
"count": "计数",
"create": "新建",
"create-entity": "新建{{entity}}",
@@ -530,6 +533,7 @@
"kpi-name": "KPI 名称",
"kpi-title": "关键绩效指标 (KPI)",
"kpi-uppercase": "KPI",
+ "kpi-uppercase-plural": "KPIs",
"language": "语言",
"last": "最近",
"last-error": "最近错误",
@@ -905,6 +909,7 @@
"show-or-hide-advanced-config": "{{showAdv}}高级配置",
"sign-in-with-sso": "使用 {{sso}} 单点登录",
"size": "大小",
+ "size-evolution-graph": "Size Evolution Graph",
"skew": "偏态",
"skipped": "已跳过",
"slack": "Slack",
@@ -1483,6 +1488,7 @@
"service-with-space-not-allowed": "服务名称不允许使用空格",
"session-expired": "您的会话已超时,请重新登录!",
"setup-custom-property": "OpenMetadata 支持数据表中的自定义属性。通过添加唯一的属性名称来创建自定义属性。名称必须以小写字母开头,以 camelCase 驼峰格式为首选。字段名称可以包含大写字母和数字,但不支持空格、下划线和标点符号。从提供的选项中指定一个属性类型,并通过描述您的自定义属性向团队提供更多信息。",
+ "size-evolution-description": "Size evolution of assets in organization.",
"soft-delete-message-for-entity": "软删除将停用{{entity}},这将禁用{{entity}}上的任何发现、读取或写入操作",
"something-went-wrong": "出现了一些问题",
"special-character-not-allowed": "不允许使用特殊字符",
diff --git a/openmetadata-ui/src/main/resources/ui/src/pages/DataInsightPage/DataInsight.interface.ts b/openmetadata-ui/src/main/resources/ui/src/pages/DataInsightPage/DataInsight.interface.ts
index 4ee215c09d4f..2fe283cf2087 100644
--- a/openmetadata-ui/src/main/resources/ui/src/pages/DataInsightPage/DataInsight.interface.ts
+++ b/openmetadata-ui/src/main/resources/ui/src/pages/DataInsightPage/DataInsight.interface.ts
@@ -11,7 +11,15 @@
* limitations under the License.
*/
-import { SearchDropdownOption } from '../../components/SearchDropdown/SearchDropdown.interface';
+import { ReactNode } from 'react';
+import { DateRangeObject } from '../../components/ProfilerDashboard/component/TestSummary';
+import {
+ SearchDropdownOption,
+ SearchDropdownProps,
+} from '../../components/SearchDropdown/SearchDropdown.interface';
+import { Kpi } from '../../generated/dataInsight/kpi/kpi';
+import { Tag } from '../../generated/entity/classification/tag';
+import { ChartFilter } from '../../interface/data-insight.interface';
export type TeamStateType = {
defaultOptions: SearchDropdownOption[];
@@ -19,3 +27,23 @@ export type TeamStateType = {
options: SearchDropdownOption[];
};
export type TierStateType = Omit;
+
+export interface DataInsightProviderProps {
+ children: ReactNode;
+}
+
+export interface DataInsightContextType {
+ teamFilter: Omit;
+ tierFilter: Omit;
+ selectedDaysFilter: number;
+ chartFilter: ChartFilter;
+ onChartFilterChange: (value: DateRangeObject, days?: number) => void;
+ kpi: {
+ isLoading: boolean;
+ data: Kpi[];
+ };
+ tierTag: {
+ tags: Tag[];
+ isLoading: boolean;
+ };
+}
diff --git a/openmetadata-ui/src/main/resources/ui/src/pages/DataInsightPage/DataInsightClassBase.ts b/openmetadata-ui/src/main/resources/ui/src/pages/DataInsightPage/DataInsightClassBase.ts
new file mode 100644
index 000000000000..c3499740a065
--- /dev/null
+++ b/openmetadata-ui/src/main/resources/ui/src/pages/DataInsightPage/DataInsightClassBase.ts
@@ -0,0 +1,84 @@
+/*
+ * Copyright 2023 Collate.
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+import { ReactComponent as AppAnalyticsIcon } from '../../assets/svg/app-analytics.svg';
+import { ReactComponent as DataAssetsIcon } from '../../assets/svg/data-asset.svg';
+import { ReactComponent as KPIIcon } from '../../assets/svg/kpi.svg';
+import AppAnalyticsTab from '../../components/DataInsightDetail/AppAnalyticsTab/AppAnalyticsTab.component';
+import DataAssetsTab from '../../components/DataInsightDetail/DataAssetsTab/DataAssetsTab.component';
+import { DataInsightTabs } from '../../interface/data-insight.interface';
+import { getDataInsightPathWithFqn } from '../../utils/DataInsightUtils';
+import i18n from '../../utils/i18next/LocalUtil';
+import KPIList from './KPIList';
+
+type LeftSideBarType = {
+ key: DataInsightTabs;
+ label: string;
+ icon: SvgComponent;
+ iconProps: React.SVGProps;
+};
+
+class DataInsightClassBase {
+ public getLeftSideBar(): LeftSideBarType[] {
+ return [
+ {
+ key: DataInsightTabs.DATA_ASSETS,
+ label: i18n.t('label.data-asset-plural'),
+ icon: AppAnalyticsIcon,
+ iconProps: {
+ className: 'side-panel-icons',
+ },
+ },
+ {
+ key: DataInsightTabs.APP_ANALYTICS,
+ label: i18n.t('label.app-analytic-plural'),
+ icon: DataAssetsIcon,
+ iconProps: {
+ className: 'side-panel-icons',
+ },
+ },
+ {
+ key: DataInsightTabs.KPIS,
+ label: i18n.t('label.kpi-uppercase-plural'),
+ icon: KPIIcon,
+ iconProps: {
+ className: 'side-panel-icons',
+ },
+ },
+ ];
+ }
+
+ public getDataInsightTab() {
+ return [
+ {
+ key: DataInsightTabs.DATA_ASSETS,
+ path: getDataInsightPathWithFqn(DataInsightTabs.DATA_ASSETS),
+ component: DataAssetsTab,
+ },
+ {
+ key: DataInsightTabs.APP_ANALYTICS,
+ path: getDataInsightPathWithFqn(DataInsightTabs.APP_ANALYTICS),
+ component: AppAnalyticsTab,
+ },
+ {
+ key: DataInsightTabs.KPIS,
+ path: getDataInsightPathWithFqn(DataInsightTabs.KPIS),
+ component: KPIList,
+ },
+ ];
+ }
+}
+
+const dataInsightClassBase = new DataInsightClassBase();
+
+export default dataInsightClassBase;
+export { DataInsightClassBase };
diff --git a/openmetadata-ui/src/main/resources/ui/src/pages/DataInsightPage/DataInsightHeader/DataInsightHeader.component.tsx b/openmetadata-ui/src/main/resources/ui/src/pages/DataInsightPage/DataInsightHeader/DataInsightHeader.component.tsx
new file mode 100644
index 000000000000..c8cc92617cb9
--- /dev/null
+++ b/openmetadata-ui/src/main/resources/ui/src/pages/DataInsightPage/DataInsightHeader/DataInsightHeader.component.tsx
@@ -0,0 +1,143 @@
+/*
+ * Copyright 2023 Collate.
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+import { Button, Col, Row, Space, Typography } from 'antd';
+import React, { useMemo } from 'react';
+import { useTranslation } from 'react-i18next';
+import { useHistory, useParams } from 'react-router-dom';
+import DataInsightSummary from '../../../components/DataInsightDetail/DataInsightSummary';
+import KPIChart from '../../../components/DataInsightDetail/KPIChart';
+import DatePickerMenu from '../../../components/DatePickerMenu/DatePickerMenu.component';
+import { usePermissionProvider } from '../../../components/PermissionProvider/PermissionProvider';
+import { ResourceEntity } from '../../../components/PermissionProvider/PermissionProvider.interface';
+import SearchDropdown from '../../../components/SearchDropdown/SearchDropdown';
+import { ROUTES } from '../../../constants/constants';
+import { Operation } from '../../../generated/entity/policies/policy';
+import { DataInsightTabs } from '../../../interface/data-insight.interface';
+import { getOptionalDataInsightTabFlag } from '../../../utils/DataInsightUtils';
+import { formatDate } from '../../../utils/date-time/DateTimeUtils';
+import { checkPermission } from '../../../utils/PermissionsUtils';
+import { useDataInsightProvider } from '../DataInsightProvider';
+import { DataInsightHeaderProps } from './DataInsightHeader.interface';
+
+const DataInsightHeader = ({ onScrollToChart }: DataInsightHeaderProps) => {
+ const {
+ teamFilter: team,
+ tierFilter: tier,
+ chartFilter,
+ onChartFilterChange,
+ kpi,
+ } = useDataInsightProvider();
+
+ const { tab } = useParams<{ tab: DataInsightTabs }>();
+ const history = useHistory();
+ const { t } = useTranslation();
+ const { permissions } = usePermissionProvider();
+
+ const { showDataInsightSummary, showKpiChart } =
+ getOptionalDataInsightTabFlag(tab);
+
+ const viewKPIPermission = useMemo(
+ () => checkPermission(Operation.ViewAll, ResourceEntity.KPI, permissions),
+ [permissions]
+ );
+
+ const createKPIPermission = useMemo(
+ () => checkPermission(Operation.Create, ResourceEntity.KPI, permissions),
+ [permissions]
+ );
+
+ const handleAddKPI = () => {
+ history.push(ROUTES.ADD_KPI);
+ };
+
+ return (
+
+