mirror of
https://github.com/zadam/trilium.git
synced 2025-11-14 01:05:49 +01:00
launchbar WIP
This commit is contained in:
@@ -3,18 +3,17 @@ import BasicWidget from "./basic_widget.js";
|
||||
const TPL = `<div class="spacer"></div>`;
|
||||
|
||||
export default class SpacerWidget extends BasicWidget {
|
||||
constructor(baseSize = 0, growIndex = 1000, shrinkIndex = 1000) {
|
||||
constructor(baseSize = 0, growthFactor = 1000) {
|
||||
super();
|
||||
|
||||
this.baseSize = baseSize;
|
||||
this.growIndex = growIndex;
|
||||
this.shrinkIndex = shrinkIndex;
|
||||
this.growthFactor = growthFactor;
|
||||
}
|
||||
|
||||
doRender() {
|
||||
this.$widget = $(TPL);
|
||||
this.$widget.css("flex-basis", this.baseSize);
|
||||
this.$widget.css("flex-grow", this.growIndex);
|
||||
this.$widget.css("flex-shrink", this.shrinkIndex);
|
||||
this.$widget.css("flex-grow", this.growthFactor);
|
||||
this.$widget.css("flex-shrink", 1000);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user