fix handle of the default value

This commit is contained in:
lucataglia 2023-05-20 23:12:02 +02:00
parent fc0611d750
commit 5a6dc0e89f

View File

@ -77,7 +77,7 @@ function ExpandButton({
if ( if (
shouldExpandNode === 'collapse' || shouldExpandNode === 'collapse' ||
(isDefault && expandableDefaultValue === 'collapse') (isDefault && expandableDefaultValue === 'expand')
) { ) {
return ( return (
<div role="presentation" onClick={onExpand}> <div role="presentation" onClick={onExpand}>
@ -105,7 +105,7 @@ function CollapseButton({
if ( if (
shouldExpandNode === 'expand' || shouldExpandNode === 'expand' ||
(isDefault && expandableDefaultValue === 'expand') (isDefault && expandableDefaultValue === 'collapse')
) { ) {
return ( return (
<div role="presentation" onClick={onCollapse}> <div role="presentation" onClick={onCollapse}>