Merge branch 'upcoming' of https://github.com/maikirakiwi/Cider into upcoming
This commit is contained in:
commit
a2f9ceda54
3 changed files with 31 additions and 39 deletions
|
@ -1988,6 +1988,10 @@ const app = new Vue({
|
|||
this.library.albums.meta = response.data.meta
|
||||
},
|
||||
async getListenNow(attempt = 0) {
|
||||
if (this.listennow.timestamp > Date.now() - 120000) {
|
||||
return
|
||||
}
|
||||
|
||||
if (attempt > 3) {
|
||||
return
|
||||
}
|
||||
|
@ -2018,6 +2022,7 @@ const app = new Vue({
|
|||
includeResponseMeta: !0,
|
||||
reload: !0
|
||||
})).data;
|
||||
this.listennow.timestamp = Date.now()
|
||||
console.log(this.listennow)
|
||||
} catch (e) {
|
||||
console.log(e)
|
||||
|
@ -2025,6 +2030,9 @@ const app = new Vue({
|
|||
}
|
||||
},
|
||||
async getBrowsePage(attempt = 0) {
|
||||
if (this.browsepage.timestamp > Date.now() - 120000) {
|
||||
return
|
||||
}
|
||||
if (attempt > 3) {
|
||||
return
|
||||
}
|
||||
|
@ -2041,6 +2049,7 @@ const app = new Vue({
|
|||
"art[url]": "f"
|
||||
});
|
||||
this.browsepage = browse.data.data[0];
|
||||
this.browsepage.timestamp = Date.now()
|
||||
console.log(this.browsepage)
|
||||
} catch (e) {
|
||||
console.log(e)
|
||||
|
@ -3407,6 +3416,7 @@ const app = new Vue({
|
|||
let element = document.querySelector(selector);
|
||||
var overflowX = element.offsetWidth < element.scrollWidth,
|
||||
overflowY = element.offsetHeight < element.scrollHeight;
|
||||
element.setAttribute('data-value', '\xa0\xa0\xa0\xa0' + element.textContent);
|
||||
|
||||
return (overflowX || overflowY); } catch (e) { return false}
|
||||
},
|
||||
|
@ -3414,34 +3424,6 @@ const app = new Vue({
|
|||
//this.webremoteqr = await ipcRenderer.invoke('setRemoteQR','')
|
||||
this.webremoteurl = await ipcRenderer.invoke('showQR','')
|
||||
//this.modals.qrcode = true;
|
||||
|
||||
},
|
||||
checkMarquee() {
|
||||
if(isElementOverflowing('#app-main > div.app-chrome > div.app-chrome--center > div > div > div.playback-info > div.song-artist') == true) {
|
||||
document.getElementsByClassName('song-artist')[0].classList.add('marquee');
|
||||
document.getElementsByClassName('song-artist')[1].classList.add('marquee-after');
|
||||
}
|
||||
if(isElementOverflowing('#app-main > div.app-chrome > div.app-chrome--center > div > div > div.playback-info > div.song-name') == true) {
|
||||
document.getElementsByClassName('song-name')[0].classList.add('marquee');
|
||||
document.getElementsByClassName('song-name')[1].classList.add('marquee-after');
|
||||
}
|
||||
},
|
||||
closeWindow(){
|
||||
switch (app.cfg.general.close_behavior) {
|
||||
case 0:
|
||||
case '0':
|
||||
ipcRenderer.send('close');
|
||||
break;
|
||||
case 1:
|
||||
case '1':
|
||||
ipcRenderer.send('minimize');
|
||||
break;
|
||||
case 2:
|
||||
case '2':
|
||||
ipcRenderer.send('minimizeTray');
|
||||
break;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1111,6 +1111,9 @@ input[type=range].web-slider::-webkit-slider-runnable-track {
|
|||
&.song-name{
|
||||
overflow: unset ;
|
||||
}
|
||||
&::after{
|
||||
content: attr(data-value);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
@ -1166,11 +1169,11 @@ input[type=range].web-slider::-webkit-slider-runnable-track {
|
|||
|
||||
@keyframes marquee {
|
||||
from {
|
||||
transform: translateX(100%);
|
||||
transform: translateX(0);
|
||||
}
|
||||
|
||||
to {
|
||||
transform: translateX(-100%);
|
||||
transform: translateX(-140%);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1249,13 +1252,12 @@ input[type=range].web-slider::-webkit-slider-runnable-track {
|
|||
display: flex;
|
||||
position: relative;
|
||||
}
|
||||
.app-chrome .app-chrome-item > .app-playback-controls .song-artist-album {
|
||||
.app-chrome .app-chrome-item > .app-playback-controls > div >.song-artist-album {
|
||||
font-weight: 400;
|
||||
font-size: 12px;
|
||||
text-align: center;
|
||||
/*height: 1.2em;
|
||||
line-height: 1.2em;*/
|
||||
|
||||
z-index: 1;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
|
@ -1263,11 +1265,18 @@ input[type=range].web-slider::-webkit-slider-runnable-track {
|
|||
max-width: 340px;
|
||||
overflow: hidden;
|
||||
|
||||
.song-artist-album-content{
|
||||
font-weight: 400;
|
||||
font-size: 12px;
|
||||
text-align: center;
|
||||
width:100%;
|
||||
|
||||
.song-artist-normal {
|
||||
height: inherit;
|
||||
&.song-artist-normal {
|
||||
height: inherit;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
&.song-artist-marquee {
|
||||
> marquee {
|
||||
margin-bottom: -3px;
|
||||
|
|
|
@ -86,17 +86,17 @@
|
|||
<mediaitem-artwork :url="currentArtUrl"></mediaitem-artwork>
|
||||
</div>
|
||||
<div class="playback-info">
|
||||
<!-- :class="[isElementOverflowing('#app-main > div.app-chrome > div.app-chrome--center > div > div > div.playback-info > div.song-name') ? 'marquee' : '']" -->
|
||||
<div class="song-name" style="-webkit-box-orient: horizontal;"
|
||||
|
||||
:class="[isElementOverflowing('#app-main > div.app-chrome > div.app-chrome--center > div > div > div.playback-info > div.song-name') ? 'marquee' : '']"
|
||||
:style="[mk.nowPlayingItem['attributes']['contentRating'] == 'explicit' ? {'margin-left' : '23px'} : {'margin-left' : '0px'} ]">
|
||||
{{ mk.nowPlayingItem["attributes"]["name"] }}
|
||||
<div class="explicit-icon"
|
||||
v-if="mk.nowPlayingItem['attributes']['contentRating'] == 'explicit'"
|
||||
style="display: inline-block"></div>
|
||||
</div>
|
||||
<!-- :class="[isElementOverflowing('#app-main > div.app-chrome > div.app-chrome--center > div > div > div.playback-info > div.song-artist') ? 'marquee' : '']" -->
|
||||
<div class="song-artist-album"
|
||||
<div class="song-artist-album">
|
||||
<div class="song-artist-album-content"
|
||||
:class="[isElementOverflowing('#app-main > .app-chrome .app-chrome-item > .app-playback-controls > div >.song-artist-album > .song-artist-album-content') ? 'marquee' : '']"
|
||||
style="display: inline-block; -webkit-box-orient: horizontal; white-space: nowrap;">
|
||||
<div class="item-navigate song-artist" style="display: inline-block"
|
||||
@click="getNowPlayingItemDetailed(`artist`)">
|
||||
|
@ -110,6 +110,7 @@
|
|||
(mk.nowPlayingItem["attributes"]["albumName"]) : "" }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="song-progress">
|
||||
<div class="song-duration"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue