Fixes 2931: Fix issue hitting enter on input is clearing pre-added tags#26039
Fixes 2931: Fix issue hitting enter on input is clearing pre-added tags#26039chirag-madlani merged 4 commits intomainfrom
Conversation
|
Hi there 👋 Thanks for your contribution! The OpenMetadata team will review the PR shortly! Once it has been labeled as Let us know if you need any help! |
🔍 CI failure analysis for 70db886: Multiple Playwright CI shards (1/6 and 4/6) failed with test failures in AuditLogs, LineageSettings, and CustomProperties areas. All failures are unrelated to this PR's SSO form changes.IssueMultiple Playwright CI shards failed with test failures across different areas. Root CauseThe failures are unrelated to this PR's changes. This PR modifies only SSO configuration form files:
All test failures occur in completely different areas with no connection to SSO forms. DetailsShard 1/6 FailuresFailed Tests (2)
Flaky (1)
Shard 4/6 FailuresFailed (1)
Flaky (11)
Common Patterns
These are pre-existing test infrastructure issues. The SSO keyboard event handling and Jest test fixes in this PR have no connection to AuditLogs, LineageSettings, or CustomProperties functionality. Code Review 👍 Approved with suggestions 2 resolved / 2 findingsClean, well-tested fix for Enter key event propagation clearing Select tags. The implementation follows existing patterns in the codebase with proper cleanup. No new issues beyond the two already-posted findings. ✅ 2 resolved✅ Bug: Dead code:
|
| Auto-apply | Compact |
|
|
Was this helpful? React with 👍 / 👎 | Gitar
|
|
Changes have been cherry-picked to the 1.11.11 branch. |



Describe your changes:
Fixes https://github.com/open-metadata/openmetadata-collate/issues/2931
I worked on ... because ...
Problem
When pressing Enter in any input field on the SSO Configuration Form, pre-added tags in Select (tag mode) fields were being unexpectedly cleared.
Root Cause
Enter keydown events on inputs bubbled up and triggered Ant Design's internal tag-removal logic on nearby Select components.
Solution
Added
createFormKeyDownHandlerutility inSSOUtils.tsthat attaches akeydownlistener to the form, intercepting Enter on input fields viapreventDefault+stopPropagation. The handler explicitly skips:TEXTAREAelements (multi-line input should work normally).ant-select-selector(so Select tag fields still work)Screen.Recording.2026-02-23.at.1.04.50.PM.mov
Type of change:
Checklist:
Fixes <issue-number>: <short explanation>Summary by Gitar
createFormKeyDownHandlerutility to prevent Enter keydown events from bubbling up and triggering Ant Design Select tag removalThis will update automatically on new commits.