Skip to content

Commit

Permalink
feat(SelectItem): fix situation when initial event is prevented by th…
Browse files Browse the repository at this point in the history
…e parent
  • Loading branch information
kilobyte2007 committed Dec 31, 2024
1 parent ad88d9e commit 2922b10
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion packages/core/src/Select/SelectItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,10 @@ const textId = useId(undefined, 'reka-select-item-text')
const SELECT_SELECT = 'select.select'
function handleSelectCustomEvent(ev: PointerEvent | KeyboardEvent) {
async function handleSelectCustomEvent(ev: PointerEvent | KeyboardEvent) {
if (ev.defaultPrevented)
return
const eventDetail = { originalEvent: ev, value: props.value as T }
handleAndDispatchCustomEvent(SELECT_SELECT, handleSelect, eventDetail)
}
Expand Down

0 comments on commit 2922b10

Please sign in to comment.