chore: added backwards compatible method too
Signed-off-by: blam <ben@blam.sh>
This commit is contained in:
@@ -22,7 +22,7 @@ import {
|
||||
} from '@backstage/catalog-model';
|
||||
import React, { forwardRef } from 'react';
|
||||
import { entityRouteRef } from '../../routes';
|
||||
import { humanizeEntityRef } from './format';
|
||||
import { humanizeEntityRef } from './humanize';
|
||||
import { Link, LinkProps } from '@backstage/core-components';
|
||||
import { useRouteRef } from '@backstage/core-plugin-api';
|
||||
import { Tooltip } from '@material-ui/core';
|
||||
|
||||
@@ -20,6 +20,9 @@ import {
|
||||
DEFAULT_NAMESPACE,
|
||||
} from '@backstage/catalog-model';
|
||||
|
||||
/** @deprecated please use {@link humanizeEntityRef} instead */
|
||||
export const formatEntityRefTitle = humanizeEntityRef;
|
||||
|
||||
/** @public */
|
||||
export function humanizeEntityRef(
|
||||
entityRef: Entity | EntityName,
|
||||
|
||||
@@ -18,4 +18,4 @@ export { EntityRefLink } from './EntityRefLink';
|
||||
export type { EntityRefLinkProps } from './EntityRefLink';
|
||||
export { EntityRefLinks } from './EntityRefLinks';
|
||||
export type { EntityRefLinksProps } from './EntityRefLinks';
|
||||
export { humanizeEntityRef } from './format';
|
||||
export { humanizeEntityRef, formatEntityRefTitle } from './humanize';
|
||||
|
||||
+1
-1
@@ -33,7 +33,7 @@ import React, { useLayoutEffect, useRef, useState } from 'react';
|
||||
import { useNavigate } from 'react-router';
|
||||
import useAsync from 'react-use/lib/useAsync';
|
||||
import { catalogApiRef } from '../../../api';
|
||||
import { humanizeEntityRef } from '../../../components/EntityRefLink/format';
|
||||
import { humanizeEntityRef } from '../../EntityRefLink';
|
||||
import { entityRouteRef } from '../../../routes';
|
||||
import { EntityKindIcon } from './EntityKindIcon';
|
||||
|
||||
|
||||
Reference in New Issue
Block a user