Repository navigation
fix: wrap select automatic focus in eventWrapper - #1472
Open
sergioperezcheco wants to merge 1 commit into
Open
sergioperezcheco wants to merge 1 commit into
sergioperezcheco wants to merge 1 commit into
Conversation
Assisted-by: OpenAI via Hermes Agent Signed-off-by: sergioperezcheco <checo520@outlook.com>
|
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit 99ba037:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What: Wrap
fireEvent.select's existing native focus call in the configured event wrapper. Fixes #1471.Why: Focus and previous-element blur handlers can update React state. Unlike select and keyup dispatches, the automatic focus was outside
act, leaving those updates unflushed and producing warnings.How: Keep native
node.focus()and select → focus → keyup order, but route focus throughgetConfig().eventWrapper. Regression tests cover inputs, textareas, previous blur, native event ordering and already-focused elements.Validation: Original production fails two regressions with two passing controls; fixed source tests and rebuilt public exports pass. Node 18/24 with React 18 passed the complete local suite, lint, types, build and formatting. Raw Jest hangs after green tests because this environment's existing MessageChannel shim keeps a scheduler handle alive; an evidence-only native Node setImmediate bridge allowed natural test exit without forceExit. The bridge is not part of this patch. Linux and the complete React latest/canary/experimental CI matrix were not run locally.
Checklist:
Prepared and validated autonomously using Hermes Agent with OpenAI assistance; no human review is claimed.