Przeglądaj źródła

fix(app): list component jumping when mouse happens to be under the list and keyboard navigating. (#9435)

Joseph Campuzano 1 miesiąc temu
rodzic
commit
72cb7ccc00
1 zmienionych plików z 1 dodań i 0 usunięć
  1. 1 0
      packages/ui/src/components/list.tsx

+ 1 - 0
packages/ui/src/components/list.tsx

@@ -206,6 +206,7 @@ export function List<T>(props: ListProps<T> & { ref?: (ref: ListRef) => void })
                           setActive(props.key(item))
                           setActive(props.key(item))
                         }}
                         }}
                         onMouseLeave={() => {
                         onMouseLeave={() => {
+                          if (!store.mouseActive) return;
                           setActive(null)
                           setActive(null)
                         }}
                         }}
                       >
                       >