Skip to content

[Android] KeyboardStickyView used with OverKeyboardView crashes app. #884

@Mako-L

Description

@Mako-L

Describe the bug
When we use KeyboardStickyView with OverKeyboardView, set OverKeyboardView visible to true and clicked on it it crashes the app and doesn't put the elements correctly where they should be.

Code snippet

<KeyboardStickyView style={styles.keyboardStickyView}>
        <TextInput style={styles.input} testID="over_keyboard_view.input" />
        <Button
        testID="over_keyboard_view.show"
        title="Show"
        onPress={() => setShow(true)}
      />
      </KeyboardStickyView>
      
  
   
      
      {/* OverKeyboardView outside of KeyboardStickyView but in same parent */}
      <OverKeyboardView visible={isShow}>
        <GestureHandlerRootView style={styles.fullScreen}>
          <TouchableWithoutFeedback
            style={styles.fullScreen}
            testID="over_keyboard_view.background"
            onPress={() => setShow(false)}
          >
            <View style={styles.overlayContainer}>
              <TouchableOpacity
                testID="over_keyboard_view.content"
                onPress={() => setShow(false)}
              >
                <View style={styles.background} />
              </TouchableOpacity>
            </View>
          </TouchableWithoutFeedback>
        </GestureHandlerRootView>
      </OverKeyboardView>

Repo for reproducing
Repo with example

To Reproduce
Steps to reproduce the behavior:

  1. Go to main home
  2. Click on input
  3. Click on show
  4. press on the right of the blue box.
  5. app crashes.

Expected behavior
The blue box should be on the bottom in center and when clicked outside of it it should close the "modal"

Screenshots

Image

Smartphone (please complete the following information):

  • Desktop OS: Mac os
  • Device: Pixel 8
  • OS: latest
  • RN version: 0.76.7
  • RN architecture: [new
  • JS engine: idk
  • Library version: main branch.

Additional context
None

Metadata

Metadata

Assignees

Labels

KeyboardStickyView 🩹Anything related to KeyboardStickyView componentOverKeyboardViewAnything related to OverKeyboardViewrepro providedIssue contains reproduction repository/codesponsor 💖Someone pays money for the issue to be resolved 💸🎯 crashLibrary triggers a crash of the app🤖 androidAndroid specific

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions