[#181] set mobile and desktop UI on init and window resize without errors

This commit is contained in:
Robin Scholtes 2023-04-19 15:35:17 +12:00
parent f1340f1249
commit 6e4a813e1f
4 changed files with 51 additions and 20 deletions

View file

@ -28,6 +28,12 @@ class WindowWaiter {
*/
windowResize() {
debounce(this.app.adjustComponentSizes, 200, "windowResize", this.app, [])();
if ( window.innerWidth >= this.app.breakpoint ) {
this.app.resetLayout();
} else {
this.app.setMobileLayout();
}
}