Skip to content

Commit 5406103

Browse files
committed
Do not interrupt smooth scrolling on focus
1 parent 6a7da91 commit 5406103

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Resources/Private/Build/JavaScript/FormValidation.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,8 +128,8 @@ class Form {
128128
const fieldsWithError = this.#form.querySelectorAll('.powermail_field_error');
129129
fieldsWithError.forEach((field) => {
130130
if (Utility.isElementVisible(field)) {
131-
field.scrollIntoView({behavior:'smooth', block:'center'});
132131
field.focus({preventScroll:true});
132+
field.scrollIntoView({behavior:'smooth', block:'center'});
133133
throw 'StopException';
134134
}
135135
});

0 commit comments

Comments
 (0)