Skip to content

Update Firefox data for api.SVGElement.load_event #26686

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

queengooborg
Copy link
Contributor

This PR updates and corrects version values for Firefox and Firefox Android for the load_event member of the SVGElement API. The alternative_name property was incorrectly used in this context.

This PR updates and corrects version values for Firefox and Firefox Android for the `load_event` member of the `SVGElement` API. The `alternative_name` property was incorrectly used in this context.
@queengooborg queengooborg added the data:api Compat data for Web APIs. https://developer.mozilla.org/docs/Web/API label May 1, 2025
@github-actions github-actions bot added the size:xs [PR only] 0-6 LoC changed label May 1, 2025
Copy link
Contributor

github-actions bot commented May 1, 2025

Tip: Review these changes grouped by change (recommended for most PRs), or grouped by feature (for large PRs).

Comment on lines +413 to +414
"partial_implementation": true,
"notes": "Firefox uses a non-standard `SVGLoad` event. See [bug 620002](https://bugzil.la/620002) for implementation status of the standard `load` event."
Copy link
Contributor

@caugner caugner May 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure about setting partial here. What is the impact of using the non-standard SVGLoad event?

The spec mentions:

In previous SVG specifications the load event was called SVGLoad and could be dispatched immediately after parsing an element but before the related resource(s) were fully loaded.

I could therefore imagine that Chrome and Safari also used this deprecated (?!) SVGLoad event.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking at the spec, I'm not seeing anything that stands out as notable about the SVGLoad event from a web developer perspective. Perhaps a note isn't even needed!

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Based on that paragraph and the load event description:

The load event is dispatched only to structurally external elements and to the Window, when the corresponding external resources have finished loading.

We could have a subfeature "Dispatches after external resources are loaded".

@queengooborg What do you think?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PS: I think the alternative_name is correct, as you need to do svg.addEventListener("SVGLoad", listener), see: https://github.com/search?q=%2FaddEventListener%5C%28%5B%22%27%5DSVGLoad%5B%22%27%5D%2F&type=code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
data:api Compat data for Web APIs. https://developer.mozilla.org/docs/Web/API size:xs [PR only] 0-6 LoC changed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants