demarches-normaliennes/app/assets/stylesheets/new_design/forms.scss
2017-09-06 11:11:29 +02:00

117 lines
2.2 KiB
SCSS

@import "constants";
@import "colors";
.form {
overflow: hidden;
h1 {
text-align: center;
margin-bottom: 20px;
}
label {
margin-bottom: $default-spacer;
display: inline-block;
}
input[type=text],
input[type=email],
input[type=password],
input[type=date],
input[type=number],
input[type=tel],
textarea,
select {
display: block;
border-radius: 4px;
border: solid 1px $border-grey;
margin-bottom: 2 * $default-padding;
padding: $default-padding;
&:disabled {
background-color: $border-grey;
}
}
input[type=text],
input[type=email],
input[type=password],
input[type=date],
input[type=number],
input[type=tel],
textarea {
width: 100%;
}
input[type=email],
input[type=number],
input[type=tel], {
max-width: 500px;
}
input[type=checkbox],
input[type=radio] {
margin-bottom: 2 * $default-padding;
}
input[type=date] {
max-width: 180px;
}
select {
// hack found here: https://stackoverflow.com/questions/1895476/how-to-style-a-select-dropdown-with-css-only-without-javascript
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
background: image-url("icons/chevron-down.svg") no-repeat;
background-size: 14px;
background-position: right 10px center;
padding-right: 3 * $default-spacer;
// CAUTION: IE hackery ahead
&::-ms-expand {
display: none; // remove default arrow in IE 10 and 11 */
}
// target Internet Explorer 9 to undo the custom arrow */
@media screen and (min-width:0\0) {
select {
background: none\9;
}
}
}
.datetime {
input[type=date] {
display: inline-block;
}
select {
display: inline-block;
}
}
.header-section {
color: #4393F3;
font-weight: bold;
font-size: 20px;
margin-bottom: 2 * $default-padding;
}
.explication-libelle {
font-weight: bold;
font-size: 20px;
margin-bottom: $default-padding;
}
.explication {
background-color: $light-grey;
padding: $default-padding;
margin-bottom: 2 * $default-padding;
}
.send {
float: right;
margin-bottom: $default-padding;
}
}