mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-10-31 18:48:35 +00:00
Update asset types in curated assets list (#22976)
* Update asset types in curated assets list * add knowledge page in asset type list
This commit is contained in:
parent
378ace104c
commit
a24281d110
@ -245,7 +245,7 @@ const ActivityFeedCardNew = ({
|
|||||||
{/* Horizontal line connecting popover to end of container */}
|
{/* Horizontal line connecting popover to end of container */}
|
||||||
<div className="horizontal-line " />
|
<div className="horizontal-line " />
|
||||||
|
|
||||||
<div className="d-flex flex-col w-full">
|
<div className="d-flex flex-col w-full min-w-0 overflow-hidden">
|
||||||
<div className="d-flex flex-col align-start">
|
<div className="d-flex flex-col align-start">
|
||||||
<div
|
<div
|
||||||
className={classNames(
|
className={classNames(
|
||||||
|
|||||||
@ -11,7 +11,7 @@
|
|||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
import { InfoCircleOutlined, WarningOutlined } from '@ant-design/icons';
|
import { InfoCircleOutlined, WarningOutlined } from '@ant-design/icons';
|
||||||
import { Col, Progress, Row, Tooltip, Typography } from 'antd';
|
import { Progress, Tooltip, Typography } from 'antd';
|
||||||
import { toNumber } from 'lodash';
|
import { toNumber } from 'lodash';
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { useTranslation } from 'react-i18next';
|
import { useTranslation } from 'react-i18next';
|
||||||
@ -37,7 +37,7 @@ const KPILegend: React.FC<KPILegendProps> = ({
|
|||||||
|
|
||||||
const GoalCompleted = () => {
|
const GoalCompleted = () => {
|
||||||
return (
|
return (
|
||||||
<div className="goal-completed-container d-flex items-center gap-1">
|
<div className="goal-completed-container">
|
||||||
<CheckIcon />
|
<CheckIcon />
|
||||||
<Typography.Text>{t('label.goal-completed')}</Typography.Text>
|
<Typography.Text>{t('label.goal-completed')}</Typography.Text>
|
||||||
</div>
|
</div>
|
||||||
@ -46,7 +46,7 @@ const KPILegend: React.FC<KPILegendProps> = ({
|
|||||||
|
|
||||||
const GoalMissed = () => {
|
const GoalMissed = () => {
|
||||||
return (
|
return (
|
||||||
<div className="goal-missed-container d-flex items-center gap-1">
|
<div className="goal-missed-container">
|
||||||
<WarningOutlined />
|
<WarningOutlined />
|
||||||
<Typography.Text>{t('label.goal-missed')}</Typography.Text>
|
<Typography.Text>{t('label.goal-missed')}</Typography.Text>
|
||||||
</div>
|
</div>
|
||||||
@ -74,10 +74,8 @@ const KPILegend: React.FC<KPILegendProps> = ({
|
|||||||
|
|
||||||
if (isFullSize) {
|
if (isFullSize) {
|
||||||
return (
|
return (
|
||||||
<div className="kpi-full-legend p-xs m-b-sm" key={key}>
|
<div className="kpi-full-legend" key={key}>
|
||||||
<Row className="items-center" gutter={8}>
|
<div className="kpi-legend-header">
|
||||||
<Col span={24}>
|
|
||||||
<div className="d-flex justify-between">
|
|
||||||
<Typography.Text
|
<Typography.Text
|
||||||
className="kpi-legend-title"
|
className="kpi-legend-title"
|
||||||
ellipsis={{ tooltip: true }}>
|
ellipsis={{ tooltip: true }}>
|
||||||
@ -87,10 +85,7 @@ const KPILegend: React.FC<KPILegendProps> = ({
|
|||||||
{daysLeft <= 0 || isTargetMet ? (
|
{daysLeft <= 0 || isTargetMet ? (
|
||||||
<Tooltip
|
<Tooltip
|
||||||
placement="bottom"
|
placement="bottom"
|
||||||
title={getKpiResultFeedback(
|
title={getKpiResultFeedback(daysLeft, Boolean(isTargetMet))}
|
||||||
daysLeft,
|
|
||||||
Boolean(isTargetMet)
|
|
||||||
)}
|
|
||||||
trigger="hover">
|
trigger="hover">
|
||||||
<InfoCircleOutlined className="kpi-legend-info-icon" />
|
<InfoCircleOutlined className="kpi-legend-info-icon" />
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
@ -105,28 +100,32 @@ const KPILegend: React.FC<KPILegendProps> = ({
|
|||||||
strokeWidth={4}
|
strokeWidth={4}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<div className="d-flex justify-between m-t-xxs">
|
<div className="kpi-legend-bottom-row">
|
||||||
|
<div className="kpi-legend-value-section">
|
||||||
<Typography.Text className="text-xss kpi-legend-value">
|
<Typography.Text className="text-xss kpi-legend-value">
|
||||||
{current.toFixed(0)}
|
{current.toFixed(0)}
|
||||||
{suffix}
|
{suffix}
|
||||||
</Typography.Text>
|
</Typography.Text>
|
||||||
|
</div>
|
||||||
|
<div className="kpi-legend-center-section">
|
||||||
{isTargetMet ? (
|
{isTargetMet ? (
|
||||||
<GoalCompleted />
|
<GoalCompleted />
|
||||||
) : isTargetMissed ? (
|
) : isTargetMissed ? (
|
||||||
<GoalMissed />
|
<GoalMissed />
|
||||||
) : (
|
) : (
|
||||||
<Typography.Text className="text-xss font-semibold kpi-legend-days-left">
|
<Typography.Text className="text-xss font-semibold kpi-legend-days-left text-center">
|
||||||
{daysLeft <= 0 ? 0 : daysLeft}{' '}
|
{daysLeft <= 0 ? 0 : daysLeft}{' '}
|
||||||
{t('label.days-left').toUpperCase()}
|
{t('label.days-left').toUpperCase()}
|
||||||
</Typography.Text>
|
</Typography.Text>
|
||||||
)}
|
)}
|
||||||
|
</div>
|
||||||
|
<div className="kpi-legend-value-section">
|
||||||
<Typography.Text className="text-xss kpi-legend-value">
|
<Typography.Text className="text-xss kpi-legend-value">
|
||||||
{target.toFixed(0)}
|
{target.toFixed(0)}
|
||||||
{suffix}
|
{suffix}
|
||||||
</Typography.Text>
|
</Typography.Text>
|
||||||
</div>
|
</div>
|
||||||
</Col>
|
</div>
|
||||||
</Row>
|
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -14,10 +14,13 @@
|
|||||||
@import (reference) url('../../../../../styles/variables.less');
|
@import (reference) url('../../../../../styles/variables.less');
|
||||||
|
|
||||||
.kpi-legend {
|
.kpi-legend {
|
||||||
border: 1px solid @grey-15;
|
|
||||||
border-radius: @border-rad-sm;
|
border-radius: @border-rad-sm;
|
||||||
overflow-y: auto;
|
border: 1px solid @grey-15;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
gap: @size-xs;
|
||||||
max-height: 350px;
|
max-height: 350px;
|
||||||
|
overflow-y: auto;
|
||||||
|
|
||||||
.legend-dot {
|
.legend-dot {
|
||||||
border-radius: 50%;
|
border-radius: 50%;
|
||||||
@ -26,19 +29,28 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.kpi-full-legend {
|
.kpi-full-legend {
|
||||||
min-width: 235px;
|
|
||||||
background-color: @purple-4;
|
|
||||||
border: 1px solid @grey-16;
|
|
||||||
border-radius: @border-rad-sm;
|
|
||||||
background-color: @grey-26;
|
background-color: @grey-26;
|
||||||
|
border-radius: @border-rad-sm;
|
||||||
|
border: 1px solid @grey-16;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
gap: @size-xxs;
|
||||||
|
margin-bottom: @size-xs;
|
||||||
|
min-width: 0;
|
||||||
|
padding: @size-xs;
|
||||||
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.kpi-legend-title {
|
.kpi-legend-title {
|
||||||
color: @grey-700;
|
color: @grey-700;
|
||||||
|
flex: 1;
|
||||||
font-size: @size-sm;
|
font-size: @size-sm;
|
||||||
line-height: 1.2;
|
|
||||||
font-weight: @font-regular;
|
font-weight: @font-regular;
|
||||||
max-width: 180px;
|
line-height: 1.2;
|
||||||
|
min-width: 0;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
.kpi-legend-info-icon {
|
.kpi-legend-info-icon {
|
||||||
@ -60,41 +72,90 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.goal-completed-container {
|
.goal-completed-container {
|
||||||
padding: @size-xxs @size-xs;
|
align-items: center;
|
||||||
border-radius: @border-rad-xs;
|
|
||||||
background-color: @green-9;
|
background-color: @green-9;
|
||||||
|
border-radius: @border-rad-xs;
|
||||||
|
display: flex;
|
||||||
|
flex-shrink: 1;
|
||||||
font-size: 10px;
|
font-size: 10px;
|
||||||
max-width: 115px;
|
gap: @size-xxs;
|
||||||
|
min-width: 0;
|
||||||
|
padding: @size-xxs @size-xs;
|
||||||
|
width: fit-content;
|
||||||
|
|
||||||
.ant-typography {
|
.ant-typography {
|
||||||
color: @green-10;
|
color: @green-10;
|
||||||
margin-left: @size-xxs;
|
margin: 0;
|
||||||
|
min-width: 0;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
svg {
|
svg {
|
||||||
width: @size-sm;
|
|
||||||
height: @size-sm;
|
|
||||||
color: @green-10;
|
color: @green-10;
|
||||||
|
flex-shrink: 0;
|
||||||
|
height: @size-sm;
|
||||||
|
width: @size-sm;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.goal-missed-container {
|
.goal-missed-container {
|
||||||
padding: @size-xxs @size-xs;
|
align-items: center;
|
||||||
border-radius: @border-rad-xs;
|
|
||||||
background-color: @yellow-10;
|
background-color: @yellow-10;
|
||||||
|
border-radius: @border-rad-xs;
|
||||||
color: @yellow-11;
|
color: @yellow-11;
|
||||||
|
display: flex;
|
||||||
|
flex-shrink: 1;
|
||||||
font-size: 10px;
|
font-size: 10px;
|
||||||
max-width: 100px;
|
gap: @size-xxs;
|
||||||
|
min-width: 0;
|
||||||
|
padding: @size-xxs @size-xs;
|
||||||
|
width: fit-content;
|
||||||
|
|
||||||
.ant-typography {
|
.ant-typography {
|
||||||
color: @yellow-11;
|
color: @yellow-11;
|
||||||
margin-left: @size-xxs;
|
margin: 0;
|
||||||
|
min-width: 0;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
svg {
|
svg {
|
||||||
width: @size-sm;
|
|
||||||
height: @size-sm;
|
|
||||||
color: @yellow-11;
|
color: @yellow-11;
|
||||||
|
flex-shrink: 0;
|
||||||
|
height: @size-sm;
|
||||||
|
width: @size-sm;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.kpi-legend-header {
|
||||||
|
align-items: center;
|
||||||
|
display: flex;
|
||||||
|
gap: @size-xs;
|
||||||
|
justify-content: space-between;
|
||||||
|
min-width: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.kpi-legend-bottom-row {
|
||||||
|
align-items: center;
|
||||||
|
display: flex;
|
||||||
|
gap: @size-xxs;
|
||||||
|
justify-content: space-between;
|
||||||
|
min-width: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.kpi-legend-center-section {
|
||||||
|
align-items: center;
|
||||||
|
display: flex;
|
||||||
|
flex: 1;
|
||||||
|
justify-content: center;
|
||||||
|
min-width: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.kpi-legend-value-section {
|
||||||
|
flex-shrink: 0;
|
||||||
|
min-width: fit-content;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -338,7 +338,9 @@ export const CURATED_ASSETS_LIST = [
|
|||||||
EntityType.DASHBOARD_DATA_MODEL,
|
EntityType.DASHBOARD_DATA_MODEL,
|
||||||
EntityType.DATABASE,
|
EntityType.DATABASE,
|
||||||
EntityType.DATABASE_SCHEMA,
|
EntityType.DATABASE_SCHEMA,
|
||||||
|
EntityType.DATA_PRODUCT,
|
||||||
EntityType.GLOSSARY_TERM,
|
EntityType.GLOSSARY_TERM,
|
||||||
|
EntityType.KNOWLEDGE_PAGE,
|
||||||
EntityType.METRIC,
|
EntityType.METRIC,
|
||||||
EntityType.MLMODEL,
|
EntityType.MLMODEL,
|
||||||
EntityType.PIPELINE,
|
EntityType.PIPELINE,
|
||||||
|
|||||||
@ -2452,6 +2452,7 @@ export const getEntityNameLabel = (entityName?: string) => {
|
|||||||
apiCollection: t('label.api-collection'),
|
apiCollection: t('label.api-collection'),
|
||||||
apiEndpoint: t('label.api-endpoint'),
|
apiEndpoint: t('label.api-endpoint'),
|
||||||
metric: t('label.metric'),
|
metric: t('label.metric'),
|
||||||
|
page: t('label.knowledge-page'),
|
||||||
};
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user