Enter does not trigger form submission when using simplekeyboard in a form.

This issue has been tracked since 2022-06-23.

Simple-keyboard version
3.4.88

Describe the bug
Enter does not trigger form submission when using simplekeyboard in a form. Is there a workaround here using the other options available? I saw some reference in another ticket discussing accesibility that suggested flexibility using the buttonAttributes or useButtonTag options but I can't understand how that might solve this issue.

hodgef wrote this answer on 2022-07-02

Hello @quinlo,

Probably something like this:
https://codesandbox.io/s/unruffled-khorana-xdpkbm?file=/src/index.js

The idea is that a button with the property type="submit" will submit the parent form.

Regards,
Francisco Hodge

alexandereneroth wrote this answer on 2022-07-02

Hello @quinlo,

Probably something like this: codesandbox.io/s/unruffled-khorana-xdpkbm?file=/src/index.js

The idea is that a button with the property type="submit" will submit the parent form.

Regards, Francisco Hodge

@hodgef With that code all buttons will submit, since the default type of button is already submit.

How can i target all other buttons and give them type="button"?

hodgef wrote this answer on 2022-07-02

Very true. In that case you can try this out
https://codesandbox.io/s/sweet-worker-r2yx1j?file=/src/index.js

Regards,
Francisco Hodge

More Details About Repo
Owner Name hodgef
Repo Name simple-keyboard
Full Name hodgef/simple-keyboard
Language JavaScript
Created Date 2018-03-02
Updated Date 2022-12-06
Star Count 1738
Watcher Count 20
Fork Count 130
Issue Count 0

YOU MAY BE INTERESTED

Issue Title Created Date Updated Date