Improved accessibility of material-design checkbox

This commit is contained in:
the-djmaze 2023-01-30 10:09:52 +01:00
parent e148cdea75
commit d0376b53a8
5 changed files with 16 additions and 8 deletions

View file

@ -57,7 +57,12 @@
margin-bottom: 6px;
padding: 2px 0;
&:focus {
input {
opacity:0;
position:absolute;
}
&:focus-within {
outline: 1px dotted;
}
@ -70,6 +75,7 @@
.e-checkbox.material-design {
line-height: 20px;
width: auto !important;
> div {
position: relative;
@ -85,7 +91,7 @@
animation: checkmark-to-box 200ms ease-out forwards;
}
div.checked {
input:checked + div div {
.checkbox-mark-sizes();
animation: box-to-checkmark 200ms ease-out forwards;
}