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

Introduce & Standardize a way to play Haptics #120

Open
nivisi opened this issue May 12, 2023 · 0 comments
Open

Introduce & Standardize a way to play Haptics #120

nivisi opened this issue May 12, 2023 · 0 comments
Assignees
Labels

Comments

@nivisi
Copy link
Contributor

nivisi commented May 12, 2023

Vibration is quite a common thing for mobile apps. Triggered from pull to refresh, on tap on specific buttons like pin buttons, on error or whatsoever — it enhances UX for a user. There's a good article in the human interface guidelines about playing haptics.

On the native side we're getting this... Uhm natively with the native components, but on Flutter, we don't. It expands the list of things that make Flutter apps feel "off". But it's quite easy to exclude from the list.

There is a good package, flutter_vibrate. It supports playing custom vibration as well as using the predefined native vibrations, like error, success etc. I propose to add a class with static method that encapsulates usage of this package, and also to define guidelines on when we should add vibration and what exact vibration.

What I can think of at the moment:

  • Pinpad keyboard — light
  • Pin validation error — error
  • Pull to refresh, when it's armed — light
  • When a switch is toggled — light
  • On long press — light

Of course we should standardize it as much as possible so devs are not bothered with adding this themselves. Plus, it will guarantee that we're always covering vibration for the same components all across the app.

@nivisi nivisi added the TBD label May 12, 2023
@nivisi nivisi self-assigned this May 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant