├── .gitignore ├── .metadata ├── CHANGELOG.md ├── LICENSE ├── README.md ├── assets ├── images │ └── payments │ │ ├── logo.png │ │ ├── mastercard.svg │ │ ├── verve.png │ │ └── visa.svg └── json │ └── countries.json ├── example ├── .flutter-plugins-dependencies ├── .gitignore ├── .metadata ├── README.md ├── android │ ├── .gitignore │ ├── app │ │ ├── build.gradle │ │ └── src │ │ │ ├── debug │ │ │ └── AndroidManifest.xml │ │ │ ├── main │ │ │ ├── AndroidManifest.xml │ │ │ ├── kotlin │ │ │ │ └── com │ │ │ │ │ └── example │ │ │ │ │ └── example │ │ │ │ │ └── MainActivity.kt │ │ │ └── res │ │ │ │ ├── drawable │ │ │ │ └── launch_background.xml │ │ │ │ ├── mipmap-hdpi │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-mdpi │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xhdpi │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xxhdpi │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xxxhdpi │ │ │ │ └── ic_launcher.png │ │ │ │ └── values │ │ │ │ └── styles.xml │ │ │ └── profile │ │ │ └── AndroidManifest.xml │ ├── build.gradle │ ├── gradle.properties │ ├── gradle │ │ └── wrapper │ │ │ └── gradle-wrapper.properties │ └── settings.gradle ├── ios │ ├── .gitignore │ ├── Flutter │ │ ├── .last_build_id │ │ ├── AppFrameworkInfo.plist │ │ ├── Debug.xcconfig │ │ ├── Release.xcconfig │ │ └── flutter_export_environment.sh │ ├── Podfile │ ├── Podfile.lock │ ├── Runner.xcodeproj │ │ ├── project.pbxproj │ │ ├── project.xcworkspace │ │ │ ├── contents.xcworkspacedata │ │ │ └── xcshareddata │ │ │ │ ├── IDEWorkspaceChecks.plist │ │ │ │ └── WorkspaceSettings.xcsettings │ │ └── xcshareddata │ │ │ └── xcschemes │ │ │ └── Runner.xcscheme │ ├── Runner.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ │ ├── IDEWorkspaceChecks.plist │ │ │ └── WorkspaceSettings.xcsettings │ └── Runner │ │ ├── AppDelegate.swift │ │ ├── Assets.xcassets │ │ ├── AppIcon.appiconset │ │ │ ├── Contents.json │ │ │ ├── Icon-App-1024x1024@1x.png │ │ │ ├── Icon-App-20x20@1x.png │ │ │ ├── Icon-App-20x20@2x.png │ │ │ ├── Icon-App-20x20@3x.png │ │ │ ├── Icon-App-29x29@1x.png │ │ │ ├── Icon-App-29x29@2x.png │ │ │ ├── Icon-App-29x29@3x.png │ │ │ ├── Icon-App-40x40@1x.png │ │ │ ├── Icon-App-40x40@2x.png │ │ │ ├── Icon-App-40x40@3x.png │ │ │ ├── Icon-App-60x60@2x.png │ │ │ ├── Icon-App-60x60@3x.png │ │ │ ├── Icon-App-76x76@1x.png │ │ │ ├── Icon-App-76x76@2x.png │ │ │ └── Icon-App-83.5x83.5@2x.png │ │ └── LaunchImage.imageset │ │ │ ├── Contents.json │ │ │ ├── LaunchImage.png │ │ │ ├── LaunchImage@2x.png │ │ │ ├── LaunchImage@3x.png │ │ │ └── README.md │ │ ├── Base.lproj │ │ ├── LaunchScreen.storyboard │ │ └── Main.storyboard │ │ ├── Info.plist │ │ └── Runner-Bridging-Header.h ├── lib │ ├── core │ │ └── pay.dart │ ├── generated_plugin_registrant.dart │ └── main.dart ├── pubspec.lock ├── pubspec.yaml ├── s1.png ├── s2.png └── test │ └── widget_test.dart ├── lib ├── flutter_rave.dart ├── rave_provider.dart └── src │ ├── api │ ├── error_codes.dart │ ├── exceptions │ │ ├── auth_failed.dart │ │ └── general.dart │ └── services │ │ ├── http_service.dart │ │ └── rave_api_service.dart │ ├── config │ ├── api.dart │ └── constants.dart │ ├── ui │ └── components │ │ └── overlay_loader_widget.dart │ └── utils │ ├── assets.dart │ ├── credit_card.dart │ └── masked_input_formatter.dart ├── pubspec.lock ├── pubspec.yaml └── test └── flutter_rave_test.dart /.gitignore: -------------------------------------------------------------------------------- 1 | # Miscellaneous 2 | *.class 3 | *.log 4 | *.pyc 5 | *.swp 6 | .DS_Store 7 | .atom/ 8 | .buildlog/ 9 | .history 10 | .svn/ 11 | 12 | # IntelliJ related 13 | *.iml 14 | *.ipr 15 | *.iws 16 | .idea/ 17 | 18 | # Visual Studio Code related 19 | .vscode/ 20 | 21 | # Flutter/Dart/Pub related 22 | **/doc/api/ 23 | .dart_tool/ 24 | .flutter-plugins 25 | .packages 26 | .pub-cache/ 27 | .pub/ 28 | build/ 29 | 30 | # Android related 31 | **/android/**/gradle-wrapper.jar 32 | **/android/.gradle 33 | **/android/captures/ 34 | **/android/gradlew 35 | **/android/gradlew.bat 36 | **/android/local.properties 37 | **/android/**/GeneratedPluginRegistrant.java 38 | 39 | # iOS/XCode related 40 | **/ios/**/*.mode1v3 41 | **/ios/**/*.mode2v3 42 | **/ios/**/*.moved-aside 43 | **/ios/**/*.pbxuser 44 | **/ios/**/*.perspectivev3 45 | **/ios/**/*sync/ 46 | **/ios/**/.sconsign.dblite 47 | **/ios/**/.tags* 48 | **/ios/**/.vagrant/ 49 | **/ios/**/DerivedData/ 50 | **/ios/**/Icon? 51 | **/ios/**/Pods/ 52 | **/ios/**/.symlinks/ 53 | **/ios/**/profile 54 | **/ios/**/xcuserdata 55 | **/ios/.generated/ 56 | **/ios/Flutter/App.framework 57 | **/ios/Flutter/Flutter.framework 58 | **/ios/Flutter/Generated.xcconfig 59 | **/ios/Flutter/app.flx 60 | **/ios/Flutter/app.zip 61 | **/ios/Flutter/flutter_assets/ 62 | **/ios/ServiceDefinitions.json 63 | **/ios/Runner/GeneratedPluginRegistrant.* 64 | 65 | # Exceptions to above rules. 66 | !**/ios/**/default.mode1v3 67 | !**/ios/**/default.mode2v3 68 | !**/ios/**/default.pbxuser 69 | !**/ios/**/default.perspectivev3 70 | !/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages 71 | -------------------------------------------------------------------------------- /.metadata: -------------------------------------------------------------------------------- 1 | # This file tracks properties of this Flutter project. 2 | # Used by Flutter tool to assess capabilities and perform upgrades etc. 3 | # 4 | # This file should be version controlled and should not be manually edited. 5 | 6 | version: 7 | revision: 7a4c33425ddd78c54aba07d86f3f9a4a0051769b 8 | channel: stable 9 | 10 | project_type: package 11 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | ## [0.0.1] - 04-06-2019. 2 | 3 | * Initial release. 4 | 5 | ## [0.0.2] - 06-06-2019. 6 | 7 | * Added Subaccount field. 8 | 9 | 10 | ## [0.0.3] - 06-06-2019. 11 | 12 | * Bug Fixes 13 | 14 | ## [0.0.4] - 09-06-2019. 15 | 16 | * Bug Fixes 17 | 18 | ## [0.0.5] - 12-07-2019. 19 | 20 | * Bug Fixes 21 | 22 | ## [0.0.6] - 12-10-2019. 23 | 24 | * Bug Fixes 25 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Apache License 2 | Version 2.0, January 2004 3 | http://www.apache.org/licenses/ 4 | 5 | TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 6 | 7 | 1. Definitions. 8 | 9 | "License" shall mean the terms and conditions for use, reproduction, 10 | and distribution as defined by Sections 1 through 9 of this document. 11 | 12 | "Licensor" shall mean the copyright owner or entity authorized by 13 | the copyright owner that is granting the License. 14 | 15 | "Legal Entity" shall mean the union of the acting entity and all 16 | other entities that control, are controlled by, or are under common 17 | control with that entity. For the purposes of this definition, 18 | "control" means (i) the power, direct or indirect, to cause the 19 | direction or management of such entity, whether by contract or 20 | otherwise, or (ii) ownership of fifty percent (50%) or more of the 21 | outstanding shares, or (iii) beneficial ownership of such entity. 22 | 23 | "You" (or "Your") shall mean an individual or Legal Entity 24 | exercising permissions granted by this License. 25 | 26 | "Source" form shall mean the preferred form for making modifications, 27 | including but not limited to software source code, documentation 28 | source, and configuration files. 29 | 30 | "Object" form shall mean any form resulting from mechanical 31 | transformation or translation of a Source form, including but 32 | not limited to compiled object code, generated documentation, 33 | and conversions to other media types. 34 | 35 | "Work" shall mean the work of authorship, whether in Source or 36 | Object form, made available under the License, as indicated by a 37 | copyright notice that is included in or attached to the work 38 | (an example is provided in the Appendix below). 39 | 40 | "Derivative Works" shall mean any work, whether in Source or Object 41 | form, that is based on (or derived from) the Work and for which the 42 | editorial revisions, annotations, elaborations, or other modifications 43 | represent, as a whole, an original work of authorship. For the purposes 44 | of this License, Derivative Works shall not include works that remain 45 | separable from, or merely link (or bind by name) to the interfaces of, 46 | the Work and Derivative Works thereof. 47 | 48 | "Contribution" shall mean any work of authorship, including 49 | the original version of the Work and any modifications or additions 50 | to that Work or Derivative Works thereof, that is intentionally 51 | submitted to Licensor for inclusion in the Work by the copyright owner 52 | or by an individual or Legal Entity authorized to submit on behalf of 53 | the copyright owner. For the purposes of this definition, "submitted" 54 | means any form of electronic, verbal, or written communication sent 55 | to the Licensor or its representatives, including but not limited to 56 | communication on electronic mailing lists, source code control systems, 57 | and issue tracking systems that are managed by, or on behalf of, the 58 | Licensor for the purpose of discussing and improving the Work, but 59 | excluding communication that is conspicuously marked or otherwise 60 | designated in writing by the copyright owner as "Not a Contribution." 61 | 62 | "Contributor" shall mean Licensor and any individual or Legal Entity 63 | on behalf of whom a Contribution has been received by Licensor and 64 | subsequently incorporated within the Work. 65 | 66 | 2. Grant of Copyright License. Subject to the terms and conditions of 67 | this License, each Contributor hereby grants to You a perpetual, 68 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 69 | copyright license to reproduce, prepare Derivative Works of, 70 | publicly display, publicly perform, sublicense, and distribute the 71 | Work and such Derivative Works in Source or Object form. 72 | 73 | 3. Grant of Patent License. Subject to the terms and conditions of 74 | this License, each Contributor hereby grants to You a perpetual, 75 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 76 | (except as stated in this section) patent license to make, have made, 77 | use, offer to sell, sell, import, and otherwise transfer the Work, 78 | where such license applies only to those patent claims licensable 79 | by such Contributor that are necessarily infringed by their 80 | Contribution(s) alone or by combination of their Contribution(s) 81 | with the Work to which such Contribution(s) was submitted. If You 82 | institute patent litigation against any entity (including a 83 | cross-claim or counterclaim in a lawsuit) alleging that the Work 84 | or a Contribution incorporated within the Work constitutes direct 85 | or contributory patent infringement, then any patent licenses 86 | granted to You under this License for that Work shall terminate 87 | as of the date such litigation is filed. 88 | 89 | 4. Redistribution. You may reproduce and distribute copies of the 90 | Work or Derivative Works thereof in any medium, with or without 91 | modifications, and in Source or Object form, provided that You 92 | meet the following conditions: 93 | 94 | (a) You must give any other recipients of the Work or 95 | Derivative Works a copy of this License; and 96 | 97 | (b) You must cause any modified files to carry prominent notices 98 | stating that You changed the files; and 99 | 100 | (c) You must retain, in the Source form of any Derivative Works 101 | that You distribute, all copyright, patent, trademark, and 102 | attribution notices from the Source form of the Work, 103 | excluding those notices that do not pertain to any part of 104 | the Derivative Works; and 105 | 106 | (d) If the Work includes a "NOTICE" text file as part of its 107 | distribution, then any Derivative Works that You distribute must 108 | include a readable copy of the attribution notices contained 109 | within such NOTICE file, excluding those notices that do not 110 | pertain to any part of the Derivative Works, in at least one 111 | of the following places: within a NOTICE text file distributed 112 | as part of the Derivative Works; within the Source form or 113 | documentation, if provided along with the Derivative Works; or, 114 | within a display generated by the Derivative Works, if and 115 | wherever such third-party notices normally appear. The contents 116 | of the NOTICE file are for informational purposes only and 117 | do not modify the License. You may add Your own attribution 118 | notices within Derivative Works that You distribute, alongside 119 | or as an addendum to the NOTICE text from the Work, provided 120 | that such additional attribution notices cannot be construed 121 | as modifying the License. 122 | 123 | You may add Your own copyright statement to Your modifications and 124 | may provide additional or different license terms and conditions 125 | for use, reproduction, or distribution of Your modifications, or 126 | for any such Derivative Works as a whole, provided Your use, 127 | reproduction, and distribution of the Work otherwise complies with 128 | the conditions stated in this License. 129 | 130 | 5. Submission of Contributions. Unless You explicitly state otherwise, 131 | any Contribution intentionally submitted for inclusion in the Work 132 | by You to the Licensor shall be under the terms and conditions of 133 | this License, without any additional terms or conditions. 134 | Notwithstanding the above, nothing herein shall supersede or modify 135 | the terms of any separate license agreement you may have executed 136 | with Licensor regarding such Contributions. 137 | 138 | 6. Trademarks. This License does not grant permission to use the trade 139 | names, trademarks, service marks, or product names of the Licensor, 140 | except as required for reasonable and customary use in describing the 141 | origin of the Work and reproducing the content of the NOTICE file. 142 | 143 | 7. Disclaimer of Warranty. Unless required by applicable law or 144 | agreed to in writing, Licensor provides the Work (and each 145 | Contributor provides its Contributions) on an "AS IS" BASIS, 146 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 147 | implied, including, without limitation, any warranties or conditions 148 | of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A 149 | PARTICULAR PURPOSE. You are solely responsible for determining the 150 | appropriateness of using or redistributing the Work and assume any 151 | risks associated with Your exercise of permissions under this License. 152 | 153 | 8. Limitation of Liability. In no event and under no legal theory, 154 | whether in tort (including negligence), contract, or otherwise, 155 | unless required by applicable law (such as deliberate and grossly 156 | negligent acts) or agreed to in writing, shall any Contributor be 157 | liable to You for damages, including any direct, indirect, special, 158 | incidental, or consequential damages of any character arising as a 159 | result of this License or out of the use or inability to use the 160 | Work (including but not limited to damages for loss of goodwill, 161 | work stoppage, computer failure or malfunction, or any and all 162 | other commercial damages or losses), even if such Contributor 163 | has been advised of the possibility of such damages. 164 | 165 | 9. Accepting Warranty or Additional Liability. While redistributing 166 | the Work or Derivative Works thereof, You may choose to offer, 167 | and charge a fee for, acceptance of support, warranty, indemnity, 168 | or other liability obligations and/or rights consistent with this 169 | License. However, in accepting such obligations, You may act only 170 | on Your own behalf and on Your sole responsibility, not on behalf 171 | of any other Contributor, and only if You agree to indemnify, 172 | defend, and hold each Contributor harmless for any liability 173 | incurred by, or claims asserted against, such Contributor by reason 174 | of your accepting any such warranty or additional liability. 175 | 176 | END OF TERMS AND CONDITIONS 177 | 178 | APPENDIX: How to apply the Apache License to your work. 179 | 180 | To apply the Apache License to your work, attach the following 181 | boilerplate notice, with the fields enclosed by brackets "[]" 182 | replaced with your own identifying information. (Don't include 183 | the brackets!) The text should be enclosed in the appropriate 184 | comment syntax for the file format. We also recommend that a 185 | file or class name and description of purpose be included on the 186 | same "printed page" as the copyright notice for easier 187 | identification within third-party archives. 188 | 189 | Copyright [yyyy] [name of copyright owner] 190 | 191 | Licensed under the Apache License, Version 2.0 (the "License"); 192 | you may not use this file except in compliance with the License. 193 | You may obtain a copy of the License at 194 | 195 | http://www.apache.org/licenses/LICENSE-2.0 196 | 197 | Unless required by applicable law or agreed to in writing, software 198 | distributed under the License is distributed on an "AS IS" BASIS, 199 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 200 | See the License for the specific language governing permissions and 201 | limitations under the License. -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Rave by Flutterwave Plugin for Flutter 2 | 3 | [![pub package](https://img.shields.io/pub/v/flutter_rave.svg)](https://pub.dartlang.org/packages/flutter_rave) 4 | 5 | A Flutter plugin for making payments via Rave by Flutterwave Payment Gateway. Fully 6 | supports Android and iOS. 7 | 8 |
9 | 10 | 11 | 14 | 17 | 18 |
12 | 13 | 15 | 16 |
19 |
20 | 21 | 22 | ## Installation 23 | To use this plugin, add `flutter_rave` as a [dependency in your pubspec.yaml file](https://flutter.io/platform-plugins/). 24 | 25 | Then initialize the plugin preferably in the `initState` of your widget. 26 | 27 | ``` dart 28 | import 'package:flutter_rave/flutter_rave.dart'; 29 | 30 | class _MyHomePageState extends State { 31 | @override 32 | Widget build(BuildContext context) { 33 | return Scaffold( 34 | appBar: AppBar( 35 | title: Text(widget.title), 36 | ), 37 | body: Builder( 38 | builder: (context) => SingleChildScrollView( 39 | child: Column( 40 | mainAxisAlignment: MainAxisAlignment.start, 41 | children: [ 42 | Text( 43 | 'Pay Me', 44 | ), 45 | FlatButton.icon( 46 | onPressed: () { 47 | _pay(context); 48 | }, 49 | icon: Icon(Icons.email), 50 | label: Text("Pay"), 51 | ), 52 | ], 53 | ), 54 | ), 55 | ), 56 | ); 57 | } 58 | 59 | _pay(BuildContext context) { 60 | final _rave = RaveCardPayment( 61 | isDemo: true, 62 | encKey: "c53e399709de57d42e2e36ca", 63 | publicKey: "FLWPUBK-d97d92534644f21f8c50802f0ff44e02-X", 64 | transactionRef: "SCH${DateTime.now().millisecondsSinceEpoch}", 65 | amount: 100, 66 | email: "demo1@example.com", 67 | onSuccess: (response) { 68 | print("$response"); 69 | print("Transaction Successful"); 70 | 71 | if (mounted) { 72 | Scaffold.of(context).showSnackBar( 73 | SnackBar( 74 | content: Text("Transaction Sucessful!"), 75 | backgroundColor: Colors.green, 76 | duration: Duration( 77 | seconds: 5, 78 | ), 79 | ), 80 | ); 81 | } 82 | }, 83 | onFailure: (err) { 84 | print("$err"); 85 | print("Transaction failed"); 86 | }, 87 | onClosed: () { 88 | print("Transaction closed"); 89 | }, 90 | context: context, 91 | ); 92 | 93 | _rave.process(); 94 | } 95 | } 96 | ``` 97 | 98 | No other configuration required—the plugin works out of the box. 99 | 100 | ## Running Example project 101 | For help getting started with Flutter, view the online [documentation](https://flutter.io/). 102 | 103 | An [example project](https://github.com/akacokafor/flutter_rave/tree/master/example) has been provided in this plugin. 104 | Clone this repo and navigate to the **example** folder. Open it with a supported IDE or execute `flutter run` from that folder in terminal. 105 | 106 | ## Contributing, Issues and Bug Reports 107 | The project is open to public contribution. Please feel very free to contribute. 108 | Experienced an issue or want to report a bug? Please, [report it here](https://github.com/akacokafor/flutter_rave/issues). Remember to be as descriptive as possible. 109 | -------------------------------------------------------------------------------- /assets/images/payments/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/assets/images/payments/logo.png -------------------------------------------------------------------------------- /assets/images/payments/mastercard.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 7 | 9 | 10 | 15 | 19 | 23 | 24 | 26 | 29 | 32 | 36 | 39 | 42 | 44 | 46 | 50 | 52 | 53 | 54 | 56 | 59 | 62 | 65 | 67 | 70 | 72 | 74 | 77 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | -------------------------------------------------------------------------------- /assets/images/payments/verve.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/assets/images/payments/verve.png -------------------------------------------------------------------------------- /assets/images/payments/visa.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 6 | 7 | 8 | 18 | 19 | 20 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | -------------------------------------------------------------------------------- /example/.flutter-plugins-dependencies: -------------------------------------------------------------------------------- 1 | {"info":"This is a generated file; do not edit or check into version control.","plugins":{"ios":[{"name":"flutter_webview_plugin","path":"/Users/chiziaruhoma/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_webview_plugin-0.3.11/","dependencies":[]},{"name":"url_launcher","path":"/Users/chiziaruhoma/flutter/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.5/","dependencies":[]},{"name":"webview_flutter","path":"/Users/chiziaruhoma/flutter/.pub-cache/hosted/pub.dartlang.org/webview_flutter-0.3.21/","dependencies":[]}],"android":[{"name":"flutter_webview_plugin","path":"/Users/chiziaruhoma/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_webview_plugin-0.3.11/","dependencies":[]},{"name":"url_launcher","path":"/Users/chiziaruhoma/flutter/.pub-cache/hosted/pub.dartlang.org/url_launcher-5.4.5/","dependencies":[]},{"name":"webview_flutter","path":"/Users/chiziaruhoma/flutter/.pub-cache/hosted/pub.dartlang.org/webview_flutter-0.3.21/","dependencies":[]}],"macos":[{"name":"url_launcher_macos","path":"/Users/chiziaruhoma/flutter/.pub-cache/hosted/pub.dartlang.org/url_launcher_macos-0.0.1+5/","dependencies":[]}],"linux":[],"windows":[],"web":[{"name":"url_launcher_web","path":"/Users/chiziaruhoma/flutter/.pub-cache/hosted/pub.dartlang.org/url_launcher_web-0.1.1+4/","dependencies":[]}]},"dependencyGraph":[{"name":"flutter_webview_plugin","dependencies":[]},{"name":"url_launcher","dependencies":["url_launcher_web","url_launcher_macos"]},{"name":"url_launcher_macos","dependencies":[]},{"name":"url_launcher_web","dependencies":[]},{"name":"webview_flutter","dependencies":[]}],"date_created":"2020-05-07 22:00:41.539681","version":"1.18.0-12.0.pre"} -------------------------------------------------------------------------------- /example/.gitignore: -------------------------------------------------------------------------------- 1 | # Miscellaneous 2 | *.class 3 | *.log 4 | *.pyc 5 | *.swp 6 | .DS_Store 7 | .atom/ 8 | .buildlog/ 9 | .history 10 | .svn/ 11 | /web/ 12 | /macos/ 13 | 14 | # IntelliJ related 15 | *.iml 16 | *.ipr 17 | *.iws 18 | .idea/ 19 | 20 | # Visual Studio Code related 21 | .vscode/ 22 | 23 | # Flutter/Dart/Pub related 24 | **/doc/api/ 25 | .dart_tool/ 26 | .flutter-plugins 27 | .packages 28 | .pub-cache/ 29 | .pub/ 30 | /build/ 31 | 32 | # Android related 33 | **/android/**/gradle-wrapper.jar 34 | **/android/.gradle 35 | **/android/captures/ 36 | **/android/gradlew 37 | **/android/gradlew.bat 38 | **/android/local.properties 39 | **/android/**/GeneratedPluginRegistrant.java 40 | 41 | # iOS/XCode related 42 | **/ios/**/*.mode1v3 43 | **/ios/**/*.mode2v3 44 | **/ios/**/*.moved-aside 45 | **/ios/**/*.pbxuser 46 | **/ios/**/*.perspectivev3 47 | **/ios/**/*sync/ 48 | **/ios/**/.sconsign.dblite 49 | **/ios/**/.tags* 50 | **/ios/**/.vagrant/ 51 | **/ios/**/DerivedData/ 52 | **/ios/**/Icon? 53 | **/ios/**/Pods/ 54 | **/ios/**/.symlinks/ 55 | **/ios/**/profile 56 | **/ios/**/xcuserdata 57 | **/ios/.generated/ 58 | **/ios/Flutter/App.framework 59 | **/ios/Flutter/Flutter.framework 60 | **/ios/Flutter/Generated.xcconfig 61 | **/ios/Flutter/app.flx 62 | **/ios/Flutter/app.zip 63 | **/ios/Flutter/flutter_assets/ 64 | **/ios/ServiceDefinitions.json 65 | **/ios/Runner/GeneratedPluginRegistrant.* 66 | 67 | # Exceptions to above rules. 68 | !**/ios/**/default.mode1v3 69 | !**/ios/**/default.mode2v3 70 | !**/ios/**/default.pbxuser 71 | !**/ios/**/default.perspectivev3 72 | !/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages 73 | -------------------------------------------------------------------------------- /example/.metadata: -------------------------------------------------------------------------------- 1 | # This file tracks properties of this Flutter project. 2 | # Used by Flutter tool to assess capabilities and perform upgrades etc. 3 | # 4 | # This file should be version controlled and should not be manually edited. 5 | 6 | version: 7 | revision: 7a4c33425ddd78c54aba07d86f3f9a4a0051769b 8 | channel: stable 9 | 10 | project_type: app 11 | -------------------------------------------------------------------------------- /example/README.md: -------------------------------------------------------------------------------- 1 | # example 2 | 3 | A new Flutter project. 4 | 5 | ## Getting Started 6 | 7 | This project is a starting point for a Flutter application. 8 | 9 | A few resources to get you started if this is your first Flutter project: 10 | 11 | - [Lab: Write your first Flutter app](https://flutter.dev/docs/get-started/codelab) 12 | - [Cookbook: Useful Flutter samples](https://flutter.dev/docs/cookbook) 13 | 14 | For help getting started with Flutter, view our 15 | [online documentation](https://flutter.dev/docs), which offers tutorials, 16 | samples, guidance on mobile development, and a full API reference. 17 | -------------------------------------------------------------------------------- /example/android/.gitignore: -------------------------------------------------------------------------------- 1 | gradle-wrapper.jar 2 | /.gradle 3 | /captures/ 4 | /gradlew 5 | /gradlew.bat 6 | /local.properties 7 | GeneratedPluginRegistrant.java 8 | -------------------------------------------------------------------------------- /example/android/app/build.gradle: -------------------------------------------------------------------------------- 1 | def localProperties = new Properties() 2 | def localPropertiesFile = rootProject.file('local.properties') 3 | if (localPropertiesFile.exists()) { 4 | localPropertiesFile.withReader('UTF-8') { reader -> 5 | localProperties.load(reader) 6 | } 7 | } 8 | 9 | def flutterRoot = localProperties.getProperty('flutter.sdk') 10 | if (flutterRoot == null) { 11 | throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") 12 | } 13 | 14 | def flutterVersionCode = localProperties.getProperty('flutter.versionCode') 15 | if (flutterVersionCode == null) { 16 | flutterVersionCode = '1' 17 | } 18 | 19 | def flutterVersionName = localProperties.getProperty('flutter.versionName') 20 | if (flutterVersionName == null) { 21 | flutterVersionName = '1.0' 22 | } 23 | 24 | apply plugin: 'com.android.application' 25 | apply plugin: 'kotlin-android' 26 | apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" 27 | 28 | android { 29 | compileSdkVersion 28 30 | 31 | sourceSets { 32 | main.java.srcDirs += 'src/main/kotlin' 33 | } 34 | 35 | lintOptions { 36 | disable 'InvalidPackage' 37 | } 38 | 39 | defaultConfig { 40 | // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). 41 | applicationId "com.example.example" 42 | minSdkVersion 16 43 | targetSdkVersion 28 44 | versionCode flutterVersionCode.toInteger() 45 | versionName flutterVersionName 46 | } 47 | 48 | buildTypes { 49 | release { 50 | // TODO: Add your own signing config for the release build. 51 | // Signing with the debug keys for now, so `flutter run --release` works. 52 | signingConfig signingConfigs.debug 53 | } 54 | } 55 | } 56 | 57 | flutter { 58 | source '../..' 59 | } 60 | 61 | dependencies { 62 | implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" 63 | } 64 | -------------------------------------------------------------------------------- /example/android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /example/android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 8 | 12 | 19 | 23 | 27 | 32 | 36 | 37 | 38 | 39 | 40 | 41 | 43 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /example/android/app/src/main/kotlin/com/example/example/MainActivity.kt: -------------------------------------------------------------------------------- 1 | package com.example.example 2 | 3 | import io.flutter.embedding.android.FlutterActivity 4 | 5 | class MainActivity: FlutterActivity() { 6 | } 7 | -------------------------------------------------------------------------------- /example/android/app/src/main/res/drawable/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /example/android/app/src/profile/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /example/android/build.gradle: -------------------------------------------------------------------------------- 1 | buildscript { 2 | ext.kotlin_version = '1.3.50' 3 | repositories { 4 | google() 5 | jcenter() 6 | } 7 | 8 | dependencies { 9 | classpath 'com.android.tools.build:gradle:3.5.0' 10 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" 11 | } 12 | } 13 | 14 | allprojects { 15 | repositories { 16 | google() 17 | jcenter() 18 | } 19 | } 20 | 21 | rootProject.buildDir = '../build' 22 | subprojects { 23 | project.buildDir = "${rootProject.buildDir}/${project.name}" 24 | } 25 | subprojects { 26 | project.evaluationDependsOn(':app') 27 | } 28 | 29 | task clean(type: Delete) { 30 | delete rootProject.buildDir 31 | } 32 | -------------------------------------------------------------------------------- /example/android/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.jvmargs=-Xmx1536M 2 | android.enableR8=true 3 | android.useAndroidX=true 4 | android.enableJetifier=true 5 | -------------------------------------------------------------------------------- /example/android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Fri Jun 23 08:50:38 CEST 2017 2 | distributionBase=GRADLE_USER_HOME 3 | distributionPath=wrapper/dists 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.2-all.zip 7 | -------------------------------------------------------------------------------- /example/android/settings.gradle: -------------------------------------------------------------------------------- 1 | // Copyright 2014 The Flutter Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style license that can be 3 | // found in the LICENSE file. 4 | 5 | include ':app' 6 | 7 | def localPropertiesFile = new File(rootProject.projectDir, "local.properties") 8 | def properties = new Properties() 9 | 10 | assert localPropertiesFile.exists() 11 | localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) } 12 | 13 | def flutterSdkPath = properties.getProperty("flutter.sdk") 14 | assert flutterSdkPath != null, "flutter.sdk not set in local.properties" 15 | apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle" 16 | -------------------------------------------------------------------------------- /example/ios/.gitignore: -------------------------------------------------------------------------------- 1 | *.mode1v3 2 | *.mode2v3 3 | *.moved-aside 4 | *.pbxuser 5 | *.perspectivev3 6 | **/*sync/ 7 | .sconsign.dblite 8 | .tags* 9 | **/.vagrant/ 10 | **/DerivedData/ 11 | Icon? 12 | **/Pods/ 13 | **/.symlinks/ 14 | profile 15 | xcuserdata 16 | **/.generated/ 17 | Flutter/App.framework 18 | Flutter/Flutter.framework 19 | Flutter/Flutter.podspec 20 | Flutter/Generated.xcconfig 21 | Flutter/app.flx 22 | Flutter/app.zip 23 | Flutter/flutter_assets/ 24 | Flutter/flutter_export_environment.sh 25 | ServiceDefinitions.json 26 | Runner/GeneratedPluginRegistrant.* 27 | 28 | # Exceptions to above rules. 29 | !default.mode1v3 30 | !default.mode2v3 31 | !default.pbxuser 32 | !default.perspectivev3 33 | -------------------------------------------------------------------------------- /example/ios/Flutter/.last_build_id: -------------------------------------------------------------------------------- 1 | 451c6b96b608ddeb11b805e121591c89 -------------------------------------------------------------------------------- /example/ios/Flutter/AppFrameworkInfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | App 9 | CFBundleIdentifier 10 | io.flutter.flutter.app 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | App 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1.0 23 | MinimumOSVersion 24 | 8.0 25 | 26 | 27 | -------------------------------------------------------------------------------- /example/ios/Flutter/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /example/ios/Flutter/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /example/ios/Flutter/flutter_export_environment.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # This is a generated file; do not edit or check into version control. 3 | export "FLUTTER_ROOT=/Users/chiziaruhoma/flutter" 4 | export "FLUTTER_APPLICATION_PATH=/Users/chiziaruhoma/projects/ayomide/flutter_rave/example" 5 | export "FLUTTER_TARGET=/Users/chiziaruhoma/projects/ayomide/flutter_rave/example/lib/main.dart" 6 | export "FLUTTER_BUILD_DIR=build" 7 | export "SYMROOT=${SOURCE_ROOT}/../build/ios" 8 | export "OTHER_LDFLAGS=$(inherited) -framework Flutter" 9 | export "FLUTTER_FRAMEWORK_DIR=/Users/chiziaruhoma/flutter/bin/cache/artifacts/engine/ios" 10 | export "FLUTTER_BUILD_NAME=1.0.0" 11 | export "FLUTTER_BUILD_NUMBER=1" 12 | export "DART_OBFUSCATION=false" 13 | export "TRACK_WIDGET_CREATION=true" 14 | export "TREE_SHAKE_ICONS=false" 15 | -------------------------------------------------------------------------------- /example/ios/Podfile: -------------------------------------------------------------------------------- 1 | # Uncomment this line to define a global platform for your project 2 | # platform :ios, '9.0' 3 | 4 | # CocoaPods analytics sends network stats synchronously affecting flutter build latency. 5 | ENV['COCOAPODS_DISABLE_STATS'] = 'true' 6 | 7 | project 'Runner', { 8 | 'Debug' => :debug, 9 | 'Profile' => :release, 10 | 'Release' => :release, 11 | } 12 | 13 | def parse_KV_file(file, separator='=') 14 | file_abs_path = File.expand_path(file) 15 | if !File.exists? file_abs_path 16 | return []; 17 | end 18 | generated_key_values = {} 19 | skip_line_start_symbols = ["#", "/"] 20 | File.foreach(file_abs_path) do |line| 21 | next if skip_line_start_symbols.any? { |symbol| line =~ /^\s*#{symbol}/ } 22 | plugin = line.split(pattern=separator) 23 | if plugin.length == 2 24 | podname = plugin[0].strip() 25 | path = plugin[1].strip() 26 | podpath = File.expand_path("#{path}", file_abs_path) 27 | generated_key_values[podname] = podpath 28 | else 29 | puts "Invalid plugin specification: #{line}" 30 | end 31 | end 32 | generated_key_values 33 | end 34 | 35 | target 'Runner' do 36 | use_frameworks! 37 | use_modular_headers! 38 | 39 | # Flutter Pod 40 | 41 | copied_flutter_dir = File.join(__dir__, 'Flutter') 42 | copied_framework_path = File.join(copied_flutter_dir, 'Flutter.framework') 43 | copied_podspec_path = File.join(copied_flutter_dir, 'Flutter.podspec') 44 | unless File.exist?(copied_framework_path) && File.exist?(copied_podspec_path) 45 | # Copy Flutter.framework and Flutter.podspec to Flutter/ to have something to link against if the xcode backend script has not run yet. 46 | # That script will copy the correct debug/profile/release version of the framework based on the currently selected Xcode configuration. 47 | # CocoaPods will not embed the framework on pod install (before any build phases can generate) if the dylib does not exist. 48 | 49 | generated_xcode_build_settings_path = File.join(copied_flutter_dir, 'Generated.xcconfig') 50 | unless File.exist?(generated_xcode_build_settings_path) 51 | raise "Generated.xcconfig must exist. If you're running pod install manually, make sure flutter pub get is executed first" 52 | end 53 | generated_xcode_build_settings = parse_KV_file(generated_xcode_build_settings_path) 54 | cached_framework_dir = generated_xcode_build_settings['FLUTTER_FRAMEWORK_DIR']; 55 | 56 | unless File.exist?(copied_framework_path) 57 | FileUtils.cp_r(File.join(cached_framework_dir, 'Flutter.framework'), copied_flutter_dir) 58 | end 59 | unless File.exist?(copied_podspec_path) 60 | FileUtils.cp(File.join(cached_framework_dir, 'Flutter.podspec'), copied_flutter_dir) 61 | end 62 | end 63 | 64 | # Keep pod path relative so it can be checked into Podfile.lock. 65 | pod 'Flutter', :path => 'Flutter' 66 | 67 | # Plugin Pods 68 | 69 | # Prepare symlinks folder. We use symlinks to avoid having Podfile.lock 70 | # referring to absolute paths on developers' machines. 71 | system('rm -rf .symlinks') 72 | system('mkdir -p .symlinks/plugins') 73 | plugin_pods = parse_KV_file('../.flutter-plugins') 74 | plugin_pods.each do |name, path| 75 | symlink = File.join('.symlinks', 'plugins', name) 76 | File.symlink(path, symlink) 77 | pod name, :path => File.join(symlink, 'ios') 78 | end 79 | end 80 | 81 | post_install do |installer| 82 | installer.pods_project.targets.each do |target| 83 | target.build_configurations.each do |config| 84 | config.build_settings['ENABLE_BITCODE'] = 'NO' 85 | end 86 | end 87 | end 88 | -------------------------------------------------------------------------------- /example/ios/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - Flutter (1.0.0) 3 | - flutter_webview_plugin (0.0.1): 4 | - Flutter 5 | - url_launcher (0.0.1): 6 | - Flutter 7 | - url_launcher_macos (0.0.1): 8 | - Flutter 9 | - url_launcher_web (0.0.1): 10 | - Flutter 11 | - webview_flutter (0.0.1): 12 | - Flutter 13 | 14 | DEPENDENCIES: 15 | - Flutter (from `Flutter`) 16 | - flutter_webview_plugin (from `.symlinks/plugins/flutter_webview_plugin/ios`) 17 | - url_launcher (from `.symlinks/plugins/url_launcher/ios`) 18 | - url_launcher_macos (from `.symlinks/plugins/url_launcher_macos/ios`) 19 | - url_launcher_web (from `.symlinks/plugins/url_launcher_web/ios`) 20 | - webview_flutter (from `.symlinks/plugins/webview_flutter/ios`) 21 | 22 | EXTERNAL SOURCES: 23 | Flutter: 24 | :path: Flutter 25 | flutter_webview_plugin: 26 | :path: ".symlinks/plugins/flutter_webview_plugin/ios" 27 | url_launcher: 28 | :path: ".symlinks/plugins/url_launcher/ios" 29 | url_launcher_macos: 30 | :path: ".symlinks/plugins/url_launcher_macos/ios" 31 | url_launcher_web: 32 | :path: ".symlinks/plugins/url_launcher_web/ios" 33 | webview_flutter: 34 | :path: ".symlinks/plugins/webview_flutter/ios" 35 | 36 | SPEC CHECKSUMS: 37 | Flutter: 0e3d915762c693b495b44d77113d4970485de6ec 38 | flutter_webview_plugin: ed9e8a6a96baf0c867e90e1bce2673913eeac694 39 | url_launcher: 6fef411d543ceb26efce54b05a0a40bfd74cbbef 40 | url_launcher_macos: fd7894421cd39320dce5f292fc99ea9270b2a313 41 | url_launcher_web: e5527357f037c87560776e36436bf2b0288b965c 42 | webview_flutter: d2b4d6c66968ad042ad94cbb791f5b72b4678a96 43 | 44 | PODFILE CHECKSUM: c34e2287a9ccaa606aeceab922830efb9a6ff69a 45 | 46 | COCOAPODS: 1.8.4 47 | -------------------------------------------------------------------------------- /example/ios/Runner.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; 11 | 1CA1582CB8472A975CE7E1ED /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B7476D9E39FB81CBC0B499CF /* Pods_Runner.framework */; }; 12 | 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; 13 | 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; }; 14 | 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; 15 | 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; 16 | 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; 17 | /* End PBXBuildFile section */ 18 | 19 | /* Begin PBXCopyFilesBuildPhase section */ 20 | 9705A1C41CF9048500538489 /* Embed Frameworks */ = { 21 | isa = PBXCopyFilesBuildPhase; 22 | buildActionMask = 2147483647; 23 | dstPath = ""; 24 | dstSubfolderSpec = 10; 25 | files = ( 26 | ); 27 | name = "Embed Frameworks"; 28 | runOnlyForDeploymentPostprocessing = 0; 29 | }; 30 | /* End PBXCopyFilesBuildPhase section */ 31 | 32 | /* Begin PBXFileReference section */ 33 | 030832FCFC5F500791CCEA3C /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = ""; }; 34 | 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; }; 35 | 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; }; 36 | 351F01D53CDAFD7F260C1801 /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = ""; }; 37 | 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; }; 38 | 47165142C147CE4DF3E5864C /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = ""; }; 39 | 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = ""; }; 40 | 74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 41 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; }; 42 | 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; }; 43 | 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; }; 44 | 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; 45 | 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 46 | 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 47 | 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 48 | 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 49 | B7476D9E39FB81CBC0B499CF /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 50 | /* End PBXFileReference section */ 51 | 52 | /* Begin PBXFrameworksBuildPhase section */ 53 | 97C146EB1CF9000F007C117D /* Frameworks */ = { 54 | isa = PBXFrameworksBuildPhase; 55 | buildActionMask = 2147483647; 56 | files = ( 57 | 1CA1582CB8472A975CE7E1ED /* Pods_Runner.framework in Frameworks */, 58 | ); 59 | runOnlyForDeploymentPostprocessing = 0; 60 | }; 61 | /* End PBXFrameworksBuildPhase section */ 62 | 63 | /* Begin PBXGroup section */ 64 | 67D67654B300619DFDF3AA95 /* Pods */ = { 65 | isa = PBXGroup; 66 | children = ( 67 | 351F01D53CDAFD7F260C1801 /* Pods-Runner.debug.xcconfig */, 68 | 030832FCFC5F500791CCEA3C /* Pods-Runner.release.xcconfig */, 69 | 47165142C147CE4DF3E5864C /* Pods-Runner.profile.xcconfig */, 70 | ); 71 | name = Pods; 72 | path = Pods; 73 | sourceTree = ""; 74 | }; 75 | 9544F6E2303DD0EB6391AD7B /* Frameworks */ = { 76 | isa = PBXGroup; 77 | children = ( 78 | B7476D9E39FB81CBC0B499CF /* Pods_Runner.framework */, 79 | ); 80 | name = Frameworks; 81 | sourceTree = ""; 82 | }; 83 | 9740EEB11CF90186004384FC /* Flutter */ = { 84 | isa = PBXGroup; 85 | children = ( 86 | 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */, 87 | 9740EEB21CF90195004384FC /* Debug.xcconfig */, 88 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, 89 | 9740EEB31CF90195004384FC /* Generated.xcconfig */, 90 | ); 91 | name = Flutter; 92 | sourceTree = ""; 93 | }; 94 | 97C146E51CF9000F007C117D = { 95 | isa = PBXGroup; 96 | children = ( 97 | 9740EEB11CF90186004384FC /* Flutter */, 98 | 97C146F01CF9000F007C117D /* Runner */, 99 | 97C146EF1CF9000F007C117D /* Products */, 100 | 67D67654B300619DFDF3AA95 /* Pods */, 101 | 9544F6E2303DD0EB6391AD7B /* Frameworks */, 102 | ); 103 | sourceTree = ""; 104 | }; 105 | 97C146EF1CF9000F007C117D /* Products */ = { 106 | isa = PBXGroup; 107 | children = ( 108 | 97C146EE1CF9000F007C117D /* Runner.app */, 109 | ); 110 | name = Products; 111 | sourceTree = ""; 112 | }; 113 | 97C146F01CF9000F007C117D /* Runner */ = { 114 | isa = PBXGroup; 115 | children = ( 116 | 97C146FA1CF9000F007C117D /* Main.storyboard */, 117 | 97C146FD1CF9000F007C117D /* Assets.xcassets */, 118 | 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, 119 | 97C147021CF9000F007C117D /* Info.plist */, 120 | 97C146F11CF9000F007C117D /* Supporting Files */, 121 | 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */, 122 | 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */, 123 | 74858FAE1ED2DC5600515810 /* AppDelegate.swift */, 124 | 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */, 125 | ); 126 | path = Runner; 127 | sourceTree = ""; 128 | }; 129 | 97C146F11CF9000F007C117D /* Supporting Files */ = { 130 | isa = PBXGroup; 131 | children = ( 132 | ); 133 | name = "Supporting Files"; 134 | sourceTree = ""; 135 | }; 136 | /* End PBXGroup section */ 137 | 138 | /* Begin PBXNativeTarget section */ 139 | 97C146ED1CF9000F007C117D /* Runner */ = { 140 | isa = PBXNativeTarget; 141 | buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; 142 | buildPhases = ( 143 | F4291655FF3057C2495ED3CC /* [CP] Check Pods Manifest.lock */, 144 | 9740EEB61CF901F6004384FC /* Run Script */, 145 | 97C146EA1CF9000F007C117D /* Sources */, 146 | 97C146EB1CF9000F007C117D /* Frameworks */, 147 | 97C146EC1CF9000F007C117D /* Resources */, 148 | 9705A1C41CF9048500538489 /* Embed Frameworks */, 149 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */, 150 | B985CCEF60985DE5854C73D2 /* [CP] Embed Pods Frameworks */, 151 | ); 152 | buildRules = ( 153 | ); 154 | dependencies = ( 155 | ); 156 | name = Runner; 157 | productName = Runner; 158 | productReference = 97C146EE1CF9000F007C117D /* Runner.app */; 159 | productType = "com.apple.product-type.application"; 160 | }; 161 | /* End PBXNativeTarget section */ 162 | 163 | /* Begin PBXProject section */ 164 | 97C146E61CF9000F007C117D /* Project object */ = { 165 | isa = PBXProject; 166 | attributes = { 167 | LastUpgradeCheck = 1020; 168 | ORGANIZATIONNAME = ""; 169 | TargetAttributes = { 170 | 97C146ED1CF9000F007C117D = { 171 | CreatedOnToolsVersion = 7.3.1; 172 | LastSwiftMigration = 1100; 173 | }; 174 | }; 175 | }; 176 | buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; 177 | compatibilityVersion = "Xcode 9.3"; 178 | developmentRegion = en; 179 | hasScannedForEncodings = 0; 180 | knownRegions = ( 181 | en, 182 | Base, 183 | ); 184 | mainGroup = 97C146E51CF9000F007C117D; 185 | productRefGroup = 97C146EF1CF9000F007C117D /* Products */; 186 | projectDirPath = ""; 187 | projectRoot = ""; 188 | targets = ( 189 | 97C146ED1CF9000F007C117D /* Runner */, 190 | ); 191 | }; 192 | /* End PBXProject section */ 193 | 194 | /* Begin PBXResourcesBuildPhase section */ 195 | 97C146EC1CF9000F007C117D /* Resources */ = { 196 | isa = PBXResourcesBuildPhase; 197 | buildActionMask = 2147483647; 198 | files = ( 199 | 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */, 200 | 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, 201 | 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, 202 | 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, 203 | ); 204 | runOnlyForDeploymentPostprocessing = 0; 205 | }; 206 | /* End PBXResourcesBuildPhase section */ 207 | 208 | /* Begin PBXShellScriptBuildPhase section */ 209 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { 210 | isa = PBXShellScriptBuildPhase; 211 | buildActionMask = 2147483647; 212 | files = ( 213 | ); 214 | inputPaths = ( 215 | ); 216 | name = "Thin Binary"; 217 | outputPaths = ( 218 | ); 219 | runOnlyForDeploymentPostprocessing = 0; 220 | shellPath = /bin/sh; 221 | shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin"; 222 | }; 223 | 9740EEB61CF901F6004384FC /* Run Script */ = { 224 | isa = PBXShellScriptBuildPhase; 225 | buildActionMask = 2147483647; 226 | files = ( 227 | ); 228 | inputPaths = ( 229 | ); 230 | name = "Run Script"; 231 | outputPaths = ( 232 | ); 233 | runOnlyForDeploymentPostprocessing = 0; 234 | shellPath = /bin/sh; 235 | shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; 236 | }; 237 | B985CCEF60985DE5854C73D2 /* [CP] Embed Pods Frameworks */ = { 238 | isa = PBXShellScriptBuildPhase; 239 | buildActionMask = 2147483647; 240 | files = ( 241 | ); 242 | inputPaths = ( 243 | "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh", 244 | "${PODS_ROOT}/../Flutter/Flutter.framework", 245 | "${BUILT_PRODUCTS_DIR}/flutter_webview_plugin/flutter_webview_plugin.framework", 246 | "${BUILT_PRODUCTS_DIR}/url_launcher/url_launcher.framework", 247 | "${BUILT_PRODUCTS_DIR}/webview_flutter/webview_flutter.framework", 248 | ); 249 | name = "[CP] Embed Pods Frameworks"; 250 | outputPaths = ( 251 | "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/Flutter.framework", 252 | "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/flutter_webview_plugin.framework", 253 | "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/url_launcher.framework", 254 | "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/webview_flutter.framework", 255 | ); 256 | runOnlyForDeploymentPostprocessing = 0; 257 | shellPath = /bin/sh; 258 | shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n"; 259 | showEnvVarsInLog = 0; 260 | }; 261 | F4291655FF3057C2495ED3CC /* [CP] Check Pods Manifest.lock */ = { 262 | isa = PBXShellScriptBuildPhase; 263 | buildActionMask = 2147483647; 264 | files = ( 265 | ); 266 | inputFileListPaths = ( 267 | ); 268 | inputPaths = ( 269 | "${PODS_PODFILE_DIR_PATH}/Podfile.lock", 270 | "${PODS_ROOT}/Manifest.lock", 271 | ); 272 | name = "[CP] Check Pods Manifest.lock"; 273 | outputFileListPaths = ( 274 | ); 275 | outputPaths = ( 276 | "$(DERIVED_FILE_DIR)/Pods-Runner-checkManifestLockResult.txt", 277 | ); 278 | runOnlyForDeploymentPostprocessing = 0; 279 | shellPath = /bin/sh; 280 | 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"; 281 | showEnvVarsInLog = 0; 282 | }; 283 | /* End PBXShellScriptBuildPhase section */ 284 | 285 | /* Begin PBXSourcesBuildPhase section */ 286 | 97C146EA1CF9000F007C117D /* Sources */ = { 287 | isa = PBXSourcesBuildPhase; 288 | buildActionMask = 2147483647; 289 | files = ( 290 | 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */, 291 | 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */, 292 | ); 293 | runOnlyForDeploymentPostprocessing = 0; 294 | }; 295 | /* End PBXSourcesBuildPhase section */ 296 | 297 | /* Begin PBXVariantGroup section */ 298 | 97C146FA1CF9000F007C117D /* Main.storyboard */ = { 299 | isa = PBXVariantGroup; 300 | children = ( 301 | 97C146FB1CF9000F007C117D /* Base */, 302 | ); 303 | name = Main.storyboard; 304 | sourceTree = ""; 305 | }; 306 | 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = { 307 | isa = PBXVariantGroup; 308 | children = ( 309 | 97C147001CF9000F007C117D /* Base */, 310 | ); 311 | name = LaunchScreen.storyboard; 312 | sourceTree = ""; 313 | }; 314 | /* End PBXVariantGroup section */ 315 | 316 | /* Begin XCBuildConfiguration section */ 317 | 249021D3217E4FDB00AE95B9 /* Profile */ = { 318 | isa = XCBuildConfiguration; 319 | buildSettings = { 320 | ALWAYS_SEARCH_USER_PATHS = NO; 321 | CLANG_ANALYZER_NONNULL = YES; 322 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 323 | CLANG_CXX_LIBRARY = "libc++"; 324 | CLANG_ENABLE_MODULES = YES; 325 | CLANG_ENABLE_OBJC_ARC = YES; 326 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 327 | CLANG_WARN_BOOL_CONVERSION = YES; 328 | CLANG_WARN_COMMA = YES; 329 | CLANG_WARN_CONSTANT_CONVERSION = YES; 330 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 331 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 332 | CLANG_WARN_EMPTY_BODY = YES; 333 | CLANG_WARN_ENUM_CONVERSION = YES; 334 | CLANG_WARN_INFINITE_RECURSION = YES; 335 | CLANG_WARN_INT_CONVERSION = YES; 336 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 337 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 338 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 339 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 340 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 341 | CLANG_WARN_STRICT_PROTOTYPES = YES; 342 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 343 | CLANG_WARN_UNREACHABLE_CODE = YES; 344 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 345 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 346 | COPY_PHASE_STRIP = NO; 347 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 348 | ENABLE_NS_ASSERTIONS = NO; 349 | ENABLE_STRICT_OBJC_MSGSEND = YES; 350 | GCC_C_LANGUAGE_STANDARD = gnu99; 351 | GCC_NO_COMMON_BLOCKS = YES; 352 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 353 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 354 | GCC_WARN_UNDECLARED_SELECTOR = YES; 355 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 356 | GCC_WARN_UNUSED_FUNCTION = YES; 357 | GCC_WARN_UNUSED_VARIABLE = YES; 358 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 359 | MTL_ENABLE_DEBUG_INFO = NO; 360 | SDKROOT = iphoneos; 361 | SUPPORTED_PLATFORMS = iphoneos; 362 | TARGETED_DEVICE_FAMILY = "1,2"; 363 | VALIDATE_PRODUCT = YES; 364 | }; 365 | name = Profile; 366 | }; 367 | 249021D4217E4FDB00AE95B9 /* Profile */ = { 368 | isa = XCBuildConfiguration; 369 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; 370 | buildSettings = { 371 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 372 | CLANG_ENABLE_MODULES = YES; 373 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 374 | ENABLE_BITCODE = NO; 375 | FRAMEWORK_SEARCH_PATHS = ( 376 | "$(inherited)", 377 | "$(PROJECT_DIR)/Flutter", 378 | ); 379 | INFOPLIST_FILE = Runner/Info.plist; 380 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 381 | LIBRARY_SEARCH_PATHS = ( 382 | "$(inherited)", 383 | "$(PROJECT_DIR)/Flutter", 384 | ); 385 | PRODUCT_BUNDLE_IDENTIFIER = com.example.example; 386 | PRODUCT_NAME = "$(TARGET_NAME)"; 387 | SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; 388 | SWIFT_VERSION = 5.0; 389 | VERSIONING_SYSTEM = "apple-generic"; 390 | }; 391 | name = Profile; 392 | }; 393 | 97C147031CF9000F007C117D /* Debug */ = { 394 | isa = XCBuildConfiguration; 395 | buildSettings = { 396 | ALWAYS_SEARCH_USER_PATHS = NO; 397 | CLANG_ANALYZER_NONNULL = YES; 398 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 399 | CLANG_CXX_LIBRARY = "libc++"; 400 | CLANG_ENABLE_MODULES = YES; 401 | CLANG_ENABLE_OBJC_ARC = YES; 402 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 403 | CLANG_WARN_BOOL_CONVERSION = YES; 404 | CLANG_WARN_COMMA = YES; 405 | CLANG_WARN_CONSTANT_CONVERSION = YES; 406 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 407 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 408 | CLANG_WARN_EMPTY_BODY = YES; 409 | CLANG_WARN_ENUM_CONVERSION = YES; 410 | CLANG_WARN_INFINITE_RECURSION = YES; 411 | CLANG_WARN_INT_CONVERSION = YES; 412 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 413 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 414 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 415 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 416 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 417 | CLANG_WARN_STRICT_PROTOTYPES = YES; 418 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 419 | CLANG_WARN_UNREACHABLE_CODE = YES; 420 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 421 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 422 | COPY_PHASE_STRIP = NO; 423 | DEBUG_INFORMATION_FORMAT = dwarf; 424 | ENABLE_STRICT_OBJC_MSGSEND = YES; 425 | ENABLE_TESTABILITY = YES; 426 | GCC_C_LANGUAGE_STANDARD = gnu99; 427 | GCC_DYNAMIC_NO_PIC = NO; 428 | GCC_NO_COMMON_BLOCKS = YES; 429 | GCC_OPTIMIZATION_LEVEL = 0; 430 | GCC_PREPROCESSOR_DEFINITIONS = ( 431 | "DEBUG=1", 432 | "$(inherited)", 433 | ); 434 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 435 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 436 | GCC_WARN_UNDECLARED_SELECTOR = YES; 437 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 438 | GCC_WARN_UNUSED_FUNCTION = YES; 439 | GCC_WARN_UNUSED_VARIABLE = YES; 440 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 441 | MTL_ENABLE_DEBUG_INFO = YES; 442 | ONLY_ACTIVE_ARCH = YES; 443 | SDKROOT = iphoneos; 444 | TARGETED_DEVICE_FAMILY = "1,2"; 445 | }; 446 | name = Debug; 447 | }; 448 | 97C147041CF9000F007C117D /* Release */ = { 449 | isa = XCBuildConfiguration; 450 | buildSettings = { 451 | ALWAYS_SEARCH_USER_PATHS = NO; 452 | CLANG_ANALYZER_NONNULL = YES; 453 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 454 | CLANG_CXX_LIBRARY = "libc++"; 455 | CLANG_ENABLE_MODULES = YES; 456 | CLANG_ENABLE_OBJC_ARC = YES; 457 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 458 | CLANG_WARN_BOOL_CONVERSION = YES; 459 | CLANG_WARN_COMMA = YES; 460 | CLANG_WARN_CONSTANT_CONVERSION = YES; 461 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 462 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 463 | CLANG_WARN_EMPTY_BODY = YES; 464 | CLANG_WARN_ENUM_CONVERSION = YES; 465 | CLANG_WARN_INFINITE_RECURSION = YES; 466 | CLANG_WARN_INT_CONVERSION = YES; 467 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 468 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 469 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 470 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 471 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 472 | CLANG_WARN_STRICT_PROTOTYPES = YES; 473 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 474 | CLANG_WARN_UNREACHABLE_CODE = YES; 475 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 476 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 477 | COPY_PHASE_STRIP = NO; 478 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 479 | ENABLE_NS_ASSERTIONS = NO; 480 | ENABLE_STRICT_OBJC_MSGSEND = YES; 481 | GCC_C_LANGUAGE_STANDARD = gnu99; 482 | GCC_NO_COMMON_BLOCKS = YES; 483 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 484 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 485 | GCC_WARN_UNDECLARED_SELECTOR = YES; 486 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 487 | GCC_WARN_UNUSED_FUNCTION = YES; 488 | GCC_WARN_UNUSED_VARIABLE = YES; 489 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 490 | MTL_ENABLE_DEBUG_INFO = NO; 491 | SDKROOT = iphoneos; 492 | SUPPORTED_PLATFORMS = iphoneos; 493 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 494 | TARGETED_DEVICE_FAMILY = "1,2"; 495 | VALIDATE_PRODUCT = YES; 496 | }; 497 | name = Release; 498 | }; 499 | 97C147061CF9000F007C117D /* Debug */ = { 500 | isa = XCBuildConfiguration; 501 | baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; 502 | buildSettings = { 503 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 504 | CLANG_ENABLE_MODULES = YES; 505 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 506 | ENABLE_BITCODE = NO; 507 | FRAMEWORK_SEARCH_PATHS = ( 508 | "$(inherited)", 509 | "$(PROJECT_DIR)/Flutter", 510 | ); 511 | INFOPLIST_FILE = Runner/Info.plist; 512 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 513 | LIBRARY_SEARCH_PATHS = ( 514 | "$(inherited)", 515 | "$(PROJECT_DIR)/Flutter", 516 | ); 517 | PRODUCT_BUNDLE_IDENTIFIER = com.example.example; 518 | PRODUCT_NAME = "$(TARGET_NAME)"; 519 | SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; 520 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 521 | SWIFT_VERSION = 5.0; 522 | VERSIONING_SYSTEM = "apple-generic"; 523 | }; 524 | name = Debug; 525 | }; 526 | 97C147071CF9000F007C117D /* Release */ = { 527 | isa = XCBuildConfiguration; 528 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; 529 | buildSettings = { 530 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 531 | CLANG_ENABLE_MODULES = YES; 532 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 533 | ENABLE_BITCODE = NO; 534 | FRAMEWORK_SEARCH_PATHS = ( 535 | "$(inherited)", 536 | "$(PROJECT_DIR)/Flutter", 537 | ); 538 | INFOPLIST_FILE = Runner/Info.plist; 539 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 540 | LIBRARY_SEARCH_PATHS = ( 541 | "$(inherited)", 542 | "$(PROJECT_DIR)/Flutter", 543 | ); 544 | PRODUCT_BUNDLE_IDENTIFIER = com.example.example; 545 | PRODUCT_NAME = "$(TARGET_NAME)"; 546 | SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; 547 | SWIFT_VERSION = 5.0; 548 | VERSIONING_SYSTEM = "apple-generic"; 549 | }; 550 | name = Release; 551 | }; 552 | /* End XCBuildConfiguration section */ 553 | 554 | /* Begin XCConfigurationList section */ 555 | 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = { 556 | isa = XCConfigurationList; 557 | buildConfigurations = ( 558 | 97C147031CF9000F007C117D /* Debug */, 559 | 97C147041CF9000F007C117D /* Release */, 560 | 249021D3217E4FDB00AE95B9 /* Profile */, 561 | ); 562 | defaultConfigurationIsVisible = 0; 563 | defaultConfigurationName = Release; 564 | }; 565 | 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = { 566 | isa = XCConfigurationList; 567 | buildConfigurations = ( 568 | 97C147061CF9000F007C117D /* Debug */, 569 | 97C147071CF9000F007C117D /* Release */, 570 | 249021D4217E4FDB00AE95B9 /* Profile */, 571 | ); 572 | defaultConfigurationIsVisible = 0; 573 | defaultConfigurationName = Release; 574 | }; 575 | /* End XCConfigurationList section */ 576 | }; 577 | rootObject = 97C146E61CF9000F007C117D /* Project object */; 578 | } 579 | -------------------------------------------------------------------------------- /example/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /example/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 39 | 40 | 41 | 42 | 43 | 44 | 54 | 56 | 62 | 63 | 64 | 65 | 66 | 67 | 73 | 75 | 81 | 82 | 83 | 84 | 86 | 87 | 90 | 91 | 92 | -------------------------------------------------------------------------------- /example/ios/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /example/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /example/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /example/ios/Runner/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | import UIKit 2 | import Flutter 3 | 4 | @UIApplicationMain 5 | @objc class AppDelegate: FlutterAppDelegate { 6 | override func application( 7 | _ application: UIApplication, 8 | didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? 9 | ) -> Bool { 10 | GeneratedPluginRegistrant.register(with: self) 11 | return super.application(application, didFinishLaunchingWithOptions: launchOptions) 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "20x20", 5 | "idiom" : "iphone", 6 | "filename" : "Icon-App-20x20@2x.png", 7 | "scale" : "2x" 8 | }, 9 | { 10 | "size" : "20x20", 11 | "idiom" : "iphone", 12 | "filename" : "Icon-App-20x20@3x.png", 13 | "scale" : "3x" 14 | }, 15 | { 16 | "size" : "29x29", 17 | "idiom" : "iphone", 18 | "filename" : "Icon-App-29x29@1x.png", 19 | "scale" : "1x" 20 | }, 21 | { 22 | "size" : "29x29", 23 | "idiom" : "iphone", 24 | "filename" : "Icon-App-29x29@2x.png", 25 | "scale" : "2x" 26 | }, 27 | { 28 | "size" : "29x29", 29 | "idiom" : "iphone", 30 | "filename" : "Icon-App-29x29@3x.png", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "size" : "40x40", 35 | "idiom" : "iphone", 36 | "filename" : "Icon-App-40x40@2x.png", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "size" : "40x40", 41 | "idiom" : "iphone", 42 | "filename" : "Icon-App-40x40@3x.png", 43 | "scale" : "3x" 44 | }, 45 | { 46 | "size" : "60x60", 47 | "idiom" : "iphone", 48 | "filename" : "Icon-App-60x60@2x.png", 49 | "scale" : "2x" 50 | }, 51 | { 52 | "size" : "60x60", 53 | "idiom" : "iphone", 54 | "filename" : "Icon-App-60x60@3x.png", 55 | "scale" : "3x" 56 | }, 57 | { 58 | "size" : "20x20", 59 | "idiom" : "ipad", 60 | "filename" : "Icon-App-20x20@1x.png", 61 | "scale" : "1x" 62 | }, 63 | { 64 | "size" : "20x20", 65 | "idiom" : "ipad", 66 | "filename" : "Icon-App-20x20@2x.png", 67 | "scale" : "2x" 68 | }, 69 | { 70 | "size" : "29x29", 71 | "idiom" : "ipad", 72 | "filename" : "Icon-App-29x29@1x.png", 73 | "scale" : "1x" 74 | }, 75 | { 76 | "size" : "29x29", 77 | "idiom" : "ipad", 78 | "filename" : "Icon-App-29x29@2x.png", 79 | "scale" : "2x" 80 | }, 81 | { 82 | "size" : "40x40", 83 | "idiom" : "ipad", 84 | "filename" : "Icon-App-40x40@1x.png", 85 | "scale" : "1x" 86 | }, 87 | { 88 | "size" : "40x40", 89 | "idiom" : "ipad", 90 | "filename" : "Icon-App-40x40@2x.png", 91 | "scale" : "2x" 92 | }, 93 | { 94 | "size" : "76x76", 95 | "idiom" : "ipad", 96 | "filename" : "Icon-App-76x76@1x.png", 97 | "scale" : "1x" 98 | }, 99 | { 100 | "size" : "76x76", 101 | "idiom" : "ipad", 102 | "filename" : "Icon-App-76x76@2x.png", 103 | "scale" : "2x" 104 | }, 105 | { 106 | "size" : "83.5x83.5", 107 | "idiom" : "ipad", 108 | "filename" : "Icon-App-83.5x83.5@2x.png", 109 | "scale" : "2x" 110 | }, 111 | { 112 | "size" : "1024x1024", 113 | "idiom" : "ios-marketing", 114 | "filename" : "Icon-App-1024x1024@1x.png", 115 | "scale" : "1x" 116 | } 117 | ], 118 | "info" : { 119 | "version" : 1, 120 | "author" : "xcode" 121 | } 122 | } 123 | -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "LaunchImage.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "LaunchImage@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "filename" : "LaunchImage@3x.png", 16 | "scale" : "3x" 17 | } 18 | ], 19 | "info" : { 20 | "version" : 1, 21 | "author" : "xcode" 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png -------------------------------------------------------------------------------- /example/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md: -------------------------------------------------------------------------------- 1 | # Launch Screen Assets 2 | 3 | You can customize the launch screen with your own desired assets by replacing the image files in this directory. 4 | 5 | You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images. -------------------------------------------------------------------------------- /example/ios/Runner/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /example/ios/Runner/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /example/ios/Runner/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | example 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | $(FLUTTER_BUILD_NAME) 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | $(FLUTTER_BUILD_NUMBER) 23 | LSRequiresIPhoneOS 24 | 25 | UILaunchStoryboardName 26 | LaunchScreen 27 | UIMainStoryboardFile 28 | Main 29 | UISupportedInterfaceOrientations 30 | 31 | UIInterfaceOrientationPortrait 32 | UIInterfaceOrientationLandscapeLeft 33 | UIInterfaceOrientationLandscapeRight 34 | 35 | UISupportedInterfaceOrientations~ipad 36 | 37 | UIInterfaceOrientationPortrait 38 | UIInterfaceOrientationPortraitUpsideDown 39 | UIInterfaceOrientationLandscapeLeft 40 | UIInterfaceOrientationLandscapeRight 41 | 42 | UIViewControllerBasedStatusBarAppearance 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /example/ios/Runner/Runner-Bridging-Header.h: -------------------------------------------------------------------------------- 1 | #import "GeneratedPluginRegistrant.h" 2 | -------------------------------------------------------------------------------- /example/lib/core/pay.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_rave/flutter_rave.dart'; 3 | 4 | class PayAPI { 5 | static pay(BuildContext context, {bool mounted = false}) { 6 | final _rave = RaveCardPayment( 7 | isDemo: true, 8 | encKey: "c53e399709de57d42e2e36ca", 9 | publicKey: "FLWPUBK-d97d92534644f21f8c50802f0ff44e02-X", 10 | transactionRef: "hvHPvKYaRuJLlJWSPWGGKUyaAfWeZKnm", 11 | amount: 100, 12 | email: "demo1@example.com", 13 | onSuccess: (response) { 14 | print("$response"); 15 | print("Transaction Successful"); 16 | 17 | if (mounted) { 18 | Scaffold.of(context).showSnackBar( 19 | SnackBar( 20 | content: Text("Transaction Sucessful!"), 21 | backgroundColor: Colors.green, 22 | duration: Duration( 23 | seconds: 5, 24 | ), 25 | ), 26 | ); 27 | } 28 | }, 29 | onFailure: (err) { 30 | print("$err"); 31 | print("Transaction failed"); 32 | }, 33 | onClosed: () { 34 | print("Transaction closed"); 35 | }, 36 | context: context, 37 | ); 38 | 39 | _rave.process(); 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /example/lib/generated_plugin_registrant.dart: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | 5 | // ignore: unused_import 6 | import 'dart:ui'; 7 | 8 | import 'package:url_launcher_web/url_launcher_web.dart'; 9 | 10 | import 'package:flutter_web_plugins/flutter_web_plugins.dart'; 11 | 12 | // ignore: public_member_api_docs 13 | void registerPlugins(PluginRegistry registry) { 14 | UrlLauncherPlugin.registerWith(registry.registrarFor(UrlLauncherPlugin)); 15 | registry.registerMessageHandler(); 16 | } 17 | -------------------------------------------------------------------------------- /example/lib/main.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_rave/flutter_rave.dart'; 3 | 4 | import 'core/pay.dart'; 5 | 6 | void main() => runApp(MyApp()); 7 | 8 | class MyApp extends StatelessWidget { 9 | // This widget is the root of your application. 10 | @override 11 | Widget build(BuildContext context) { 12 | return MaterialApp( 13 | title: 'Flutter Rave', 14 | debugShowCheckedModeBanner: false, 15 | theme: ThemeData( 16 | primarySwatch: Colors.blue, 17 | ), 18 | home: MyHomePage(), 19 | ); 20 | } 21 | } 22 | 23 | class MyHomePage extends StatefulWidget { 24 | @override 25 | _MyHomePageState createState() => _MyHomePageState(); 26 | } 27 | 28 | class _MyHomePageState extends State { 29 | @override 30 | Widget build(BuildContext context) { 31 | return Scaffold( 32 | appBar: AppBar( 33 | elevation: 1, 34 | title: Text( 35 | 'Flutter Rave Payment', 36 | style: TextStyle( 37 | color: Colors.black, fontSize: 14, fontWeight: FontWeight.w300), 38 | ), 39 | backgroundColor: Colors.white, 40 | ), 41 | body: Center( 42 | child: Column( 43 | mainAxisAlignment: MainAxisAlignment.center, 44 | crossAxisAlignment: CrossAxisAlignment.center, 45 | children: [ 46 | Text( 47 | 'Click to Pay', 48 | ), 49 | SizedBox( 50 | height: 30, 51 | ), 52 | Container( 53 | height: 50, 54 | width: 200, 55 | child: FlatButton.icon( 56 | color: Colors.redAccent, 57 | onPressed: () { 58 | PayAPI.pay(context, mounted: mounted); 59 | }, 60 | icon: Icon( 61 | Icons.attach_money, 62 | color: Colors.white, 63 | ), 64 | label: Text("Pay"), 65 | textColor: Colors.white, 66 | ), 67 | ), 68 | ], 69 | ), 70 | ), 71 | ); 72 | } 73 | } 74 | -------------------------------------------------------------------------------- /example/pubspec.lock: -------------------------------------------------------------------------------- 1 | # Generated by pub 2 | # See https://dart.dev/tools/pub/glossary#lockfile 3 | packages: 4 | async: 5 | dependency: transitive 6 | description: 7 | name: async 8 | url: "https://pub.dartlang.org" 9 | source: hosted 10 | version: "2.4.1" 11 | boolean_selector: 12 | dependency: transitive 13 | description: 14 | name: boolean_selector 15 | url: "https://pub.dartlang.org" 16 | source: hosted 17 | version: "2.0.0" 18 | charcode: 19 | dependency: transitive 20 | description: 21 | name: charcode 22 | url: "https://pub.dartlang.org" 23 | source: hosted 24 | version: "1.1.3" 25 | clock: 26 | dependency: transitive 27 | description: 28 | name: clock 29 | url: "https://pub.dartlang.org" 30 | source: hosted 31 | version: "1.0.1" 32 | collection: 33 | dependency: transitive 34 | description: 35 | name: collection 36 | url: "https://pub.dartlang.org" 37 | source: hosted 38 | version: "1.14.12" 39 | convert: 40 | dependency: transitive 41 | description: 42 | name: convert 43 | url: "https://pub.dartlang.org" 44 | source: hosted 45 | version: "2.1.1" 46 | crypto: 47 | dependency: transitive 48 | description: 49 | name: crypto 50 | url: "https://pub.dartlang.org" 51 | source: hosted 52 | version: "2.1.4" 53 | cupertino_icons: 54 | dependency: "direct main" 55 | description: 56 | name: cupertino_icons 57 | url: "https://pub.dartlang.org" 58 | source: hosted 59 | version: "0.1.3" 60 | dio: 61 | dependency: transitive 62 | description: 63 | name: dio 64 | url: "https://pub.dartlang.org" 65 | source: hosted 66 | version: "3.0.9" 67 | dio_flutter_transformer: 68 | dependency: transitive 69 | description: 70 | name: dio_flutter_transformer 71 | url: "https://pub.dartlang.org" 72 | source: hosted 73 | version: "3.0.2" 74 | equatable: 75 | dependency: transitive 76 | description: 77 | name: equatable 78 | url: "https://pub.dartlang.org" 79 | source: hosted 80 | version: "1.1.1" 81 | fake_async: 82 | dependency: transitive 83 | description: 84 | name: fake_async 85 | url: "https://pub.dartlang.org" 86 | source: hosted 87 | version: "1.1.0" 88 | flushbar: 89 | dependency: transitive 90 | description: 91 | name: flushbar 92 | url: "https://pub.dartlang.org" 93 | source: hosted 94 | version: "1.10.2" 95 | flutter: 96 | dependency: "direct main" 97 | description: flutter 98 | source: sdk 99 | version: "0.0.0" 100 | flutter_rave: 101 | dependency: "direct main" 102 | description: 103 | path: ".." 104 | relative: true 105 | source: path 106 | version: "0.0.6" 107 | flutter_svg: 108 | dependency: transitive 109 | description: 110 | name: flutter_svg 111 | url: "https://pub.dartlang.org" 112 | source: hosted 113 | version: "0.17.4" 114 | flutter_test: 115 | dependency: "direct dev" 116 | description: flutter 117 | source: sdk 118 | version: "0.0.0" 119 | flutter_web_plugins: 120 | dependency: transitive 121 | description: flutter 122 | source: sdk 123 | version: "0.0.0" 124 | flutter_webview_plugin: 125 | dependency: transitive 126 | description: 127 | name: flutter_webview_plugin 128 | url: "https://pub.dartlang.org" 129 | source: hosted 130 | version: "0.3.11" 131 | http_parser: 132 | dependency: transitive 133 | description: 134 | name: http_parser 135 | url: "https://pub.dartlang.org" 136 | source: hosted 137 | version: "3.1.4" 138 | intl: 139 | dependency: transitive 140 | description: 141 | name: intl 142 | url: "https://pub.dartlang.org" 143 | source: hosted 144 | version: "0.16.1" 145 | js: 146 | dependency: transitive 147 | description: 148 | name: js 149 | url: "https://pub.dartlang.org" 150 | source: hosted 151 | version: "0.6.1+1" 152 | matcher: 153 | dependency: transitive 154 | description: 155 | name: matcher 156 | url: "https://pub.dartlang.org" 157 | source: hosted 158 | version: "0.12.6" 159 | meta: 160 | dependency: transitive 161 | description: 162 | name: meta 163 | url: "https://pub.dartlang.org" 164 | source: hosted 165 | version: "1.1.8" 166 | path: 167 | dependency: transitive 168 | description: 169 | name: path 170 | url: "https://pub.dartlang.org" 171 | source: hosted 172 | version: "1.7.0" 173 | path_drawing: 174 | dependency: transitive 175 | description: 176 | name: path_drawing 177 | url: "https://pub.dartlang.org" 178 | source: hosted 179 | version: "0.4.1" 180 | path_parsing: 181 | dependency: transitive 182 | description: 183 | name: path_parsing 184 | url: "https://pub.dartlang.org" 185 | source: hosted 186 | version: "0.1.4" 187 | petitparser: 188 | dependency: transitive 189 | description: 190 | name: petitparser 191 | url: "https://pub.dartlang.org" 192 | source: hosted 193 | version: "3.0.2" 194 | plugin_platform_interface: 195 | dependency: transitive 196 | description: 197 | name: plugin_platform_interface 198 | url: "https://pub.dartlang.org" 199 | source: hosted 200 | version: "1.0.2" 201 | sky_engine: 202 | dependency: transitive 203 | description: flutter 204 | source: sdk 205 | version: "0.0.99" 206 | source_span: 207 | dependency: transitive 208 | description: 209 | name: source_span 210 | url: "https://pub.dartlang.org" 211 | source: hosted 212 | version: "1.7.0" 213 | stack_trace: 214 | dependency: transitive 215 | description: 216 | name: stack_trace 217 | url: "https://pub.dartlang.org" 218 | source: hosted 219 | version: "1.9.3" 220 | stream_channel: 221 | dependency: transitive 222 | description: 223 | name: stream_channel 224 | url: "https://pub.dartlang.org" 225 | source: hosted 226 | version: "2.0.0" 227 | string_scanner: 228 | dependency: transitive 229 | description: 230 | name: string_scanner 231 | url: "https://pub.dartlang.org" 232 | source: hosted 233 | version: "1.0.5" 234 | term_glyph: 235 | dependency: transitive 236 | description: 237 | name: term_glyph 238 | url: "https://pub.dartlang.org" 239 | source: hosted 240 | version: "1.1.0" 241 | test_api: 242 | dependency: transitive 243 | description: 244 | name: test_api 245 | url: "https://pub.dartlang.org" 246 | source: hosted 247 | version: "0.2.15" 248 | tripledes: 249 | dependency: transitive 250 | description: 251 | name: tripledes 252 | url: "https://pub.dartlang.org" 253 | source: hosted 254 | version: "2.1.0" 255 | typed_data: 256 | dependency: transitive 257 | description: 258 | name: typed_data 259 | url: "https://pub.dartlang.org" 260 | source: hosted 261 | version: "1.1.6" 262 | url_launcher: 263 | dependency: transitive 264 | description: 265 | name: url_launcher 266 | url: "https://pub.dartlang.org" 267 | source: hosted 268 | version: "5.4.5" 269 | url_launcher_macos: 270 | dependency: transitive 271 | description: 272 | name: url_launcher_macos 273 | url: "https://pub.dartlang.org" 274 | source: hosted 275 | version: "0.0.1+5" 276 | url_launcher_platform_interface: 277 | dependency: transitive 278 | description: 279 | name: url_launcher_platform_interface 280 | url: "https://pub.dartlang.org" 281 | source: hosted 282 | version: "1.0.6" 283 | url_launcher_web: 284 | dependency: transitive 285 | description: 286 | name: url_launcher_web 287 | url: "https://pub.dartlang.org" 288 | source: hosted 289 | version: "0.1.1+4" 290 | vector_math: 291 | dependency: transitive 292 | description: 293 | name: vector_math 294 | url: "https://pub.dartlang.org" 295 | source: hosted 296 | version: "2.0.8" 297 | webview_flutter: 298 | dependency: transitive 299 | description: 300 | name: webview_flutter 301 | url: "https://pub.dartlang.org" 302 | source: hosted 303 | version: "0.3.21" 304 | xml: 305 | dependency: transitive 306 | description: 307 | name: xml 308 | url: "https://pub.dartlang.org" 309 | source: hosted 310 | version: "3.7.0" 311 | sdks: 312 | dart: ">=2.7.2 <3.0.0" 313 | flutter: ">=1.12.13+hotfix.5 <2.0.0" 314 | -------------------------------------------------------------------------------- /example/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: example 2 | description: A new Flutter project. 3 | 4 | # The following defines the version and build number for your application. 5 | # A version number is three numbers separated by dots, like 1.2.43 6 | # followed by an optional build number separated by a +. 7 | # Both the version and the builder number may be overridden in flutter 8 | # build by specifying --build-name and --build-number, respectively. 9 | # In Android, build-name is used as versionName while build-number used as versionCode. 10 | # Read more about Android versioning at https://developer.android.com/studio/publish/versioning 11 | # In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion. 12 | # Read more about iOS versioning at 13 | # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html 14 | version: 1.0.0+1 15 | 16 | environment: 17 | sdk: ">=2.1.0 <3.0.0" 18 | 19 | dependencies: 20 | flutter: 21 | sdk: flutter 22 | flutter_rave: 23 | path: ../ 24 | # The following adds the Cupertino Icons font to your application. 25 | # Use with the CupertinoIcons class for iOS style icons. 26 | cupertino_icons: ^0.1.2 27 | 28 | dev_dependencies: 29 | flutter_test: 30 | sdk: flutter 31 | 32 | 33 | # For information on the generic Dart part of this file, see the 34 | # following page: https://www.dartlang.org/tools/pub/pubspec 35 | 36 | # The following section is specific to Flutter. 37 | flutter: 38 | 39 | # The following line ensures that the Material Icons font is 40 | # included with your application, so that you can use the icons in 41 | # the material Icons class. 42 | uses-material-design: true 43 | 44 | # To add assets to your application, add an assets section, like this: 45 | # assets: 46 | # - images/a_dot_burr.jpeg 47 | # - images/a_dot_ham.jpeg 48 | 49 | # An image asset can refer to one or more resolution-specific "variants", see 50 | # https://flutter.dev/assets-and-images/#resolution-aware. 51 | 52 | # For details regarding adding assets from package dependencies, see 53 | # https://flutter.dev/assets-and-images/#from-packages 54 | 55 | # To add custom fonts to your application, add a fonts section here, 56 | # in this "flutter" section. Each entry in this list should have a 57 | # "family" key with the font family name, and a "fonts" key with a 58 | # list giving the asset and other descriptors for the font. For 59 | # example: 60 | # fonts: 61 | # - family: Schyler 62 | # fonts: 63 | # - asset: fonts/Schyler-Regular.ttf 64 | # - asset: fonts/Schyler-Italic.ttf 65 | # style: italic 66 | # - family: Trajan Pro 67 | # fonts: 68 | # - asset: fonts/TrajanPro.ttf 69 | # - asset: fonts/TrajanPro_Bold.ttf 70 | # weight: 700 71 | # 72 | # For details regarding fonts from package dependencies, 73 | # see https://flutter.dev/custom-fonts/#from-packages 74 | -------------------------------------------------------------------------------- /example/s1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/s1.png -------------------------------------------------------------------------------- /example/s2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/renealexander616/flutter-rave/2a5ec089c50646d22f4ed30e6e2f368bee89dc53/example/s2.png -------------------------------------------------------------------------------- /example/test/widget_test.dart: -------------------------------------------------------------------------------- 1 | // This is a basic Flutter widget test. 2 | // 3 | // To perform an interaction with a widget in your test, use the WidgetTester 4 | // utility that Flutter provides. For example, you can send tap and scroll 5 | // gestures. You can also use WidgetTester to find child widgets in the widget 6 | // tree, read text, and verify that the values of widget properties are correct. 7 | 8 | //import 'package:flutter/material.dart'; 9 | //import 'package:flutter_test/flutter_test.dart'; 10 | 11 | //import 'package:example/main.dart'; 12 | 13 | void main() { 14 | // testWidgets('Counter increments smoke test', (WidgetTester tester) async { 15 | // // Build our app and trigger a frame. 16 | // await tester.pumpWidget(MyApp()); 17 | // 18 | // // Verify that our counter starts at 0. 19 | // expect(find.text('0'), findsOneWidget); 20 | // expect(find.text('1'), findsNothing); 21 | // 22 | // // Tap the '+' icon and trigger a frame. 23 | // await tester.tap(find.byIcon(Icons.add)); 24 | // await tester.pump(); 25 | // 26 | // // Verify that our counter has incremented. 27 | // expect(find.text('0'), findsNothing); 28 | // expect(find.text('1'), findsOneWidget); 29 | // }); 30 | } 31 | -------------------------------------------------------------------------------- /lib/flutter_rave.dart: -------------------------------------------------------------------------------- 1 | library flutter_rave; 2 | 3 | import 'dart:async'; 4 | import 'dart:convert'; 5 | import 'dart:io'; 6 | 7 | import 'package:equatable/equatable.dart'; 8 | import 'package:flutter/cupertino.dart'; 9 | import 'package:flutter/foundation.dart'; 10 | import 'package:flutter/material.dart'; 11 | import 'package:flutter/services.dart'; 12 | import 'package:flutter_rave/src/api/services/rave_api_service.dart'; 13 | import 'package:flutter_rave/src/config/constants.dart'; 14 | import 'package:flutter_rave/src/ui/components/overlay_loader_widget.dart'; 15 | import 'package:flutter_rave/src/utils/assets.dart'; 16 | import 'package:flutter_rave/src/utils/credit_card.dart'; 17 | import 'package:flutter_rave/src/utils/masked_input_formatter.dart'; 18 | import 'package:flutter_svg/flutter_svg.dart'; 19 | import 'package:flutter_webview_plugin/flutter_webview_plugin.dart'; 20 | 21 | part 'rave_provider.dart'; 22 | 23 | class RaveCardPayment { 24 | final String publicKey; 25 | final String encKey; 26 | final String transactionRef; 27 | final List> subaccounts; 28 | final double amount; 29 | final String email; 30 | final Function onSuccess; 31 | final Function onFailure; 32 | final Function onClosed; 33 | final BuildContext context; 34 | final bool isDemo; 35 | final bool isDollar; 36 | 37 | const RaveCardPayment({ 38 | Key key, 39 | @required this.publicKey, 40 | @required this.encKey, 41 | @required this.transactionRef, 42 | @required this.amount, 43 | @required this.email, 44 | this.subaccounts, 45 | this.isDemo = false, 46 | this.isDollar = false, 47 | this.onSuccess, 48 | this.onFailure, 49 | this.onClosed, 50 | @required this.context, 51 | }); 52 | 53 | void process() { 54 | showDialog( 55 | context: context, 56 | builder: (dialogContext) { 57 | return _AddDebitCardScreen( 58 | isDemo: this.isDemo, 59 | isDollar: this.isDollar, 60 | publicKey: this.publicKey, 61 | encKey: this.encKey, 62 | transactionRef: this.transactionRef, 63 | subaccounts: this.subaccounts, 64 | amount: this.amount, 65 | email: this.email, 66 | onSuccess: (r) { 67 | Navigator.of(dialogContext).pop(); 68 | if (this.onSuccess != null) { 69 | this.onSuccess(r); 70 | } 71 | 72 | if (this.onClosed != null) { 73 | this.onClosed(); 74 | } 75 | }, 76 | onFailure: (r) { 77 | Navigator.of(dialogContext).pop(); 78 | if (this.onFailure != null) { 79 | this.onFailure(r); 80 | } 81 | 82 | if (this.onClosed != null) { 83 | this.onClosed(); 84 | } 85 | }, 86 | onClose: () { 87 | Navigator.of(dialogContext).pop(); 88 | if (this.onClosed != null) { 89 | this.onClosed(); 90 | } 91 | }, 92 | ); 93 | }, 94 | ); 95 | } 96 | } 97 | 98 | class CreditCardInfo extends Equatable { 99 | final String cardNumber; 100 | final String expirationMonth; 101 | final String expirationYear; 102 | final String cvv; 103 | 104 | String brand; 105 | String type; 106 | 107 | CreditCardInfo( 108 | this.cardNumber, this.expirationMonth, this.expirationYear, this.cvv); 109 | 110 | bool get isComplete { 111 | return cardNumber != null && 112 | cardNumber.isNotEmpty && 113 | expirationMonth != null && 114 | expirationMonth.isNotEmpty && 115 | expirationYear != null && 116 | expirationYear.isNotEmpty && 117 | cvv != null && 118 | cvv.isNotEmpty; 119 | } 120 | 121 | @override 122 | List get props => [ 123 | cvv, 124 | expirationMonth, 125 | expirationYear, 126 | cardNumber, 127 | ]; 128 | } 129 | 130 | class _AddDebitCardScreen extends StatefulWidget { 131 | static String route = "/debit-cards/add"; 132 | final String publicKey; 133 | final String encKey; 134 | final String transactionRef; 135 | final List> subaccounts; 136 | final double amount; 137 | final String email; 138 | final bool isDemo; 139 | final bool isDollar; 140 | final Function onSuccess; 141 | final Function onFailure; 142 | final Function onClose; 143 | 144 | const _AddDebitCardScreen({ 145 | Key key, 146 | @required this.publicKey, 147 | @required this.encKey, 148 | @required this.transactionRef, 149 | @required this.amount, 150 | @required this.email, 151 | this.subaccounts, 152 | this.isDemo = false, 153 | this.isDollar = false, 154 | this.onSuccess, 155 | this.onFailure, 156 | this.onClose, 157 | }) : super(key: key); 158 | 159 | @override 160 | __AddDebitCardScreenState createState() => __AddDebitCardScreenState(); 161 | } 162 | 163 | class __AddDebitCardScreenState extends State<_AddDebitCardScreen> { 164 | GlobalKey _globalKey = GlobalKey(); 165 | 166 | bool canContinue = false; 167 | CreditCardInfo _cardInfo; 168 | Function _processCard; 169 | 170 | @override 171 | Widget build(BuildContext context) { 172 | return Material( 173 | color: Colors.transparent, 174 | child: Container( 175 | color: Colors.black12.withOpacity(0.1), 176 | child: Stack( 177 | alignment: AlignmentDirectional.center, 178 | fit: StackFit.expand, 179 | children: [ 180 | AbsorbPointer(), 181 | SafeArea( 182 | child: Center( 183 | child: Form( 184 | key: _globalKey, 185 | child: Padding( 186 | padding: const EdgeInsets.all(20.0), 187 | child: Stack( 188 | alignment: AlignmentDirectional.center, 189 | children: [ 190 | Container( 191 | decoration: BoxDecoration( 192 | color: Colors.white, 193 | borderRadius: BorderRadius.circular(8.0), 194 | ), 195 | child: Padding( 196 | padding: const EdgeInsets.all(20.0), 197 | child: Column( 198 | crossAxisAlignment: CrossAxisAlignment.center, 199 | mainAxisAlignment: MainAxisAlignment.center, 200 | mainAxisSize: MainAxisSize.min, 201 | children: [ 202 | SizedBox( 203 | child: RaveProvider( 204 | isDemo: widget.isDemo, 205 | publicKey: widget.publicKey, 206 | encKey: widget.encKey, 207 | transactionRef: widget.transactionRef, 208 | amount: widget.amount, 209 | email: widget.email, 210 | subaccounts: widget.subaccounts, 211 | onSuccess: widget.onSuccess, 212 | onFailure: widget.onSuccess, 213 | cardInfo: _cardInfo, 214 | builder: (context, processCard) { 215 | _processCard = processCard; 216 | return _AddDebitCardWidget( 217 | amount: widget.amount, 218 | isDollar: widget.isDollar, 219 | onValidated: (CreditCardInfo creditCard) { 220 | if (creditCard != null) { 221 | setState( 222 | () { 223 | _cardInfo = creditCard; 224 | }, 225 | ); 226 | } 227 | setState( 228 | () { 229 | canContinue = creditCard != null; 230 | }, 231 | ); 232 | }, 233 | ); 234 | }, 235 | ), 236 | ), 237 | SizedBox( 238 | height: 10, 239 | ), 240 | Container( 241 | width: double.infinity, 242 | height: 60, 243 | padding: EdgeInsets.symmetric(horizontal: 10), 244 | child: FlatButton( 245 | color: Theme.of(context).accentColor, 246 | disabledColor: Colors.grey[300], 247 | onPressed: canContinue 248 | ? () async { 249 | var result; 250 | try { 251 | result = await _processCard(); 252 | } catch (e) { 253 | widget.onFailure(e); 254 | return; 255 | } 256 | 257 | if (result != null) { 258 | if (widget.onSuccess != null) { 259 | widget.onSuccess(result); 260 | } 261 | } else { 262 | if (widget.onFailure != null) { 263 | widget.onFailure( 264 | "Transaction Failed"); 265 | } 266 | } 267 | } 268 | : null, 269 | child: Text( 270 | "Continue", 271 | style: TextStyle( 272 | color: Colors.white, 273 | ), 274 | ), 275 | ), 276 | ), 277 | SizedBox( 278 | height: 20, 279 | ), 280 | ], 281 | ), 282 | ), 283 | ), 284 | Positioned( 285 | right: 30.0, 286 | top: 20.0, 287 | width: 20.0, 288 | height: 20.0, 289 | child: InkWell( 290 | onTap: () { 291 | if (widget.onClose != null) { 292 | widget.onClose(); 293 | } 294 | }, 295 | child: Container( 296 | decoration: BoxDecoration( 297 | shape: BoxShape.circle, 298 | ), 299 | child: Center( 300 | child: Icon( 301 | Icons.close, 302 | color: Colors.red, 303 | size: 23, 304 | ), 305 | ), 306 | ), 307 | ), 308 | ), 309 | ], 310 | ), 311 | ), 312 | ), 313 | )), 314 | ], 315 | ), 316 | ), 317 | ); 318 | } 319 | } 320 | 321 | class _AddDebitCardWidget extends StatefulWidget { 322 | final Function(CreditCardInfo) onValidated; 323 | final double amount; 324 | final bool isDollar; 325 | 326 | const _AddDebitCardWidget({ 327 | Key key, 328 | this.onValidated, 329 | @required this.amount, 330 | @required this.isDollar, 331 | }) : super(key: key); 332 | 333 | @override 334 | __AddDebitCardWidgetState createState() => __AddDebitCardWidgetState(); 335 | } 336 | 337 | class __AddDebitCardWidgetState extends State<_AddDebitCardWidget> { 338 | TextEditingController _creditCardNumberController = TextEditingController(); 339 | TextEditingController _creditCardExpirationController = 340 | TextEditingController(); 341 | TextEditingController _cvvController = TextEditingController(); 342 | 343 | final expirationMaskFormatter = MaskTextInputFormatter('__/__'); 344 | final creditCardTextInputFormatter = CreditCardTextInputFormatter(); 345 | 346 | FocusNode _cardNumerFocusNode = FocusNode(); 347 | FocusNode _cardExpDateFocusNode = FocusNode(); 348 | FocusNode _cardCvvFocusNode = FocusNode(); 349 | 350 | String cardNumber = ''; 351 | String unmaskedCardNumber = ''; 352 | 353 | String expirationValue = ''; 354 | String unmaskedExpirationDateValue = ''; 355 | 356 | String cvv; 357 | String cardBrand; 358 | String cardBin = ""; 359 | 360 | CreditCardInfo _creditCardInfo; 361 | 362 | _onExpirationDateTextChange(String s) { 363 | setState(() { 364 | expirationValue = s; 365 | unmaskedExpirationDateValue = expirationMaskFormatter.getEscapedString(s); 366 | }); 367 | 368 | if (expirationValue.length >= 5) { 369 | FocusScope.of(context).requestFocus(_cardCvvFocusNode); 370 | } 371 | 372 | _validate(); 373 | } 374 | 375 | _onCardNumberChanged(String s) { 376 | final _unmaskedCardNumber = creditCardTextInputFormatter.getRawString(); 377 | 378 | if (_unmaskedCardNumber.isNotEmpty) { 379 | final r = CreditCardUtils(_unmaskedCardNumber); 380 | final f = r.cardIssuer; 381 | String _cardBrand; 382 | if (f == Issuers.VISA) { 383 | _cardBrand = "visa"; 384 | } 385 | if (f == Issuers.MASTERCARD) { 386 | _cardBrand = "mastercard"; 387 | } 388 | if (f == Issuers.VERVE) { 389 | _cardBrand = "verve"; 390 | } 391 | 392 | if (f == Issuers.UNKNOWN) { 393 | _cardBrand = "verve"; 394 | } 395 | 396 | if (_cardBrand != cardBrand) { 397 | setState(() { 398 | cardBrand = _cardBrand; 399 | }); 400 | } 401 | } 402 | 403 | setState(() { 404 | cardNumber = _unmaskedCardNumber; 405 | unmaskedCardNumber = _unmaskedCardNumber; 406 | }); 407 | 408 | _validate(); 409 | } 410 | 411 | _onCvvChange(String s) { 412 | setState(() { 413 | cvv = s; 414 | }); 415 | _validate(); 416 | } 417 | 418 | _validate() { 419 | if (widget.onValidated != null) { 420 | widget.onValidated(null); 421 | } 422 | 423 | if (cardNumber == null || cardNumber.isEmpty) return; 424 | if (cvv == null || cvv.isEmpty) { 425 | return; 426 | } 427 | if (expirationValue == null || expirationValue.isEmpty) return; 428 | final expirationParts = expirationValue.split("/"); 429 | 430 | _creditCardInfo = CreditCardInfo( 431 | cardNumber, expirationParts.first, expirationParts.last, cvv); 432 | _creditCardInfo.brand = cardBrand; 433 | 434 | if (widget.onValidated != null) { 435 | widget.onValidated(_creditCardInfo); 436 | } 437 | } 438 | 439 | @override 440 | void dispose() { 441 | _creditCardNumberController.dispose(); 442 | _creditCardExpirationController.dispose(); 443 | _cvvController.dispose(); 444 | _cardCvvFocusNode.dispose(); 445 | _cardExpDateFocusNode.dispose(); 446 | _cardNumerFocusNode.dispose(); 447 | super.dispose(); 448 | } 449 | 450 | @override 451 | Widget build(BuildContext context) { 452 | return Container( 453 | padding: EdgeInsets.all(10.0), 454 | child: Column( 455 | mainAxisSize: MainAxisSize.max, 456 | crossAxisAlignment: CrossAxisAlignment.start, 457 | children: [ 458 | SizedBox( 459 | height: 30, 460 | ), 461 | Padding( 462 | padding: const EdgeInsets.only( 463 | bottom: 20.0, 464 | ), 465 | child: Container( 466 | height: 50.0, 467 | child: Row( 468 | mainAxisAlignment: MainAxisAlignment.end, 469 | crossAxisAlignment: CrossAxisAlignment.stretch, 470 | children: [ 471 | Expanded( 472 | child: ListTile( 473 | contentPadding: EdgeInsets.zero, 474 | title: Text( 475 | "Enter your Card Details", 476 | style: TextStyle( 477 | color: Colors.black, 478 | fontWeight: FontWeight.w500, 479 | fontSize: 20), 480 | ), 481 | subtitle: Padding( 482 | padding: const EdgeInsets.only(top:10), 483 | child: Text( 484 | "You will be charged ${widget.isDollar ? dollarSymbol : nairaSymbol}${widget.amount}", 485 | style: Theme.of(context).textTheme.subtitle1.copyWith( 486 | color: Colors.grey, 487 | ), 488 | ), 489 | ), 490 | ), 491 | ), 492 | AnimatedOpacity( 493 | opacity: 1.0, 494 | duration: Duration( 495 | milliseconds: 200, 496 | ), 497 | child: Image.asset( 498 | Assets.logo, 499 | package: 'flutter_rave', 500 | width: 20.0, 501 | ), 502 | ), 503 | ], 504 | ), 505 | ), 506 | ), 507 | Padding( 508 | padding: const EdgeInsets.only(bottom: 10.0, top:20), 509 | child: Column( 510 | mainAxisSize: MainAxisSize.min, 511 | crossAxisAlignment: CrossAxisAlignment.start, 512 | children: [ 513 | Text( 514 | "Card Number", 515 | style: Theme.of(context).textTheme.subtitle2.copyWith( 516 | fontSize: 14.0, 517 | color: Colors.grey[600], 518 | ), 519 | ), 520 | SizedBox( 521 | height: 20, 522 | ), 523 | TextField( 524 | focusNode: _cardNumerFocusNode, 525 | controller: _creditCardNumberController, 526 | onChanged: _onCardNumberChanged, 527 | keyboardType: TextInputType.number, 528 | textInputAction: TextInputAction.next, 529 | onSubmitted: (v) { 530 | _onCardNumberChanged(v); 531 | FocusScope.of(context).requestFocus(_cardCvvFocusNode); 532 | }, 533 | inputFormatters: [ 534 | WhitelistingTextInputFormatter.digitsOnly, 535 | creditCardTextInputFormatter, 536 | ], 537 | decoration: InputDecoration( 538 | filled: true, 539 | fillColor: Colors.white, 540 | hintText: "0000 1234 1234 1234 1234", 541 | enabledBorder: OutlineInputBorder( 542 | borderRadius: BorderRadius.circular(4.0), 543 | borderSide: BorderSide(color: Colors.grey[200]), 544 | ), 545 | focusedBorder: OutlineInputBorder( 546 | borderRadius: BorderRadius.circular(4.0), 547 | borderSide: BorderSide( 548 | color: Theme.of(context).primaryColor, 549 | ), 550 | ), 551 | suffix: _makeCardIconWidget(cardBrand), 552 | ), 553 | ) 554 | ], 555 | ), 556 | ), 557 | SizedBox( 558 | height: 25, 559 | ), 560 | Padding( 561 | padding: const EdgeInsets.only(bottom: 5.0), 562 | child: Container( 563 | width: MediaQuery.of(context).size.width, 564 | child: Row( 565 | crossAxisAlignment: CrossAxisAlignment.start, 566 | mainAxisAlignment: MainAxisAlignment.spaceBetween, 567 | mainAxisSize: MainAxisSize.max, 568 | children: [ 569 | Flexible( 570 | child: Container( 571 | child: Column( 572 | mainAxisSize: MainAxisSize.min, 573 | crossAxisAlignment: CrossAxisAlignment.start, 574 | children: [ 575 | Text( 576 | "Expiry Date", 577 | style: 578 | Theme.of(context).textTheme.subtitle2.copyWith( 579 | fontSize: 14.0, 580 | color: Colors.grey[600], 581 | ), 582 | ), 583 | SizedBox( 584 | height: 20, 585 | ), 586 | TextField( 587 | focusNode: _cardExpDateFocusNode, 588 | maxLength: 5, 589 | maxLengthEnforced: true, 590 | keyboardType: TextInputType.number, 591 | onSubmitted: (v) { 592 | _onExpirationDateTextChange(v); 593 | }, 594 | buildCounter: ( 595 | c, { 596 | int currentLength, 597 | int maxLength, 598 | bool isFocused, 599 | }) { 600 | return Container(); 601 | }, 602 | onChanged: _onExpirationDateTextChange, 603 | inputFormatters: [ 604 | WhitelistingTextInputFormatter.digitsOnly, 605 | expirationMaskFormatter, 606 | ], 607 | controller: _creditCardExpirationController, 608 | decoration: InputDecoration( 609 | filled: true, 610 | fillColor: Colors.white, 611 | hintText: "01/20", 612 | enabledBorder: OutlineInputBorder( 613 | borderRadius: BorderRadius.circular(4.0), 614 | borderSide: BorderSide(color: Colors.grey[200]), 615 | ), 616 | focusedBorder: OutlineInputBorder( 617 | borderRadius: BorderRadius.circular(4.0), 618 | borderSide: BorderSide( 619 | color: Theme.of(context).primaryColor, 620 | ), 621 | ), 622 | ), 623 | ) 624 | ], 625 | ), 626 | ), 627 | ), 628 | SizedBox( 629 | width: 10.0, 630 | ), 631 | Flexible( 632 | child: Container( 633 | child: Column( 634 | mainAxisSize: MainAxisSize.min, 635 | crossAxisAlignment: CrossAxisAlignment.start, 636 | children: [ 637 | Text( 638 | "CVV", 639 | style: 640 | Theme.of(context).textTheme.subtitle2.copyWith( 641 | fontSize: 14.0, 642 | color: Colors.grey[600], 643 | ), 644 | ), 645 | SizedBox( 646 | height: 20, 647 | ), 648 | TextField( 649 | focusNode: _cardCvvFocusNode, 650 | controller: _cvvController, 651 | maxLength: 4, 652 | maxLengthEnforced: true, 653 | keyboardType: TextInputType.number, 654 | onSubmitted: (v) { 655 | _onCvvChange(v); 656 | }, 657 | buildCounter: ( 658 | c, { 659 | int currentLength, 660 | int maxLength, 661 | bool isFocused, 662 | }) { 663 | return Container(); 664 | }, 665 | onChanged: _onCvvChange, 666 | inputFormatters: [ 667 | WhitelistingTextInputFormatter.digitsOnly, 668 | ], 669 | decoration: InputDecoration( 670 | filled: true, 671 | fillColor: Colors.white, 672 | hintText: "000", 673 | enabledBorder: OutlineInputBorder( 674 | borderRadius: BorderRadius.circular(4.0), 675 | borderSide: BorderSide(color: Colors.grey[200]), 676 | ), 677 | focusedBorder: OutlineInputBorder( 678 | borderRadius: BorderRadius.circular(4.0), 679 | borderSide: BorderSide( 680 | color: Theme.of(context).primaryColor, 681 | ), 682 | ), 683 | ), 684 | ) 685 | ], 686 | ), 687 | ), 688 | ), 689 | ], 690 | ), 691 | ), 692 | ), 693 | ], 694 | ), 695 | ); 696 | } 697 | 698 | _makeCardIconWidget([String brand]) { 699 | final size = 20.0; 700 | 701 | if (brand == null) { 702 | return null; 703 | } 704 | 705 | switch (brand.toLowerCase()) { 706 | case "mastercard": 707 | return SvgPicture.asset( 708 | Assets.mastercard, 709 | package: 'flutter_rave', 710 | width: size, 711 | ); 712 | 713 | case "visa": 714 | return SvgPicture.asset( 715 | Assets.visa, 716 | width: size, 717 | package: 'flutter_rave', 718 | color: Colors.white, 719 | ); 720 | 721 | case "verve": 722 | return Image.asset( 723 | Assets.verve, 724 | package: 'flutter_rave', 725 | width: size, 726 | ); 727 | } 728 | 729 | return Image.asset( 730 | Assets.logo, 731 | package: 'flutter_rave', 732 | width: size, 733 | ); 734 | } 735 | } 736 | 737 | class _CardAddedSuccessfully extends StatefulWidget { 738 | @override 739 | __CardAddedSuccessfullyState createState() => __CardAddedSuccessfullyState(); 740 | } 741 | 742 | class __CardAddedSuccessfullyState extends State<_CardAddedSuccessfully> { 743 | @override 744 | Widget build(BuildContext context) { 745 | return Scaffold( 746 | appBar: AppBar(), 747 | body: SafeArea( 748 | child: SingleChildScrollView( 749 | child: Padding( 750 | padding: const EdgeInsets.all(15.0), 751 | child: Column( 752 | mainAxisAlignment: MainAxisAlignment.center, 753 | crossAxisAlignment: CrossAxisAlignment.center, 754 | children: [ 755 | AnimatedOpacity( 756 | opacity: 1.0, 757 | duration: Duration(milliseconds: 500), 758 | curve: Curves.bounceIn, 759 | child: Container( 760 | child: Icon( 761 | Icons.check_circle, 762 | size: 80.0, 763 | color: Theme.of(context).accentColor, 764 | ), 765 | ), 766 | ), 767 | SizedBox( 768 | height: 25, 769 | ), 770 | Text( 771 | "We've added your Debit Card", 772 | textAlign: TextAlign.center, 773 | style: Theme.of(context).textTheme.headline6.copyWith( 774 | fontWeight: FontWeight.bold, 775 | ), 776 | ), 777 | SizedBox( 778 | height: 15, 779 | ), 780 | Text( 781 | "We've successfully added your card, you can now save with it.", 782 | style: Theme.of(context).textTheme.bodyText2, 783 | textAlign: TextAlign.center, 784 | ), 785 | SizedBox( 786 | height: 25, 787 | ), 788 | SizedBox( 789 | width: double.infinity, 790 | child: FlatButton( 791 | color: Theme.of(context).primaryColor, 792 | disabledColor: Colors.grey[300], 793 | onPressed: () {}, 794 | child: Text( 795 | "Continue", 796 | style: TextStyle( 797 | color: Colors.white, 798 | ), 799 | ), 800 | ), 801 | ) 802 | ], 803 | ), 804 | ), 805 | )), 806 | ); 807 | } 808 | } 809 | -------------------------------------------------------------------------------- /lib/rave_provider.dart: -------------------------------------------------------------------------------- 1 | //library flutter_rave; 2 | 3 | part of "flutter_rave.dart"; 4 | 5 | typedef Widget RaveWidgetBuilder( 6 | BuildContext context, 7 | VoidCallback processCard, 8 | ); 9 | 10 | class RaveInAppLocalhostServer { 11 | HttpServer _server; 12 | int _port = 8184; 13 | Function(Map) _onResponse; 14 | 15 | RaveInAppLocalhostServer( 16 | {int port = 8184, Function(Map) onResponse}) { 17 | this._port = port; 18 | this._onResponse = onResponse; 19 | } 20 | 21 | Future start() async { 22 | if (this._server != null) { 23 | throw Exception('Server already started on http://127.0.0.1:$_port'); 24 | } 25 | var completer = new Completer(); 26 | runZoned(() { 27 | HttpServer.bind('127.0.0.1', _port).then((server) { 28 | this._server = server; 29 | server.listen((HttpRequest request) async { 30 | var qParams = request.requestedUri.queryParameters; 31 | if (this._onResponse != null) { 32 | this._onResponse(qParams); 33 | } 34 | request.response.close(); 35 | }); 36 | 37 | completer.complete(); 38 | }); 39 | }, onError: (e, stackTrace) => print('Error: $e $stackTrace')); 40 | 41 | return completer.future; 42 | } 43 | 44 | ///Closes the server. 45 | Future close() async { 46 | if (this._server != null) { 47 | await this._server.close(force: true); 48 | 49 | this._server = null; 50 | } 51 | } 52 | } 53 | 54 | class RaveProvider extends StatefulWidget { 55 | final RaveWidgetBuilder builder; 56 | final CreditCardInfo cardInfo; 57 | final List> subaccounts; 58 | final String publicKey; 59 | final String encKey; 60 | final String transactionRef; 61 | final double amount; 62 | final String email; 63 | final Function onSuccess; 64 | final Function onFailure; 65 | final bool isDemo; 66 | 67 | RaveProvider({ 68 | Key key, 69 | this.builder, 70 | this.isDemo = false, 71 | @required this.cardInfo, 72 | @required this.publicKey, 73 | @required this.encKey, 74 | this.subaccounts, 75 | this.transactionRef, 76 | this.amount, 77 | this.email, 78 | this.onSuccess, 79 | this.onFailure, 80 | }) : super(key: key); 81 | 82 | @override 83 | _RaveProviderState createState() => _RaveProviderState(); 84 | } 85 | 86 | class _RaveProviderState extends State { 87 | RaveApiService _raveService = RaveApiService.instance; 88 | 89 | static const AUTH_PIN = "PIN"; 90 | static const ACCESS_OTP = "ACCESS_OTP"; 91 | static const NOAUTH_INTERNATIONAL = "NOAUTH_INTERNATIONAL"; 92 | static const AVS_VBVSECURECODE = "AVS_VBVSECURECODE"; 93 | RaveInAppLocalhostServer localhostServer; 94 | 95 | bool isProcessing = false; 96 | bool webhookSuccess = false; 97 | bool canContinue = false; 98 | Map responseResult; 99 | 100 | Route verificationRoute; 101 | BuildContext verificationRouteContext; 102 | 103 | @override 104 | void initState() { 105 | super.initState(); 106 | this.webhookSuccess = false; 107 | this.canContinue = false; 108 | this.responseResult = null; 109 | verificationRoute = null; 110 | _startServer(); 111 | } 112 | 113 | _startServer() async { 114 | localhostServer = RaveInAppLocalhostServer( 115 | onResponse: this.onRaveFeedback, 116 | ); 117 | await localhostServer.start(); 118 | } 119 | 120 | @override 121 | void dispose() { 122 | this.webhookSuccess = false; 123 | this.canContinue = false; 124 | this.responseResult = null; 125 | verificationRoute = null; 126 | localhostServer.close(); 127 | super.dispose(); 128 | } 129 | 130 | @override 131 | void didChangeDependencies() { 132 | super.didChangeDependencies(); 133 | } 134 | 135 | @override 136 | Widget build(BuildContext context) { 137 | return Stack( 138 | alignment: AlignmentDirectional.center, 139 | children: [ 140 | Container( 141 | child: widget.builder(context, processCard), 142 | ), 143 | isProcessing 144 | ? OverlayLoaderWidget() 145 | : Container( 146 | width: 0, 147 | height: 0, 148 | ), 149 | ], 150 | ); 151 | } 152 | 153 | Future> processCard({ 154 | String suggestedAuth, 155 | String redirectUrl = "http://127.0.0.1:8184", 156 | String suggestedAuthValue, 157 | Map billingAddressInfo, 158 | }) async { 159 | try { 160 | if (widget.cardInfo == null) return null; 161 | if (!widget.cardInfo.isComplete) return null; 162 | 163 | String authValue; 164 | 165 | setState(() { 166 | isProcessing = true; 167 | }); 168 | 169 | var response = await _raveService.startChargeCard( 170 | widget.cardInfo, 171 | widget.publicKey, 172 | widget.encKey, 173 | email: widget.email, 174 | isProduction: !widget.isDemo, 175 | transactionReference: widget.transactionRef, 176 | amount: widget.amount, 177 | redirectUrl: redirectUrl, 178 | suggestedAuth: suggestedAuth, 179 | suggestedAuthValue: suggestedAuthValue, 180 | billingAddressInfo: billingAddressInfo, 181 | subaccounts: widget.subaccounts, 182 | ); 183 | 184 | setState(() { 185 | isProcessing = false; 186 | }); 187 | 188 | if (response["message"] == "AUTH_SUGGESTION") { 189 | if (response["data"]["suggested_auth"] == AUTH_PIN) { 190 | authValue = await _getAuthValue(response["data"]["suggested_auth"]); 191 | 192 | setState(() { 193 | isProcessing = false; 194 | }); 195 | 196 | return processCard( 197 | suggestedAuth: response["data"]["suggested_auth"], 198 | suggestedAuthValue: authValue, 199 | ); 200 | } 201 | 202 | if (response["data"]["suggested_auth"] == AVS_VBVSECURECODE || 203 | response["data"]["suggested_auth"] == NOAUTH_INTERNATIONAL) { 204 | final additionalPayload = await _collectAddressDetails(); 205 | 206 | setState(() { 207 | isProcessing = false; 208 | }); 209 | 210 | return processCard( 211 | suggestedAuth: response["data"]["suggested_auth"], 212 | suggestedAuthValue: null, 213 | billingAddressInfo: additionalPayload, 214 | ); 215 | } 216 | } 217 | 218 | if (response["message"] == "V-COMP" && 219 | response["data"]["chargeResponseCode"] == "02") { 220 | if (response["data"]["authModelUsed"] == ACCESS_OTP) { 221 | final otp = await _getAuthValue( 222 | "OTP", 223 | response["data"]["chargeResponseMessage"], 224 | ); 225 | 226 | try { 227 | setState(() { 228 | isProcessing = true; 229 | }); 230 | final r = await _raveService.validateTransaction( 231 | response["data"]["flwRef"], 232 | otp, 233 | widget.publicKey, 234 | !widget.isDemo, 235 | ); 236 | 237 | setState(() { 238 | isProcessing = false; 239 | }); 240 | return r; 241 | } catch (e) { 242 | setState(() { 243 | isProcessing = false; 244 | }); 245 | rethrow; 246 | } 247 | } else if (response["data"]["authModelUsed"] == "PIN") { 248 | final otp = await _getAuthValue( 249 | "OTP", 250 | response["data"]["chargeResponseMessage"], 251 | ); 252 | 253 | try { 254 | setState(() { 255 | isProcessing = true; 256 | }); 257 | final r = await _raveService.validateTransaction( 258 | response["data"]["flwRef"], 259 | otp, 260 | widget.publicKey, 261 | !widget.isDemo, 262 | ); 263 | 264 | setState(() { 265 | isProcessing = false; 266 | }); 267 | return r; 268 | } catch (e) { 269 | setState(() { 270 | isProcessing = false; 271 | }); 272 | rethrow; 273 | } 274 | } else if (response["data"]["authModelUsed"] == "VBVSECURECODE") { 275 | final uri = Uri.parse(response["data"]["authurl"]); 276 | var raveVerificationData; 277 | 278 | verificationRoute = MaterialPageRoute>( 279 | builder: (c) { 280 | verificationRouteContext = c; 281 | 282 | return WebviewScaffold( 283 | url: uri.toString(), 284 | appBar: AppBar( 285 | elevation: 0, 286 | backgroundColor: Colors.white, 287 | centerTitle: true, 288 | shape: Border( 289 | bottom: BorderSide( 290 | color: Colors.grey[500], 291 | ), 292 | ), 293 | iconTheme: IconThemeData( 294 | color: Colors.grey[600], 295 | ), 296 | title: const Text( 297 | 'Card Verification', 298 | style: TextStyle( 299 | fontSize: 12.0, 300 | fontWeight: FontWeight.w500, 301 | color: Colors.green, 302 | ), 303 | ), 304 | ), 305 | withZoom: false, 306 | withLocalStorage: true, 307 | withJavascript: true, 308 | hidden: true, 309 | initialChild: Center( 310 | child: CupertinoActivityIndicator(), 311 | ), 312 | ); 313 | }, 314 | fullscreenDialog: true, 315 | ); 316 | await Navigator.of(context).push(verificationRoute); 317 | 318 | if (!webhookSuccess) { 319 | throw "Failed to process transaction $uri"; 320 | } 321 | raveVerificationData = responseResult; 322 | 323 | if (raveVerificationData != null && 324 | raveVerificationData["chargeResponseCode"].toString() == "00") { 325 | setState(() { 326 | isProcessing = false; 327 | }); 328 | 329 | return raveVerificationData; 330 | } 331 | } 332 | } 333 | 334 | if (response["message"] == "V-COMP" && 335 | response["data"]["chargeResponseCode"] == "00") { 336 | setState(() { 337 | isProcessing = false; 338 | }); 339 | 340 | return response; 341 | } 342 | 343 | setState(() { 344 | isProcessing = false; 345 | }); 346 | 347 | return null; 348 | } catch (e) { 349 | if (mounted) { 350 | Scaffold.of(context).showSnackBar( 351 | SnackBar( 352 | content: Text("${e.toString()}"), 353 | duration: Duration( 354 | seconds: 5, 355 | ), 356 | backgroundColor: Colors.red, 357 | ), 358 | ); 359 | 360 | setState(() { 361 | isProcessing = false; 362 | }); 363 | } 364 | rethrow; 365 | } 366 | } 367 | 368 | Future _getAuthValue(String response, [String message]) async { 369 | final _value = await _showValueModal( 370 | title: response, 371 | message: message ?? "Please provide your $response", 372 | ); 373 | 374 | return _value; 375 | } 376 | 377 | Future _showValueModal({String title, String message}) async { 378 | String value = await showDialog( 379 | barrierDismissible: false, 380 | context: context, 381 | builder: (c) { 382 | return ValueCollectorComponent( 383 | title: title, 384 | message: message, 385 | onValueCollected: (value) { 386 | Navigator.of( 387 | c, 388 | rootNavigator: true, 389 | ).pop(value); 390 | }); 391 | }, 392 | ); 393 | 394 | return value; 395 | } 396 | 397 | Future> _collectAddressDetails() async { 398 | return await Navigator.of(context).push>( 399 | MaterialPageRoute>( 400 | builder: (c) => BillingInfoProvider(), 401 | fullscreenDialog: true, 402 | ), 403 | ); 404 | } 405 | 406 | onRaveFeedback(Map feedback) { 407 | if (feedback != null && feedback.containsKey("response")) { 408 | this.responseResult = json.decode(feedback["response"]); 409 | this.canContinue = true; 410 | this.webhookSuccess = true; 411 | 412 | if (verificationRoute != null && verificationRouteContext != null) { 413 | Navigator.of(verificationRouteContext).pop(this.responseResult); 414 | } 415 | 416 | setState(() {}); 417 | } 418 | } 419 | } 420 | 421 | class BillingInfoProvider extends StatefulWidget { 422 | @override 423 | _BillingInfoProviderState createState() => _BillingInfoProviderState(); 424 | } 425 | 426 | class _BillingInfoProviderState extends State { 427 | GlobalKey _globalKey = GlobalKey(); 428 | 429 | String billingzip = ""; 430 | String billingcity = ""; 431 | String billingaddress = ""; 432 | String billingstate = ""; 433 | String billingcountry = ""; 434 | 435 | Future>> countries; 436 | 437 | Map selectedCountry; 438 | Map selectedState; 439 | 440 | @override 441 | void initState() { 442 | super.initState(); 443 | 444 | countries = fetchCountries(context); 445 | } 446 | 447 | List> parseCountries(String responseBody) { 448 | final decoded = json.decode(responseBody); 449 | final parsed = (decoded as List) 450 | .map((i) => (i as Map)) 451 | .toList(); 452 | return parsed; 453 | } 454 | 455 | Future>> fetchCountries( 456 | BuildContext context) async { 457 | try { 458 | final response = await rootBundle.loadString(Assets.jsonCountries); 459 | 460 | return parseCountries(response); // compute(, response); 461 | } catch (e) { 462 | return []; 463 | } 464 | } 465 | 466 | @override 467 | Widget build(BuildContext context) { 468 | return Scaffold( 469 | appBar: AppBar(), 470 | body: SafeArea( 471 | child: SingleChildScrollView( 472 | child: Form( 473 | key: _globalKey, 474 | child: Padding( 475 | padding: EdgeInsets.symmetric( 476 | horizontal: 20.0, 477 | ), 478 | child: Column( 479 | crossAxisAlignment: CrossAxisAlignment.stretch, 480 | children: [ 481 | Text( 482 | "Provide your Billing details", 483 | style: Theme.of(context).textTheme.headline6.copyWith( 484 | fontWeight: FontWeight.bold, 485 | ), 486 | ), 487 | SizedBox( 488 | height: 15, 489 | ), 490 | Text( 491 | "Your billings details are required to validate your card", 492 | style: Theme.of(context).textTheme.bodyText1, 493 | ), 494 | SizedBox( 495 | height: 15, 496 | ), 497 | TextFormField( 498 | textInputAction: TextInputAction.continueAction, 499 | keyboardType: TextInputType.text, 500 | validator: (v) { 501 | if (v == null || v.trim().isEmpty) 502 | return "Address is required"; 503 | 504 | else return null; 505 | }, 506 | onSaved: (v) { 507 | setState(() { 508 | billingaddress = v; 509 | }); 510 | }, 511 | decoration: InputDecoration( 512 | hintText: "Address", 513 | ), 514 | ), 515 | SizedBox( 516 | height: 15, 517 | ), 518 | FutureBuilder>>( 519 | future: countries, 520 | builder: (context, snapshot) { 521 | return DropdownButton>( 522 | items: !snapshot.hasData 523 | ? [] 524 | : snapshot.data 525 | .map( 526 | (i) => DropdownMenuItem>( 527 | value: i, 528 | child: Text( 529 | i["name"], 530 | ), 531 | ), 532 | ) 533 | .toList(), 534 | hint: Text("Select Country"), 535 | value: selectedCountry, 536 | onChanged: (item) { 537 | setState(() { 538 | selectedCountry = item; 539 | billingcountry = item["code2"]; 540 | }); 541 | }, 542 | ); 543 | }), 544 | SizedBox( 545 | height: 15, 546 | ), 547 | DropdownButton>( 548 | items: selectedCountry == null 549 | ? [] 550 | : (selectedCountry["states"] as List) 551 | .map((i) => (i as Map)) 552 | .map((i) => DropdownMenuItem>( 553 | value: i, 554 | child: Text( 555 | i["name"], 556 | ), 557 | )) 558 | .toList(), 559 | hint: Text("Select State"), 560 | value: selectedState, 561 | onChanged: (item) { 562 | setState(() { 563 | selectedState = item; 564 | billingstate = item["code"]; 565 | }); 566 | }, 567 | ), 568 | SizedBox( 569 | height: 15, 570 | ), 571 | TextFormField( 572 | textInputAction: TextInputAction.continueAction, 573 | keyboardType: TextInputType.text, 574 | validator: (v) { 575 | if (v == null || v.trim().isEmpty) 576 | return "Name is required"; 577 | 578 | else return null; 579 | }, 580 | onSaved: (v) { 581 | setState(() { 582 | billingcity = v; 583 | }); 584 | }, 585 | decoration: InputDecoration( 586 | hintText: "Your City Code", 587 | helperText: "Example: LA", 588 | ), 589 | ), 590 | SizedBox( 591 | height: 15, 592 | ), 593 | TextFormField( 594 | textInputAction: TextInputAction.continueAction, 595 | keyboardType: TextInputType.text, 596 | validator: (v) { 597 | if (v == null || v.trim().isEmpty) 598 | return "Zip Code is required"; 599 | else return null; 600 | }, 601 | onSaved: (v) { 602 | setState(() { 603 | billingzip = v; 604 | }); 605 | }, 606 | decoration: InputDecoration( 607 | hintText: "Zip Code", 608 | ), 609 | ), 610 | SizedBox( 611 | height: 15, 612 | ), 613 | FlatButton( 614 | color: Theme.of(context).accentColor, 615 | onPressed: () { 616 | _globalKey.currentState.save(); 617 | if (_globalKey.currentState.validate()) { 618 | Navigator.of(context).pop({ 619 | "billingaddress": billingaddress, 620 | "billingcountry": billingcountry, 621 | "billingzip": billingzip, 622 | "billingstate": billingstate, 623 | "billingcity": billingcity, 624 | }); 625 | } 626 | }, 627 | child: Text( 628 | "Continue", 629 | style: TextStyle( 630 | color: Colors.white, 631 | ), 632 | ), 633 | ), 634 | ], 635 | ), 636 | ), 637 | ), 638 | )), 639 | ); 640 | } 641 | } 642 | 643 | class ValueCollectorComponent extends StatefulWidget { 644 | final String title; 645 | final String message; 646 | final Function(String) onValueCollected; 647 | 648 | const ValueCollectorComponent({ 649 | Key key, 650 | this.title, 651 | this.message, 652 | this.onValueCollected, 653 | }) : super(key: key); 654 | 655 | @override 656 | _ValueCollectorComponentState createState() => 657 | _ValueCollectorComponentState(); 658 | } 659 | 660 | class _ValueCollectorComponentState extends State { 661 | String value; 662 | 663 | @override 664 | Widget build(BuildContext context) { 665 | return AlertDialog( 666 | title: Text( 667 | widget.title, 668 | style: Theme.of(context) 669 | .textTheme 670 | .headline6 671 | .copyWith(color: Theme.of(context).primaryColor), 672 | ), 673 | content: Column( 674 | mainAxisSize: MainAxisSize.min, 675 | crossAxisAlignment: CrossAxisAlignment.stretch, 676 | children: [ 677 | Padding( 678 | padding: const EdgeInsets.only(bottom: 10.0), 679 | child: Text( 680 | widget.message, 681 | style: Theme.of(context).textTheme.bodyText1, 682 | ), 683 | ), 684 | TextField( 685 | keyboardType: TextInputType.numberWithOptions(), 686 | inputFormatters: [ 687 | WhitelistingTextInputFormatter.digitsOnly, 688 | ], 689 | onChanged: (v) { 690 | setState(() { 691 | value = v?.trim(); 692 | }); 693 | }, 694 | decoration: InputDecoration( 695 | hintText: "Enter ${widget.title}", 696 | ), 697 | ), 698 | SizedBox( 699 | height: 30, 700 | ), 701 | SizedBox( 702 | width: double.infinity, 703 | child: RaisedButton( 704 | onPressed: () { 705 | if (value != null && value.isNotEmpty) { 706 | if (widget.onValueCollected != null) { 707 | widget.onValueCollected(value); 708 | } 709 | } 710 | }, 711 | child: Text( 712 | "Submit", 713 | style: TextStyle( 714 | color: Colors.white, 715 | ), 716 | ), 717 | ), 718 | ), 719 | ], 720 | ), 721 | ); 722 | } 723 | } 724 | -------------------------------------------------------------------------------- /lib/src/api/error_codes.dart: -------------------------------------------------------------------------------- 1 | class ErrorCodes { 2 | static final requiresOtp = "otp_required"; 3 | static final bankListFetch = "bank_list_failure"; 4 | static final bankAccountNameResolution = "account_name_resolution"; 5 | } 6 | -------------------------------------------------------------------------------- /lib/src/api/exceptions/auth_failed.dart: -------------------------------------------------------------------------------- 1 | import 'package:equatable/equatable.dart'; 2 | 3 | class AuthFailedException extends Equatable { 4 | final String message = "Authentication Failed"; 5 | 6 | @override 7 | List get props => [message]; 8 | } 9 | 10 | class RegistrationFailedException extends Equatable { 11 | final String message = "User Registration Failed"; 12 | 13 | @override 14 | List get props => [message]; 15 | } 16 | -------------------------------------------------------------------------------- /lib/src/api/exceptions/general.dart: -------------------------------------------------------------------------------- 1 | import 'package:equatable/equatable.dart'; 2 | 3 | class ApiCallFailedException extends Equatable { 4 | final String message; 5 | 6 | ApiCallFailedException({this.message = "Api call failed"}); 7 | 8 | @override 9 | List get props => [message]; 10 | } 11 | -------------------------------------------------------------------------------- /lib/src/api/services/http_service.dart: -------------------------------------------------------------------------------- 1 | import 'package:dio/dio.dart'; 2 | import 'package:dio_flutter_transformer/dio_flutter_transformer.dart'; 3 | import 'package:equatable/equatable.dart'; 4 | import 'package:flutter_rave/src/config/api.dart'; 5 | 6 | class HttpService extends Equatable { 7 | static HttpService get instance => HttpService._(ApiConfig.instance); 8 | 9 | final ApiConfig config; 10 | 11 | Dio _dio; 12 | 13 | Dio get dio => _dio; 14 | 15 | HttpService._(this.config) : super() { 16 | _dio = Dio( 17 | BaseOptions( 18 | baseUrl: config.baseUrl, 19 | connectTimeout: 30000, 20 | receiveTimeout: 30000, 21 | responseType: ResponseType.json, 22 | headers: {"Accept": "application/json"}, 23 | ), 24 | ); 25 | 26 | _dio.transformer = FlutterTransformer(); 27 | 28 | _dio.interceptors.add( 29 | InterceptorsWrapper( 30 | onRequest: (RequestOptions options) { 31 | return options; 32 | }, 33 | onResponse: (Response response) { 34 | return response; 35 | }, 36 | ), 37 | ); 38 | } 39 | 40 | factory HttpService(ApiConfig apiConfig) { 41 | return HttpService._(apiConfig); 42 | } 43 | 44 | setCurrentUser(String authToken) { 45 | if (authToken == null || authToken.length <= 0) { 46 | throw "Auth Token cannot be empty"; 47 | } 48 | _dio.options.headers["Authorization"] = "Bearer $authToken"; 49 | return this; 50 | } 51 | 52 | removeCurrentUser() { 53 | final headers = _dio.options.headers; 54 | headers.remove("Authorization"); 55 | _dio.options.headers = headers; 56 | return this; 57 | } 58 | 59 | List get props => [config]; 60 | } 61 | -------------------------------------------------------------------------------- /lib/src/api/services/rave_api_service.dart: -------------------------------------------------------------------------------- 1 | import "dart:convert"; 2 | 3 | import "package:dio/dio.dart"; 4 | import "package:dio_flutter_transformer/dio_flutter_transformer.dart"; 5 | import "package:flutter_rave/flutter_rave.dart" show CreditCardInfo; 6 | import "package:tripledes/tripledes.dart"; 7 | 8 | class RaveApiService { 9 | static RaveApiService get instance => RaveApiService(); 10 | 11 | final _sandboxProductionUrl = "https://ravesandboxapi.flutterwave.com"; 12 | final _liveProductionUrl = "https://api.ravepay.co"; 13 | 14 | final _validationEndpoint = "/flwv3-pug/getpaidx/api/validatecharge"; 15 | final _chargeEndpoint = "/flwv3-pug/getpaidx/api/charge"; 16 | 17 | Dio _dio; 18 | Dio _productionDio; 19 | 20 | RaveApiService() { 21 | _dio = Dio( 22 | BaseOptions( 23 | baseUrl: _sandboxProductionUrl, 24 | connectTimeout: 30000, 25 | receiveTimeout: 30000, 26 | responseType: ResponseType.json, 27 | headers: { 28 | "Accept": "application/json", 29 | }, 30 | ), 31 | ); 32 | 33 | _productionDio = Dio( 34 | BaseOptions( 35 | baseUrl: _liveProductionUrl, 36 | connectTimeout: 30000, 37 | receiveTimeout: 30000, 38 | responseType: ResponseType.json, 39 | headers: { 40 | "Accept": "application/json", 41 | }, 42 | ), 43 | ); 44 | 45 | _dio.transformer = FlutterTransformer(); 46 | _productionDio.transformer = FlutterTransformer(); 47 | 48 | _dio.interceptors.add( 49 | InterceptorsWrapper( 50 | onRequest: (RequestOptions options) { 51 | print(options.uri.toString()); 52 | print(options.data.toString()); 53 | return options; 54 | }, 55 | onResponse: (Response response) { 56 | print(response.headers.toString()); 57 | print(response.data.toString()); 58 | return response; 59 | }, 60 | onError: (DioError e) { 61 | print(e.type.toString()); 62 | print(e.response.headers.toString()); 63 | print(e.response.data.toString()); 64 | return e; //continue 65 | }, 66 | ), 67 | ); 68 | 69 | _productionDio.interceptors.add( 70 | InterceptorsWrapper( 71 | onRequest: (RequestOptions options) { 72 | print(options.uri.toString()); 73 | print(options.data.toString()); 74 | return options; 75 | }, 76 | onResponse: (Response response) { 77 | print(response.headers.toString()); 78 | print(response.data.toString()); 79 | return response; 80 | }, 81 | onError: (DioError e) { 82 | print(e.type.toString()); 83 | print(e.response.headers.toString()); 84 | print(e.response.data.toString()); 85 | return e; //continue 86 | }, 87 | ), 88 | ); 89 | } 90 | 91 | Future> startChargeCard( 92 | CreditCardInfo card, 93 | String ravePublicKey, 94 | String raveEncryptionKey, { 95 | bool isProduction = true, 96 | String email, 97 | String firstName, 98 | String lastName, 99 | String phoneNumber, 100 | String transactionReference, 101 | double amount, 102 | String suggestedAuth = "pin", 103 | String suggestedAuthValue, 104 | Map billingAddressInfo, 105 | List> subaccounts, 106 | String redirectUrl = "http://localhost:8184", 107 | }) async { 108 | final payload = { 109 | "PBFPubKey": ravePublicKey, 110 | "cardno": card.cardNumber, 111 | "currency": "NGN", 112 | "country": "NG", 113 | "cvv": card.cvv, 114 | "amount": amount, 115 | "expiryyear": card.expirationYear, 116 | "expirymonth": card.expirationMonth, 117 | "suggested_auth": suggestedAuth, 118 | "email": email, 119 | "firstname": firstName, 120 | "lastname": lastName, 121 | "phonenumber": phoneNumber, 122 | "redirect_url": redirectUrl, 123 | "txRef": transactionReference, 124 | }; 125 | 126 | print(payload); 127 | print("isProduction $isProduction"); 128 | 129 | if (suggestedAuthValue != null) { 130 | payload[suggestedAuth.toLowerCase()] = suggestedAuthValue; 131 | } 132 | if (subaccounts != null) { 133 | payload["subaccounts"] = subaccounts; 134 | } 135 | 136 | if (billingAddressInfo != null) { 137 | billingAddressInfo.forEach((key, value) { 138 | payload[key] = value; 139 | }); 140 | } 141 | 142 | return await _chargeCard( 143 | ravePublicKey, 144 | raveEncryptionKey, 145 | payload, 146 | isProduction, 147 | ); 148 | } 149 | 150 | _chargeCard(String ravePublicKey, String raveEncryptionKey, 151 | Map chargeDataGlobal, 152 | [bool isProduction = true]) async { 153 | final encoded = json.encode(chargeDataGlobal); 154 | final encryped = encrypt(raveEncryptionKey, encoded); 155 | final newData = { 156 | "PBFPubKey": ravePublicKey, 157 | "client": encryped, 158 | "alg": "3DES-24" 159 | }; 160 | 161 | var response; 162 | 163 | if (isProduction) { 164 | response = await _productionDio.post( 165 | _chargeEndpoint, 166 | data: newData, 167 | ); 168 | } else { 169 | response = await _dio.post( 170 | _chargeEndpoint, 171 | data: newData, 172 | ); 173 | } 174 | 175 | return response.data; 176 | } 177 | 178 | encrypt(key, text) { 179 | var blockCipher = BlockCipher(TripleDESEngine(), key); 180 | var i = blockCipher.encodeB64(text); 181 | return i; 182 | } 183 | 184 | validateTransaction(String txRef, String otp, String publicKey, 185 | [bool isProduction = true]) async { 186 | final newData = { 187 | "PBFPubKey": publicKey, 188 | "transaction_reference": txRef, 189 | "otp": otp, 190 | }; 191 | 192 | final dio = isProduction ? _productionDio : _dio; 193 | 194 | final response = await dio.post( 195 | _validationEndpoint, 196 | data: newData, 197 | ); 198 | 199 | return response.data; 200 | } 201 | 202 | fetchTransactionDetails(txRef, String publicKey) async { 203 | final newData = { 204 | "PBFPubKey": publicKey, 205 | "transaction_reference": txRef, 206 | }; 207 | final response = await _dio.post( 208 | _validationEndpoint, 209 | data: newData, 210 | ); 211 | 212 | return response.data; 213 | } 214 | } 215 | -------------------------------------------------------------------------------- /lib/src/config/api.dart: -------------------------------------------------------------------------------- 1 | import 'package:equatable/equatable.dart'; 2 | 3 | class ApiConfig extends Equatable { 4 | static ApiConfig get instance => ApiConfig._(); 5 | 6 | final String baseUrl; 7 | final String raveEndpoint; 8 | final String ravePublicKey; 9 | final String paystackEndPoint; 10 | final String paystackPublicKey; 11 | final String defaultCardProvider; 12 | 13 | String raveEncryptionKey; 14 | 15 | ApiConfig._({ 16 | this.baseUrl, 17 | this.paystackEndPoint, 18 | this.raveEndpoint, 19 | this.paystackPublicKey, 20 | this.ravePublicKey, 21 | this.raveEncryptionKey, 22 | this.defaultCardProvider, 23 | }) : super(); 24 | 25 | factory ApiConfig( 26 | String baseUrl, { 27 | String raveEndpoint, 28 | String ravePublicKey, 29 | String raveEncryptionKey, 30 | String paystackEndPoint, 31 | String paystackPublicKey, 32 | String defaultProvider, 33 | bool force: false, 34 | }) { 35 | return ApiConfig._( 36 | baseUrl: baseUrl, 37 | raveEndpoint: raveEndpoint, 38 | ravePublicKey: ravePublicKey, 39 | raveEncryptionKey: raveEncryptionKey, 40 | paystackEndPoint: paystackEndPoint, 41 | paystackPublicKey: paystackPublicKey, 42 | defaultCardProvider: defaultProvider, 43 | ); 44 | } 45 | 46 | factory ApiConfig.make( 47 | String baseUrl, { 48 | String raveEndpoint, 49 | String ravePublicKey, 50 | String raveEncryptionKey, 51 | String paystackEndPoint, 52 | String paystackPublicKey, 53 | String defaultProvider, 54 | }) { 55 | return ApiConfig( 56 | baseUrl, 57 | raveEndpoint: raveEndpoint, 58 | ravePublicKey: ravePublicKey, 59 | raveEncryptionKey: raveEncryptionKey, 60 | paystackEndPoint: paystackEndPoint, 61 | paystackPublicKey: paystackPublicKey, 62 | defaultProvider: defaultProvider, 63 | ); 64 | } 65 | 66 | @override 67 | List get props => [ 68 | baseUrl, 69 | paystackPublicKey, 70 | ravePublicKey, 71 | raveEndpoint, 72 | raveEncryptionKey, 73 | defaultCardProvider, 74 | paystackEndPoint, 75 | ]; 76 | } 77 | -------------------------------------------------------------------------------- /lib/src/config/constants.dart: -------------------------------------------------------------------------------- 1 | const minPasswordLength = 4; 2 | 3 | const nairaSymbol = "₦"; 4 | const dollarSymbol = "\$"; 5 | const cardTokenizationCharge = 100; 6 | -------------------------------------------------------------------------------- /lib/src/ui/components/overlay_loader_widget.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | class OverlayLoaderWidget extends StatelessWidget { 4 | @override 5 | Widget build(BuildContext context) { 6 | return AbsorbPointer( 7 | child: Container( 8 | child: Center( 9 | child: SizedBox( 10 | width: 80, 11 | height: 80, 12 | child: Container( 13 | decoration: BoxDecoration( 14 | color: Colors.black87, 15 | borderRadius: BorderRadius.circular(8.0), 16 | ), 17 | child: Center( 18 | child: SizedBox( 19 | width: 25, 20 | height: 25, 21 | child: CircularProgressIndicator( 22 | strokeWidth: 2.0, 23 | valueColor: AlwaysStoppedAnimation( 24 | Colors.white, 25 | ), 26 | ), 27 | ), 28 | ), 29 | ), 30 | ), 31 | ), 32 | ), 33 | ); 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /lib/src/utils/assets.dart: -------------------------------------------------------------------------------- 1 | class Assets { 2 | static String logo = "assets/images/payments/logo.png"; 3 | static final String mastercard = "assets/images/payments/mastercard.svg"; 4 | static final String visa = "assets/images/payments/visa.svg"; 5 | static final String verve = "assets/images/payments/verve.png"; 6 | static final String jsonCountries = 7 | "packages/flutter_rave/assets/json/countries.json"; 8 | } 9 | -------------------------------------------------------------------------------- /lib/src/utils/credit_card.dart: -------------------------------------------------------------------------------- 1 | final Map _industryIdentifierMap = { 2 | "1": Industries.AIRLINES, 3 | "2": Industries.AIRLINES, 4 | "3": Industries.TRAVEL_AND_ENTERTAINMENT, 5 | "4": Industries.BANKING_AND_FINANCIAL, 6 | "5": Industries.BANKING_AND_FINANCIAL, 7 | "6": Industries.MERCHANDIZING_AND_BANKING, 8 | "7": Industries.PETROLEUM, 9 | "8": Industries.TELECOMMUNICATIONS, 10 | "9": Industries.NATIONAL_ASSIGNMENT 11 | }; 12 | 13 | final List _issuerIdentifierList = [ 14 | {"RegExp": new RegExp(r'^4'), "Issuers": Issuers.VISA}, 15 | {"RegExp": new RegExp(r'^5[1-5]'), "Issuers": Issuers.MASTERCARD}, 16 | {"RegExp": new RegExp(r'^50'), "Issuers": Issuers.VERVE}, 17 | {"RegExp": new RegExp(r'^6(0|4|5)(1|4)?(1)?'), "Issuers": Issuers.DISCOVER}, 18 | {"RegExp": new RegExp(r'^3(4|7)'), "Issuers": Issuers.AMEX} 19 | ]; 20 | 21 | class CreditCardUtils { 22 | String cardNumber; 23 | Issuers cardIssuer; 24 | Industries cardIndustry; 25 | bool valid; 26 | 27 | CreditCardUtils(String number) { 28 | this.cardNumber = number.replaceAll(new RegExp(r"-|\s"), ""); 29 | this._load(); 30 | } 31 | 32 | CreditCardUtils.clean(String number, RegExp patten) { 33 | this.cardNumber = number.replaceAll(patten, ""); 34 | this._load(); 35 | } 36 | 37 | bool _check(String number) { 38 | var reg = new RegExp(r'^\d*$'); 39 | return reg.hasMatch(number) && number.isNotEmpty; 40 | } 41 | 42 | _load() { 43 | if (_check(this.cardNumber)) { 44 | this.valid = this._validate(this.cardNumber); 45 | this.cardIndustry = this._industry(this.cardNumber); 46 | this.cardIssuer = this._issuer(this.cardNumber); 47 | } else { 48 | throw new FormatException("Unclean Input: ${this.cardNumber}"); 49 | } 50 | } 51 | 52 | int _calculate(luhn) { 53 | var sum = luhn 54 | .split("") 55 | .map((e) => int.parse(e, radix: 10)) 56 | .reduce((a, b) => a + b); 57 | 58 | var delta = [0, 1, 2, 3, 4, -4, -3, -2, -1, 0]; 59 | for (var i = luhn.length - 1; i >= 0; i -= 2) { 60 | sum += delta[int.parse(luhn.substring(i, i + 1), radix: 10)]; 61 | } 62 | 63 | var mod10 = 10 - (sum % 10); 64 | return mod10 == 10 ? 0 : mod10; 65 | } 66 | 67 | bool _validate(luhn) { 68 | var luhnDigit = 69 | int.parse(luhn.substring(luhn.length - 1, luhn.length), radix: 10); 70 | var luhnLess = luhn.substring(0, luhn.length - 1); 71 | return (this._calculate(luhnLess) == luhnDigit); 72 | } 73 | 74 | Industries _industry(String number) { 75 | return _industryIdentifierMap[number.substring(0, 1)]; 76 | } 77 | 78 | Issuers _issuer(String number) { 79 | Issuers issuer = Issuers.UNKNOWN; 80 | var issuerID = number.substring(0, 6); 81 | _issuerIdentifierList.forEach((item) { 82 | if (item["RegExp"].hasMatch(issuerID)) { 83 | issuer = item["Issuers"]; 84 | } 85 | }); 86 | return issuer; 87 | } 88 | 89 | toJson() => { 90 | "number": this.cardNumber, 91 | "industry": this.cardIndustry, 92 | "issuer": this.cardIssuer, 93 | "valid": this.valid 94 | }; 95 | 96 | toString() => 97 | "number: ${this.cardNumber}, industry: ${this.cardIndustry}, issuer: ${this.cardIssuer}, valid: ${this.valid}"; 98 | } 99 | 100 | class Industries { 101 | final _value; 102 | const Industries._internal(this._value); 103 | toString() => '$_value'; 104 | toJson() => '$_value'; 105 | 106 | static const AIRLINES = const Industries._internal('Airlines'); 107 | static const TRAVEL_AND_ENTERTAINMENT = 108 | const Industries._internal('Travel and Entertainment'); 109 | static const BANKING_AND_FINANCIAL = 110 | const Industries._internal('Banking and Financial'); 111 | static const MERCHANDIZING_AND_BANKING = 112 | const Industries._internal('Merchandizing and Banking'); 113 | static const PETROLEUM = const Industries._internal('Petroleum'); 114 | static const TELECOMMUNICATIONS = 115 | const Industries._internal('Telecommunications'); 116 | static const NATIONAL_ASSIGNMENT = 117 | const Industries._internal('National Assignment'); 118 | } 119 | 120 | class Issuers { 121 | final _value; 122 | const Issuers._internal(this._value); 123 | toString() => '$_value'; 124 | toJson() => '$_value'; 125 | 126 | static const VISA = const Issuers._internal('Visa'); 127 | static const MASTERCARD = const Issuers._internal('Mastercard'); 128 | static const DISCOVER = const Issuers._internal('Discover'); 129 | static const AMEX = const Issuers._internal('Amex'); 130 | static const VERVE = const Issuers._internal('Verve'); 131 | static const UNKNOWN = const Issuers._internal('Unknown'); 132 | } 133 | -------------------------------------------------------------------------------- /lib/src/utils/masked_input_formatter.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/services.dart'; 2 | 3 | class MaskTextInputFormatter extends TextInputFormatter { 4 | Map _maskMap; 5 | List _maskList; 6 | 7 | MaskTextInputFormatter(maskString, {escapeChar: "_"}) { 8 | assert(maskString != null); 9 | final entries = RegExp('[^$escapeChar]+') 10 | .allMatches(maskString) 11 | .map((match) => MapEntry(match.start, match.group(0))); 12 | 13 | _maskMap = new Map.fromEntries(entries); 14 | _maskList = _maskMap.keys.toList(); 15 | } 16 | 17 | String getEscapedString(String inputText) { 18 | _maskList.reversed 19 | .where((index) => 20 | index < inputText.length && _substringIsMask(inputText, index)) 21 | .forEach((index) { 22 | inputText = inputText.substring(0, index) + 23 | inputText.substring(index + _maskMap[index].length); 24 | }); 25 | return inputText; 26 | } 27 | 28 | bool _substringIsMask(String inputText, int index) { 29 | try { 30 | return inputText.substring(index, index + _maskMap[index].length) == 31 | _maskMap[index]; 32 | } on RangeError { 33 | return false; 34 | } 35 | } 36 | 37 | @override 38 | TextEditingValue formatEditUpdate( 39 | TextEditingValue oldValue, TextEditingValue newValue) { 40 | var escapedString = getEscapedString(newValue.text); 41 | var position = newValue.selection.baseOffset - 42 | (newValue.text.length - escapedString.length); 43 | 44 | _maskList.forEach((index) { 45 | if (escapedString.length > index) { 46 | escapedString = escapedString.substring(0, index) + 47 | _maskMap[index] + 48 | escapedString.substring(index); 49 | position += _maskMap[index].length; 50 | } 51 | }); 52 | 53 | return newValue.copyWith( 54 | text: escapedString, 55 | selection: TextSelection.collapsed(offset: position)); 56 | } 57 | } 58 | 59 | class CreditCardTextInputFormatter extends TextInputFormatter { 60 | String formattedString = ""; 61 | String rawString = ""; 62 | CreditCardTextInputFormatter(); 63 | 64 | String getRawString() { 65 | rawString = formattedString.replaceAll(" ", "").trim(); 66 | return rawString; 67 | } 68 | 69 | @override 70 | TextEditingValue formatEditUpdate( 71 | TextEditingValue oldValue, TextEditingValue newValue) { 72 | formattedString = newValue.text; 73 | var escapedString = getEscapedString(newValue.text); 74 | var position = newValue.selection.baseOffset - 75 | (newValue.text.length - escapedString.length); 76 | 77 | return newValue.copyWith( 78 | text: escapedString, 79 | selection: TextSelection.collapsed(offset: position)); 80 | } 81 | 82 | getEscapedString(String text) { 83 | List chunks = text.split(""); 84 | List padded = []; 85 | 86 | int group = 0; 87 | String cache = ""; 88 | 89 | chunks.forEach((i) { 90 | group += 1; 91 | cache += i; 92 | 93 | if (group == 4) { 94 | padded.add(cache); 95 | group = 0; 96 | cache = ""; 97 | } 98 | }); 99 | 100 | if (cache.length > 0) { 101 | padded.add(cache); 102 | cache = ""; 103 | group = 0; 104 | } 105 | return padded.join(" "); 106 | } 107 | } 108 | -------------------------------------------------------------------------------- /pubspec.lock: -------------------------------------------------------------------------------- 1 | # Generated by pub 2 | # See https://dart.dev/tools/pub/glossary#lockfile 3 | packages: 4 | async: 5 | dependency: transitive 6 | description: 7 | name: async 8 | url: "https://pub.dartlang.org" 9 | source: hosted 10 | version: "2.4.1" 11 | boolean_selector: 12 | dependency: transitive 13 | description: 14 | name: boolean_selector 15 | url: "https://pub.dartlang.org" 16 | source: hosted 17 | version: "2.0.0" 18 | charcode: 19 | dependency: transitive 20 | description: 21 | name: charcode 22 | url: "https://pub.dartlang.org" 23 | source: hosted 24 | version: "1.1.3" 25 | clock: 26 | dependency: transitive 27 | description: 28 | name: clock 29 | url: "https://pub.dartlang.org" 30 | source: hosted 31 | version: "1.0.1" 32 | collection: 33 | dependency: transitive 34 | description: 35 | name: collection 36 | url: "https://pub.dartlang.org" 37 | source: hosted 38 | version: "1.14.12" 39 | convert: 40 | dependency: transitive 41 | description: 42 | name: convert 43 | url: "https://pub.dartlang.org" 44 | source: hosted 45 | version: "2.1.1" 46 | crypto: 47 | dependency: "direct main" 48 | description: 49 | name: crypto 50 | url: "https://pub.dartlang.org" 51 | source: hosted 52 | version: "2.1.4" 53 | cupertino_icons: 54 | dependency: "direct main" 55 | description: 56 | name: cupertino_icons 57 | url: "https://pub.dartlang.org" 58 | source: hosted 59 | version: "0.1.3" 60 | dio: 61 | dependency: "direct main" 62 | description: 63 | name: dio 64 | url: "https://pub.dartlang.org" 65 | source: hosted 66 | version: "3.0.9" 67 | dio_flutter_transformer: 68 | dependency: "direct main" 69 | description: 70 | name: dio_flutter_transformer 71 | url: "https://pub.dartlang.org" 72 | source: hosted 73 | version: "3.0.2" 74 | equatable: 75 | dependency: "direct main" 76 | description: 77 | name: equatable 78 | url: "https://pub.dartlang.org" 79 | source: hosted 80 | version: "1.1.1" 81 | fake_async: 82 | dependency: transitive 83 | description: 84 | name: fake_async 85 | url: "https://pub.dartlang.org" 86 | source: hosted 87 | version: "1.1.0" 88 | flushbar: 89 | dependency: "direct main" 90 | description: 91 | name: flushbar 92 | url: "https://pub.dartlang.org" 93 | source: hosted 94 | version: "1.10.2" 95 | flutter: 96 | dependency: "direct main" 97 | description: flutter 98 | source: sdk 99 | version: "0.0.0" 100 | flutter_svg: 101 | dependency: "direct main" 102 | description: 103 | name: flutter_svg 104 | url: "https://pub.dartlang.org" 105 | source: hosted 106 | version: "0.17.4" 107 | flutter_test: 108 | dependency: "direct dev" 109 | description: flutter 110 | source: sdk 111 | version: "0.0.0" 112 | flutter_web_plugins: 113 | dependency: transitive 114 | description: flutter 115 | source: sdk 116 | version: "0.0.0" 117 | flutter_webview_plugin: 118 | dependency: "direct main" 119 | description: 120 | name: flutter_webview_plugin 121 | url: "https://pub.dartlang.org" 122 | source: hosted 123 | version: "0.3.11" 124 | http_parser: 125 | dependency: transitive 126 | description: 127 | name: http_parser 128 | url: "https://pub.dartlang.org" 129 | source: hosted 130 | version: "3.1.4" 131 | intl: 132 | dependency: "direct main" 133 | description: 134 | name: intl 135 | url: "https://pub.dartlang.org" 136 | source: hosted 137 | version: "0.16.1" 138 | js: 139 | dependency: transitive 140 | description: 141 | name: js 142 | url: "https://pub.dartlang.org" 143 | source: hosted 144 | version: "0.6.1+1" 145 | matcher: 146 | dependency: transitive 147 | description: 148 | name: matcher 149 | url: "https://pub.dartlang.org" 150 | source: hosted 151 | version: "0.12.6" 152 | meta: 153 | dependency: transitive 154 | description: 155 | name: meta 156 | url: "https://pub.dartlang.org" 157 | source: hosted 158 | version: "1.1.8" 159 | path: 160 | dependency: transitive 161 | description: 162 | name: path 163 | url: "https://pub.dartlang.org" 164 | source: hosted 165 | version: "1.7.0" 166 | path_drawing: 167 | dependency: transitive 168 | description: 169 | name: path_drawing 170 | url: "https://pub.dartlang.org" 171 | source: hosted 172 | version: "0.4.1" 173 | path_parsing: 174 | dependency: transitive 175 | description: 176 | name: path_parsing 177 | url: "https://pub.dartlang.org" 178 | source: hosted 179 | version: "0.1.4" 180 | petitparser: 181 | dependency: transitive 182 | description: 183 | name: petitparser 184 | url: "https://pub.dartlang.org" 185 | source: hosted 186 | version: "3.0.2" 187 | plugin_platform_interface: 188 | dependency: transitive 189 | description: 190 | name: plugin_platform_interface 191 | url: "https://pub.dartlang.org" 192 | source: hosted 193 | version: "1.0.2" 194 | sky_engine: 195 | dependency: transitive 196 | description: flutter 197 | source: sdk 198 | version: "0.0.99" 199 | source_span: 200 | dependency: transitive 201 | description: 202 | name: source_span 203 | url: "https://pub.dartlang.org" 204 | source: hosted 205 | version: "1.7.0" 206 | stack_trace: 207 | dependency: transitive 208 | description: 209 | name: stack_trace 210 | url: "https://pub.dartlang.org" 211 | source: hosted 212 | version: "1.9.3" 213 | stream_channel: 214 | dependency: transitive 215 | description: 216 | name: stream_channel 217 | url: "https://pub.dartlang.org" 218 | source: hosted 219 | version: "2.0.0" 220 | string_scanner: 221 | dependency: transitive 222 | description: 223 | name: string_scanner 224 | url: "https://pub.dartlang.org" 225 | source: hosted 226 | version: "1.0.5" 227 | term_glyph: 228 | dependency: transitive 229 | description: 230 | name: term_glyph 231 | url: "https://pub.dartlang.org" 232 | source: hosted 233 | version: "1.1.0" 234 | test_api: 235 | dependency: transitive 236 | description: 237 | name: test_api 238 | url: "https://pub.dartlang.org" 239 | source: hosted 240 | version: "0.2.15" 241 | tripledes: 242 | dependency: "direct main" 243 | description: 244 | name: tripledes 245 | url: "https://pub.dartlang.org" 246 | source: hosted 247 | version: "2.1.0" 248 | typed_data: 249 | dependency: transitive 250 | description: 251 | name: typed_data 252 | url: "https://pub.dartlang.org" 253 | source: hosted 254 | version: "1.1.6" 255 | url_launcher: 256 | dependency: "direct main" 257 | description: 258 | name: url_launcher 259 | url: "https://pub.dartlang.org" 260 | source: hosted 261 | version: "5.4.5" 262 | url_launcher_macos: 263 | dependency: transitive 264 | description: 265 | name: url_launcher_macos 266 | url: "https://pub.dartlang.org" 267 | source: hosted 268 | version: "0.0.1+5" 269 | url_launcher_platform_interface: 270 | dependency: transitive 271 | description: 272 | name: url_launcher_platform_interface 273 | url: "https://pub.dartlang.org" 274 | source: hosted 275 | version: "1.0.6" 276 | url_launcher_web: 277 | dependency: transitive 278 | description: 279 | name: url_launcher_web 280 | url: "https://pub.dartlang.org" 281 | source: hosted 282 | version: "0.1.1+4" 283 | vector_math: 284 | dependency: transitive 285 | description: 286 | name: vector_math 287 | url: "https://pub.dartlang.org" 288 | source: hosted 289 | version: "2.0.8" 290 | webview_flutter: 291 | dependency: "direct main" 292 | description: 293 | name: webview_flutter 294 | url: "https://pub.dartlang.org" 295 | source: hosted 296 | version: "0.3.21" 297 | xml: 298 | dependency: transitive 299 | description: 300 | name: xml 301 | url: "https://pub.dartlang.org" 302 | source: hosted 303 | version: "3.7.0" 304 | sdks: 305 | dart: ">=2.7.2 <3.0.0" 306 | flutter: ">=1.12.13+hotfix.5 <2.0.0" 307 | -------------------------------------------------------------------------------- /pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: flutter_rave 2 | description: Flutterwave's Rave Card Processing Plugin. Completely supports Android and iOS. 3 | version: 1.0.0 4 | author: Ogbonda Chiziaruhoma 5 | homepage: https://github.com/zfinix/flutter_rave 6 | 7 | environment: 8 | sdk: ">=2.5.2 <3.0.0" 9 | 10 | dependencies: 11 | cupertino_icons: ^0.1.2 12 | flutter_svg: 0.18.0 13 | dio: 3.0.9 14 | dio_flutter_transformer: 3.0.2 15 | equatable: ^1.1.1 16 | flushbar: ^1.3.0 17 | intl: any 18 | crypto: ^2.0.6 19 | tripledes: ^2.1.0 20 | flutter_webview_plugin: ^0.3.5 21 | url_launcher: ^5.0.2 22 | webview_flutter: ^0.3.9 23 | flutter: 24 | sdk: flutter 25 | 26 | dev_dependencies: 27 | flutter_test: 28 | sdk: flutter 29 | 30 | # For information on the generic Dart part of this file, see the 31 | # following page: https://www.dartlang.org/tools/pub/pubspec 32 | 33 | # The following section is specific to Flutter. 34 | flutter: 35 | assets: 36 | - assets/images/payments/ 37 | - assets/json/ 38 | 39 | # To add assets to your package, add an assets section, like this: 40 | # assets: 41 | # - images/a_dot_burr.jpeg 42 | # - images/a_dot_ham.jpeg 43 | # 44 | # For details regarding assets in packages, see 45 | # https://flutter.dev/assets-and-images/#from-packages 46 | # 47 | # An image asset can refer to one or more resolution-specific "variants", see 48 | # https://flutter.dev/assets-and-images/#resolution-aware. 49 | 50 | # To add custom fonts to your package, add a fonts section here, 51 | # in this "flutter" section. Each entry in this list should have a 52 | # "family" key with the font family name, and a "fonts" key with a 53 | # list giving the asset and other descriptors for the font. For 54 | # example: 55 | # fonts: 56 | # - family: Schyler 57 | # fonts: 58 | # - asset: fonts/Schyler-Regular.ttf 59 | # - asset: fonts/Schyler-Italic.ttf 60 | # style: italic 61 | # - family: Trajan Pro 62 | # fonts: 63 | # - asset: fonts/TrajanPro.ttf 64 | # - asset: fonts/TrajanPro_Bold.ttf 65 | # weight: 700 66 | # 67 | # For details regarding fonts in packages, see 68 | # https://flutter.dev/custom-fonts/#from-packages 69 | -------------------------------------------------------------------------------- /test/flutter_rave_test.dart: -------------------------------------------------------------------------------- 1 | // 2 | //import 'package:flutter_rave/flutter_rave.dart'; 3 | 4 | void main() { 5 | // test('adds one to input values', () { 6 | // }); 7 | } 8 | --------------------------------------------------------------------------------