├── .circleci └── config.yml ├── .editorconfig ├── .gitattributes ├── .gitignore ├── .npmrc ├── .yarnrc ├── CHANGELOG.md ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── android ├── build.gradle └── src │ └── main │ ├── AndroidManifest.xml │ └── java │ └── com │ └── reactnativewalletmanager │ ├── WalletManagerModule.java │ └── WalletManagerPackage.java ├── babel.config.js ├── docs ├── android.gif ├── android.webm ├── companyLogo.png ├── ios.gif ├── logo.png ├── logoAndroid.png └── stripe.png ├── example ├── Run ├── android │ ├── app │ │ ├── build.gradle │ │ ├── debug.keystore │ │ ├── proguard-rules.pro │ │ └── src │ │ │ ├── debug │ │ │ ├── AndroidManifest.xml │ │ │ └── java │ │ │ │ └── com │ │ │ │ └── example │ │ │ │ └── reactnativewalletmanager │ │ │ │ └── ReactNativeFlipper.java │ │ │ └── main │ │ │ ├── AndroidManifest.xml │ │ │ ├── java │ │ │ └── com │ │ │ │ └── example │ │ │ │ └── reactnativewalletmanager │ │ │ │ ├── MainActivity.java │ │ │ │ └── MainApplication.java │ │ │ └── res │ │ │ ├── mipmap-hdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ └── values │ │ │ ├── strings.xml │ │ │ └── styles.xml │ ├── build.gradle │ ├── gradle.properties │ ├── gradle │ │ └── wrapper │ │ │ ├── gradle-wrapper.jar │ │ │ └── gradle-wrapper.properties │ ├── gradlew │ ├── gradlew.bat │ └── settings.gradle ├── app.json ├── babel.config.js ├── index.tsx ├── ios │ ├── File.swift │ ├── Podfile │ ├── Podfile.lock │ ├── WalletManagerExample-Bridging-Header.h │ ├── WalletManagerExample.xcodeproj │ │ ├── project.pbxproj │ │ └── xcshareddata │ │ │ └── xcschemes │ │ │ └── WalletManagerExample.xcscheme │ ├── WalletManagerExample.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ │ └── IDEWorkspaceChecks.plist │ └── WalletManagerExample │ │ ├── AppDelegate.h │ │ ├── AppDelegate.m │ │ ├── Images.xcassets │ │ ├── AppIcon.appiconset │ │ │ └── Contents.json │ │ └── Contents.json │ │ ├── Info.plist │ │ ├── LaunchScreen.storyboard │ │ ├── WalletManagerExample.entitlements │ │ └── main.m ├── metro.config.js ├── package.json ├── resources │ ├── SamplePasses │ │ ├── BoardingPass.pass │ │ │ ├── icon.png │ │ │ ├── icon@2x.png │ │ │ ├── logo.png │ │ │ ├── logo@2x.png │ │ │ └── pass.json │ │ ├── BoardingPass.pkpass │ │ ├── Coupon.pass │ │ │ ├── icon.png │ │ │ ├── icon@2x.png │ │ │ ├── logo.png │ │ │ ├── logo@2x.png │ │ │ └── pass.json │ │ ├── Coupon.pkpass │ │ ├── Event.pass │ │ │ ├── background.png │ │ │ ├── background@2x.png │ │ │ ├── icon.png │ │ │ ├── icon@2x.png │ │ │ ├── logo.png │ │ │ ├── logo@2x.png │ │ │ ├── pass.json │ │ │ ├── thumbnail.png │ │ │ └── thumbnail@2x.png │ │ ├── Event.pkpass │ │ ├── Generic.pass │ │ │ ├── icon.png │ │ │ ├── icon@2x.png │ │ │ ├── logo.png │ │ │ ├── logo@2x.png │ │ │ ├── pass.json │ │ │ ├── thumbnail.png │ │ │ └── thumbnail@2x.png │ │ ├── Generic.pkpass │ │ ├── StoreCard.pass │ │ │ ├── icon.png │ │ │ ├── icon@2x.png │ │ │ ├── logo.png │ │ │ ├── pass.json │ │ │ ├── strip.png │ │ │ └── strip@2x.png │ │ └── StoreCard.pkpass │ └── pass.pkpass ├── src │ ├── App.tsx │ └── WalletButton.tsx └── yarn.lock ├── ios ├── WalletManager.h ├── WalletManager.m └── WalletManager.xcodeproj │ └── project.pbxproj ├── package.json ├── react-native-wallet-manager.podspec ├── scripts └── bootstrap.js ├── src ├── __tests__ │ └── index.test.tsx └── index.tsx ├── tsconfig.build.json ├── tsconfig.json └── yarn.lock /.circleci/config.yml: -------------------------------------------------------------------------------- 1 | version: 2.1 2 | 3 | executors: 4 | default: 5 | docker: 6 | - image: circleci/node:10 7 | working_directory: ~/project 8 | 9 | commands: 10 | attach_project: 11 | steps: 12 | - attach_workspace: 13 | at: ~/project 14 | 15 | jobs: 16 | install-dependencies: 17 | executor: default 18 | steps: 19 | - checkout 20 | - attach_project 21 | - restore_cache: 22 | keys: 23 | - dependencies-{{ checksum "package.json" }} 24 | - dependencies- 25 | - restore_cache: 26 | keys: 27 | - dependencies-example-{{ checksum "example/package.json" }} 28 | - dependencies-example- 29 | - run: 30 | name: Install dependencies 31 | command: | 32 | yarn install --cwd example --frozen-lockfile 33 | yarn install --frozen-lockfile 34 | - save_cache: 35 | key: dependencies-{{ checksum "package.json" }} 36 | paths: node_modules 37 | - save_cache: 38 | key: dependencies-example-{{ checksum "example/package.json" }} 39 | paths: example/node_modules 40 | - persist_to_workspace: 41 | root: . 42 | paths: . 43 | 44 | lint: 45 | executor: default 46 | steps: 47 | - attach_project 48 | - run: 49 | name: Lint files 50 | command: | 51 | yarn lint 52 | 53 | typescript: 54 | executor: default 55 | steps: 56 | - attach_project 57 | - run: 58 | name: Typecheck files 59 | command: | 60 | yarn typescript 61 | 62 | unit-tests: 63 | executor: default 64 | steps: 65 | - attach_project 66 | - run: 67 | name: Run unit tests 68 | command: | 69 | yarn test --coverage 70 | - store_artifacts: 71 | path: coverage 72 | destination: coverage 73 | 74 | build-package: 75 | executor: default 76 | steps: 77 | - attach_project 78 | - run: 79 | name: Build package 80 | command: | 81 | yarn prepare 82 | 83 | workflows: 84 | build-and-test: 85 | jobs: 86 | - install-dependencies 87 | - lint: 88 | requires: 89 | - install-dependencies 90 | - typescript: 91 | requires: 92 | - install-dependencies 93 | - unit-tests: 94 | requires: 95 | - install-dependencies 96 | - build-package: 97 | requires: 98 | - install-dependencies 99 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | # EditorConfig helps developers define and maintain consistent 2 | # coding styles between different editors and IDEs 3 | # editorconfig.org 4 | 5 | root = true 6 | 7 | [*] 8 | 9 | indent_style = space 10 | indent_size = 2 11 | 12 | end_of_line = lf 13 | charset = utf-8 14 | trim_trailing_whitespace = true 15 | insert_final_newline = true 16 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | *.pbxproj -text 2 | # specific for windows script files 3 | *.bat text eol=crlf -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # OSX 2 | # 3 | .DS_Store 4 | 5 | # XDE 6 | .expo/ 7 | 8 | # VSCode 9 | .vscode/ 10 | jsconfig.json 11 | 12 | # Xcode 13 | # 14 | build/ 15 | *.pbxuser 16 | !default.pbxuser 17 | *.mode1v3 18 | !default.mode1v3 19 | *.mode2v3 20 | !default.mode2v3 21 | *.perspectivev3 22 | !default.perspectivev3 23 | xcuserdata 24 | *.xccheckout 25 | *.moved-aside 26 | DerivedData 27 | *.hmap 28 | *.ipa 29 | *.xcuserstate 30 | project.xcworkspace 31 | 32 | # Android/IJ 33 | # 34 | .idea 35 | .gradle 36 | local.properties 37 | android.iml 38 | 39 | # Cocoapods 40 | # 41 | example/ios/Pods 42 | 43 | # node.js 44 | # 45 | node_modules/ 46 | npm-debug.log 47 | yarn-debug.log 48 | yarn-error.log 49 | 50 | # BUCK 51 | buck-out/ 52 | \.buckd/ 53 | android/app/libs 54 | android/keystores/debug.keystore 55 | 56 | # Expo 57 | .expo/* 58 | 59 | # generated by bob 60 | lib/ 61 | -------------------------------------------------------------------------------- /.npmrc: -------------------------------------------------------------------------------- 1 | @dev-family:registry=https://npm.pkg.github.com -------------------------------------------------------------------------------- /.yarnrc: -------------------------------------------------------------------------------- 1 | # Override Yarn command so we can automatically setup the repo on running `yarn` 2 | 3 | yarn-path "scripts/bootstrap.js" 4 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # Changelog 2 | 3 | ## v0.0.2 4 | 5 | ### Added 6 | 7 | - Added a method that allows user to view the added Pass into the wallet ([c4e7dabb5aebf1f7176cf3815436156648025ffa](https://github.com/dev-family/react-native-wallet-manager/pull/1/commits/c4e7dabb5aebf1f7176cf3815436156648025ffa) by [@pratikkishornaik](https://github.com/pratikkishornaik)) 8 | 9 | ## v0.0.3 10 | 11 | ### Added 12 | 13 | - Add suport for new versions of RN on android side. ([17bc045ae5b37e1d142bc94ffa7e5693973730c9](https://github.com/dev-family/react-native-wallet-manager/pull/11/commits/17bc045ae5b37e1d142bc94ffa7e5693973730c9) by [@LucasVeloz](https://github.com/LucasVeloz)) 14 | 15 | ## v0.0.4 16 | 17 | ### Added 18 | 19 | - Adds ability to check for iOS PKAddPassesViewController canAddPasses method. ([1b8c5c4f79a34820f6e3a709240f26b3e247b53f](https://github.com/dev-family/react-native-wallet-manager/pull/11/commits/1b8c5c4f79a34820f6e3a709240f26b3e247b53f) by [@brantleyenglish](https://github.com/brantleyenglish)) 20 | 21 | ## v0.0.5 22 | 23 | ### Added 24 | 25 | - Added support to android target SDK v 33. ([6470e80ebae77019cb29c4213a60deb9b7bfb06c](https://github.com/dev-family/react-native-wallet-manager/pull/15/commits/6470e80ebae77019cb29c4213a60deb9b7bfb06c) by [@ferencik-f](https://github.com/ferencik-f)) 26 | 27 | ## v0.0.6 28 | 29 | ### Added 30 | 31 | - Added support for React Native 0.73 on android. ([86776d5fa9d3ef9ccccb98db6387d3e361471ae6](https://github.com/dev-family/react-native-wallet-manager/pull/18/commits/86776d5fa9d3ef9ccccb98db6387d3e361471ae6) by [@LucasVeloz](https://github.com/LucasVeloz)) 32 | 33 | ## v0.0.7 34 | 35 | ### Added 36 | 37 | - Added showAddPassControllerFromFile method for iOS platform to pass in local filepath of .pkpass. ([f989b785d8e54f4642dba74226850b9d24b10508](https://github.com/dev-family/react-native-wallet-manager/pull/21/commits/f989b785d8e54f4642dba74226850b9d24b10508) by [@devt259](https://github.com/devt259)) 38 | 39 | ## v1.1.0 40 | 41 | ### Added 42 | 43 | - **Google Wallet**: added new methods for Android: 44 | - **addPassToGoogleWallet** method to add passes to Google Wallet. 45 | - **canAddPasses** method to verify if Google Wallet is supported on the device. 46 | 47 | ### Updated 48 | 49 | - **Documentation**: completely revamped for improved usability and structure. 50 | - Detailed sections added for using the new Google Wallet methods. 51 | - Improved navigation and added step-by-step examples. 52 | 53 | ### Fixed 54 | 55 | - **Examples**: updated code examples for all new features, including integration with Google Wallet on Android. 56 | 57 | ## v1.1.1 58 | 59 | ### Fixed 60 | 61 | - Replaced **dispatch_get_main_queue** with **dispatch_get_global_queue** in methods **addPassFromUrl** and **showAddPassControllerFromFile** to fix the app crashed, if Wallet not installed. ([e4766ca091e09b1234c027640c04f34e0307bd17](https://github.com/dev-family/react-native-wallet-manager/pull/30/commits/e4766ca091e09b1234c027640c04f34e0307bd17) by [@ghorbani-m](https://github.com/ghorbani-m)) 62 | -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | # Contributing 2 | 3 | We want this community to be friendly and respectful to each other. Please follow it in all your interactions with the project. 4 | 5 | ## Development workflow 6 | 7 | To get started with the project, run `yarn` in the root directory to install the required dependencies for each package: 8 | 9 | ```sh 10 | yarn 11 | ``` 12 | 13 | > While it's possible to use [`npm`](https://github.com/npm/cli), the tooling is built around [`yarn`](https://classic.yarnpkg.com/), so you'll have an easier time if you use `yarn` for development. 14 | 15 | While developing, you can run the [example app](/example/) to test your changes. Any changes you make in your library's JavaScript code will be reflected in the example app without a rebuild. If you change any native code, then you'll need to rebuild the example app. 16 | 17 | To start the packager: 18 | 19 | ```sh 20 | yarn example start 21 | ``` 22 | 23 | To run the example app on Android: 24 | 25 | ```sh 26 | yarn example android 27 | ``` 28 | 29 | To run the example app on iOS: 30 | 31 | ```sh 32 | yarn example ios 33 | ``` 34 | 35 | Make sure your code passes TypeScript and ESLint. Run the following to verify: 36 | 37 | ```sh 38 | yarn typescript 39 | yarn lint 40 | ``` 41 | 42 | To fix formatting errors, run the following: 43 | 44 | ```sh 45 | yarn lint --fix 46 | ``` 47 | 48 | Remember to add tests for your change if possible. Run the unit tests by: 49 | 50 | ```sh 51 | yarn test 52 | ``` 53 | 54 | To edit the Objective-C files, open `example/ios/WalletManagerExample.xcworkspace` in XCode and find the source files at `Pods > Development Pods > react-native-wallet-manager`. 55 | 56 | To edit the Kotlin files, open `example/android` in Android studio and find the source files at `reactnativewalletmanager` under `Android`. 57 | 58 | ### Commit message convention 59 | 60 | We follow the [conventional commits specification](https://www.conventionalcommits.org/en) for our commit messages: 61 | 62 | - `fix`: bug fixes, e.g. fix crash due to deprecated method. 63 | - `feat`: new features, e.g. add new method to the module. 64 | - `refactor`: code refactor, e.g. migrate from class components to hooks. 65 | - `docs`: changes into documentation, e.g. add usage example for the module.. 66 | - `test`: adding or updating tests, e.g. add integration tests using detox. 67 | - `chore`: tooling changes, e.g. change CI config. 68 | 69 | Our pre-commit hooks verify that your commit message matches this format when committing. 70 | 71 | ### Linting and tests 72 | 73 | [ESLint](https://eslint.org/), [Prettier](https://prettier.io/), [TypeScript](https://www.typescriptlang.org/) 74 | 75 | We use [TypeScript](https://www.typescriptlang.org/) for type checking, [ESLint](https://eslint.org/) with [Prettier](https://prettier.io/) for linting and formatting the code, and [Jest](https://jestjs.io/) for testing. 76 | 77 | Our pre-commit hooks verify that the linter and tests pass when committing. 78 | 79 | ### Publishing to npm 80 | 81 | We use [release-it](https://github.com/release-it/release-it) to make it easier to publish new versions. It handles common tasks like bumping version based on semver, creating tags and releases etc. 82 | 83 | To publish new versions, run the following: 84 | 85 | ```sh 86 | yarn release 87 | ``` 88 | 89 | ### Scripts 90 | 91 | The `package.json` file contains various scripts for common tasks: 92 | 93 | - `yarn bootstrap`: setup project by installing all dependencies and pods. 94 | - `yarn typescript`: type-check files with TypeScript. 95 | - `yarn lint`: lint files with ESLint. 96 | - `yarn test`: run unit tests with Jest. 97 | - `yarn example start`: start the Metro server for the example app. 98 | - `yarn example android`: run the example app on Android. 99 | - `yarn example ios`: run the example app on iOS. 100 | 101 | ### Sending a pull request 102 | 103 | > **Working on your first pull request?** You can learn how from this _free_ series: [How to Contribute to an Open Source Project on GitHub](https://egghead.io/series/how-to-contribute-to-an-open-source-project-on-github). 104 | 105 | When you're sending a pull request: 106 | 107 | - Prefer small pull requests focused on one change. 108 | - Verify that linters and tests are passing. 109 | - Review the documentation to make sure it looks good. 110 | - Follow the pull request template when opening a pull request. 111 | - For pull requests that change the API or implementation, discuss with maintainers first by opening an issue. 112 | 113 | ## Code of Conduct 114 | 115 | ### Our Pledge 116 | 117 | We as members, contributors, and leaders pledge to make participation in our community a harassment-free experience for everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, religion, or sexual identity and orientation. 118 | 119 | We pledge to act and interact in ways that contribute to an open, welcoming, diverse, inclusive, and healthy community. 120 | 121 | ### Our Standards 122 | 123 | Examples of behavior that contributes to a positive environment for our community include: 124 | 125 | - Demonstrating empathy and kindness toward other people 126 | - Being respectful of differing opinions, viewpoints, and experiences 127 | - Giving and gracefully accepting constructive feedback 128 | - Accepting responsibility and apologizing to those affected by our mistakes, and learning from the experience 129 | - Focusing on what is best not just for us as individuals, but for the overall community 130 | 131 | Examples of unacceptable behavior include: 132 | 133 | - The use of sexualized language or imagery, and sexual attention or 134 | advances of any kind 135 | - Trolling, insulting or derogatory comments, and personal or political attacks 136 | - Public or private harassment 137 | - Publishing others' private information, such as a physical or email 138 | address, without their explicit permission 139 | - Other conduct which could reasonably be considered inappropriate in a 140 | professional setting 141 | 142 | ### Enforcement Responsibilities 143 | 144 | Community leaders are responsible for clarifying and enforcing our standards of acceptable behavior and will take appropriate and fair corrective action in response to any behavior that they deem inappropriate, threatening, offensive, or harmful. 145 | 146 | Community leaders have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, and will communicate reasons for moderation decisions when appropriate. 147 | 148 | ### Scope 149 | 150 | This Code of Conduct applies within all community spaces, and also applies when an individual is officially representing the community in public spaces. Examples of representing our community include using an official e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. 151 | 152 | ### Enforcement 153 | 154 | Instances of abusive, harassing, or otherwise unacceptable behavior may be reported to the community leaders responsible for enforcement at [INSERT CONTACT METHOD]. All complaints will be reviewed and investigated promptly and fairly. 155 | 156 | All community leaders are obligated to respect the privacy and security of the reporter of any incident. 157 | 158 | ### Enforcement Guidelines 159 | 160 | Community leaders will follow these Community Impact Guidelines in determining the consequences for any action they deem in violation of this Code of Conduct: 161 | 162 | #### 1. Correction 163 | 164 | **Community Impact**: Use of inappropriate language or other behavior deemed unprofessional or unwelcome in the community. 165 | 166 | **Consequence**: A private, written warning from community leaders, providing clarity around the nature of the violation and an explanation of why the behavior was inappropriate. A public apology may be requested. 167 | 168 | #### 2. Warning 169 | 170 | **Community Impact**: A violation through a single incident or series of actions. 171 | 172 | **Consequence**: A warning with consequences for continued behavior. No interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, for a specified period of time. This includes avoiding interactions in community spaces as well as external channels like social media. Violating these terms may lead to a temporary or permanent ban. 173 | 174 | #### 3. Temporary Ban 175 | 176 | **Community Impact**: A serious violation of community standards, including sustained inappropriate behavior. 177 | 178 | **Consequence**: A temporary ban from any sort of interaction or public communication with the community for a specified period of time. No public or private interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, is allowed during this period. Violating these terms may lead to a permanent ban. 179 | 180 | #### 4. Permanent Ban 181 | 182 | **Community Impact**: Demonstrating a pattern of violation of community standards, including sustained inappropriate behavior, harassment of an individual, or aggression toward or disparagement of classes of individuals. 183 | 184 | **Consequence**: A permanent ban from any sort of public interaction within the community. 185 | 186 | ### Attribution 187 | 188 | This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 2.0, 189 | available at https://www.contributor-covenant.org/version/2/0/code_of_conduct.html. 190 | 191 | Community Impact Guidelines were inspired by [Mozilla's code of conduct enforcement ladder](https://github.com/mozilla/diversity). 192 | 193 | [homepage]: https://www.contributor-covenant.org 194 | 195 | For answers to common questions about this code of conduct, see the FAQ at 196 | https://www.contributor-covenant.org/faq. Translations are available at https://www.contributor-covenant.org/translations. 197 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2021 dev.family 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | # react-native-wallet-manager 4 | 5 | This library provides integration with both Apple Wallet on iOS and Google Wallet on Android. It allows you to add, remove, and check for existing passes on iOS, and add passes to Google Wallet on Android. 6 | 7 | [![npm version](https://badge.fury.io/js/react-native-wallet-manager.svg)](https://www.npmjs.org/package/react-native-wallet-manager) 8 | [![npm](https://img.shields.io/npm/dt/react-native-wallet-manager.svg)](https://www.npmjs.org/package/react-native-wallet-manager) 9 | [![MIT](https://img.shields.io/dub/l/vibe-d.svg)](https://opensource.org/licenses/MIT) 10 |
11 | [![Platform - Android](https://img.shields.io/badge/platform-Android-3ddc84.svg?style=flat&logo=android)](https://www.android.com) 12 | [![Platform - iOS](https://img.shields.io/badge/platform-iOS-000.svg?style=flat&logo=apple)](https://developer.apple.com/ios) 13 | 14 | 15 | Twitter 16 | 17 | 18 | | | | 19 | | :-------------------------------------------------------------------------------------------------------------------------------: | :--------------------------------------------------------------------------------------------------------------------------------------------------------: | 20 | | iOS | Android | 21 | 22 | ## Installation 23 | 24 | ```sh 25 | yarn add react-native-wallet-manager 26 | ``` 27 | 28 | or 29 | 30 | ```sh 31 | npm install react-native-wallet-manager 32 | ``` 33 | 34 | ## Setup 35 | 36 | ### iOS 37 | 38 | To enable the Wallet functionality on iOS, you need to add the Wallet capability in Xcode. Follow these steps: 39 | 40 | 1. Open your project in Xcode (`xcworkspace` file). 41 | 42 | 2. Select your project **Target**. 43 | 3. Go to the **Signing & Capabilities** tab. 44 | 4. Click on **+ Capability** to add a new capability. 45 | 5. In the search bar, type **Wallet** and add it to your project. 46 | 47 | After that, navigate to the `ios` folder in your project directory and run the following command to install necessary dependencies: 48 | 49 | ```bash 50 | cd ios && pod install 51 | ``` 52 | 53 | ### Android 54 | 55 | To enable Google Wallet functionality on Android, you need to add the Google Play Services dependency to your project. Follow these steps: 56 | 57 | 1. Open the `android/app/build.gradle` file in your project. 58 | 2. In the `dependencies` section, add the following line with the latest version of `play-services-pay`: 59 | 60 | ```bash 61 | implementation "com.google.android.gms:play-services-pay:" 62 | ``` 63 | 64 | Replace `` with the most recent version number available. You can find the latest version on the [Google Play Services release notes page](https://developers.google.com/android/guides/releases). 65 | 66 | ## Usage 67 | 68 | For platform-specific instructions on how to create passes: 69 | 70 | - **iOS**: For a detailed guide on creating Apple Wallet pkpasses visit [this Medium article](https://medium.com/@dev.family/how-to-integrate-apple-wallet-into-the-mobile-app-54700346beb1). 71 | - **Android**: You can find a detailed guide on creating passes for Google Wallet at [this Google Codelab](https://codelabs.developers.google.com/add-to-wallet-web). 72 | 73 | To use this library, start by importing it into your React Native component: 74 | 75 | ```javascript 76 | import WalletManager from 'react-native-wallet-manager'; 77 | ``` 78 | 79 | ## API 80 | 81 | | Method | Parameters | iOS | Android | 82 | | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------- | --- | ------- | 83 | | [`canAddPasses()`](#canaddpasses) | None | ✅ | ✅ | 84 | | [`addPassToGoogleWallet(jwt: string)`](#addpasstogooglewalletjwt-string) | `jwt: string` | ❌ | ✅ | 85 | | [`addPassFromUrl(url: string)`](#addpassfromurlurl-string) | `url: string` | ✅ | ✅ | 86 | | [`hasPass(cardIdentifier: string, serialNumber?: string)`](#haspasscardidentifier-string-serialnumber-string) | `cardIdentifier: string, serialNumber?: string` | ✅ | ❌ | 87 | | [`removePass(cardIdentifier: string, serialNumber?: string)`](#removepasscardidentifier-string-serialnumber-string) | `cardIdentifier: string, serialNumber?: string` | ✅ | ❌ | 88 | | [`viewInWallet(cardIdentifier: string, serialNumber?: string)`](#viewinwalletcardidentifier-string-serialnumber-string) | `cardIdentifier: string, serialNumber?: string` | ✅ | ❌ | 89 | | [`showViewControllerWithData(filePath: string)`](#showviewcontrollerwithdatafilepath-string) | `filePath: string` | ✅ | ❌ | 90 | 91 | ### Notes 92 | 93 | All methods return a `Promise` that resolves with the result of the operation or rejects if an error occurs. 94 | 95 | ## canAddPasses() 96 | 97 | Checks if the device can add passes to the wallet. This method is supported on both iOS and Android. 98 | 99 | ### Example 100 | 101 | ```javascript 102 | const canAddPasses = async () => { 103 | try { 104 | const result = await WalletManager.canAddPasses(); 105 | console.log(result); 106 | } catch (e) { 107 | console.log(e); 108 | } 109 | }; 110 | ``` 111 | 112 | ## addPassToGoogleWallet(jwt: string) 113 | 114 | Adds a pass to Google Wallet. This method is only supported on Android. 115 | 116 | ### Parameters 117 | 118 | - `jwt` (string): The JWT token containing the pass information to be added to Google Wallet. 119 | 120 | _Note:_ In the example below, you'll see a placeholder for the JWT. You need to generate a valid Google Wallet JWT for testing purposes. 121 | 122 | ### Example 123 | 124 | ```javascript 125 | const addPassToGoogleWallet = async () => { 126 | try { 127 | await WalletManager.addPassToGoogleWallet( 128 | 'eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9...' 129 | ); 130 | } catch (e) { 131 | console.log(e); 132 | } 133 | }; 134 | ``` 135 | 136 | ## addPassFromUrl(url: string) 137 | 138 | Adds a pass from a specified URL. This method is supported on both iOS and Android. 139 | 140 | - On iOS, it will add the pass to Apple Wallet. 141 | - On Android, it will open the URL in a browser. 142 | 143 | ### Parameters 144 | 145 | - `url` (string): The URL of the pass file (`.pkpass` file) to be added. 146 | 147 | ### Examples 148 | 149 | ```javascript 150 | const addPass = async () => { 151 | try { 152 | const result = await WalletManager.addPassFromUrl( 153 | 'https://github.com/dev-family/react-native-wallet-manager/blob/main/example/resources/pass.pkpass?raw=true' 154 | ); 155 | console.log(result); 156 | } catch (e) { 157 | console.log(e); 158 | } 159 | }; 160 | ``` 161 | 162 | ## hasPass(cardIdentifier: string, serialNumber?: string) 163 | 164 | Checks if a pass with a specific identifier exists in the Apple Wallet. This method is only supported on iOS. 165 | 166 | ### Parameters 167 | 168 | - `cardIdentifier` (string): The unique identifier of the pass to check. 169 | - `serialNumber` (string, optional): The serial number of the pass. This parameter is optional and can be used to further specify the pass. 170 | 171 | ### Example 172 | 173 | ```javascript 174 | const hasPass = async () => { 175 | try { 176 | const result = await WalletManager.hasPass('pass.family.dev.walletManager'); 177 | console.log(`has pass: ${result}`); 178 | } catch (e) { 179 | console.log(e, 'hasPass'); 180 | } 181 | }; 182 | ``` 183 | 184 | ## removePass(cardIdentifier: string, serialNumber?: string) 185 | 186 | Removes a pass with a specific identifier from the Apple Wallet. This method is only supported on iOS. 187 | 188 | ### Parameters 189 | 190 | - `cardIdentifier` (string): The unique identifier of the pass to remove. 191 | - `serialNumber` (string, optional): The serial number of the pass. This parameter is optional and can be used to further specify the pass. 192 | 193 | ### Example 194 | 195 | ```javascript 196 | const removePass = async () => { 197 | try { 198 | const result = await WalletManager.removePass( 199 | 'pass.family.dev.walletManager' 200 | ); 201 | console.log(`remove pass: ${result}`); 202 | } catch (e) { 203 | console.log(e, 'removePass'); 204 | } 205 | }; 206 | ``` 207 | 208 | ## viewInWallet(cardIdentifier: string, serialNumber?: string) 209 | 210 | Opens a pass with a specific identifier in Apple Wallet. This method is only supported on iOS. 211 | 212 | ### Parameters 213 | 214 | - `cardIdentifier` (string): The unique identifier of the pass to view. 215 | - `serialNumber` (string, optional): The serial number of the pass. This parameter is optional and can be used to further specify the pass. 216 | 217 | ### Example 218 | 219 | ```javascript 220 | const viewPass = async () => { 221 | try { 222 | const result = await WalletManager.viewInWallet( 223 | 'pass.family.dev.walletManager' 224 | ); 225 | console.log(result); 226 | } catch (e) { 227 | console.log(e, 'error Viewing Pass'); 228 | } 229 | }; 230 | ``` 231 | 232 | ## showViewControllerWithData(filePath: string) 233 | 234 | Displays a view controller to add a pass using the data from the specified file path. This method is only supported on iOS. 235 | 236 | ### Parameters 237 | 238 | - `filePath` (string): The path to the `.pkpass` file containing the pass data to be added to Apple Wallet. 239 | 240 | ### Example 241 | 242 | ```javascript 243 | const showViewControllerWithData = async (filePath) => { 244 | try { 245 | const result = await WalletManager.showViewControllerWithData(filePath); 246 | console.log(`Pass was added: ${result}`); 247 | } catch (e) { 248 | console.error('Error displaying pass view controller:', e); 249 | } 250 | }; 251 | ``` 252 | 253 | Project inspired by [react-native-wallet](https://www.npmjs.com/package/react-native-wallet) 254 | 255 | ## Contributing 256 | 257 | See the [contributing guide](CONTRIBUTING.md) to learn how to contribute to the repository and the development workflow. 258 | 259 | ## License 260 | 261 | MIT 262 | -------------------------------------------------------------------------------- /android/build.gradle: -------------------------------------------------------------------------------- 1 | buildscript { 2 | if (project == rootProject) { 3 | repositories { 4 | google() 5 | jcenter() 6 | } 7 | 8 | dependencies { 9 | classpath 'com.android.tools.build:gradle:3.5.3' 10 | 11 | } 12 | } 13 | } 14 | 15 | apply plugin: 'com.android.library' 16 | 17 | def safeExtGet(prop, fallback) { 18 | rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback 19 | } 20 | 21 | android { 22 | compileSdkVersion safeExtGet('WalletManager_compileSdkVersion', 34) 23 | buildToolsVersion safeExtGet('WalletManager_buildToolsVersion', '33.0.0') 24 | defaultConfig { 25 | minSdkVersion safeExtGet('WalletManager_minSdkVersion', 21) 26 | targetSdkVersion safeExtGet('WalletManager_targetSdkVersion', 33) 27 | versionCode 1 28 | versionName "1.0" 29 | 30 | } 31 | 32 | buildTypes { 33 | release { 34 | minifyEnabled false 35 | } 36 | } 37 | lintOptions { 38 | disable 'GradleCompatible' 39 | } 40 | compileOptions { 41 | sourceCompatibility JavaVersion.VERSION_1_8 42 | targetCompatibility JavaVersion.VERSION_1_8 43 | } 44 | } 45 | 46 | repositories { 47 | mavenLocal() 48 | maven { 49 | // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm 50 | url("$rootDir/../node_modules/react-native/android") 51 | } 52 | google() 53 | jcenter() 54 | } 55 | 56 | dependencies { 57 | //noinspection GradleDynamicVersion 58 | implementation "com.facebook.react:react-native:+" // From node_modules 59 | implementation 'com.google.android.gms:play-services-pay:16.5.0' 60 | implementation "com.google.android.gms:play-services-wallet:19.4.0" 61 | } 62 | -------------------------------------------------------------------------------- /android/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /android/src/main/java/com/reactnativewalletmanager/WalletManagerModule.java: -------------------------------------------------------------------------------- 1 | package com.reactnativewalletmanager; 2 | 3 | import androidx.annotation.NonNull; 4 | import android.app.Activity; 5 | import android.content.Context; 6 | import android.content.Intent; 7 | import android.content.pm.PackageManager; 8 | import android.util.Log; 9 | 10 | import com.facebook.react.bridge.ActivityEventListener; 11 | import com.facebook.react.bridge.BaseActivityEventListener; 12 | import com.facebook.react.bridge.Promise; 13 | import com.facebook.react.bridge.ReactApplicationContext; 14 | import com.facebook.react.bridge.ReactContextBaseJavaModule; 15 | import com.facebook.react.bridge.ReactMethod; 16 | import com.facebook.react.module.annotations.ReactModule; 17 | 18 | import com.google.android.gms.common.api.ApiException; 19 | import com.google.android.gms.common.api.CommonStatusCodes; 20 | import com.google.android.gms.tasks.OnFailureListener; 21 | import com.google.android.gms.tasks.OnSuccessListener; 22 | import com.google.android.gms.pay.PayClient; 23 | import com.google.android.gms.pay.Pay; 24 | import com.google.android.gms.pay.PayApiAvailabilityStatus; 25 | 26 | @ReactModule(name = WalletManagerModule.NAME) 27 | public class WalletManagerModule extends ReactContextBaseJavaModule { 28 | public static final String NAME = "WalletManager"; 29 | private final PayClient walletClient; 30 | private static final int addToGoogleWalletRequestCode = 1001; 31 | private Promise addPassPromise; 32 | 33 | public WalletManagerModule(@NonNull ReactApplicationContext reactContext) { 34 | super(reactContext); 35 | walletClient = Pay.getClient(reactContext); 36 | reactContext.addActivityEventListener(mActivityEventListener); 37 | } 38 | 39 | @Override 40 | @NonNull 41 | public String getName() { 42 | return NAME; 43 | } 44 | 45 | @ReactMethod 46 | public void canAddPasses(final Promise promise) { 47 | walletClient.getPayApiAvailabilityStatus(PayClient.RequestType.SAVE_PASSES) 48 | .addOnSuccessListener(new OnSuccessListener() { 49 | @Override 50 | public void onSuccess(Integer status) { 51 | if (status == PayApiAvailabilityStatus.AVAILABLE) { 52 | promise.resolve(true); 53 | } else { 54 | promise.resolve(false); 55 | } 56 | } 57 | }) 58 | .addOnFailureListener(new OnFailureListener() { 59 | @Override 60 | public void onFailure(@NonNull Exception e) { 61 | promise.reject("ERROR", "Error when checking the availability of the Google Wallet API: " + e.getMessage(), e); 62 | } 63 | }); 64 | } 65 | 66 | @ReactMethod 67 | public void addPassToGoogleWallet(String jwt, Promise promise) { 68 | Activity activity = getCurrentActivity(); 69 | if (activity != null) { 70 | this.addPassPromise = promise; 71 | try { 72 | walletClient.savePassesJwt(jwt, activity, addToGoogleWalletRequestCode); 73 | 74 | } catch (Exception e) { 75 | e.printStackTrace(); 76 | 77 | if (e instanceof com.google.android.gms.common.api.ApiException) { 78 | ApiException apiException = (ApiException) e; 79 | int statusCode = apiException.getStatusCode(); 80 | String statusMessage = com.google.android.gms.common.api.CommonStatusCodes.getStatusCodeString(statusCode); 81 | promise.reject("API_ERROR", "Google Pay API error occurred. Status code: " + statusCode + ", Message: " + statusMessage); 82 | } else { 83 | promise.reject("GENERAL_ERROR", "Error when saving to Google Wallet: " + e.getMessage(), e); 84 | } 85 | this.addPassPromise = null; 86 | } 87 | } else { 88 | String errorMessage = "Current activity is unavailable."; 89 | promise.reject("NO_ACTIVITY", errorMessage); 90 | } 91 | } 92 | 93 | private final ActivityEventListener mActivityEventListener = new BaseActivityEventListener() { 94 | @Override 95 | public void onActivityResult(Activity activity, int requestCode, int resultCode, Intent data) { 96 | if (requestCode == addToGoogleWalletRequestCode) { 97 | if (addPassPromise != null) { 98 | switch (resultCode) { 99 | case Activity.RESULT_OK: 100 | addPassPromise.resolve("Pass successfully added to Google Wallet"); 101 | break; 102 | case Activity.RESULT_CANCELED: 103 | addPassPromise.reject("RESULT_CANCELED", "The operation was canceled by the user."); 104 | break; 105 | default: 106 | String error = data != null ? data.getStringExtra("error") : "Unknown error"; 107 | addPassPromise.reject("UNKNOWN_ERROR", "An error occurred: " + error); 108 | break; 109 | } 110 | addPassPromise = null; 111 | } 112 | } 113 | } 114 | }; 115 | } 116 | -------------------------------------------------------------------------------- /android/src/main/java/com/reactnativewalletmanager/WalletManagerPackage.java: -------------------------------------------------------------------------------- 1 | package com.reactnativewalletmanager; 2 | 3 | import androidx.annotation.NonNull; 4 | 5 | import com.facebook.react.ReactPackage; 6 | import com.facebook.react.bridge.NativeModule; 7 | import com.facebook.react.bridge.ReactApplicationContext; 8 | import com.facebook.react.uimanager.ViewManager; 9 | 10 | import java.util.ArrayList; 11 | import java.util.Collections; 12 | import java.util.List; 13 | 14 | public class WalletManagerPackage implements ReactPackage { 15 | @NonNull 16 | @Override 17 | public List createNativeModules(@NonNull ReactApplicationContext reactContext) { 18 | List modules = new ArrayList<>(); 19 | modules.add(new WalletManagerModule(reactContext)); 20 | return modules; 21 | } 22 | 23 | @NonNull 24 | @Override 25 | public List createViewManagers(@NonNull ReactApplicationContext reactContext) { 26 | return Collections.emptyList(); 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: ['module:metro-react-native-babel-preset'], 3 | }; 4 | -------------------------------------------------------------------------------- /docs/android.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/docs/android.gif -------------------------------------------------------------------------------- /docs/android.webm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/docs/android.webm -------------------------------------------------------------------------------- /docs/companyLogo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/docs/companyLogo.png -------------------------------------------------------------------------------- /docs/ios.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/docs/ios.gif -------------------------------------------------------------------------------- /docs/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/docs/logo.png -------------------------------------------------------------------------------- /docs/logoAndroid.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/docs/logoAndroid.png -------------------------------------------------------------------------------- /docs/stripe.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/docs/stripe.png -------------------------------------------------------------------------------- /example/Run: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/Run -------------------------------------------------------------------------------- /example/android/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: "com.android.application" 2 | 3 | import com.android.build.OutputFile 4 | 5 | /** 6 | * The react.gradle file registers a task for each build variant (e.g. bundleDebugJsAndAssets 7 | * and bundleReleaseJsAndAssets). 8 | * These basically call `react-native bundle` with the correct arguments during the Android build 9 | * cycle. By default, bundleDebugJsAndAssets is skipped, as in debug/dev mode we prefer to load the 10 | * bundle directly from the development server. Below you can see all the possible configurations 11 | * and their defaults. If you decide to add a configuration block, make sure to add it before the 12 | * `apply from: "../../node_modules/react-native/react.gradle"` line. 13 | * 14 | * project.ext.react = [ 15 | * // the name of the generated asset file containing your JS bundle 16 | * bundleAssetName: "index.android.bundle", 17 | * 18 | * // the entry file for bundle generation 19 | * entryFile: "index.android.js", 20 | * 21 | * // https://reactnative.dev/docs/performance#enable-the-ram-format 22 | * bundleCommand: "ram-bundle", 23 | * 24 | * // whether to bundle JS and assets in debug mode 25 | * bundleInDebug: false, 26 | * 27 | * // whether to bundle JS and assets in release mode 28 | * bundleInRelease: true, 29 | * 30 | * // whether to bundle JS and assets in another build variant (if configured). 31 | * // See http://tools.android.com/tech-docs/new-build-system/user-guide#TOC-Build-Variants 32 | * // The configuration property can be in the following formats 33 | * // 'bundleIn${productFlavor}${buildType}' 34 | * // 'bundleIn${buildType}' 35 | * // bundleInFreeDebug: true, 36 | * // bundleInPaidRelease: true, 37 | * // bundleInBeta: true, 38 | * 39 | * // whether to disable dev mode in custom build variants (by default only disabled in release) 40 | * // for WalletManagerExample: to disable dev mode in the staging build type (if configured) 41 | * devDisabledInStaging: true, 42 | * // The configuration property can be in the following formats 43 | * // 'devDisabledIn${productFlavor}${buildType}' 44 | * // 'devDisabledIn${buildType}' 45 | * 46 | * // the root of your project, i.e. where "package.json" lives 47 | * root: "../../", 48 | * 49 | * // where to put the JS bundle asset in debug mode 50 | * jsBundleDirDebug: "$buildDir/intermediates/assets/debug", 51 | * 52 | * // where to put the JS bundle asset in release mode 53 | * jsBundleDirRelease: "$buildDir/intermediates/assets/release", 54 | * 55 | * // where to put drawable resources / React Native assets, e.g. the ones you use via 56 | * // require('./image.png')), in debug mode 57 | * resourcesDirDebug: "$buildDir/intermediates/res/merged/debug", 58 | * 59 | * // where to put drawable resources / React Native assets, e.g. the ones you use via 60 | * // require('./image.png')), in release mode 61 | * resourcesDirRelease: "$buildDir/intermediates/res/merged/release", 62 | * 63 | * // by default the gradle tasks are skipped if none of the JS files or assets change; this means 64 | * // that we don't look at files in android/ or ios/ to determine whether the tasks are up to 65 | * // date; if you have any other folders that you want to ignore for performance reasons (gradle 66 | * // indexes the entire tree), add them here. Alternatively, if you have JS files in android/ 67 | * // for WalletManagerExample, you might want to remove it from here. 68 | * inputExcludes: ["android/**", "ios/**"], 69 | * 70 | * // override which node gets called and with what additional arguments 71 | * nodeExecutableAndArgs: ["node"], 72 | * 73 | * // supply additional arguments to the packager 74 | * extraPackagerArgs: [] 75 | * ] 76 | */ 77 | 78 | project.ext.react = [ 79 | enableHermes: false, // clean and rebuild if changing 80 | entryFile: "index.tsx", 81 | ] 82 | 83 | apply from: "../../node_modules/react-native/react.gradle" 84 | 85 | /** 86 | * Set this to true to create two separate APKs instead of one: 87 | * - An APK that only works on ARM devices 88 | * - An APK that only works on x86 devices 89 | * The advantage is the size of the APK is reduced by about 4MB. 90 | * Upload all the APKs to the Play Store and people will download 91 | * the correct one based on the CPU architecture of their device. 92 | */ 93 | def enableSeparateBuildPerCPUArchitecture = false 94 | 95 | /** 96 | * Run Proguard to shrink the Java bytecode in release builds. 97 | */ 98 | def enableProguardInReleaseBuilds = false 99 | 100 | /** 101 | * The preferred build flavor of JavaScriptCore. 102 | * 103 | * For WalletManagerExample, to use the international variant, you can use: 104 | * `def jscFlavor = 'org.webkit:android-jsc-intl:+'` 105 | * 106 | * The international variant includes ICU i18n library and necessary data 107 | * allowing to use e.g. `Date.toLocaleString` and `String.localeCompare` that 108 | * give correct results when using with locales other than en-US. Note that 109 | * this variant is about 6MiB larger per architecture than default. 110 | */ 111 | def jscFlavor = 'org.webkit:android-jsc:+' 112 | 113 | /** 114 | * Whether to enable the Hermes VM. 115 | * 116 | * This should be set on project.ext.react and mirrored here. If it is not set 117 | * on project.ext.react, JavaScript will not be compiled to Hermes Bytecode 118 | * and the benefits of using Hermes will therefore be sharply reduced. 119 | */ 120 | def enableHermes = project.ext.react.get("enableHermes", false); 121 | 122 | android { 123 | namespace "com.example.reactnativewalletmanager" 124 | compileSdkVersion rootProject.ext.compileSdkVersion 125 | compileOptions { 126 | sourceCompatibility JavaVersion.VERSION_1_8 127 | targetCompatibility JavaVersion.VERSION_1_8 128 | } 129 | 130 | defaultConfig { 131 | 132 | minSdkVersion rootProject.ext.minSdkVersion 133 | targetSdkVersion rootProject.ext.targetSdkVersion 134 | versionCode 1 135 | versionName "1.0" 136 | } 137 | splits { 138 | abi { 139 | reset() 140 | enable enableSeparateBuildPerCPUArchitecture 141 | universalApk false // If true, also generate a universal APK 142 | include "armeabi-v7a", "x86", "arm64-v8a", "x86_64" 143 | } 144 | } 145 | signingConfigs { 146 | debug { 147 | storeFile file('debug.keystore') 148 | storePassword 'android' 149 | keyAlias 'androiddebugkey' 150 | keyPassword 'android' 151 | } 152 | } 153 | buildTypes { 154 | debug { 155 | signingConfig signingConfigs.debug 156 | } 157 | release { 158 | // Caution! In production, you need to generate your own keystore file. 159 | // see https://reactnative.dev/docs/signed-apk-android. 160 | signingConfig signingConfigs.debug 161 | minifyEnabled enableProguardInReleaseBuilds 162 | proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro" 163 | } 164 | } 165 | // applicationVariants are e.g. debug, release 166 | applicationVariants.all { variant -> 167 | variant.outputs.each { output -> 168 | // For each separate APK per architecture, set a unique version code as described here: 169 | // https://developer.android.com/studio/build/configure-apk-splits.html 170 | def versionCodes = ["armeabi-v7a": 1, "x86": 2, "arm64-v8a": 3, "x86_64": 4] 171 | def abi = output.getFilter(OutputFile.ABI) 172 | if (abi != null) { // null for the universal-debug, universal-release variants 173 | output.versionCodeOverride = 174 | versionCodes.get(abi) * 1048576 + defaultConfig.versionCode 175 | } 176 | 177 | } 178 | } 179 | } 180 | 181 | dependencies { 182 | implementation fileTree(dir: "libs", include: ["*.jar"]) 183 | //noinspection GradleDynamicVersion 184 | implementation "com.facebook.react:react-native:+" 185 | implementation 'com.google.android.gms:play-services-pay:16.5.0' 186 | implementation "com.google.android.gms:play-services-wallet:19.4.0" 187 | implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.0.0" 188 | debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}") { 189 | exclude group:'com.facebook.fbjni' 190 | } 191 | debugImplementation("com.facebook.flipper:flipper-network-plugin:${FLIPPER_VERSION}") { 192 | exclude group:'com.facebook.flipper' 193 | exclude group:'com.squareup.okhttp3', module:'okhttp' 194 | } 195 | debugImplementation("com.facebook.flipper:flipper-fresco-plugin:${FLIPPER_VERSION}") { 196 | exclude group:'com.facebook.flipper' 197 | } 198 | 199 | if (enableHermes) { 200 | def hermesPath = "../../node_modules/hermes-engine/android/"; 201 | debugImplementation files(hermesPath + "hermes-debug.aar") 202 | releaseImplementation files(hermesPath + "hermes-release.aar") 203 | } else { 204 | implementation jscFlavor 205 | } 206 | 207 | implementation project(':reactnativewalletmanager') 208 | } 209 | 210 | // Run this once to be able to run the application with BUCK 211 | // puts all compile dependencies into folder libs for BUCK to use 212 | task copyDownloadableDepsToLibs(type: Copy) { 213 | from configurations.implementation 214 | into 'libs' 215 | } 216 | 217 | apply from: file("../../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesAppBuildGradle(project) 218 | -------------------------------------------------------------------------------- /example/android/app/debug.keystore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/android/app/debug.keystore -------------------------------------------------------------------------------- /example/android/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /usr/local/Cellar/android-sdk/24.3.3/tools/proguard/proguard-android.txt 4 | # You can edit the include path and order by changing the proguardFiles 5 | # directive in build.gradle. 6 | # 7 | # For more details, see 8 | # http://developer.android.com/guide/developing/tools/proguard.html 9 | 10 | # Add any project specific keep options here: 11 | -------------------------------------------------------------------------------- /example/android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /example/android/app/src/debug/java/com/example/reactnativewalletmanager/ReactNativeFlipper.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) Facebook, Inc. and its affiliates. 3 | * 4 | *

This source code is licensed under the MIT license found in the LICENSE file in the root 5 | * directory of this source tree. 6 | */ 7 | package com.example.reactnativewalletmanager; 8 | 9 | import android.content.Context; 10 | import com.facebook.flipper.android.AndroidFlipperClient; 11 | import com.facebook.flipper.android.utils.FlipperUtils; 12 | import com.facebook.flipper.core.FlipperClient; 13 | import com.facebook.flipper.plugins.crashreporter.CrashReporterPlugin; 14 | import com.facebook.flipper.plugins.databases.DatabasesFlipperPlugin; 15 | import com.facebook.flipper.plugins.fresco.FrescoFlipperPlugin; 16 | import com.facebook.flipper.plugins.inspector.DescriptorMapping; 17 | import com.facebook.flipper.plugins.inspector.InspectorFlipperPlugin; 18 | import com.facebook.flipper.plugins.network.FlipperOkhttpInterceptor; 19 | import com.facebook.flipper.plugins.network.NetworkFlipperPlugin; 20 | import com.facebook.flipper.plugins.react.ReactFlipperPlugin; 21 | import com.facebook.flipper.plugins.sharedpreferences.SharedPreferencesFlipperPlugin; 22 | import com.facebook.react.ReactInstanceManager; 23 | import com.facebook.react.bridge.ReactContext; 24 | import com.facebook.react.modules.network.NetworkingModule; 25 | import okhttp3.OkHttpClient; 26 | 27 | public class ReactNativeFlipper { 28 | public static void initializeFlipper(Context context, ReactInstanceManager reactInstanceManager) { 29 | if (FlipperUtils.shouldEnableFlipper(context)) { 30 | final FlipperClient client = AndroidFlipperClient.getInstance(context); 31 | client.addPlugin(new InspectorFlipperPlugin(context, DescriptorMapping.withDefaults())); 32 | client.addPlugin(new ReactFlipperPlugin()); 33 | client.addPlugin(new DatabasesFlipperPlugin(context)); 34 | client.addPlugin(new SharedPreferencesFlipperPlugin(context)); 35 | client.addPlugin(CrashReporterPlugin.getInstance()); 36 | NetworkFlipperPlugin networkFlipperPlugin = new NetworkFlipperPlugin(); 37 | NetworkingModule.setCustomClientBuilder( 38 | new NetworkingModule.CustomClientBuilder() { 39 | @Override 40 | public void apply(OkHttpClient.Builder builder) { 41 | builder.addNetworkInterceptor(new FlipperOkhttpInterceptor(networkFlipperPlugin)); 42 | } 43 | }); 44 | client.addPlugin(networkFlipperPlugin); 45 | client.start(); 46 | // Fresco Plugin needs to ensure that ImagePipelineFactory is initialized 47 | // Hence we run if after all native modules have been initialized 48 | ReactContext reactContext = reactInstanceManager.getCurrentReactContext(); 49 | if (reactContext == null) { 50 | reactInstanceManager.addReactInstanceEventListener( 51 | new ReactInstanceManager.ReactInstanceEventListener() { 52 | @Override 53 | public void onReactContextInitialized(ReactContext reactContext) { 54 | reactInstanceManager.removeReactInstanceEventListener(this); 55 | reactContext.runOnNativeModulesQueueThread( 56 | new Runnable() { 57 | @Override 58 | public void run() { 59 | client.addPlugin(new FrescoFlipperPlugin()); 60 | } 61 | }); 62 | } 63 | }); 64 | } else { 65 | client.addPlugin(new FrescoFlipperPlugin()); 66 | } 67 | } 68 | } 69 | } 70 | -------------------------------------------------------------------------------- /example/android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | 13 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /example/android/app/src/main/java/com/example/reactnativewalletmanager/MainActivity.java: -------------------------------------------------------------------------------- 1 | package com.example.reactnativewalletmanager; 2 | 3 | import com.facebook.react.ReactActivity; 4 | 5 | public class MainActivity extends ReactActivity { 6 | 7 | /** 8 | * Returns the name of the main component registered from JavaScript. This is used to schedule 9 | * rendering of the component. 10 | */ 11 | @Override 12 | protected String getMainComponentName() { 13 | return "WalletManagerExample"; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /example/android/app/src/main/java/com/example/reactnativewalletmanager/MainApplication.java: -------------------------------------------------------------------------------- 1 | package com.example.reactnativewalletmanager; 2 | 3 | import android.app.Application; 4 | import android.content.Context; 5 | import com.facebook.react.PackageList; 6 | import com.facebook.react.ReactApplication; 7 | import com.facebook.react.ReactNativeHost; 8 | import com.facebook.react.ReactPackage; 9 | import com.facebook.react.ReactInstanceManager; 10 | import com.facebook.soloader.SoLoader; 11 | import java.lang.reflect.InvocationTargetException; 12 | import java.util.List; 13 | import com.reactnativewalletmanager.WalletManagerPackage; 14 | 15 | public class MainApplication extends Application implements ReactApplication { 16 | 17 | private final ReactNativeHost mReactNativeHost = 18 | new ReactNativeHost(this) { 19 | @Override 20 | public boolean getUseDeveloperSupport() { 21 | return BuildConfig.DEBUG; 22 | } 23 | 24 | @Override 25 | protected List getPackages() { 26 | @SuppressWarnings("UnnecessaryLocalVariable") 27 | List packages = new PackageList(this).getPackages(); 28 | // Packages that cannot be autolinked yet can be added manually here, for WalletManagerExample: 29 | // packages.add(new MyReactNativePackage()); 30 | packages.add(new WalletManagerPackage()); 31 | return packages; 32 | } 33 | 34 | @Override 35 | protected String getJSMainModuleName() { 36 | return "index"; 37 | } 38 | }; 39 | 40 | @Override 41 | public ReactNativeHost getReactNativeHost() { 42 | return mReactNativeHost; 43 | } 44 | 45 | @Override 46 | public void onCreate() { 47 | super.onCreate(); 48 | SoLoader.init(this, /* native exopackage */ false); 49 | initializeFlipper(this, getReactNativeHost().getReactInstanceManager()); // Remove this line if you don't want Flipper enabled 50 | } 51 | 52 | /** 53 | * Loads Flipper in React Native templates. 54 | * 55 | * @param context 56 | */ 57 | private static void initializeFlipper(Context context, ReactInstanceManager reactInstanceManager) { 58 | if (BuildConfig.DEBUG) { 59 | try { 60 | /* 61 | We use reflection here to pick up the class that initializes Flipper, 62 | since Flipper library is not available in release mode 63 | */ 64 | Class aClass = Class.forName("com.reactnativewalletmanagerExample.ReactNativeFlipper"); 65 | aClass 66 | .getMethod("initializeFlipper", Context.class, ReactInstanceManager.class) 67 | .invoke(null, context, reactInstanceManager); 68 | } catch (ClassNotFoundException e) { 69 | e.printStackTrace(); 70 | } catch (NoSuchMethodException e) { 71 | e.printStackTrace(); 72 | } catch (IllegalAccessException e) { 73 | e.printStackTrace(); 74 | } catch (InvocationTargetException e) { 75 | e.printStackTrace(); 76 | } 77 | } 78 | } 79 | } 80 | -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | WalletManager Example 3 | 4 | -------------------------------------------------------------------------------- /example/android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /example/android/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | ext { 5 | buildToolsVersion = "33.0.0" 6 | minSdkVersion = 21 7 | compileSdkVersion = 33 8 | targetSdkVersion = 33 9 | } 10 | repositories { 11 | google() 12 | jcenter() 13 | } 14 | dependencies { 15 | classpath("com.android.tools.build:gradle:7.4.0") 16 | 17 | // NOTE: Do not place your application dependencies here; they belong 18 | // in the individual module build.gradle files 19 | } 20 | } 21 | 22 | allprojects { 23 | repositories { 24 | mavenLocal() 25 | maven { 26 | // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm 27 | url("$rootDir/../node_modules/react-native/android") 28 | } 29 | maven { 30 | // Android JSC is installed from npm 31 | url("$rootDir/../node_modules/jsc-android/dist") 32 | } 33 | 34 | google() 35 | jcenter() 36 | maven { url 'https://www.jitpack.io' } 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /example/android/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | 3 | # IDE (e.g. Android Studio) users: 4 | # Gradle settings configured through the IDE *will override* 5 | # any settings specified in this file. 6 | 7 | # For more details on how to configure your build environment visit 8 | # http://www.gradle.org/docs/current/userguide/build_environment.html 9 | 10 | # Specifies the JVM arguments used for the daemon process. 11 | # The setting is particularly useful for tweaking memory settings. 12 | # Default value: -Xmx10248m -XX:MaxPermSize=256m 13 | # org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 14 | 15 | # When configured, Gradle will run in incubating parallel mode. 16 | # This option should only be used with decoupled projects. More details, visit 17 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 18 | # org.gradle.parallel=true 19 | 20 | android.useAndroidX=true 21 | android.enableJetifier=true 22 | FLIPPER_VERSION=0.125.0 23 | -------------------------------------------------------------------------------- /example/android/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/android/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /example/android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-all.zip 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | -------------------------------------------------------------------------------- /example/android/gradlew: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env sh 2 | 3 | # 4 | # Copyright 2015 the original author or authors. 5 | # 6 | # Licensed under the Apache License, Version 2.0 (the "License"); 7 | # you may not use this file except in compliance with the License. 8 | # You may obtain a copy of the License at 9 | # 10 | # https://www.apache.org/licenses/LICENSE-2.0 11 | # 12 | # Unless required by applicable law or agreed to in writing, software 13 | # distributed under the License is distributed on an "AS IS" BASIS, 14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | # See the License for the specific language governing permissions and 16 | # limitations under the License. 17 | # 18 | 19 | ############################################################################## 20 | ## 21 | ## Gradle start up script for UN*X 22 | ## 23 | ############################################################################## 24 | 25 | # Attempt to set APP_HOME 26 | # Resolve links: $0 may be a link 27 | PRG="$0" 28 | # Need this for relative symlinks. 29 | while [ -h "$PRG" ] ; do 30 | ls=`ls -ld "$PRG"` 31 | link=`expr "$ls" : '.*-> \(.*\)$'` 32 | if expr "$link" : '/.*' > /dev/null; then 33 | PRG="$link" 34 | else 35 | PRG=`dirname "$PRG"`"/$link" 36 | fi 37 | done 38 | SAVED="`pwd`" 39 | cd "`dirname \"$PRG\"`/" >/dev/null 40 | APP_HOME="`pwd -P`" 41 | cd "$SAVED" >/dev/null 42 | 43 | APP_NAME="Gradle" 44 | APP_BASE_NAME=`basename "$0"` 45 | 46 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 47 | DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' 48 | 49 | # Use the maximum available, or set MAX_FD != -1 to use that value. 50 | MAX_FD="maximum" 51 | 52 | warn () { 53 | echo "$*" 54 | } 55 | 56 | die () { 57 | echo 58 | echo "$*" 59 | echo 60 | exit 1 61 | } 62 | 63 | # OS specific support (must be 'true' or 'false'). 64 | cygwin=false 65 | msys=false 66 | darwin=false 67 | nonstop=false 68 | case "`uname`" in 69 | CYGWIN* ) 70 | cygwin=true 71 | ;; 72 | Darwin* ) 73 | darwin=true 74 | ;; 75 | MINGW* ) 76 | msys=true 77 | ;; 78 | NONSTOP* ) 79 | nonstop=true 80 | ;; 81 | esac 82 | 83 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar 84 | 85 | # Determine the Java command to use to start the JVM. 86 | if [ -n "$JAVA_HOME" ] ; then 87 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then 88 | # IBM's JDK on AIX uses strange locations for the executables 89 | JAVACMD="$JAVA_HOME/jre/sh/java" 90 | else 91 | JAVACMD="$JAVA_HOME/bin/java" 92 | fi 93 | if [ ! -x "$JAVACMD" ] ; then 94 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME 95 | 96 | Please set the JAVA_HOME variable in your environment to match the 97 | location of your Java installation." 98 | fi 99 | else 100 | JAVACMD="java" 101 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 102 | 103 | Please set the JAVA_HOME variable in your environment to match the 104 | location of your Java installation." 105 | fi 106 | 107 | # Increase the maximum file descriptors if we can. 108 | if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then 109 | MAX_FD_LIMIT=`ulimit -H -n` 110 | if [ $? -eq 0 ] ; then 111 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then 112 | MAX_FD="$MAX_FD_LIMIT" 113 | fi 114 | ulimit -n $MAX_FD 115 | if [ $? -ne 0 ] ; then 116 | warn "Could not set maximum file descriptor limit: $MAX_FD" 117 | fi 118 | else 119 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" 120 | fi 121 | fi 122 | 123 | # For Darwin, add options to specify how the application appears in the dock 124 | if $darwin; then 125 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" 126 | fi 127 | 128 | # For Cygwin or MSYS, switch paths to Windows format before running java 129 | if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then 130 | APP_HOME=`cygpath --path --mixed "$APP_HOME"` 131 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` 132 | JAVACMD=`cygpath --unix "$JAVACMD"` 133 | 134 | # We build the pattern for arguments to be converted via cygpath 135 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` 136 | SEP="" 137 | for dir in $ROOTDIRSRAW ; do 138 | ROOTDIRS="$ROOTDIRS$SEP$dir" 139 | SEP="|" 140 | done 141 | OURCYGPATTERN="(^($ROOTDIRS))" 142 | # Add a user-defined pattern to the cygpath arguments 143 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then 144 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" 145 | fi 146 | # Now convert the arguments - kludge to limit ourselves to /bin/sh 147 | i=0 148 | for arg in "$@" ; do 149 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` 150 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option 151 | 152 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition 153 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` 154 | else 155 | eval `echo args$i`="\"$arg\"" 156 | fi 157 | i=`expr $i + 1` 158 | done 159 | case $i in 160 | 0) set -- ;; 161 | 1) set -- "$args0" ;; 162 | 2) set -- "$args0" "$args1" ;; 163 | 3) set -- "$args0" "$args1" "$args2" ;; 164 | 4) set -- "$args0" "$args1" "$args2" "$args3" ;; 165 | 5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; 166 | 6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; 167 | 7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; 168 | 8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; 169 | 9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; 170 | esac 171 | fi 172 | 173 | # Escape application args 174 | save () { 175 | for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done 176 | echo " " 177 | } 178 | APP_ARGS=`save "$@"` 179 | 180 | # Collect all arguments for the java command, following the shell quoting and substitution rules 181 | eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS" 182 | 183 | exec "$JAVACMD" "$@" 184 | -------------------------------------------------------------------------------- /example/android/gradlew.bat: -------------------------------------------------------------------------------- 1 | @rem 2 | @rem Copyright 2015 the original author or authors. 3 | @rem 4 | @rem Licensed under the Apache License, Version 2.0 (the "License"); 5 | @rem you may not use this file except in compliance with the License. 6 | @rem You may obtain a copy of the License at 7 | @rem 8 | @rem http://www.apache.org/licenses/LICENSE-2.0 9 | @rem 10 | @rem Unless required by applicable law or agreed to in writing, software 11 | @rem distributed under the License is distributed on an "AS IS" BASIS, 12 | @rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | @rem See the License for the specific language governing permissions and 14 | @rem limitations under the License. 15 | @rem 16 | 17 | @if "%DEBUG%" == "" @echo off 18 | @rem ########################################################################## 19 | @rem 20 | @rem Gradle startup script for Windows 21 | @rem 22 | @rem ########################################################################## 23 | 24 | @rem Set local scope for the variables with windows NT shell 25 | if "%OS%"=="Windows_NT" setlocal 26 | 27 | set DIRNAME=%~dp0 28 | if "%DIRNAME%" == "" set DIRNAME=. 29 | set APP_BASE_NAME=%~n0 30 | set APP_HOME=%DIRNAME% 31 | 32 | @rem Resolve any "." and ".." in APP_HOME to make it shorter. 33 | for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi 34 | 35 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 36 | set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" 37 | 38 | @rem Find java.exe 39 | if defined JAVA_HOME goto findJavaFromJavaHome 40 | 41 | set JAVA_EXE=java.exe 42 | %JAVA_EXE% -version >NUL 2>&1 43 | if "%ERRORLEVEL%" == "0" goto init 44 | 45 | echo. 46 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 47 | echo. 48 | echo Please set the JAVA_HOME variable in your environment to match the 49 | echo location of your Java installation. 50 | 51 | goto fail 52 | 53 | :findJavaFromJavaHome 54 | set JAVA_HOME=%JAVA_HOME:"=% 55 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe 56 | 57 | if exist "%JAVA_EXE%" goto init 58 | 59 | echo. 60 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 61 | echo. 62 | echo Please set the JAVA_HOME variable in your environment to match the 63 | echo location of your Java installation. 64 | 65 | goto fail 66 | 67 | :init 68 | @rem Get command-line arguments, handling Windows variants 69 | 70 | if not "%OS%" == "Windows_NT" goto win9xME_args 71 | 72 | :win9xME_args 73 | @rem Slurp the command line arguments. 74 | set CMD_LINE_ARGS= 75 | set _SKIP=2 76 | 77 | :win9xME_args_slurp 78 | if "x%~1" == "x" goto execute 79 | 80 | set CMD_LINE_ARGS=%* 81 | 82 | :execute 83 | @rem Setup the command line 84 | 85 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 86 | 87 | @rem Execute Gradle 88 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% 89 | 90 | :end 91 | @rem End local scope for the variables with windows NT shell 92 | if "%ERRORLEVEL%"=="0" goto mainEnd 93 | 94 | :fail 95 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 96 | rem the _cmd.exe /c_ return code! 97 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 98 | exit /b 1 99 | 100 | :mainEnd 101 | if "%OS%"=="Windows_NT" endlocal 102 | 103 | :omega 104 | -------------------------------------------------------------------------------- /example/android/settings.gradle: -------------------------------------------------------------------------------- 1 | rootProject.name = 'WalletManagerExample' 2 | apply from: file("../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesSettingsGradle(settings) 3 | include ':app' 4 | 5 | include ':reactnativewalletmanager' 6 | project(':reactnativewalletmanager').projectDir = new File(rootProject.projectDir, '../../android') 7 | -------------------------------------------------------------------------------- /example/app.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "WalletManagerExample", 3 | "displayName": "WalletManager Example" 4 | } 5 | -------------------------------------------------------------------------------- /example/babel.config.js: -------------------------------------------------------------------------------- 1 | const path = require('path'); 2 | const pak = require('../package.json'); 3 | 4 | module.exports = { 5 | presets: ['module:metro-react-native-babel-preset'], 6 | plugins: [ 7 | [ 8 | 'module-resolver', 9 | { 10 | extensions: ['.tsx', '.ts', '.js', '.json'], 11 | alias: { 12 | [pak.name]: path.join(__dirname, '..', pak.source), 13 | }, 14 | }, 15 | ], 16 | ], 17 | }; 18 | -------------------------------------------------------------------------------- /example/index.tsx: -------------------------------------------------------------------------------- 1 | import { AppRegistry } from 'react-native'; 2 | import App from './src/App'; 3 | import { name as appName } from './app.json'; 4 | 5 | AppRegistry.registerComponent(appName, () => App); 6 | -------------------------------------------------------------------------------- /example/ios/File.swift: -------------------------------------------------------------------------------- 1 | // 2 | // File.swift 3 | // WalletManagerExample 4 | // 5 | 6 | import Foundation 7 | -------------------------------------------------------------------------------- /example/ios/Podfile: -------------------------------------------------------------------------------- 1 | require_relative '../node_modules/react-native/scripts/react_native_pods' 2 | require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules' 3 | 4 | platform :ios, '10.0' 5 | 6 | target 'WalletManagerExample' do 7 | config = use_native_modules! 8 | 9 | use_react_native!(:path => config["reactNativePath"]) 10 | 11 | pod 'react-native-wallet-manager', :path => '../..' 12 | 13 | # Enables Flipper. 14 | # 15 | # Note that if you have use_frameworks! enabled, Flipper will not work and 16 | # you should disable these next few lines. 17 | # use_flipper!({ 'Flipper' => '0.80.0' }) 18 | # post_install do |installer| 19 | # flipper_post_install(installer) 20 | # end 21 | end 22 | -------------------------------------------------------------------------------- /example/ios/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - boost-for-react-native (1.63.0) 3 | - DoubleConversion (1.1.6) 4 | - FBLazyVector (0.63.4) 5 | - FBReactNativeSpec (0.63.4): 6 | - Folly (= 2020.01.13.00) 7 | - RCTRequired (= 0.63.4) 8 | - RCTTypeSafety (= 0.63.4) 9 | - React-Core (= 0.63.4) 10 | - React-jsi (= 0.63.4) 11 | - ReactCommon/turbomodule/core (= 0.63.4) 12 | - Folly (2020.01.13.00): 13 | - boost-for-react-native 14 | - DoubleConversion 15 | - Folly/Default (= 2020.01.13.00) 16 | - glog 17 | - Folly/Default (2020.01.13.00): 18 | - boost-for-react-native 19 | - DoubleConversion 20 | - glog 21 | - glog (0.3.5) 22 | - RCTRequired (0.63.4) 23 | - RCTTypeSafety (0.63.4): 24 | - FBLazyVector (= 0.63.4) 25 | - Folly (= 2020.01.13.00) 26 | - RCTRequired (= 0.63.4) 27 | - React-Core (= 0.63.4) 28 | - React (0.63.4): 29 | - React-Core (= 0.63.4) 30 | - React-Core/DevSupport (= 0.63.4) 31 | - React-Core/RCTWebSocket (= 0.63.4) 32 | - React-RCTActionSheet (= 0.63.4) 33 | - React-RCTAnimation (= 0.63.4) 34 | - React-RCTBlob (= 0.63.4) 35 | - React-RCTImage (= 0.63.4) 36 | - React-RCTLinking (= 0.63.4) 37 | - React-RCTNetwork (= 0.63.4) 38 | - React-RCTSettings (= 0.63.4) 39 | - React-RCTText (= 0.63.4) 40 | - React-RCTVibration (= 0.63.4) 41 | - React-callinvoker (0.63.4) 42 | - React-Core (0.63.4): 43 | - Folly (= 2020.01.13.00) 44 | - glog 45 | - React-Core/Default (= 0.63.4) 46 | - React-cxxreact (= 0.63.4) 47 | - React-jsi (= 0.63.4) 48 | - React-jsiexecutor (= 0.63.4) 49 | - Yoga 50 | - React-Core/CoreModulesHeaders (0.63.4): 51 | - Folly (= 2020.01.13.00) 52 | - glog 53 | - React-Core/Default 54 | - React-cxxreact (= 0.63.4) 55 | - React-jsi (= 0.63.4) 56 | - React-jsiexecutor (= 0.63.4) 57 | - Yoga 58 | - React-Core/Default (0.63.4): 59 | - Folly (= 2020.01.13.00) 60 | - glog 61 | - React-cxxreact (= 0.63.4) 62 | - React-jsi (= 0.63.4) 63 | - React-jsiexecutor (= 0.63.4) 64 | - Yoga 65 | - React-Core/DevSupport (0.63.4): 66 | - Folly (= 2020.01.13.00) 67 | - glog 68 | - React-Core/Default (= 0.63.4) 69 | - React-Core/RCTWebSocket (= 0.63.4) 70 | - React-cxxreact (= 0.63.4) 71 | - React-jsi (= 0.63.4) 72 | - React-jsiexecutor (= 0.63.4) 73 | - React-jsinspector (= 0.63.4) 74 | - Yoga 75 | - React-Core/RCTActionSheetHeaders (0.63.4): 76 | - Folly (= 2020.01.13.00) 77 | - glog 78 | - React-Core/Default 79 | - React-cxxreact (= 0.63.4) 80 | - React-jsi (= 0.63.4) 81 | - React-jsiexecutor (= 0.63.4) 82 | - Yoga 83 | - React-Core/RCTAnimationHeaders (0.63.4): 84 | - Folly (= 2020.01.13.00) 85 | - glog 86 | - React-Core/Default 87 | - React-cxxreact (= 0.63.4) 88 | - React-jsi (= 0.63.4) 89 | - React-jsiexecutor (= 0.63.4) 90 | - Yoga 91 | - React-Core/RCTBlobHeaders (0.63.4): 92 | - Folly (= 2020.01.13.00) 93 | - glog 94 | - React-Core/Default 95 | - React-cxxreact (= 0.63.4) 96 | - React-jsi (= 0.63.4) 97 | - React-jsiexecutor (= 0.63.4) 98 | - Yoga 99 | - React-Core/RCTImageHeaders (0.63.4): 100 | - Folly (= 2020.01.13.00) 101 | - glog 102 | - React-Core/Default 103 | - React-cxxreact (= 0.63.4) 104 | - React-jsi (= 0.63.4) 105 | - React-jsiexecutor (= 0.63.4) 106 | - Yoga 107 | - React-Core/RCTLinkingHeaders (0.63.4): 108 | - Folly (= 2020.01.13.00) 109 | - glog 110 | - React-Core/Default 111 | - React-cxxreact (= 0.63.4) 112 | - React-jsi (= 0.63.4) 113 | - React-jsiexecutor (= 0.63.4) 114 | - Yoga 115 | - React-Core/RCTNetworkHeaders (0.63.4): 116 | - Folly (= 2020.01.13.00) 117 | - glog 118 | - React-Core/Default 119 | - React-cxxreact (= 0.63.4) 120 | - React-jsi (= 0.63.4) 121 | - React-jsiexecutor (= 0.63.4) 122 | - Yoga 123 | - React-Core/RCTSettingsHeaders (0.63.4): 124 | - Folly (= 2020.01.13.00) 125 | - glog 126 | - React-Core/Default 127 | - React-cxxreact (= 0.63.4) 128 | - React-jsi (= 0.63.4) 129 | - React-jsiexecutor (= 0.63.4) 130 | - Yoga 131 | - React-Core/RCTTextHeaders (0.63.4): 132 | - Folly (= 2020.01.13.00) 133 | - glog 134 | - React-Core/Default 135 | - React-cxxreact (= 0.63.4) 136 | - React-jsi (= 0.63.4) 137 | - React-jsiexecutor (= 0.63.4) 138 | - Yoga 139 | - React-Core/RCTVibrationHeaders (0.63.4): 140 | - Folly (= 2020.01.13.00) 141 | - glog 142 | - React-Core/Default 143 | - React-cxxreact (= 0.63.4) 144 | - React-jsi (= 0.63.4) 145 | - React-jsiexecutor (= 0.63.4) 146 | - Yoga 147 | - React-Core/RCTWebSocket (0.63.4): 148 | - Folly (= 2020.01.13.00) 149 | - glog 150 | - React-Core/Default (= 0.63.4) 151 | - React-cxxreact (= 0.63.4) 152 | - React-jsi (= 0.63.4) 153 | - React-jsiexecutor (= 0.63.4) 154 | - Yoga 155 | - React-CoreModules (0.63.4): 156 | - FBReactNativeSpec (= 0.63.4) 157 | - Folly (= 2020.01.13.00) 158 | - RCTTypeSafety (= 0.63.4) 159 | - React-Core/CoreModulesHeaders (= 0.63.4) 160 | - React-jsi (= 0.63.4) 161 | - React-RCTImage (= 0.63.4) 162 | - ReactCommon/turbomodule/core (= 0.63.4) 163 | - React-cxxreact (0.63.4): 164 | - boost-for-react-native (= 1.63.0) 165 | - DoubleConversion 166 | - Folly (= 2020.01.13.00) 167 | - glog 168 | - React-callinvoker (= 0.63.4) 169 | - React-jsinspector (= 0.63.4) 170 | - React-jsi (0.63.4): 171 | - boost-for-react-native (= 1.63.0) 172 | - DoubleConversion 173 | - Folly (= 2020.01.13.00) 174 | - glog 175 | - React-jsi/Default (= 0.63.4) 176 | - React-jsi/Default (0.63.4): 177 | - boost-for-react-native (= 1.63.0) 178 | - DoubleConversion 179 | - Folly (= 2020.01.13.00) 180 | - glog 181 | - React-jsiexecutor (0.63.4): 182 | - DoubleConversion 183 | - Folly (= 2020.01.13.00) 184 | - glog 185 | - React-cxxreact (= 0.63.4) 186 | - React-jsi (= 0.63.4) 187 | - React-jsinspector (0.63.4) 188 | - react-native-wallet-manager (1.1.0): 189 | - React-Core 190 | - React-RCTActionSheet (0.63.4): 191 | - React-Core/RCTActionSheetHeaders (= 0.63.4) 192 | - React-RCTAnimation (0.63.4): 193 | - FBReactNativeSpec (= 0.63.4) 194 | - Folly (= 2020.01.13.00) 195 | - RCTTypeSafety (= 0.63.4) 196 | - React-Core/RCTAnimationHeaders (= 0.63.4) 197 | - React-jsi (= 0.63.4) 198 | - ReactCommon/turbomodule/core (= 0.63.4) 199 | - React-RCTBlob (0.63.4): 200 | - FBReactNativeSpec (= 0.63.4) 201 | - Folly (= 2020.01.13.00) 202 | - React-Core/RCTBlobHeaders (= 0.63.4) 203 | - React-Core/RCTWebSocket (= 0.63.4) 204 | - React-jsi (= 0.63.4) 205 | - React-RCTNetwork (= 0.63.4) 206 | - ReactCommon/turbomodule/core (= 0.63.4) 207 | - React-RCTImage (0.63.4): 208 | - FBReactNativeSpec (= 0.63.4) 209 | - Folly (= 2020.01.13.00) 210 | - RCTTypeSafety (= 0.63.4) 211 | - React-Core/RCTImageHeaders (= 0.63.4) 212 | - React-jsi (= 0.63.4) 213 | - React-RCTNetwork (= 0.63.4) 214 | - ReactCommon/turbomodule/core (= 0.63.4) 215 | - React-RCTLinking (0.63.4): 216 | - FBReactNativeSpec (= 0.63.4) 217 | - React-Core/RCTLinkingHeaders (= 0.63.4) 218 | - React-jsi (= 0.63.4) 219 | - ReactCommon/turbomodule/core (= 0.63.4) 220 | - React-RCTNetwork (0.63.4): 221 | - FBReactNativeSpec (= 0.63.4) 222 | - Folly (= 2020.01.13.00) 223 | - RCTTypeSafety (= 0.63.4) 224 | - React-Core/RCTNetworkHeaders (= 0.63.4) 225 | - React-jsi (= 0.63.4) 226 | - ReactCommon/turbomodule/core (= 0.63.4) 227 | - React-RCTSettings (0.63.4): 228 | - FBReactNativeSpec (= 0.63.4) 229 | - Folly (= 2020.01.13.00) 230 | - RCTTypeSafety (= 0.63.4) 231 | - React-Core/RCTSettingsHeaders (= 0.63.4) 232 | - React-jsi (= 0.63.4) 233 | - ReactCommon/turbomodule/core (= 0.63.4) 234 | - React-RCTText (0.63.4): 235 | - React-Core/RCTTextHeaders (= 0.63.4) 236 | - React-RCTVibration (0.63.4): 237 | - FBReactNativeSpec (= 0.63.4) 238 | - Folly (= 2020.01.13.00) 239 | - React-Core/RCTVibrationHeaders (= 0.63.4) 240 | - React-jsi (= 0.63.4) 241 | - ReactCommon/turbomodule/core (= 0.63.4) 242 | - ReactCommon/turbomodule/core (0.63.4): 243 | - DoubleConversion 244 | - Folly (= 2020.01.13.00) 245 | - glog 246 | - React-callinvoker (= 0.63.4) 247 | - React-Core (= 0.63.4) 248 | - React-cxxreact (= 0.63.4) 249 | - React-jsi (= 0.63.4) 250 | - Yoga (1.14.0) 251 | 252 | DEPENDENCIES: 253 | - DoubleConversion (from `../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec`) 254 | - FBLazyVector (from `../node_modules/react-native/Libraries/FBLazyVector`) 255 | - FBReactNativeSpec (from `../node_modules/react-native/Libraries/FBReactNativeSpec`) 256 | - Folly (from `../node_modules/react-native/third-party-podspecs/Folly.podspec`) 257 | - glog (from `../node_modules/react-native/third-party-podspecs/glog.podspec`) 258 | - RCTRequired (from `../node_modules/react-native/Libraries/RCTRequired`) 259 | - RCTTypeSafety (from `../node_modules/react-native/Libraries/TypeSafety`) 260 | - React (from `../node_modules/react-native/`) 261 | - React-callinvoker (from `../node_modules/react-native/ReactCommon/callinvoker`) 262 | - React-Core (from `../node_modules/react-native/`) 263 | - React-Core/DevSupport (from `../node_modules/react-native/`) 264 | - React-Core/RCTWebSocket (from `../node_modules/react-native/`) 265 | - React-CoreModules (from `../node_modules/react-native/React/CoreModules`) 266 | - React-cxxreact (from `../node_modules/react-native/ReactCommon/cxxreact`) 267 | - React-jsi (from `../node_modules/react-native/ReactCommon/jsi`) 268 | - React-jsiexecutor (from `../node_modules/react-native/ReactCommon/jsiexecutor`) 269 | - React-jsinspector (from `../node_modules/react-native/ReactCommon/jsinspector`) 270 | - react-native-wallet-manager (from `../..`) 271 | - React-RCTActionSheet (from `../node_modules/react-native/Libraries/ActionSheetIOS`) 272 | - React-RCTAnimation (from `../node_modules/react-native/Libraries/NativeAnimation`) 273 | - React-RCTBlob (from `../node_modules/react-native/Libraries/Blob`) 274 | - React-RCTImage (from `../node_modules/react-native/Libraries/Image`) 275 | - React-RCTLinking (from `../node_modules/react-native/Libraries/LinkingIOS`) 276 | - React-RCTNetwork (from `../node_modules/react-native/Libraries/Network`) 277 | - React-RCTSettings (from `../node_modules/react-native/Libraries/Settings`) 278 | - React-RCTText (from `../node_modules/react-native/Libraries/Text`) 279 | - React-RCTVibration (from `../node_modules/react-native/Libraries/Vibration`) 280 | - ReactCommon/turbomodule/core (from `../node_modules/react-native/ReactCommon`) 281 | - Yoga (from `../node_modules/react-native/ReactCommon/yoga`) 282 | 283 | SPEC REPOS: 284 | trunk: 285 | - boost-for-react-native 286 | 287 | EXTERNAL SOURCES: 288 | DoubleConversion: 289 | :podspec: "../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec" 290 | FBLazyVector: 291 | :path: "../node_modules/react-native/Libraries/FBLazyVector" 292 | FBReactNativeSpec: 293 | :path: "../node_modules/react-native/Libraries/FBReactNativeSpec" 294 | Folly: 295 | :podspec: "../node_modules/react-native/third-party-podspecs/Folly.podspec" 296 | glog: 297 | :podspec: "../node_modules/react-native/third-party-podspecs/glog.podspec" 298 | RCTRequired: 299 | :path: "../node_modules/react-native/Libraries/RCTRequired" 300 | RCTTypeSafety: 301 | :path: "../node_modules/react-native/Libraries/TypeSafety" 302 | React: 303 | :path: "../node_modules/react-native/" 304 | React-callinvoker: 305 | :path: "../node_modules/react-native/ReactCommon/callinvoker" 306 | React-Core: 307 | :path: "../node_modules/react-native/" 308 | React-CoreModules: 309 | :path: "../node_modules/react-native/React/CoreModules" 310 | React-cxxreact: 311 | :path: "../node_modules/react-native/ReactCommon/cxxreact" 312 | React-jsi: 313 | :path: "../node_modules/react-native/ReactCommon/jsi" 314 | React-jsiexecutor: 315 | :path: "../node_modules/react-native/ReactCommon/jsiexecutor" 316 | React-jsinspector: 317 | :path: "../node_modules/react-native/ReactCommon/jsinspector" 318 | react-native-wallet-manager: 319 | :path: "../.." 320 | React-RCTActionSheet: 321 | :path: "../node_modules/react-native/Libraries/ActionSheetIOS" 322 | React-RCTAnimation: 323 | :path: "../node_modules/react-native/Libraries/NativeAnimation" 324 | React-RCTBlob: 325 | :path: "../node_modules/react-native/Libraries/Blob" 326 | React-RCTImage: 327 | :path: "../node_modules/react-native/Libraries/Image" 328 | React-RCTLinking: 329 | :path: "../node_modules/react-native/Libraries/LinkingIOS" 330 | React-RCTNetwork: 331 | :path: "../node_modules/react-native/Libraries/Network" 332 | React-RCTSettings: 333 | :path: "../node_modules/react-native/Libraries/Settings" 334 | React-RCTText: 335 | :path: "../node_modules/react-native/Libraries/Text" 336 | React-RCTVibration: 337 | :path: "../node_modules/react-native/Libraries/Vibration" 338 | ReactCommon: 339 | :path: "../node_modules/react-native/ReactCommon" 340 | Yoga: 341 | :path: "../node_modules/react-native/ReactCommon/yoga" 342 | 343 | SPEC CHECKSUMS: 344 | boost-for-react-native: 39c7adb57c4e60d6c5479dd8623128eb5b3f0f2c 345 | DoubleConversion: cde416483dac037923206447da6e1454df403714 346 | FBLazyVector: 3bb422f41b18121b71783a905c10e58606f7dc3e 347 | FBReactNativeSpec: f2c97f2529dd79c083355182cc158c9f98f4bd6e 348 | Folly: b73c3869541e86821df3c387eb0af5f65addfab4 349 | glog: 40a13f7840415b9a77023fbcae0f1e6f43192af3 350 | RCTRequired: 082f10cd3f905d6c124597fd1c14f6f2655ff65e 351 | RCTTypeSafety: 8c9c544ecbf20337d069e4ae7fd9a377aadf504b 352 | React: b0a957a2c44da4113b0c4c9853d8387f8e64e615 353 | React-callinvoker: c3f44dd3cb195b6aa46621fff95ded79d59043fe 354 | React-Core: d3b2a1ac9a2c13c3bcde712d9281fc1c8a5b315b 355 | React-CoreModules: 0581ff36cb797da0943d424f69e7098e43e9be60 356 | React-cxxreact: c1480d4fda5720086c90df537ee7d285d4c57ac3 357 | React-jsi: a0418934cf48f25b485631deb27c64dc40fb4c31 358 | React-jsiexecutor: 93bd528844ad21dc07aab1c67cb10abae6df6949 359 | React-jsinspector: 58aef7155bc9a9683f5b60b35eccea8722a4f53a 360 | react-native-wallet-manager: 84d63605a7138cff449bd3d3b649d2fa12bd9393 361 | React-RCTActionSheet: 89a0ca9f4a06c1f93c26067af074ccdce0f40336 362 | React-RCTAnimation: 1bde3ecc0c104c55df246eda516e0deb03c4e49b 363 | React-RCTBlob: a97d378b527740cc667e03ebfa183a75231ab0f0 364 | React-RCTImage: c1b1f2d3f43a4a528c8946d6092384b5c880d2f0 365 | React-RCTLinking: 35ae4ab9dc0410d1fcbdce4d7623194a27214fb2 366 | React-RCTNetwork: 29ec2696f8d8cfff7331fac83d3e893c95ef43ae 367 | React-RCTSettings: 60f0691bba2074ef394f95d4c2265ec284e0a46a 368 | React-RCTText: 5c51df3f08cb9dedc6e790161195d12bac06101c 369 | React-RCTVibration: ae4f914cfe8de7d4de95ae1ea6cc8f6315d73d9d 370 | ReactCommon: 73d79c7039f473b76db6ff7c6b159c478acbbb3b 371 | Yoga: 4bd86afe9883422a7c4028c00e34790f560923d6 372 | 373 | PODFILE CHECKSUM: 374c455f3e73d3fa972f0a266464401bbadc9c7f 374 | 375 | COCOAPODS: 1.14.3 376 | -------------------------------------------------------------------------------- /example/ios/WalletManagerExample-Bridging-Header.h: -------------------------------------------------------------------------------- 1 | // 2 | // Use this file to import your target's public headers that you would like to expose to Swift. 3 | // 4 | -------------------------------------------------------------------------------- /example/ios/WalletManagerExample.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 00E356F31AD99517003FC87E /* WalletManagerExampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* WalletManagerExampleTests.m */; }; 11 | 0AD68C5A26C26AD700193B2C /* PassKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 0AD68C5926C26AD700193B2C /* PassKit.framework */; }; 12 | 13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.m */; }; 13 | 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; }; 14 | 13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; }; 15 | 2D02E4BC1E0B4A80006451C7 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.m */; }; 16 | 2D02E4BD1E0B4A84006451C7 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; }; 17 | 2D02E4BF1E0B4AB3006451C7 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; }; 18 | 2DCD954D1E0B4F2C00145EB5 /* WalletManagerExampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* WalletManagerExampleTests.m */; }; 19 | 4C39C56BAD484C67AA576FFA /* libPods-WalletManagerExample.a in Frameworks */ = {isa = PBXBuildFile; fileRef = CA3E69C5B9553B26FBA2DF04 /* libPods-WalletManagerExample.a */; }; 20 | 81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */; }; 21 | /* End PBXBuildFile section */ 22 | 23 | /* Begin PBXContainerItemProxy section */ 24 | 00E356F41AD99517003FC87E /* PBXContainerItemProxy */ = { 25 | isa = PBXContainerItemProxy; 26 | containerPortal = 83CBB9F71A601CBA00E9B192 /* Project object */; 27 | proxyType = 1; 28 | remoteGlobalIDString = 13B07F861A680F5B00A75B9A; 29 | remoteInfo = WalletManagerExample; 30 | }; 31 | 2D02E4911E0B4A5D006451C7 /* PBXContainerItemProxy */ = { 32 | isa = PBXContainerItemProxy; 33 | containerPortal = 83CBB9F71A601CBA00E9B192 /* Project object */; 34 | proxyType = 1; 35 | remoteGlobalIDString = 2D02E47A1E0B4A5D006451C7; 36 | remoteInfo = "WalletManagerExample-tvOS"; 37 | }; 38 | /* End PBXContainerItemProxy section */ 39 | 40 | /* Begin PBXFileReference section */ 41 | 008F07F21AC5B25A0029DE68 /* main.jsbundle */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = main.jsbundle; sourceTree = ""; }; 42 | 00E356EE1AD99517003FC87E /* WalletManagerExampleTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = WalletManagerExampleTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 43 | 00E356F11AD99517003FC87E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 44 | 00E356F21AD99517003FC87E /* WalletManagerExampleTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = WalletManagerExampleTests.m; sourceTree = ""; }; 45 | 0AD68C5826C26AD700193B2C /* WalletManagerExample.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; name = WalletManagerExample.entitlements; path = WalletManagerExample/WalletManagerExample.entitlements; sourceTree = ""; }; 46 | 0AD68C5926C26AD700193B2C /* PassKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = PassKit.framework; path = System/Library/Frameworks/PassKit.framework; sourceTree = SDKROOT; }; 47 | 13B07F961A680F5B00A75B9A /* WalletManagerExample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = WalletManagerExample.app; sourceTree = BUILT_PRODUCTS_DIR; }; 48 | 13B07FAF1A68108700A75B9A /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = WalletManagerExample/AppDelegate.h; sourceTree = ""; }; 49 | 13B07FB01A68108700A75B9A /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = AppDelegate.m; path = WalletManagerExample/AppDelegate.m; sourceTree = ""; }; 50 | 13B07FB51A68108700A75B9A /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = WalletManagerExample/Images.xcassets; sourceTree = ""; }; 51 | 13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = WalletManagerExample/Info.plist; sourceTree = ""; }; 52 | 13B07FB71A68108700A75B9A /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = WalletManagerExample/main.m; sourceTree = ""; }; 53 | 2D02E47B1E0B4A5D006451C7 /* WalletManagerExample-tvOS.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "WalletManagerExample-tvOS.app"; sourceTree = BUILT_PRODUCTS_DIR; }; 54 | 2D02E4901E0B4A5D006451C7 /* WalletManagerExample-tvOSTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "WalletManagerExample-tvOSTests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; }; 55 | 47F7ED3B7971BE374F7B8635 /* Pods-WalletManagerExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-WalletManagerExample.debug.xcconfig"; path = "Target Support Files/Pods-WalletManagerExample/Pods-WalletManagerExample.debug.xcconfig"; sourceTree = ""; }; 56 | 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = LaunchScreen.storyboard; path = WalletManagerExample/LaunchScreen.storyboard; sourceTree = ""; }; 57 | CA3E69C5B9553B26FBA2DF04 /* libPods-WalletManagerExample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-WalletManagerExample.a"; sourceTree = BUILT_PRODUCTS_DIR; }; 58 | E00ACF0FDA8BF921659E2F9A /* Pods-WalletManagerExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-WalletManagerExample.release.xcconfig"; path = "Target Support Files/Pods-WalletManagerExample/Pods-WalletManagerExample.release.xcconfig"; sourceTree = ""; }; 59 | ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; }; 60 | ED2971642150620600B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS12.0.sdk/System/Library/Frameworks/JavaScriptCore.framework; sourceTree = DEVELOPER_DIR; }; 61 | /* End PBXFileReference section */ 62 | 63 | /* Begin PBXFrameworksBuildPhase section */ 64 | 00E356EB1AD99517003FC87E /* Frameworks */ = { 65 | isa = PBXFrameworksBuildPhase; 66 | buildActionMask = 2147483647; 67 | files = ( 68 | ); 69 | runOnlyForDeploymentPostprocessing = 0; 70 | }; 71 | 13B07F8C1A680F5B00A75B9A /* Frameworks */ = { 72 | isa = PBXFrameworksBuildPhase; 73 | buildActionMask = 2147483647; 74 | files = ( 75 | 0AD68C5A26C26AD700193B2C /* PassKit.framework in Frameworks */, 76 | 4C39C56BAD484C67AA576FFA /* libPods-WalletManagerExample.a in Frameworks */, 77 | ); 78 | runOnlyForDeploymentPostprocessing = 0; 79 | }; 80 | 2D02E4781E0B4A5D006451C7 /* Frameworks */ = { 81 | isa = PBXFrameworksBuildPhase; 82 | buildActionMask = 2147483647; 83 | files = ( 84 | ); 85 | runOnlyForDeploymentPostprocessing = 0; 86 | }; 87 | 2D02E48D1E0B4A5D006451C7 /* Frameworks */ = { 88 | isa = PBXFrameworksBuildPhase; 89 | buildActionMask = 2147483647; 90 | files = ( 91 | ); 92 | runOnlyForDeploymentPostprocessing = 0; 93 | }; 94 | /* End PBXFrameworksBuildPhase section */ 95 | 96 | /* Begin PBXGroup section */ 97 | 00E356EF1AD99517003FC87E /* WalletManagerExampleTests */ = { 98 | isa = PBXGroup; 99 | children = ( 100 | 00E356F21AD99517003FC87E /* WalletManagerExampleTests.m */, 101 | 00E356F01AD99517003FC87E /* Supporting Files */, 102 | ); 103 | path = WalletManagerExampleTests; 104 | sourceTree = ""; 105 | }; 106 | 00E356F01AD99517003FC87E /* Supporting Files */ = { 107 | isa = PBXGroup; 108 | children = ( 109 | 00E356F11AD99517003FC87E /* Info.plist */, 110 | ); 111 | name = "Supporting Files"; 112 | sourceTree = ""; 113 | }; 114 | 13B07FAE1A68108700A75B9A /* WalletManagerExample */ = { 115 | isa = PBXGroup; 116 | children = ( 117 | 0AD68C5826C26AD700193B2C /* WalletManagerExample.entitlements */, 118 | 008F07F21AC5B25A0029DE68 /* main.jsbundle */, 119 | 13B07FAF1A68108700A75B9A /* AppDelegate.h */, 120 | 13B07FB01A68108700A75B9A /* AppDelegate.m */, 121 | 13B07FB51A68108700A75B9A /* Images.xcassets */, 122 | 13B07FB61A68108700A75B9A /* Info.plist */, 123 | 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */, 124 | 13B07FB71A68108700A75B9A /* main.m */, 125 | ); 126 | name = WalletManagerExample; 127 | sourceTree = ""; 128 | }; 129 | 2D16E6871FA4F8E400B85C8A /* Frameworks */ = { 130 | isa = PBXGroup; 131 | children = ( 132 | 0AD68C5926C26AD700193B2C /* PassKit.framework */, 133 | ED297162215061F000B7C4FE /* JavaScriptCore.framework */, 134 | ED2971642150620600B7C4FE /* JavaScriptCore.framework */, 135 | CA3E69C5B9553B26FBA2DF04 /* libPods-WalletManagerExample.a */, 136 | ); 137 | name = Frameworks; 138 | sourceTree = ""; 139 | }; 140 | 6B9684456A2045ADE5A6E47E /* Pods */ = { 141 | isa = PBXGroup; 142 | children = ( 143 | 47F7ED3B7971BE374F7B8635 /* Pods-WalletManagerExample.debug.xcconfig */, 144 | E00ACF0FDA8BF921659E2F9A /* Pods-WalletManagerExample.release.xcconfig */, 145 | ); 146 | path = Pods; 147 | sourceTree = ""; 148 | }; 149 | 832341AE1AAA6A7D00B99B32 /* Libraries */ = { 150 | isa = PBXGroup; 151 | children = ( 152 | ); 153 | name = Libraries; 154 | sourceTree = ""; 155 | }; 156 | 83CBB9F61A601CBA00E9B192 = { 157 | isa = PBXGroup; 158 | children = ( 159 | 13B07FAE1A68108700A75B9A /* WalletManagerExample */, 160 | 832341AE1AAA6A7D00B99B32 /* Libraries */, 161 | 00E356EF1AD99517003FC87E /* WalletManagerExampleTests */, 162 | 83CBBA001A601CBA00E9B192 /* Products */, 163 | 2D16E6871FA4F8E400B85C8A /* Frameworks */, 164 | 6B9684456A2045ADE5A6E47E /* Pods */, 165 | ); 166 | indentWidth = 2; 167 | sourceTree = ""; 168 | tabWidth = 2; 169 | usesTabs = 0; 170 | }; 171 | 83CBBA001A601CBA00E9B192 /* Products */ = { 172 | isa = PBXGroup; 173 | children = ( 174 | 13B07F961A680F5B00A75B9A /* WalletManagerExample.app */, 175 | 00E356EE1AD99517003FC87E /* WalletManagerExampleTests.xctest */, 176 | 2D02E47B1E0B4A5D006451C7 /* WalletManagerExample-tvOS.app */, 177 | 2D02E4901E0B4A5D006451C7 /* WalletManagerExample-tvOSTests.xctest */, 178 | ); 179 | name = Products; 180 | sourceTree = ""; 181 | }; 182 | /* End PBXGroup section */ 183 | 184 | /* Begin PBXNativeTarget section */ 185 | 00E356ED1AD99517003FC87E /* WalletManagerExampleTests */ = { 186 | isa = PBXNativeTarget; 187 | buildConfigurationList = 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "WalletManagerExampleTests" */; 188 | buildPhases = ( 189 | 00E356EA1AD99517003FC87E /* Sources */, 190 | 00E356EB1AD99517003FC87E /* Frameworks */, 191 | 00E356EC1AD99517003FC87E /* Resources */, 192 | ); 193 | buildRules = ( 194 | ); 195 | dependencies = ( 196 | 00E356F51AD99517003FC87E /* PBXTargetDependency */, 197 | ); 198 | name = WalletManagerExampleTests; 199 | productName = WalletManagerExampleTests; 200 | productReference = 00E356EE1AD99517003FC87E /* WalletManagerExampleTests.xctest */; 201 | productType = "com.apple.product-type.bundle.unit-test"; 202 | }; 203 | 13B07F861A680F5B00A75B9A /* WalletManagerExample */ = { 204 | isa = PBXNativeTarget; 205 | buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "WalletManagerExample" */; 206 | buildPhases = ( 207 | 4F0A6FC082772762E3E4C96C /* [CP] Check Pods Manifest.lock */, 208 | FD10A7F022414F080027D42C /* Start Packager */, 209 | 13B07F871A680F5B00A75B9A /* Sources */, 210 | 13B07F8C1A680F5B00A75B9A /* Frameworks */, 211 | 13B07F8E1A680F5B00A75B9A /* Resources */, 212 | 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */, 213 | C1D60D28B925C94BD88E79D7 /* [CP] Copy Pods Resources */, 214 | ); 215 | buildRules = ( 216 | ); 217 | dependencies = ( 218 | ); 219 | name = WalletManagerExample; 220 | productName = WalletManagerExample; 221 | productReference = 13B07F961A680F5B00A75B9A /* WalletManagerExample.app */; 222 | productType = "com.apple.product-type.application"; 223 | }; 224 | 2D02E47A1E0B4A5D006451C7 /* WalletManagerExample-tvOS */ = { 225 | isa = PBXNativeTarget; 226 | buildConfigurationList = 2D02E4BA1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "WalletManagerExample-tvOS" */; 227 | buildPhases = ( 228 | FD10A7F122414F3F0027D42C /* Start Packager */, 229 | 2D02E4771E0B4A5D006451C7 /* Sources */, 230 | 2D02E4781E0B4A5D006451C7 /* Frameworks */, 231 | 2D02E4791E0B4A5D006451C7 /* Resources */, 232 | 2D02E4CB1E0B4B27006451C7 /* Bundle React Native Code And Images */, 233 | ); 234 | buildRules = ( 235 | ); 236 | dependencies = ( 237 | ); 238 | name = "WalletManagerExample-tvOS"; 239 | productName = "WalletManagerExample-tvOS"; 240 | productReference = 2D02E47B1E0B4A5D006451C7 /* WalletManagerExample-tvOS.app */; 241 | productType = "com.apple.product-type.application"; 242 | }; 243 | 2D02E48F1E0B4A5D006451C7 /* WalletManagerExample-tvOSTests */ = { 244 | isa = PBXNativeTarget; 245 | buildConfigurationList = 2D02E4BB1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "WalletManagerExample-tvOSTests" */; 246 | buildPhases = ( 247 | 2D02E48C1E0B4A5D006451C7 /* Sources */, 248 | 2D02E48D1E0B4A5D006451C7 /* Frameworks */, 249 | 2D02E48E1E0B4A5D006451C7 /* Resources */, 250 | ); 251 | buildRules = ( 252 | ); 253 | dependencies = ( 254 | 2D02E4921E0B4A5D006451C7 /* PBXTargetDependency */, 255 | ); 256 | name = "WalletManagerExample-tvOSTests"; 257 | productName = "WalletManagerExample-tvOSTests"; 258 | productReference = 2D02E4901E0B4A5D006451C7 /* WalletManagerExample-tvOSTests.xctest */; 259 | productType = "com.apple.product-type.bundle.unit-test"; 260 | }; 261 | /* End PBXNativeTarget section */ 262 | 263 | /* Begin PBXProject section */ 264 | 83CBB9F71A601CBA00E9B192 /* Project object */ = { 265 | isa = PBXProject; 266 | attributes = { 267 | LastUpgradeCheck = 1130; 268 | TargetAttributes = { 269 | 00E356ED1AD99517003FC87E = { 270 | CreatedOnToolsVersion = 6.2; 271 | TestTargetID = 13B07F861A680F5B00A75B9A; 272 | }; 273 | 13B07F861A680F5B00A75B9A = { 274 | DevelopmentTeam = 6ABZKYHVHB; 275 | LastSwiftMigration = 1120; 276 | }; 277 | 2D02E47A1E0B4A5D006451C7 = { 278 | CreatedOnToolsVersion = 8.2.1; 279 | ProvisioningStyle = Automatic; 280 | }; 281 | 2D02E48F1E0B4A5D006451C7 = { 282 | CreatedOnToolsVersion = 8.2.1; 283 | ProvisioningStyle = Automatic; 284 | TestTargetID = 2D02E47A1E0B4A5D006451C7; 285 | }; 286 | }; 287 | }; 288 | buildConfigurationList = 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "WalletManagerExample" */; 289 | compatibilityVersion = "Xcode 3.2"; 290 | developmentRegion = en; 291 | hasScannedForEncodings = 0; 292 | knownRegions = ( 293 | en, 294 | Base, 295 | ); 296 | mainGroup = 83CBB9F61A601CBA00E9B192; 297 | productRefGroup = 83CBBA001A601CBA00E9B192 /* Products */; 298 | projectDirPath = ""; 299 | projectRoot = ""; 300 | targets = ( 301 | 13B07F861A680F5B00A75B9A /* WalletManagerExample */, 302 | 00E356ED1AD99517003FC87E /* WalletManagerExampleTests */, 303 | 2D02E47A1E0B4A5D006451C7 /* WalletManagerExample-tvOS */, 304 | 2D02E48F1E0B4A5D006451C7 /* WalletManagerExample-tvOSTests */, 305 | ); 306 | }; 307 | /* End PBXProject section */ 308 | 309 | /* Begin PBXResourcesBuildPhase section */ 310 | 00E356EC1AD99517003FC87E /* Resources */ = { 311 | isa = PBXResourcesBuildPhase; 312 | buildActionMask = 2147483647; 313 | files = ( 314 | ); 315 | runOnlyForDeploymentPostprocessing = 0; 316 | }; 317 | 13B07F8E1A680F5B00A75B9A /* Resources */ = { 318 | isa = PBXResourcesBuildPhase; 319 | buildActionMask = 2147483647; 320 | files = ( 321 | 81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */, 322 | 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */, 323 | ); 324 | runOnlyForDeploymentPostprocessing = 0; 325 | }; 326 | 2D02E4791E0B4A5D006451C7 /* Resources */ = { 327 | isa = PBXResourcesBuildPhase; 328 | buildActionMask = 2147483647; 329 | files = ( 330 | 2D02E4BD1E0B4A84006451C7 /* Images.xcassets in Resources */, 331 | ); 332 | runOnlyForDeploymentPostprocessing = 0; 333 | }; 334 | 2D02E48E1E0B4A5D006451C7 /* Resources */ = { 335 | isa = PBXResourcesBuildPhase; 336 | buildActionMask = 2147483647; 337 | files = ( 338 | ); 339 | runOnlyForDeploymentPostprocessing = 0; 340 | }; 341 | /* End PBXResourcesBuildPhase section */ 342 | 343 | /* Begin PBXShellScriptBuildPhase section */ 344 | 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */ = { 345 | isa = PBXShellScriptBuildPhase; 346 | buildActionMask = 2147483647; 347 | files = ( 348 | ); 349 | inputPaths = ( 350 | ); 351 | name = "Bundle React Native code and images"; 352 | outputPaths = ( 353 | ); 354 | runOnlyForDeploymentPostprocessing = 0; 355 | shellPath = /bin/sh; 356 | shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh"; 357 | }; 358 | 2D02E4CB1E0B4B27006451C7 /* Bundle React Native Code And Images */ = { 359 | isa = PBXShellScriptBuildPhase; 360 | buildActionMask = 2147483647; 361 | files = ( 362 | ); 363 | inputPaths = ( 364 | ); 365 | name = "Bundle React Native Code And Images"; 366 | outputPaths = ( 367 | ); 368 | runOnlyForDeploymentPostprocessing = 0; 369 | shellPath = /bin/sh; 370 | shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh"; 371 | }; 372 | 4F0A6FC082772762E3E4C96C /* [CP] Check Pods Manifest.lock */ = { 373 | isa = PBXShellScriptBuildPhase; 374 | buildActionMask = 2147483647; 375 | files = ( 376 | ); 377 | inputFileListPaths = ( 378 | ); 379 | inputPaths = ( 380 | "${PODS_PODFILE_DIR_PATH}/Podfile.lock", 381 | "${PODS_ROOT}/Manifest.lock", 382 | ); 383 | name = "[CP] Check Pods Manifest.lock"; 384 | outputFileListPaths = ( 385 | ); 386 | outputPaths = ( 387 | "$(DERIVED_FILE_DIR)/Pods-WalletManagerExample-checkManifestLockResult.txt", 388 | ); 389 | runOnlyForDeploymentPostprocessing = 0; 390 | shellPath = /bin/sh; 391 | shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; 392 | showEnvVarsInLog = 0; 393 | }; 394 | C1D60D28B925C94BD88E79D7 /* [CP] Copy Pods Resources */ = { 395 | isa = PBXShellScriptBuildPhase; 396 | buildActionMask = 2147483647; 397 | files = ( 398 | ); 399 | inputPaths = ( 400 | "${PODS_ROOT}/Target Support Files/Pods-WalletManagerExample/Pods-WalletManagerExample-resources.sh", 401 | "${PODS_CONFIGURATION_BUILD_DIR}/React-Core/AccessibilityResources.bundle", 402 | ); 403 | name = "[CP] Copy Pods Resources"; 404 | outputPaths = ( 405 | "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/AccessibilityResources.bundle", 406 | ); 407 | runOnlyForDeploymentPostprocessing = 0; 408 | shellPath = /bin/sh; 409 | shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-WalletManagerExample/Pods-WalletManagerExample-resources.sh\"\n"; 410 | showEnvVarsInLog = 0; 411 | }; 412 | FD10A7F022414F080027D42C /* Start Packager */ = { 413 | isa = PBXShellScriptBuildPhase; 414 | buildActionMask = 2147483647; 415 | files = ( 416 | ); 417 | inputFileListPaths = ( 418 | ); 419 | inputPaths = ( 420 | ); 421 | name = "Start Packager"; 422 | outputFileListPaths = ( 423 | ); 424 | outputPaths = ( 425 | ); 426 | runOnlyForDeploymentPostprocessing = 0; 427 | shellPath = /bin/sh; 428 | shellScript = "export RCT_METRO_PORT=\"${RCT_METRO_PORT:=8081}\"\necho \"export RCT_METRO_PORT=${RCT_METRO_PORT}\" > \"${SRCROOT}/../node_modules/react-native/scripts/.packager.env\"\nif [ -z \"${RCT_NO_LAUNCH_PACKAGER+xxx}\" ] ; then\n if nc -w 5 -z localhost ${RCT_METRO_PORT} ; then\n if ! curl -s \"http://localhost:${RCT_METRO_PORT}/status\" | grep -q \"packager-status:running\" ; then\n echo \"Port ${RCT_METRO_PORT} already in use, packager is either not running or not running correctly\"\n exit 2\n fi\n else\n open \"$SRCROOT/../node_modules/react-native/scripts/launchPackager.command\" || echo \"Can't start packager automatically\"\n fi\nfi\n"; 429 | showEnvVarsInLog = 0; 430 | }; 431 | FD10A7F122414F3F0027D42C /* Start Packager */ = { 432 | isa = PBXShellScriptBuildPhase; 433 | buildActionMask = 2147483647; 434 | files = ( 435 | ); 436 | inputFileListPaths = ( 437 | ); 438 | inputPaths = ( 439 | ); 440 | name = "Start Packager"; 441 | outputFileListPaths = ( 442 | ); 443 | outputPaths = ( 444 | ); 445 | runOnlyForDeploymentPostprocessing = 0; 446 | shellPath = /bin/sh; 447 | shellScript = "export RCT_METRO_PORT=\"${RCT_METRO_PORT:=8081}\"\necho \"export RCT_METRO_PORT=${RCT_METRO_PORT}\" > \"${SRCROOT}/../node_modules/react-native/scripts/.packager.env\"\nif [ -z \"${RCT_NO_LAUNCH_PACKAGER+xxx}\" ] ; then\n if nc -w 5 -z localhost ${RCT_METRO_PORT} ; then\n if ! curl -s \"http://localhost:${RCT_METRO_PORT}/status\" | grep -q \"packager-status:running\" ; then\n echo \"Port ${RCT_METRO_PORT} already in use, packager is either not running or not running correctly\"\n exit 2\n fi\n else\n open \"$SRCROOT/../node_modules/react-native/scripts/launchPackager.command\" || echo \"Can't start packager automatically\"\n fi\nfi\n"; 448 | showEnvVarsInLog = 0; 449 | }; 450 | /* End PBXShellScriptBuildPhase section */ 451 | 452 | /* Begin PBXSourcesBuildPhase section */ 453 | 00E356EA1AD99517003FC87E /* Sources */ = { 454 | isa = PBXSourcesBuildPhase; 455 | buildActionMask = 2147483647; 456 | files = ( 457 | 00E356F31AD99517003FC87E /* WalletManagerExampleTests.m in Sources */, 458 | ); 459 | runOnlyForDeploymentPostprocessing = 0; 460 | }; 461 | 13B07F871A680F5B00A75B9A /* Sources */ = { 462 | isa = PBXSourcesBuildPhase; 463 | buildActionMask = 2147483647; 464 | files = ( 465 | 13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */, 466 | 13B07FC11A68108700A75B9A /* main.m in Sources */, 467 | ); 468 | runOnlyForDeploymentPostprocessing = 0; 469 | }; 470 | 2D02E4771E0B4A5D006451C7 /* Sources */ = { 471 | isa = PBXSourcesBuildPhase; 472 | buildActionMask = 2147483647; 473 | files = ( 474 | 2D02E4BF1E0B4AB3006451C7 /* main.m in Sources */, 475 | 2D02E4BC1E0B4A80006451C7 /* AppDelegate.m in Sources */, 476 | ); 477 | runOnlyForDeploymentPostprocessing = 0; 478 | }; 479 | 2D02E48C1E0B4A5D006451C7 /* Sources */ = { 480 | isa = PBXSourcesBuildPhase; 481 | buildActionMask = 2147483647; 482 | files = ( 483 | 2DCD954D1E0B4F2C00145EB5 /* WalletManagerExampleTests.m in Sources */, 484 | ); 485 | runOnlyForDeploymentPostprocessing = 0; 486 | }; 487 | /* End PBXSourcesBuildPhase section */ 488 | 489 | /* Begin PBXTargetDependency section */ 490 | 00E356F51AD99517003FC87E /* PBXTargetDependency */ = { 491 | isa = PBXTargetDependency; 492 | target = 13B07F861A680F5B00A75B9A /* WalletManagerExample */; 493 | targetProxy = 00E356F41AD99517003FC87E /* PBXContainerItemProxy */; 494 | }; 495 | 2D02E4921E0B4A5D006451C7 /* PBXTargetDependency */ = { 496 | isa = PBXTargetDependency; 497 | target = 2D02E47A1E0B4A5D006451C7 /* WalletManagerExample-tvOS */; 498 | targetProxy = 2D02E4911E0B4A5D006451C7 /* PBXContainerItemProxy */; 499 | }; 500 | /* End PBXTargetDependency section */ 501 | 502 | /* Begin XCBuildConfiguration section */ 503 | 00E356F61AD99517003FC87E /* Debug */ = { 504 | isa = XCBuildConfiguration; 505 | buildSettings = { 506 | BUNDLE_LOADER = "$(TEST_HOST)"; 507 | GCC_PREPROCESSOR_DEFINITIONS = ( 508 | "DEBUG=1", 509 | "$(inherited)", 510 | ); 511 | INFOPLIST_FILE = WalletManagerExampleTests/Info.plist; 512 | IPHONEOS_DEPLOYMENT_TARGET = 10.0; 513 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 514 | OTHER_LDFLAGS = ( 515 | "-ObjC", 516 | "-lc++", 517 | "$(inherited)", 518 | ); 519 | PRODUCT_BUNDLE_IDENTIFIER = com.example.reactnativewalletmanager; 520 | PRODUCT_NAME = "$(TARGET_NAME)"; 521 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/WalletManagerExample.app/WalletManagerExample"; 522 | }; 523 | name = Debug; 524 | }; 525 | 00E356F71AD99517003FC87E /* Release */ = { 526 | isa = XCBuildConfiguration; 527 | buildSettings = { 528 | BUNDLE_LOADER = "$(TEST_HOST)"; 529 | COPY_PHASE_STRIP = NO; 530 | INFOPLIST_FILE = WalletManagerExampleTests/Info.plist; 531 | IPHONEOS_DEPLOYMENT_TARGET = 10.0; 532 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 533 | OTHER_LDFLAGS = ( 534 | "-ObjC", 535 | "-lc++", 536 | "$(inherited)", 537 | ); 538 | PRODUCT_BUNDLE_IDENTIFIER = com.example.reactnativewalletmanager; 539 | PRODUCT_NAME = "$(TARGET_NAME)"; 540 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/WalletManagerExample.app/WalletManagerExample"; 541 | }; 542 | name = Release; 543 | }; 544 | 13B07F941A680F5B00A75B9A /* Debug */ = { 545 | isa = XCBuildConfiguration; 546 | baseConfigurationReference = 47F7ED3B7971BE374F7B8635 /* Pods-WalletManagerExample.debug.xcconfig */; 547 | buildSettings = { 548 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 549 | CLANG_ENABLE_MODULES = YES; 550 | CODE_SIGN_ENTITLEMENTS = WalletManagerExample/WalletManagerExample.entitlements; 551 | CURRENT_PROJECT_VERSION = 1; 552 | DEVELOPMENT_TEAM = 6ABZKYHVHB; 553 | ENABLE_BITCODE = NO; 554 | INFOPLIST_FILE = WalletManagerExample/Info.plist; 555 | IPHONEOS_DEPLOYMENT_TARGET = 11.0; 556 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 557 | OTHER_LDFLAGS = ( 558 | "$(inherited)", 559 | "-ObjC", 560 | "-lc++", 561 | ); 562 | PRODUCT_BUNDLE_IDENTIFIER = com.example.reactnativewalletmanager; 563 | PRODUCT_NAME = WalletManagerExample; 564 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 565 | SWIFT_VERSION = 5.0; 566 | VERSIONING_SYSTEM = "apple-generic"; 567 | }; 568 | name = Debug; 569 | }; 570 | 13B07F951A680F5B00A75B9A /* Release */ = { 571 | isa = XCBuildConfiguration; 572 | baseConfigurationReference = E00ACF0FDA8BF921659E2F9A /* Pods-WalletManagerExample.release.xcconfig */; 573 | buildSettings = { 574 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 575 | CLANG_ENABLE_MODULES = YES; 576 | CODE_SIGN_ENTITLEMENTS = WalletManagerExample/WalletManagerExample.entitlements; 577 | CURRENT_PROJECT_VERSION = 1; 578 | DEVELOPMENT_TEAM = 6ABZKYHVHB; 579 | INFOPLIST_FILE = WalletManagerExample/Info.plist; 580 | IPHONEOS_DEPLOYMENT_TARGET = 11.0; 581 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 582 | OTHER_LDFLAGS = ( 583 | "$(inherited)", 584 | "-ObjC", 585 | "-lc++", 586 | ); 587 | PRODUCT_BUNDLE_IDENTIFIER = com.example.reactnativewalletmanager; 588 | PRODUCT_NAME = WalletManagerExample; 589 | SWIFT_VERSION = 5.0; 590 | VERSIONING_SYSTEM = "apple-generic"; 591 | }; 592 | name = Release; 593 | }; 594 | 2D02E4971E0B4A5E006451C7 /* Debug */ = { 595 | isa = XCBuildConfiguration; 596 | buildSettings = { 597 | ASSETCATALOG_COMPILER_APPICON_NAME = "App Icon & Top Shelf Image"; 598 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage; 599 | CLANG_ANALYZER_NONNULL = YES; 600 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 601 | CLANG_WARN_INFINITE_RECURSION = YES; 602 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 603 | DEBUG_INFORMATION_FORMAT = dwarf; 604 | ENABLE_TESTABILITY = YES; 605 | GCC_NO_COMMON_BLOCKS = YES; 606 | INFOPLIST_FILE = "WalletManagerExample-tvOS/Info.plist"; 607 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 608 | OTHER_LDFLAGS = ( 609 | "$(inherited)", 610 | "-ObjC", 611 | "-lc++", 612 | ); 613 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.WalletManagerExample-tvOS"; 614 | PRODUCT_NAME = "$(TARGET_NAME)"; 615 | SDKROOT = appletvos; 616 | TARGETED_DEVICE_FAMILY = 3; 617 | TVOS_DEPLOYMENT_TARGET = 10.0; 618 | }; 619 | name = Debug; 620 | }; 621 | 2D02E4981E0B4A5E006451C7 /* Release */ = { 622 | isa = XCBuildConfiguration; 623 | buildSettings = { 624 | ASSETCATALOG_COMPILER_APPICON_NAME = "App Icon & Top Shelf Image"; 625 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage; 626 | CLANG_ANALYZER_NONNULL = YES; 627 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 628 | CLANG_WARN_INFINITE_RECURSION = YES; 629 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 630 | COPY_PHASE_STRIP = NO; 631 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 632 | GCC_NO_COMMON_BLOCKS = YES; 633 | INFOPLIST_FILE = "WalletManagerExample-tvOS/Info.plist"; 634 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 635 | OTHER_LDFLAGS = ( 636 | "$(inherited)", 637 | "-ObjC", 638 | "-lc++", 639 | ); 640 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.WalletManagerExample-tvOS"; 641 | PRODUCT_NAME = "$(TARGET_NAME)"; 642 | SDKROOT = appletvos; 643 | TARGETED_DEVICE_FAMILY = 3; 644 | TVOS_DEPLOYMENT_TARGET = 10.0; 645 | }; 646 | name = Release; 647 | }; 648 | 2D02E4991E0B4A5E006451C7 /* Debug */ = { 649 | isa = XCBuildConfiguration; 650 | buildSettings = { 651 | BUNDLE_LOADER = "$(TEST_HOST)"; 652 | CLANG_ANALYZER_NONNULL = YES; 653 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 654 | CLANG_WARN_INFINITE_RECURSION = YES; 655 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 656 | DEBUG_INFORMATION_FORMAT = dwarf; 657 | ENABLE_TESTABILITY = YES; 658 | GCC_NO_COMMON_BLOCKS = YES; 659 | INFOPLIST_FILE = "WalletManagerExample-tvOSTests/Info.plist"; 660 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 661 | OTHER_LDFLAGS = ( 662 | "$(inherited)", 663 | "-ObjC", 664 | "-lc++", 665 | ); 666 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.WalletManagerExample-tvOSTests"; 667 | PRODUCT_NAME = "$(TARGET_NAME)"; 668 | SDKROOT = appletvos; 669 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/WalletManagerExample-tvOS.app/WalletManagerExample-tvOS"; 670 | TVOS_DEPLOYMENT_TARGET = 10.1; 671 | }; 672 | name = Debug; 673 | }; 674 | 2D02E49A1E0B4A5E006451C7 /* Release */ = { 675 | isa = XCBuildConfiguration; 676 | buildSettings = { 677 | BUNDLE_LOADER = "$(TEST_HOST)"; 678 | CLANG_ANALYZER_NONNULL = YES; 679 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 680 | CLANG_WARN_INFINITE_RECURSION = YES; 681 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 682 | COPY_PHASE_STRIP = NO; 683 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 684 | GCC_NO_COMMON_BLOCKS = YES; 685 | INFOPLIST_FILE = "WalletManagerExample-tvOSTests/Info.plist"; 686 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 687 | OTHER_LDFLAGS = ( 688 | "$(inherited)", 689 | "-ObjC", 690 | "-lc++", 691 | ); 692 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.WalletManagerExample-tvOSTests"; 693 | PRODUCT_NAME = "$(TARGET_NAME)"; 694 | SDKROOT = appletvos; 695 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/WalletManagerExample-tvOS.app/WalletManagerExample-tvOS"; 696 | TVOS_DEPLOYMENT_TARGET = 10.1; 697 | }; 698 | name = Release; 699 | }; 700 | 83CBBA201A601CBA00E9B192 /* Debug */ = { 701 | isa = XCBuildConfiguration; 702 | buildSettings = { 703 | ALWAYS_SEARCH_USER_PATHS = NO; 704 | CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; 705 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 706 | CLANG_CXX_LIBRARY = "libc++"; 707 | CLANG_ENABLE_MODULES = YES; 708 | CLANG_ENABLE_OBJC_ARC = YES; 709 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 710 | CLANG_WARN_BOOL_CONVERSION = YES; 711 | CLANG_WARN_COMMA = YES; 712 | CLANG_WARN_CONSTANT_CONVERSION = YES; 713 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 714 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 715 | CLANG_WARN_EMPTY_BODY = YES; 716 | CLANG_WARN_ENUM_CONVERSION = YES; 717 | CLANG_WARN_INFINITE_RECURSION = YES; 718 | CLANG_WARN_INT_CONVERSION = YES; 719 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 720 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 721 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 722 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 723 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 724 | CLANG_WARN_STRICT_PROTOTYPES = YES; 725 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 726 | CLANG_WARN_UNREACHABLE_CODE = YES; 727 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 728 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 729 | COPY_PHASE_STRIP = NO; 730 | ENABLE_STRICT_OBJC_MSGSEND = YES; 731 | ENABLE_TESTABILITY = YES; 732 | GCC_C_LANGUAGE_STANDARD = gnu99; 733 | GCC_DYNAMIC_NO_PIC = NO; 734 | GCC_NO_COMMON_BLOCKS = YES; 735 | GCC_OPTIMIZATION_LEVEL = 0; 736 | GCC_PREPROCESSOR_DEFINITIONS = ( 737 | "DEBUG=1", 738 | "$(inherited)", 739 | ); 740 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 741 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 742 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 743 | GCC_WARN_UNDECLARED_SELECTOR = YES; 744 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 745 | GCC_WARN_UNUSED_FUNCTION = YES; 746 | GCC_WARN_UNUSED_VARIABLE = YES; 747 | IPHONEOS_DEPLOYMENT_TARGET = 10.0; 748 | LD_RUNPATH_SEARCH_PATHS = "/usr/lib/swift $(inherited)"; 749 | LIBRARY_SEARCH_PATHS = ( 750 | "\"$(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME)\"", 751 | "\"$(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME)\"", 752 | "\"$(inherited)\"", 753 | ); 754 | MTL_ENABLE_DEBUG_INFO = YES; 755 | ONLY_ACTIVE_ARCH = YES; 756 | SDKROOT = iphoneos; 757 | }; 758 | name = Debug; 759 | }; 760 | 83CBBA211A601CBA00E9B192 /* Release */ = { 761 | isa = XCBuildConfiguration; 762 | buildSettings = { 763 | ALWAYS_SEARCH_USER_PATHS = NO; 764 | CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; 765 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 766 | CLANG_CXX_LIBRARY = "libc++"; 767 | CLANG_ENABLE_MODULES = YES; 768 | CLANG_ENABLE_OBJC_ARC = YES; 769 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 770 | CLANG_WARN_BOOL_CONVERSION = YES; 771 | CLANG_WARN_COMMA = YES; 772 | CLANG_WARN_CONSTANT_CONVERSION = YES; 773 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 774 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 775 | CLANG_WARN_EMPTY_BODY = YES; 776 | CLANG_WARN_ENUM_CONVERSION = YES; 777 | CLANG_WARN_INFINITE_RECURSION = YES; 778 | CLANG_WARN_INT_CONVERSION = YES; 779 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 780 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 781 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 782 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 783 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 784 | CLANG_WARN_STRICT_PROTOTYPES = YES; 785 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 786 | CLANG_WARN_UNREACHABLE_CODE = YES; 787 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 788 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 789 | COPY_PHASE_STRIP = YES; 790 | ENABLE_NS_ASSERTIONS = NO; 791 | ENABLE_STRICT_OBJC_MSGSEND = YES; 792 | GCC_C_LANGUAGE_STANDARD = gnu99; 793 | GCC_NO_COMMON_BLOCKS = YES; 794 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 795 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 796 | GCC_WARN_UNDECLARED_SELECTOR = YES; 797 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 798 | GCC_WARN_UNUSED_FUNCTION = YES; 799 | GCC_WARN_UNUSED_VARIABLE = YES; 800 | IPHONEOS_DEPLOYMENT_TARGET = 10.0; 801 | LD_RUNPATH_SEARCH_PATHS = "/usr/lib/swift $(inherited)"; 802 | LIBRARY_SEARCH_PATHS = ( 803 | "\"$(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME)\"", 804 | "\"$(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME)\"", 805 | "\"$(inherited)\"", 806 | ); 807 | MTL_ENABLE_DEBUG_INFO = NO; 808 | SDKROOT = iphoneos; 809 | VALIDATE_PRODUCT = YES; 810 | }; 811 | name = Release; 812 | }; 813 | /* End XCBuildConfiguration section */ 814 | 815 | /* Begin XCConfigurationList section */ 816 | 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "WalletManagerExampleTests" */ = { 817 | isa = XCConfigurationList; 818 | buildConfigurations = ( 819 | 00E356F61AD99517003FC87E /* Debug */, 820 | 00E356F71AD99517003FC87E /* Release */, 821 | ); 822 | defaultConfigurationIsVisible = 0; 823 | defaultConfigurationName = Release; 824 | }; 825 | 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "WalletManagerExample" */ = { 826 | isa = XCConfigurationList; 827 | buildConfigurations = ( 828 | 13B07F941A680F5B00A75B9A /* Debug */, 829 | 13B07F951A680F5B00A75B9A /* Release */, 830 | ); 831 | defaultConfigurationIsVisible = 0; 832 | defaultConfigurationName = Release; 833 | }; 834 | 2D02E4BA1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "WalletManagerExample-tvOS" */ = { 835 | isa = XCConfigurationList; 836 | buildConfigurations = ( 837 | 2D02E4971E0B4A5E006451C7 /* Debug */, 838 | 2D02E4981E0B4A5E006451C7 /* Release */, 839 | ); 840 | defaultConfigurationIsVisible = 0; 841 | defaultConfigurationName = Release; 842 | }; 843 | 2D02E4BB1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "WalletManagerExample-tvOSTests" */ = { 844 | isa = XCConfigurationList; 845 | buildConfigurations = ( 846 | 2D02E4991E0B4A5E006451C7 /* Debug */, 847 | 2D02E49A1E0B4A5E006451C7 /* Release */, 848 | ); 849 | defaultConfigurationIsVisible = 0; 850 | defaultConfigurationName = Release; 851 | }; 852 | 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "WalletManagerExample" */ = { 853 | isa = XCConfigurationList; 854 | buildConfigurations = ( 855 | 83CBBA201A601CBA00E9B192 /* Debug */, 856 | 83CBBA211A601CBA00E9B192 /* Release */, 857 | ); 858 | defaultConfigurationIsVisible = 0; 859 | defaultConfigurationName = Release; 860 | }; 861 | /* End XCConfigurationList section */ 862 | }; 863 | rootObject = 83CBB9F71A601CBA00E9B192 /* Project object */; 864 | } 865 | -------------------------------------------------------------------------------- /example/ios/WalletManagerExample.xcodeproj/xcshareddata/xcschemes/WalletManagerExample.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 29 | 35 | 36 | 37 | 38 | 39 | 44 | 45 | 51 | 52 | 53 | 54 | 55 | 56 | 66 | 68 | 74 | 75 | 76 | 77 | 83 | 85 | 91 | 92 | 93 | 94 | 96 | 97 | 100 | 101 | 102 | -------------------------------------------------------------------------------- /example/ios/WalletManagerExample.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /example/ios/WalletManagerExample.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /example/ios/WalletManagerExample/AppDelegate.h: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) Facebook, Inc. and its affiliates. 3 | * 4 | * This source code is licensed under the MIT license found in the 5 | * LICENSE file in the root directory of this source tree. 6 | */ 7 | 8 | #import 9 | #import 10 | 11 | @interface AppDelegate : UIResponder 12 | 13 | @property (nonatomic, strong) UIWindow *window; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /example/ios/WalletManagerExample/AppDelegate.m: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) Facebook, Inc. and its affiliates. 3 | * 4 | * This source code is licensed under the MIT license found in the 5 | * LICENSE file in the root directory of this source tree. 6 | */ 7 | 8 | #import "AppDelegate.h" 9 | 10 | #import 11 | #import 12 | #import 13 | 14 | #ifdef FB_SONARKIT_ENABLED 15 | #import 16 | #import 17 | #import 18 | #import 19 | #import 20 | #import 21 | static void InitializeFlipper(UIApplication *application) { 22 | FlipperClient *client = [FlipperClient sharedClient]; 23 | SKDescriptorMapper *layoutDescriptorMapper = [[SKDescriptorMapper alloc] initWithDefaults]; 24 | [client addPlugin:[[FlipperKitLayoutPlugin alloc] initWithRootNode:application withDescriptorMapper:layoutDescriptorMapper]]; 25 | [client addPlugin:[[FKUserDefaultsPlugin alloc] initWithSuiteName:nil]]; 26 | [client addPlugin:[FlipperKitReactPlugin new]]; 27 | [client addPlugin:[[FlipperKitNetworkPlugin alloc] initWithNetworkAdapter:[SKIOSNetworkAdapter new]]]; 28 | [client start]; 29 | } 30 | #endif 31 | 32 | @implementation AppDelegate 33 | 34 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 35 | { 36 | #ifdef FB_SONARKIT_ENABLED 37 | InitializeFlipper(application); 38 | #endif 39 | RCTBridge *bridge = [[RCTBridge alloc] initWithDelegate:self launchOptions:launchOptions]; 40 | RCTRootView *rootView = [[RCTRootView alloc] initWithBridge:bridge 41 | moduleName:@"WalletManagerExample" 42 | initialProperties:nil]; 43 | 44 | rootView.backgroundColor = [[UIColor alloc] initWithRed:1.0f green:1.0f blue:1.0f alpha:1]; 45 | 46 | self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds]; 47 | UIViewController *rootViewController = [UIViewController new]; 48 | rootViewController.view = rootView; 49 | self.window.rootViewController = rootViewController; 50 | [self.window makeKeyAndVisible]; 51 | return YES; 52 | } 53 | 54 | - (NSURL *)sourceURLForBridge:(RCTBridge *)bridge 55 | { 56 | #if DEBUG 57 | return [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index" fallbackResource:nil]; 58 | #else 59 | return [[NSBundle mainBundle] URLForResource:@"main" withExtension:@"jsbundle"]; 60 | #endif 61 | } 62 | 63 | @end 64 | -------------------------------------------------------------------------------- /example/ios/WalletManagerExample/Images.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "scale" : "2x", 6 | "size" : "20x20" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "scale" : "3x", 11 | "size" : "20x20" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "scale" : "2x", 16 | "size" : "29x29" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "scale" : "3x", 21 | "size" : "29x29" 22 | }, 23 | { 24 | "idiom" : "iphone", 25 | "scale" : "2x", 26 | "size" : "40x40" 27 | }, 28 | { 29 | "idiom" : "iphone", 30 | "scale" : "3x", 31 | "size" : "40x40" 32 | }, 33 | { 34 | "idiom" : "iphone", 35 | "scale" : "2x", 36 | "size" : "60x60" 37 | }, 38 | { 39 | "idiom" : "iphone", 40 | "scale" : "3x", 41 | "size" : "60x60" 42 | }, 43 | { 44 | "idiom" : "ios-marketing", 45 | "scale" : "1x", 46 | "size" : "1024x1024" 47 | } 48 | ], 49 | "info" : { 50 | "author" : "xcode", 51 | "version" : 1 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /example/ios/WalletManagerExample/Images.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /example/ios/WalletManagerExample/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleDisplayName 8 | WalletManager Example 9 | CFBundleExecutable 10 | $(EXECUTABLE_NAME) 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | $(PRODUCT_NAME) 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | 1.0 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | 1 25 | LSRequiresIPhoneOS 26 | 27 | NSAppTransportSecurity 28 | 29 | NSAllowsArbitraryLoads 30 | 31 | NSExceptionDomains 32 | 33 | localhost 34 | 35 | NSExceptionAllowsInsecureHTTPLoads 36 | 37 | 38 | 39 | 40 | NSLocationWhenInUseUsageDescription 41 | 42 | UILaunchStoryboardName 43 | LaunchScreen 44 | UIRequiredDeviceCapabilities 45 | 46 | armv7 47 | 48 | UISupportedInterfaceOrientations 49 | 50 | UIInterfaceOrientationPortrait 51 | UIInterfaceOrientationLandscapeLeft 52 | UIInterfaceOrientationLandscapeRight 53 | 54 | UIViewControllerBasedStatusBarAppearance 55 | 56 | 57 | 58 | -------------------------------------------------------------------------------- /example/ios/WalletManagerExample/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 25 | 31 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | -------------------------------------------------------------------------------- /example/ios/WalletManagerExample/WalletManagerExample.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.apple.developer.pass-type-identifiers 6 | 7 | $(TeamIdentifierPrefix)* 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /example/ios/WalletManagerExample/main.m: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) Facebook, Inc. and its affiliates. 3 | * 4 | * This source code is licensed under the MIT license found in the 5 | * LICENSE file in the root directory of this source tree. 6 | */ 7 | 8 | #import 9 | 10 | #import "AppDelegate.h" 11 | 12 | int main(int argc, char * argv[]) { 13 | @autoreleasepool { 14 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /example/metro.config.js: -------------------------------------------------------------------------------- 1 | const path = require('path'); 2 | const blacklist = require('metro-config/src/defaults/blacklist'); 3 | const escape = require('escape-string-regexp'); 4 | const pak = require('../package.json'); 5 | 6 | const root = path.resolve(__dirname, '..'); 7 | 8 | const modules = Object.keys({ 9 | ...pak.peerDependencies, 10 | }); 11 | 12 | module.exports = { 13 | projectRoot: __dirname, 14 | watchFolders: [root], 15 | 16 | // We need to make sure that only one version is loaded for peerDependencies 17 | // So we blacklist them at the root, and alias them to the versions in example's node_modules 18 | resolver: { 19 | blacklistRE: blacklist( 20 | modules.map( 21 | (m) => 22 | new RegExp(`^${escape(path.join(root, 'node_modules', m))}\\/.*$`) 23 | ) 24 | ), 25 | 26 | extraNodeModules: modules.reduce((acc, name) => { 27 | acc[name] = path.join(__dirname, 'node_modules', name); 28 | return acc; 29 | }, {}), 30 | }, 31 | 32 | transformer: { 33 | getTransformOptions: async () => ({ 34 | transform: { 35 | experimentalImportSupport: false, 36 | inlineRequires: true, 37 | }, 38 | }), 39 | }, 40 | }; 41 | -------------------------------------------------------------------------------- /example/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "react-native-wallet-manager-example", 3 | "description": "Example app for react-native-wallet-manager", 4 | "version": "0.0.1", 5 | "private": true, 6 | "scripts": { 7 | "android": "react-native run-android", 8 | "ios": "react-native run-ios", 9 | "start": "react-native start" 10 | }, 11 | "dependencies": { 12 | "fs": "^0.0.1-security", 13 | "jsonwebtoken": "^9.0.2", 14 | "react": "16.13.1", 15 | "react-native": "0.63.4" 16 | }, 17 | "devDependencies": { 18 | "@babel/core": "^7.12.10", 19 | "@babel/runtime": "^7.12.5", 20 | "babel-plugin-module-resolver": "^4.0.0", 21 | "metro-react-native-babel-preset": "^0.64.0" 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /example/resources/SamplePasses/BoardingPass.pass/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/BoardingPass.pass/icon.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/BoardingPass.pass/icon@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/BoardingPass.pass/icon@2x.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/BoardingPass.pass/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/BoardingPass.pass/logo.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/BoardingPass.pass/logo@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/BoardingPass.pass/logo@2x.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/BoardingPass.pass/pass.json: -------------------------------------------------------------------------------- 1 | { 2 | "formatVersion" : 1, 3 | "passTypeIdentifier" : "pass.com.apple.devpubs.example", 4 | "serialNumber" : "gT6zrHkaW", 5 | "teamIdentifier" : "A93A5CM278", 6 | "webServiceURL" : "https://example.com/passes/", 7 | "authenticationToken" : "vxwxd7J8AlNNFPS8k0a0FfUFtq0ewzFdc", 8 | "relevantDate" : "2012-07-22T14:25-08:00", 9 | "locations" : [ 10 | { 11 | "longitude" : -122.3748889, 12 | "latitude" : 37.6189722 13 | } 14 | ], 15 | "barcode" : { 16 | "message" : "SFOJFK JOHN APPLESEED LH451 2012-07-22T14:25-08:00", 17 | "format" : "PKBarcodeFormatPDF417", 18 | "messageEncoding" : "iso-8859-1" 19 | }, 20 | "organizationName" : "Skyport Airways", 21 | "description" : "Skyport Boarding Pass", 22 | "logoText" : "Skyport Airways", 23 | "foregroundColor" : "rgb(22, 55, 110)", 24 | "backgroundColor" : "rgb(50, 91, 185)", 25 | "boardingPass" : { 26 | "transitType" : "PKTransitTypeAir", 27 | "headerFields" : [ 28 | { 29 | "label" : "GATE", 30 | "key" : "gate", 31 | "value" : "23", 32 | "changeMessage" : "Gate changed to %@." 33 | } 34 | ], 35 | "primaryFields" : [ 36 | { 37 | "key" : "depart", 38 | "label" : "SAN FRANCISCO", 39 | "value" : "SFO" 40 | }, 41 | { 42 | "key" : "arrive", 43 | "label" : "NEW YORK", 44 | "value" : "JFK" 45 | } 46 | ], 47 | "secondaryFields" : [ 48 | { 49 | "key" : "passenger", 50 | "label" : "PASSENGER", 51 | "value" : "John Appleseed" 52 | } 53 | ], 54 | "auxiliaryFields" : [ 55 | { 56 | "label" : "DEPART", 57 | "key" : "boardingTime", 58 | "value" : "2:25 PM", 59 | "changeMessage" : "Boarding time changed to %@." 60 | }, 61 | { 62 | "label" : "FLIGHT", 63 | "key" : "flightNewName", 64 | "value" : "815", 65 | "changeMessage" : "Flight number changed to %@" 66 | }, 67 | { 68 | "key" : "class", 69 | "label" : "DESIG.", 70 | "value" : "Coach" 71 | }, 72 | { 73 | "key" : "date", 74 | "label" : "DATE", 75 | "value" : "7/22", 76 | } 77 | ], 78 | "backFields" : [ 79 | { 80 | "key" : "passport", 81 | "label" : "PASSPORT", 82 | "value" : "Canadian/Canadien" 83 | }, 84 | { 85 | "key" : "residence", 86 | "label" : "RESIDENCE", 87 | "value" : "999 Infinite Loop, Apartment 42, Cupertino CA" 88 | } 89 | ] 90 | } 91 | } 92 | -------------------------------------------------------------------------------- /example/resources/SamplePasses/BoardingPass.pkpass: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/BoardingPass.pkpass -------------------------------------------------------------------------------- /example/resources/SamplePasses/Coupon.pass/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Coupon.pass/icon.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Coupon.pass/icon@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Coupon.pass/icon@2x.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Coupon.pass/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Coupon.pass/logo.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Coupon.pass/logo@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Coupon.pass/logo@2x.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Coupon.pass/pass.json: -------------------------------------------------------------------------------- 1 | { 2 | "formatVersion" : 1, 3 | "passTypeIdentifier" : "pass.com.apple.devpubs.example", 4 | "serialNumber" : "E5982H-I2", 5 | "teamIdentifier" : "A93A5CM278", 6 | "webServiceURL" : "https://example.com/passes/", 7 | "authenticationToken" : "vxwxd7J8AlNNFPS8k0a0FfUFtq0ewzFdc", 8 | "barcode" : { 9 | "message" : "123456789", 10 | "format" : "PKBarcodeFormatPDF417", 11 | "messageEncoding" : "iso-8859-1" 12 | }, 13 | "locations" : [ 14 | { 15 | "longitude" : -122.3748889, 16 | "latitude" : 37.6189722 17 | }, 18 | { 19 | "longitude" : -122.03118, 20 | "latitude" : 37.33182 21 | } 22 | ], 23 | "organizationName" : "Paw Planet", 24 | "description" : "Paw Planet Coupon", 25 | "logoText" : "Paw Planet", 26 | "foregroundColor" : "rgb(255, 255, 255)", 27 | "backgroundColor" : "rgb(206, 140, 53)", 28 | "coupon" : { 29 | "primaryFields" : [ 30 | { 31 | "key" : "offer", 32 | "label" : "Any premium dog food", 33 | "value" : "20% off" 34 | } 35 | ], 36 | "auxiliaryFields" : [ 37 | { 38 | "key" : "expires", 39 | "label" : "EXPIRES", 40 | "value" : "2013-04-24T10:00-05:00", 41 | "isRelative" : true, 42 | "dateStyle" : "PKDateStyleShort" 43 | } 44 | ] 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /example/resources/SamplePasses/Coupon.pkpass: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Coupon.pkpass -------------------------------------------------------------------------------- /example/resources/SamplePasses/Event.pass/background.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Event.pass/background.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Event.pass/background@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Event.pass/background@2x.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Event.pass/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Event.pass/icon.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Event.pass/icon@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Event.pass/icon@2x.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Event.pass/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Event.pass/logo.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Event.pass/logo@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Event.pass/logo@2x.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Event.pass/pass.json: -------------------------------------------------------------------------------- 1 | { 2 | "formatVersion" : 1, 3 | "passTypeIdentifier" : "pass.com.apple.devpubs.example", 4 | "serialNumber" : "nmyuxofgna", 5 | "teamIdentifier" : "A93A5CM278", 6 | "webServiceURL" : "https://example.com/passes/", 7 | "authenticationToken" : "vxwxd7J8AlNNFPS8k0a0FfUFtq0ewzFdc", 8 | "relevantDate" : "2011-12-08T13:00-08:00", 9 | "locations" : [ 10 | { 11 | "longitude" : -122.3748889, 12 | "latitude" : 37.6189722 13 | }, 14 | { 15 | "longitude" : -122.03118, 16 | "latitude" : 37.33182 17 | } 18 | ], 19 | "barcode" : { 20 | "message" : "123456789", 21 | "format" : "PKBarcodeFormatPDF417", 22 | "messageEncoding" : "iso-8859-1" 23 | }, 24 | "organizationName" : "Apple Inc.", 25 | "description" : "Apple Event Ticket", 26 | "foregroundColor" : "rgb(255, 255, 255)", 27 | "backgroundColor" : "rgb(60, 65, 76)", 28 | "eventTicket" : { 29 | "primaryFields" : [ 30 | { 31 | "key" : "event", 32 | "label" : "EVENT", 33 | "value" : "The Beat Goes On" 34 | } 35 | ], 36 | "secondaryFields" : [ 37 | { 38 | "key" : "loc", 39 | "label" : "LOCATION", 40 | "value" : "Moscone West" 41 | } 42 | ] 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /example/resources/SamplePasses/Event.pass/thumbnail.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Event.pass/thumbnail.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Event.pass/thumbnail@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Event.pass/thumbnail@2x.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Event.pkpass: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Event.pkpass -------------------------------------------------------------------------------- /example/resources/SamplePasses/Generic.pass/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Generic.pass/icon.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Generic.pass/icon@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Generic.pass/icon@2x.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Generic.pass/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Generic.pass/logo.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Generic.pass/logo@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Generic.pass/logo@2x.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Generic.pass/pass.json: -------------------------------------------------------------------------------- 1 | { 2 | "formatVersion" : 1, 3 | "passTypeIdentifier" : "pass.com.apple.devpubs.example", 4 | "serialNumber" : "8j23fm3", 5 | "webServiceURL" : "https://example.com/passes/", 6 | "authenticationToken" : "vxwxd7J8AlNNFPS8k0a0FfUFtq0ewzFdc", 7 | "teamIdentifier" : "A93A5CM278", 8 | "locations" : [ 9 | { 10 | "longitude" : -122.3748889, 11 | "latitude" : 37.6189722 12 | }, 13 | { 14 | "longitude" : -122.03118, 15 | "latitude" : 37.33182 16 | } 17 | ], 18 | "barcode" : { 19 | "message" : "123456789", 20 | "format" : "PKBarcodeFormatPDF417", 21 | "messageEncoding" : "iso-8859-1" 22 | }, 23 | "organizationName" : "Toy Town", 24 | "description" : "Toy Town Membership", 25 | "logoText" : "Toy Town", 26 | "foregroundColor" : "rgb(255, 255, 255)", 27 | "backgroundColor" : "rgb(197, 31, 31)", 28 | "generic" : { 29 | "primaryFields" : [ 30 | { 31 | "key" : "member", 32 | "value" : "Johnny Appleseed" 33 | } 34 | ], 35 | "secondaryFields" : [ 36 | { 37 | "key" : "subtitle", 38 | "label" : "MEMBER SINCE", 39 | "value" : "2012" 40 | } 41 | ], 42 | "auxiliaryFields" : [ 43 | { 44 | "key" : "level", 45 | "label" : "LEVEL", 46 | "value" : "Platinum" 47 | }, 48 | { 49 | "key" : "favorite", 50 | "label" : "FAVORITE TOY", 51 | "value" : "Bucky Ball Magnets", 52 | "textAlignment" : "PKTextAlignmentRight" 53 | } 54 | ], 55 | "backFields" : [ 56 | { 57 | "numberStyle" : "PKNumberStyleSpellOut", 58 | "label" : "spelled out", 59 | "key" : "numberStyle", 60 | "value" : 200 61 | }, 62 | { 63 | "label" : "in Reals", 64 | "key" : "currency", 65 | "value" : 200, 66 | "currencyCode" : "BRL" 67 | }, 68 | { 69 | "dateStyle" : "PKDateStyleFull", 70 | "label" : "full date", 71 | "key" : "dateFull", 72 | "value" : "1980-05-07T10:00-05:00" 73 | }, 74 | { 75 | "label" : "full time", 76 | "key" : "timeFull", 77 | "value" : "1980-05-07T10:00-05:00", 78 | "timeStyle" : "PKDateStyleFull" 79 | }, 80 | { 81 | "dateStyle" : "PKDateStyleShort", 82 | "label" : "short date and time", 83 | "key" : "dateTime", 84 | "value" : "1980-05-07T10:00-05:00", 85 | "timeStyle" : "PKDateStyleShort" 86 | }, 87 | { 88 | "dateStyle" : "PKDateStyleShort", 89 | "label" : "relative date", 90 | "key" : "relStyle", 91 | "value" : "2013-04-24T10:00-05:00", 92 | "isRelative" : true 93 | } 94 | ] 95 | } 96 | } 97 | -------------------------------------------------------------------------------- /example/resources/SamplePasses/Generic.pass/thumbnail.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Generic.pass/thumbnail.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Generic.pass/thumbnail@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Generic.pass/thumbnail@2x.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/Generic.pkpass: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/Generic.pkpass -------------------------------------------------------------------------------- /example/resources/SamplePasses/StoreCard.pass/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/StoreCard.pass/icon.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/StoreCard.pass/icon@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/StoreCard.pass/icon@2x.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/StoreCard.pass/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/StoreCard.pass/logo.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/StoreCard.pass/pass.json: -------------------------------------------------------------------------------- 1 | { 2 | "formatVersion" : 1, 3 | "passTypeIdentifier" : "pass.com.apple.devpubs.example", 4 | "serialNumber" : "p69f2J", 5 | "teamIdentifier" : "A93A5CM278", 6 | "webServiceURL" : "https://example.com/passes/", 7 | "authenticationToken" : "vxwxd7J8AlNNFPS8k0a0FfUFtq0ewzFdc", 8 | "locations" : [ 9 | { 10 | "longitude" : -122.3748889, 11 | "latitude" : 37.6189722 12 | } 13 | ], 14 | "barcode" : { 15 | "message" : "123456789", 16 | "format" : "PKBarcodeFormatPDF417", 17 | "messageEncoding" : "iso-8859-1" 18 | }, 19 | "organizationName" : "Organic Produce", 20 | "description" : "Organic Produce Loyalty Card", 21 | "logoText" : "Organic Produce", 22 | "foregroundColor" : "rgb(255, 255, 255)", 23 | "backgroundColor" : "rgb(55, 117, 50)", 24 | "storeCard" : { 25 | "primaryFields" : [ 26 | { 27 | "key" : "balance", 28 | "label" : "remaining balance", 29 | "value" : 21.75, 30 | "currencyCode" : "USD" 31 | } 32 | ], 33 | "auxiliaryFields" : [ 34 | { 35 | "key" : "deal", 36 | "label" : "Deal of the Day", 37 | "value" : "Lemons" 38 | } 39 | ] 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /example/resources/SamplePasses/StoreCard.pass/strip.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/StoreCard.pass/strip.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/StoreCard.pass/strip@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/StoreCard.pass/strip@2x.png -------------------------------------------------------------------------------- /example/resources/SamplePasses/StoreCard.pkpass: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/SamplePasses/StoreCard.pkpass -------------------------------------------------------------------------------- /example/resources/pass.pkpass: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dev-family/react-native-wallet-manager/7602011fe906f21673d59308d94852af671a0a92/example/resources/pass.pkpass -------------------------------------------------------------------------------- /example/src/App.tsx: -------------------------------------------------------------------------------- 1 | import * as React from 'react'; 2 | import { 3 | StyleSheet, 4 | View, 5 | SafeAreaView, 6 | StatusBar, 7 | Button, 8 | Platform, 9 | } from 'react-native'; 10 | import WalletManager from 'react-native-wallet-manager'; 11 | import WalletButton from './WalletButton'; 12 | 13 | export default function App() { 14 | const addPassToGoogleWallet = async () => { 15 | try { 16 | await WalletManager.addPassToGoogleWallet( 17 | 'eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJ3YWxsZXQtbWFuYWdlci1zZXJ2aWNlQHdhbGxldG1hbmFnZXJleGFtcGxlLmlhbS5nc2VydmljZWFjY291bnQuY29tIiwiYXVkIjoiZ29vZ2xlIiwib3JpZ2lucyI6W10sInR5cCI6InNhdmV0b3dhbGxldCIsInBheWxvYWQiOnsiZ2VuZXJpY09iamVjdHMiOlt7ImlkIjoiMzM4ODAwMDAwMDAyMjc4Njk5NC5tc2hiX2JjIiwiY2xhc3NJZCI6IjMzODgwMDAwMDAwMjI3ODY5OTQuY29kZWxhYl9jbGFzcyIsImdlbmVyaWNUeXBlIjoiR0VORVJJQ19UWVBFX1VOU1BFQ0lGSUVEIiwiaGV4QmFja2dyb3VuZENvbG9yIjoiIzM2MUNBNSIsImxvZ28iOnsic291cmNlVXJpIjp7InVyaSI6Imh0dHBzOi8vcmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbS9kZXYtZmFtaWx5L3JlYWN0LW5hdGl2ZS13YWxsZXQtbWFuYWdlci9yZWZzL2hlYWRzL21haW4vZG9jcy9sb2dvQW5kcm9pZC5wbmcifX0sImNhcmRUaXRsZSI6eyJkZWZhdWx0VmFsdWUiOnsibGFuZ3VhZ2UiOiJlbiIsInZhbHVlIjoiRGV2LkZhbWlseSJ9fSwic3ViaGVhZGVyIjp7ImRlZmF1bHRWYWx1ZSI6eyJsYW5ndWFnZSI6ImVuIiwidmFsdWUiOiJBdHRlbmRlZSJ9fSwiaGVhZGVyIjp7ImRlZmF1bHRWYWx1ZSI6eyJsYW5ndWFnZSI6ImVuIiwidmFsdWUiOiJNYXJpYSJ9fSwiYmFyY29kZSI6eyJ0eXBlIjoiUVJfQ09ERSIsInZhbHVlIjoiaHR0cHM6Ly9kZXYuZmFtaWx5In0sImhlcm9JbWFnZSI6eyJzb3VyY2VVcmkiOnsidXJpIjoiaHR0cHM6Ly9yYXcuZ2l0aHVidXNlcmNvbnRlbnQuY29tL2Rldi1mYW1pbHkvcmVhY3QtbmF0aXZlLXdhbGxldC1tYW5hZ2VyL3JlZnMvaGVhZHMvbWFpbi9kb2NzL3N0cmlwZS5wbmcifX0sInRleHRNb2R1bGVzRGF0YSI6W3siaGVhZGVyIjoiUE9JTlRTIiwiYm9keSI6IjEyMzQiLCJpZCI6InBvaW50cyJ9LHsiaGVhZGVyIjoiQ09OVEFDVFMiLCJib2R5IjoiMjAiLCJpZCI6ImNvbnRhY3RzIn1dfV19LCJpYXQiOjE3MjkwMDMwMDV9.jIBtnHEz6HGqhRwoNCPiq3oGAdAZV6fct9tfC7BxozRQNJtJQGK423l-g6tIK6k9XcedPSvoi5467I4OAfjXR4F2yu5xc-Ry-xMkNeLut1hNgHRd0g-L4moDrk3pSBiuP7k32IS5eouZ8bX_7VcklSLMV98YvD17HI0SCCaUjxv3i7CaGRFsJTM-45BAffp-10nqkL5LsrGt6Sk8a12UdqI7WRav0xzOvkyA2ieQYX1URWeoGS_F54-943LrBpa9AKoZK3ScdTz0K3Ts2VssjmXraV_8Ns3l70fyPzQejaTFTJ1TYpUBdr1cWfeduQUCJGZPYmotfqZ38rWZty1cBg' 18 | ); 19 | } catch (e) { 20 | console.log(e); 21 | } 22 | }; 23 | 24 | const canAddPasses = async () => { 25 | try { 26 | const result = await WalletManager.canAddPasses(); 27 | console.log(result); 28 | } catch (e) { 29 | console.log(e); 30 | } 31 | }; 32 | 33 | const addPass = async () => { 34 | try { 35 | const result = await WalletManager.addPassFromUrl( 36 | 'https://github.com/dev-family/react-native-wallet-manager/blob/main/example/resources/pass.pkpass?raw=true' 37 | ); 38 | console.log(result); 39 | } catch (e) { 40 | console.log(e); 41 | } 42 | }; 43 | 44 | const removePass = async () => { 45 | try { 46 | const result = await WalletManager.removePass( 47 | 'pass.family.dev.walletManager' 48 | ); 49 | console.log(`remove pass: ${result}`); 50 | } catch (e) { 51 | console.log(e, 'removePass'); 52 | } 53 | }; 54 | 55 | const hasPass = async () => { 56 | try { 57 | const result = await WalletManager.hasPass( 58 | 'pass.family.dev.walletManager' 59 | ); 60 | console.log(`has pass: ${result}`); 61 | } catch (e) { 62 | console.log(e, 'hasPass'); 63 | } 64 | }; 65 | 66 | const viewPass = async () => { 67 | try { 68 | const result = await WalletManager.viewInWallet( 69 | 'pass.family.dev.walletManager' 70 | ); 71 | console.log(result); 72 | } catch (e) { 73 | console.log(e, 'error Viewing Pass'); 74 | } 75 | }; 76 | 77 | return ( 78 | 79 | 80 | 81 | 84 |