From f3355cc1a4433f1f4e2d855e04c21b19fc45c6d5 Mon Sep 17 00:00:00 2001 From: Adam Alston Date: Thu, 27 Feb 2025 22:39:38 -0500 Subject: [PATCH] fix(TableExpandHeader): update props types --- .../src/components/DataTable/TableExpandHeader.tsx | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/packages/react/src/components/DataTable/TableExpandHeader.tsx b/packages/react/src/components/DataTable/TableExpandHeader.tsx index aafba16d58a7..c6916e8b1efa 100644 --- a/packages/react/src/components/DataTable/TableExpandHeader.tsx +++ b/packages/react/src/components/DataTable/TableExpandHeader.tsx @@ -1,5 +1,5 @@ /** - * Copyright IBM Corp. 2016, 2023 + * Copyright IBM Corp. 2016, 2025 * * This source code is licensed under the Apache-2.0 license found in the * LICENSE file in the root directory of this source tree. @@ -58,20 +58,21 @@ export type TableExpandHeaderPropsBase = { export type TableExpandHeaderPropsWithToggle = Omit< TableExpandHeaderPropsBase, - 'ariaLabel' | 'aria-label' | 'enableToggle' | 'onExpand' + 'aria-label' | 'enableToggle' | 'onExpand' > & { enableToggle: true; - ariaLabel: string; ['aria-label']: string; onExpand(event: React.MouseEvent): void; }; export type TableExpandHeaderPropsWithExpando = Omit< TableExpandHeaderPropsBase, - 'ariaLabel' | 'aria-label' | 'enableExpando' | 'onExpand' + 'aria-label' | 'enableExpando' | 'onExpand' > & { + /** + * @deprecated The enableExpando prop is being replaced by `enableToggle` + */ enableExpando: true; - ariaLabel: string; ['aria-label']: string; onExpand(event: React.MouseEvent): void; };