19
loading...
This website collects cookies to deliver better user experience
rtl
or ltr
??: stop thinking about that. We no more have a straight direction but a circular one. Do we have direction with clocks? no we don't! Same thing here, it's a universal circular direction.grid-area:1/1
, I can have all the elements above each other without the need of using position:absolute
width:100%;height:100%
to the inputs so they cover the whole area and I make them invisible (but still interactive)<i>
element and clip-path
. That shape will have 3 background layersconic-gradient
with a 72deg
step (360deg/5
) controlled with the variable --p
.--l
. Yes, this one will respond to the hover effect..stars input:nth-of-type(2) {transform:rotate(72deg)}
.stars input:nth-of-type(3) {transform:rotate(144deg)}
.stars input:nth-of-type(4) {transform:rotate(216deg)}
.stars input:nth-of-type(5) {transform:rotate(288deg)}
:hover
or :checked
I change the variables I described previously and we have our ONE star rating.