Describe the bug
After the bidi support integrated everything is much easier for RTL languages.
At the same time, an issue (glitch) occurs when you try to add a <Text> element inside another <Text> element.
To Reproduce
- Create a basic environment of react-pdf with a font supported by RTL (e.g: Rubik)
- Add a
<Text> element and add style={{direction: 'rtl'}} to it so RTL will work properly (so far so good - everything should be fine)
- Add a
<Text style={{ color: 'red' }}> element with text inside
<View style={{ fontFamily: 'Rubik', textAlign: 'center', width: '100%' }}>
<Text style={{direction: 'rtl'}}>עברית <Text style={{ color: 'red'}}>קשה</Text> שפה</Text>
</View>
<View style={{ fontFamily: 'Rubik', textAlign: 'center', width: '100%' }}>
<Text style={{direction: 'rtl'}}>ولما كان <Text style={{ color: 'red'}}>تناسي</Text> حقوق الإنسان وازدراؤها قد أفضيا إلى أعمال همجية</Text>
</View>
Expected behavior
Expected the text in the inner <Text> element to be colored in red.
Screenshots


Desktop (please complete the following information):
- OS: MacOS, Linux
- Browser: Chrome. Firefox
- React-pdf version: v4.0.0
Describe the bug
After the bidi support integrated everything is much easier for RTL languages.
At the same time, an issue (glitch) occurs when you try to add a
<Text>element inside another<Text>element.To Reproduce
<Text>element and addstyle={{direction: 'rtl'}}to it so RTL will work properly (so far so good - everything should be fine)<Text style={{ color: 'red' }}>element with text insideExpected behavior
Expected the text in the inner
<Text>element to be colored in red.Screenshots

Desktop (please complete the following information):