-
Notifications
You must be signed in to change notification settings - Fork 221
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
Add preprocessValue
callback, just to allow users to change value a…
#115
Conversation
…s they type - This is useful to do normalizations, like transforming japanese numbers (e.g., 1, 2, etc.) to the right alpha numbers (e.g., `1`, `2`, etc.).
I think this is the real issue. IMO normalization should be done by saving fixed value and passing it as |
@janmarek I meant passing For the use case I mentioned, the |
@patw0929 any thoughts on this? |
Hi @brunops |
Oh, no problem man. I wouldn't add normalization as part of the plugin itself, I think providing a callback where people can process the input any way they want to is more flexible (most people will probably never use this). |
Sorry for being busy so long... 😭 I'm curious about the need of normalizations. Because we already restrict the input keys in |
@patw0929 no worries man! You are correct, the problem appears when full width numbers need to be allowed, in a way that instead of when typing |
Going to close this due to age, not opposed to revisiting the underlying changes / ideas though! |
…s they type
1
,2
, etc.).defaultValue
property.. directly changingvalue
makes the cursor jump like crazy.Simulate.change
andSimulate.keyDown