[FR]: Retain states of SearchTextField after configuration changes
Is there an existing issue for this?
- [X] I have searched the existing issues
Describe the problem
Unlike EditText in Android Views, TextField in Compose doesn’t automatically retain or restore its states as the device goes through configuration changes such as rotating the device between landscape and portrait orientations, folding / unfolding the device, resizing window, switching dark mode, etc.
Currently, the app opens keyboard after configuration changed even when a user hid the keyboard by tapping back button or 'search' key. Also, position of cursor is not retained after the event.
This is also to find out good solution for this public issue on Compose: https://issuetracker.google.com/192776771
Describe the solution
I suggest to implement equivalent experiences with EditText, by retaining the following after configuration changes:
- Position of cursor
- Text selection
- Focus
- Keyboard visibility
Additional context
No response
Code of Conduct
- [X] I agree to follow this project's Code of Conduct