fix: Glossary tags are not showing proper name when using in entities #13440 (#13448)

This commit is contained in:
Shailesh Parmar 2023-10-05 18:35:01 +05:30 committed by GitHub
parent 44df02010a
commit de2b2c6428
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 7 deletions

View File

@ -13,7 +13,7 @@
import { Select, SelectProps, Space, Tooltip, Typography } from 'antd';
import { DefaultOptionType } from 'antd/lib/select';
import { AxiosError } from 'axios';
import { debounce } from 'lodash';
import { debounce, isEmpty } from 'lodash';
import React, { FC, useCallback, useMemo, useState } from 'react';
import Loader from '../../components/Loader/Loader';
import { FQN_SEPARATOR_CHAR } from '../../constants/char.constants';
@ -70,8 +70,9 @@ const AsyncSelectList: FC<AsyncSelectListProps> = ({
.map((tag) => {
const displayName = tag.data?.displayName;
const parts = Fqn.split(tag.label);
const lastPartOfTag =
displayName ?? parts.slice(-1).join(FQN_SEPARATOR_CHAR);
const lastPartOfTag = isEmpty(displayName)
? parts.slice(-1).join(FQN_SEPARATOR_CHAR)
: displayName;
parts.pop();
return {

View File

@ -97,7 +97,7 @@ const TagsV1 = ({
const tagColorBar = useMemo(
() =>
color ? (
<div className="tag-color-bar" style={{ background: color }} />
<div className="tag-color-bar" style={{ borderColor: color }} />
) : null,
[color]
);

View File

@ -44,9 +44,7 @@
}
.tag-color-bar {
width: 5px;
height: auto;
background: @tag-background-color;
border-left: 5px solid @tag-background-color;
}
.tags-label {