1.2.4 • Published 1 year ago

@ajxb/akav v1.2.4

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

AKAV (ActualKeyboardAvoidingView)

Because https://reactnative.dev/docs/keyboardavoidingview isn't enough (we still use it though)

The Problem:

Keyboard placement in React Native has been an inconvience for me and for many other developers. And simply follolowing the docs isn't quite ideal.

The Solution:

A universal view where the skelenton of the page is defined, and action buttons are well positioned, regardless where the keyboard is.

Preview:

Keyboard ShownKeyboard Hidden
import AKAV from '@ajxb/akav'

const RenderSubmitButton = () => {
	return <Button type={'primary'} title={'Login'} onPress={handleLogin}/> } offset={120} pl={10} pr={10} testID={'loginSubmitButton'}/>
}

<AKAV submitButton={<RenderSubmitButton/>}
	<MyLogo/>
	<MyEmailInputField/>
	<MyPasswordInputField/>
</AKAV/>
PropDescriptionTypeDefault
submitButtonMost likely View container that contains the page's - Call to - action buttonsReactNodeRequired
childrenThe rest of the page's components, like forms and imagesReactNodeRequired
backgroundThe background color of the SafeAreaView that contains the childrenString#FFFFFF
plPadding left of the SafeAreaView that contains the childrenNumber20
prPadding right of the SafeAreaView that contains the childrenNumber20
needsSTBDoes the ScrollView need to scroll to the bottom of the page when keyboard opens? (Useful in some edge cases)Booleanfalse
offsetThe KeyboardAvoidingView offset, (see Documentation)Number100
1.2.0

1 year ago

1.2.4

1 year ago

1.2.3

1 year ago

1.2.2

1 year ago

1.2.1

1 year ago

1.1.2

1 year ago

1.1.1

3 years ago

1.1.0

3 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.31

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago