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

Document which (if any) svg attributes are disallowed #496

Closed
erikdahlstrom opened this issue Oct 7, 2015 · 7 comments
Closed

Document which (if any) svg attributes are disallowed #496

erikdahlstrom opened this issue Oct 7, 2015 · 7 comments

Comments

@erikdahlstrom
Copy link

https://github.com/ampproject/amphtml/blob/master/spec/amp-html-format.md#svg

Are there any svg attributes that are disallowed, or handled in a limited way (apart from the already listed "xlink:href")?

@Gregable
Copy link
Member

Gregable commented Oct 7, 2015

This is implemented as a white list, so essentially there are an infinite number of disallowed attributes. That said, there are definitely some that I can think of which we conceptually disallow:

  • Any attribute starting with 'on'
  • Any animation attributes (e.g. attributeType, begin, restart, keySplines, accumulate, etc)

Also xlink:href is allowed if the target starts with '#', so in other words is local to the document.

@erikdahlstrom
Copy link
Author

Is the white list of attributes too long to list in the docs? If not, please add the list to the docs, and otherwise consider adding a link to the complete set of allowed attributes.

@dvoytenko
Copy link
Contributor

No, not long. We'll do.

@dvoytenko
Copy link
Contributor

But my ideal solution would be to merge the validation rules into Github very soon and build docs based on them automatically. This way we'll have rules and docs sync'd 100%. So, I'd prioritize doing that.

@erikdahlstrom
Copy link
Author

Sounds good to me.

@cramforce
Copy link
Member

Is there anything to do here?

@Gregable
Copy link
Member

Nothing left to do here specific to the original issue. The validator is now available with all of the attribute lists in the spec file.

I think we can use Issue #994 to track auto-generated documentation.

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

No branches or pull requests

6 participants