Intent to Ship: Support ping, hreflang, type and referrerPolicy for SVGAElement

28 views
Skip to first unread message

Divyansh Mangal

unread,
Nov 5, 2025, 4:39:58 AM (yesterday) Nov 5
to blink-dev
Contact emails
Specification
Summary
Adds support for ping, hreflang, type, and referrerPolicy attributes on SVGAElement, aligning its behavior with HTMLAnchorElement for consistent link handling across HTML and SVG.

Blink component
Web Feature ID
svg

Motivation
The SVGAElement interface in SVG 2.0 is evolving to align more closely with HTML anchor elements, now supporting attributes like ping, hreflang, type, and referrerPolicy. This promotes consistency across web technologies and gives developers more control over link behavior and metadata.

ping: Specifies URLs to be notified when a link is followed, enabling lightweight tracking and analytics without disrupting navigation.

hreflang: Indicates the language of the linked resource, improving accessibility and helping search engines serve localized content.

type: Declares the MIME type of the linked resource, allowing smarter handling and performance optimization.

referrerPolicy: Controls how much referrer info is sent when navigating. Policies like no-referrer or strict-origin-when-cross-origin enhance privacy and security.

These enhancements make SVG links more powerful, predictable, and aligned with modern web standards.

Initial public proposal
No information provided

TAG review
No information provided

TAG review status
Not applicable

Risks


Interoperability and Compatibility
Gecko only partially supports the ping attribute
Open bug for full implementation for ping attribute in Gecko: https://bugzilla.mozilla.org/show_bug.cgi?id=951104 
hreflang, type and referrerPolicy are fully supported.

WebKit: Neutral (https://github.com/WebKit/standards-positions/issues/566
WebKit has recently shipped hreflang and type attribute support for SVG <a> element

Web developers: No signals

Other signals: 10+ users have upvoted on the Chromium bug.

WebView application risks
Does this intent deprecate or change behavior of existing APIs, such that it has potentially high risk for Android WebView-based applications?
None


Debuggability
Attributes will be inspectable via DevTools Elements panel, consistent with HTML <a> element.

Will this feature be supported on all six Blink platforms (Windows, Mac, Linux, ChromeOS, Android, and Android WebView)?
Yes

Is this feature fully tested by web-platform-tests?
Yes

For ping:

for hreflang:

for type:

for referrerPolicy:
120 new WPTs tests are generated for checking the various cases of referrerPolicy, the tests have the pattern *referrer-policy/gen/*/svg-a-tag.http.html*
Flag name on about://flags
No information provided

Finch feature name
SvgAnchorElementAttributes

Rollout plan
Will ship enabled for all users

Requires code in //chrome?
False

Tracking bug
Estimated milestones
Shipping on desktop
144
Shipping on Android
144
Shipping on WebView
144


Anticipated spec changes
Open questions about a feature may be a source of future web compat or interop issues. Please list open issues (e.g. links to known github issues in the project for the feature specification) whose resolution may introduce web compat/interop risk (e.g., changing to naming or structure of the API in a non-backward-compatible way).
No information provided

Link to entry on the Chrome Platform Status
This intent message was generated by Chrome Platform Status.

Philip Jägenstedt

unread,
Nov 5, 2025, 5:41:22 AM (yesterday) Nov 5
to Divyansh Mangal, blink-dev
Hi Divyansh!

Thanks for working to align SVG and HTML <a> elements!

Can you confirm if https://svgwg.org/svg2-draft/linking.html#InterfaceSVGAElement really defines all of the behavior you'd like to ship here? In particular for ping and referrerPolicy, it's non-trivial, and the SVG spec itself doesn't seem to define anything beyond the IDL attribute reflection.

I think that updating https://html.spec.whatwg.org/#hyperlink-auditing and https://html.spec.whatwg.org/#following-hyperlinks to include SVG <a> or to somehow invoke HTML from the SVG spec would be enough. Unless this is already covered somewhere I'm not seeing, can you look into making the appropriate spec changes?

Best regards,
Philip

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/SEYP153MB1097BD3F67D4555910484B16ADC5A%40SEYP153MB1097.APCP153.PROD.OUTLOOK.COM.

Divyansh Mangal

unread,
12:38 AM (5 hours ago) 12:38 AM
to Philip Jägenstedt, blink-dev
Hi Philip, SVG2.0 does indeed defines these attributes by giving references of corresponding definitions of HTML <a> tag attributes.

For ping and referrerPolicy, we have the following, respectively:

Moreover, SVG2.0 says:
These attributes further describe the targetted resource and its relationship to the current document. Allowed values and meaning are as defined for the a element in HTML.

But let me know if these references are enough for defining the behaviour?

With Regards
Divyansh

From: Philip Jägenstedt <foo...@chromium.org>
Sent: 05 November 2025 16:10
To: Divyansh Mangal <dma...@microsoft.com>
Cc: blink-dev <blin...@chromium.org>
Subject: [EXTERNAL] Re: [blink-dev] Intent to Ship: Support ping, hreflang, type and referrerPolicy for SVGAElement
 

Philip Jägenstedt

unread,
4:15 AM (2 hours ago) 4:15 AM
to Divyansh Mangal, blink-dev
Hi Divyansh,

Thanks for the links, I think that the "meaning" in "allowed values and meaning" is supposed to imply that the same processing model and algorithm should be used. I do think it would be better if the SVG spec was more explicit, but that's practically an editorial concern.

If there is any difference at all between SVG <a> and HTML <a> in how these four attributes are handled I think that needs to be spec'd and tested, but if it's all the same then this seems straightforward.

LGTM1

Best regards,
Philip

Divyansh Mangal

unread,
4:43 AM (1 hour ago) 4:43 AM
to Philip Jägenstedt, blink-dev
Hi Philip, Thanks for the approval!

Providing inputs to your comments below:

> Thanks for the links, I think that the "meaning" in "allowed values and meaning" is supposed to imply that the same processing model and algorithm should be used. I do think it would be better if the SVG spec was more explicit, but that's practically an editorial concern.
    Got it, I see your point, I will raise this as an issue to update the spec for SVG <a> element so that the meaning is a little more clear in terms of processing model and algorithm as well.

> If there is any difference at all between SVG <a> and HTML <a> in how these four attributes are handled I think that needs to be spec'd and tested, but if it's all the same then this seems straightforward.
    And yes, attributes in HTML <a> and SVG <a> are expected to behave the same.

With Regards
Divyansh

From: Philip Jägenstedt <foo...@chromium.org>
Sent: 06 November 2025 14:45

To: Divyansh Mangal <dma...@microsoft.com>
Cc: blink-dev <blin...@chromium.org>
Subject: Re: [EXTERNAL] Re: [blink-dev] Intent to Ship: Support ping, hreflang, type and referrerPolicy for SVGAElement
 
Reply all
Reply to author
Forward
0 new messages