@netless/telebox-insider 0.2.31 → 0.2.32-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -2381,12 +2381,15 @@ class MaxTitleBar extends DefaultTitleBar {
|
|
|
2381
2381
|
}
|
|
2382
2382
|
setBoxes(boxes) {
|
|
2383
2383
|
this.boxes = boxes;
|
|
2384
|
+
if (this.$titleBar) {
|
|
2385
|
+
this.$titleBar.classList.toggle(this.wrapClassName("max-titlebar-maximized"), this.state === TELE_BOX_STATE.Maximized && boxes.length > 0);
|
|
2386
|
+
}
|
|
2384
2387
|
this.updateTitles();
|
|
2385
2388
|
}
|
|
2386
2389
|
setState(state) {
|
|
2387
2390
|
super.setState(state);
|
|
2388
2391
|
if (this.$titleBar) {
|
|
2389
|
-
this.$titleBar.classList.toggle(this.wrapClassName("max-titlebar-maximized"), state === TELE_BOX_STATE.Maximized);
|
|
2392
|
+
this.$titleBar.classList.toggle(this.wrapClassName("max-titlebar-maximized"), state === TELE_BOX_STATE.Maximized && this.boxes.length > 0);
|
|
2390
2393
|
}
|
|
2391
2394
|
this.updateTitles();
|
|
2392
2395
|
}
|
|
@@ -2411,7 +2414,7 @@ class MaxTitleBar extends DefaultTitleBar {
|
|
|
2411
2414
|
$titleBar.style.transform = `translate(${x}px, ${y}px)`;
|
|
2412
2415
|
$titleBar.style.width = width + "px";
|
|
2413
2416
|
$titleBar.classList.add(this.wrapClassName("max-titlebar"));
|
|
2414
|
-
$titleBar.classList.toggle(this.wrapClassName("max-titlebar-maximized"), this.state === TELE_BOX_STATE.Maximized);
|
|
2417
|
+
$titleBar.classList.toggle(this.wrapClassName("max-titlebar-maximized"), this.state === TELE_BOX_STATE.Maximized && this.boxes.length > 0);
|
|
2415
2418
|
$titleBar.classList.toggle(this.wrapClassName("readonly"), this.readonly);
|
|
2416
2419
|
$titleBar.classList.add(this.wrapClassName(this.darkMode ? "color-scheme-dark" : "color-scheme-light"));
|
|
2417
2420
|
const $titlesArea = document.createElement("div");
|