diff --git a/resources/CheckboxHack.d.ts b/resources/CheckboxHack.d.ts index d2fa76e7e..23f774bd4 100644 --- a/resources/CheckboxHack.d.ts +++ b/resources/CheckboxHack.d.ts @@ -1,6 +1,6 @@ interface CheckboxHack { - updateAriaExpanded(checkbox: HTMLInputElement): void; - bindUpdateAriaExpandedOnInput(checkbox: HTMLInputElement): CheckboxHackListeners; + updateAriaExpanded(checkbox: HTMLInputElement, button: HTMLElement): void; + bindUpdateAriaExpandedOnInput(checkbox: HTMLInputElement, button: HTMLElement): CheckboxHackListeners; bindToggleOnClick(checkbox: HTMLInputElement, button: HTMLElement): CheckboxHackListeners; bindDismissOnClickOutside(window: Window, checkbox: HTMLInputElement, button: HTMLElement, target: Node): CheckboxHackListeners; bindDismissOnFocusLoss(window: Window, checkbox: HTMLInputElement, button: HTMLElement, target: Node): CheckboxHackListeners; diff --git a/resources/skins.vector.js/skin.js b/resources/skins.vector.js/skin.js index 0da980abe..b19ff3411 100644 --- a/resources/skins.vector.js/skin.js +++ b/resources/skins.vector.js/skin.js @@ -46,9 +46,9 @@ function initSidebar( document ) { var button = document.getElementById( 'mw-sidebar-button' ); if ( checkbox instanceof HTMLInputElement && button ) { checkboxHack.bindToggleOnClick( checkbox, button ); - checkboxHack.bindUpdateAriaExpandedOnInput( checkbox ); + checkboxHack.bindUpdateAriaExpandedOnInput( checkbox, button ); - checkboxHack.updateAriaExpanded( checkbox ); + checkboxHack.updateAriaExpanded( checkbox, button ); } }