Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Conversation

@htoor3
Copy link
Contributor

@htoor3 htoor3 commented May 23, 2023

Ordering of input elements inside of the DOM tree for autofill groups does not reflect the order of the form rendered on screen. This is causing some issues with password managers and autofill, specifically Bitwarden.

We are currently always appending the currently focused input element to the end of the form.

This leads to a tree that appears out of order:
Screenshot 2023-05-23 at 2 57 37 PM

This fix is tracking the position of where the focused input node should be inserted and inserting it there, rather than always at the end of the form. Once the tree is ordered correctly, Bitwarden's autofill logic works in Flutter forms.

Tree order after fix:
Screenshot 2023-05-23 at 6 01 05 PM

Fixes flutter/flutter#61301
Fixes flutter/flutter#68005

Pre-launch Checklist

  • I read the [Contributor Guide] and followed the process outlined there for submitting PRs.
  • I read the [Tree Hygiene] wiki page, which explains my responsibilities.
  • I read and followed the [Flutter Style Guide] and the [C++, Objective-C, Java style guides].
  • I listed at least one issue that this PR fixes in the description above.
  • I added new tests to check the change I am making or feature I am adding, or Hixie said the PR is test-exempt. See [testing the engine] for instructions on writing and running engine tests.
  • I updated/added relevant documentation (doc comments with ///).
  • I signed the [CLA].
  • All existing and new tests are passing.

@flutter-dashboard flutter-dashboard bot added the platform-web Code specifically for the web engine label May 23, 2023
@htoor3 htoor3 requested a review from mdebbar May 23, 2023 23:07
Copy link
Contributor

@mdebbar mdebbar left a comment

Choose a reason for hiding this comment

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

LGTM. Thanks for fixing this!

Once tests are added, please re-ping me for re-review.

@htoor3 htoor3 requested a review from mdebbar May 24, 2023 20:38
@htoor3 htoor3 marked this pull request as ready for review May 24, 2023 20:40
Copy link
Contributor

@mdebbar mdebbar left a comment

Choose a reason for hiding this comment

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

LGTM

@htoor3 htoor3 added the autosubmit Merge PR when tree becomes green via auto submit App label May 26, 2023
@auto-submit auto-submit bot merged commit 40df5ac into flutter:main May 26, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request May 26, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request May 26, 2023
auto-submit bot pushed a commit to flutter/flutter that referenced this pull request May 26, 2023
…127698)

flutter/engine@84f2fc1...ec7b0ae

2023-05-26 [email protected] Checkout android and emsdk deps in linux. (flutter/engine#42339)
2023-05-26 [email protected] [web] - Fix autofill group input ordering  (flutter/engine#42268)
2023-05-26 [email protected] Roll Skia from 1622df035714 to ac897edeb16a (1 revision) (flutter/engine#42348)

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 [email protected],[email protected],[email protected] 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://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
@JaredEzz
Copy link

Is there a good way to know when this would be rolled into stable or hotfixed? I tried to view on https://flutter-dashboard.appspot.com/#/build but it was a bit confusing

@willxie
Copy link

willxie commented Jun 29, 2023

Thanks for the fix.

Has this been reverted? It works in beta channel for 3.12.0 but not the current latest 3.12.0-1.1.pre

@JaredEzz
Copy link

JaredEzz commented Sep 6, 2023

Tested on stable 3.13 and bitwarden can autofill from the extension but no context menu shows up in the textfield

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

autosubmit Merge PR when tree becomes green via auto submit App platform-web Code specifically for the web engine

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[WEB] [Firefox] Autofill does not fill both login fields Autofill doesn't work with password managers on web

4 participants