Skip to content
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

inconsistent validation of svg #82

Open
btrem opened this issue Jan 9, 2024 · 0 comments
Open

inconsistent validation of svg #82

btrem opened this issue Jan 9, 2024 · 0 comments

Comments

@btrem
Copy link

btrem commented Jan 9, 2024

Using the direct input validation form, this snippet

<?xml version="1.0" encoding="UTF-8"?>
<svg xmlns="http://www.w3.org/2000/svg">
    <linearGradient id="a">
        <stop stop-color="#0f0"/>
        <stop offset="1" stop-color="#00f"/>
    </linearGradient>
    <rect width="300" height="300" fill="url(#a)" />
</svg>

is validated as xml and passes. But the same extract, when saved as a file and submitted to the validation service via file upload, is validated as SVG 1.1 + URL + HTML + MathML 3.0, and produces a missing attribute error. The same happens if the document is validated via uri: it is validated as SVG 1.1 and produces an error.

I discovered this when a PR in another repo failed an automatic test because validation of an svg file failed. But I couldn't figure out what was wrong because the direct input method did not show any problem.

Is this a limitation of the direct input validation?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant