[CA][ca.boohoo.com] The Address dropdown is not displayed and the autofill is not working for none of the fields after clearing the form once
Categories
(Toolkit :: Form Autofill, task)
Tracking
()
People
(Reporter: ailea, Assigned: enndeakin)
References
(Blocks 1 open bug, )
Details
(Whiteboard: [fxcm-addr-compatibility])
Attachments
(4 files)
Found in
- 118.0a1
Affected versions
- 118.0a1
Tested platforms
- Affected platforms: Windows 10
Preconditions
- browser.search.region = CA
- Have at least one Address already saved
Steps to reproduce
- Reach the Address form on https://ca.boohoo.com
- Click on any Address field and select any Address entry from the dropdown
- Click on any field and choose the Clear Form option
- Click on any Shipping Information section field
- Click on any Shipping section field
Expected result
- The address autofill dropdown should be displayed for all the eligible fields.
Actual result
- The address autofill dropdown is not displayed for none of the fields after step 3, after clearing the form. For the form section (Shipping Information), the dropdown is not displayed at all and for the second section (Shipping), the Clear Form dropdown is displayed even if the fields are already empty.
Regression range
- N/A
Aditional Notes
Assignee | ||
Comment 1•5 months ago
|
||
The issue here is that the page hides the address form elements when the form is cleared, however the autofill highlight state is only cleared in response to an input event. Because the form element is hidden, the event will not fire. We should instead be explicitly resetting the form highlight state when clearing a form field.
Assignee | ||
Updated•5 months ago
|
Assignee | ||
Updated•5 months ago
|
Updated•5 months ago
|
Assignee | ||
Updated•4 months ago
|
Assignee | ||
Comment 2•4 months ago
|
||
Resetting the state when the value is modified is bug 1359355.
Assignee | ||
Comment 3•4 months ago
|
||
The existing autofill state is set on the form element using nsIDOMWindowUtils::AddManuallyManagedState, but a separate map #filledStateByElement within FormAutofillHandler.sys.mjs is used to keep track of which elements are filled in. However, this relies on input events that don't fire when form elements are hidden. In addition, when a page modifies the form field value directly, the preview state can be modified but the #filledStateByElement map is not.
Instead, remove the extra map, and just use the form field's autofill state directly. The form field will take responsibility for removing the preview state when its value changes.
This behaviour applies to single field input elements and select elements.
Depends on D210999
Updated•4 months ago
|
Updated•4 months ago
|
Assignee | ||
Comment 4•4 months ago
|
||
Depends on D211000
Pushed by neil@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/ce62044e34cc allowing getting and modifying the autofill state directly within the input and select elements, and reset this state when its value changes, r=webidl,emilio https://hg.mozilla.org/integration/autoland/rev/c7c873318c54 set the autofill state directly on the input and select elements rather than using windowUtils and a separate hash that can be out of sync with each other, r=credential-management-reviewers,dimi https://hg.mozilla.org/integration/autoland/rev/8bb1cc02549c tests for when a form field is modified using script or by the user when it is autofilled, and additional tests for when the form fields are hidden and modified, r=credential-management-reviewers,dimi
Comment 6•4 months ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/ce62044e34cc
https://hg.mozilla.org/mozilla-central/rev/c7c873318c54
https://hg.mozilla.org/mozilla-central/rev/8bb1cc02549c
Updated•4 months ago
|
Reporter | ||
Comment 7•2 months ago
|
||
Verified - Fixed in Release 128, Beta 129.0b3 and Nightly 130.0a1 (2024-07-15).
Description
•