-
Notifications
You must be signed in to change notification settings - Fork 6k
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
[web] Don't add href="#"
to semantics links
#53395
Conversation
@@ -18,9 +18,8 @@ class Link extends PrimaryRoleManager { | |||
@override | |||
DomElement createElement() { | |||
final DomElement element = domDocument.createElement('a'); | |||
// TODO(chunhtai): Fill in the real link once the framework sends entire uri. | |||
// https://github.com/flutter/flutter/issues/102535. | |||
element.setAttribute('href', '#'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what will happen if there isn't a href?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When you click on it, the browser doesn't navigate. It's still announced as a link by VoiceOver.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
…150637) flutter/engine@dda82d9...33415c6 2024-06-21 skia-flutter-autoroll@skia.org Roll Dart SDK from 4483d67ba725 to fc1e5912fc94 (1 revision) (flutter/engine#53503) 2024-06-21 98614782+auto-submit[bot]@users.noreply.github.com Reverts "Fix focus management for text fields (#51009)" (flutter/engine#53502) 2024-06-21 skia-flutter-autoroll@skia.org Roll Dart SDK from 19d3e659f49a to 4483d67ba725 (2 revisions) (flutter/engine#53501) 2024-06-20 mdebbar@google.com [web] Add 'flt-semantics-identifier' attribute to semantics nodes (flutter/engine#53278) 2024-06-20 mdebbar@google.com [web] Don't add `href="#"` to semantics links (flutter/engine#53395) 2024-06-20 skia-flutter-autoroll@skia.org Roll Dart SDK from be6b533e07e7 to 19d3e659f49a (1 revision) (flutter/engine#53495) 2024-06-20 skia-flutter-autoroll@skia.org Roll Fuchsia Linux SDK from tD5pof7jVnbXPwP7l... to iU-B6rJxy0wUYSmmp... (flutter/engine#53493) Also rolling transitive DEPS: fuchsia/sdk/core/linux-amd64 from tD5pof7jVnbX to iU-B6rJxy0wU If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-engine-flutter-autoroll Please CC jsimmons@google.com,rmistry@google.com,zra@google.com on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
…lutter#150637) flutter/engine@dda82d9...33415c6 2024-06-21 skia-flutter-autoroll@skia.org Roll Dart SDK from 4483d67ba725 to fc1e5912fc94 (1 revision) (flutter/engine#53503) 2024-06-21 98614782+auto-submit[bot]@users.noreply.github.com Reverts "Fix focus management for text fields (flutter#51009)" (flutter/engine#53502) 2024-06-21 skia-flutter-autoroll@skia.org Roll Dart SDK from 19d3e659f49a to 4483d67ba725 (2 revisions) (flutter/engine#53501) 2024-06-20 mdebbar@google.com [web] Add 'flt-semantics-identifier' attribute to semantics nodes (flutter/engine#53278) 2024-06-20 mdebbar@google.com [web] Don't add `href="#"` to semantics links (flutter/engine#53395) 2024-06-20 skia-flutter-autoroll@skia.org Roll Dart SDK from be6b533e07e7 to 19d3e659f49a (1 revision) (flutter/engine#53495) 2024-06-20 skia-flutter-autoroll@skia.org Roll Fuchsia Linux SDK from tD5pof7jVnbXPwP7l... to iU-B6rJxy0wUYSmmp... (flutter/engine#53493) Also rolling transitive DEPS: fuchsia/sdk/core/linux-amd64 from tD5pof7jVnbX to iU-B6rJxy0wU If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-engine-flutter-autoroll Please CC jsimmons@google.com,rmistry@google.com,zra@google.com on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
This is a stopgap for issues like flutter/flutter#146291 until we land better link semantics (in flutter/flutter#150263 and flutter/packages#6711). For the time being, the
href="#"
isn't providing any extra value, and is causing the browser to navigate to to#
whenever the semantics link is clicked, which is undesirable.Fixes flutter/flutter#146291