mirror of
https://github.com/Kilo-Org/kilocode.git
synced 2026-09-24 16:02:55 +08:00
fix(vscode): use inert instead of aria-hidden on collapsed sidebar
aria-hidden only hides from screen readers; pointer-events: none only blocks the mouse. Tab focus could still traverse into the hidden sidebar's worktree buttons and session items. inert handles all three at once: removes from the a11y tree, blocks pointer events, and prevents keyboard focus.
This commit is contained in:
@@ -2131,7 +2131,7 @@ const AgentManagerContent: Component = () => {
|
||||
class="am-sidebar"
|
||||
classList={{ "am-sidebar-collapsed": sidebarCollapsed() }}
|
||||
style={{ width: sidebarCollapsed() ? "0px" : `${sidebarWidth()}px` }}
|
||||
aria-hidden={sidebarCollapsed()}
|
||||
inert={sidebarCollapsed() || undefined}
|
||||
>
|
||||
<ResizeHandle
|
||||
direction="horizontal"
|
||||
|
||||
@@ -40,7 +40,8 @@
|
||||
padding-right: 0;
|
||||
border-right-width: 0;
|
||||
overflow: hidden;
|
||||
pointer-events: none;
|
||||
/* Pointer events, focus, and a11y tree exclusion are all handled by the
|
||||
inert attribute on the element. No need for pointer-events: none. */
|
||||
}
|
||||
|
||||
.am-sidebar-collapsed > [data-component="resize-handle"] {
|
||||
|
||||
Reference in New Issue
Block a user