File: /var/www/design.system/src/molecules/Inputs/Radio/Radio.module.scss
.root {
position: relative;
display: flex;
flex-direction: column;
align-items: flex-start;
cursor: default;
&.disabled {
cursor: default;
pointer-events: none;
.wrapper {
&::before {
background-color: var(--backgroundDisabledPrimary);
}
}
.input:checked + .wrapper {
&::before {
background-color: var(--backgroundDisabledPrimary);
}
&::after {
background-color: var(--iconDisabledOnDisabledPrimary);
}
}
.label {
color: var(--textDisabledPrimary);
}
.description {
color: var(--textDisabledSecondary);
}
}
}
.input {
position: absolute;
opacity: 0;
left: 0;
top: 0;
margin: 0;
z-index: 1;
}
.wrapper {
width: max-content;
min-height: 22px;
display: flex;
position: relative;
padding-left: 28px;
z-index: 0;
&:hover {
&::before {
background-color: var(--backgroundBrandTertiaryHover);
}
}
&::before {
content: '';
position: absolute;
top: 3px;
left: 0;
width: 16px;
height: 16px;
background-color: var(--backgroundBrandTertiary);
border-radius: var(--radiusFull);
z-index: 0;
}
&::after {
content: '';
position: absolute;
top: 6px;
left: 3px;
width: 10px;
height: 10px;
background-color: var(--backgroundBrandPrimary);
border-radius: var(--radiusFull);
opacity: 0;
z-index: 1;
}
}
.input:checked + .wrapper {
&::before {
background-color: var(--backgroundBrandTertiary);
}
&::after {
opacity: 1;
}
&:hover {
&::before {
background-color: var(--backgroundBrandTertiaryHover);
}
&::after {
background-color: var(--backgroundBrandPrimaryHover);
}
}
}
.label {
color: var(--textDefaultPrimary);
}
.description {
padding-left: 28px;
color: var(--textDefaultSecondary);
}