New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SVG tags are case-sensitive, but yew lowercases them #2483
Comments
For the moment it seems I can work around it by creating the <@{"clipPath"} ...>...</@> |
Dynamic tags do not work in my case. I have installed Yew 0.19.3
Renders as:
Expected:
|
As mentioned in #1269, if you manually create a tag with |
Dynamic tags should now work. If you compile with nightly, a lint is added that reminds you that literal tags are "normalized" to lowercase and to use dynamic tags, i.e. |
Problem
SVG tags are case-sensitive, but yew lowercases them.
My particular issue is with
clipPath
- this is defined as an element with anid
, then referred to from CSS with a#
url back to the element. On FireFox at least, if theclipPath
node is insteadclippath
, the reference can't be resolved.Whatever I type in the
html!
macro, svgclipPath
elements are created asclippath
, and therefore cannot be referred to.This issue is alluded to in the comments of #1269 , and might affect the resolution of that issue.
Steps To Reproduce
Replace the default rendering in the basic template with the following:
Expected behavior
You should see a blue circle clipped by a rectangle (example from https://jenkov.com/tutorials/svg/clip-path.html & screenshot there). With yew in FireFox, you'll see nothing. You can comment the
style=
line to see the unclipped circle.Environment:
Questionnaire
The text was updated successfully, but these errors were encountered: