Skip to content

fix(mobile): fixing mnemonics screen behavior [PERA-3698]#134

Merged
fmsouza merged 1 commit intomainfrom
fmsouza/pera-3698
Feb 25, 2026
Merged

fix(mobile): fixing mnemonics screen behavior [PERA-3698]#134
fmsouza merged 1 commit intomainfrom
fmsouza/pera-3698

Conversation

@fmsouza
Copy link
Contributor

@fmsouza fmsouza commented Feb 25, 2026

Pull Request Template

Description

  • Fixed focus bouncing between mnemonic input fields by replacing a fragile setTimeout-based focus transfer with a useEffect that fires after render commit when refs are guaranteed to be set
  • Fixed autocomplete suggestions not filling the field — the dropdown was absolutely positioned inside a small parent view, so on iOS taps fell through to the TextInput row underneath instead of hitting the suggestion. Moved the dropdown to render inline in the layout flow so it properly receives touches
  • Eliminated stale closure in paste detection — handleWordChange now reads from a wordsRef instead of capturing words in its dependency array, preventing false clipboard checks on rapid typing
  • Stabilized input refs — replaced per-render inline ref callbacks (24/25 new functions every render) with a useMemo-based refCallbacks array created once
  • Added deps to useImperativeHandle in PWInput to prevent unnecessary handle recreation each render
  • All fixes apply to both 24-word (HD wallet) and 25-word (Algo25) mnemonic flows

Related Issues

Checklist

  • Have you tested your changes locally?
  • Have you reviewed the code for any potential issues?
  • Have you documented any necessary changes in the project's documentation?
  • Have you added any necessary tests for your changes?
  • Have you updated any relevant dependencies?

Additional Notes

  • Add any additional notes or comments that may be helpful for reviewers.

@fmsouza fmsouza requested a review from wjbeau February 25, 2026 12:45
@fmsouza fmsouza self-assigned this Feb 25, 2026
@fmsouza fmsouza merged commit c115e56 into main Feb 25, 2026
7 checks passed
@fmsouza fmsouza deleted the fmsouza/pera-3698 branch February 25, 2026 13:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants