mirror of
https://github.com/zadam/trilium.git
synced 2025-11-05 12:55:55 +01:00
20 lines
458 B
JavaScript
20 lines
458 B
JavaScript
|
|
import FlexContainer from "../containers/flex_container.js";
|
||
|
|
|
||
|
|
export default class SidebarContainer extends FlexContainer {
|
||
|
|
|
||
|
|
constructor(screenName, direction) {
|
||
|
|
super(direction);
|
||
|
|
|
||
|
|
this.screenName = screenName;
|
||
|
|
}
|
||
|
|
|
||
|
|
activeScreenChangedEvent({activeScreen}) {
|
||
|
|
if (activeScreen === this.screenName) {
|
||
|
|
this.$widget.addClass('show');
|
||
|
|
} else {
|
||
|
|
this.$widget.removeClass('show');
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
}
|