[web] Optionally Show FilePath on Now playing-Page
This commit is contained in:
parent
c645d570ea
commit
a4ae747b15
File diff suppressed because one or more lines are too long
|
@ -28,6 +28,7 @@
|
|||
static struct settings_option webinterface_options[] =
|
||||
{
|
||||
{ "show_composer_now_playing", SETTINGS_TYPE_BOOL },
|
||||
{ "show_filepath_now_playing", SETTINGS_TYPE_BOOL },
|
||||
{ "show_composer_for_genre", SETTINGS_TYPE_STR },
|
||||
{ "show_cover_artwork_in_album_lists", SETTINGS_TYPE_BOOL, { true } },
|
||||
{ "show_menu_item_playlists", SETTINGS_TYPE_BOOL, { true } },
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
{
|
||||
"name": "owntone-web",
|
||||
"version": "2.0.0",
|
||||
"version": "2.0.1",
|
||||
"lockfileVersion": 2,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "owntone-web",
|
||||
"version": "2.0.0",
|
||||
"version": "2.0.1",
|
||||
"dependencies": {
|
||||
"@aacassandra/vue3-progressbar": "^1.0.3",
|
||||
"@mdi/js": "^6.7.96",
|
||||
|
@ -2461,15 +2461,15 @@
|
|||
"dev": true
|
||||
},
|
||||
"node_modules/vite": {
|
||||
"version": "2.9.13",
|
||||
"resolved": "https://registry.npmjs.org/vite/-/vite-2.9.13.tgz",
|
||||
"integrity": "sha512-AsOBAaT0AD7Mhe8DuK+/kE4aWYFMx/i0ZNi98hJclxb4e0OhQcZYUrvLjIaQ8e59Ui7txcvKMiJC1yftqpQoDw==",
|
||||
"version": "2.9.15",
|
||||
"resolved": "https://registry.npmjs.org/vite/-/vite-2.9.15.tgz",
|
||||
"integrity": "sha512-fzMt2jK4vQ3yK56te3Kqpkaeq9DkcZfBbzHwYpobasvgYmP2SoAr6Aic05CsB4CzCZbsDv4sujX3pkEGhLabVQ==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"esbuild": "^0.14.27",
|
||||
"postcss": "^8.4.13",
|
||||
"resolve": "^1.22.0",
|
||||
"rollup": "^2.59.0"
|
||||
"rollup": ">=2.59.0 <2.78.0"
|
||||
},
|
||||
"bin": {
|
||||
"vite": "bin/vite.js"
|
||||
|
@ -4403,16 +4403,16 @@
|
|||
"dev": true
|
||||
},
|
||||
"vite": {
|
||||
"version": "2.9.13",
|
||||
"resolved": "https://registry.npmjs.org/vite/-/vite-2.9.13.tgz",
|
||||
"integrity": "sha512-AsOBAaT0AD7Mhe8DuK+/kE4aWYFMx/i0ZNi98hJclxb4e0OhQcZYUrvLjIaQ8e59Ui7txcvKMiJC1yftqpQoDw==",
|
||||
"version": "2.9.15",
|
||||
"resolved": "https://registry.npmjs.org/vite/-/vite-2.9.15.tgz",
|
||||
"integrity": "sha512-fzMt2jK4vQ3yK56te3Kqpkaeq9DkcZfBbzHwYpobasvgYmP2SoAr6Aic05CsB4CzCZbsDv4sujX3pkEGhLabVQ==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"esbuild": "^0.14.27",
|
||||
"fsevents": "~2.3.2",
|
||||
"postcss": "^8.4.13",
|
||||
"resolve": "^1.22.0",
|
||||
"rollup": "^2.59.0"
|
||||
"rollup": ">=2.59.0 <2.78.0"
|
||||
}
|
||||
},
|
||||
"vue": {
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "owntone-web",
|
||||
"version": "2.0.0",
|
||||
"version": "2.0.1",
|
||||
"scripts": {
|
||||
"serve": "vite",
|
||||
"build": "vite build --base='./'",
|
||||
|
|
|
@ -461,7 +461,8 @@
|
|||
"show-composer-genres": "Zeige den Komponisten für die aufgelisteten Genres an",
|
||||
"show-composer-info": "Wenn aktiviert, wird der Komponist auf der \"Aktuell läuft\"-Seite angezeigt.",
|
||||
"show-composer": "Komponisten anzeigen",
|
||||
"show-coverart": "Zeige Cover-Artwork in der Albumliste"
|
||||
"show-coverart": "Zeige Cover-Artwork in der Albumliste",
|
||||
"show-path": "Dateipfad auf der \"Aktuell läuft\"-Seite anzeigen"
|
||||
},
|
||||
"services": {
|
||||
"lastfm": {
|
||||
|
|
|
@ -453,13 +453,14 @@
|
|||
"recently-added-page-info": "Limit the number of albums shown on the \"Recently Added\" page",
|
||||
"recently-added-page": "Recently added page",
|
||||
"search": "Search",
|
||||
"show-composer-genres-info-1": "Comma separated list of genres the composer should be displayed on the \"now playing page\"",
|
||||
"show-composer-genres-info-1": "Comma separated list of genres the composer should be displayed on the \"Now playing page\"",
|
||||
"show-composer-genres-info-2": "Leave empty to always show the composer.",
|
||||
"show-composer-genres-info-3": "The genre tag of the current track is matched by checking, if one of the defined genres are included. For example setting to \"classical, soundtrack\" will show the composer for tracks with a genre tag of \"Contemporary Classical\"",
|
||||
"show-composer-genres": "Show composer only for listed genres",
|
||||
"show-composer-info": "If enabled the composer of the current playing track is shown on the \"now playing page\"",
|
||||
"show-composer-info": "If enabled the composer of the current playing track is shown on the \"Now playing page\"",
|
||||
"show-composer": "Show composer",
|
||||
"show-coverart": "Show cover artwork in album list"
|
||||
"show-coverart": "Show cover artwork in album list",
|
||||
"show-path": "Show filepath on the \"Now playing\" page"
|
||||
},
|
||||
"services": {
|
||||
"lastfm": {
|
||||
|
|
|
@ -457,9 +457,10 @@
|
|||
"show-composer-genres-info-2": "Laissez vide pour toujours afficher le compositeur.",
|
||||
"show-composer-genres-info-3": "L’étiquette de genre de la piste actuelle est comparée en vérifiant si l’un des genres définis est inclus. Par exemple, en choisissant \"classique, bande sonore\", le compositeur pour les pistes dont l’étiquette de genre est \"classique contemporain\" sera affiché.",
|
||||
"show-composer-genres": "Afficher le compositeur uniquement pour les genres listés",
|
||||
"show-composer-info": "Si actif, le compositeur de la piste en cours de lecture est affiché sur la page \"lecture en cours\"",
|
||||
"show-composer-info": "Si actif, le compositeur de la piste en cours de lecture est affiché sur la page \"Lecture en cours\"",
|
||||
"show-composer": "Afficher le compositeur",
|
||||
"show-coverart": "Afficher les illustration dans la liste d’albums"
|
||||
"show-coverart": "Afficher les illustration dans la liste d’albums",
|
||||
"show-path": "Afficher le chemin du fichier sur la page \"Lecture en cours\""
|
||||
},
|
||||
"services": {
|
||||
"lastfm": {
|
||||
|
|
|
@ -49,6 +49,11 @@
|
|||
v-text="composer"
|
||||
/>
|
||||
<h3 class="subtitle is-6" v-text="now_playing.album" />
|
||||
<h3
|
||||
v-if="filepath"
|
||||
class="subtitle is-6 has-text-grey "
|
||||
v-text="filepath"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -131,9 +136,21 @@ export default {
|
|||
}
|
||||
}
|
||||
return null
|
||||
}
|
||||
},
|
||||
|
||||
settings_option_show_filepath_now_playing() {
|
||||
return this.$store.getters.settings_option_show_filepath_now_playing
|
||||
},
|
||||
|
||||
filepath() {
|
||||
if (this.settings_option_show_filepath_now_playing) {
|
||||
return this.now_playing.path
|
||||
}
|
||||
return null
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
watch: {
|
||||
state() {
|
||||
if (this.interval_id > 0) {
|
||||
|
|
|
@ -144,6 +144,14 @@
|
|||
/>
|
||||
</template>
|
||||
</settings-textfield>
|
||||
<settings-checkbox
|
||||
category_name="webinterface"
|
||||
option_name="show_filepath_now_playing"
|
||||
>
|
||||
<template #label>
|
||||
<span v-text="$t('page.settings.general.show-path')" />
|
||||
</template>
|
||||
</settings-checkbox>
|
||||
</template>
|
||||
</content-with-heading>
|
||||
<content-with-heading>
|
||||
|
@ -192,6 +200,11 @@ export default {
|
|||
settings_option_show_composer_now_playing() {
|
||||
return this.$store.getters.settings_option_show_composer_now_playing
|
||||
},
|
||||
|
||||
settings_option_show_filepath_now_playing() {
|
||||
return this.$store.getters.settings_option_show_filepath_now_playing
|
||||
},
|
||||
|
||||
locale: {
|
||||
get() {
|
||||
let languages = this.$i18n.availableLocales
|
||||
|
|
|
@ -119,6 +119,18 @@ export default createStore({
|
|||
return null
|
||||
},
|
||||
|
||||
settings_option_show_filepath_now_playing: (state, getters) => {
|
||||
if (getters.settings_webinterface) {
|
||||
const option = getters.settings_webinterface.options.find(
|
||||
(elem) => elem.name === 'show_filepath_now_playing'
|
||||
)
|
||||
if (option) {
|
||||
return option.value
|
||||
}
|
||||
}
|
||||
return false
|
||||
},
|
||||
|
||||
settings_category: (state) => (categoryName) => {
|
||||
return state.settings.categories.find(
|
||||
(elem) => elem.name === categoryName
|
||||
|
|
Loading…
Reference in New Issue