[web] Rename player page

This commit is contained in:
Alain Nussbaumer
2025-05-29 21:40:47 +02:00
parent 0c7e94b903
commit 5f2785171c
13 changed files with 54 additions and 63 deletions

View File

@@ -13,7 +13,7 @@
@remove="removePodcast"
>
<template #content>
<i18n-t keypath="dialog.podcast.remove.info" tag="p" scope="global">
<i18n-t tag="p" keypath="dialog.podcast.remove.info" scope="global">
<template #separator>
<br />
</template>

View File

@@ -1,10 +1,10 @@
<template>
<nav class="navbar is-fixed-bottom" :class="{ 'is-dark': !isNowPlayingPage }">
<nav class="navbar is-fixed-bottom" :class="{ 'is-dark': !isPlayerPage }">
<div class="navbar-brand is-flex-grow-1">
<control-link class="navbar-item" :to="{ name: 'queue' }">
<mdicon class="icon" name="playlist-play" />
</control-link>
<template v-if="isNowPlayingPage">
<template v-if="isPlayerPage">
<control-player-previous class="navbar-item ml-auto" />
<control-player-back class="navbar-item" :offset="10000" />
<control-player-play class="navbar-item" />
@@ -13,22 +13,14 @@
</template>
<template v-else>
<control-link
:to="{ name: 'now-playing' }"
:to="{ name: 'player' }"
exact
class="navbar-item is-justify-content-flex-start is-expanded is-clipped is-size-7"
>
<div class="is-text-clipped">
<strong v-text="queueStore.current.title" />
<br />
<span v-text="queueStore.current.artist" />
<span
v-if="queueStore.current.album"
v-text="
$t('navigation.now-playing', {
album: queueStore.current.album
})
"
/>
<span v-text="metadata" />
</div>
</control-link>
<control-player-play class="navbar-item" />
@@ -115,8 +107,12 @@ export default {
}
},
computed: {
isNowPlayingPage() {
return this.$route.name === 'now-playing'
isPlayerPage() {
return this.$route.name === 'player'
},
metadata() {
const { current } = this.queueStore
return [current.artist, current.album].filter(Boolean).join(' - ')
}
}
}

View File

@@ -40,7 +40,7 @@
<span
:class="{
'pl-5': menu.sub,
'has-text-weight-semibold': !menu.sub
'has-text-weight-semibold': menu.icon
}"
v-text="$t(menu.key)"
/>

View File

