Skip to content

Commit

Permalink
fix: add comment
Browse files Browse the repository at this point in the history
  • Loading branch information
tienifr committed Oct 16, 2023
1 parent 74c85b4 commit 0a7b80b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/components/PDFView/PDFPasswordForm.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,10 @@ function PDFPasswordForm({isFocused, isPasswordInvalid, shouldShowLoadingIndicat
if (!textInputRef.current) {
return;
}
/**
* We recommend using setTimeout to wait for the animation to finish and then focus on the input
* Relevant thread: https://expensify.slack.com/archives/C01GTK53T8Q/p1694660990479979
*/
focusTimeoutRef.current = setTimeout(() => {
textInputRef.current.focus();
}, CONST.ANIMATED_TRANSITION);
Expand Down

0 comments on commit 0a7b80b

Please sign in to comment.