1
0
mirror of https://github.com/locomotivemtl/locomotive-boilerplate.git synced 2026-01-15 00:55:08 +08:00
Files
locomotive-boilerplate/project-x/assets/styles/src/base/_forms.scss
Antoine Boulanger 191aed5b5e Merge remote-tracking branch 'origin/master'
Conflicts:
	project-x/assets/styles/dist/main.css
	project-x/assets/styles/src/base/_forms.scss
2014-10-02 13:03:14 -04:00

93 lines
1.7 KiB
SCSS

/* ==========================================================================
Forms | http://codepen.io/AntoineBoulanger/pen/uBJmi
========================================================================== */
/* Input
========================================================================== */
.input {
background-color: #cccccc;
display: block;
width: 100%;
color: $black;
border: none;
border-radius: 0;
outline: none;
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
}
/* Select
========================================================================== */
// Wrapper
.select {
display: block;
position: relative;
// Select arrow
&:after {
content: "";
position: absolute;
top: 0;
right: 0;
width: 30px;
height: 100%;
display: block;
background-color: #ccc;
background-image: url('../../images/select-arrow.svg');
background-repeat: no-repeat;
background-position: center;
pointer-events: none;
}
}
// Select
.select__input {
@extend .input;
padding-right: 30px;
&::-ms-expand {
display: none;
}
}
/* Checkbox
========================================================================== */
// Wrapper
.checkbox {
display: inline-block;
}
// Real input hidden
.checkbox__input {
display: none;
&:checked {
+ .checkbox__check {
&:after {
visibility: visible;
}
}
}
}
// Fake input visible
.checkbox__check {
@extend .input;
display: inline-block;
width: 25px;
height: 25px;
&:after {
content: "";
display: block;
background-image: url('../../images/check.svg');
background-repeat: no-repeat;
background-position: center;
width: 25px;
height: 25px;
visibility: hidden;
}
}