# react-native-onboarding-modal

Latest version **0.0.5** (published 2022-01-17) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-native-onboarding-modal
pnpm add react-native-onboarding-modal
yarn add react-native-onboarding-modal
bun add react-native-onboarding-modal
```

## Health

**Score 20/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities.

Warnings: low downloads; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.5 |
| Published | 2022-01-17 |
| First published | 2021-09-25 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 128.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 10 |
| Author | Sevval Eygul |
| Maintainers | sevvaleygul |
| Keywords | SevvalEygul, ŞevvalEygül, Sevval, sevval, Şevval, şevval, react, react-native, javascript, ui-lib, rn, onboarding, modal, Onboarding, Modal, onboarding-modal, onboardingModal |

## Links

- npm: https://www.npmjs.com/package/react-native-onboarding-modal
- Repository: https://github.com/sevvaleygul0/react-native-onboarding-modal
- Homepage: https://github.com/sevvaleygul0/react-native-onboarding-modal#readme
- Issues: https://github.com/sevvaleygul0/react-native-onboarding-modal/issues
- npm.io page: https://npm.io/package/react-native-onboarding-modal

## Dependencies (3)

- [react-native-modal](https://npm.io/package/react-native-modal.md) ^13.0.0
- [react-native-snap-carousel](https://npm.io/package/react-native-snap-carousel.md) ^3.9.1
- [@types/react-native-snap-carousel](https://npm.io/package/@types/react-native-snap-carousel.md) ^3.8.4

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 0.0.5 (latest) — 2022-01-17
- 0.0.4 — 2022-01-17
- 0.0.3 — 2022-01-17
- 0.0.2 — 2021-09-26
- 0.0.1 — 2021-09-25

## README

<img alt="React Native Typescript Library Starter" src="assets/onboarding-modal.png" width="1050"/>

<p align="center">
  <img alt="React Native Typescript Library Starter"
        src="assets/Screenshots/onboarding-modal.gif" height="820"/>
  <img alt="React Native Typescript Library Starter" src="assets/Screenshots/onboarding-modal.png" height="820"/>
</p>

# Installation

Add the dependency:

```bash
npm i react-native-onboarding-modal
```

## Peer Dependencies

<h5><i>IMPORTANT! You need install them</i></h5>

```js
"react-native-modal": ">=  13.0.0",
"react-native-snap-carousel": ">=  3.9.1"
```

# Usage

## Import

```jsx
import OnboardingModal, { IOnboardingModal } from "react-native-onboarding-modal";
```

## Data Format

```jsx
const exampleData: IOnboardingModal = [
  {
    title: 'Love Nature',
    subtitle: "Let's live close to nature",
    asset: require('./assets/watering.png'),
  },
}
```

## Basic Usage

```jsx
<OnboardingModal
  data={exampleData}
  onBottomButtonPress={() => console.log("Handle Let's Go Button")}
/>
```

## Advanced Usage

```jsx
<OnboardingModal
  onboardingData={exampleData}
  buttonTextColor="#51186E"
  buttonBackgroundColor="#DCCFE2"
  photoStyle={{ width: 300, height: 300 }}
  titleStyle={{ fontSize: 32, color: "#8066BA" }}
  onBottomButtonPress={() => console.log("Handle Let's Go Button")}
/>
```

# Configuration - Props

## Fundamentals

| Property       |       Type       |  Default  | Description             |
| -------------- | :--------------: | :-------: | ----------------------- |
| onboardingData | IOnboardingModal | undefined | set data shown in modal |

## Customization (Optionals)

| Property              |        Type         |  Default  | Description                                                                    |
| --------------------- | :-----------------: | :-------: | ------------------------------------------------------------------------------ |
| carouselRef           |         any         | undefined | set carouselRef prop for carousel                                              |
| disableBottomButton   |       boolean       |   false   | set visibility of the bottom button                                            |
| buttonContainer       | CustomViewStyleProp |  default  | set your own component instead of default bottom button component              |
| buttonBackgroundColor |       string        |  #21AE79  | change the button's text color                                                 |
| buttonText            |       string        | Let's Go  | change the button's text                                                       |
| buttonTextColor       |       string        |  #fefefe  | change the button's text color                                                 |
| onBottomButtonPress   |      function       |  default  | handle bottom button is pressed                                                |
| cardContainerStyle    |      ViewStyle      |  default  | set or override the style object for the modal main container                  |
| carouselItemContainer | CustomViewStyleProp |  default  | set your own component instead of default react-native-snap-carousel component |
| titleStyle            |     TitleStyle      |  default  | set or override the style object for the title text style                      |
| subtitleStyle         |     TitleStyle      |  default  | set or override the style object for the subtitle text style                   |
| photoStyle            |     ImageStyle      |  default  | set or override the style object for the photo style                           |

## Future Plans

- [x] ~~LICENSE~~

# Change Log

Change log will be here !

## Author

Sevval Eygul, sevvalleygull@gmail.com

## License

React Native Onboarding Modal is available under the MIT license. See the LICENSE file for more info.

---
_Source: https://npm.io/package/react-native-onboarding-modal · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
