resize tab

This commit is contained in:
open-trade
2022-01-03 16:31:13 +08:00
parent d6b56a2f35
commit b17bda9a55
2 changed files with 13 additions and 1 deletions

View File

@@ -278,4 +278,13 @@ class MultipleSessions: Reactor.Component {
handler.set_option('show-sessions-type', el.id || "");
this.stupidUpdate();
}
function onSize() {
var w = this.$(.sessions-bar).box(#width) - 220;
this.$(#sessions-type span).style.set{
"max-width": (w / 2) + "px",
};
}
}
view.on("size", function() { app.multipleSessions.onSize(); });