1
0
mirror of https://github.com/BookStackApp/BookStack.git synced 2025-07-28 17:02:04 +03:00

Added tri-layout desktop sticky-scroll

This commit is contained in:
Dan Brown
2018-12-09 13:42:35 +00:00
parent e1474194db
commit 8fd8652bbf
3 changed files with 35 additions and 10 deletions

View File

@ -18,7 +18,9 @@ class TriLayout {
}
updateLayout() {
const newLayout = (window.innerWidth <= 1000) ? 'mobile' : 'desktop';
let newLayout = 'tablet';
if (window.innerWidth <= 1000) newLayout = 'mobile';
if (window.innerWidth >= 1400) newLayout = 'desktop';
if (newLayout === this.lastLayoutType) return;
if (this.onDestroy) {
@ -28,7 +30,7 @@ class TriLayout {
if (newLayout === 'desktop') {
this.setupDesktop();
} else {
} else if (newLayout === 'mobile') {
this.setupMobile();
}
@ -50,7 +52,7 @@ class TriLayout {
}
setupDesktop() {
// TODO
//
}
/**