Skip to content

Commit

Permalink
fix(Select): 'popper' item not focused when open via arrow navigation (
Browse files Browse the repository at this point in the history
  • Loading branch information
zernonia committed Feb 5, 2024
1 parent 1021bf1 commit 7b3c606
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions packages/radix-vue/src/Popper/PopperContent.vue
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,9 @@ defineOptions({
const props = withDefaults(defineProps<PopperContentProps>(), {
...PopperContentPropsDefaultValue,
})
const emits = defineEmits<{
placed: [void]
}>()
const rootContext = injectPopperRootContext()
const { forwardRef, currentElement: contentElement } = useForwardExpose()
Expand Down Expand Up @@ -290,6 +293,11 @@ const placedAlign = computed(
() => getSideAndAlignFromPlacement(placement.value)[1],
)
watchEffect(() => {
if (isPositioned.value)
emits('placed')
})
const cannotCenterArrow = computed(
() => middlewareData.value.arrow?.centerOffset !== 0,
)
Expand Down

0 comments on commit 7b3c606

Please sign in to comment.