introduce the @backstage/filter-predicates package

Signed-off-by: Fredrik Adelöw <freben@gmail.com>
This commit is contained in:
Fredrik Adelöw
2026-02-03 14:36:56 +01:00
parent f2c1da4c4c
commit 7feb83b586
42 changed files with 1092 additions and 322 deletions
+7 -7
View File
@@ -9,10 +9,10 @@ import { ApiFactory } from '@backstage/frontend-plugin-api';
import { ConfigurableExtensionDataRef } from '@backstage/frontend-plugin-api';
import { defaultEntityContentGroups } from '@backstage/plugin-catalog-react/alpha';
import { Entity } from '@backstage/catalog-model';
import { EntityPredicate } from '@backstage/plugin-catalog-react/alpha';
import { ExtensionBlueprintParams } from '@backstage/frontend-plugin-api';
import { ExtensionDataRef } from '@backstage/frontend-plugin-api';
import { ExtensionInput } from '@backstage/frontend-plugin-api';
import { FilterPredicate } from '@backstage/filter-predicates';
import { IconComponent } from '@backstage/frontend-plugin-api';
import { IconLinkVerticalProps } from '@backstage/core-components';
import { JSX as JSX_2 } from 'react';
@@ -124,11 +124,11 @@ const _default: OverridableFrontendPlugin<
config: {
path: string | undefined;
title: string | undefined;
filter: EntityPredicate | undefined;
filter: FilterPredicate | undefined;
group: string | false | undefined;
};
configInput: {
filter?: EntityPredicate | undefined;
filter?: FilterPredicate | undefined;
title?: string | undefined;
path?: string | undefined;
group?: string | false | undefined;
@@ -204,7 +204,7 @@ const _default: OverridableFrontendPlugin<
group?: keyof defaultEntityContentGroups | (string & {});
loader: () => Promise<JSX.Element>;
routeRef?: RouteRef_2;
filter?: string | EntityPredicate | ((entity: Entity) => boolean);
filter?: string | FilterPredicate | ((entity: Entity) => boolean);
};
}>;
'entity-icon-link:techdocs/read-docs': OverridableExtensionDefinition<{
@@ -213,10 +213,10 @@ const _default: OverridableFrontendPlugin<
config: {
label: string | undefined;
title: string | undefined;
filter: EntityPredicate | undefined;
filter: FilterPredicate | undefined;
};
configInput: {
filter?: EntityPredicate | undefined;
filter?: FilterPredicate | undefined;
label?: string | undefined;
title?: string | undefined;
};
@@ -243,7 +243,7 @@ const _default: OverridableFrontendPlugin<
inputs: {};
params: {
useProps: () => Omit<IconLinkVerticalProps, 'color'>;
filter?: EntityPredicate | ((entity: Entity) => boolean);
filter?: FilterPredicate | ((entity: Entity) => boolean);
};
}>;
'nav-item:techdocs': OverridableExtensionDefinition<{