From 978f04eab0f1a2d525e54734976778315ab8225b Mon Sep 17 00:00:00 2001 From: Alex Carpenter Date: Fri, 19 Jul 2024 13:34:35 -0400 Subject: [PATCH] reverts changes in #3762 --- packages/elements/src/react/common/form/index.tsx | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/packages/elements/src/react/common/form/index.tsx b/packages/elements/src/react/common/form/index.tsx index 28b3571d4b..dbd6553bdb 100644 --- a/packages/elements/src/react/common/form/index.tsx +++ b/packages/elements/src/react/common/form/index.tsx @@ -298,11 +298,7 @@ const useInput = ({ const onFocus = React.useCallback( (event: React.FocusEvent) => { onFocusProp?.(event); - // Check for relatedTarget to avoid validating password when the input - // is programticallly focused after form submission. Avoids the issue - // where an error message would get removed and the success validation - // was shown immediately. - if (shouldValidatePassword && Boolean(event.relatedTarget)) { + if (shouldValidatePassword) { validatePassword(event.target.value); } },