Skip to content

SVG autofocus attribute: missing but widely available#41576

Merged
estelle merged 6 commits intomainfrom
svgautofocus
Oct 20, 2025
Merged

SVG autofocus attribute: missing but widely available#41576
estelle merged 6 commits intomainfrom
svgautofocus

Conversation

@estelle
Copy link
Copy Markdown
Member

@estelle estelle commented Oct 17, 2025

@estelle estelle requested a review from a team as a code owner October 17, 2025 12:29
@estelle estelle requested review from hamishwillee and removed request for a team October 17, 2025 12:29
@github-actions github-actions bot added Content:SVG SVG docs size/m [PR only] 51-500 LoC changed labels Oct 17, 2025
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Oct 17, 2025

Preview URLs

Flaws (12)

Note! 1 document with no flaws that don't need to be listed. 🎉

URL: /en-US/docs/Web/SVG/Reference/Attribute
Title: SVG Attribute reference
Flaw count: 12

  • macros:
    • Can't resolve /en-US/docs/Web/SVG/Reference/Attribute/hreflang
    • Can't resolve /en-US/docs/Web/SVG/Reference/Attribute/offset
    • Can't resolve /en-US/docs/Web/SVG/Reference/Attribute/ping
    • Can't resolve /en-US/docs/Web/SVG/Reference/Attribute/referrerPolicy
    • Can't resolve /en-US/docs/Web/SVG/Reference/Attribute/rel
    • and 7 more flaws omitted

(comment last updated: 2025-10-20 09:31:48)

Copy link
Copy Markdown
Member

@Josh-Cena Josh-Cena left a comment

Choose a reason for hiding this comment

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

Minor nits

Comment thread files/en-us/web/svg/reference/attribute/autofocus/index.md Outdated
Comment thread files/en-us/web/svg/reference/attribute/autofocus/index.md Outdated
Comment thread files/en-us/web/svg/reference/attribute/autofocus/index.md Outdated
> [!NOTE]
> The `autofocus` attribute has an HTML counterpart: [`autofocus`](/en-US/docs/Web/HTML/Reference/Global_attributes/autofocus)

## Usage notes
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Aside, but would be good to migrate section name "Usage notes" globally to "Description" to match Web APIs.

sidebar: svgref
---

The **`autofocus`** global SVG attribute defines a focusable element to be focused after it's connected to a document. The attribute has no effect if the element is not already focusable.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

What if this is applied to multiple elements?

Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
Comment thread files/en-us/web/svg/reference/attribute/autofocus/index.md Outdated
Comment thread files/en-us/web/svg/reference/attribute/autofocus/index.md Outdated
@estelle estelle merged commit f806e0f into main Oct 20, 2025
11 of 13 checks passed
@estelle estelle deleted the svgautofocus branch October 20, 2025 09:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Content:SVG SVG docs size/m [PR only] 51-500 LoC changed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants