Add longest-line sizing for wrapped Text - #58351
Conversation
Summary: Add `textWidthMode="longest-line"` to size wrapped `Text` to its widest rendered line on Android and iOS. This keeps content-proportional spacing in horizontal layouts without an `onTextLayout` round trip; the default measurement behavior is unchanged. Changelog: [General][Added] - Add `textWidthMode="longest-line"` for sizing wrapped `Text` to its widest rendered line. Differential Revision: D118718410
|
@Abbondanzo has exported this pull request. If you are a Meta employee, you can view the originating Diff in D118718410. |
|
Warning JavaScript API change detected This PR commits an update to
This change was flagged as: |
|
/review |
🤖 AI code reviewDecision: Ready for human review Overall PR risk: Low. The change is additive and preserves default Text measurement, with new behavior limited to Text that opts into longest-line mode on Android and iOS. The most plausible breakage is narrower measurement or rewrapping for opted-in Text only. No critical or warning findings were reported. No findings. This review is advisory — it never blocks a merge and never auto-approves. |
|
/review |
1 similar comment
|
/review |
Summary:
Add
textWidthMode="longest-line"to size wrappedTextto its widest rendered line on Android and iOS. This keeps content-proportional spacing in horizontal layouts without anonTextLayoutround trip; the default measurement behavior is unchanged.Changelog:
[General][Added] - Add
textWidthMode="longest-line"for sizing wrappedTextto its widest rendered line.Differential Revision: D118718410