mercredi 29 avril 2015

How does css checkbox hack work?

I just came across the switch toggle button which is created only using css. It known as the checkbox hack.

For those who doesn't know what a checkbox css hack is, Please read it here

http://ift.tt/1bUhgkY

I tried it out and it was working perfectly fine. But I didn't understand how this is working because we are not clicking on the checkbox.

So I have 2 questions

  1. How is this working ?

  2. Instead of absolute positioning I tried it with

    display: none;

It still worked. Does this method have any drawbacks?




Aucun commentaire:

Enregistrer un commentaire