{"id":13406825,"url":"https://github.com/gorhom/react-native-paper-onboarding","last_synced_at":"2025-05-16T09:00:20.118Z","repository":{"id":41061941,"uuid":"244014883","full_name":"gorhom/react-native-paper-onboarding","owner":"gorhom","description":"Paper Onboarding is a material design UI slider for `React Native`.","archived":false,"fork":false,"pushed_at":"2021-11-03T14:49:14.000Z","size":2870,"stargazers_count":884,"open_issues_count":8,"forks_count":52,"subscribers_count":15,"default_branch":"master","last_synced_at":"2025-05-10T09:05:02.786Z","etag":null,"topics":["material","onboarding","paper","react-native","reanimated","redash","slider","ui"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gorhom.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"github":"gorhom"}},"created_at":"2020-02-29T17:51:41.000Z","updated_at":"2025-05-10T06:19:55.000Z","dependencies_parsed_at":"2022-07-16T05:30:35.542Z","dependency_job_id":null,"html_url":"https://github.com/gorhom/react-native-paper-onboarding","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gorhom%2Freact-native-paper-onboarding","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gorhom%2Freact-native-paper-onboarding/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gorhom%2Freact-native-paper-onboarding/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gorhom%2Freact-native-paper-onboarding/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gorhom","download_url":"https://codeload.github.com/gorhom/react-native-paper-onboarding/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254501547,"owners_count":22081526,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["material","onboarding","paper","react-native","reanimated","redash","slider","ui"],"created_at":"2024-07-30T19:02:40.278Z","updated_at":"2025-05-16T09:00:18.572Z","avatar_url":"https://github.com/gorhom.png","language":"TypeScript","funding_links":["https://github.com/sponsors/gorhom"],"categories":["TypeScript"],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\u003ch1\u003ePaper Onboarding\u003c/h1\u003e\n\n[![npm](https://badgen.net/npm/v/@gorhom/paper-onboarding)](https://www.npmjs.com/package/@gorhom/paper-onboarding) [![npm](https://badgen.net/npm/license/@gorhom/paper-onboarding)](https://www.npmjs.com/package/@gorhom/paper-onboarding) [![npm](https://badgen.net/npm/types/@gorhom/paper-onboarding)](https://www.npmjs.com/package/@gorhom/paper-onboarding)\n\n\u003cimg src=\"./preview.gif\"\u003e\n\nPaper Onboarding is a material design UI slider for `React Native` inspired by [Ramotion Paper Onboarding](https://github.com/Ramotion/paper-onboarding).\n\n\u003c/div\u003e\n\n---\n\n## Installation\n\n```sh\nyarn add @gorhom/paper-onboarding\n# or\nnpm install @gorhom/paper-onboarding\n```\n\n\u003e Also, you need to install [react-native-reanimated](https://github.com/software-mansion/react-native-reanimated), [react-native-gesture-handler](https://github.com/software-mansion/react-native-gesture-handler) \u0026 [react-native-svg](https://github.com/react-native-community/react-native-svg), and follow their installation instructions.\n\n## Usage\n\n```tsx\nimport PaperOnboarding, {PaperOnboardingItemType} from \"@gorhom/paper-onboarding\";\n\nconst data: PaperOnboardingItemType[] = [\n  {\n    title: 'Hotels',\n    description: 'All hotels and hostels are sorted by hospitality rating',\n    backgroundColor: '#698FB8',\n    image: /* IMAGE COMPONENT */,\n    icon: /* ICON COMPONENT */,\n    content: /* CUSTOM COMPONENT */,\n  },\n  {\n    title: 'Banks',\n    description: 'We carefully verify all banks before add them into the app',\n    backgroundColor: '#6CB2B8',\n    image: /* IMAGE COMPONENT */,\n    icon: /* ICON COMPONENT */,\n    content: /* CUSTOM COMPONENT */,\n  },\n  {\n    title: 'Stores',\n    description: 'All local stores are categorized for your convenience',\n    backgroundColor: '#9D8FBF',\n    image: /* IMAGE COMPONENT */,\n    icon: /* ICON COMPONENT */,\n    content: /* CUSTOM COMPONENT */,\n  },\n];\n\nconst Screen = () =\u003e {\n  const handleOnClosePress = () =\u003e console.log('navigate to other screen')\n  return (\n    \u003cPaperOnboarding\n      data={data}\n      onCloseButtonPress={handleOnClosePress}\n    /\u003e\n  )\n}\n```\n\n## Props\n\n| name                     | description                                                          | required | type                                                       | default                                    |\n| ------------------------ | -------------------------------------------------------------------- | -------- | ---------------------------------------------------------- | ------------------------------------------ |\n| data                     | Array of pages/slides to present.                                    | YES      | Array\u003c[PaperOnboardingItemType](#paperonboardingitemtype)\u003e |                                            |\n| safeInsets               | Safe area insets usually come from `react-native-safe-area-context`. | NO       | Insets                                                     | {top: 50, bottom: 50, left: 50, right: 50} |\n| direction                | Pan gesture direction.                                               | NO       | 'horizontal' \\| 'vertical'                                 | horizontal                                 |\n| indicatorSize            | Indicator size (width and height).                                   | NO       | number                                                     | 40                                         |\n| indicatorBackgroundColor | Indicator background color.                                          | NO       | string                                                     | white                                      |\n| indicatorBorderColor     | Indicator border color.                                              | NO       | string                                                     | white                                      |\n| titleStyle               | Text style to override `all` page/slide title style.                 | NO       | StyleProp\u003cTextStyle\u003e                                       |                                            |\n| descriptionStyle         | Text style to override `all` page/slide description style.           | NO       | StyleProp\u003cTextStyle\u003e                                       |                                            |\n| closeButton              | Custom component to be used instead of the default close button.     | NO       | (() =\u003e React.ReactNode) \\| React.ReactNode                 |                                            |\n| closeButtonText          | Close button text.                                                   | NO       | string                                                     | close                                      |\n| closeButtonTextStyle     | Close button text style.                                             | NO       | StyleProp\u003cTextStyle\u003e                                       |                                            |\n| onCloseButtonPress       | Callback on close button pressed.                                    | NO       | () =\u003e void                                                 |                                            |\n| onIndexChange            | Callback when index change.                                          | NO       | () =\u003e void                                                 |                                            |\n\n#### PaperOnboardingItemType\n\n| name             | description                                                                                   | required | type                                                                                    |\n| ---------------- | --------------------------------------------------------------------------------------------- | -------- | --------------------------------------------------------------------------------------- |\n| content          | Slide/page content, this will replace default content.                                        | NO       | ((props: [PageContentProps](./src/types.ts#L87)) =\u003e React.ReactNode) \\| React.ReactNode |\n| image            | Image cover.                                                                                  | NO       | (() =\u003e React.ReactNode) \\| React.ReactNode                                              |\n| icon             | Indicator icon.                                                                               | NO       | (() =\u003e React.ReactNode) \\| React.ReactNode                                              |\n| backgroundColor  | Background color.                                                                             | YES      | string                                                                                  |\n| title            | Title text.                                                                                   | NO       | string                                                                                  |\n| description      | Description text.                                                                             | NO       | string                                                                                  |\n| titleStyle       | Text style to override page/slide title default style.                                        | NO       | StyleProp\u003cTextStyle\u003e                                                                    |\n| descriptionStyle | Text style to override page/slide description default style.                                  | NO       | StyleProp\u003cTextStyle\u003e                                                                    |\n| showCloseButton  | Show close button when page/slide is active, _note: last page will always show close button._ | NO       | boolean                                                                                 |\n\n## Methods\n\n| name     | description                | type       |\n| -------- | -------------------------- | ---------- |\n| next     | Navigate to next page.     | () =\u003e void |\n| previous | Navigate to previous page. | () =\u003e void |\n\n## Author\n\n- [Mo Gorhom](https://twitter.com/gorhom)\n\n## Sponsor \u0026 Support\n\nTo keep this library maintained and up-to-date please consider [sponsoring it on GitHub](https://github.com/sponsors/gorhom). Or if you are looking for a private support or help in customizing the experience, then reach out to me on Twitter [@gorhom](https://twitter.com/gorhom).\n\n## License\n\n[MIT](./LICENSE)\n\n## Built With ❤️\n\n- [react-native-gesture-handler](https://github.com/software-mansion/react-native-gesture-handler)\n- [react-native-reanimated](https://github.com/software-mansion/react-native-reanimated)\n- [react-native-redash](https://github.com/wcandillon/react-native-redash)\n- [react-native-svg](https://github.com/react-native-community/react-native-svg)\n- [@react-native-community/bob](https://github.com/react-native-community/bob)\n\n---\n\n\u003cp align=\"center\"\u003e\n\u003ca href=\"https://gorhom.dev\" target=\"_blank\"\u003e\u003cimg height=\"18\" alt=\"Mo Gorhom\" src=\"./logo.png\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgorhom%2Freact-native-paper-onboarding","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgorhom%2Freact-native-paper-onboarding","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgorhom%2Freact-native-paper-onboarding/lists"}