catalog-react: Deprecate getEntityMetadataViewUrl and getEntityMetadataEditUrl

Signed-off-by: Johan Haals <johan.haals@gmail.com>
This commit is contained in:
Johan Haals
2022-02-25 15:34:36 +01:00
parent 05d73d0850
commit 8f0e8e039b
7 changed files with 34 additions and 13 deletions
@@ -20,13 +20,13 @@ import {
RELATION_PARENT_OF,
ANNOTATION_LOCATION,
stringifyEntityRef,
ANNOTATION_EDIT_URL,
} from '@backstage/catalog-model';
import {
catalogApiRef,
EntityRefLinks,
getEntityRelations,
useEntity,
getEntityMetadataEditUrl,
} from '@backstage/plugin-catalog-react';
import {
Box,
@@ -94,7 +94,8 @@ export const GroupProfileCard = ({
const allowRefresh =
entityLocation?.startsWith('url:') || entityLocation?.startsWith('file:');
const entityMetadataEditUrl = getEntityMetadataEditUrl(group);
const entityMetadataEditUrl =
group.metadata.annotations?.[ANNOTATION_EDIT_URL];
const displayName = profile?.displayName ?? name;
const emailHref = profile?.email ? `mailto:${profile.email}` : '#';