[Android] textAlignVertical doesn't work on nested text
See original GitHub issue- I have reviewed the documentation
- I have searched existing issues
- I am using the latest React Native version
textAlignVertical works fine when set on the top-most Text component. However, if you have any nested texts (a common use case), you can not override the alignVertical in the child Text component.
Environment
OS: macOS Sierra 10.12.6 Node: 9.3.0 Yarn: 1.3.2 npm: 5.6.0 Watchman: 4.9.0 Xcode: Xcode 9.2 Build version 9C40b Android Studio: 2.3.3
Packages: (wanted => installed) react: 16.3.0-alpha.1 => 16.3.0-alpha.1 react-native: 0.55.0 => 0.55.0
Steps to Reproduce
- Use this expo app OR create a nested Text component with the same height as its parent & give it a textAlignVertical
Expected Behavior
The child Text’s textAlignVertical should be honored.
Actual Behavior
The child Text’s textAlignVertical is NOT honored. See screenshots below for two different cases:
textAlignVertical on parent Text | textAlignVertical on child Text |
---|---|
![]() |
![]() |
Issue Analytics
- State:
- Created 5 years ago
- Reactions:8
- Comments:10 (1 by maintainers)
Top Results From Across the Web
[Android] textAlignVertical doesn't work on nested text #30375
textAlignVertical works fine when set on the top-most Text component. However, if you have any nested texts (a common use case), you can...
Read more >Nested Text, Vertical Align not working - React Native
I want the nested Text vertically center aligned with the parent one. Code // @flow import React, { Component } from 'react'; ...
Read more >Text · React Native
A React component for displaying text. Text supports nesting, styling, and touch handling. In the following example, the nested title and body text...
Read more >Text - React Native Archive
A React component for displaying text. Text supports nesting, styling, and touch handling. In the following example, the nested title and body text...
Read more >Aligning Children using Flexbox in React Native - Modus Create
First we need to create the required views and texts, open the ... Because we didn't define a flex direction, the column direction...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community’s attention? This issue may be closed if no further activity occurs. You may also label this issue as “For Discussion” or “Good first issue” and I will leave it open. Thank you for your contributions.
Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please feel free to create a new issue with up-to-date information.