Compare commits
1 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
25be34d9c7 |
71
package-lock.json
generated
71
package-lock.json
generated
@ -9,8 +9,7 @@
|
|||||||
"version": "0.1.0",
|
"version": "0.1.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@fortawesome/fontawesome-svg-core": "^6.3.0",
|
"@fortawesome/fontawesome-svg-core": "^6.3.0",
|
||||||
"@fortawesome/free-regular-svg-icons": "^6.4.2",
|
"@fortawesome/free-solid-svg-icons": "^6.3.0",
|
||||||
"@fortawesome/free-solid-svg-icons": "^6.4.2",
|
|
||||||
"@fortawesome/vue-fontawesome": "^3.0.3",
|
"@fortawesome/vue-fontawesome": "^3.0.3",
|
||||||
"axios": "^1.3.3",
|
"axios": "^1.3.3",
|
||||||
"body-parser": "^1.20.1",
|
"body-parser": "^1.20.1",
|
||||||
@ -1891,48 +1890,18 @@
|
|||||||
"node": ">=6"
|
"node": ">=6"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@fortawesome/free-regular-svg-icons": {
|
|
||||||
"version": "6.4.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/@fortawesome/free-regular-svg-icons/-/free-regular-svg-icons-6.4.2.tgz",
|
|
||||||
"integrity": "sha512-0+sIUWnkgTVVXVAPQmW4vxb9ZTHv0WstOa3rBx9iPxrrrDH6bNLsDYuwXF9b6fGm+iR7DKQvQshUH/FJm3ed9Q==",
|
|
||||||
"hasInstallScript": true,
|
|
||||||
"dependencies": {
|
|
||||||
"@fortawesome/fontawesome-common-types": "6.4.2"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@fortawesome/free-regular-svg-icons/node_modules/@fortawesome/fontawesome-common-types": {
|
|
||||||
"version": "6.4.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/@fortawesome/fontawesome-common-types/-/fontawesome-common-types-6.4.2.tgz",
|
|
||||||
"integrity": "sha512-1DgP7f+XQIJbLFCTX1V2QnxVmpLdKdzzo2k8EmvDOePfchaIGQ9eCHj2up3/jNEbZuBqel5OxiaOJf37TWauRA==",
|
|
||||||
"hasInstallScript": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">=6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@fortawesome/free-solid-svg-icons": {
|
"node_modules/@fortawesome/free-solid-svg-icons": {
|
||||||
"version": "6.4.2",
|
"version": "6.3.0",
|
||||||
"resolved": "https://registry.npmjs.org/@fortawesome/free-solid-svg-icons/-/free-solid-svg-icons-6.4.2.tgz",
|
"resolved": "https://registry.npmjs.org/@fortawesome/free-solid-svg-icons/-/free-solid-svg-icons-6.3.0.tgz",
|
||||||
"integrity": "sha512-sYwXurXUEQS32fZz9hVCUUv/xu49PEJEyUOsA51l6PU/qVgfbTb2glsTEaJngVVT8VqBATRIdh7XVgV1JF1LkA==",
|
"integrity": "sha512-x5tMwzF2lTH8pyv8yeZRodItP2IVlzzmBuD1M7BjawWgg9XAvktqJJ91Qjgoaf8qJpHQ8FEU9VxRfOkLhh86QA==",
|
||||||
"hasInstallScript": true,
|
"hasInstallScript": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@fortawesome/fontawesome-common-types": "6.4.2"
|
"@fortawesome/fontawesome-common-types": "6.3.0"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=6"
|
"node": ">=6"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@fortawesome/free-solid-svg-icons/node_modules/@fortawesome/fontawesome-common-types": {
|
|
||||||
"version": "6.4.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/@fortawesome/fontawesome-common-types/-/fontawesome-common-types-6.4.2.tgz",
|
|
||||||
"integrity": "sha512-1DgP7f+XQIJbLFCTX1V2QnxVmpLdKdzzo2k8EmvDOePfchaIGQ9eCHj2up3/jNEbZuBqel5OxiaOJf37TWauRA==",
|
|
||||||
"hasInstallScript": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">=6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@fortawesome/vue-fontawesome": {
|
"node_modules/@fortawesome/vue-fontawesome": {
|
||||||
"version": "3.0.3",
|
"version": "3.0.3",
|
||||||
"resolved": "https://registry.npmjs.org/@fortawesome/vue-fontawesome/-/vue-fontawesome-3.0.3.tgz",
|
"resolved": "https://registry.npmjs.org/@fortawesome/vue-fontawesome/-/vue-fontawesome-3.0.3.tgz",
|
||||||
@ -14992,34 +14961,12 @@
|
|||||||
"@fortawesome/fontawesome-common-types": "6.3.0"
|
"@fortawesome/fontawesome-common-types": "6.3.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"@fortawesome/free-regular-svg-icons": {
|
|
||||||
"version": "6.4.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/@fortawesome/free-regular-svg-icons/-/free-regular-svg-icons-6.4.2.tgz",
|
|
||||||
"integrity": "sha512-0+sIUWnkgTVVXVAPQmW4vxb9ZTHv0WstOa3rBx9iPxrrrDH6bNLsDYuwXF9b6fGm+iR7DKQvQshUH/FJm3ed9Q==",
|
|
||||||
"requires": {
|
|
||||||
"@fortawesome/fontawesome-common-types": "6.4.2"
|
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"@fortawesome/fontawesome-common-types": {
|
|
||||||
"version": "6.4.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/@fortawesome/fontawesome-common-types/-/fontawesome-common-types-6.4.2.tgz",
|
|
||||||
"integrity": "sha512-1DgP7f+XQIJbLFCTX1V2QnxVmpLdKdzzo2k8EmvDOePfchaIGQ9eCHj2up3/jNEbZuBqel5OxiaOJf37TWauRA=="
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"@fortawesome/free-solid-svg-icons": {
|
"@fortawesome/free-solid-svg-icons": {
|
||||||
"version": "6.4.2",
|
"version": "6.3.0",
|
||||||
"resolved": "https://registry.npmjs.org/@fortawesome/free-solid-svg-icons/-/free-solid-svg-icons-6.4.2.tgz",
|
"resolved": "https://registry.npmjs.org/@fortawesome/free-solid-svg-icons/-/free-solid-svg-icons-6.3.0.tgz",
|
||||||
"integrity": "sha512-sYwXurXUEQS32fZz9hVCUUv/xu49PEJEyUOsA51l6PU/qVgfbTb2glsTEaJngVVT8VqBATRIdh7XVgV1JF1LkA==",
|
"integrity": "sha512-x5tMwzF2lTH8pyv8yeZRodItP2IVlzzmBuD1M7BjawWgg9XAvktqJJ91Qjgoaf8qJpHQ8FEU9VxRfOkLhh86QA==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"@fortawesome/fontawesome-common-types": "6.4.2"
|
"@fortawesome/fontawesome-common-types": "6.3.0"
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"@fortawesome/fontawesome-common-types": {
|
|
||||||
"version": "6.4.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/@fortawesome/fontawesome-common-types/-/fontawesome-common-types-6.4.2.tgz",
|
|
||||||
"integrity": "sha512-1DgP7f+XQIJbLFCTX1V2QnxVmpLdKdzzo2k8EmvDOePfchaIGQ9eCHj2up3/jNEbZuBqel5OxiaOJf37TWauRA=="
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"@fortawesome/vue-fontawesome": {
|
"@fortawesome/vue-fontawesome": {
|
||||||
|
@ -14,8 +14,7 @@
|
|||||||
"main": "electron.js",
|
"main": "electron.js",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@fortawesome/fontawesome-svg-core": "^6.3.0",
|
"@fortawesome/fontawesome-svg-core": "^6.3.0",
|
||||||
"@fortawesome/free-regular-svg-icons": "^6.4.2",
|
"@fortawesome/free-solid-svg-icons": "^6.3.0",
|
||||||
"@fortawesome/free-solid-svg-icons": "^6.4.2",
|
|
||||||
"@fortawesome/vue-fontawesome": "^3.0.3",
|
"@fortawesome/vue-fontawesome": "^3.0.3",
|
||||||
"axios": "^1.3.3",
|
"axios": "^1.3.3",
|
||||||
"body-parser": "^1.20.1",
|
"body-parser": "^1.20.1",
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"backend_de": "http://localhost:31204",
|
"backend_dev": "http://localhost:31204",
|
||||||
"backend_dev": "https://webplay.rocks",
|
"backend_de": "https://webplay.rocks",
|
||||||
"backend": ""
|
"backend": "https://webplay.rocks"
|
||||||
}
|
}
|
@ -85,10 +85,23 @@ td.fillCell>* {
|
|||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.favourite {
|
||||||
|
z-index: 1;
|
||||||
|
position: absolute;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
.favourite.active {
|
.favourite.active {
|
||||||
color: var(--yellow);
|
color: var(--yellow);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.keepPlaying {
|
||||||
|
z-index: 1;
|
||||||
|
position: absolute;
|
||||||
|
cursor: pointer;
|
||||||
|
right: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
DIALOGS
|
DIALOGS
|
||||||
@ -625,8 +638,9 @@ td.fillCell>* {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#artists .artistCover {
|
#artists .artistCover {
|
||||||
width: 160px;
|
min-width: 100%;
|
||||||
height: initial;
|
height: initial;
|
||||||
|
min-height: 128px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#artists .artistName {
|
#artists .artistName {
|
||||||
|
@ -1741,10 +1741,6 @@ td.strech {
|
|||||||
box-shadow: 0 1px 4px var(--glow);
|
box-shadow: 0 1px 4px var(--glow);
|
||||||
}
|
}
|
||||||
|
|
||||||
.glow-text {
|
|
||||||
text-shadow: 0 1px 4px var(--glow);
|
|
||||||
}
|
|
||||||
|
|
||||||
.nowrap {
|
.nowrap {
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
@ -146,6 +146,8 @@ export default {
|
|||||||
this.audio.pause();
|
this.audio.pause();
|
||||||
this.audio.src = url;
|
this.audio.src = url;
|
||||||
|
|
||||||
|
this.pushHistoryItem();
|
||||||
|
|
||||||
if (this.currentTrackParent.progress) {
|
if (this.currentTrackParent.progress) {
|
||||||
if (this.currentTrackParent.progress.id == this.selectedTrack._id) {
|
if (this.currentTrackParent.progress.id == this.selectedTrack._id) {
|
||||||
this.skipToSecond(this.currentTrackParent.progress.progress);
|
this.skipToSecond(this.currentTrackParent.progress.progress);
|
||||||
@ -295,7 +297,6 @@ export default {
|
|||||||
track: this.selectedTrack,
|
track: this.selectedTrack,
|
||||||
rate: this.audioBpm,
|
rate: this.audioBpm,
|
||||||
});
|
});
|
||||||
this.pushHistoryItem();
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -1,32 +1,65 @@
|
|||||||
<template>
|
<template>
|
||||||
<div ref="dialogBackground" class="dialog-background" v-if="visible" @click="bgClicked">
|
<div
|
||||||
<div class="dialog-window" :class="{
|
ref="dialogBackground"
|
||||||
|
class="dialog-background"
|
||||||
|
v-if="visible"
|
||||||
|
@click="bgClicked"
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
class="dialog-window"
|
||||||
|
:class="{
|
||||||
fullscreen: isFullscreen,
|
fullscreen: isFullscreen,
|
||||||
'max-size': maxSize,
|
'max-size': maxSize,
|
||||||
playing: $store.getters['player/isPlaying'],
|
playing: $store.getters['player/isPlaying'],
|
||||||
}">
|
}"
|
||||||
<div class="dialog-header" :class="{ hideOnMobile: showHeaderOnMobile == false, 'flat-dialog-header': flatDialogHeader == true }" v-if="showHeader" @dblclick="headerDoubleClick">
|
>
|
||||||
|
<div
|
||||||
|
class="dialog-header"
|
||||||
|
:class="{ hideOnMobile: showHeaderOnMobile == false }"
|
||||||
|
v-if="showHeader"
|
||||||
|
@dblclick="headerDoubleClick"
|
||||||
|
>
|
||||||
<div class="dialog-header-left">
|
<div class="dialog-header-left">
|
||||||
<slot name="header-left" />
|
<slot name="header-left" />
|
||||||
</div>
|
</div>
|
||||||
<div class="dialog-header-center">
|
<div class="dialog-header-center">
|
||||||
<h3 v-if="dialogTitle && !flatDialogHeader">{{ dialogTitle }}</h3>
|
<h3 v-if="dialogTitle">{{ dialogTitle }}</h3>
|
||||||
<slot name="header-center" />
|
<slot name="header-center" />
|
||||||
</div>
|
</div>
|
||||||
<div class="dialog-header-right">
|
<div class="dialog-header-right">
|
||||||
<slot name="header-right" />
|
<slot name="header-right" />
|
||||||
<button class="hideOnMobile" @click="isFullscreen = !isFullscreen" v-if="showFullscreenButton" :title="isFullscreen ? 'Restore' : 'Fullscreen'">
|
<button
|
||||||
|
class="hideOnMobile"
|
||||||
|
@click="isFullscreen = !isFullscreen"
|
||||||
|
v-if="showFullscreenButton"
|
||||||
|
:title="isFullscreen ? 'Restore' : 'Fullscreen'"
|
||||||
|
>
|
||||||
<awesome-icon v-if="isFullscreen" icon="compress" />
|
<awesome-icon v-if="isFullscreen" icon="compress" />
|
||||||
<awesome-icon v-else icon="expand" />
|
<awesome-icon v-else icon="expand" />
|
||||||
</button>
|
</button>
|
||||||
<button @click="cancel" class="red" v-if="showCloseButton" title="Close">
|
<button
|
||||||
|
@click="cancel"
|
||||||
|
class="red"
|
||||||
|
v-if="showCloseButton"
|
||||||
|
title="Close"
|
||||||
|
>
|
||||||
<awesome-icon icon="times" />
|
<awesome-icon icon="times" />
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="dialog-body" :class="{ hideXScroll: disableXscroll == true, hideYScroll: disableYscroll == true, 'flat-dialog-header': flatDialogHeader == true }">
|
<div
|
||||||
|
class="dialog-body"
|
||||||
|
:class="{
|
||||||
|
hideXScroll: disableXscroll == true,
|
||||||
|
hideYScroll: disableYscroll == true,
|
||||||
|
}"
|
||||||
|
>
|
||||||
<slot />
|
<slot />
|
||||||
<div class="dialog-body-content" v-if="dialogContent" v-html="dialogContent" />
|
<div
|
||||||
|
class="dialog-body-content"
|
||||||
|
v-if="dialogContent"
|
||||||
|
v-html="dialogContent"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
<div class="dialog-footer" v-if="showFooter">
|
<div class="dialog-footer" v-if="showFooter">
|
||||||
<div class="dialog-footer-left">
|
<div class="dialog-footer-left">
|
||||||
@ -41,15 +74,41 @@
|
|||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<slot name="footer-right" />
|
<slot name="footer-right" />
|
||||||
<div class="dialog-footer-controls" v-if="showFooterButtons &&
|
<div
|
||||||
|
class="dialog-footer-controls"
|
||||||
|
v-if="
|
||||||
|
showFooterButtons &&
|
||||||
(openButtons == null || openButtons.length > 0)
|
(openButtons == null || openButtons.length > 0)
|
||||||
">
|
"
|
||||||
<button v-for="( button, i ) in dialogButtons " :key="i" @click="click('clicked', button.text || button)" :class="button.class || ''" :disabled="button.disabled" :title="button.title || ''" v-show="button.visible != false">
|
>
|
||||||
<awesome-icon v-if="button.icon" :icon="button.icon" class="ma-right8" />
|
<button
|
||||||
|
v-for="(button, i) in dialogButtons"
|
||||||
|
:key="i"
|
||||||
|
@click="click('clicked', button.text || button)"
|
||||||
|
:class="button.class || ''"
|
||||||
|
:disabled="button.disabled"
|
||||||
|
:title="button.title || ''"
|
||||||
|
v-show="button.visible != false"
|
||||||
|
>
|
||||||
|
<awesome-icon
|
||||||
|
v-if="button.icon"
|
||||||
|
:icon="button.icon"
|
||||||
|
class="ma-right8"
|
||||||
|
/>
|
||||||
{{ button.text || button }}
|
{{ button.text || button }}
|
||||||
</button>
|
</button>
|
||||||
<button ref="dialogButton" @click="click('accept')" v-if="showFooterButtons && !dialogButtons" :disabled="!enableFooterButtons" :class="buttonClass">
|
<button
|
||||||
<awesome-icon v-if="buttonIcon" :icon="buttonIcon" class="ma-right8" />
|
ref="dialogButton"
|
||||||
|
@click="click('accept')"
|
||||||
|
v-if="showFooterButtons && !dialogButtons"
|
||||||
|
:disabled="!enableFooterButtons"
|
||||||
|
:class="buttonClass"
|
||||||
|
>
|
||||||
|
<awesome-icon
|
||||||
|
v-if="buttonIcon"
|
||||||
|
:icon="buttonIcon"
|
||||||
|
class="ma-right8"
|
||||||
|
/>
|
||||||
{{ buttonText }}
|
{{ buttonText }}
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
@ -84,10 +143,6 @@ export default {
|
|||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: false,
|
default: false,
|
||||||
},
|
},
|
||||||
flatDialogHeader: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
showFooter: {
|
showFooter: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: true,
|
default: true,
|
||||||
@ -246,7 +301,6 @@ export default {
|
|||||||
z-index: 1000;
|
z-index: 1000;
|
||||||
animation: fadeIn ease 0.20s;
|
animation: fadeIn ease 0.20s;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-window {
|
.dialog-window {
|
||||||
box-shadow: 0px 8px 32px var(--shadow);
|
box-shadow: 0px 8px 32px var(--shadow);
|
||||||
background-color: var(--white);
|
background-color: var(--white);
|
||||||
@ -254,16 +308,13 @@ export default {
|
|||||||
max-height: 80%;
|
max-height: 80%;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
border-top-left-radius: 8px;
|
border-top-left-radius: 4px;
|
||||||
border-top-right-radius: 8px;
|
border-top-right-radius: 4px;
|
||||||
position: absolute;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-window.max-size {
|
.dialog-window.max-size {
|
||||||
width: 90%;
|
width: 90%;
|
||||||
height: 90%;
|
height: 90%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-window.fullscreen {
|
.dialog-window.fullscreen {
|
||||||
max-width: initial;
|
max-width: initial;
|
||||||
max-height: initial;
|
max-height: initial;
|
||||||
@ -278,21 +329,10 @@ export default {
|
|||||||
flex-shrink: 0;
|
flex-shrink: 0;
|
||||||
background-color: var(--background);
|
background-color: var(--background);
|
||||||
box-shadow: 0px 1px 4px var(--shadow);
|
box-shadow: 0px 1px 4px var(--shadow);
|
||||||
border-top-left-radius: 8px;
|
border-top-left-radius: 4px;
|
||||||
border-top-right-radius: 8px;
|
border-top-right-radius: 4px;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header.flat-dialog-header {
|
|
||||||
background: transparent;
|
|
||||||
position: absolute;
|
|
||||||
left: 0;
|
|
||||||
right: 0;
|
|
||||||
top: 0;
|
|
||||||
box-shadow: none;
|
|
||||||
z-index: 101;
|
|
||||||
}
|
|
||||||
|
|
||||||
.dialog-header h3 {
|
.dialog-header h3 {
|
||||||
flex-grow: 1;
|
flex-grow: 1;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
@ -304,7 +344,6 @@ export default {
|
|||||||
align-self: center;
|
align-self: center;
|
||||||
cursor: default;
|
cursor: default;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header input,
|
.dialog-header input,
|
||||||
.dialog-header select {
|
.dialog-header select {
|
||||||
padding: 0 4px;
|
padding: 0 4px;
|
||||||
@ -313,7 +352,6 @@ export default {
|
|||||||
background-color: var(--white);
|
background-color: var(--white);
|
||||||
align-self: stretch;
|
align-self: stretch;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header button,
|
.dialog-header button,
|
||||||
.dialog-header a {
|
.dialog-header a {
|
||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
@ -327,124 +365,85 @@ export default {
|
|||||||
.dialog-header button:hover {
|
.dialog-header button:hover {
|
||||||
background-color: var(--light-gray);
|
background-color: var(--light-gray);
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header button.red:hover {
|
.dialog-header button.red:hover {
|
||||||
background-color: var(--red50);
|
background-color: var(--red50);
|
||||||
color: var(--white);
|
color: var(--white);
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header button.red svg {
|
.dialog-header button.red svg {
|
||||||
color: var(--red);
|
color: var(--red);
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header button.red:hover svg {
|
.dialog-header button.red:hover svg {
|
||||||
color: var(--white);
|
color: var(--white);
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header button.blue {
|
.dialog-header button.blue {
|
||||||
background-color: var(--blue);
|
background-color: var(--blue);
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header button.green:hover {
|
.dialog-header button.green:hover {
|
||||||
background-color: var(--green);
|
background-color: var(--green);
|
||||||
color: var(--green);
|
color: var(--green);
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header button.green svg {
|
.dialog-header button.green svg {
|
||||||
color: var(--green);
|
color: var(--green);
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header button.yellow {
|
.dialog-header button.yellow {
|
||||||
background-color: var(--yellow);
|
background-color: var(--yellow);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* SUCCESS */
|
/* SUCCESS */
|
||||||
.dialog-header button.success svg {
|
.dialog-header button.success svg {
|
||||||
color: var(--success);
|
color: var(--success);
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header button.success:hover {
|
.dialog-header button.success:hover {
|
||||||
background-color: var(--success);
|
background-color: var(--success);
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header button.success:hover svg {
|
.dialog-header button.success:hover svg {
|
||||||
color: var(--white);
|
color: var(--white);
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header button.primary,
|
.dialog-header button.primary,
|
||||||
.dialog-header a.primary {
|
.dialog-header a.primary {
|
||||||
background-color: var(--primary);
|
background-color: var(--primary);
|
||||||
color: var(--white);
|
color: var(--white);
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header button > span,
|
.dialog-header button > span,
|
||||||
.dialog-header a > span {
|
.dialog-header a > span {
|
||||||
margin-left: 12px;
|
margin-left: 12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header svg {
|
.dialog-header svg {
|
||||||
width: 16px !important;
|
width: 16px !important;
|
||||||
height: 16px;
|
height: 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header > div,
|
.dialog-header > div,
|
||||||
.dialog-footer > div {
|
.dialog-footer > div {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header > .dialog-header-center,
|
.dialog-header > .dialog-header-center,
|
||||||
.dialog-footer > .dialog-footer-center {
|
.dialog-footer > .dialog-footer-center {
|
||||||
flex-grow: 1;
|
flex-grow: 1;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
margin: 0 12px;
|
margin: 0 12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header > .dialog-header-right input,
|
.dialog-header > .dialog-header-right input,
|
||||||
.dialog-header > .dialog-header-right select {
|
.dialog-header > .dialog-header-right select {
|
||||||
border-left: 1px solid var(--light-border);
|
border-left: 1px solid var(--light-border);
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header.flat-dialog-header>.dialog-header-right>button {
|
|
||||||
color: var(--white);
|
|
||||||
}
|
|
||||||
|
|
||||||
.dialog-header.flat-dialog-header>.dialog-header-right>button:hover {
|
|
||||||
color: var(--gray);
|
|
||||||
}
|
|
||||||
|
|
||||||
.dialog-body {
|
.dialog-body {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
flex-grow: 1;
|
flex-grow: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
.dialog-body.flat-dialog-header {
|
|
||||||
border-top-left-radius: 8px;
|
|
||||||
border-top-right-radius: 8px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.dialog-window.fullscreen .dialog-body.flat-dialog-header {
|
|
||||||
border-top-left-radius: 0px;
|
|
||||||
border-top-right-radius: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.dialog-body.hideXScroll {
|
.dialog-body.hideXScroll {
|
||||||
overflow-x: hidden;
|
overflow-x: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-body.hideYScroll {
|
.dialog-body.hideYScroll {
|
||||||
overflow-y: hidden;
|
overflow-y: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-body-content {
|
.dialog-body-content {
|
||||||
margin: 4px;
|
margin: 4px;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-footer {
|
.dialog-footer {
|
||||||
border-top: 1px solid var(--light-border);
|
border-top: 1px solid var(--light-border);
|
||||||
display: flex;
|
display: flex;
|
||||||
@ -452,33 +451,27 @@ export default {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
background-color: var(--background);
|
background-color: var(--background);
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-footer button:disabled {
|
.dialog-footer button:disabled {
|
||||||
opacity: 0.5;
|
opacity: 0.5;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-footer .dialog-message {
|
.dialog-footer .dialog-message {
|
||||||
flex-grow: 1;
|
flex-grow: 1;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
margin-left: 4px;
|
margin-left: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-footer .dialog-message svg {
|
.dialog-footer .dialog-message svg {
|
||||||
margin-right: 4px;
|
margin-right: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-footer .dialog-footer-controls {
|
.dialog-footer .dialog-footer-controls {
|
||||||
padding: 4px;
|
padding: 4px;
|
||||||
display: flex;
|
display: flex;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-footer .dialog-footer-controls button:not(:last-child) {
|
.dialog-footer .dialog-footer-controls button:not(:last-child) {
|
||||||
margin-right: 4px;
|
margin-right: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (max-width: 480px),
|
@media (max-width: 480px), (max-height: 480px) {
|
||||||
(max-height: 480px) {
|
|
||||||
.dialog-window {
|
.dialog-window {
|
||||||
max-width: initial;
|
max-width: initial;
|
||||||
max-height: initial;
|
max-height: initial;
|
||||||
@ -487,22 +480,14 @@ export default {
|
|||||||
border-top-left-radius: 0;
|
border-top-left-radius: 0;
|
||||||
border-top-right-radius: 0;
|
border-top-right-radius: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-window.max-size {
|
.dialog-window.max-size {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-header {
|
.dialog-header {
|
||||||
border-top-left-radius: 0;
|
border-top-left-radius: 0;
|
||||||
border-top-right-radius: 0;
|
border-top-right-radius: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dialog-body.flat-dialog-header {
|
|
||||||
border-top-left-radius: 0;
|
|
||||||
border-top-right-radius: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.dialog-window.playing {
|
.dialog-window.playing {
|
||||||
margin-bottom: 60px;
|
margin-bottom: 60px;
|
||||||
height: calc(100% - 60px);
|
height: calc(100% - 60px);
|
||||||
|
@ -1,46 +1,17 @@
|
|||||||
<template>
|
<template>
|
||||||
<DialogBase ref="dialogWindow" :title="album_title" @canceled="closed" :showFooter="false" :disableXscroll="true" :disableYscroll="true" :flatDialogHeader="true">
|
<DialogBase ref="dialogWindow" :title="album_title" @canceled="closed" :showFooter="false" :disableXscroll="true" :disableYscroll="true">
|
||||||
<div id="albumViewer" class="flex-row">
|
<div id="albumViewer" class="flex-row">
|
||||||
<div id="header" class="flex-column grow">
|
<div id="header" class="flex-column">
|
||||||
<div id="background" :style="coverBackground" />
|
<div id="background" :style="coverBackground" />
|
||||||
<div id="title" class="flex-column pa grow z1">
|
<div class="grow z1 center flex-column">
|
||||||
<img class="glow ma" :src="cover" />
|
<img class="glow ma24" :src="cover" @dblclick="dblclick" />
|
||||||
<span id="stats" class="center">
|
</div>
|
||||||
{{ selectedAlbum.title }}
|
<awesome-icon icon="star" size="2x" class="favourite ma4" :class="{ active: isFavourite }" @click="toggleFavourite" title="Favourite" />
|
||||||
<br />
|
<awesome-icon icon="play" size="2x" class="keepPlaying ma4 primary-text" @click="playProgress" v-if="selectedAlbum.progress" title="Keep playing" />
|
||||||
by
|
<div id="stats" class="flex-row z1">
|
||||||
<b @click="gotoArtist" class="pointer">{{ selectedAlbum.artist_name }}</b>
|
|
||||||
<br />
|
|
||||||
<span v-if="album_year">
|
|
||||||
from year <b>{{ album_year }}</b> </span><br />
|
|
||||||
<b>{{ album_tracks.length }}</b> Tracks with a duration of
|
|
||||||
<b>{{ album_duration }}</b>
|
|
||||||
</span>
|
|
||||||
<div class="grow"> </div>
|
|
||||||
<div class="flex-row grow ma-top">
|
|
||||||
<button class="flat ma-right" title="Favourite" @click="toggleFavourite">
|
|
||||||
<awesome-icon :icon="['fas', 'star']" size="2x" class="white-text favourite active" v-if="isFavourite" />
|
|
||||||
<awesome-icon :icon="['far', 'star']" size="2x" class="white-text favourite" v-else />
|
|
||||||
</button>
|
|
||||||
<button class="flat ma-right" title="Keep playing" v-if="selectedAlbum._id == selectedTrackContainer._id && isPlaying">
|
|
||||||
<awesome-icon icon="compact-disc" size="2x" class="primary-text" />
|
|
||||||
</button>
|
|
||||||
<button class="flat ma-right" title="Keep playing" @click="playProgress" v-else-if="selectedAlbum.progress">
|
|
||||||
<awesome-icon icon="play" size="2x" class="primary-text" />
|
|
||||||
</button>
|
|
||||||
<button class="flat ma-right" title="Play" @click="playAlbum" v-else>
|
|
||||||
<awesome-icon icon="play" size="2x" class="white-text" />
|
|
||||||
</button>
|
|
||||||
<button @click="gotoPrevAlbum" class="flat ma-left ma-right" :title="prevAlbum.name" :disabled="!prevAlbum._id">
|
|
||||||
<awesome-icon icon="angle-left" class="ma4 white-text" />
|
|
||||||
</button>
|
|
||||||
<button @click="gotoNextAlbum" class="flat" :title="nextAlbum.name" :disabled="!nextAlbum._id">
|
|
||||||
<awesome-icon icon="angle-right" class="ma4 white-text" />
|
|
||||||
</button>
|
|
||||||
<div class="grow"></div>
|
|
||||||
<DropDown v-if="$store.getters['user/isAdministrator']">
|
<DropDown v-if="$store.getters['user/isAdministrator']">
|
||||||
<button class="flat center" :title="visibility_text">
|
<button class="flat center" :title="visibility_text">
|
||||||
<awesome-icon :icon="visibility_icon" class="white-text" />
|
<awesome-icon :icon="visibility_icon" />
|
||||||
</button>
|
</button>
|
||||||
<template v-slot:dropdown-content>
|
<template v-slot:dropdown-content>
|
||||||
<div>
|
<div>
|
||||||
@ -62,9 +33,24 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</DropDown>
|
</DropDown>
|
||||||
|
<div class="grow flex-column">
|
||||||
|
<p class="ma4 center">
|
||||||
|
<span class="grow center">
|
||||||
|
by
|
||||||
|
<b @click="gotoArtist" class="pointer">{{
|
||||||
|
selectedAlbum.artist_name
|
||||||
|
}}</b>
|
||||||
|
<br />
|
||||||
|
<span v-if="album_year">
|
||||||
|
from year <b>{{ album_year }}</b> </span><br />
|
||||||
|
<b>{{ album_tracks.length }}</b> Tracks with a duration of
|
||||||
|
<b>{{ album_duration }}</b>
|
||||||
|
</span>
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
<DropDown v-if="$store.getters['user/isAdministrator']">
|
<DropDown v-if="$store.getters['user/isAdministrator']">
|
||||||
<button class="flat center">
|
<button class="flat center">
|
||||||
<awesome-icon icon="ellipsis-v" class="white-text" />
|
<awesome-icon icon="ellipsis-v" />
|
||||||
</button>
|
</button>
|
||||||
<template v-slot:dropdown-content>
|
<template v-slot:dropdown-content>
|
||||||
<div>
|
<div>
|
||||||
@ -83,7 +69,6 @@
|
|||||||
</DropDown>
|
</DropDown>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
<ul id="trackList" class="tracks">
|
<ul id="trackList" class="tracks">
|
||||||
<li v-for="track in selectedAlbum.tracks" :key="track._id">
|
<li v-for="track in selectedAlbum.tracks" :key="track._id">
|
||||||
<TrackItem :track="track" :showCover="false" />
|
<TrackItem :track="track" :showCover="false" />
|
||||||
@ -115,7 +100,7 @@ export default {
|
|||||||
window.location.origin + "/#/share?id=" + this.selectedAlbum.share._id;
|
window.location.origin + "/#/share?id=" + this.selectedAlbum.share._id;
|
||||||
navigator.clipboard.writeText(url);
|
navigator.clipboard.writeText(url);
|
||||||
},
|
},
|
||||||
playAlbum() {
|
dblclick() {
|
||||||
this.$store.commit("tracks/resetSelectedTrack");
|
this.$store.commit("tracks/resetSelectedTrack");
|
||||||
this.$store.commit("radios/resetSelectedRadio");
|
this.$store.commit("radios/resetSelectedRadio");
|
||||||
this.$store.dispatch("tracks/playContainer", this.selectedAlbum);
|
this.$store.dispatch("tracks/playContainer", this.selectedAlbum);
|
||||||
@ -246,9 +231,7 @@ export default {
|
|||||||
nextAlbum: ["albums/nextAlbum"],
|
nextAlbum: ["albums/nextAlbum"],
|
||||||
selectedAlbum: ["albums/selectedAlbum"],
|
selectedAlbum: ["albums/selectedAlbum"],
|
||||||
selectedTrack: ["tracks/selectedTrack"],
|
selectedTrack: ["tracks/selectedTrack"],
|
||||||
selectedTrackContainer: ["tracks/selectedTrackContainer"],
|
|
||||||
favourites: ["user/favourites"],
|
favourites: ["user/favourites"],
|
||||||
isPlaying: ["player/isPlaying"],
|
|
||||||
}),
|
}),
|
||||||
album_title() {
|
album_title() {
|
||||||
return this.selectedAlbum.title;
|
return this.selectedAlbum.title;
|
||||||
@ -349,13 +332,11 @@ export default {
|
|||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
#albumViewer {
|
#albumViewer {
|
||||||
height: 400px;
|
height: 366px;
|
||||||
width: 640px;
|
width: 640px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#header {
|
#header {
|
||||||
width: 304px;
|
|
||||||
height: 400px;
|
|
||||||
position: relative;
|
position: relative;
|
||||||
background-color: black;
|
background-color: black;
|
||||||
}
|
}
|
||||||
@ -367,8 +348,13 @@ export default {
|
|||||||
|
|
||||||
#stats {
|
#stats {
|
||||||
z-index: 2;
|
z-index: 2;
|
||||||
|
align-items: center;
|
||||||
color: var(--white);
|
color: var(--white);
|
||||||
text-shadow: 0 1px 2px black;
|
text-shadow: 0 1px 2px black;
|
||||||
|
line-height: 1.4;
|
||||||
|
background-color: #ffffff40;
|
||||||
|
border-top: 1px solid #ffffff20;
|
||||||
|
border-bottom: 1px solid #00000020;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dropdown-activator button {
|
.dropdown-activator button {
|
||||||
|
@ -1,10 +1,11 @@
|
|||||||
<template>
|
<template>
|
||||||
<DialogBase ref="dialogWindow" id="dialogWindow" :title="selectedArtist.name" @canceled="closed" :showFooter="false" :flatDialogHeader="true" :showFullscreenButton="true" :disableXscroll="true" :disableYscroll="true">
|
<DialogBase ref="dialogWindow" id="dialogWindow" :title="selectedArtist.name" @canceled="closed" :showFooter="false" :showFullscreenButton="true" :disableXscroll="true" :disableYscroll="true">
|
||||||
<div id="artistViewer">
|
<div id="artistViewer">
|
||||||
<div id="header" class="flex-column">
|
<div id="header" class="flex-column">
|
||||||
<div id="background" :style="coverBackground" />
|
<div id="background" :style="coverBackground" />
|
||||||
<div id="title" class="flex-column ma-left ma-right pa-bottom">
|
<awesome-icon icon="star" size="2x" class="favourite ma4" :class="{ active: isFavourite }" @click="toggleFavourite" />
|
||||||
<h1>
|
<awesome-icon icon="play" size="2x" class="keepPlaying ma4 primary-text" @click="playProgress" v-if="selectedArtist.progress" title="Keep playing" />
|
||||||
|
<h1 @dblclick="dblclick">
|
||||||
{{ selectedArtist.name }}
|
{{ selectedArtist.name }}
|
||||||
</h1>
|
</h1>
|
||||||
<span id="stats" class="ma-bottom">
|
<span id="stats" class="ma-bottom">
|
||||||
@ -12,30 +13,23 @@
|
|||||||
<b>{{ artist_albums.length }}</b> Albums with a duration of
|
<b>{{ artist_albums.length }}</b> Albums with a duration of
|
||||||
<b>{{ artist_duration }}</b>
|
<b>{{ artist_duration }}</b>
|
||||||
</span>
|
</span>
|
||||||
<div class="flex-row ma-top ma-bottom">
|
<div id="albumList" class="flex-row showOnMobilePortrait">
|
||||||
<button class="flat ma-right" @click="toggleFavourite" title="Favourite">
|
<AlbumItem class="ma" :class="{ playing: playingAlbumId == album._id }" v-for="album in selectedArtist.albums" :key="album._id" :item="album" @click="scrollToAlbum(album)" @dblclick="playAlbum(album)" />
|
||||||
<awesome-icon :icon="['fas', 'star']" size="2x" class="white-text favourite active" v-if="isFavourite" />
|
</div>
|
||||||
<awesome-icon :icon="['far', 'star']" size="2x" class="white-text favourite" v-else />
|
<div id="navigation" class="flex-row center ma-top">
|
||||||
|
<div class="flex-row grow"></div>
|
||||||
|
<div class="flex-row">
|
||||||
|
<button @click="gotoPrevArtist" class="primary ma4" :title="prevArtist.name" :disabled="!prevArtist._id">
|
||||||
|
<awesome-icon icon="angle-left" class="ma4" />
|
||||||
</button>
|
</button>
|
||||||
<button class="flat ma-right" title="Keep playing" v-if="selectedArtist._id == selectedTrackContainer._id && isPlaying">
|
<button @click="gotoNextArtist" class="primary ma4" :title="nextArtist.name" :disabled="!nextArtist._id">
|
||||||
<awesome-icon icon="compact-disc" size="2x" class="primary-text" />
|
<awesome-icon icon="angle-right" class="ma4" />
|
||||||
</button>
|
</button>
|
||||||
<button class="flat ma-right" @click="playProgress" title="Keep playing" v-else-if="selectedArtist.progress">
|
</div>
|
||||||
<awesome-icon icon="play" size="2x" class="primary-text" />
|
<div class="flex-row grow right center">
|
||||||
</button>
|
<DropDown v-if="$store.getters['user/isAdministrator']" class="hideOnMobile">
|
||||||
<button class="flat ma-right" @click="playArtist" title="Play" v-else>
|
<button class="flat pa8-left pa8-right">
|
||||||
<awesome-icon icon="play" size="2x" class="white-text" />
|
<awesome-icon icon="ellipsis-v" />
|
||||||
</button>
|
|
||||||
<button @click="gotoPrevArtist" class="flat ma-left ma-right" :title="prevArtist.name" :disabled="!prevArtist._id">
|
|
||||||
<awesome-icon icon="angle-left" class="ma4 white-text" />
|
|
||||||
</button>
|
|
||||||
<button @click="gotoNextArtist" class="flat" :title="nextArtist.name" :disabled="!nextArtist._id">
|
|
||||||
<awesome-icon icon="angle-right" class="ma4 white-text" />
|
|
||||||
</button>
|
|
||||||
|
|
||||||
<DropDown v-if="$store.getters['user/isAdministrator']" class="ma-left hideOnMobile">
|
|
||||||
<button class="flat pa-left pa-right">
|
|
||||||
<awesome-icon icon="ellipsis-v" class="white-text" />
|
|
||||||
</button>
|
</button>
|
||||||
<template v-slot:dropdown-content>
|
<template v-slot:dropdown-content>
|
||||||
<div>
|
<div>
|
||||||
@ -54,9 +48,6 @@
|
|||||||
</DropDown>
|
</DropDown>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id="albumList" class="flex-row showOnMobilePortrait">
|
|
||||||
<AlbumItem class="ma" :class="{ playing: playingAlbumId == album._id }" v-for="album in selectedArtist.albums" :key="album._id" :item="album" @click="scrollToAlbum(album)" @dblclick="playAlbum(album)" />
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="flex-row overflow-y">
|
<div class="flex-row overflow-y">
|
||||||
<div id="albumList" class="flex-column hideOnMobilePortrait">
|
<div id="albumList" class="flex-column hideOnMobilePortrait">
|
||||||
@ -86,7 +77,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
playArtist() {
|
dblclick() {
|
||||||
this.$store.commit("tracks/resetSelectedTrack");
|
this.$store.commit("tracks/resetSelectedTrack");
|
||||||
this.$store.commit("radios/resetSelectedRadio");
|
this.$store.commit("radios/resetSelectedRadio");
|
||||||
this.$store.dispatch("tracks/playContainer", this.selectedArtist);
|
this.$store.dispatch("tracks/playContainer", this.selectedArtist);
|
||||||
@ -119,9 +110,8 @@ export default {
|
|||||||
},
|
},
|
||||||
closed() {
|
closed() {
|
||||||
if (
|
if (
|
||||||
window.history.state.back && (
|
|
||||||
window.history.state.back.indexOf("?") == -1 ||
|
window.history.state.back.indexOf("?") == -1 ||
|
||||||
window.history.state.back.startsWith("/search"))
|
window.history.state.back.startsWith("/search")
|
||||||
) {
|
) {
|
||||||
this.$router.back();
|
this.$router.back();
|
||||||
} else {
|
} else {
|
||||||
@ -179,7 +169,6 @@ export default {
|
|||||||
nextArtist: ["artists/nextArtist"],
|
nextArtist: ["artists/nextArtist"],
|
||||||
selectedArtist: ["artists/selectedArtist"],
|
selectedArtist: ["artists/selectedArtist"],
|
||||||
selectedTrack: ["tracks/selectedTrack"],
|
selectedTrack: ["tracks/selectedTrack"],
|
||||||
selectedTrackContainer: ["tracks/selectedTrackContainer"],
|
|
||||||
favourites: ["user/favourites"],
|
favourites: ["user/favourites"],
|
||||||
isPlaying: ["player/isPlaying"]
|
isPlaying: ["player/isPlaying"]
|
||||||
}),
|
}),
|
||||||
@ -273,6 +262,7 @@ export default {
|
|||||||
h1,
|
h1,
|
||||||
#stats {
|
#stats {
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
|
text-align: center;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
color: var(--white);
|
color: var(--white);
|
||||||
text-shadow: 0 1px 2px black;
|
text-shadow: 0 1px 2px black;
|
||||||
@ -290,10 +280,6 @@ h1,
|
|||||||
max-width: 100%;
|
max-width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
#header #title {
|
|
||||||
z-index: 100;
|
|
||||||
}
|
|
||||||
|
|
||||||
#albumList {
|
#albumList {
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
|
@ -1,38 +1,18 @@
|
|||||||
<template>
|
<template>
|
||||||
<DialogBase ref="dialogWindow" :title="selectedBox.title" @canceled="closed" :showFooter="false" :closeOnEscape="selectedVideo._id == null" :disableXscroll="true" :disableYscroll="true" :flatDialogHeader="true">
|
<DialogBase ref="dialogWindow" :title="selectedBox.title" @canceled="closed" :showFooter="false" :closeOnEscape="selectedVideo._id == null" :disableXscroll="true" :disableYscroll="true">
|
||||||
<div id="boxViewer" class="flex-row">
|
<div id="boxViewer" class="flex-row">
|
||||||
<div id="header" class="flex-column grow">
|
<div id="header" class="flex-column">
|
||||||
<div id="background" :style="coverBackground" />
|
<div id="background" :style="coverBackground" />
|
||||||
<div id="title" class="grow z1 pa flex-column">
|
<div class="grow z1 center flex-column">
|
||||||
<img class="glow ma" :src="cover" />
|
<img class="glow ma24" :src="cover" @dblclick="dblclick" />
|
||||||
<span id="stats" class="center">
|
</div>
|
||||||
<b>{{ selectedBox.title }}</b>
|
<awesome-icon icon="star" size="2x" class="favourite ma4 z2" :class="{ active: isFavourite }" @click="toggleFavourite" />
|
||||||
<br />
|
<awesome-icon icon="play" size="2x" class="keepPlaying ma4 primary-text" @click="playProgress" v-if="selectedBox.progress" title="Keep playing" />
|
||||||
<b>{{ box_videos.length }}</b> Videos
|
|
||||||
</span>
|
|
||||||
|
|
||||||
<div class="grow"> </div>
|
<div id="stats" class="flex-row z1">
|
||||||
<div class="flex-row ma-top grow">
|
|
||||||
<button class="flat ma-right" title="Favourite" @click="toggleFavourite">
|
|
||||||
<awesome-icon :icon="['fas', 'star']" size="2x" class="white-text favourite active" v-if="isFavourite" />
|
|
||||||
<awesome-icon :icon="['far', 'star']" size="2x" class="white-text favourite" v-else />
|
|
||||||
</button>
|
|
||||||
<button class="flat ma-right" title="Keep playing" @click="playProgress" v-if="selectedBox.progress">
|
|
||||||
<awesome-icon icon="play" size="2x" class="primary-text" />
|
|
||||||
</button>
|
|
||||||
<button class="flat ma-right" title="Play" @dblclick="dblclick" v-else>
|
|
||||||
<awesome-icon icon="play" size="2x" class="white-text" />
|
|
||||||
</button>
|
|
||||||
<button @click="gotoPrevBox" class="flat ma-left ma-right" :title="prevBox.name" :disabled="!prevBox._id">
|
|
||||||
<awesome-icon icon="angle-left" class="ma4 white-text" />
|
|
||||||
</button>
|
|
||||||
<button @click="gotoNextBox" class="flat" :title="nextBox.name" :disabled="!nextBox._id">
|
|
||||||
<awesome-icon icon="angle-right" class="ma4 white-text" />
|
|
||||||
</button>
|
|
||||||
<div class="grow"></div>
|
|
||||||
<DropDown v-if="$store.getters['user/isAdministrator']">
|
<DropDown v-if="$store.getters['user/isAdministrator']">
|
||||||
<button class="flat center" :title="visibility_text">
|
<button class="flat center" :title="visibility_text">
|
||||||
<awesome-icon :icon="visibility_icon" class="white-text" />
|
<awesome-icon :icon="visibility_icon" />
|
||||||
</button>
|
</button>
|
||||||
<template v-slot:dropdown-content>
|
<template v-slot:dropdown-content>
|
||||||
<div>
|
<div>
|
||||||
@ -54,9 +34,18 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</DropDown>
|
</DropDown>
|
||||||
|
<div class="grow flex-column">
|
||||||
|
<p class="ma4 center">
|
||||||
|
<span class="">
|
||||||
|
<b>{{ selectedBox.title }}</b>
|
||||||
|
<br />
|
||||||
|
<b>{{ box_videos.length }}</b> Videos
|
||||||
|
</span>
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
<DropDown v-if="$store.getters['user/isAdministrator']">
|
<DropDown v-if="$store.getters['user/isAdministrator']">
|
||||||
<button class="flat center">
|
<button class="flat center">
|
||||||
<awesome-icon icon="ellipsis-v" class="white-text" />
|
<awesome-icon icon="ellipsis-v" />
|
||||||
</button>
|
</button>
|
||||||
<template v-slot:dropdown-content>
|
<template v-slot:dropdown-content>
|
||||||
<div>
|
<div>
|
||||||
@ -75,7 +64,7 @@
|
|||||||
</DropDown>
|
</DropDown>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
<ul id="videoList" class="videos">
|
<ul id="videoList" class="videos">
|
||||||
<li v-for="item in selectedBox.videos" :key="item._id">
|
<li v-for="item in selectedBox.videos" :key="item._id">
|
||||||
<VideoItem :video="item" />
|
<VideoItem :video="item" />
|
||||||
@ -276,7 +265,7 @@ export default {
|
|||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
#boxViewer {
|
#boxViewer {
|
||||||
height: 486px;
|
height: 462px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#header {
|
#header {
|
||||||
@ -291,8 +280,13 @@ export default {
|
|||||||
|
|
||||||
#stats {
|
#stats {
|
||||||
z-index: 2;
|
z-index: 2;
|
||||||
|
align-items: center;
|
||||||
color: var(--white);
|
color: var(--white);
|
||||||
text-shadow: 0 1px 2px black;
|
text-shadow: 0 1px 2px black;
|
||||||
|
line-height: 1.4;
|
||||||
|
background-color: #ffffff40;
|
||||||
|
border-top: 1px solid #ffffff20;
|
||||||
|
border-bottom: 1px solid #00000020;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dropdown-activator button {
|
.dropdown-activator button {
|
||||||
@ -300,6 +294,11 @@ export default {
|
|||||||
height: 32px;
|
height: 32px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#stats p {
|
||||||
|
max-width: 192px;
|
||||||
|
align-self: center;
|
||||||
|
}
|
||||||
|
|
||||||
#videoList {
|
#videoList {
|
||||||
background-color: var(--white);
|
background-color: var(--white);
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
|
@ -4,7 +4,6 @@ import App from './App.vue'
|
|||||||
|
|
||||||
import { library } from '@fortawesome/fontawesome-svg-core'
|
import { library } from '@fortawesome/fontawesome-svg-core'
|
||||||
import { fas } from '@fortawesome/free-solid-svg-icons'
|
import { fas } from '@fortawesome/free-solid-svg-icons'
|
||||||
import { far } from '@fortawesome/free-regular-svg-icons'
|
|
||||||
import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome'
|
import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome'
|
||||||
|
|
||||||
import DialogBase from "./components/base-components/Dialog";
|
import DialogBase from "./components/base-components/Dialog";
|
||||||
@ -16,7 +15,6 @@ import ArtistItem from "./components/Artist"
|
|||||||
import BoxItem from "./components/Box"
|
import BoxItem from "./components/Box"
|
||||||
|
|
||||||
library.add(fas)
|
library.add(fas)
|
||||||
library.add(far)
|
|
||||||
|
|
||||||
import store from "./store/index";
|
import store from "./store/index";
|
||||||
import router from './router'
|
import router from './router'
|
||||||
|
@ -3,12 +3,18 @@ import axios from 'axios'
|
|||||||
export default {
|
export default {
|
||||||
checkIfInstanceIsNew(context) {
|
checkIfInstanceIsNew(context) {
|
||||||
return new Promise((resolve) => {
|
return new Promise((resolve) => {
|
||||||
axios.get(context.rootGetters.server + "/api/system/setup").then((res) => {
|
axios
|
||||||
|
.get(context.rootGetters.server + "/api/system/setup")
|
||||||
|
.then((res) => {
|
||||||
|
console.log(res.status);
|
||||||
if (res.status == 200) {
|
if (res.status == 200) {
|
||||||
resolve(true);
|
resolve(true);
|
||||||
} else {
|
} else {
|
||||||
resolve(false);
|
resolve(false);
|
||||||
}
|
}
|
||||||
|
})
|
||||||
|
.catch(err => {
|
||||||
|
console.log(err);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -32,15 +32,12 @@ export default {
|
|||||||
|
|
||||||
},
|
},
|
||||||
loadAlbums(context, force) {
|
loadAlbums(context, force) {
|
||||||
return new Promise((resolve) => {
|
|
||||||
if ((!context.state.eos || force) && !context.state.loading) {
|
if ((!context.state.eos || force) && !context.state.loading) {
|
||||||
context.state.loading = true;
|
context.state.loading = true;
|
||||||
axios.get(context.rootGetters.server + "/api/albums/page/" + context.state.page++, context.rootGetters.headers).then((res) => {
|
axios.get(context.rootGetters.server + "/api/albums/page/" + context.state.page++, context.rootGetters.headers).then((res) => {
|
||||||
context.commit("setAlbums", res.data);
|
context.commit("setAlbums", res.data);
|
||||||
resolve(res.data);
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
|
||||||
},
|
},
|
||||||
loadFavourites(context) {
|
loadFavourites(context) {
|
||||||
axios.get(context.rootGetters.server + "/api/albums/favourites", context.rootGetters.headers).then(res => {
|
axios.get(context.rootGetters.server + "/api/albums/favourites", context.rootGetters.headers).then(res => {
|
||||||
|
@ -13,15 +13,12 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
loadArtists(context, force) {
|
loadArtists(context, force) {
|
||||||
return new Promise((resolve) => {
|
|
||||||
if ((!context.state.eos || force) && !context.state.loading) {
|
if ((!context.state.eos || force) && !context.state.loading) {
|
||||||
context.state.loading = true;
|
context.state.loading = true;
|
||||||
axios.get(context.rootGetters.server + "/api/artists/page/" + context.state.page++, context.rootGetters.headers).then((res) => {
|
axios.get(context.rootGetters.server + "/api/artists/page/" + context.state.page++, context.rootGetters.headers).then((res) => {
|
||||||
context.commit("setArtists", res.data);
|
context.commit("setArtists", res.data);
|
||||||
resolve(res.data);
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
|
||||||
},
|
},
|
||||||
loadArtist(context, id) {
|
loadArtist(context, id) {
|
||||||
context.state.loading = true;
|
context.state.loading = true;
|
||||||
|
@ -13,15 +13,12 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
loadBoxes(context, force) {
|
loadBoxes(context, force) {
|
||||||
return new Promise((resolve) => {
|
|
||||||
if ((!context.state.eos || force) && !context.state.loading) {
|
if ((!context.state.eos || force) && !context.state.loading) {
|
||||||
context.state.loading = true;
|
context.state.loading = true;
|
||||||
axios.get(context.rootGetters.server + "/api/boxes/page/" + context.state.page++, context.rootGetters.headers).then((res) => {
|
axios.get(context.rootGetters.server + "/api/boxes/page/" + context.state.page++, context.rootGetters.headers).then((res) => {
|
||||||
context.commit("setBoxes", res.data);
|
context.commit("setBoxes", res.data);
|
||||||
resolve(res.data);
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
|
||||||
},
|
},
|
||||||
loadFavourites(context) {
|
loadFavourites(context) {
|
||||||
axios.get(context.rootGetters.server + "/api/boxes/favourites", context.rootGetters.headers).then(res => {
|
axios.get(context.rootGetters.server + "/api/boxes/favourites", context.rootGetters.headers).then(res => {
|
||||||
|
@ -10,11 +10,13 @@ export default {
|
|||||||
load(context) {
|
load(context) {
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
axios.get(context.rootGetters.server + "/api/user/login", context.rootGetters.headers).then((res) => {
|
axios.get(context.rootGetters.server + "/api/user/login", context.rootGetters.headers).then((res) => {
|
||||||
|
console.log(res.data);
|
||||||
context.commit("load", res.data);
|
context.commit("load", res.data);
|
||||||
context.rootState["player"].shuffle = res.data.player.shuffle;
|
context.rootState["player"].shuffle = res.data.player.shuffle;
|
||||||
context.rootState["player"].repeatType = res.data.player.repeat;
|
context.rootState["player"].repeatType = res.data.player.repeat;
|
||||||
resolve();
|
resolve();
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
|
console.log("error")
|
||||||
context.commit("resetToken");
|
context.commit("resetToken");
|
||||||
reject(err);
|
reject(err);
|
||||||
});
|
});
|
||||||
|
@ -7,12 +7,20 @@
|
|||||||
<g>
|
<g>
|
||||||
<animateTransform id="animY1" attributeName="transform" type="translate" begin="0s; animY2.end" from="0 -140" to="-20 -60" dur="30s" />
|
<animateTransform id="animY1" attributeName="transform" type="translate" begin="0s; animY2.end" from="0 -140" to="-20 -60" dur="30s" />
|
||||||
<animateTransform id="animY2" attributeName="transform" type="translate" begin="animY1.end" from="-20 -60" to="0 -140" dur="30s" />
|
<animateTransform id="animY2" attributeName="transform" type="translate" begin="animY1.end" from="-20 -60" to="0 -140" dur="30s" />
|
||||||
|
|
||||||
<image :xlink:href="item.covers.cover64" :x="Math.floor(i / 6) * 64" :y="i % 6 * 64" width="64" height="64" v-for="(item, i) in randomCovers" :key="item" />
|
<image :xlink:href="item.covers.cover64" :x="Math.floor(i / 6) * 64" :y="i % 6 * 64" width="64" height="64" v-for="(item, i) in randomCovers" :key="item" />
|
||||||
</g>
|
</g>
|
||||||
</svg>
|
</svg>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex-column" style="z-index: 1;">
|
<div class="flex-column" style="z-index: 1;">
|
||||||
<h1>WebPlay</h1>
|
<h1>WebPlay</h1>
|
||||||
|
<p>
|
||||||
|
<b>{{ serverInfo.stats.tracks.toLocaleString("de-DE") }}</b> Tracks
|
||||||
|
and
|
||||||
|
<b>{{ serverInfo.stats.videos.toLocaleString("de-DE") }}</b> Videos |
|
||||||
|
Users:
|
||||||
|
<b>{{ serverInfo.stats.users }}</b>
|
||||||
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<MessageScreen title="First Run?" subtitle="You still don't have any Music or Video content on your instance" icon="sync" :commands="messageCommands" @commandClicked="messageCommand" :showCommands="$store.getters['user/isAdministrator']" v-if="serverInfo.stats.tracks == 0 && serverInfo.stats.videos == 0" />
|
<MessageScreen title="First Run?" subtitle="You still don't have any Music or Video content on your instance" icon="sync" :commands="messageCommands" @commandClicked="messageCommand" :showCommands="$store.getters['user/isAdministrator']" v-if="serverInfo.stats.tracks == 0 && serverInfo.stats.videos == 0" />
|
||||||
@ -81,13 +89,13 @@ export default {
|
|||||||
messageCommands: [
|
messageCommands: [
|
||||||
{
|
{
|
||||||
title: "Scan for Music files",
|
title: "Scan for Music files",
|
||||||
subtitle: "Scan your server for music files…",
|
subtitle: "Scann your server for music files…",
|
||||||
icon: "music",
|
icon: "music",
|
||||||
command: "scanMusic",
|
command: "scanMusic",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "Scan for Video files",
|
title: "Scan for Video files",
|
||||||
subtitle: "Scan your server for video files…",
|
subtitle: "Scann your server for video files…",
|
||||||
icon: "video",
|
icon: "video",
|
||||||
command: "scanVideos",
|
command: "scanVideos",
|
||||||
},
|
},
|
||||||
@ -106,11 +114,8 @@ export default {
|
|||||||
this.$store.dispatch("videos/loadMostViewed");
|
this.$store.dispatch("videos/loadMostViewed");
|
||||||
if (this.randomCovers.length == 0) {
|
if (this.randomCovers.length == 0) {
|
||||||
this.$store.dispatch("albums/loadRandomCovers", 60);
|
this.$store.dispatch("albums/loadRandomCovers", 60);
|
||||||
this.$store.dispatch("albums/loadAlbums", true).then(() => {
|
this.$store.dispatch("albums/loadAlbums", true);
|
||||||
this.$store.dispatch("artists/loadArtists", true).then(() => {
|
this.$store.dispatch("artists/loadArtists", true);
|
||||||
this.$store.dispatch("boxes/loadBoxes", true);
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
loadNextPage() {
|
loadNextPage() {
|
||||||
|
@ -123,13 +123,17 @@ export default {
|
|||||||
checkTocken() {
|
checkTocken() {
|
||||||
let token = localStorage.getItem("token");
|
let token = localStorage.getItem("token");
|
||||||
if (token) {
|
if (token) {
|
||||||
|
console.log("hello token")
|
||||||
this.$store.dispatch("user/setToken", token);
|
this.$store.dispatch("user/setToken", token);
|
||||||
|
console.log("hello token; user/load")
|
||||||
this.$store
|
this.$store
|
||||||
.dispatch("user/load")
|
.dispatch("user/load")
|
||||||
.then(() => {
|
.then(() => {
|
||||||
|
console.log("user loaded")
|
||||||
this.goto();
|
this.goto();
|
||||||
})
|
})
|
||||||
.catch((err) => {
|
.catch((err) => {
|
||||||
|
console.log("user not loaded")
|
||||||
console.log(err);
|
console.log(err);
|
||||||
this.checkIfNewBackend();
|
this.checkIfNewBackend();
|
||||||
});
|
});
|
||||||
@ -157,6 +161,7 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
checkIfNewBackend() {
|
checkIfNewBackend() {
|
||||||
|
console.log("check new instance")
|
||||||
this.$store.dispatch("checkIfInstanceIsNew").then((res) => {
|
this.$store.dispatch("checkIfInstanceIsNew").then((res) => {
|
||||||
if (res) {
|
if (res) {
|
||||||
this.$router.replace("setup");
|
this.$router.replace("setup");
|
||||||
|
Loading…
Reference in New Issue
Block a user