1
1
mirror of https://github.com/Fabio286/antares.git synced 2025-06-05 21:59:22 +02:00

fix: focus goes outside modals with tab key navigation

This commit is contained in:
2022-06-26 15:07:37 +02:00
parent 0a3a4827dd
commit e42c424a13
14 changed files with 140 additions and 23 deletions

View File

@ -2,7 +2,7 @@
<Teleport to="#window-content">
<div id="settings" class="modal active">
<a class="modal-overlay c-hand" @click="closeModal" />
<div class="modal-container">
<div ref="trapRef" class="modal-container">
<div class="modal-header pl-2">
<div class="modal-title h6">
<div class="d-flex">
@ -309,6 +309,7 @@ import { useI18n } from 'vue-i18n';
import { useApplicationStore } from '@/stores/application';
import { useSettingsStore } from '@/stores/settings';
import { useWorkspacesStore } from '@/stores/workspaces';
import { useFocusTrap } from '@/composables/useFocusTrap';
import { localesNames } from '@/i18n/supported-locales';
import ModalSettingsUpdate from '@/components/ModalSettingsUpdate.vue';
import ModalSettingsChangelog from '@/components/ModalSettingsChangelog.vue';
@ -322,6 +323,8 @@ const applicationStore = useApplicationStore();
const settingsStore = useSettingsStore();
const workspacesStore = useWorkspacesStore();
const { trapRef } = useFocusTrap({ disableAutofocus: true });
const {
selectedSettingTab,
updateStatus