Merge pull request #5772 from qburst/fix--5770

fix: focus trap issue in Inplace
pull/5863/head
Tuğçe Küçükoğlu 2024-06-10 10:38:42 +03:00 committed by GitHub
commit 774139cf38
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>