Fractional metrics with inline Views cause inconsistent Text wrapping
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 127k
- Forks
- 25.3k
- Avg merge
- 1d 23h
- Merged PRs (30d)
- 4
Description
Description
on Android, Text containing an inline positions the outside the bounding box of its parent as if it was wrapping. This is affected by font size, font scaling, and both the size and position of the container.
Steps to reproduce
Compare snack with screenshots
React Native Version
0.81.5
Affected Platforms
Runtime - Android
Areas
Fabric - The New Renderer
Output of npx @react-native-community/cli info
n/a
Stacktrace or Logs
n/a
MANDATORY Reproducer
https://snack.expo.dev/@codatrigger/shallow-orange-chips
Screenshots and Videos
Web: ideal appearance
iOS: unrelated baseline positioning bug, otherwise correct
Android: width reserved but positioned on next "line"
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by running the mandatory Snack reproducer on Android with React Native 0.81.5, then compare its inline View placement with the provided web, iOS, and Android screenshots. Trace the Fabric text and inline-View layout path, checking font size, font scaling, and container size or position; done means the View stays within its parent's bounding box across those cases.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, react-native
- Domain
- mobile-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 46/100