summaryrefslogtreecommitdiffstats
path: root/browser/actors/FormValidationChild.sys.mjs
diff options
context:
space:
mode:
Diffstat (limited to 'browser/actors/FormValidationChild.sys.mjs')
-rw-r--r--browser/actors/FormValidationChild.sys.mjs6
1 files changed, 5 insertions, 1 deletions
diff --git a/browser/actors/FormValidationChild.sys.mjs b/browser/actors/FormValidationChild.sys.mjs
index 6fa2e3c90d..f5ce427d03 100644
--- a/browser/actors/FormValidationChild.sys.mjs
+++ b/browser/actors/FormValidationChild.sys.mjs
@@ -73,7 +73,11 @@ export class FormValidationChild extends JSWindowActorChild {
if (element.isFormAssociatedCustomElements) {
// For element that are form-associated custom elements, user agents
// should use their validation anchor instead.
- element = element.internals.validationAnchor;
+ // It is not clear how constraint validation should work for FACE in
+ // spec if the validation anchor is null, see
+ // https://github.com/whatwg/html/issues/10155. Blink seems fallback to
+ // FACE itself when validation anchor is null, which looks reasonable.
+ element = element.internals.validationAnchor || element;
}
if (!element || !Services.focus.elementIsFocusable(element, 0)) {