Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: The virtual keyboard is sometimes visible after clicking on the Search field on the homepage #2712

Merged
merged 2 commits into from Aug 2, 2022

Conversation

g123k
Copy link
Collaborator

@g123k g123k commented Aug 2, 2022

The homepage card displays a TextField that does nothing. Once it has the focus, it opens a screen.
On some devices, the event to open the keyboard has the time to be consumed, hence the issue.

To prevent this behavior, I have created a fake button, with also some lovely ripples 😋
https://user-images.githubusercontent.com/246838/182380411-20e1f8af-322f-4acc-a72d-b5b57c4159a9.mp4

Will fix #2531

@g123k g123k requested a review from a team as a code owner August 2, 2022 12:59
@g123k g123k self-assigned this Aug 2, 2022
Copy link
Member

@AshAman999 AshAman999 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nothing serious, just a minor comment (can be ignored)

),
style: const TextStyle(fontSize: 18.0),
hintText: localizations.search,
suffixIcon: widget.showClearButton ? _buildClearButton() : null,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we have used this variable instead of creating readOnly here?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's another way to design this, true.
But my idea was to limit the changes on the external API

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay then it's fine, can be merged!

@teolemon
Copy link
Member

teolemon commented Aug 2, 2022

thanks @g123k

@teolemon teolemon merged commit 16ca53b into openfoodfacts:develop Aug 2, 2022
@monsieurtanuki
Copy link
Contributor

@g123k In addition to that, we could imagine another fake text field dedicated to barcodes, which would open the same "text field" page, but with a numeric keyboard.
To be displayed either close to the current fake text field, or on top when the camera is not activated. Or both.
cf. #2662.

@g123k
Copy link
Collaborator Author

g123k commented Aug 3, 2022

@g123k In addition to that, we could imagine another fake text field dedicated to barcodes, which would open the same "text field" page, but with a numeric keyboard. To be displayed either close to the current fake text field, or on top when the camera is not activated. Or both. cf. #2662.

Nice idea indeed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants