Browse Source
fix: update selector for active menu item in useMenuScroll hook (#7829)
pull/7835/head
AxiosLeo
5 months ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
1 additions and
1 deletions
-
packages/@core/ui-kit/menu-ui/src/hooks/use-menu-scroll.ts
|
|
|
@ -20,7 +20,7 @@ export function useMenuScroll( |
|
|
|
if (!isEnabled) return; |
|
|
|
|
|
|
|
const activeElement = document.querySelector( |
|
|
|
`aside li[role=menuitem].is-active`, |
|
|
|
`aside a[role=menuitem].is-active`, |
|
|
|
); |
|
|
|
if (activeElement) { |
|
|
|
activeElement.scrollIntoView({ |
|
|
|
|