From 7a3905eceaefec718a9ea3eebd0024418b3c0c77 Mon Sep 17 00:00:00 2001 From: Serge Pavlyuk Date: Wed, 6 Nov 2024 18:08:22 +0300 Subject: [PATCH] chore: add items count --- src/components/DashKit/__stories__/DashKitGroupsShowcase.tsx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/components/DashKit/__stories__/DashKitGroupsShowcase.tsx b/src/components/DashKit/__stories__/DashKitGroupsShowcase.tsx index e4e75f2..95cff11 100644 --- a/src/components/DashKit/__stories__/DashKitGroupsShowcase.tsx +++ b/src/components/DashKit/__stories__/DashKitGroupsShowcase.tsx @@ -159,7 +159,8 @@ export const DashKitGroupsShowcase: React.FC = () => { ...chartGroups.map((id) => ({ id, render: (id: string, children: React.ReactNode, props: DashkitGroupRenderProps) => { - const showPlaceholder = props.items.length === 0 && !props.isDragging; + const itemsLength = props.items.length; + const showPlaceholder = itemsLength === 0 && !props.isDragging; const isMultipleGroups = chartGroups.length > 1; const groupIndex = chartGroups.indexOf(id); @@ -195,7 +196,7 @@ export const DashKitGroupsShowcase: React.FC = () => { - {`Group: ${id}`} + {`${id}: (${itemsLength})`}