Giter VIP home page Giter VIP logo

abdemirza / react-native-avoid-softinput Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mateusz1913/react-native-avoid-softinput

0.0 0.0 0.0 6.15 MB

Native solution for common React Native problem of focused views being covered by soft input view.

Home Page: https://mateusz1913.github.io/react-native-avoid-softinput/

License: MIT License

JavaScript 4.20% Ruby 3.19% C 0.10% Objective-C 1.72% Kotlin 31.53% TypeScript 31.31% Objective-C++ 10.29% Swift 17.67%

react-native-avoid-softinput's Introduction

react-native-avoid-softinput

React Native Avoid SoftInput logo
Handle keyboard in React Native apps like a Pro

Native solution for common React Native problem of focused views being covered by soft input view. It is solved by listening for soft input events and applying translation to react root view (or bottom padding if focused element's parent is scroll view) entirely on native side and only if currently focused view is covered by soft input frame. It supports focused views being positioned in scroll views and regular views (check out example app). It also supports modal content, when content is wrapped in AvoidSoftInputView.

Form example Sticky footer example

Documentation

Check package documentation

Installation

Version 3.x.x supports React Native 0.65+ (old architecture) and has support for Android API 21+ and iOS 11.0+. It also supports Fabric & TurboModules (new architecture) with React Native 0.70+.

Library supports Android & iOS, for out-of-tree platforms, View component is used as fallback.

  1. Install library with your package manager:
yarn add react-native-avoid-softinput

or

npm i --save react-native-avoid-softinput
  1. (iOS-only) Install pods:
npx pod-install
  1. (iOS-only) Create and configure bridging header in your iOS project, if it doesn't exist (the easiest way is to create empty .swift file in XCode)

For reference, you can visit Getting started section

Expo

Usage

Check usage guides for module and view

Alternatives

If library does not suite your needs, you can check alternatives section

Contributing

See the contributing guide to learn how to contribute to the repository and the development workflow.

License

MIT

react-native-avoid-softinput's People

Contributors

arnabj avatar batical avatar brentvatne avatar dependabot[bot] avatar hatcloud avatar ipagar avatar mateusz1913 avatar max-kim avatar nucleartux avatar randall71 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.