Repository navigation
Conversation
|
@javache has exported this pull request. If you are a Meta employee, you can view the originating Diff in D126057002. |
…eact#59188) Summary: Pull Request resolved: react#59188 UIKit text change delegate callbacks now remain decision-only when JavaScript transforms an edit. The adapter rejects UIKit's original edit, records an implementation-private transaction, and applies an incremental `UITextInput` replacement on the next main-queue turn after validating the backing-view generation and base text. This preserves partial `maxLength` truncation without synchronously replacing the full attributed string or selection. Marked-text composition remains UIKit-owned; an over-limit committed value is corrected through the same deferred transaction path after composition ends. A runtime gate controls the new path. Stale edits are discarded when the backing text changes, lifecycle and JavaScript-driven updates invalidate queued transactions, and successful commits emit one change update plus the corresponding selection event. Changelog: [iOS][Fixed] - Preserve transformed `TextInput` edits without synchronously rewriting text inside UIKit delegate callbacks Reviewed By: cipolleschi Differential Revision: D126057002
javache
force-pushed
the
export-D126057002
branch
from
October 19, 2026 15:31
a443071 to
bf7e25c
Compare
This branch has not been deployed
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.
Summary:
UIKit text change delegate callbacks now remain decision-only when JavaScript transforms an edit. The adapter rejects UIKit's original edit, records an implementation-private transaction, and applies an incremental
UITextInputreplacement on the next main-queue turn after validating the backing-view generation and base text.This preserves partial
maxLengthtruncation without synchronously replacing the full attributed string or selection. Marked-text composition remains UIKit-owned; an over-limit committed value is corrected through the same deferred transaction path after composition ends. A runtime gate controls the new path.Stale edits are discarded when the backing text changes, lifecycle and JavaScript-driven updates invalidate queued transactions, and successful commits emit one change update plus the corresponding selection event.
Changelog:
[iOS][Fixed] - Preserve transformed
TextInputedits without synchronously rewriting text inside UIKit delegate callbacksReviewed By: cipolleschi
Differential Revision: D126057002