Change tab element height using stylesheet.
Debounce bake button function changes.
This commit is contained in:
parent
a7eefa88fa
commit
6d95cb01c8
@ -27,7 +27,6 @@
|
||||
#output-wrapper{
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
height: calc(100% - var(--title-height));
|
||||
}
|
||||
|
||||
#output-wrapper .textarea-wrapper {
|
||||
@ -154,9 +153,26 @@
|
||||
width: fit-content;
|
||||
}
|
||||
|
||||
#input-wrapper,
|
||||
#output-wrapper,
|
||||
#input-wrapper > * ,
|
||||
#output-wrapper > .textarea-wrapper > #output-loader {
|
||||
height: calc(100% - var(--title-height));
|
||||
}
|
||||
|
||||
#input-wrapper.show-tabs,
|
||||
#input-wrapper.show-tabs > *,
|
||||
#output-wrapper.show-tabs,
|
||||
#output-wrapper > .textarea-wrapper > #output-loader {
|
||||
height: calc(100% - var(--tab-height) - var(--title-height));
|
||||
}
|
||||
|
||||
#output-wrapper > .textarea-wrapper > * {
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.input-wrapper.textarea-wrapper {
|
||||
width: 100%;
|
||||
height: calc(100% - var(--title-height));
|
||||
box-sizing: border-box;
|
||||
overflow: hidden;
|
||||
pointer-events: auto;
|
||||
@ -175,7 +191,6 @@
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
width: 100%;
|
||||
height: calc(100% - var(--title-height));
|
||||
padding: 3px;
|
||||
margin: 0;
|
||||
overflow: hidden;
|
||||
@ -193,7 +208,6 @@
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: calc(100% - var(--title-height));
|
||||
margin: 0;
|
||||
background-color: var(--primary-background-colour);
|
||||
visibility: hidden;
|
||||
@ -232,7 +246,6 @@
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
width: 100%;
|
||||
height: calc(100% - var(--title-height));
|
||||
display: none;
|
||||
}
|
||||
|
||||
|
@ -314,7 +314,7 @@ class InputWaiter {
|
||||
*/
|
||||
bakeAll() {
|
||||
this.app.progress = 0;
|
||||
this.manager.controls.toggleBakeButtonFunction("loading");
|
||||
this.app.debounce(this.manager.controls.toggleBakeButtonFunction, 20, "toggleBakeButton", this, ["loading"]);
|
||||
this.inputWorker.postMessage({
|
||||
action: "bakeAll"
|
||||
});
|
||||
|
@ -209,15 +209,8 @@ class TabWaiter {
|
||||
document.getElementById("input-tabs-wrapper").style.display = "block";
|
||||
document.getElementById("output-tabs-wrapper").style.display = "block";
|
||||
|
||||
document.getElementById("input-wrapper").style.height = "calc(100% - var(--tab-height) - var(--title-height))";
|
||||
document.getElementById("input-highlighter").style.height = "calc(100% - var(--tab-height) - var(--title-height))";
|
||||
document.getElementById("input-file").style.height = "calc(100% - var(--tab-height) - var(--title-height))";
|
||||
|
||||
document.getElementById("output-wrapper").style.height = "calc(100% - var(--tab-height) - var(--title-height))";
|
||||
document.getElementById("output-highlighter").style.height = "calc(100% - var(--tab-height) - var(--title-height))";
|
||||
document.getElementById("output-file").style.height = "calc(100% - var(--tab-height) - var(--title-height))";
|
||||
document.getElementById("output-loader").style.height = "calc(100% - var(--tab-height) - var(--title-height))";
|
||||
document.getElementById("show-file-overlay").style.top = "calc(var(--tab-height) + var(--title-height) + 10px)";
|
||||
document.getElementById("input-wrapper").classList.add("show-tabs");
|
||||
document.getElementById("output-wrapper").classList.add("show-tabs");
|
||||
|
||||
document.getElementById("save-all-to-file").style.display = "inline-block";
|
||||
}
|
||||
@ -229,15 +222,8 @@ class TabWaiter {
|
||||
document.getElementById("input-tabs-wrapper").style.display = "none";
|
||||
document.getElementById("output-tabs-wrapper").style.display = "none";
|
||||
|
||||
document.getElementById("input-wrapper").style.height = "calc(100% - var(--title-height))";
|
||||
document.getElementById("input-highlighter").style.height = "calc(100% - var(--title-height))";
|
||||
document.getElementById("input-file").style.height = "calc(100% - var(--title-height))";
|
||||
|
||||
document.getElementById("output-wrapper").style.height = "calc(100% - var(--title-height))";
|
||||
document.getElementById("output-highlighter").style.height = "calc(100% - var(--title-height))";
|
||||
document.getElementById("output-file").style.height = "calc(100% - var(--title-height))";
|
||||
document.getElementById("output-loader").style.height = "calc(100% - var(--title-height))";
|
||||
document.getElementById("show-file-overlay").style.top = "calc(var(--title-height) + 10px)";
|
||||
document.getElementById("input-wrapper").classList.remove("show-tabs");
|
||||
document.getElementById("output-wrapper").classList.remove("show-tabs");
|
||||
|
||||
document.getElementById("save-all-to-file").style.display = "none";
|
||||
}
|
||||
|
@ -281,7 +281,7 @@ class WorkerWaiter {
|
||||
*/
|
||||
setBakingStatus(bakingStatus) {
|
||||
this.app.baking = bakingStatus;
|
||||
this.manager.controls.toggleBakeButtonFunction(bakingStatus ? "cancel" : "bake");
|
||||
this.app.debounce(this.manager.controls.toggleBakeButtonFunction, 20, "toggleBakeButton", this, [bakingStatus ? "cancel" : "bake"])();
|
||||
|
||||
if (bakingStatus) this.manager.output.hideMagicButton();
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user