Remove duplicate presentation API exports from alpha, import from public API
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Fredrik Adelöw <freben@spotify.com>
This commit is contained in:
@@ -6,19 +6,17 @@
|
||||
import { AnyRouteRefParams } from '@backstage/frontend-plugin-api';
|
||||
import { ColumnConfig } from '@backstage/ui';
|
||||
import { ComponentType } from 'react';
|
||||
import { CompoundEntityRef } from '@backstage/catalog-model';
|
||||
import { ConfigurableExtensionDataRef } from '@backstage/frontend-plugin-api';
|
||||
import { Entity } from '@backstage/catalog-model';
|
||||
import { EntityPresentationApi } from '@backstage/plugin-catalog-react';
|
||||
import { ExtensionBlueprint } from '@backstage/frontend-plugin-api';
|
||||
import { ExtensionDataRef } from '@backstage/frontend-plugin-api';
|
||||
import { ExtensionDefinition } from '@backstage/frontend-plugin-api';
|
||||
import { FilterPredicate } from '@backstage/filter-predicates';
|
||||
import { IconComponent } from '@backstage/core-plugin-api';
|
||||
import { IconLinkVerticalProps } from '@backstage/core-components';
|
||||
import { JSX as JSX_2 } from 'react';
|
||||
import { JSX as JSX_3 } from 'react/jsx-runtime';
|
||||
import { JSXElementConstructor } from 'react';
|
||||
import { Observable } from '@backstage/types';
|
||||
import { ReactElement } from 'react';
|
||||
import { ReactNode } from 'react';
|
||||
import { ResourcePermission } from '@backstage/plugin-permission-common';
|
||||
@@ -186,15 +184,6 @@ export const defaultEntityContentGroups: Record<
|
||||
string
|
||||
>;
|
||||
|
||||
// @public
|
||||
export function defaultEntityPresentation(
|
||||
entityOrRef: Entity | CompoundEntityRef | string,
|
||||
context?: {
|
||||
defaultKind?: string;
|
||||
defaultNamespace?: string;
|
||||
},
|
||||
): EntityRefPresentationSnapshot;
|
||||
|
||||
// @alpha
|
||||
export const EntityCardBlueprint: ExtensionBlueprint<{
|
||||
kind: 'entity-card';
|
||||
@@ -534,18 +523,6 @@ export interface EntityDataTableProps {
|
||||
loading?: boolean;
|
||||
}
|
||||
|
||||
// @public
|
||||
export const EntityDisplayName: (props: EntityDisplayNameProps) => JSX.Element;
|
||||
|
||||
// @public
|
||||
export type EntityDisplayNameProps = {
|
||||
entityRef: Entity | CompoundEntityRef | string;
|
||||
hideIcon?: boolean;
|
||||
disableTooltip?: boolean;
|
||||
defaultKind?: string;
|
||||
defaultNamespace?: string;
|
||||
};
|
||||
|
||||
// @alpha (undocumented)
|
||||
export const EntityHeaderBlueprint: ExtensionBlueprint<{
|
||||
kind: 'entity-header';
|
||||
@@ -653,32 +630,6 @@ export const EntityIconLinkBlueprint: ExtensionBlueprint<{
|
||||
};
|
||||
}>;
|
||||
|
||||
// @public
|
||||
export interface EntityPresentationApi {
|
||||
forEntity(
|
||||
entityOrRef: Entity | string,
|
||||
context?: {
|
||||
defaultKind?: string;
|
||||
defaultNamespace?: string;
|
||||
},
|
||||
): EntityRefPresentation;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface EntityRefPresentation {
|
||||
promise: Promise<EntityRefPresentationSnapshot>;
|
||||
snapshot: EntityRefPresentationSnapshot;
|
||||
update$?: Observable<EntityRefPresentationSnapshot>;
|
||||
}
|
||||
|
||||
// @public
|
||||
export interface EntityRefPresentationSnapshot {
|
||||
entityRef: string;
|
||||
Icon?: IconComponent | undefined | false;
|
||||
primaryTitle: string;
|
||||
secondaryTitle?: string;
|
||||
}
|
||||
|
||||
// @public (undocumented)
|
||||
export function EntityRelationCard(
|
||||
props: EntityRelationCardProps,
|
||||
@@ -752,15 +703,6 @@ export function useEntityPermission(
|
||||
error?: Error;
|
||||
};
|
||||
|
||||
// @public
|
||||
export function useEntityPresentation(
|
||||
entityOrRef: Entity | CompoundEntityRef | string,
|
||||
context?: {
|
||||
defaultKind?: string;
|
||||
defaultNamespace?: string;
|
||||
},
|
||||
): EntityRefPresentationSnapshot;
|
||||
|
||||
// @alpha (undocumented)
|
||||
export type UseProps = () =>
|
||||
| {
|
||||
|
||||
@@ -26,13 +26,5 @@ export const catalogReactTranslationRef = _catalogReactTranslationRef;
|
||||
export { isOwnerOf } from '../utils/isOwnerOf';
|
||||
export { useEntityPermission } from '../hooks/useEntityPermission';
|
||||
export * from '../components/EntityTable/TitleColumn';
|
||||
export type {
|
||||
EntityPresentationApi,
|
||||
EntityRefPresentation,
|
||||
EntityRefPresentationSnapshot,
|
||||
} from '../apis';
|
||||
export { useEntityPresentation, defaultEntityPresentation } from '../apis';
|
||||
export { EntityDisplayName } from '../components/EntityDisplayName';
|
||||
export type { EntityDisplayNameProps } from '../components/EntityDisplayName';
|
||||
export * from '../components/EntityDataTable';
|
||||
export * from '../components/EntityRelationCard';
|
||||
|
||||
@@ -21,7 +21,10 @@ import {
|
||||
} from '@backstage/catalog-model';
|
||||
import { Cell, CellText, Column, ColumnConfig, TableItem } from '@backstage/ui';
|
||||
import { EntityRefLink, EntityRefLinks } from '../EntityRefLink';
|
||||
import { defaultEntityPresentation, EntityPresentationApi } from '../../apis';
|
||||
import {
|
||||
defaultEntityPresentation,
|
||||
EntityPresentationApi,
|
||||
} from '@backstage/plugin-catalog-react';
|
||||
import { EntityTableColumnTitle } from '../EntityTable/TitleColumn';
|
||||
import { getEntityRelations } from '../../utils';
|
||||
|
||||
|
||||
Reference in New Issue
Block a user