mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-09 01:08:39 +09:00
Issue #2790 - Part 3: Address BZ bug 1849122 and resolve build issues
This commit is contained in:
parent
d99eab0d9d
commit
4cdfb9e16b
4 changed files with 33 additions and 4 deletions
|
|
@ -31,6 +31,19 @@ function FormHandler(aForm, aWindow) {
|
|||
this.window = aWindow;
|
||||
|
||||
this.fieldDetails = [];
|
||||
|
||||
// Add a reset event listener to clear autofill state
|
||||
this.form.addEventListener("reset", () => {
|
||||
console.log('Form reset detected, clearing autofill state');
|
||||
for (let element of this.form.elements) {
|
||||
if (typeof element.setAutofilled === "function") {
|
||||
element.setAutofilled(false);
|
||||
console.log('setAutofilled(false) called on', element);
|
||||
}
|
||||
}
|
||||
// Optionally, clear fieldDetails if you want to force re-collection
|
||||
// this.fieldDetails = [];
|
||||
});
|
||||
}
|
||||
|
||||
FormHandler.prototype = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue