mirror of
https://github.com/gchq/CyberChef.git
synced 2025-05-09 07:45:00 -04:00
[#181] move stylesheets from layout to organised components/, leave overal structure in layout/_structure
This commit is contained in:
parent
4507d471bc
commit
b4c0378a01
19 changed files with 163 additions and 149 deletions
43
src/web/stylesheets/components/_banner.css
Normal file
43
src/web/stylesheets/components/_banner.css
Normal file
|
@ -0,0 +1,43 @@
|
|||
/**
|
||||
* Banner area styles
|
||||
*
|
||||
* @author n1474335 [n1474335@gmail.com]
|
||||
* @copyright Crown Copyright 2017
|
||||
* @license Apache-2.0
|
||||
*/
|
||||
|
||||
#banner {
|
||||
padding-left: 12px;
|
||||
padding-right: 4px;
|
||||
line-height: var(--banner-height);
|
||||
color: var(--banner-font-colour);
|
||||
background-color: var(--banner-bg-colour);
|
||||
border-bottom: 1px solid var(--primary-border-colour);
|
||||
justify-content: space-between; /* flex is applied through .row on the banner element */
|
||||
}
|
||||
|
||||
#banner i {
|
||||
vertical-align: middle;
|
||||
padding-right: 10px;
|
||||
}
|
||||
|
||||
.banner-link {
|
||||
color: var(--banner-url-colour);
|
||||
}
|
||||
|
||||
.banner-link:hover {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
@media only screen and (min-width: 768px){
|
||||
.banner-link:hover span {
|
||||
text-decoration: underline;
|
||||
}
|
||||
}
|
||||
|
||||
#notice-wrapper {
|
||||
text-align: center;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
57
src/web/stylesheets/components/_controls.css
Normal file
57
src/web/stylesheets/components/_controls.css
Normal file
|
@ -0,0 +1,57 @@
|
|||
/**
|
||||
* Controls area styles
|
||||
*
|
||||
* @author n1474335 [n1474335@gmail.com]
|
||||
* @copyright Crown Copyright 2017
|
||||
* @license Apache-2.0
|
||||
*/
|
||||
|
||||
#controls {
|
||||
padding: 10px 0;
|
||||
border-top: 1px solid var(--primary-border-colour);
|
||||
background-color: var(--secondary-background-colour);
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
#controls-content {
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-flow: row nowrap;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
#auto-bake-label {
|
||||
display: inline-block;
|
||||
width: 100px;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
text-align: center;
|
||||
color: var(--primary-font-colour);
|
||||
font-size: 14px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
#auto-bake-label .check,
|
||||
#auto-bake-label .check::before {
|
||||
border-color: var(--input-highlight-colour);
|
||||
color: var(--input-highlight-colour);
|
||||
}
|
||||
|
||||
#auto-bake-label .checkbox-decorator {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
#bake {
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
#controls .btn {
|
||||
border-radius: 30px;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.output-maximised .hide-on-maximised-output {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
|
110
src/web/stylesheets/components/_modals.css
Executable file
110
src/web/stylesheets/components/_modals.css
Executable file
|
@ -0,0 +1,110 @@
|
|||
/**
|
||||
* Modal layout styles
|
||||
*
|
||||
* @author n1474335 [n1474335@gmail.com]
|
||||
* @copyright Crown Copyright 2017
|
||||
* @license Apache-2.0
|
||||
*/
|
||||
|
||||
.modal-content {
|
||||
background-color: var(--primary-background-colour);
|
||||
}
|
||||
|
||||
.option-item {
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
#edit-favourites-list {
|
||||
margin: 10px;
|
||||
border: 1px solid var(--op-list-operation-border-colour);
|
||||
}
|
||||
|
||||
#edit-favourites-list .operation {
|
||||
border-left: none;
|
||||
border-right: none;
|
||||
}
|
||||
|
||||
#edit-favourites-list .operation:last-child {
|
||||
border-bottom: none;
|
||||
}
|
||||
|
||||
.about-img-left {
|
||||
float: left;
|
||||
margin: 10px 20px 20px 0;
|
||||
}
|
||||
|
||||
.about-img-right {
|
||||
float: right;
|
||||
margin: 10px 0 20px 20px;
|
||||
}
|
||||
|
||||
#save-link-group {
|
||||
padding-top: 0;
|
||||
}
|
||||
|
||||
.save-link-options {
|
||||
float: right;
|
||||
}
|
||||
|
||||
.save-link-options label {
|
||||
margin-left: 10px;
|
||||
}
|
||||
|
||||
#save-footer {
|
||||
border-top: none;
|
||||
margin-top: 0;
|
||||
border-bottom: 1px solid var(--primary-border-colour);
|
||||
}
|
||||
|
||||
#support-modal textarea {
|
||||
font-family: var(--primary-font-family);
|
||||
}
|
||||
|
||||
#save-texts textarea,
|
||||
#load-text {
|
||||
font-family: var(--fixed-width-font-family);
|
||||
}
|
||||
|
||||
#save-texts textarea {
|
||||
height: 200px;
|
||||
}
|
||||
|
||||
#faqs a.btn {
|
||||
text-transform: unset;
|
||||
}
|
||||
|
||||
#faqs > div {
|
||||
padding: 20px;
|
||||
border-left: 2px solid var(--primary-border-colour);
|
||||
}
|
||||
|
||||
.checkbox label input[type=checkbox]+.checkbox-decorator .check,
|
||||
.checkbox label input[type=checkbox]+.checkbox-decorator .check::before {
|
||||
border-color: var(--input-border-colour);
|
||||
color: var(--input-highlight-colour);
|
||||
}
|
||||
|
||||
.checkbox label input[type=checkbox]:checked+.checkbox-decorator .check,
|
||||
.checkbox label input[type=checkbox]:checked+.checkbox-decorator .check::before {
|
||||
border-color: var(--input-highlight-colour);
|
||||
color: var(--input-highlight-colour);
|
||||
}
|
||||
|
||||
.bmd-form-group.is-focused .option-item label {
|
||||
color: var(--input-highlight-colour);
|
||||
}
|
||||
|
||||
.bmd-form-group.is-focused [class^='bmd-label'],
|
||||
.bmd-form-group.is-focused [class*=' bmd-label'],
|
||||
.bmd-form-group.is-focused [class^='bmd-label'],
|
||||
.bmd-form-group.is-focused [class*=' bmd-label'],
|
||||
.bmd-form-group.is-focused label,
|
||||
.checkbox label:hover {
|
||||
color: var(--input-highlight-colour);
|
||||
}
|
||||
|
||||
.bmd-form-group.option-item label+.form-control{
|
||||
background-image:
|
||||
linear-gradient(to top, var(--input-highlight-colour) 2px, rgba(0, 0, 0, 0) 2px),
|
||||
linear-gradient(to top, var(--primary-border-colour) 1px, rgba(0, 0, 0, 0) 1px);
|
||||
}
|
24
src/web/stylesheets/components/_op-list.css
Executable file
24
src/web/stylesheets/components/_op-list.css
Executable file
|
@ -0,0 +1,24 @@
|
|||
/**
|
||||
* Operation list styles
|
||||
*
|
||||
* @author n1474335 [n1474335@gmail.com]
|
||||
* @copyright Crown Copyright 2017
|
||||
* @license Apache-2.0
|
||||
*/
|
||||
|
||||
.op-list {
|
||||
list-style-type: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.op-list .operation {
|
||||
color: var(--op-list-operation-font-colour);
|
||||
background-color: var(--op-list-operation-bg-colour);
|
||||
border-color: var(--op-list-operation-border-colour);
|
||||
}
|
||||
|
||||
.op-list .operation:hover {
|
||||
filter: brightness(98%);
|
||||
}
|
||||
|
|
@ -18,10 +18,6 @@
|
|||
border-right: none;
|
||||
}
|
||||
|
||||
#rec-list .operation {
|
||||
padding: 14px;
|
||||
}
|
||||
|
||||
.op-title {
|
||||
font-weight: var(--op-title-font-weight);
|
||||
}
|
||||
|
@ -321,6 +317,7 @@ input.toggle-string {
|
|||
background-color: var(--disabled-border-colour) !important;
|
||||
}
|
||||
|
||||
/*@TODO: move below block elsewhere, think of a better name*/
|
||||
/* Mobile UI for the dropdown operations search */
|
||||
.dropdown-operations {
|
||||
position: relative;
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
color: var(--title-colour);
|
||||
background-color: var(--title-background-colour);
|
||||
line-height: calc(var(--title-height) - 14px);
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.pane-controls {
|
||||
|
|
|
@ -1,9 +1,22 @@
|
|||
/**
|
||||
* Recipe area styles
|
||||
*
|
||||
* @author n1474335 [n1474335@gmail.com]
|
||||
* @copyright Crown Copyright 2017
|
||||
* @license Apache-2.0
|
||||
*/
|
||||
|
||||
#recipe {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
#rec-list {
|
||||
overflow-y: scroll;
|
||||
}
|
||||
|
||||
#rec-list .operation {
|
||||
color: var(--rec-list-operation-font-colour);
|
||||
background-color: var(--rec-list-operation-bg-colour);
|
||||
border-color: var(--rec-list-operation-border-colour);
|
||||
padding: 14px;
|
||||
}
|
||||
|
|
20
src/web/stylesheets/components/_scrollbar.css
Normal file
20
src/web/stylesheets/components/_scrollbar.css
Normal file
|
@ -0,0 +1,20 @@
|
|||
::-webkit-scrollbar {
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
}
|
||||
|
||||
::-webkit-scrollbar-track {
|
||||
background-color: var(--scrollbar-track);
|
||||
}
|
||||
|
||||
::-webkit-scrollbar-thumb {
|
||||
background-color: var(--scrollbar-thumb);
|
||||
}
|
||||
|
||||
::-webkit-scrollbar-thumb:hover {
|
||||
background-color: var(--scrollbar-hover);
|
||||
}
|
||||
|
||||
::-webkit-scrollbar-corner {
|
||||
background-color: var(--scrollbar-track);
|
||||
}
|
184
src/web/stylesheets/components/io/_io.css
Executable file
184
src/web/stylesheets/components/io/_io.css
Executable file
|
@ -0,0 +1,184 @@
|
|||
/**
|
||||
* Input/Output area styles
|
||||
*
|
||||
* @author n1474335 [n1474335@gmail.com]
|
||||
* @copyright Crown Copyright 2017
|
||||
* @license Apache-2.0
|
||||
*/
|
||||
|
||||
#input-text,
|
||||
#output-text {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
margin: 0;
|
||||
background-color: transparent;
|
||||
overflow: hidden;
|
||||
user-select: auto;
|
||||
}
|
||||
|
||||
/* To vertically align the title nicely in the center */
|
||||
label[for="input-text"],
|
||||
label[for="output-text"] {
|
||||
line-height: revert;
|
||||
}
|
||||
|
||||
#input .cm-scroller,
|
||||
#output .cm-scroller {
|
||||
overflow-y: scroll;
|
||||
}
|
||||
|
||||
#input .cm-scroller:hover,
|
||||
#output .cm-scroller:hover {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
#output-text.html-output .cm-content,
|
||||
#output-text.html-output .cm-line,
|
||||
#output-html {
|
||||
display: block;
|
||||
height: 100%;
|
||||
user-select: auto;
|
||||
}
|
||||
|
||||
#output-text.html-output .cm-line .cm-widgetBuffer,
|
||||
#output-text.html-output .cm-line>br {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.cm-editor {
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.cm-editor .cm-content {
|
||||
font-family: var(--fixed-width-font-family);
|
||||
font-size: var(--fixed-width-font-size);
|
||||
color: var(--fixed-width-font-colour);
|
||||
}
|
||||
|
||||
#input-wrapper,
|
||||
#output-wrapper {
|
||||
height: calc(100% - var(--title-height));
|
||||
}
|
||||
|
||||
#input-wrapper.show-tabs,
|
||||
#output-wrapper.show-tabs {
|
||||
height: calc(100% - var(--tab-height) - var(--title-height));
|
||||
}
|
||||
|
||||
#output-loader {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
margin: 0;
|
||||
background-color: var(--secondary-background-colour);
|
||||
opacity: 0;
|
||||
visibility: hidden;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
|
||||
transition: all 0.5s ease;
|
||||
}
|
||||
|
||||
#output-loader-animation {
|
||||
display: block;
|
||||
position: absolute;
|
||||
width: 60%;
|
||||
height: 60%;
|
||||
top: 10%;
|
||||
transition: all 0.5s ease;
|
||||
}
|
||||
|
||||
#output-loader .loading-msg {
|
||||
opacity: 1;
|
||||
font-family: var(--primary-font-family);
|
||||
line-height: var(--primary-line-height);
|
||||
color: var(--primary-font-colour);
|
||||
left: unset;
|
||||
top: 30%;
|
||||
position: relative;
|
||||
|
||||
transition: all 0.5s ease;
|
||||
}
|
||||
|
||||
.io-info {
|
||||
margin-right: 18px;
|
||||
margin-top: 1px;
|
||||
height: 30px;
|
||||
text-align: right;
|
||||
line-height: 12px;
|
||||
font-family: var(--fixed-width-font-family);
|
||||
font-weight: normal;
|
||||
font-size: 8pt;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.dropping-file {
|
||||
border: 5px dashed var(--drop-file-border-colour) !important;
|
||||
}
|
||||
|
||||
#input-find-options,
|
||||
#output-find-options {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
flex-wrap: wrap;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
#input-tab-body .form-group.input-group,
|
||||
#output-tab-body .form-group.input-group {
|
||||
width: 70%;
|
||||
float: left;
|
||||
margin-bottom: 2rem;
|
||||
}
|
||||
|
||||
.input-find-option .toggle-string {
|
||||
width: 70%;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.input-find-option-append button {
|
||||
border-top-right-radius: 4px;
|
||||
background-color: var(--arg-background) !important;
|
||||
margin: unset;
|
||||
}
|
||||
|
||||
.input-find-option-append button:hover {
|
||||
filter: brightness(97%);
|
||||
}
|
||||
|
||||
.form-group.output-find-option {
|
||||
width: 70%;
|
||||
float: left;
|
||||
}
|
||||
|
||||
#input-num-results-container,
|
||||
#output-num-results-container {
|
||||
width: 20%;
|
||||
float: right;
|
||||
margin: 0 0 0 10%;
|
||||
}
|
||||
|
||||
#input-find-options-checkboxes,
|
||||
#output-find-options-checkboxes {
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: auto;
|
||||
overflow-x: auto;
|
||||
overflow-y: hidden;
|
||||
text-align: center;
|
||||
width: fit-content;
|
||||
}
|
||||
|
||||
#input-find-options-checkboxes li,
|
||||
#output-find-options-checkboxes li {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
float: left;
|
||||
padding: 10px;
|
||||
text-align: center;
|
||||
}
|
|
@ -1,3 +1,5 @@
|
|||
/* Not to be confused with #search-results in Operations */
|
||||
|
||||
#input-search-results,
|
||||
#output-search-results {
|
||||
list-style: none;
|
||||
|
|
32
src/web/stylesheets/components/_list.css → src/web/stylesheets/components/operations/_categories.css
Executable file → Normal file
32
src/web/stylesheets/components/_list.css → src/web/stylesheets/components/operations/_categories.css
Executable file → Normal file
|
@ -1,17 +1,3 @@
|
|||
/**
|
||||
* Operation list styles
|
||||
*
|
||||
* @author n1474335 [n1474335@gmail.com]
|
||||
* @copyright Crown Copyright 2017
|
||||
* @license Apache-2.0
|
||||
*/
|
||||
|
||||
.op-list {
|
||||
list-style-type: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.category-title {
|
||||
display: block;
|
||||
padding: 10px;
|
||||
|
@ -42,7 +28,6 @@
|
|||
border: none;
|
||||
}
|
||||
|
||||
#search-results,
|
||||
#categories {
|
||||
position: absolute;
|
||||
top: 40px; /* the height of the input[type="search"] with pos relative */
|
||||
|
@ -54,3 +39,20 @@
|
|||
border-bottom: 1px solid var(--primary-border-colour);
|
||||
z-index: 20; /* to dropdown on top of all the other elements */
|
||||
}
|
||||
|
||||
#categories a {
|
||||
color: var(--category-list-font-colour);
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
#categories a:hover {
|
||||
filter: brightness(98%);
|
||||
}
|
||||
|
||||
.favourites-hover {
|
||||
color: var(--rec-list-operation-font-colour);
|
||||
background-color: var(--rec-list-operation-bg-colour);
|
||||
border: 2px dashed var(--rec-list-operation-font-colour) !important;
|
||||
padding: 8px 8px 9px 8px;
|
||||
}
|
||||
|
19
src/web/stylesheets/components/operations/_search.css
Normal file
19
src/web/stylesheets/components/operations/_search.css
Normal file
|
@ -0,0 +1,19 @@
|
|||
#search {
|
||||
padding-left: 10px;
|
||||
padding-right: 10px;
|
||||
background-image:
|
||||
linear-gradient(to top, var(--input-highlight-colour) 2px, rgba(0, 0, 0, 0) 2px),
|
||||
linear-gradient(to top, var(--primary-border-colour) 1px, rgba(0, 0, 0, 0) 1px);
|
||||
}
|
||||
|
||||
#search-results {
|
||||
position: absolute;
|
||||
top: 40px; /* the height of the input[type="search"] with pos relative */
|
||||
left: 0;
|
||||
right: 0;
|
||||
height: auto;
|
||||
max-height: 60vh;
|
||||
overflow: scroll;
|
||||
border-bottom: 1px solid var(--primary-border-colour);
|
||||
z-index: 20; /* to dropdown on top of all the other elements */
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue