From 0e2988ca38a54ca7eddae55e11dac45e750383ca Mon Sep 17 00:00:00 2001 From: Daraphista <81943522+Daraphista@users.noreply.github.com> Date: Sun, 29 May 2022 11:47:09 +0800 Subject: [PATCH] fix(sidebar): move aria-expanded attribute to button --- lib/ui/src/components/sidebar/Tree.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ui/src/components/sidebar/Tree.tsx b/lib/ui/src/components/sidebar/Tree.tsx index 222df3e2bcf3..20887cae22f2 100644 --- a/lib/ui/src/components/sidebar/Tree.tsx +++ b/lib/ui/src/components/sidebar/Tree.tsx @@ -190,7 +190,6 @@ const Node = React.memo( data-ref-id={refId} data-item-id={item.id} data-nodetype="root" - aria-expanded={isExpanded} > ( event.preventDefault(); setExpanded({ ids: [item.id], value: !isExpanded }); }} + aria-expanded={isExpanded} > {item.renderLabel?.(item) || item.name}