Should rh-button always submit? #1266
bennypowers
started this conversation in
Ideas
Replies: 1 comment 1 reply
-
I agree as long as we're explicit in our documentation that this differs from standard button functionality. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Consider
Without custom javascript, the second button show above will submit the form
So too
The secondary variant button here will submit the form
Proposal
I submit (:drum:) that our design system buttons should request to submit the form if-and-only-if they have
type="submit"
. In all other cases, they should not submit the form without user-written custom javascript.Potential Pitfalls
submit behaviour of custom button FACEs has not yet been specified. If we take this decision now, we may come up against a future in which the standards have diverged. Nonetheless, in order to open up uses like "show logs" from above, I think we're within our rights to take this decision.
Beta Was this translation helpful? Give feedback.
All reactions