Files
roll20-character-sheets-tester/Savage Worlds - Graph Paper/source/styles/_general.scss
T

697 lines
12 KiB
SCSS

// #############################################################################
// BASIC SETUP
// #############################################################################
*,
::before,
::after {
box-sizing: border-box;
}
p {
font-family: inherit;
font-size: inherit;
line-height: inherit;
margin: 0 0 8px 0;
}
ul {
list-style: none;
padding: 0;
margin: 0;
li b:first-child {
display: inline-block;
padding-right: 8px;
min-width: 96px;
}
}
textarea,
select,
button,
fieldset,
input,
option,
label {
display: flex;
background-color: transparent;
background-image: none;
font-family: inherit;
font-weight: 400;
text-decoration: none;
padding: 0;
margin: 0;
border: 0;
border-radius: 0;
outline: 0 !important;
min-width: 0;
box-shadow: none;
appearance: none;
-moz-appearance: none;
-webkit-appearance: none;
&::placeholder {
color: $c-text-gray;
}
}
button,
label,
input[type=checkbox],
input[type=radio] {
cursor: pointer;
}
button,
button > span {
&:hover,
&:hover > span {
color: $c-text-hover !important;
}
}
button[type=action] {
color: $c-text-light;
font-size: $fs-s;
font-weight: 500;
line-height: 1;
}
input[type=text]:not(.sheet-hex) {
background-color: transparent;
color: $c-text;
font-size: $fs-s;
line-height: 20px;
text-overflow: ellipsis;
&::placeholder {
font-size: $fs-xs;
line-height: 20px;
}
&:not(.sheet-align-left) {
text-align: center;
}
}
input[type=hidden] {
display: none;
}
textarea {
color: $c-text-light;
font-size: 9px;
line-height: 1.6;
width: 100%;
resize: none;
}
input[type=checkbox].sheet-checkbox {
background-color: $c-white;
border: 1px solid $c-text-lighter;
border-radius: 2px;
height: 10px;
width: 10px;
&::before {
content: '';
display: block;
border-radius: 1px;
margin: 1px 0 0 1px;
height: 6px;
width: 6px;
}
&:checked::before {
background-color: $c-text-lighter;
}
}
.sheet-wrapper {
text-align: center;
}
.sheet-body {
color: $c-text;
font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
font-size: $fs-s;
line-height: 1;
text-align: left;
background: {
image: linear-gradient(to right, #fbfbfb 1px, transparent 1px),
linear-gradient(to bottom, #fbfbfb 1px, transparent 1px);
size: 8px 8px;
position: -1px -1px;
}
padding-top: 8px;
margin: 0 auto;
-webkit-font-smoothing: antialiased;
text-rendering: optimizeLegibility;
> div {
margin: 0 auto;
}
~ rolltemplate {
display: none;
}
}
.sheet-variant-radio {
display: inline-block;
&::after {
content: '';
display: inline-block;
padding: 3px;
border: 1px solid $c-outline;
border-radius: 50%;
}
&:checked::after {
background-color: $c-outline;
}
&--wildcard:checked ~ .sheet-body {
width: 800px;
.sheet-extra {
display: none;
}
}
&--extra:checked ~ .sheet-body {
width: 474px;
.sheet-wildcard {
display: none;
}
}
}
.sheet-wildcard {
.sheet-section {
display: flex;
justify-content: space-between;
> .sheet-left {
display: flex;
flex-direction: column;
flex-shrink: 0;
width: 470px;
}
> .sheet-right {
flex-grow: 1;
}
}
}
// #############################################################################
// GENERICS & COMMON
// #############################################################################
.sheet-hidden {
display: none;
}
.sheet-block {
position: relative;
margin-top: 40px;
}
.sheet-header {
display: flex;
justify-content: space-between;
padding-bottom: 4px;
border-bottom: 1px dotted $c-outline;
height: 16px;
&__title {
display: block;
flex-grow: 1;
color: $c-text-light;
font-size: $fs-l;
font-weight: 700;
text-transform: uppercase;
}
&__labels {
display: flex;
align-items: flex-end;
line-height: 8px;
text-align: center;
text-transform: uppercase;
padding-right: 16px;
margin-bottom: -2px;
> span {
display: block;
}
}
}
.sheet-label,
.sheet-header__labels * {
color: $c-text-lightest;
font-size: $fs-xs;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.sheet-large-label {
color: $c-text-light;
font-size: $fs-l;
font-weight: 700;
text-transform: uppercase;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.sheet-footer {
color: $c-text-light;
line-height: 16px;
height: 16px;
}
.sheet-toggle {
&:not(:checked):not(.sheet-toggle--special) + *,
&:not(:checked):not(.sheet-toggle--special) ~ .repcontainer,
&:not(:checked):not(.sheet-toggle--special) ~ .repcontrol {
display: none;
}
&::after {
display: flex;
align-items: center;
justify-content: center;
color: $c-text-lighter;
line-height: 1;
width: 16px;
}
&:checked::after {
color: $c-text-light;
}
&--block {
display: none;
}
&--visibility {
position: absolute;
top: 4px;
right: 0;
&::after {
content: '`';
color: $c-text-gray;
font-size: $fs-s;
font-family: Pictos;
height: 10px;
}
&:checked::after {
color: $c-text-gray;
}
&:checked::after {
content: 'J';
}
}
&--arrow {
position: absolute;
right: 0;
top: 0;
&::after {
content: '►';
font-size: $fs-xs;
line-height: 20px;
height: 20px;
width: 20px;
transform-origin: 9px 10px;
transition: transform .3s ease-in-out;
}
&:checked::after {
transform: rotate(90deg);
}
}
&--settings,
&--note-box,
&--loss {
&::after {
color: $c-text-lightest;
font-family: Pictos;
font-size: $fs-s;
padding-top: 1px;
width: 10px;
}
}
&--settings {
&::after {
content: 'y';
}
}
&--note-box {
&::after {
content: 'n';
}
}
&--loss {
&::after {
content: 'Q';
}
}
&--weight {
&::after {
content: 'V';
color: $c-text-lightest;
font-family: Pictos;
font-size: $fs-l;
padding-top: 1px;
width: 10px;
transform: rotateZ(-90deg) scaleX(0.75);
}
}
&--spoiler {
&::after {
content: '&';
color: $c-text-light;
font-family: Pictos;
font-size: 10px;
height: 100%;
}
&:checked::after {
content: '_';
}
}
&--list-roll {
&:not(:checked) ~ .sheet-repitem__skill-roll {
display: none;
}
}
}
.sheet-radio-track {
position: relative;
flex-shrink: 0;
background-color: $c-white;
box-shadow: $shadow;
&::before {
z-index: 1;
display: flex;
align-items: center;
justify-content: center;
color: $c-white;
font-size: 9px;
height: 100%;
width: 100%;
}
&::after {
content: '';
position: absolute;
top: 50%;
left: 50%;
display: block;
border-radius: inherit;
height: 0;
width: 0;
transform: translate(-50%, -50%);
transition: height .3s ease-in-out,
width .3s ease-in-out,
background-color .1s ease-in-out;
}
&:hover::after,
&:hover ~ .sheet-radio-track:not(:checked)::after {
background-color: $c-background-hover;
height: 60%;
width: 60%;
}
&:checked {
&::after,
~ .sheet-radio-track:not(:checked)::after {
background-color: $c-background-dark;
height: 100%;
width: 100%;
transition-duration: .1s;
}
}
}
.sheet-tooltip {
pointer-events: none;
position: absolute;
display: flex;
align-items: center;
background-color: $c-background-tooltip;
color: $c-white;
font-size: $fs-s;
line-height: 1;
padding: 2px 6px;
border-radius: 2px;
opacity: 0;
transition: opacity .3s ease-in-out;
span:not(:last-child) {
margin-right: 2px;
}
// Arrow
&::after {
content: '';
position: absolute;
height: 10px;
width: 10px;
}
&--left {
top: 50%;
left: -6px;
transform: translate(-100%, -50%);
&::after {
top: 50%;
right: -8px;
border: 5px solid transparent;
border-left-color: $c-background-tooltip;
transform: translateY(-50%);
}
}
&--top {
top: -6px;
left: 50%;
transform: translate(-50%, -100%);
&::after {
bottom: -8px;
left: 50%;
border: 5px solid transparent;
border-top-color: $c-background-tooltip;
transform: translateX(-50%);
}
}
}
.sheet-damage-roll-toggle {
&-label {
display: block;
line-height: 8px;
text-align: center;
padding-right: 10px;
input[type=checkbox]:checked ~ span {
color: $c-text-light;
font-weight: 500;
}
.sheet-icon {
display: inline-block;
font-family: Pictos;
font-size: $fs-s;
margin-right: 4px;
overflow: visible;
}
}
~ .repcontainer .sheet-damage-button-overlay {
position: relative;
button[type=roll] {
position: absolute;
top: 0;
left: 0;
z-index: -1;
display: block;
height: 100%;
width: 100%;
}
}
&:checked ~ .repcontainer .sheet-damage-button-overlay {
button[type=roll] {
z-index: 1;
}
input[type=text] {
position: relative;
z-index: 0;
font-weight: 500;
&:placeholder-shown {
z-index: 2; // Keeps empty input above button
}
}
}
}
.sheet-label-toggle {
user-select: none;
flex-shrink: 0;
width: auto;
input[type=text].sheet-label-toggle__input {
background-color: $c-white;
color: $c-text-light;
line-height: 14px;
border: 1px solid $c-background-dark;
border-width: 1px;
border-radius: 0 2px 2px 0;
padding: 0 4px;
margin-left: -2px;
height: 14px;
width: 96px;
&:first-child {
border-left-width: 2px;
}
&--tiny {
width: 32px;
}
&::placeholder{
line-height: 12px;
}
}
span {
display: block;
flex-shrink: 0;
background-color: $c-background-dark;
color: $c-white;
font-size: $fs-xs;
font-weight: 500;
line-height: 15px;
border-radius: 2px;
padding: 0 4px;
height: 14px;
}
&--full-row {
flex-basis: 100%;
input[type=text].sheet-label-toggle__input {
text-align: left;
width: 100%;
}
}
input[type=checkbox] {
display: none;
&:not(:checked) {
+ span {
background-color: $c-text-gray;
}
~ input[type=text].sheet-label-toggle__input {
color: $c-text-lightest;
border-color: $c-text-gray;
}
}
}
}
// #############################################################################
// SETTING TOGGLES
// #############################################################################
.sheet-toggle-roboto:checked ~ .sheet-body {
font-family: $f-roboto;
}
.sheet-toggle-dark-labels:checked ~ .sheet-body {
.sheet-header__labels *,
.sheet-label,
.sheet-hexfield__label {
color: $c-text-light !important;
}
}
.sheet-toggle-skill-die-numbers:not(:checked) ~ .sheet-body {
.sheet-radio-track::before {
display: none;
}
}
.sheet-toggle-corners:not(:checked) ~ .sheet-body {
:not(.sheet-icon):not(.sheet-color-cycle__radio) {
border-radius: 0 !important;
&::before,
&::after {
border-radius: 0 !important;
}
}
}
.sheet-toggle-transitions:not(:checked) ~ .sheet-body {
*,
::before,
::after {
transition-duration: 0s !important;
}
}
.sheet-toggle-delays:not(:checked) ~ .sheet-body {
*,
::before,
::after {
transition-delay: 0s !important;
}
}
.sheet-toggle-grid:not(:checked) ~ .sheet-body {
background: none;
}
.sheet-toggle-description-input:not(:checked) ~ .repcontainer {
.sheet-roll-description {
display: none;
}
}
.sheet-toggle-injection-input:not(:checked) ~ .repcontainer {
.sheet-roll-injection {
display: none;
}
}