@@ -121,7 +121,6 @@
"artists": "Künstler",
"audiobooks": "Hörbücher",
"composers": "Komponisten",
"now-playing": " - {album}",
"stream-error": "HTTP-stream-Fehler: Stream kann nicht geladen werden oder wurde wg. Netzwerkfehler gestopt",
"stream": "HTTP-stream",
"volume": "Lautstärke",
@@ -208,7 +207,7 @@
"spotify": "Spotify"
}
},
"now-playing": {
"player": {
"info": "Tracks durch Auswählen aus der Bibliothek anfügen",
"time": "Live|{time}|{time}",
"title": "Deine Playliste ist leer."
@@ -279,7 +278,7 @@
"navigation-item-selection-info": "Auf den Bildschirmen mobiler Geräte wird nur das Burger-Menü angezeigt.",
"navigation-item-selection": "Wähle hier die Einträge des oberen Navigationsmenüs",
"navigation-items": "Navigationsmenüs",
"now-playing-page": "Aktuell läuft-Seite",
"player-page": "Aktuell läuft-Seite",
"playlists": "Playlisten",
"podcasts": "Podcasts",
"radio": "Radio",

View File

@@ -121,7 +121,6 @@
"artists": "Artists",
"audiobooks": "Audiobooks",
"composers": "Composers",
"now-playing": " - {album}",
"stream-error": "HTTP stream error: failed to load stream or stopped loading due to network problem",
"stream": "HTTP stream",
"volume": "Volume",
@@ -208,7 +207,7 @@
"spotify": "Spotify"
}
},
"now-playing": {
"player": {
"info": "Add some tracks by browsing your library",
"time": "Live|{time}|{time}",
"title": "Your play queue is empty"
@@ -279,7 +278,7 @@
"navigation-item-selection-info": "On mobile device screens, only the burger menu is displayed.",
"navigation-item-selection": "Select the top navigation bar menu items",
"navigation-items": "Navigation Bar",
"now-playing-page": "Now playing page",
"player-page": "Player page",
"playlists": "Playlists",
"podcasts": "Podcasts",
"radio": "Radio",

View File

@@ -121,7 +121,6 @@
"artists": "Artistes",
"audiobooks": "Livres audio",
"composers": "Compositeurs",
"now-playing": " - {album}",
"stream-error": "Erreur du flux HTTP : échec du chargement du flux ou arrêt du chargement en raison dun problème réseau",
"stream": "Flux HTTP",
"volume": "Volume",
@@ -208,7 +207,7 @@
"spotify": "Spotify"
}
},
"now-playing": {
"player": {
"info": "Ajoutez des pistes en parcourant votre bibliothèque",
"time": "En direct|{time}|{time}",
"title": "La file dattente est vide"
@@ -279,7 +278,7 @@
"navigation-item-selection-info": "Sur les écrans des appareils mobiles, seul le menu est affiché.",
"navigation-item-selection": "Sélectionnez les éléments de la barre de navigation supérieure",
"navigation-items": "Barre de navigation",
"now-playing-page": "Page « En cours de lecture »",
"player-page": "Page « En cours de lecture »",
"playlists": "Listes de lecture",
"podcasts": "Podcasts",
"radio": "Radio",

View File

@@ -121,7 +121,6 @@
"artists": "艺人",
"audiobooks": "有声读物",
"composers": "作曲家",
"now-playing": " - {album}",
"stream-error": "HTTP流错误流载入失败或者由于网络原因无法载入",
"stream": "HTTP流",
"volume": "音量",
@@ -208,7 +207,7 @@
"spotify": "Spotify"
}
},
"now-playing": {
"player": {
"info": "浏览资料库添加曲目",
"time": "直播|{time}|{time}",
"title": "播放清单是空的"
@@ -279,7 +278,7 @@
"navigation-item-selection-info": "在移动设备屏幕上,只显示汉堡菜单",
"navigation-item-selection": "选择顶部导航栏菜单项",
"navigation-items": "导航条",
"now-playing-page": "“正在播放”页面",
"player-page": "“正在播放”页面",
"playlists": "播放列表",
"podcasts": "播客",
"radio": "广播电台",

View File

@@ -121,7 +121,6 @@
"artists": "藝人",
"audiobooks": "有聲書",
"composers": "作曲家",
"now-playing": " - {album}",
"stream-error": "HTTP串流錯誤串流載入失敗或者由於網絡原因無法載入",
"stream": "HTTP串流",
"volume": "音量",
@@ -208,7 +207,7 @@
"spotify": "Spotify"
}
},
"now-playing": {
"player": {
"info": "瀏覽資料庫新增曲目",
"time": "直播|{time}|{time}",
"title": "播放清單是空的"
@@ -279,7 +278,7 @@
"navigation-item-selection-info": "在行動裝置螢幕上,只會顯示漢堡菜單",
"navigation-item-selection": "選擇頂部導航欄菜單項",
"navigation-items": "導航條",
"now-playing-page": "“正在播放”頁面",
"player-page": "“正在播放”頁面",
"playlists": "播放列表",
"podcasts": "Podcast",
"radio": "電台",

View File

@@ -41,8 +41,8 @@
/>
</div>
<div v-else class="mx-auto">
<p class="title is-5" v-text="$t('page.now-playing.title')" />
<p class="subtitle" v-text="$t('page.now-playing.info')" />
<p class="title is-5" v-text="$t('page.player.title')" />
<p class="subtitle" v-text="$t('page.player.info')" />
</div>
</div>
<modal-dialog-queue-item
@@ -65,7 +65,7 @@ import { useSettingsStore } from '@/stores/settings'
const INTERVAL = 1000
export default {
name: 'PageNowPlaying',
name: 'PagePlayer',
components: {
ControlImage,
ControlSlider,
@@ -129,7 +129,7 @@ export default {
return Number(this.isLive) || Math.floor(this.track.length_ms / INTERVAL)
},
trackTotalTime() {
return this.$t('page.now-playing.time', this.track.length_ms, {
return this.$t('page.player.time', this.track.length_ms, {
named: {
time: this.$formatters.toTimecode(this.track.length_ms)
}

View File

@@ -84,7 +84,7 @@
<content-with-heading>
<template #heading>
<pane-title
:content="{ title: $t('page.settings.general.now-playing-page') }"
:content="{ title: $t('page.settings.general.player-page') }"
/>
</template>
<template #content>
@@ -118,9 +118,9 @@
</template>
<template #help>
<i18n-t
keypath="page.settings.general.show-composer-genres-help"
tag="p"
class="help"
keypath="page.settings.general.show-composer-genres-help"
scope="global"
>
<slot><br /></slot>

View File

@@ -25,7 +25,7 @@ import PageMusicRecentlyPlayed from '@/pages/PageMusicRecentlyPlayed.vue'
import PageMusicSpotify from '@/pages/PageMusicSpotify.vue'
import PageMusicSpotifyFeaturedPlaylists from '@/pages/PageMusicSpotifyFeaturedPlaylists.vue'
import PageMusicSpotifyNewReleases from '@/pages/PageMusicSpotifyNewReleases.vue'
import PageNowPlaying from '@/pages/PageNowPlaying.vue'
import PagePlayer from '@/pages/PagePlayer.vue'
import PagePlaylistFolder from '@/pages/PagePlaylistFolder.vue'
import PagePlaylistTracks from '@/pages/PagePlaylistTracks.vue'
import PagePlaylistTracksSpotify from '@/pages/PagePlaylistTracksSpotify.vue'
@@ -174,7 +174,7 @@ export const router = createRouter({
name: 'music-genres',
path: '/music/genres'
},
{ component: PageNowPlaying, name: 'now-playing', path: '/now-playing' },
{ component: PagePlayer, name: 'player', path: '/player' },
{
name: 'playlists',
path: '/playlists',