software-mansion/react-native-screens

`live-markdown` + `native-stack` + `fabric` causes incorrect layout when keyboard is open on Android

kirillzyusko opened this issue · 2 comments

Description

If you use @expensify/react-native-live-markdown with native-stack (and new arch enabled) then input is obscured by the keyboard even if adjustResize is specified for softInputMode.

Actually I don't know if it's correct repo to open an issue or it should be opened in @expensify/react-native-live-markdown, because:

  • native-stack + TextInput from RN -> everything is working fine
  • stack + live-markdown -> everything works fine
  • stack + TextInput from RN -> everything is working fine
  • native-stack + live-markdown produces incorrect layout.

The reason why I open it here because if you inspect elements in layout inspector then you can notice, that next children to Screen has incorrect layout (and I tend to think that the problem comes from RNS, but feel free to correct me - if you think it's live-markdown issue, let me know and I'll re-open issue there):

image

Steps to reproduce

  • click on go to details
  • set focus to input

Snack or a link to a repository

https://github.com/kirillzyusko/native-stack-markdown-repro

Screens version

3.31.0

React Native version

0.73.4

Platforms

Android

JavaScript runtime

Hermes

Workflow

React Native (without Expo)

Architecture

Fabric (New Architecture)

Build type

Debug mode

Device

Android emulator

Device model

Pixel 3A (API 33)

Acknowledgements

Yes

Hi, @kirillzyusko! I believe this issue does not come from react-native-screens, since we're not impacting any layout changes during the screen layout. Also, I can observe that MarkdownTextInput already jumps before screens are calling first layout. Therefore, can I ask you to create an issue in react-native-live-markdown repo first? We can of course re-open this issue, if you think this still should be fixed in screens repo!

Hey @tboba

Makes sense! I opened issue in live-markdown - Expensify/react-native-live-markdown#346

I'll close this issue - and yeah, will re-open if we think it should be re-opened in RNS. Thank you for your help!