Why does a rect require width and height attribute in Firefox?

前端 未结 2 1327
无人共我
无人共我 2021-01-22 17:59

In the following example I created a blinking eyes animation using CSS and an SVG: http://codepen.io/JamesTheHacker/pen/oLZVrY

It works fine in chrome, but on Firefox th

2条回答
  •  Happy的楠姐
    2021-01-22 18:38

    • In SVG 1.1 height and width are attributes i.e. you can't set the height and width via CSS.
    • In SVG 2 it is proposed width and height should be CSS properties.

    Only Chrome has so far implemented this part of the unfinished SVG 2 specification.

提交回复
热议问题