Merge pull request #32631 from backstage/freben/predicates-2
Introduce the `@backstage/filter-predicates` package
This commit is contained in:
@@ -9,10 +9,10 @@ import { ApiFactory } from '@backstage/frontend-plugin-api';
|
||||
import { defaultEntityContentGroups } from '@backstage/plugin-catalog-react/alpha';
|
||||
import { Entity } from '@backstage/catalog-model';
|
||||
import { EntityCardType } from '@backstage/plugin-catalog-react/alpha';
|
||||
import { EntityPredicate } from '@backstage/plugin-catalog-react/alpha';
|
||||
import { ExtensionBlueprintParams } from '@backstage/frontend-plugin-api';
|
||||
import { ExtensionDataRef } from '@backstage/frontend-plugin-api';
|
||||
import { ExternalRouteRef } from '@backstage/core-plugin-api';
|
||||
import { FilterPredicate } from '@backstage/filter-predicates';
|
||||
import { IconComponent } from '@backstage/frontend-plugin-api';
|
||||
import { JSX as JSX_2 } from 'react';
|
||||
import { JSXElementConstructor } from 'react';
|
||||
@@ -87,11 +87,11 @@ const _default: OverridableFrontendPlugin<
|
||||
kind: 'entity-card';
|
||||
name: 'consumed-apis';
|
||||
config: {
|
||||
filter: EntityPredicate | undefined;
|
||||
filter: FilterPredicate | undefined;
|
||||
type: 'content' | 'info' | undefined;
|
||||
};
|
||||
configInput: {
|
||||
filter?: EntityPredicate | undefined;
|
||||
filter?: FilterPredicate | undefined;
|
||||
type?: 'content' | 'info' | undefined;
|
||||
};
|
||||
output:
|
||||
@@ -120,7 +120,7 @@ const _default: OverridableFrontendPlugin<
|
||||
inputs: {};
|
||||
params: {
|
||||
loader: () => Promise<JSX.Element>;
|
||||
filter?: string | EntityPredicate | ((entity: Entity) => boolean);
|
||||
filter?: string | FilterPredicate | ((entity: Entity) => boolean);
|
||||
type?: EntityCardType;
|
||||
};
|
||||
}>;
|
||||
@@ -128,11 +128,11 @@ const _default: OverridableFrontendPlugin<
|
||||
kind: 'entity-card';
|
||||
name: 'consuming-components';
|
||||
config: {
|
||||
filter: EntityPredicate | undefined;
|
||||
filter: FilterPredicate | undefined;
|
||||
type: 'content' | 'info' | undefined;
|
||||
};
|
||||
configInput: {
|
||||
filter?: EntityPredicate | undefined;
|
||||
filter?: FilterPredicate | undefined;
|
||||
type?: 'content' | 'info' | undefined;
|
||||
};
|
||||
output:
|
||||
@@ -161,7 +161,7 @@ const _default: OverridableFrontendPlugin<
|
||||
inputs: {};
|
||||
params: {
|
||||
loader: () => Promise<JSX.Element>;
|
||||
filter?: string | EntityPredicate | ((entity: Entity) => boolean);
|
||||
filter?: string | FilterPredicate | ((entity: Entity) => boolean);
|
||||
type?: EntityCardType;
|
||||
};
|
||||
}>;
|
||||
@@ -169,11 +169,11 @@ const _default: OverridableFrontendPlugin<
|
||||
kind: 'entity-card';
|
||||
name: 'definition';
|
||||
config: {
|
||||
filter: EntityPredicate | undefined;
|
||||
filter: FilterPredicate | undefined;
|
||||
type: 'content' | 'info' | undefined;
|
||||
};
|
||||
configInput: {
|
||||
filter?: EntityPredicate | undefined;
|
||||
filter?: FilterPredicate | undefined;
|
||||
type?: 'content' | 'info' | undefined;
|
||||
};
|
||||
output:
|
||||
@@ -202,7 +202,7 @@ const _default: OverridableFrontendPlugin<
|
||||
inputs: {};
|
||||
params: {
|
||||
loader: () => Promise<JSX.Element>;
|
||||
filter?: string | EntityPredicate | ((entity: Entity) => boolean);
|
||||
filter?: string | FilterPredicate | ((entity: Entity) => boolean);
|
||||
type?: EntityCardType;
|
||||
};
|
||||
}>;
|
||||
@@ -210,11 +210,11 @@ const _default: OverridableFrontendPlugin<
|
||||
kind: 'entity-card';
|
||||
name: 'has-apis';
|
||||
config: {
|
||||
filter: EntityPredicate | undefined;
|
||||
filter: FilterPredicate | undefined;
|
||||
type: 'content' | 'info' | undefined;
|
||||
};
|
||||
configInput: {
|
||||
filter?: EntityPredicate | undefined;
|
||||
filter?: FilterPredicate | undefined;
|
||||
type?: 'content' | 'info' | undefined;
|
||||
};
|
||||
output:
|
||||
@@ -243,7 +243,7 @@ const _default: OverridableFrontendPlugin<
|
||||
inputs: {};
|
||||
params: {
|
||||
loader: () => Promise<JSX.Element>;
|
||||
filter?: string | EntityPredicate | ((entity: Entity) => boolean);
|
||||
filter?: string | FilterPredicate | ((entity: Entity) => boolean);
|
||||
type?: EntityCardType;
|
||||
};
|
||||
}>;
|
||||
@@ -251,11 +251,11 @@ const _default: OverridableFrontendPlugin<
|
||||
kind: 'entity-card';
|
||||
name: 'provided-apis';
|
||||
config: {
|
||||
filter: EntityPredicate | undefined;
|
||||
filter: FilterPredicate | undefined;
|
||||
type: 'content' | 'info' | undefined;
|
||||
};
|
||||
configInput: {
|
||||
filter?: EntityPredicate | undefined;
|
||||
filter?: FilterPredicate | undefined;
|
||||
type?: 'content' | 'info' | undefined;
|
||||
};
|
||||
output:
|
||||
@@ -284,7 +284,7 @@ const _default: OverridableFrontendPlugin<
|
||||
inputs: {};
|
||||
params: {
|
||||
loader: () => Promise<JSX.Element>;
|
||||
filter?: string | EntityPredicate | ((entity: Entity) => boolean);
|
||||
filter?: string | FilterPredicate | ((entity: Entity) => boolean);
|
||||
type?: EntityCardType;
|
||||
};
|
||||
}>;
|
||||
@@ -292,11 +292,11 @@ const _default: OverridableFrontendPlugin<
|
||||
kind: 'entity-card';
|
||||
name: 'providing-components';
|
||||
config: {
|
||||
filter: EntityPredicate | undefined;
|
||||
filter: FilterPredicate | undefined;
|
||||
type: 'content' | 'info' | undefined;
|
||||
};
|
||||
configInput: {
|
||||
filter?: EntityPredicate | undefined;
|
||||
filter?: FilterPredicate | undefined;
|
||||
type?: 'content' | 'info' | undefined;
|
||||
};
|
||||
output:
|
||||
@@ -325,7 +325,7 @@ const _default: OverridableFrontendPlugin<
|
||||
inputs: {};
|
||||
params: {
|
||||
loader: () => Promise<JSX.Element>;
|
||||
filter?: string | EntityPredicate | ((entity: Entity) => boolean);
|
||||
filter?: string | FilterPredicate | ((entity: Entity) => boolean);
|
||||
type?: EntityCardType;
|
||||
};
|
||||
}>;
|
||||
@@ -335,12 +335,12 @@ const _default: OverridableFrontendPlugin<
|
||||
config: {
|
||||
path: string | undefined;
|
||||
title: string | undefined;
|
||||
filter: EntityPredicate | undefined;
|
||||
filter: FilterPredicate | undefined;
|
||||
group: string | false | undefined;
|
||||
icon: string | undefined;
|
||||
};
|
||||
configInput: {
|
||||
filter?: EntityPredicate | undefined;
|
||||
filter?: FilterPredicate | undefined;
|
||||
title?: string | undefined;
|
||||
path?: string | undefined;
|
||||
group?: string | false | undefined;
|
||||
@@ -396,7 +396,7 @@ const _default: OverridableFrontendPlugin<
|
||||
icon?: string | ReactElement;
|
||||
loader: () => Promise<JSX.Element>;
|
||||
routeRef?: RouteRef_2;
|
||||
filter?: string | EntityPredicate | ((entity: Entity) => boolean);
|
||||
filter?: string | FilterPredicate | ((entity: Entity) => boolean);
|
||||
};
|
||||
}>;
|
||||
'entity-content:api-docs/definition': OverridableExtensionDefinition<{
|
||||
@@ -405,12 +405,12 @@ const _default: OverridableFrontendPlugin<
|
||||
config: {
|
||||
path: string | undefined;
|
||||
title: string | undefined;
|
||||
filter: EntityPredicate | undefined;
|
||||
filter: FilterPredicate | undefined;
|
||||
group: string | false | undefined;
|
||||
icon: string | undefined;
|
||||
};
|
||||
configInput: {
|
||||
filter?: EntityPredicate | undefined;
|
||||
filter?: FilterPredicate | undefined;
|
||||
title?: string | undefined;
|
||||
path?: string | undefined;
|
||||
group?: string | false | undefined;
|
||||
@@ -466,7 +466,7 @@ const _default: OverridableFrontendPlugin<
|
||||
icon?: string | ReactElement;
|
||||
loader: () => Promise<JSX.Element>;
|
||||
routeRef?: RouteRef_2;
|
||||
filter?: string | EntityPredicate | ((entity: Entity) => boolean);
|
||||
filter?: string | FilterPredicate | ((entity: Entity) => boolean);
|
||||
};
|
||||
}>;
|
||||
'nav-item:api-docs': OverridableExtensionDefinition<{
|
||||
|
||||
Reference in New Issue
Block a user