feat(EntityRefLink): add disableTooltip prop to control tooltip visibility

Signed-off-by: Yash Oswal <yoswal@redhat.com>
This commit is contained in:
Yash Oswal
2024-09-26 15:29:14 +05:30
parent 2e32ba5031
commit 6812980eba
3 changed files with 9 additions and 0 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/plugin-catalog-react': minor
---
Added a new prop, `disableTooltip` to the `EntityRefLink` component
+1
View File
@@ -456,6 +456,7 @@ export type EntityRefLinkProps = {
title?: string;
children?: React_2.ReactNode;
hideIcon?: boolean;
disableTooltip?: boolean;
} & Omit<LinkProps, 'to'>;
// @public
@@ -39,6 +39,7 @@ export type EntityRefLinkProps = {
title?: string;
children?: React.ReactNode;
hideIcon?: boolean;
disableTooltip?: boolean;
} & Omit<LinkProps, 'to'>;
/**
@@ -55,6 +56,7 @@ export const EntityRefLink = forwardRef<any, EntityRefLinkProps>(
title,
children,
hideIcon,
disableTooltip,
...linkProps
} = props;
const entityRoute = useEntityRoute(props.entityRef);
@@ -65,6 +67,7 @@ export const EntityRefLink = forwardRef<any, EntityRefLinkProps>(
defaultKind={defaultKind}
defaultNamespace={defaultNamespace}
hideIcon={hideIcon}
disableTooltip={disableTooltip}
/>
);