Merge pull request #30508 from backstage/rugvip/cards

catalog,org: update alpha entity page cards
This commit is contained in:
Patrik Oldsberg
2025-07-14 11:04:20 +02:00
committed by GitHub
4 changed files with 30 additions and 13 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/plugin-org': patch
---
Updated card extensions for the new frontend system to use the new entity predicates, and switch the card type to `info` for the user and group profile cards.
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/plugin-catalog': patch
---
Updated card extensions for the new frontend system to use the new entity predicates, and to not show the about card on User and Group pages.
+14 -9
View File
@@ -56,6 +56,11 @@ export const catalogAboutEntityCard = EntityCardBlueprint.makeWithOverrides({
}
return originalFactory({
type: 'info',
filter: {
$not: {
kind: { $in: ['user', 'group'] },
},
},
async loader() {
const { InternalAboutCard } = await import(
'../components/AboutCard/AboutCard'
@@ -72,7 +77,7 @@ export const catalogLinksEntityCard = EntityCardBlueprint.make({
name: 'links',
params: {
type: 'info',
filter: 'has:links',
filter: { 'metadata.links': { $exists: true } },
loader: async () =>
import('../components/EntityLinksCard').then(m =>
compatWrapper(<m.EntityLinksCard variant="gridItem" />),
@@ -84,7 +89,7 @@ export const catalogLabelsEntityCard = EntityCardBlueprint.make({
name: 'labels',
params: {
type: 'info',
filter: 'has:labels',
filter: { 'metadata.labels': { $exists: true } },
loader: async () =>
import('../components/EntityLabelsCard').then(m =>
compatWrapper(<m.EntityLabelsCard variant="gridItem" />),
@@ -95,7 +100,7 @@ export const catalogLabelsEntityCard = EntityCardBlueprint.make({
export const catalogDependsOnComponentsEntityCard = EntityCardBlueprint.make({
name: 'depends-on-components',
params: {
filter: 'kind:component',
filter: { kind: 'component' },
loader: async () =>
import('../components/DependsOnComponentsCard').then(m =>
compatWrapper(<m.DependsOnComponentsCard variant="gridItem" />),
@@ -106,7 +111,7 @@ export const catalogDependsOnComponentsEntityCard = EntityCardBlueprint.make({
export const catalogDependsOnResourcesEntityCard = EntityCardBlueprint.make({
name: 'depends-on-resources',
params: {
filter: 'kind:component',
filter: { kind: 'component' },
loader: async () =>
import('../components/DependsOnResourcesCard').then(m =>
compatWrapper(<m.DependsOnResourcesCard variant="gridItem" />),
@@ -117,7 +122,7 @@ export const catalogDependsOnResourcesEntityCard = EntityCardBlueprint.make({
export const catalogHasComponentsEntityCard = EntityCardBlueprint.make({
name: 'has-components',
params: {
filter: 'kind:system',
filter: { kind: 'system' },
loader: async () =>
import('../components/HasComponentsCard').then(m =>
compatWrapper(<m.HasComponentsCard variant="gridItem" />),
@@ -128,7 +133,7 @@ export const catalogHasComponentsEntityCard = EntityCardBlueprint.make({
export const catalogHasResourcesEntityCard = EntityCardBlueprint.make({
name: 'has-resources',
params: {
filter: 'kind:system',
filter: { kind: 'system' },
loader: async () =>
import('../components/HasResourcesCard').then(m =>
compatWrapper(<m.HasResourcesCard variant="gridItem" />),
@@ -139,7 +144,7 @@ export const catalogHasResourcesEntityCard = EntityCardBlueprint.make({
export const catalogHasSubcomponentsEntityCard = EntityCardBlueprint.make({
name: 'has-subcomponents',
params: {
filter: 'kind:component',
filter: { kind: 'component' },
loader: async () =>
import('../components/HasSubcomponentsCard').then(m =>
compatWrapper(<m.HasSubcomponentsCard variant="gridItem" />),
@@ -150,7 +155,7 @@ export const catalogHasSubcomponentsEntityCard = EntityCardBlueprint.make({
export const catalogHasSubdomainsEntityCard = EntityCardBlueprint.make({
name: 'has-subdomains',
params: {
filter: 'kind:domain',
filter: { kind: 'domain' },
loader: async () =>
import('../components/HasSubdomainsCard').then(m =>
compatWrapper(<m.HasSubdomainsCard variant="gridItem" />),
@@ -161,7 +166,7 @@ export const catalogHasSubdomainsEntityCard = EntityCardBlueprint.make({
export const catalogHasSystemsEntityCard = EntityCardBlueprint.make({
name: 'has-systems',
params: {
filter: 'kind:domain',
filter: { kind: 'domain' },
loader: async () =>
import('../components/HasSystemsCard').then(m =>
compatWrapper(<m.HasSystemsCard variant="gridItem" />),
+6 -4
View File
@@ -26,7 +26,8 @@ import { EntityCardBlueprint } from '@backstage/plugin-catalog-react/alpha';
const EntityGroupProfileCard = EntityCardBlueprint.make({
name: 'group-profile',
params: {
filter: 'kind:group',
type: 'info',
filter: { kind: 'group' },
loader: async () =>
import('./components/Cards/Group/GroupProfile/GroupProfileCard').then(m =>
compatWrapper(<m.GroupProfileCard />),
@@ -38,7 +39,7 @@ const EntityGroupProfileCard = EntityCardBlueprint.make({
const EntityMembersListCard = EntityCardBlueprint.make({
name: 'members-list',
params: {
filter: 'kind:group',
filter: { kind: 'group' },
loader: async () =>
import('./components/Cards/Group/MembersList/MembersListCard').then(m =>
compatWrapper(<m.MembersListCard />),
@@ -50,7 +51,7 @@ const EntityMembersListCard = EntityCardBlueprint.make({
const EntityOwnershipCard = EntityCardBlueprint.make({
name: 'ownership',
params: {
filter: 'kind:group,user',
filter: { kind: { $in: ['group', 'user'] } },
loader: async () =>
import('./components/Cards/OwnershipCard/OwnershipCard').then(m =>
compatWrapper(<m.OwnershipCard />),
@@ -69,7 +70,8 @@ const EntityUserProfileCard = EntityCardBlueprint.makeWithOverrides({
},
factory(originalFactory, { config }) {
return originalFactory({
filter: 'kind:user',
type: 'info',
filter: { kind: 'user' },
loader: async () =>
import('./components/Cards/User/UserProfileCard/UserProfileCard').then(
m =>