gestiojeux/mainsite/scss/forms.scss
Guillaume Bertholon ccd8ee9cc9 Add game comments and rework game models
Models are now more structured for number of players, and durations can
be omitted.
2020-12-13 00:12:06 +01:00

133 lines
2.3 KiB
SCSS

form {
display: flex;
align-items: stretch;
flex-direction: column;
.errorlist {
list-style-type: none;
margin: 0;
padding: 0;
font-size: 0.7em;
li {
@include error_box;
margin-bottom: 10px;
}
}
p {
margin: 5px 0;
width: 100%;
}
}
.helptext {
font-size: 0.7em;
color: $help_text_color;
}
input, textarea {
display: block;
width: 100%;
font: inherit;
font-size: 0.9em;
color: black;
}
input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
textarea {
background-color: white;
border: solid 1px $help_text_color;
padding: 5px 10px;
border-radius: 5px;
box-shadow: none;
&:optional {
border-color: fade-out($help_text_color, .25);
}
&:focus {
border-color: $header_bg_color;
box-shadow: 0 0 1.5px 1px $header_bg_color;
}
&:-moz-ui-invalid {
border-color: $error_box_border_color;
box-shadow: 0 0 1.5px 1px $error_box_border_color;
}
}
textarea {
font-family: $font_family;
font-size: 1em;
resize: vertical;
min-height: 120px;
}
input[type="checkbox"],
input[type="radio"] {
width: auto;
margin: 5px 10px;
}
input[type="submit"] {
@include button;
}
select {
-webkit-appearance: none;
appearance: none;
@include button;
width: 100%;
font-size: 0.9em;
margin: 0;
padding: 5px 25px 5px 10px;
text-align: left;
&:-moz-focusring {
color: transparent;
text-shadow: 0 0 0 #000;
}
background-image: url('/static/img/select_arrow.svg');
background-repeat: no-repeat;
background-position: right .7em top 50%, 0 0;
background-size: .65em auto, 100%;
}
.formfield {
padding: 5px;
margin: 10px 0;
}
.error_field {
border-radius: 10px;
background-color: rgba($error_box_color, .4);
}
form.search {
flex-direction: row;
input[type="search"] {
border-radius: 5px 0 0 5px;
border-right: 0;
}
button {
margin: 0;
border-radius: 0 10px 10px 0;
}
}
form.comment {
font-size: 0.7em;
textarea {
border-radius: 10px 10px 0 0;
border-bottom: none;
margin: 0;
}
button {
border-radius: 0 0 10px 10px;
margin: 0;
}
}