2022-04-15 14:24:30 +00:00
|
|
|
<template>
|
2022-04-30 11:55:54 +00:00
|
|
|
<footer id="mainFooter" @contextmenu.prevent="requestContextMenu">
|
2022-10-13 15:18:47 +00:00
|
|
|
<AudioPlayer/>
|
2022-04-15 14:24:30 +00:00
|
|
|
|
2022-10-13 15:18:47 +00:00
|
|
|
<div class="wrapper">
|
|
|
|
<SongInfo/>
|
|
|
|
<PlaybackControls/>
|
|
|
|
<ExtraControls/>
|
2022-04-15 14:24:30 +00:00
|
|
|
</div>
|
|
|
|
</footer>
|
|
|
|
</template>
|
|
|
|
|
2022-04-15 17:00:08 +00:00
|
|
|
<script lang="ts" setup>
|
|
|
|
import { ref } from 'vue'
|
2022-10-13 15:18:47 +00:00
|
|
|
import { eventBus, requireInjection } from '@/utils'
|
|
|
|
import { CurrentSongKey } from '@/symbols'
|
2022-04-15 17:00:08 +00:00
|
|
|
|
2022-10-13 15:18:47 +00:00
|
|
|
import AudioPlayer from '@/components/layout/app-footer/AudioPlayer.vue'
|
|
|
|
import SongInfo from '@/components/layout/app-footer/FooterSongInfo.vue'
|
2022-04-20 15:57:53 +00:00
|
|
|
import ExtraControls from '@/components/layout/app-footer/FooterExtraControls.vue'
|
2022-10-13 15:18:47 +00:00
|
|
|
import PlaybackControls from '@/components/layout/app-footer/FooterPlaybackControls.vue'
|
2022-04-15 14:24:30 +00:00
|
|
|
|
2022-10-13 15:18:47 +00:00
|
|
|
const song = requireInjection(CurrentSongKey, ref(null))
|
2022-04-15 14:24:30 +00:00
|
|
|
|
2022-04-15 17:00:08 +00:00
|
|
|
const requestContextMenu = (event: MouseEvent) => {
|
2022-10-13 15:18:47 +00:00
|
|
|
song.value && eventBus.emit('SONG_CONTEXT_MENU_REQUESTED', event, song.value)
|
2022-04-15 17:00:08 +00:00
|
|
|
}
|
2022-04-15 14:24:30 +00:00
|
|
|
</script>
|
|
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
footer {
|
|
|
|
background: var(--color-bg-secondary);
|
|
|
|
height: var(--footer-height);
|
|
|
|
display: flex;
|
2022-10-13 15:18:47 +00:00
|
|
|
box-shadow: 0 0 30px 20px rgba(0, 0, 0, .2);
|
|
|
|
flex-direction: column;
|
2022-04-15 14:24:30 +00:00
|
|
|
position: relative;
|
2022-10-13 15:18:47 +00:00
|
|
|
z-index: 1;
|
2022-04-15 14:24:30 +00:00
|
|
|
|
2022-10-13 15:18:47 +00:00
|
|
|
.wrapper {
|
2022-04-15 14:24:30 +00:00
|
|
|
display: flex;
|
2022-10-13 15:18:47 +00:00
|
|
|
flex: 1;
|
2022-04-15 14:24:30 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
</style>
|