Create CSS to enlarge checkboxes

后端 未结 9 1052
萌比男神i
萌比男神i 2020-12-29 22:12

I am trying to double the size of my checkboxes on a few pages. How do I make that happen in CSS? I don\'t want to style the hover.

Ideas?

9条回答
  •  谎友^
    谎友^ (楼主)
    2020-12-29 22:30

    To double the size of checkboxes, you can use the CSS scale property. The (2,2) means 2 times the width and 2 times the height of the original, but this will be quite large.

    input[type="checkbox"] {
      transform:scale(2, 2);
    }
    

    You can also use decimal values, for just slightly bigger checkboxes.

    input[type="checkbox"] {
          transform:scale(1.3, 1.3);
        }
    

提交回复
热议问题