[UK][next.co.uk] Cardholder Name is not autofilled due to site prefill
Categories
(Toolkit :: Form Autofill, defect, P2)
Tracking
()
People
(Reporter: tbabos, Assigned: tgiles)
References
(Blocks 3 open bugs, Regression, )
Details
Attachments
(4 files, 1 obsolete file)
Affected Versions:
- All latest Firefox versions using force enable (Nightly 86, Beta RC 85.0, Release 84.0.2)
Tested on:
- MacOS 10.15
- Windows 10 x64
Prerequisites:
- browser.search.region UK
- extensions.formautofill.supportedCountries UK
- download latest Firefox Nightly with region locale (switch extensions.formautofill.available to "on" for testing non-Nightly builds)
Steps to Reproduce:
- Launch Firefox
- Go to and reach the payment form next.co.uk
- Using autofill feature, fill in 1 saved CC entry - observe Bug 1
- Fill in manually new CC info and submit the form - observe Bug 2
Expected Results:
- Selecting a saved CC entry from the dropdown should will in all fields (even site prefilled ones)
- Submitting the form with new CC info should trigger the Credit Card save doorhanger
Actual Results:
- Bug 1: Cardholder name is not autofilled
- Bug 2: CC save doorhanger is not displayed upon form submission
Notes:
- Severity: S3 severity, due to lack of Save doorhanger
- Reproducible on Chrome?: No for both issues
- Regression-range: reproducible on all latest versions, this site was never tested before, can look for regression-range if need be
Comment 1•5 years ago
|
||
- issue with identifying a name field, or we ignore it due to prefilled text
| Assignee | ||
Comment 2•4 years ago
|
||
Renaming this bug as the CC save doorhanger not appearing is not due to the cardholder name issue in this bug.
| Assignee | ||
Comment 3•4 years ago
|
||
Since the cardholder name is filled by the site, we won't autofill the cardholder name because it already has a value. I'm not sure how we're going to handle this case without accidentally autofilling...as checking if the element has a value before filling is how we prevent manual entries from being overwritten since autocomplete and autofill both use this autofillFields function.
| Assignee | ||
Comment 4•4 years ago
|
||
Attaching a complete web page that reproduces the bug. Should make solving the bug a little quicker than having to create a test account on this site and all that.
| Assignee | ||
Updated•4 years ago
|
| Assignee | ||
Updated•4 years ago
|
| Assignee | ||
Comment 5•4 years ago
|
||
Enables autofilling into fields that may have been filled by the site.
Enables autofill preview to work as expected if a field already has a value.
Ensures autofill does not restore the default value if the user manually clears out the field's value.
This fixes the case on next.co.uk where the value of the cardholder name is being used as a placeholder.
| Assignee | ||
Comment 6•4 years ago
|
||
Comment 7•4 years ago
|
||
Hi Emilio,
Needinfo here in case you didn't see the ping in the phabricator.
https://phabricator.services.mozilla.com/D123260#inline-682663
Comment 8•4 years ago
|
||
Thanks, yeah, pings in phab are so easy to miss.
If we always want to have the value hidden if we set a previewValue, then I think we want to change this selector to be:
:not(:-moz-autofill-preview)::-moz-text-control-editing-root,
...
And that'd be a simpler fix. Note that the user wouldn't be able to type while the preview is on, but perhaps that's reasonable as IIUC the preview is only temporary?
Comment 9•4 years ago
|
||
(In reply to Emilio Cobos Álvarez (:emilio) from comment #8)
:not(:-moz-autofill-preview)::-moz-text-control-editing-root, ...And that'd be a simpler fix. Note that the user wouldn't be able to type while the preview is on, but perhaps that's reasonable as IIUC the preview is only temporary?
Thank you for the help! Yes, the preview is only temporary.
Hi Tim, could you help test what Emilio suggested? thanks!
| Assignee | ||
Comment 10•4 years ago
|
||
I agree that the user not being able to type is perfectly reasonable since previewed text is temporary. I'll test out that selector change and see what happens.
| Assignee | ||
Comment 11•4 years ago
|
||
Hmm, adding that selector won't make the difference we need for this bug unfortunately. While adding the :not(:-moz-autofill-preview)::-moz-text-control-editing-root selector does solve the preview value overlapping the actual value, form autofill still needs to remove the "placeholder" value from the field in order for autofill to work as expected. Otherwise the preview will show that the prefilled value will be autofilled...but then does not actually autofill over the prefilled value.
I suppose I can keep the selector change, since modifying a field while previewing seems like something we shouldn't allow anyway.
| Assignee | ||
Comment 12•4 years ago
|
||
Comment 13•4 years ago
|
||
Comment 14•4 years ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/1d81d6c502d9
https://hg.mozilla.org/mozilla-central/rev/bdf61151a654
| Reporter | ||
Comment 15•4 years ago
|
||
Verified-fixed on the latest Firefox Nightly 93.0a1 (2021-09-05) (64-bit) on macOS 10.15.
Although the Cardholder Name is pre-filled by the site, it will be correctly auto-filled and the autofill dropdown can be toggled from this field.
Description
•