From 737d4a73f838d8ef9f830769d163eefd1b03b96e Mon Sep 17 00:00:00 2001 From: Benjamin Janssens Date: Thu, 14 Aug 2025 13:40:45 +0200 Subject: [PATCH] chore(plugin-org): restore original default behaviour of OwnershipCard Signed-off-by: Benjamin Janssens --- .../src/components/Cards/OwnershipCard/ComponentsGrid.tsx | 2 +- .../src/components/Cards/OwnershipCard/OwnershipCard.tsx | 7 +++---- .../src/components/Cards/OwnershipCard/useGetEntities.ts | 2 +- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/plugins/org/src/components/Cards/OwnershipCard/ComponentsGrid.tsx b/plugins/org/src/components/Cards/OwnershipCard/ComponentsGrid.tsx index 5ba91ab601..0c177f31a8 100644 --- a/plugins/org/src/components/Cards/OwnershipCard/ComponentsGrid.tsx +++ b/plugins/org/src/components/Cards/OwnershipCard/ComponentsGrid.tsx @@ -124,7 +124,7 @@ export const ComponentsGrid = ({ relationsType, relationAggregation, entityFilterKind, - entityLimit, + entityLimit = 6, }: { className?: string; entity: Entity; diff --git a/plugins/org/src/components/Cards/OwnershipCard/OwnershipCard.tsx b/plugins/org/src/components/Cards/OwnershipCard/OwnershipCard.tsx index eac411a805..b449896b72 100644 --- a/plugins/org/src/components/Cards/OwnershipCard/OwnershipCard.tsx +++ b/plugins/org/src/components/Cards/OwnershipCard/OwnershipCard.tsx @@ -100,14 +100,13 @@ export const OwnershipCard = (props: { variant, entityFilterKind, hideRelationsToggle, - entityLimit, - scrollHeight: propScrollHeight = '292px', + entityLimit = 6, + scrollHeight: propScrollHeight, } = props; const relationAggregation = props.relationAggregation ?? props.relationsType; const relationsToggle = hideRelationsToggle === undefined ? false : hideRelationsToggle; - const scrollHeight = - entityLimit || variant === 'fullHeight' ? 'none' : propScrollHeight; + const scrollHeight = variant !== 'fullHeight' ? propScrollHeight : undefined; const classes = useStyles(); const { entity } = useEntity(); const { t } = useTranslationRef(orgTranslationRef); diff --git a/plugins/org/src/components/Cards/OwnershipCard/useGetEntities.ts b/plugins/org/src/components/Cards/OwnershipCard/useGetEntities.ts index 98e319a4c3..a5a5363192 100644 --- a/plugins/org/src/components/Cards/OwnershipCard/useGetEntities.ts +++ b/plugins/org/src/components/Cards/OwnershipCard/useGetEntities.ts @@ -184,7 +184,7 @@ export function useGetEntities( entity: Entity, relationAggregation: EntityRelationAggregation, entityFilterKind?: string[], - entityLimit?: number, + entityLimit = 6, ): { componentsWithCounters: | {