environments/review-front-deve-otr6gc/deployments/13419
wvffle 2022-07-21 15:25:22 +00:00 zatwierdzone przez Georg Krause
rodzic 998bd02a05
commit c0719c21f1
2 zmienionych plików z 10 dodań i 1 usunięć

Wyświetl plik

@ -1,6 +1,6 @@
<script setup lang="ts">
import { useStore } from '~/store'
import { nextTick, onMounted, ref, computed } from 'vue'
import { nextTick, onMounted, ref, computed, onBeforeMount, onUnmounted } from 'vue'
import { useRouter } from 'vue-router'
import time from '~/utils/time'
import { useFocusTrap } from '@vueuse/integrations/useFocusTrap'
@ -14,6 +14,14 @@ import usePlayer from '~/composables/audio/usePlayer'
const queueModal = ref()
let savedScroll = 0
onBeforeMount(() => (savedScroll = window.scrollY))
onUnmounted(() => {
document.body.parentElement?.setAttribute('style', 'scroll-behavior: auto')
window.scrollTo({ top: savedScroll, behavior: undefined })
document.body.parentElement?.removeAttribute('style')
})
const { activate } = useFocusTrap(queueModal, { allowOutsideClick: true })
activate()

Wyświetl plik

@ -213,6 +213,7 @@
align-items: center;
justify-content: space-between;
min-width: 10em;
z-index: 2;
> .control.button {
padding: 0.5em;