Files
hoppscotch/assets/css/styles.scss
liyasthomas b7ac58b31a 💄 Minor UI update
2019-09-13 23:17:34 +05:30

464 lines
6.3 KiB
SCSS

$responsiveWidth: 720px;
::selection {
background-color: var(--ac-color);
color: var(--act-color);
}
::-webkit-scrollbar {
width: 8px;
height: 8px;
}
::-webkit-scrollbar-thumb {
background-color: rgba(0, 0, 0, .5);
}
::-webkit-scrollbar-thumb:hover {
background-color: rgba(0, 0, 0, .6);
}
::placeholder {
color: var(--fg-color);
}
* {
box-sizing: border-box;
outline: 0;
border: 0;
}
a {
display: inline-flex;
color: inherit;
text-decoration: none;
font-weight: 700;
}
body {
background-color: var(--bg-color);
color: var(--fg-color);
font-weight: 500;
line-height: 1.5;
-webkit-tap-highlight-color: transparent;
-webkit-touch-callout: none;
user-select: none;
font-family: "Poppins", "Roboto", "Noto", sans-serif;
}
h1,
h2,
h3 {
margin: 0;
font-weight: 700;
}
h3.title {
margin: 4px;
}
header,
footer {
& > div {
display: flex;
padding: 16px;
width: 100%;
align-items: center;
justify-content: space-between;
}
}
nav {
a:not(:last-of-type) {
margin-right: 15px;
}
}
body.sticky-footer footer {
position: fixed;
right: 0;
bottom: 0;
left: 0;
}
.logo {
color: var(--ac-color);
}
button {
display: inline-flex;
align-items: center;
justify-content: center;
margin: 4px;
padding: 8px 16px;
border-radius: 4px;
background-color: var(--ac-color);
color: var(--act-color);
font-weight: 700;
font-size: 16px;
font-family: "Poppins", "Roboto", "Noto", sans-serif;
cursor: pointer;
transition: all 0.2s ease-in-out;
fill: var(--act-color);
span {
display: inline-flex;
margin-left: 8px;
}
&.icon {
background-color: var(--bg-color);
color: var(--ac-color);
fill: var(--ac-color);
}
&:not([disabled]):hover,
&:not(.disabled):focus {
background-color: var(--bg-color);
box-shadow: inset 0 0 0 2px var(--ac-color);
color: var(--ac-color);
fill: var(--ac-color);
}
}
fieldset {
margin: 16px 0;
border: 2px solid var(--fg-color);
border-radius: 4px;
}
legend {
color: var(--fg-color);
font-weight: 700;
cursor: pointer;
}
fieldset textarea,
fieldset pre
code {
resize: vertical;
}
fieldset.blue {
border-color: #57b5f9;
}
fieldset.blue legend {
color: #57b5f9;
}
fieldset.gray {
border-color: #BCC2CD;
}
fieldset.gray legend {
color: #BCC2CD;
}
fieldset.green {
border-color: #50fa7b;
}
fieldset.green legend {
color: #50fa7b;
}
fieldset.cyan {
border-color: #8be9fd;
}
fieldset.cyan legend {
color: #8be9fd;
}
fieldset.purple {
border-color: #bd93f9;
}
fieldset.purple legend {
color: #bd93f9;
}
fieldset.orange {
border-color: #ffb86c;
}
fieldset.orange legend {
color: #ffb86c;
}
fieldset.pink {
border-color: #ff79c6;
}
fieldset.pink legend {
color: #ff79c6;
}
fieldset.red {
border-color: #ff5555;
}
fieldset.red legend {
color: #ff5555;
}
fieldset.yellow {
border-color: #f1fa8c;
}
fieldset.yellow legend {
color: #f1fa8c;
}
.hidden {
display: none;
}
select,
input,
option,
textarea,
pre {
margin: 4px;
padding: 8px;
border-radius: 4px;
width: calc(100% - 8px);
background-color: var(--bg-dark-color);
color: var(--fg-color);
font-weight: 700;
font-size: 18px;
font-family: monospace;
transition: all 0.2s ease-in-out;
user-select: all;
&:not([readonly]):hover,
&:not([readonly]):focus {
background-color: var(--bg-color);
box-shadow: inset 0 0 0 2px var(--ac-color);
}
}
pre {
display: grid;
}
code {
height: 336px;
}
.hljs,
.hljs-subst {
background-color: var(--bg-dark-color) !important;
color: var(--fg-color) !important;
}
select,
input,
option {
height: 41px;
}
input[type="checkbox"] {
display: none;
&,
& + label {
vertical-align: middle;
cursor: pointer;
&:before {
content: "\2714";
border: 2px solid var(--fg-color);
border-radius: 4px;
display: inline-flex;
height: 16px;
width: 16px;
align-items: center;
justify-content: center;
margin: 8px 8px 8px 0;
color: transparent;
transition: .2s;
}
}
&:checked + label:before {
background-color: var(--ac-color);
border-color: var(--ac-color);
color: var(--act-color);
}
}
.error,
.disabled,
[disabled] {
background-color: var(--err-color);
color: #b2b2b2;
fill: #b2b2b2;
cursor: default;
&.icon {
color: #b2b2b2;
fill: #b2b2b2;
}
}
label {
padding: 4px;
}
ul,
ol {
display: flex;
margin: 4px 0 4px;
padding: 0;
list-style-type: none;
}
ul li,
ol li {
display: inline-flex;
flex-direction: column;
flex-grow: 1;
}
.flex-wrap {
display: flex;
justify-content: space-between;
align-items: center;
}
.show-on-small-screen {
display: flex;
}
@media (max-width: $responsiveWidth) {
header div {
display: flex;
text-align: center;
flex-direction: column;
nav {
display: inline-flex;
margin-top: 20px;
}
}
ul,
ol {
flex-direction: column;
}
ul li,
ol li {
display: flex;
}
.hide-on-small-screen {
display: none;
}
.show-on-small-screen {
display: inline-flex;
}
}
#installPWA {
display: none;
}
.info-response {
background-color: #FFEB3B;
}
.success-response {
background-color: #4BB543;
}
.redir-response {
background-color: #FF5722;
}
.cl-error-response {
background-color: #A63232;
}
.sv-error-response {
background-color: #B71C1C;
}
.missing-data-response {
background-color: var(--err-color);
}
.virtual-list::-webkit-scrollbar {
width: 0;
}
fieldset#history {
.method-list-item {
position: relative;
span {
position: absolute;
top: 44px;
right: 12px;
font-weight: 700;
font-family: monospace, monospace;
}
}
}
.align-left {
text-align: left;
}
.align-center {
text-align: center;
}
.align-right {
text-align: right;
}
#response-details-wrapper {
position: relative;
overflow: hidden;
border-radius: 4px;
textarea {
margin: 0;
width: 100%;
}
.covers-response {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
background-color: white;
height: 100%;
width: 100%;
}
}
#action {
#hidden-message {
display: none;
}
&.show {
display: flex;
position: fixed;
top: 16px;
right: 16px;
z-index: 1;
#hidden-message {
display: block;
margin-left: 4px;
}
}
}