Skip to content

headerLargeTitle & headerSearchBarOptions Doesn't Support RTL #1884

@Wahsner

Description

@Wahsner

Description

When RTL is enabled, the headerLargeTitle & headerSearchBarOptions don't honour the text direction. Instead they remain LTR as shown in the below screen cuttings.

  • Restarting the app between changing text direction makes no difference.
  • The fact the text itself isn't a RTL language makes no difference.
  • Having the device in a RTL language makes no difference.
  • Doesn't matter if you're using Paper or Fabric or the new/old arch.
  • Doesn't matter if you're running in debug or release.
  • Doesn't matter if you're running on a real or sim device.

headerLargeTitle
image
headerSearchBarOptions(focused)
image

I would expect them to be positioned right as shown below (taken from the contacts app)

Large Title
image
Search bar(focused)
image

Steps to reproduce

  1. Set the options direction: 'rtl'
  2. Not sure if required, but Set I18nManager.forceRTL(true); in the App.js too
  3. Restart the app by closing it completely from background and re-launching

Expected

  • For text direction to be RTL for headerLargeTitle & headerSearchBarOptions

Actual

  • headerLargeTitle & headerSearchBarOptions are still LTR

Snack or a link to a repository

https://github.com/0xRenshaw/react-native-screens/tree/main/FabricExample

Screens version

3.25.0

React Native version

0.72.4

Platforms

iOS

JavaScript runtime

None

Workflow

React Native (without Expo)

Architecture

Paper (Old Architecture)

Build type

Release mode

Device

Real device

Device model

No response

Acknowledgements

Yes

Metadata

Metadata

Assignees

Labels

Missing reproThis issue need minimum repro scenarioPlatform: iOSThis issue is specific to iOS

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions