fix(opencode): command palette mouse hover highlights wrong item (#7721)

This commit is contained in:
Kit Langton 2026-01-10 19:52:17 -05:00 committed by GitHub
commit a457828a67
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -255,7 +255,7 @@ export function DialogSelect<T>(props: DialogSelectProps<T>) {
props.onSelect?.(option) props.onSelect?.(option)
}} }}
onMouseOver={() => { onMouseOver={() => {
const index = filtered().findIndex((x) => isDeepEqual(x.value, option.value)) const index = flat().findIndex((x) => isDeepEqual(x.value, option.value))
if (index === -1) return if (index === -1) return
moveTo(index) moveTo(index)
}} }}