搜尋 Mozilla 技術支援網站

防止技術支援詐騙。我們絕對不會要求您撥打電話或發送簡訊,或是提供個人資訊。請用「回報濫用」功能回報可疑的行為。

Learn More

Svg path d doesn't work

  • 3 回覆
  • 1 有這個問題
  • 1 次檢視
  • 最近回覆由 A.Repnin

more options

<svg><g><path fill="red" d="M-17169009 -11080329L16366781 -11080329L16366781 22493289L-17169009 22493289z"></path></g></svg>

It works in Chrome 83.0.4103.116, but doesn't work in Firefox 78.0.1. Could you fix it in Firefox?

<svg><g><path fill="red" d="M-17169009 -11080329L16366781 -11080329L16366781 22493289L-17169009 22493289z"></path></g></svg> It works in Chrome 83.0.4103.116, but doesn't work in Firefox 78.0.1. Could you fix it in Firefox?

所有回覆 (4)

more options

Additional information: each number has 8 digits. If you remove last digit from each number then red box will be shown on the page.

由 A.Repnin 於 修改

more options

I'm pretty sure, that we're not going to be that out of scope.

What about:

<svg><g transform="translate(410000, -5700000)"><path fill="red" d="M-17169009 -11080329L16366781 -11080329L16366781 22493289L-17169009 22493289z"></path></g></svg>

more options

TyDraniu said

I'm pretty sure, that we're not going to be that out of scope. What about: <svg><g transform="translate(410000, -5700000)"><path fill="red" d="M-17169009 -11080329L16366781 -11080329L16366781 22493289L-17169009 22493289z"></path></g></svg>

Thank you for the answer. 1) Could you describe root of problem? Why my code didn't work without transform="translate(410000, -5700000)" ? 2) Why did you use 410000 and -5700000 values. How did you calculate them?

more options

Thank you for the answer. 1) Could you describe root of problem? Why my code didn't work without transform="translate(410000, -5700000)" ? 2) Why did you use 410000 and -5700000 values. How did you calculate them?

由 A.Repnin 於 修改