Skip to content

Incorrect first frame when using KeyboardAvoidingView/KeyboardStickyView+offset and keyboard gets resized #315

Closed
@kirillzyusko

Description

@kirillzyusko

Describe the bug

Incorrect first frame when using KeyboardAvoidingView/KeyboardStickyView and keyboard gets resized

Code snippet

Reproducible in example app.

Repo for reproducing

Reproducible in example app.

To Reproduce
Steps to reproduce the behavior:

  1. Go to KeyboardAvoidingView/KeyboardStickyView example screens
  2. Click on TextInput and wait for keyboard to be shown
  3. Resize keyboard (change to emoji input)
  4. Animation starts from a different frame (i. e. view moved down and then animate)

Expected behavior

Animation should start from current/last position.

Screenshots

resize-jump.mp4

Smartphone (please complete the following information):

  • Desktop OS:MacOS 14.1
  • Device: Pixel 7 Pro
  • OS: Android 14
  • RN version: 0.72.4
  • RN architecture: old
  • JS engine: Hermes
  • Library version: 1.10.0

Additional context

It happens because progress becomes 0.7 instead of 1, and because of that we see initial jump.

Metadata

Metadata

Assignees

Labels

KeyboardAvoidingView 🧪Anything related to KeyboardAvoidingView componentKeyboardStickyView 🩹Anything related to KeyboardStickyView component🐛 bugSomething isn't working📚 componentsAnything related to the exported components of this library🤖 androidAndroid specific

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions