fixes focus trap issue in inplace

pull/5772/head^2
navedqb 2024-05-23 11:05:45 +05:30 committed by GitHub
parent dd02b1d6fe
commit 9e34f4409a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 2 deletions

View File

@ -1,9 +1,9 @@
<template> <template>
<div v-focustrap :class="cx('root')" aria-live="polite" v-bind="ptmi('root')"> <div :class="cx('root')" aria-live="polite" v-bind="ptmi('root')">
<div v-if="!d_active" ref="display" :class="cx('display')" :tabindex="$attrs.tabindex || '0'" role="button" @click="open" @keydown.enter="open" v-bind="{ ...displayProps, ...ptm('display') }"> <div v-if="!d_active" ref="display" :class="cx('display')" :tabindex="$attrs.tabindex || '0'" role="button" @click="open" @keydown.enter="open" v-bind="{ ...displayProps, ...ptm('display') }">
<slot name="display"></slot> <slot name="display"></slot>
</div> </div>
<div v-else :class="cx('content')" v-bind="ptm('content')"> <div v-else v-focustrap :class="cx('content')" v-bind="ptm('content')">
<slot name="content"></slot> <slot name="content"></slot>
<IPButton v-if="closable" :aria-label="closeAriaLabel" @click="close" :unstyled="unstyled" :pt="ptm('closeButton')" v-bind="closeButtonProps"> <IPButton v-if="closable" :aria-label="closeAriaLabel" @click="close" :unstyled="unstyled" :pt="ptm('closeButton')" v-bind="closeButtonProps">
<template #icon> <template #icon>