NO-JIRA: Autofocus name field in create project/namespace modals - #16902
NO-JIRA: Autofocus name field in create project/namespace modals#16902fallmo wants to merge 1 commit into
Conversation
Added `autoFocus` to the Name `TextInput` in both `CreateProjectModal.tsx` and `CreateNamespaceModal.tsx`
|
Pipeline controller notification For optional jobs, comment This repository is configured in: LGTM mode |
|
@fallmo: This pull request explicitly references no jira issue. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository: openshift/coderabbit/.coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
WalkthroughChangesModal input autofocus
Estimated code review effort: 1 (Trivial) | ~2 minutes Suggested reviewers: 🚥 Pre-merge checks | ✅ 14 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (14 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Hi @fallmo. Thanks for your PR. I'm waiting for a openshift member to verify that this patch is reasonable to test. If it is, they should reply with Regular contributors should join the org to skip this step. Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: fallmo The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
Analysis / Root cause:
The Name field in
CreateProjectModalandCreateNamespaceModalwasn't autofocused, so on open, keyboard/screen-reader focus landed on the first tabbable element in the modal (the "Learn more about working with projects" link, or the field-level help icon) instead of the input. This appears to be an oversight from the PatternFly v6 modal migration rather than an intentional choice — sibling modals like TextInputModal already autofocus their primary field.Solution description:
Added
autoFocusto the NameTextInputin bothCreateProjectModal.tsxandCreateNamespaceModal.tsx, matching the existing pattern used elsewhere inconsole-shared.Test cases:
Summary by CodeRabbit