consul/ui-v2/app/styles/components/toggle/layout.scss

34 lines
476 B
SCSS

%toggle {
position: relative;
}
%toggle input {
display: none;
}
%toggle span {
display: inline-block;
padding-left: 25px;
}
%toggle span::before,
%toggle span::after {
position: absolute;
display: block;
content: '';
top: 50%;
}
%toggle span::before {
left: 0px;
width: 20px;
height: 12px;
margin-top: -8px;
}
%toggle span::after {
left: 2px;
margin-top: -6px;
width: 8px;
height: 8px;
}
%toggle input:checked + span::after {
left: 10px;
}