mirror of
https://github.com/wekan/wekan.git
synced 2025-12-27 20:58:48 +01:00
add: support compact mode for mobile web, auto adapt to small screen/window
This commit is contained in:
parent
0954cff5b4
commit
354eff9f7b
23 changed files with 436 additions and 131 deletions
|
|
@ -18,7 +18,8 @@ BlazeComponent.extendComponent({
|
|||
},
|
||||
|
||||
onCreated() {
|
||||
this._isOpen = new ReactiveVar(!Session.get('currentCard'));
|
||||
const initOpen = Utils.isMiniScreen() ? false : (!Session.get('currentCard'));
|
||||
this._isOpen = new ReactiveVar(initOpen);
|
||||
this._view = new ReactiveVar(defaultView);
|
||||
Sidebar = this;
|
||||
},
|
||||
|
|
@ -96,6 +97,7 @@ BlazeComponent.extendComponent({
|
|||
// XXX Hacky, we need some kind of `super`
|
||||
const mixinEvents = this.getMixin(Mixins.InfiniteScrolling).events();
|
||||
return [...mixinEvents, {
|
||||
'click .js-hide-sidebar': this.hide,
|
||||
'click .js-toggle-sidebar': this.toggle,
|
||||
'click .js-back-home': this.setView,
|
||||
}];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue