Added hotfix for formsubmit on enter keydown.#2377
Added hotfix for formsubmit on enter keydown.#2377nuke-ellington merged 5 commits intosiemens:mainfrom
Conversation
🦋 Changeset detectedLatest commit: 6a0fc7e The changes in this PR will be included in the next version bump. This PR includes changesets to release 5 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Summary of ChangesHello @1307-Dev, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request resolves an issue where forms containing an Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request introduces a hotfix to ensure forms are submitted on 'Enter' key press when an ix-button with type="submit" is used. The changes involve updating the handleSubmitOnEnterKeydown utility function and expanding the test suite to cover this new scenario.
The changes are generally good and address the issue described. The following comments have been retained as they are valid and do not conflict with the provided rules:
- A suggestion to simplify the logic in
input.util.tsby removing what appears to be a redundant code block, which would improve maintainability. - A request to remove
.onlyfrom the new test case inform-ready.ct.tsto ensure all tests are executed in the test suite.
|



💡 What is the current behavior?
Form submit on enter down is only limited when the button used is native with type submit. Does not submit when the button used is ix-button with type submit
GitHub Issue Number: #2362
JIRA Issue Number:IX-3895
🆕 What is the new behavior?
The form now submits when ix-button with type=submit is used. Adjusted the utility function to have a more robust submission. Modified the form ready tests to reflect the same behaviour.
🏁 Checklist
A pull request can only be merged if all of these conditions are met (where applicable):
pnpm test)pnpm lint)pnpm build, changes pushed)👨💻 Help & support