New TV Mode, dashboard toolbar update (layout change & new cycle view mode button) (#13025)

* wip: design update for navbar with kiosk mode button

* feat: progress on new view mode button

* css: view state refactorings

* feat: kiosk modes & playlist support

* feature: cycle tv mode feature, renamed view modes to TV, and Kiosk

* fix: updated the alert notification message

* fix: removed unused parameter

* fix: correct the css class set for tv mode

* some minor improvements to playlist
This commit is contained in:
Torkel Ödegaard
2018-08-30 11:52:31 +02:00
committed by GitHub
parent 36bc8b77fb
commit 154fbe2413
18 changed files with 279 additions and 286 deletions

View File

@@ -842,12 +842,20 @@ export class DashboardModel {
})
);
// Consider navbar and submenu controls, padding and margin
let visibleHeight = window.innerHeight - 55 - 20;
const navbarHeight = 55;
const margin = 20;
const submenuHeight = 50;
// Remove submenu if visible
if (this.meta.submenuEnabled) {
visibleHeight -= 50;
let visibleHeight = viewHeight - navbarHeight - margin;
// Remove submenu height if visible
if (this.meta.submenuEnabled && !this.meta.kiosk) {
visibleHeight -= submenuHeight;
}
// add back navbar height
if (this.meta.kiosk === 'b') {
visibleHeight += 55;
}
const visibleGridHeight = Math.floor(visibleHeight / (GRID_CELL_HEIGHT + GRID_CELL_VMARGIN));