mirror of
https://github.com/gchq/CyberChef.git
synced 2025-04-20 23:06:16 -04:00
Improved Controls CSS
This commit is contained in:
parent
85ffe48743
commit
bc949b47d9
4 changed files with 17 additions and 12 deletions
|
@ -589,6 +589,7 @@ class App {
|
||||||
this.manager.recipe.adjustWidth();
|
this.manager.recipe.adjustWidth();
|
||||||
this.manager.input.calcMaxTabs();
|
this.manager.input.calcMaxTabs();
|
||||||
this.manager.output.calcMaxTabs();
|
this.manager.output.calcMaxTabs();
|
||||||
|
this.manager.controls.calcControlsHeight();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -6,27 +6,20 @@
|
||||||
* @license Apache-2.0
|
* @license Apache-2.0
|
||||||
*/
|
*/
|
||||||
|
|
||||||
:root {
|
|
||||||
--controls-height: 75px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#controls {
|
#controls {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: var(--controls-height);
|
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
padding: 0;
|
padding: 10px 0;
|
||||||
padding-top: 12px;
|
|
||||||
border-top: 1px solid var(--primary-border-colour);
|
border-top: 1px solid var(--primary-border-colour);
|
||||||
background-color: var(--secondary-background-colour);
|
background-color: var(--secondary-background-colour);
|
||||||
}
|
}
|
||||||
|
|
||||||
#controls-content {
|
#controls-content {
|
||||||
position: relative;
|
position: relative;
|
||||||
left: 50%;
|
display: flex;
|
||||||
top: 50%;
|
flex-flow: row nowrap;
|
||||||
transform: translate(-50%, -50%);
|
align-items: center;
|
||||||
transform-origin: center left;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#auto-bake-label {
|
#auto-bake-label {
|
||||||
|
@ -56,6 +49,7 @@
|
||||||
|
|
||||||
#controls .btn {
|
#controls .btn {
|
||||||
border-radius: 30px;
|
border-radius: 30px;
|
||||||
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.output-maximised .hide-on-maximised-output {
|
.output-maximised .hide-on-maximised-output {
|
||||||
|
|
|
@ -7,7 +7,6 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#rec-list {
|
#rec-list {
|
||||||
bottom: var(--controls-height);
|
|
||||||
overflow: auto;
|
overflow: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -410,6 +410,17 @@ ${navigator.userAgent}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Calculates the height of the controls area and adjusts the recipe
|
||||||
|
* height accordingly.
|
||||||
|
*/
|
||||||
|
calcControlsHeight() {
|
||||||
|
const controls = document.getElementById("controls"),
|
||||||
|
recList = document.getElementById("rec-list");
|
||||||
|
|
||||||
|
recList.style.bottom = controls.clientHeight + "px";
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export default ControlsWaiter;
|
export default ControlsWaiter;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue