Skip to content

Commit f05a239

Browse files
committed
fix: add key prop to accordion tab root element for improved rendering
1 parent 573d119 commit f05a239

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

components/lib/accordion/Accordion.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -306,15 +306,14 @@ export const Accordion = React.forwardRef((inProps, ref) => {
306306

307307
const rootProps = mergeProps(
308308
{
309-
key,
310309
className: cx('accordiontab.root', { selected })
311310
},
312311
AccordionTabBase.getCOtherProps(tab),
313312
getTabPT(tab, 'root', index)
314313
);
315314

316315
return (
317-
<div {...rootProps}>
316+
<div {...rootProps} key={key}>
318317
{tabHeader}
319318
{tabContent}
320319
</div>

0 commit comments

Comments
 (0)