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

Update Safari data for html.global_attributes.autofocus #23688

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

queengooborg
Copy link
Collaborator

This PR updates and corrects version values for Safari (Desktop and iOS/iPadOS) for the autofocus member of the global_attributes HTML feature. This fixes #23457, which contains the supporting evidence for this change.

This PR updates and corrects version values for Safari (Desktop and iOS/iPadOS) for the `autofocus` member of the `global_attributes` HTML feature. This fixes mdn#23457, which contains the supporting evidence for this change.
@queengooborg queengooborg added the data:html 📄 Compat data for HTML elements. https://developer.mozilla.org/docs/Web/HTML label Jul 7, 2024
Copy link
Member

@Elchi3 Elchi3 left a comment

Choose a reason for hiding this comment

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

So, this will move this feature from baseline high back to limited availability. I think that's correct based on:

There was WebKit/WebKit#2907 which maybe improved things a little? Unsure.

cc'ing @ddbeck and @foolip for thoughts as they authored web-platform-dx/web-features#838

@queengooborg
Copy link
Collaborator Author

Upon inspecting the bug and commit, and doing some manual testing, I can now confirm that the attribute is supported under specific conditions, rather than not being supported at all. I've updated the PR accordingly, and set a version number based on the date of the commit linked.

Copy link
Member

@Elchi3 Elchi3 left a comment

Choose a reason for hiding this comment

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

Thanks for adding the note. I wonder if we want partial_implementation here? Caniuse decided to go for entirely unsupported in iOS. I'm not sure how to judge this.

@queengooborg
Copy link
Collaborator Author

I was thinking about setting partial implementation, but I wasn't certain. Then again, this behavior is technically non-conforming to the spec, and our definition of partial_implementation is if "the implementation of the sub-feature deviates from the specification in a way that may cause significant compatibility problems", so...I guess we should?

@ddbeck
Copy link
Collaborator

ddbeck commented Jul 10, 2024

So, this will move this feature from baseline high back to limited availability. I think that's correct based on:

I think this is more serious than the PR suggests, even, and it's OK for it to un-Baseline the autofocus feature. It looks like there are two compat issues to report here in BCD:

  • autofocus: If there's no hardware keyboard connected, then the autofocus attribute has no effect (for example, the focus event doesn't fire and the element does not match the :focus selector).

    I think it'd be nice if the note mentioned an example of what "no effect" means. I don't think the on-screen keyboard not appearing is worthy of mention, since this doesn't seem to happen in Chrome or Firefox for Android, either (nor do I think we should endorse some web developers' expectation to have casual control over users' input devices, even virtualized ones).

  • focus(): If there's no hardware keyboard connected and the user has not yet interacted with the page, then calling focus() on an <input> element has no effect (for example, the element does not match the :focus selector).

    I'm not sure if this matters enough for a partial on focus(), but it's definitely noteworthy and deeply weird.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
data:html 📄 Compat data for HTML elements. https://developer.mozilla.org/docs/Web/HTML
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Autofocus is not supported on iOS Safari
3 participants