SVG viewBox无法在Chrome中正常运行,但在Edge中

时间:2020-06-11 12:57:04

标签: html google-chrome svg

我正在使用SVG viewBox工作项目,这是一个html代码段。

<body>
  <svg width="960" height="960" viewBox="18897158,-480,960,960">
    <g>
      <circle cx="18897482" cy="-94" r="3" fill="#18ff00"></circle>
      <circle cx="18897837" cy="-102" r="3" fill="#18ff00"></circle>
      <line x1="18897482" y1="-94.00" x2="18897837" y2="-102" stroke-width="1" stroke="#18ff00">
      </line>
      <text x="18897660" y="-98" fill="#18ff00" dominant-baseline="middle"
        text-anchor="middle">0.00094mm</text>
    </g>
  </svg>
</body>

在Chrome中使用此html时,line元素无法正确显示,但可以在Edge中使用。我想知道这是Chrome中的错误吗?

0 个答案:

没有答案
相关问题