mirror of
https://github.com/fleetdm/fleet
synced 2026-05-04 13:59:01 +00:00
* update button to follow new style guide * update button styles for inverted ghost buttons * update a color name to match new styleguide
56 lines
1.1 KiB
SCSS
56 lines
1.1 KiB
SCSS
// build with the help of this article, with some of our own modifications
|
|
// https://moderncss.dev/pure-css-custom-styled-radio-buttons/
|
|
|
|
.radio {
|
|
font-size: $x-small;
|
|
display: flex;
|
|
align-items: center;
|
|
|
|
&__input {
|
|
display: flex;
|
|
|
|
input {
|
|
opacity: 0;
|
|
width: 0;
|
|
height: 0;
|
|
position: absolute;
|
|
|
|
& + .radio__control::before {
|
|
position: absolute;
|
|
content: "";
|
|
width: 10px;
|
|
height: 10px;
|
|
box-shadow: inset 1em 1em $core-vibrant-blue;
|
|
background-color: $core-vibrant-blue;
|
|
border-radius: 50%;
|
|
top: 3px;
|
|
left: 3px;
|
|
transition: 180ms transform ease-in-out;
|
|
transform: scale(0);
|
|
}
|
|
|
|
&:checked + .radio__control::before {
|
|
transform: scale(1);
|
|
}
|
|
|
|
&:focus + .radio__control {
|
|
border-color: $core-vibrant-blue;
|
|
}
|
|
}
|
|
}
|
|
|
|
&__control {
|
|
position: relative;
|
|
display: flex;
|
|
width: 16px;
|
|
height: 16px;
|
|
border-radius: 50%;
|
|
border: 2px solid $ui-fleet-black-10;
|
|
transform: translateY(-0.05em);
|
|
}
|
|
|
|
&__label {
|
|
margin-left: $pad-small;
|
|
line-height: 1;
|
|
}
|
|
}
|