Update: Move title to left if image is missing for opened active item

pull/52/head
Juraj Nyíri 3 years ago
parent f4e9eec304
commit c91f41e100

@ -22819,7 +22819,12 @@ class PlexMeetsHomeAssistant extends HTMLElement {
} }
this.detailElem.style.transition = '0s'; this.detailElem.style.transition = '0s';
this.detailElem.style.top = `${top - 1000}px`; this.detailElem.style.top = `${top - 1000}px`;
if (!lodash.isEmpty(lodash.get(data, 'thumb'))) {
this.detailElem.style.left = `${this.minExpandedWidth + 30}px`; this.detailElem.style.left = `${this.minExpandedWidth + 30}px`;
}
else {
this.detailElem.style.left = `16px`;
}
clearInterval(this.showDetailsTimeout); clearInterval(this.showDetailsTimeout);
// eslint-disable-next-line @typescript-eslint/no-misused-promises // eslint-disable-next-line @typescript-eslint/no-misused-promises
this.showDetailsTimeout = setTimeout(async () => { this.showDetailsTimeout = setTimeout(async () => {

@ -1185,7 +1185,12 @@ class PlexMeetsHomeAssistant extends HTMLElement {
this.detailElem.style.transition = '0s'; this.detailElem.style.transition = '0s';
this.detailElem.style.top = `${top - 1000}px`; this.detailElem.style.top = `${top - 1000}px`;
if (!_.isEmpty(_.get(data, 'thumb'))) {
this.detailElem.style.left = `${this.minExpandedWidth + 30}px`; this.detailElem.style.left = `${this.minExpandedWidth + 30}px`;
} else {
this.detailElem.style.left = `16px`;
}
clearInterval(this.showDetailsTimeout); clearInterval(this.showDetailsTimeout);
// eslint-disable-next-line @typescript-eslint/no-misused-promises // eslint-disable-next-line @typescript-eslint/no-misused-promises
this.showDetailsTimeout = setTimeout(async () => { this.showDetailsTimeout = setTimeout(async () => {

Loading…
Cancel
Save