├── .eslintrc
├── .gitignore
├── .npmignore
├── .travis.yml
├── LICENSE.md
├── README.md
├── RNFormsExample
├── .babelrc
├── .buckconfig
├── .flowconfig
├── .gitattributes
├── .gitignore
├── .watchmanconfig
├── CustomInput.js
├── ExampleForm.js
├── __tests__
│ ├── index.android.js
│ └── index.ios.js
├── android
│ ├── app
│ │ ├── BUCK
│ │ ├── build.gradle
│ │ ├── proguard-rules.pro
│ │ └── src
│ │ │ └── main
│ │ │ ├── AndroidManifest.xml
│ │ │ ├── assets
│ │ │ └── fonts
│ │ │ │ ├── Entypo.ttf
│ │ │ │ ├── EvilIcons.ttf
│ │ │ │ ├── FontAwesome.ttf
│ │ │ │ ├── Foundation.ttf
│ │ │ │ ├── Ionicons.ttf
│ │ │ │ ├── MaterialCommunityIcons.ttf
│ │ │ │ ├── MaterialIcons.ttf
│ │ │ │ ├── Octicons.ttf
│ │ │ │ ├── SimpleLineIcons.ttf
│ │ │ │ └── Zocial.ttf
│ │ │ ├── java
│ │ │ └── com
│ │ │ │ └── rnformsexample
│ │ │ │ ├── MainActivity.java
│ │ │ │ └── MainApplication.java
│ │ │ └── res
│ │ │ ├── mipmap-hdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-mdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-xhdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-xxhdpi
│ │ │ └── ic_launcher.png
│ │ │ └── values
│ │ │ ├── strings.xml
│ │ │ └── styles.xml
│ ├── build.gradle
│ ├── gradle.properties
│ ├── gradle
│ │ └── wrapper
│ │ │ ├── gradle-wrapper.jar
│ │ │ └── gradle-wrapper.properties
│ ├── gradlew
│ ├── gradlew.bat
│ ├── keystores
│ │ ├── BUCK
│ │ └── debug.keystore.properties
│ └── settings.gradle
├── index.android.js
├── index.ios.js
├── ios
│ ├── RNFormsExample.xcodeproj
│ │ ├── project.pbxproj
│ │ └── xcshareddata
│ │ │ └── xcschemes
│ │ │ └── RNFormsExample.xcscheme
│ ├── RNFormsExample
│ │ ├── AppDelegate.h
│ │ ├── AppDelegate.m
│ │ ├── Base.lproj
│ │ │ └── LaunchScreen.xib
│ │ ├── Images.xcassets
│ │ │ └── AppIcon.appiconset
│ │ │ │ └── Contents.json
│ │ ├── Info.plist
│ │ └── main.m
│ └── RNFormsExampleTests
│ │ ├── Info.plist
│ │ └── RNFormsExampleTests.m
├── package.json
└── yarn.lock
├── img
├── AndroidScreenshot.png
└── ExampleScreenshot.png
├── index.js
├── lib
├── ActionSheetCell.js
├── ButtonCell.js
├── DatePickerCell.js
├── DefaultStyles.js
├── Form.js
├── Line.js
├── PushButtonCell.js
├── Section.js
├── SwitchCell.js
├── TextInputCell.js
├── index.js
└── validators.js
└── package.json
/.eslintrc:
--------------------------------------------------------------------------------
1 | {
2 | 'parser': 'babel-eslint',
3 | 'extends': 'airbnb',
4 | 'plugins': [
5 | 'react'
6 | ],
7 | 'rules': {
8 | 'import/no-unresolved': [2, { ignore: ['react', 'react-native', '\.ios||android.js$'] }],
9 | 'react/jsx-boolean-value': [2, 'always'],
10 | 'react/jsx-no-bind': 0,
11 | 'react/prop-types': [2, { ignore: ['children'] }],
12 | 'arrow-body-style': ['error', 'as-needed'],
13 | 'no-unused-expressions': [2, { 'allowShortCircuit': true }]
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules/*
2 | .DS_STORE
3 | .npm-debug.log
4 |
--------------------------------------------------------------------------------
/.npmignore:
--------------------------------------------------------------------------------
1 | RNFormsExample/*
2 | img/*
3 |
--------------------------------------------------------------------------------
/.travis.yml:
--------------------------------------------------------------------------------
1 | language: node_js
2 | node_js:
3 | - 'node'
4 | install:
5 | - npm install
6 | script:
7 | - npm run lint
8 |
--------------------------------------------------------------------------------
/LICENSE.md:
--------------------------------------------------------------------------------
1 | The MIT License (MIT)
2 |
3 | Copyright (c) 2016 Michael Helvey
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the 'Software'), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
6 |
7 | The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
8 |
9 | THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
10 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # React Native Forms #
2 | [](https://badge.fury.io/js/react-native-forms)
3 | [](https://travis-ci.org/michaelhelvey/react-native-forms)
4 |
5 | ### Project status
6 |
7 | I wrote this library several (many?) years ago for a use-case at work, when React Native was still quite young, comparatively. I open sourced it in the general spirit of sharing code that had been useful to me, but with the vicissitudes of life being what they are, I didn't have the opportunity to keep it up to date, and it's become very antiquated. If you want to use it, go for it! But because I no longer use React Native at work, I don't have time to update this or add features, though I will take PRs and potentially give an active contributor maintenance rights over the repo, if they find it useful to work on. For similiar UI functionality within a much larger and better-maintained project, at the time of writing I'd recommend checking out [React Native Elements](https://react-native-training.github.io/react-native-elements/). There are plenty of other better alternatives as well, and more coming around every day. Thanks for stopping by!
8 |
9 | ---
10 |
11 | React Native Forms is a cross-platform library for creating native-looking forms using [React Native](https://github.com/facebook/react-native).
12 |
13 | Some benefits of React Native Forms:
14 |
15 | - Works for iOS and Android out of the box.
16 | - Easily extensible, allowing for the creation of custom appearances and behaviors.
17 | - Exposes functions for handling form data outside of the form components, for easy use in [Flux](https://github.com/facebook/flux) /[Redux](https://github.com/reactjs/redux) applications.
18 | - Customizable form validation API. Inject `validator` functions as props to all your form components, and get errors by simply calling `getValidationErrors` on your form to get a serialized copy of all your validation errors.
19 | - Simple, declarative syntax - you don't have to write any styles at all to produce a form, if you don't want to (although all default styles are overridable)
20 |
21 | ```js
22 |
31 | ```
32 | Then, you can get the the serialized data from your form by simply calling `this.form.getData();`
33 |
34 | - Plus, a library of common form components available out of the box, for iOS and Android:
35 |
36 | iOS | Android
37 | :-------------------------:|:-------------------------:
38 |  | 
39 |
40 |
41 | ## Installation ##
42 | `npm install react-native-forms --save`
43 |
44 | The package has no native dependencies. In the example project, I use the excellent [react-native-vector-icons]('https://github.com/oblador/react-native-vector-icons') for icons in the example library and screenshots, but React Native Forms does not depend on it.
45 |
46 | You can then require any component or function from the library:
47 |
48 | `const { Form, Section, createValidator } = require('react-native-forms');`
49 |
50 | Or if you use ES6 syntax:
51 |
52 | `import { Form, Section, createValidator } from 'react-native-forms';`
53 |
54 |
55 | ## Documentation ##
56 |
57 | ### Form Validation
58 |
59 | The top-level `Form` component exposes functions and props to handle data in the form.
60 |
61 | - Functions called on the `Form` component.
62 | - [`getData()`](#getData)
63 | - [`getValidationErrors()`](#getValidationErrors)
64 | - Function props passed to the `Form` component.
65 | - [`onChange([ref], [value])`](#onChange)
66 | - [`onPress([ref])`](#onPress)
67 | - [`onValidationError([ref], [message])`](#onValidationError)
68 |
69 | If you are developing your own component for use with React Native Forms, note that an[`onChange([ref], [value])`](#onChange) and [`onPress([ref])`](#onPress) function is injected into each child component of a `Form`, and you will need to make sure you call `this.props.onChange(value)` or `this.props.onPress()` at the appropriate times.
70 |
71 | Additionally, each child component has a `validator` prop, which you can use to pass a function to validate the component's value. See [Form Validation](#FormValidation) below for more information.
72 |
73 | ### Method Reference
74 |
75 |
76 | #### getData() ####
77 |
78 | Returns a *copy* of the form's data, expressed as an object, in the shape:
79 |
80 | ```js
81 | {
82 | sectionRef: {
83 | firstChildRef: firstChildValue,
84 | secondChildRef: secondChildValue,
85 | },
86 | };
87 | ```
88 |
89 |
90 | #### getValidationErrors() ####
91 |
92 | Returns a *copy* of the form's validation errors, expressed as an object of error objects in the shape:
93 |
94 | ```js
95 | {
96 | sectionRef: {
97 | childRef: childValidationErrMessage,
98 | },
99 | }
100 | ```
101 |
102 |
103 | #### onChange([ref], [value]) ####
104 |
105 | Where `ref` is the ref of the child component whose value has changed, and `value` is the new value of the child component.
106 |
107 | Note: it is not recommended to perform validation as a result of this function. Instead, inject a validator into the child component through the `validator` prop, and listen for validation errors at the the top-level `Form`'s [`getValidationErrors`](#getValidationErrors) or [`onValidationError`](#onValidationError) functions.
108 |
109 |
110 | #### onPress([ref]) ####
111 |
112 | Where `ref` is the ref of the child component responding to the touch event.
113 |
114 | This is called by each component that respond to touch events. Examples from the library would include `PushButtonCell` or `ButtonCell`.
115 |
116 |
117 | #### onValidationError([sectionRef], [sectionData]) ####
118 |
119 | Where `sectionRef` is the ref of the child section component whose validation function has failed. The error message is set as a value on whichever child of the section failed its `validator` prop.
120 |
121 | You'll probably never need to use this function, since you probably only want to alert users of validation errors on submit.
122 |
123 |
124 | ### Form Validation
125 |
126 | Each validation function takes a single argument, `value`, which contains the value of the component it's validating. If validation fails, the function throws an error with a specified message.
127 |
128 | The library exposes one generic function for creating validators: `createValidator`.
129 |
130 | #### createValidator([validator], [options])
131 |
132 | Returns a validator function, created with specified options. You can pass either a validator from the library (such as `emailValidator`) or one of your own.
133 |
134 | ##### Arguments
135 |
136 | - [`validator(value): boolean`] *Function*: This function is passed the value of the component the validator is passed to as a prop, and should return the boolean value of whether the component's value is valid.
137 |
138 | - [`options`] *Object*: Customizes the behavior of the validator function.
139 | - [`errorMessage`] *String*: The message that the validator should fail with.
140 |
141 | ### Components
142 |
143 | Out of the box, React Native Forms comes with
144 | - `ActionSheetCell` (ios only)
145 | - `ButtonCell`
146 | - `DatePickerCell` (ios only)
147 | - `PushButtonCell`
148 | - `SwitchCell`
149 | - `TextInputCell`
150 |
151 | I've tried to make these components as consistent and customizable as possible, but PR's are highly welcome to improve their API, as well as to add more common form components, and improve documentation. I'm also working to provide more components.
152 |
153 | To learn how to use them, see their usage in the example project, as well as the available `propTypes` in each component's source.
154 |
155 | #### Creating Custom Components
156 |
157 | You can write your own components, and give them whatever styles or behaviors you want. `Form` and `Section` components are agnostic as to the styles and behaviors of their children.
158 |
159 | Remember that the parent `Section` will automatically inject `onPress` and `onChange` props into your component, and bind the child's `refs` to the function. To make your component work with React Native Form's data API, simply call `this.props.onChange(value)` or `this.props.onPress()` at appropriate times. For more information, see the example project.
160 |
161 |
162 | ## FAQ ##
163 |
164 |
165 | ##### When I navigate to the form, I get an error: RCTUIManager.m Error frame is not a descendant of < RCTShadowView >
166 |
167 | This error happens when you have multiple views listening for keyboard events. This can happen, for example, when multiple scroll views inside a navigation stack are listening to keyboard events in order to scroll to a text input.
168 |
169 | You can fix this by unmounting any components which are listening for keyboard events before presenting another. React Native Forms depends on [react-native-keyboard-aware-scroll-view](https://github.com/APSL/react-native-keyboard-aware-scroll-view), which listens for keyboard events if you've enabled the `keyboardAware` prop on your top-level `Form` component.
170 |
171 | I'd like to fix this and allow for keyboard aware child forms. This seems to be possible. (For example, see [this discussion](https://github.com/facebook/react-native/pull/7876) in react-native). PR's are welcome.
172 |
173 |
174 | ## Contributing ##
175 |
176 | PR's are *very* welcome! This is a very young library, and probably has a wealth of bugs and optimizations to fix and improve on. I have just a couple requests:
177 |
178 | - Please use the linter included with the package for code style. I follow [Airbnb](https://github.com/airbnb/javascript), with a few modifications.
179 | - Update the documentation and example project if necessary/applicable.
180 |
181 | Thank you!
182 |
183 |
184 | ## License ##
185 | MIT
186 |
--------------------------------------------------------------------------------
/RNFormsExample/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | 'presets': ['react-native']
3 | }
--------------------------------------------------------------------------------
/RNFormsExample/.buckconfig:
--------------------------------------------------------------------------------
1 |
2 | [android]
3 | target = Google Inc.:Google APIs:23
4 |
5 | [maven_repositories]
6 | central = https://repo1.maven.org/maven2
7 |
--------------------------------------------------------------------------------
/RNFormsExample/.flowconfig:
--------------------------------------------------------------------------------
1 | [ignore]
2 | ; We fork some components by platform
3 | .*/*[.]android.js
4 |
5 | ; Ignore 'BUCK' generated dirs
6 | /\.buckd/
7 |
8 | ; Ignore unexpected extra '@providesModule'
9 | .*/node_modules/.*/node_modules/fbjs/.*
10 |
11 | ; Ignore duplicate module providers
12 | ; For RN Apps installed via npm, 'Libraries' folder is inside
13 | ; 'node_modules/react-native' but in the source repo it is in the root
14 | .*/Libraries/react-native/React.js
15 | .*/Libraries/react-native/ReactNative.js
16 |
17 | [include]
18 |
19 | [libs]
20 | node_modules/react-native/Libraries/react-native/react-native-interface.js
21 | node_modules/react-native/flow
22 | flow/
23 |
24 | [options]
25 | module.system=haste
26 |
27 | experimental.strict_type_args=true
28 |
29 | munge_underscores=true
30 |
31 | module.name_mapper='^[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> 'RelativeImageStub'
32 |
33 | suppress_type=$FlowIssue
34 | suppress_type=$FlowFixMe
35 | suppress_type=$FixMe
36 |
37 | suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(3[0-6]\\|[1-2][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)
38 | suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(3[0-6]\\|1[0-9]\\|[1-2][0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+
39 | suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy
40 |
41 | unsafe.enable_getters_and_setters=true
42 |
43 | [version]
44 | ^0.36.0
45 |
--------------------------------------------------------------------------------
/RNFormsExample/.gitattributes:
--------------------------------------------------------------------------------
1 | *.pbxproj -text
2 |
--------------------------------------------------------------------------------
/RNFormsExample/.gitignore:
--------------------------------------------------------------------------------
1 | # OSX
2 | #
3 | .DS_Store
4 |
5 | # Xcode
6 | #
7 | build/
8 | *.pbxuser
9 | !default.pbxuser
10 | *.mode1v3
11 | !default.mode1v3
12 | *.mode2v3
13 | !default.mode2v3
14 | *.perspectivev3
15 | !default.perspectivev3
16 | xcuserdata
17 | *.xccheckout
18 | *.moved-aside
19 | DerivedData
20 | *.hmap
21 | *.ipa
22 | *.xcuserstate
23 | project.xcworkspace
24 |
25 | # Android/IntelliJ
26 | #
27 | build/
28 | .idea
29 | .gradle
30 | local.properties
31 | *.iml
32 |
33 | # node.js
34 | #
35 | node_modules/
36 | npm-debug.log
37 |
38 | # BUCK
39 | buck-out/
40 | \.buckd/
41 | android/app/libs
42 | *.keystore
43 |
44 | # fastlane
45 | #
46 | # It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the
47 | # screenshots whenever they are needed.
48 | # For more information about the recommended setup visit:
49 | # https://github.com/fastlane/fastlane/blob/master/fastlane/docs/Gitignore.md
50 |
51 | fastlane/report.xml
52 | fastlane/Preview.html
53 | fastlane/screenshots
54 |
--------------------------------------------------------------------------------
/RNFormsExample/.watchmanconfig:
--------------------------------------------------------------------------------
1 | {}
--------------------------------------------------------------------------------
/RNFormsExample/CustomInput.js:
--------------------------------------------------------------------------------
1 | import React, { PropTypes } from 'react';
2 | import {
3 | View,
4 | Text,
5 | TextInput,
6 | StyleSheet,
7 | } from 'react-native';
8 | import Icon from 'react-native-vector-icons/Ionicons';
9 |
10 | const styles = StyleSheet.create({
11 | container: {
12 | height: 44,
13 | flexDirection: 'row',
14 | },
15 | rightTextInput: {
16 | height: 44,
17 | width: 200,
18 | marginRight: 10,
19 | fontSize: 16,
20 | alignSelf: 'center',
21 | textAlign: 'right',
22 | },
23 | title: {
24 | flex: 1,
25 | marginLeft: 10,
26 | alignSelf: 'center',
27 | fontSize: 16,
28 | },
29 | icon: {
30 | paddingLeft: 10,
31 | alignSelf: 'center',
32 | },
33 | });
34 |
35 | export default class CustomInput extends React.Component {
36 | constructor(props) {
37 | super(props);
38 | this.state = {
39 | value: props.value || '',
40 | };
41 | if (props.value) {
42 | this.props.onChange && this.props.onChange(props.value);
43 | }
44 | }
45 |
46 | handleChange(event) {
47 | const value = event.nativeEvent.text;
48 | this.setState({
49 | value,
50 | });
51 | this.props.onChange && this.props.onChange(value);
52 | try {
53 | this.props.validator && this.props.validator(value);
54 | this.props.onValidationPass && this.props.onValidationPass();
55 | } catch (e) {
56 | this.props.onValidationError && this.props.onValidationError(e.message);
57 | }
58 | }
59 |
60 | render() {
61 | return (
62 |
63 |
64 | {this.props.title}
65 | {/* {this.props.title} */}
66 |
73 |
74 | );
75 | }
76 | }
77 |
78 | CustomInput.propTypes = {
79 | onChange: PropTypes.func,
80 | onValidationError: PropTypes.func,
81 | onValidationPass: PropTypes.func,
82 | title: PropTypes.string,
83 | validator: PropTypes.func,
84 | value: PropTypes.string,
85 | };
86 |
--------------------------------------------------------------------------------
/RNFormsExample/ExampleForm.js:
--------------------------------------------------------------------------------
1 | /* eslint-disable no-console */
2 |
3 | import React from 'react';
4 | import { View } from 'react-native';
5 | import {
6 | ActionSheetCell,
7 | ButtonCell,
8 | createValidator,
9 | DatePickerCell,
10 | emailValidator,
11 | Form,
12 | PushButtonCell,
13 | Section,
14 | SwitchCell,
15 | TextInputCell,
16 | } from 'react-native-forms';
17 | import Icon from 'react-native-vector-icons/Ionicons';
18 | import CustomInput from './CustomInput';
19 |
20 | class ExampleForm extends React.Component {
21 |
22 | onValidationError(ref, message) {
23 | console.log(ref, message);
24 | }
25 |
26 | handleChange(ref, change) {
27 | console.log(ref, change);
28 | }
29 |
30 | handlePress(ref) {
31 | if (ref === 'LogData') {
32 | console.log(this.form.getData());
33 | } else if (ref === 'LogValidationErrors') {
34 | console.log(this.form.getValidationErrors());
35 | }
36 | }
37 |
38 | render() {
39 | const forwardIcon = ;
40 | const alertIcon = ;
41 | return (
42 |
43 |
137 |
138 | );
139 | }
140 | }
141 |
142 | export default ExampleForm;
143 |
--------------------------------------------------------------------------------
/RNFormsExample/__tests__/index.android.js:
--------------------------------------------------------------------------------
1 | import 'react-native';
2 | import React from 'react';
3 | import Index from '../index.android.js';
4 |
5 | // Note: test renderer must be required after react-native.
6 | import renderer from 'react-test-renderer';
7 |
8 | it('renders correctly', () => {
9 | const tree = renderer.create(
10 |
11 | );
12 | });
13 |
--------------------------------------------------------------------------------
/RNFormsExample/__tests__/index.ios.js:
--------------------------------------------------------------------------------
1 | import 'react-native';
2 | import React from 'react';
3 | import Index from '../index.ios.js';
4 |
5 | // Note: test renderer must be required after react-native.
6 | import renderer from 'react-test-renderer';
7 |
8 | it('renders correctly', () => {
9 | const tree = renderer.create(
10 |
11 | );
12 | });
13 |
--------------------------------------------------------------------------------
/RNFormsExample/android/app/BUCK:
--------------------------------------------------------------------------------
1 | import re
2 |
3 | # To learn about Buck see [Docs](https://buckbuild.com/).
4 | # To run your application with Buck:
5 | # - install Buck
6 | # - `npm start` - to start the packager
7 | # - `cd android`
8 | # - `keytool -genkey -v -keystore keystores/debug.keystore -storepass android -alias androiddebugkey -keypass android -dname 'CN=Android Debug,O=Android,C=US'`
9 | # - `./gradlew :app:copyDownloadableDepsToLibs` - make all Gradle compile dependencies available to Buck
10 | # - `buck install -r android/app` - compile, install and run application
11 | #
12 |
13 | lib_deps = []
14 | for jarfile in glob(['libs/*.jar']):
15 | name = 'jars__' + re.sub(r'^.*/([^/]+)\.jar$', r'\1', jarfile)
16 | lib_deps.append(':' + name)
17 | prebuilt_jar(
18 | name = name,
19 | binary_jar = jarfile,
20 | )
21 |
22 | for aarfile in glob(['libs/*.aar']):
23 | name = 'aars__' + re.sub(r'^.*/([^/]+)\.aar$', r'\1', aarfile)
24 | lib_deps.append(':' + name)
25 | android_prebuilt_aar(
26 | name = name,
27 | aar = aarfile,
28 | )
29 |
30 | android_library(
31 | name = 'all-libs',
32 | exported_deps = lib_deps
33 | )
34 |
35 | android_library(
36 | name = 'app-code',
37 | srcs = glob([
38 | 'src/main/java/**/*.java',
39 | ]),
40 | deps = [
41 | ':all-libs',
42 | ':build_config',
43 | ':res',
44 | ],
45 | )
46 |
47 | android_build_config(
48 | name = 'build_config',
49 | package = 'com.rnformsexample',
50 | )
51 |
52 | android_resource(
53 | name = 'res',
54 | res = 'src/main/res',
55 | package = 'com.rnformsexample',
56 | )
57 |
58 | android_binary(
59 | name = 'app',
60 | package_type = 'debug',
61 | manifest = 'src/main/AndroidManifest.xml',
62 | keystore = '//android/keystores:debug',
63 | deps = [
64 | ':app-code',
65 | ],
66 | )
67 |
--------------------------------------------------------------------------------
/RNFormsExample/android/app/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.application'
2 |
3 | import com.android.build.OutputFile
4 |
5 | /**
6 | * The react.gradle file registers a task for each build variant (e.g. bundleDebugJsAndAssets
7 | * and bundleReleaseJsAndAssets).
8 | * These basically call `react-native bundle` with the correct arguments during the Android build
9 | * cycle. By default, bundleDebugJsAndAssets is skipped, as in debug/dev mode we prefer to load the
10 | * bundle directly from the development server. Below you can see all the possible configurations
11 | * and their defaults. If you decide to add a configuration block, make sure to add it before the
12 | * `apply from: '../../node_modules/react-native/react.gradle'` line.
13 | *
14 | * project.ext.react = [
15 | * // the name of the generated asset file containing your JS bundle
16 | * bundleAssetName: 'index.android.bundle',
17 | *
18 | * // the entry file for bundle generation
19 | * entryFile: 'index.android.js',
20 | *
21 | * // whether to bundle JS and assets in debug mode
22 | * bundleInDebug: false,
23 | *
24 | * // whether to bundle JS and assets in release mode
25 | * bundleInRelease: true,
26 | *
27 | * // whether to bundle JS and assets in another build variant (if configured).
28 | * // See http://tools.android.com/tech-docs/new-build-system/user-guide#TOC-Build-Variants
29 | * // The configuration property can be in the following formats
30 | * // 'bundleIn${productFlavor}${buildType}'
31 | * // 'bundleIn${buildType}'
32 | * // bundleInFreeDebug: true,
33 | * // bundleInPaidRelease: true,
34 | * // bundleInBeta: true,
35 | *
36 | * // the root of your project, i.e. where 'package.json' lives
37 | * root: '../../',
38 | *
39 | * // where to put the JS bundle asset in debug mode
40 | * jsBundleDirDebug: '$buildDir/intermediates/assets/debug',
41 | *
42 | * // where to put the JS bundle asset in release mode
43 | * jsBundleDirRelease: '$buildDir/intermediates/assets/release',
44 | *
45 | * // where to put drawable resources / React Native assets, e.g. the ones you use via
46 | * // require('./image.png')), in debug mode
47 | * resourcesDirDebug: '$buildDir/intermediates/res/merged/debug',
48 | *
49 | * // where to put drawable resources / React Native assets, e.g. the ones you use via
50 | * // require('./image.png')), in release mode
51 | * resourcesDirRelease: '$buildDir/intermediates/res/merged/release',
52 | *
53 | * // by default the gradle tasks are skipped if none of the JS files or assets change; this means
54 | * // that we don't look at files in android/ or ios/ to determine whether the tasks are up to
55 | * // date; if you have any other folders that you want to ignore for performance reasons (gradle
56 | * // indexes the entire tree), add them here. Alternatively, if you have JS files in android/
57 | * // for example, you might want to remove it from here.
58 | * inputExcludes: ['android/**', 'ios/**'],
59 | *
60 | * // override which node gets called and with what additional arguments
61 | * nodeExecutableAndArgs: ['node']
62 | *
63 | * // supply additional arguments to the packager
64 | * extraPackagerArgs: []
65 | * ]
66 | */
67 |
68 | apply from: '../../node_modules/react-native/react.gradle'
69 |
70 | /**
71 | * Set this to true to create two separate APKs instead of one:
72 | * - An APK that only works on ARM devices
73 | * - An APK that only works on x86 devices
74 | * The advantage is the size of the APK is reduced by about 4MB.
75 | * Upload all the APKs to the Play Store and people will download
76 | * the correct one based on the CPU architecture of their device.
77 | */
78 | def enableSeparateBuildPerCPUArchitecture = false
79 |
80 | /**
81 | * Run Proguard to shrink the Java bytecode in release builds.
82 | */
83 | def enableProguardInReleaseBuilds = false
84 |
85 | android {
86 | compileSdkVersion 23
87 | buildToolsVersion '23.0.1'
88 |
89 | defaultConfig {
90 | applicationId 'com.rnformsexample'
91 | minSdkVersion 16
92 | targetSdkVersion 22
93 | versionCode 1
94 | versionName '1.0'
95 | ndk {
96 | abiFilters 'armeabi-v7a', 'x86'
97 | }
98 | }
99 | splits {
100 | abi {
101 | reset()
102 | enable enableSeparateBuildPerCPUArchitecture
103 | universalApk false // If true, also generate a universal APK
104 | include 'armeabi-v7a', 'x86'
105 | }
106 | }
107 | buildTypes {
108 | release {
109 | minifyEnabled enableProguardInReleaseBuilds
110 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
111 | }
112 | }
113 | // applicationVariants are e.g. debug, release
114 | applicationVariants.all { variant ->
115 | variant.outputs.each { output ->
116 | // For each separate APK per architecture, set a unique version code as described here:
117 | // http://tools.android.com/tech-docs/new-build-system/user-guide/apk-splits
118 | def versionCodes = ['armeabi-v7a':1, 'x86':2]
119 | def abi = output.getFilter(OutputFile.ABI)
120 | if (abi != null) { // null for the universal-debug, universal-release variants
121 | output.versionCodeOverride =
122 | versionCodes.get(abi) * 1048576 + defaultConfig.versionCode
123 | }
124 | }
125 | }
126 | }
127 |
128 | dependencies {
129 | compile project(':react-native-vector-icons')
130 | compile fileTree(dir: 'libs', include: ['*.jar'])
131 | compile 'com.android.support:appcompat-v7:23.0.1'
132 | compile 'com.facebook.react:react-native:+' // From node_modules
133 | }
134 |
135 | // Run this once to be able to run the application with BUCK
136 | // puts all compile dependencies into folder libs for BUCK to use
137 | task copyDownloadableDepsToLibs(type: Copy) {
138 | from configurations.compile
139 | into 'libs'
140 | }
141 |
--------------------------------------------------------------------------------
/RNFormsExample/android/app/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # By default, the flags in this file are appended to flags specified
3 | # in /usr/local/Cellar/android-sdk/24.3.3/tools/proguard/proguard-android.txt
4 | # You can edit the include path and order by changing the proguardFiles
5 | # directive in build.gradle.
6 | #
7 | # For more details, see
8 | # http://developer.android.com/guide/developing/tools/proguard.html
9 |
10 | # Add any project specific keep options here:
11 |
12 | # If your project uses WebView with JS, uncomment the following
13 | # and specify the fully qualified class name to the JavaScript interface
14 | # class:
15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
16 | # public *;
17 | #}
18 |
19 | # Disabling obfuscation is useful if you collect stack traces from production crashes
20 | # (unless you are using a system that supports de-obfuscate the stack traces).
21 | -dontobfuscate
22 |
23 | # React Native
24 |
25 | # Keep our interfaces so they can be used by other ProGuard rules.
26 | # See http://sourceforge.net/p/proguard/bugs/466/
27 | -keep,allowobfuscation @interface com.facebook.proguard.annotations.DoNotStrip
28 | -keep,allowobfuscation @interface com.facebook.proguard.annotations.KeepGettersAndSetters
29 | -keep,allowobfuscation @interface com.facebook.common.internal.DoNotStrip
30 |
31 | # Do not strip any method/class that is annotated with @DoNotStrip
32 | -keep @com.facebook.proguard.annotations.DoNotStrip class *
33 | -keep @com.facebook.common.internal.DoNotStrip class *
34 | -keepclassmembers class * {
35 | @com.facebook.proguard.annotations.DoNotStrip *;
36 | @com.facebook.common.internal.DoNotStrip *;
37 | }
38 |
39 | -keepclassmembers @com.facebook.proguard.annotations.KeepGettersAndSetters class * {
40 | void set*(***);
41 | *** get*();
42 | }
43 |
44 | -keep class * extends com.facebook.react.bridge.JavaScriptModule { *; }
45 | -keep class * extends com.facebook.react.bridge.NativeModule { *; }
46 | -keepclassmembers,includedescriptorclasses class * { native ; }
47 | -keepclassmembers class * { @com.facebook.react.uimanager.UIProp ; }
48 | -keepclassmembers class * { @com.facebook.react.uimanager.annotations.ReactProp ; }
49 | -keepclassmembers class * { @com.facebook.react.uimanager.annotations.ReactPropGroup ; }
50 |
51 | -dontwarn com.facebook.react.**
52 |
53 | # okhttp
54 |
55 | -keepattributes Signature
56 | -keepattributes *Annotation*
57 | -keep class okhttp3.** { *; }
58 | -keep interface okhttp3.** { *; }
59 | -dontwarn okhttp3.**
60 |
61 | # okio
62 |
63 | -keep class sun.misc.Unsafe { *; }
64 | -dontwarn java.nio.file.*
65 | -dontwarn org.codehaus.mojo.animal_sniffer.IgnoreJRERequirement
66 | -dontwarn okio.**
67 |
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
8 |
9 |
12 |
13 |
19 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/assets/fonts/Entypo.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/app/src/main/assets/fonts/Entypo.ttf
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/assets/fonts/EvilIcons.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/app/src/main/assets/fonts/EvilIcons.ttf
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/assets/fonts/FontAwesome.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/app/src/main/assets/fonts/FontAwesome.ttf
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/assets/fonts/Foundation.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/app/src/main/assets/fonts/Foundation.ttf
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/assets/fonts/Ionicons.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/app/src/main/assets/fonts/Ionicons.ttf
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/assets/fonts/MaterialCommunityIcons.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/app/src/main/assets/fonts/MaterialCommunityIcons.ttf
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/assets/fonts/MaterialIcons.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/app/src/main/assets/fonts/MaterialIcons.ttf
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/assets/fonts/Octicons.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/app/src/main/assets/fonts/Octicons.ttf
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/assets/fonts/SimpleLineIcons.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/app/src/main/assets/fonts/SimpleLineIcons.ttf
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/assets/fonts/Zocial.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/app/src/main/assets/fonts/Zocial.ttf
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/java/com/rnformsexample/MainActivity.java:
--------------------------------------------------------------------------------
1 | package com.rnformsexample;
2 |
3 | import com.facebook.react.ReactActivity;
4 |
5 | public class MainActivity extends ReactActivity {
6 |
7 | /**
8 | * Returns the name of the main component registered from JavaScript.
9 | * This is used to schedule rendering of the component.
10 | */
11 | @Override
12 | protected String getMainComponentName() {
13 | return 'RNFormsExample';
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/java/com/rnformsexample/MainApplication.java:
--------------------------------------------------------------------------------
1 | package com.rnformsexample;
2 |
3 | import android.app.Application;
4 | import android.util.Log;
5 |
6 | import com.facebook.react.ReactApplication;
7 | import com.oblador.vectoricons.VectorIconsPackage;
8 | import com.facebook.react.ReactInstanceManager;
9 | import com.facebook.react.ReactNativeHost;
10 | import com.facebook.react.ReactPackage;
11 | import com.facebook.react.shell.MainReactPackage;
12 | import com.facebook.soloader.SoLoader;
13 |
14 | import java.util.Arrays;
15 | import java.util.List;
16 |
17 | public class MainApplication extends Application implements ReactApplication {
18 |
19 | private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) {
20 | @Override
21 | protected boolean getUseDeveloperSupport() {
22 | return BuildConfig.DEBUG;
23 | }
24 |
25 | @Override
26 | protected List getPackages() {
27 | return Arrays.asList(
28 | new MainReactPackage(),
29 | new VectorIconsPackage()
30 | );
31 | }
32 | };
33 |
34 | @Override
35 | public ReactNativeHost getReactNativeHost() {
36 | return mReactNativeHost;
37 | }
38 |
39 | @Override
40 | public void onCreate() {
41 | super.onCreate();
42 | SoLoader.init(this, /* native exopackage */ false);
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/res/mipmap-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/app/src/main/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/app/src/main/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 | RNFormsExample
3 |
4 |
--------------------------------------------------------------------------------
/RNFormsExample/android/app/src/main/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/RNFormsExample/android/build.gradle:
--------------------------------------------------------------------------------
1 | // Top-level build file where you can add configuration options common to all sub-projects/modules.
2 |
3 | buildscript {
4 | repositories {
5 | jcenter()
6 | }
7 | dependencies {
8 | classpath 'com.android.tools.build:gradle:1.3.1'
9 |
10 | // NOTE: Do not place your application dependencies here; they belong
11 | // in the individual module build.gradle files
12 | }
13 | }
14 |
15 | allprojects {
16 | repositories {
17 | mavenLocal()
18 | jcenter()
19 | maven {
20 | // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
21 | url '$rootDir/../node_modules/react-native/android'
22 | }
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/RNFormsExample/android/gradle.properties:
--------------------------------------------------------------------------------
1 | # Project-wide Gradle settings.
2 |
3 | # IDE (e.g. Android Studio) users:
4 | # Gradle settings configured through the IDE *will override*
5 | # any settings specified in this file.
6 |
7 | # For more details on how to configure your build environment visit
8 | # http://www.gradle.org/docs/current/userguide/build_environment.html
9 |
10 | # Specifies the JVM arguments used for the daemon process.
11 | # The setting is particularly useful for tweaking memory settings.
12 | # Default value: -Xmx10248m -XX:MaxPermSize=256m
13 | # org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
14 |
15 | # When configured, Gradle will run in incubating parallel mode.
16 | # This option should only be used with decoupled projects. More details, visit
17 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
18 | # org.gradle.parallel=true
19 |
20 | android.useDeprecatedNdk=true
21 |
--------------------------------------------------------------------------------
/RNFormsExample/android/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/RNFormsExample/android/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/RNFormsExample/android/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | distributionBase=GRADLE_USER_HOME
2 | distributionPath=wrapper/dists
3 | zipStoreBase=GRADLE_USER_HOME
4 | zipStorePath=wrapper/dists
5 | distributionUrl=https\://services.gradle.org/distributions/gradle-2.4-all.zip
6 |
--------------------------------------------------------------------------------
/RNFormsExample/android/gradlew:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 |
3 | ##############################################################################
4 | ##
5 | ## Gradle start up script for UN*X
6 | ##
7 | ##############################################################################
8 |
9 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
10 | DEFAULT_JVM_OPTS=''
11 |
12 | APP_NAME='Gradle'
13 | APP_BASE_NAME=`basename '$0'`
14 |
15 | # Use the maximum available, or set MAX_FD != -1 to use that value.
16 | MAX_FD='maximum'
17 |
18 | warn ( ) {
19 | echo '$*'
20 | }
21 |
22 | die ( ) {
23 | echo
24 | echo '$*'
25 | echo
26 | exit 1
27 | }
28 |
29 | # OS specific support (must be 'true' or 'false').
30 | cygwin=false
31 | msys=false
32 | darwin=false
33 | case '`uname`' in
34 | CYGWIN* )
35 | cygwin=true
36 | ;;
37 | Darwin* )
38 | darwin=true
39 | ;;
40 | MINGW* )
41 | msys=true
42 | ;;
43 | esac
44 |
45 | # For Cygwin, ensure paths are in UNIX format before anything is touched.
46 | if $cygwin ; then
47 | [ -n '$JAVA_HOME' ] && JAVA_HOME=`cygpath --unix '$JAVA_HOME'`
48 | fi
49 |
50 | # Attempt to set APP_HOME
51 | # Resolve links: $0 may be a link
52 | PRG='$0'
53 | # Need this for relative symlinks.
54 | while [ -h '$PRG' ] ; do
55 | ls=`ls -ld '$PRG'`
56 | link=`expr '$ls' : '.*-> \(.*\)$'`
57 | if expr '$link' : '/.*' > /dev/null; then
58 | PRG='$link'
59 | else
60 | PRG=`dirname '$PRG'`'/$link'
61 | fi
62 | done
63 | SAVED='`pwd`'
64 | cd '`dirname \'$PRG\'`/' >&-
65 | APP_HOME='`pwd -P`'
66 | cd '$SAVED' >&-
67 |
68 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
69 |
70 | # Determine the Java command to use to start the JVM.
71 | if [ -n '$JAVA_HOME' ] ; then
72 | if [ -x '$JAVA_HOME/jre/sh/java' ] ; then
73 | # IBM's JDK on AIX uses strange locations for the executables
74 | JAVACMD='$JAVA_HOME/jre/sh/java'
75 | else
76 | JAVACMD='$JAVA_HOME/bin/java'
77 | fi
78 | if [ ! -x '$JAVACMD' ] ; then
79 | die 'ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
80 |
81 | Please set the JAVA_HOME variable in your environment to match the
82 | location of your Java installation.'
83 | fi
84 | else
85 | JAVACMD='java'
86 | which java >/dev/null 2>&1 || die 'ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
87 |
88 | Please set the JAVA_HOME variable in your environment to match the
89 | location of your Java installation.'
90 | fi
91 |
92 | # Increase the maximum file descriptors if we can.
93 | if [ '$cygwin' = 'false' -a '$darwin' = 'false' ] ; then
94 | MAX_FD_LIMIT=`ulimit -H -n`
95 | if [ $? -eq 0 ] ; then
96 | if [ '$MAX_FD' = 'maximum' -o '$MAX_FD' = 'max' ] ; then
97 | MAX_FD='$MAX_FD_LIMIT'
98 | fi
99 | ulimit -n $MAX_FD
100 | if [ $? -ne 0 ] ; then
101 | warn 'Could not set maximum file descriptor limit: $MAX_FD'
102 | fi
103 | else
104 | warn 'Could not query maximum file descriptor limit: $MAX_FD_LIMIT'
105 | fi
106 | fi
107 |
108 | # For Darwin, add options to specify how the application appears in the dock
109 | if $darwin; then
110 | GRADLE_OPTS='$GRADLE_OPTS \'-Xdock:name=$APP_NAME\' \'-Xdock:icon=$APP_HOME/media/gradle.icns\''
111 | fi
112 |
113 | # For Cygwin, switch paths to Windows format before running java
114 | if $cygwin ; then
115 | APP_HOME=`cygpath --path --mixed '$APP_HOME'`
116 | CLASSPATH=`cygpath --path --mixed '$CLASSPATH'`
117 |
118 | # We build the pattern for arguments to be converted via cygpath
119 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
120 | SEP=''
121 | for dir in $ROOTDIRSRAW ; do
122 | ROOTDIRS='$ROOTDIRS$SEP$dir'
123 | SEP='|'
124 | done
125 | OURCYGPATTERN='(^($ROOTDIRS))'
126 | # Add a user-defined pattern to the cygpath arguments
127 | if [ '$GRADLE_CYGPATTERN' != '' ] ; then
128 | OURCYGPATTERN='$OURCYGPATTERN|($GRADLE_CYGPATTERN)'
129 | fi
130 | # Now convert the arguments - kludge to limit ourselves to /bin/sh
131 | i=0
132 | for arg in '$@' ; do
133 | CHECK=`echo '$arg'|egrep -c '$OURCYGPATTERN' -`
134 | CHECK2=`echo '$arg'|egrep -c '^-'` ### Determine if an option
135 |
136 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
137 | eval `echo args$i`=`cygpath --path --ignore --mixed '$arg'`
138 | else
139 | eval `echo args$i`='\'$arg\''
140 | fi
141 | i=$((i+1))
142 | done
143 | case $i in
144 | (0) set -- ;;
145 | (1) set -- '$args0' ;;
146 | (2) set -- '$args0' '$args1' ;;
147 | (3) set -- '$args0' '$args1' '$args2' ;;
148 | (4) set -- '$args0' '$args1' '$args2' '$args3' ;;
149 | (5) set -- '$args0' '$args1' '$args2' '$args3' '$args4' ;;
150 | (6) set -- '$args0' '$args1' '$args2' '$args3' '$args4' '$args5' ;;
151 | (7) set -- '$args0' '$args1' '$args2' '$args3' '$args4' '$args5' '$args6' ;;
152 | (8) set -- '$args0' '$args1' '$args2' '$args3' '$args4' '$args5' '$args6' '$args7' ;;
153 | (9) set -- '$args0' '$args1' '$args2' '$args3' '$args4' '$args5' '$args6' '$args7' '$args8' ;;
154 | esac
155 | fi
156 |
157 | # Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
158 | function splitJvmOpts() {
159 | JVM_OPTS=('$@')
160 | }
161 | eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
162 | JVM_OPTS[${#JVM_OPTS[*]}]='-Dorg.gradle.appname=$APP_BASE_NAME'
163 |
164 | exec '$JAVACMD' '${JVM_OPTS[@]}' -classpath '$CLASSPATH' org.gradle.wrapper.GradleWrapperMain '$@'
165 |
--------------------------------------------------------------------------------
/RNFormsExample/android/gradlew.bat:
--------------------------------------------------------------------------------
1 | @if '%DEBUG%' == '' @echo off
2 | @rem ##########################################################################
3 | @rem
4 | @rem Gradle startup script for Windows
5 | @rem
6 | @rem ##########################################################################
7 |
8 | @rem Set local scope for the variables with windows NT shell
9 | if '%OS%'=='Windows_NT' setlocal
10 |
11 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
12 | set DEFAULT_JVM_OPTS=
13 |
14 | set DIRNAME=%~dp0
15 | if '%DIRNAME%' == '' set DIRNAME=.
16 | set APP_BASE_NAME=%~n0
17 | set APP_HOME=%DIRNAME%
18 |
19 | @rem Find java.exe
20 | if defined JAVA_HOME goto findJavaFromJavaHome
21 |
22 | set JAVA_EXE=java.exe
23 | %JAVA_EXE% -version >NUL 2>&1
24 | if '%ERRORLEVEL%' == '0' goto init
25 |
26 | echo.
27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
28 | echo.
29 | echo Please set the JAVA_HOME variable in your environment to match the
30 | echo location of your Java installation.
31 |
32 | goto fail
33 |
34 | :findJavaFromJavaHome
35 | set JAVA_HOME=%JAVA_HOME:'=%
36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe
37 |
38 | if exist '%JAVA_EXE%' goto init
39 |
40 | echo.
41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
42 | echo.
43 | echo Please set the JAVA_HOME variable in your environment to match the
44 | echo location of your Java installation.
45 |
46 | goto fail
47 |
48 | :init
49 | @rem Get command-line arguments, handling Windowz variants
50 |
51 | if not '%OS%' == 'Windows_NT' goto win9xME_args
52 | if '%@eval[2+2]' == '4' goto 4NT_args
53 |
54 | :win9xME_args
55 | @rem Slurp the command line arguments.
56 | set CMD_LINE_ARGS=
57 | set _SKIP=2
58 |
59 | :win9xME_args_slurp
60 | if 'x%~1' == 'x' goto execute
61 |
62 | set CMD_LINE_ARGS=%*
63 | goto execute
64 |
65 | :4NT_args
66 | @rem Get arguments from the 4NT Shell from JP Software
67 | set CMD_LINE_ARGS=%$
68 |
69 | :execute
70 | @rem Setup the command line
71 |
72 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
73 |
74 | @rem Execute Gradle
75 | '%JAVA_EXE%' %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% '-Dorg.gradle.appname=%APP_BASE_NAME%' -classpath '%CLASSPATH%' org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
76 |
77 | :end
78 | @rem End local scope for the variables with windows NT shell
79 | if '%ERRORLEVEL%'=='0' goto mainEnd
80 |
81 | :fail
82 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
83 | rem the _cmd.exe /c_ return code!
84 | if not '' == '%GRADLE_EXIT_CONSOLE%' exit 1
85 | exit /b 1
86 |
87 | :mainEnd
88 | if '%OS%'=='Windows_NT' endlocal
89 |
90 | :omega
91 |
--------------------------------------------------------------------------------
/RNFormsExample/android/keystores/BUCK:
--------------------------------------------------------------------------------
1 | keystore(
2 | name = 'debug',
3 | store = 'debug.keystore',
4 | properties = 'debug.keystore.properties',
5 | visibility = [
6 | 'PUBLIC',
7 | ],
8 | )
9 |
--------------------------------------------------------------------------------
/RNFormsExample/android/keystores/debug.keystore.properties:
--------------------------------------------------------------------------------
1 | key.store=debug.keystore
2 | key.alias=androiddebugkey
3 | key.store.password=android
4 | key.alias.password=android
5 |
--------------------------------------------------------------------------------
/RNFormsExample/android/settings.gradle:
--------------------------------------------------------------------------------
1 | rootProject.name = 'RNFormsExample'
2 | include ':react-native-vector-icons'
3 | project(':react-native-vector-icons').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-vector-icons/android')
4 |
5 | include ':app'
6 |
--------------------------------------------------------------------------------
/RNFormsExample/index.android.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Sample React Native App
3 | * https://github.com/facebook/react-native
4 | * @flow
5 | */
6 |
7 | import React from 'react';
8 | import {
9 | AppRegistry,
10 | } from 'react-native';
11 |
12 | import ExampleForm from './ExampleForm';
13 |
14 | function RNFormsExample() {
15 | return ;
16 | }
17 |
18 | AppRegistry.registerComponent('RNFormsExample', () => RNFormsExample);
19 |
--------------------------------------------------------------------------------
/RNFormsExample/index.ios.js:
--------------------------------------------------------------------------------
1 | /* eslint-disable */
2 |
3 | /**
4 | * Sample React Native App
5 | * https://github.com/facebook/react-native
6 | * @flow
7 | */
8 |
9 | import React, { Component } from 'react';
10 | import {
11 | AppRegistry,
12 | StyleSheet,
13 | Text,
14 | View,
15 | NavigatorIOS,
16 | } from 'react-native';
17 |
18 | import ExampleForm from './ExampleForm';
19 |
20 | class RNFormsExample extends Component {
21 | render() {
22 | return (
23 |
30 | );
31 | }
32 | }
33 |
34 | AppRegistry.registerComponent('RNFormsExample', () => RNFormsExample);
35 |
--------------------------------------------------------------------------------
/RNFormsExample/ios/RNFormsExample.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 46;
7 | objects = {
8 | /* Begin PBXBuildFile section */
9 | 00C302E51ABCBA2D00DB3ED1 /* libRCTActionSheet.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302AC1ABCB8CE00DB3ED1 /* libRCTActionSheet.a */; };
10 | 00C302E71ABCBA2D00DB3ED1 /* libRCTGeolocation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302BA1ABCB90400DB3ED1 /* libRCTGeolocation.a */; };
11 | 00C302E81ABCBA2D00DB3ED1 /* libRCTImage.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302C01ABCB91800DB3ED1 /* libRCTImage.a */; };
12 | 00C302E91ABCBA2D00DB3ED1 /* libRCTNetwork.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302DC1ABCB9D200DB3ED1 /* libRCTNetwork.a */; };
13 | 00C302EA1ABCBA2D00DB3ED1 /* libRCTVibration.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302E41ABCB9EE00DB3ED1 /* libRCTVibration.a */; };
14 | 00E356F31AD99517003FC87E /* RNFormsExampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* RNFormsExampleTests.m */; };
15 | 133E29F31AD74F7200F7D852 /* libRCTLinking.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 78C398B91ACF4ADC00677621 /* libRCTLinking.a */; };
16 | 139105C61AF99C1200B5F7CC /* libRCTSettings.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 139105C11AF99BAD00B5F7CC /* libRCTSettings.a */; };
17 | 139FDEF61B0652A700C62182 /* libRCTWebSocket.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 139FDEF41B06529B00C62182 /* libRCTWebSocket.a */; };
18 | 13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.m */; };
19 | 13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB11A68108700A75B9A /* LaunchScreen.xib */; };
20 | 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; };
21 | 13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
22 | 140ED2AC1D01E1AD002B40FF /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 146834041AC3E56700842450 /* libReact.a */; };
23 | 146834051AC3E58100842450 /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 146834041AC3E56700842450 /* libReact.a */; };
24 | 5E9157361DD0AC6A00FF2AA8 /* libRCTAnimation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5E9157331DD0AC6500FF2AA8 /* libRCTAnimation.a */; };
25 | 832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 832341B51AAA6A8300B99B32 /* libRCTText.a */; };
26 | A75A7E787CA340CE9CCE3396 /* libRNVectorIcons.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 2E9402464ABF42AF8F2BD0D7 /* libRNVectorIcons.a */; };
27 | FEAA548A083B4BEE831FFCA3 /* Entypo.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 3F4F30AE6BB4447BA2136B1D /* Entypo.ttf */; };
28 | 32D7C1C1B1104324A2F563B3 /* EvilIcons.ttf in Resources */ = {isa = PBXBuildFile; fileRef = D7F3120A7BF24A1AA1B1D48D /* EvilIcons.ttf */; };
29 | 21F2AC39137B47CB9FA3F54B /* FontAwesome.ttf in Resources */ = {isa = PBXBuildFile; fileRef = B4A389FD267547F78ED01696 /* FontAwesome.ttf */; };
30 | C24AD9EB7A8F4B65B7DB7CC1 /* Foundation.ttf in Resources */ = {isa = PBXBuildFile; fileRef = C6A30B4EA5604232AF87A050 /* Foundation.ttf */; };
31 | 200DE7474DA747119CD02C97 /* Ionicons.ttf in Resources */ = {isa = PBXBuildFile; fileRef = F44D7B1671D54B55BDCFB5CB /* Ionicons.ttf */; };
32 | A88D0AE39E2A4FFB9F1BB7F3 /* MaterialCommunityIcons.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 3B5ECF0F96E149F99AB9B14E /* MaterialCommunityIcons.ttf */; };
33 | 27813136D99D4FC6A4C0C83C /* MaterialIcons.ttf in Resources */ = {isa = PBXBuildFile; fileRef = A4DC32F7FFFE457BB0AB2D14 /* MaterialIcons.ttf */; };
34 | 903087577D6C4972BC988C10 /* Octicons.ttf in Resources */ = {isa = PBXBuildFile; fileRef = F5D673761891428C93754C95 /* Octicons.ttf */; };
35 | 94E298F124114187A2A898F2 /* SimpleLineIcons.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 573D82E57F86429F8BCA30FB /* SimpleLineIcons.ttf */; };
36 | 37754247697A4F70822BDB7A /* Zocial.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 8BDC3B35B9FF4A1295F472C6 /* Zocial.ttf */; };
37 | /* End PBXBuildFile section */
38 |
39 | /* Begin PBXContainerItemProxy section */
40 | 00C302AB1ABCB8CE00DB3ED1 /* PBXContainerItemProxy */ = {
41 | isa = PBXContainerItemProxy;
42 | containerPortal = 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */;
43 | proxyType = 2;
44 | remoteGlobalIDString = 134814201AA4EA6300B7C361;
45 | remoteInfo = RCTActionSheet;
46 | };
47 | 00C302B91ABCB90400DB3ED1 /* PBXContainerItemProxy */ = {
48 | isa = PBXContainerItemProxy;
49 | containerPortal = 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */;
50 | proxyType = 2;
51 | remoteGlobalIDString = 134814201AA4EA6300B7C361;
52 | remoteInfo = RCTGeolocation;
53 | };
54 | 00C302BF1ABCB91800DB3ED1 /* PBXContainerItemProxy */ = {
55 | isa = PBXContainerItemProxy;
56 | containerPortal = 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */;
57 | proxyType = 2;
58 | remoteGlobalIDString = 58B5115D1A9E6B3D00147676;
59 | remoteInfo = RCTImage;
60 | };
61 | 00C302DB1ABCB9D200DB3ED1 /* PBXContainerItemProxy */ = {
62 | isa = PBXContainerItemProxy;
63 | containerPortal = 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */;
64 | proxyType = 2;
65 | remoteGlobalIDString = 58B511DB1A9E6C8500147676;
66 | remoteInfo = RCTNetwork;
67 | };
68 | 00C302E31ABCB9EE00DB3ED1 /* PBXContainerItemProxy */ = {
69 | isa = PBXContainerItemProxy;
70 | containerPortal = 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */;
71 | proxyType = 2;
72 | remoteGlobalIDString = 832C81801AAF6DEF007FA2F7;
73 | remoteInfo = RCTVibration;
74 | };
75 | 00E356F41AD99517003FC87E /* PBXContainerItemProxy */ = {
76 | isa = PBXContainerItemProxy;
77 | containerPortal = 83CBB9F71A601CBA00E9B192 /* Project object */;
78 | proxyType = 1;
79 | remoteGlobalIDString = 13B07F861A680F5B00A75B9A;
80 | remoteInfo = RNFormsExample;
81 | };
82 | 139105C01AF99BAD00B5F7CC /* PBXContainerItemProxy */ = {
83 | isa = PBXContainerItemProxy;
84 | containerPortal = 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */;
85 | proxyType = 2;
86 | remoteGlobalIDString = 134814201AA4EA6300B7C361;
87 | remoteInfo = RCTSettings;
88 | };
89 | 139FDEF31B06529B00C62182 /* PBXContainerItemProxy */ = {
90 | isa = PBXContainerItemProxy;
91 | containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */;
92 | proxyType = 2;
93 | remoteGlobalIDString = 3C86DF461ADF2C930047B81A;
94 | remoteInfo = RCTWebSocket;
95 | };
96 | 146834031AC3E56700842450 /* PBXContainerItemProxy */ = {
97 | isa = PBXContainerItemProxy;
98 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
99 | proxyType = 2;
100 | remoteGlobalIDString = 83CBBA2E1A601D0E00E9B192;
101 | remoteInfo = React;
102 | };
103 | 3DAD3E831DF850E9000B6D8A /* PBXContainerItemProxy */ = {
104 | isa = PBXContainerItemProxy;
105 | containerPortal = 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */;
106 | proxyType = 2;
107 | remoteGlobalIDString = 2D2A283A1D9B042B00D4039D;
108 | remoteInfo = 'RCTImage-tvOS';
109 | };
110 | 3DAD3E871DF850E9000B6D8A /* PBXContainerItemProxy */ = {
111 | isa = PBXContainerItemProxy;
112 | containerPortal = 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */;
113 | proxyType = 2;
114 | remoteGlobalIDString = 2D2A28471D9B043800D4039D;
115 | remoteInfo = 'RCTLinking-tvOS';
116 | };
117 | 3DAD3E8B1DF850E9000B6D8A /* PBXContainerItemProxy */ = {
118 | isa = PBXContainerItemProxy;
119 | containerPortal = 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */;
120 | proxyType = 2;
121 | remoteGlobalIDString = 2D2A28541D9B044C00D4039D;
122 | remoteInfo = 'RCTNetwork-tvOS';
123 | };
124 | 3DAD3E8F1DF850E9000B6D8A /* PBXContainerItemProxy */ = {
125 | isa = PBXContainerItemProxy;
126 | containerPortal = 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */;
127 | proxyType = 2;
128 | remoteGlobalIDString = 2D2A28611D9B046600D4039D;
129 | remoteInfo = 'RCTSettings-tvOS';
130 | };
131 | 3DAD3E931DF850E9000B6D8A /* PBXContainerItemProxy */ = {
132 | isa = PBXContainerItemProxy;
133 | containerPortal = 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */;
134 | proxyType = 2;
135 | remoteGlobalIDString = 2D2A287B1D9B048500D4039D;
136 | remoteInfo = 'RCTText-tvOS';
137 | };
138 | 3DAD3E981DF850E9000B6D8A /* PBXContainerItemProxy */ = {
139 | isa = PBXContainerItemProxy;
140 | containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */;
141 | proxyType = 2;
142 | remoteGlobalIDString = 2D2A28881D9B049200D4039D;
143 | remoteInfo = 'RCTWebSocket-tvOS';
144 | };
145 | 3DAD3EA21DF850E9000B6D8A /* PBXContainerItemProxy */ = {
146 | isa = PBXContainerItemProxy;
147 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
148 | proxyType = 2;
149 | remoteGlobalIDString = 2D2A28131D9B038B00D4039D;
150 | remoteInfo = 'React-tvOS';
151 | };
152 | 3DAD3EA41DF850E9000B6D8A /* PBXContainerItemProxy */ = {
153 | isa = PBXContainerItemProxy;
154 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
155 | proxyType = 2;
156 | remoteGlobalIDString = 3D3C059A1DE3340900C268FA;
157 | remoteInfo = yoga;
158 | };
159 | 3DAD3EA61DF850E9000B6D8A /* PBXContainerItemProxy */ = {
160 | isa = PBXContainerItemProxy;
161 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
162 | proxyType = 2;
163 | remoteGlobalIDString = 3D3C06751DE3340C00C268FA;
164 | remoteInfo = 'yoga-tvOS';
165 | };
166 | 3DAD3EA81DF850E9000B6D8A /* PBXContainerItemProxy */ = {
167 | isa = PBXContainerItemProxy;
168 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
169 | proxyType = 2;
170 | remoteGlobalIDString = 3D3CD9251DE5FBEC00167DC4;
171 | remoteInfo = cxxreact;
172 | };
173 | 3DAD3EAA1DF850E9000B6D8A /* PBXContainerItemProxy */ = {
174 | isa = PBXContainerItemProxy;
175 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
176 | proxyType = 2;
177 | remoteGlobalIDString = 3D3CD9321DE5FBEE00167DC4;
178 | remoteInfo = 'cxxreact-tvOS';
179 | };
180 | 3DAD3EAC1DF850E9000B6D8A /* PBXContainerItemProxy */ = {
181 | isa = PBXContainerItemProxy;
182 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
183 | proxyType = 2;
184 | remoteGlobalIDString = 3D3CD90B1DE5FBD600167DC4;
185 | remoteInfo = jschelpers;
186 | };
187 | 3DAD3EAE1DF850E9000B6D8A /* PBXContainerItemProxy */ = {
188 | isa = PBXContainerItemProxy;
189 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
190 | proxyType = 2;
191 | remoteGlobalIDString = 3D3CD9181DE5FBD800167DC4;
192 | remoteInfo = 'jschelpers-tvOS';
193 | };
194 | 5E9157321DD0AC6500FF2AA8 /* PBXContainerItemProxy */ = {
195 | isa = PBXContainerItemProxy;
196 | containerPortal = 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */;
197 | proxyType = 2;
198 | remoteGlobalIDString = 134814201AA4EA6300B7C361;
199 | remoteInfo = RCTAnimation;
200 | };
201 | 5E9157341DD0AC6500FF2AA8 /* PBXContainerItemProxy */ = {
202 | isa = PBXContainerItemProxy;
203 | containerPortal = 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */;
204 | proxyType = 2;
205 | remoteGlobalIDString = 2D2A28201D9B03D100D4039D;
206 | remoteInfo = 'RCTAnimation-tvOS';
207 | };
208 | 78C398B81ACF4ADC00677621 /* PBXContainerItemProxy */ = {
209 | isa = PBXContainerItemProxy;
210 | containerPortal = 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */;
211 | proxyType = 2;
212 | remoteGlobalIDString = 134814201AA4EA6300B7C361;
213 | remoteInfo = RCTLinking;
214 | };
215 | 832341B41AAA6A8300B99B32 /* PBXContainerItemProxy */ = {
216 | isa = PBXContainerItemProxy;
217 | containerPortal = 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */;
218 | proxyType = 2;
219 | remoteGlobalIDString = 58B5119B1A9E6C1200147676;
220 | remoteInfo = RCTText;
221 | };
222 | /* End PBXContainerItemProxy section */
223 |
224 | /* Begin PBXFileReference section */
225 | 008F07F21AC5B25A0029DE68 /* main.jsbundle */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = main.jsbundle; sourceTree = ''; };
226 | 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = 'wrapper.pb-project'; name = RCTActionSheet.xcodeproj; path = '../node_modules/react-native/Libraries/ActionSheetIOS/RCTActionSheet.xcodeproj'; sourceTree = ''; };
227 | 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = 'wrapper.pb-project'; name = RCTGeolocation.xcodeproj; path = '../node_modules/react-native/Libraries/Geolocation/RCTGeolocation.xcodeproj'; sourceTree = ''; };
228 | 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = 'wrapper.pb-project'; name = RCTImage.xcodeproj; path = '../node_modules/react-native/Libraries/Image/RCTImage.xcodeproj'; sourceTree = ''; };
229 | 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = 'wrapper.pb-project'; name = RCTNetwork.xcodeproj; path = '../node_modules/react-native/Libraries/Network/RCTNetwork.xcodeproj'; sourceTree = ''; };
230 | 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = 'wrapper.pb-project'; name = RCTVibration.xcodeproj; path = '../node_modules/react-native/Libraries/Vibration/RCTVibration.xcodeproj'; sourceTree = ''; };
231 | 00E356EE1AD99517003FC87E /* RNFormsExampleTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = RNFormsExampleTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
232 | 00E356F11AD99517003FC87E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ''; };
233 | 00E356F21AD99517003FC87E /* RNFormsExampleTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RNFormsExampleTests.m; sourceTree = ''; };
234 | 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = 'wrapper.pb-project'; name = RCTSettings.xcodeproj; path = '../node_modules/react-native/Libraries/Settings/RCTSettings.xcodeproj'; sourceTree = ''; };
235 | 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = 'wrapper.pb-project'; name = RCTWebSocket.xcodeproj; path = '../node_modules/react-native/Libraries/WebSocket/RCTWebSocket.xcodeproj'; sourceTree = ''; };
236 | 13B07F961A680F5B00A75B9A /* RNFormsExample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = RNFormsExample.app; sourceTree = BUILT_PRODUCTS_DIR; };
237 | 13B07FAF1A68108700A75B9A /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = RNFormsExample/AppDelegate.h; sourceTree = ''; };
238 | 13B07FB01A68108700A75B9A /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = AppDelegate.m; path = RNFormsExample/AppDelegate.m; sourceTree = ''; };
239 | 13B07FB21A68108700A75B9A /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = ''; };
240 | 13B07FB51A68108700A75B9A /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = RNFormsExample/Images.xcassets; sourceTree = ''; };
241 | 13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = RNFormsExample/Info.plist; sourceTree = ''; };
242 | 13B07FB71A68108700A75B9A /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = RNFormsExample/main.m; sourceTree = ''; };
243 | 146833FF1AC3E56700842450 /* React.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = 'wrapper.pb-project'; name = React.xcodeproj; path = '../node_modules/react-native/React/React.xcodeproj'; sourceTree = ''; };
244 | 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = 'wrapper.pb-project'; name = RCTAnimation.xcodeproj; path = '../node_modules/react-native/Libraries/NativeAnimation/RCTAnimation.xcodeproj'; sourceTree = ''; };
245 | 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = 'wrapper.pb-project'; name = RCTLinking.xcodeproj; path = '../node_modules/react-native/Libraries/LinkingIOS/RCTLinking.xcodeproj'; sourceTree = ''; };
246 | 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = 'wrapper.pb-project'; name = RCTText.xcodeproj; path = '../node_modules/react-native/Libraries/Text/RCTText.xcodeproj'; sourceTree = ''; };
247 | 281724D44A0A4A658A38C847 /* RNVectorIcons.xcodeproj */ = {isa = PBXFileReference; name = 'RNVectorIcons.xcodeproj'; path = '../node_modules/react-native-vector-icons/RNVectorIcons.xcodeproj'; sourceTree = ''; fileEncoding = undefined; lastKnownFileType = wrapper.pb-project; explicitFileType = undefined; includeInIndex = 0; };
248 | 2E9402464ABF42AF8F2BD0D7 /* libRNVectorIcons.a */ = {isa = PBXFileReference; name = 'libRNVectorIcons.a'; path = 'libRNVectorIcons.a'; sourceTree = ''; fileEncoding = undefined; lastKnownFileType = archive.ar; explicitFileType = undefined; includeInIndex = 0; };
249 | 3F4F30AE6BB4447BA2136B1D /* Entypo.ttf */ = {isa = PBXFileReference; name = 'Entypo.ttf'; path = '../node_modules/react-native-vector-icons/Fonts/Entypo.ttf'; sourceTree = ''; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
250 | D7F3120A7BF24A1AA1B1D48D /* EvilIcons.ttf */ = {isa = PBXFileReference; name = 'EvilIcons.ttf'; path = '../node_modules/react-native-vector-icons/Fonts/EvilIcons.ttf'; sourceTree = ''; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
251 | B4A389FD267547F78ED01696 /* FontAwesome.ttf */ = {isa = PBXFileReference; name = 'FontAwesome.ttf'; path = '../node_modules/react-native-vector-icons/Fonts/FontAwesome.ttf'; sourceTree = ''; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
252 | C6A30B4EA5604232AF87A050 /* Foundation.ttf */ = {isa = PBXFileReference; name = 'Foundation.ttf'; path = '../node_modules/react-native-vector-icons/Fonts/Foundation.ttf'; sourceTree = ''; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
253 | F44D7B1671D54B55BDCFB5CB /* Ionicons.ttf */ = {isa = PBXFileReference; name = 'Ionicons.ttf'; path = '../node_modules/react-native-vector-icons/Fonts/Ionicons.ttf'; sourceTree = ''; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
254 | 3B5ECF0F96E149F99AB9B14E /* MaterialCommunityIcons.ttf */ = {isa = PBXFileReference; name = 'MaterialCommunityIcons.ttf'; path = '../node_modules/react-native-vector-icons/Fonts/MaterialCommunityIcons.ttf'; sourceTree = ''; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
255 | A4DC32F7FFFE457BB0AB2D14 /* MaterialIcons.ttf */ = {isa = PBXFileReference; name = 'MaterialIcons.ttf'; path = '../node_modules/react-native-vector-icons/Fonts/MaterialIcons.ttf'; sourceTree = ''; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
256 | F5D673761891428C93754C95 /* Octicons.ttf */ = {isa = PBXFileReference; name = 'Octicons.ttf'; path = '../node_modules/react-native-vector-icons/Fonts/Octicons.ttf'; sourceTree = ''; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
257 | 573D82E57F86429F8BCA30FB /* SimpleLineIcons.ttf */ = {isa = PBXFileReference; name = 'SimpleLineIcons.ttf'; path = '../node_modules/react-native-vector-icons/Fonts/SimpleLineIcons.ttf'; sourceTree = ''; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
258 | 8BDC3B35B9FF4A1295F472C6 /* Zocial.ttf */ = {isa = PBXFileReference; name = 'Zocial.ttf'; path = '../node_modules/react-native-vector-icons/Fonts/Zocial.ttf'; sourceTree = ''; fileEncoding = undefined; lastKnownFileType = unknown; explicitFileType = undefined; includeInIndex = 0; };
259 | /* End PBXFileReference section */
260 |
261 | /* Begin PBXFrameworksBuildPhase section */
262 | 00E356EB1AD99517003FC87E /* Frameworks */ = {
263 | isa = PBXFrameworksBuildPhase;
264 | buildActionMask = 2147483647;
265 | files = (
266 | 140ED2AC1D01E1AD002B40FF /* libReact.a in Frameworks */,
267 | );
268 | runOnlyForDeploymentPostprocessing = 0;
269 | };
270 | 13B07F8C1A680F5B00A75B9A /* Frameworks */ = {
271 | isa = PBXFrameworksBuildPhase;
272 | buildActionMask = 2147483647;
273 | files = (
274 | 5E9157361DD0AC6A00FF2AA8 /* libRCTAnimation.a in Frameworks */,
275 | 146834051AC3E58100842450 /* libReact.a in Frameworks */,
276 | 00C302E51ABCBA2D00DB3ED1 /* libRCTActionSheet.a in Frameworks */,
277 | 00C302E71ABCBA2D00DB3ED1 /* libRCTGeolocation.a in Frameworks */,
278 | 00C302E81ABCBA2D00DB3ED1 /* libRCTImage.a in Frameworks */,
279 | 133E29F31AD74F7200F7D852 /* libRCTLinking.a in Frameworks */,
280 | 00C302E91ABCBA2D00DB3ED1 /* libRCTNetwork.a in Frameworks */,
281 | 139105C61AF99C1200B5F7CC /* libRCTSettings.a in Frameworks */,
282 | 832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */,
283 | 00C302EA1ABCBA2D00DB3ED1 /* libRCTVibration.a in Frameworks */,
284 | 139FDEF61B0652A700C62182 /* libRCTWebSocket.a in Frameworks */,
285 | A75A7E787CA340CE9CCE3396 /* libRNVectorIcons.a in Frameworks */,
286 | );
287 | runOnlyForDeploymentPostprocessing = 0;
288 | };
289 | /* End PBXFrameworksBuildPhase section */
290 |
291 | /* Begin PBXGroup section */
292 | 00C302A81ABCB8CE00DB3ED1 /* Products */ = {
293 | isa = PBXGroup;
294 | children = (
295 | 00C302AC1ABCB8CE00DB3ED1 /* libRCTActionSheet.a */,
296 | );
297 | name = Products;
298 | sourceTree = '';
299 | };
300 | 00C302B61ABCB90400DB3ED1 /* Products */ = {
301 | isa = PBXGroup;
302 | children = (
303 | 00C302BA1ABCB90400DB3ED1 /* libRCTGeolocation.a */,
304 | );
305 | name = Products;
306 | sourceTree = '';
307 | };
308 | 00C302BC1ABCB91800DB3ED1 /* Products */ = {
309 | isa = PBXGroup;
310 | children = (
311 | 00C302C01ABCB91800DB3ED1 /* libRCTImage.a */,
312 | 3DAD3E841DF850E9000B6D8A /* libRCTImage-tvOS.a */,
313 | );
314 | name = Products;
315 | sourceTree = '';
316 | };
317 | 00C302D41ABCB9D200DB3ED1 /* Products */ = {
318 | isa = PBXGroup;
319 | children = (
320 | 00C302DC1ABCB9D200DB3ED1 /* libRCTNetwork.a */,
321 | 3DAD3E8C1DF850E9000B6D8A /* libRCTNetwork-tvOS.a */,
322 | );
323 | name = Products;
324 | sourceTree = '';
325 | };
326 | 00C302E01ABCB9EE00DB3ED1 /* Products */ = {
327 | isa = PBXGroup;
328 | children = (
329 | 00C302E41ABCB9EE00DB3ED1 /* libRCTVibration.a */,
330 | );
331 | name = Products;
332 | sourceTree = '';
333 | };
334 | 00E356EF1AD99517003FC87E /* RNFormsExampleTests */ = {
335 | isa = PBXGroup;
336 | children = (
337 | 00E356F21AD99517003FC87E /* RNFormsExampleTests.m */,
338 | 00E356F01AD99517003FC87E /* Supporting Files */,
339 | );
340 | path = RNFormsExampleTests;
341 | sourceTree = '';
342 | };
343 | 00E356F01AD99517003FC87E /* Supporting Files */ = {
344 | isa = PBXGroup;
345 | children = (
346 | 00E356F11AD99517003FC87E /* Info.plist */,
347 | );
348 | name = 'Supporting Files';
349 | sourceTree = '';
350 | };
351 | 139105B71AF99BAD00B5F7CC /* Products */ = {
352 | isa = PBXGroup;
353 | children = (
354 | 139105C11AF99BAD00B5F7CC /* libRCTSettings.a */,
355 | 3DAD3E901DF850E9000B6D8A /* libRCTSettings-tvOS.a */,
356 | );
357 | name = Products;
358 | sourceTree = '';
359 | };
360 | 139FDEE71B06529A00C62182 /* Products */ = {
361 | isa = PBXGroup;
362 | children = (
363 | 139FDEF41B06529B00C62182 /* libRCTWebSocket.a */,
364 | 3DAD3E991DF850E9000B6D8A /* libRCTWebSocket-tvOS.a */,
365 | );
366 | name = Products;
367 | sourceTree = '';
368 | };
369 | 13B07FAE1A68108700A75B9A /* RNFormsExample */ = {
370 | isa = PBXGroup;
371 | children = (
372 | 008F07F21AC5B25A0029DE68 /* main.jsbundle */,
373 | 13B07FAF1A68108700A75B9A /* AppDelegate.h */,
374 | 13B07FB01A68108700A75B9A /* AppDelegate.m */,
375 | 13B07FB51A68108700A75B9A /* Images.xcassets */,
376 | 13B07FB61A68108700A75B9A /* Info.plist */,
377 | 13B07FB11A68108700A75B9A /* LaunchScreen.xib */,
378 | 13B07FB71A68108700A75B9A /* main.m */,
379 | );
380 | name = RNFormsExample;
381 | sourceTree = '';
382 | };
383 | 146834001AC3E56700842450 /* Products */ = {
384 | isa = PBXGroup;
385 | children = (
386 | 146834041AC3E56700842450 /* libReact.a */,
387 | 3DAD3EA31DF850E9000B6D8A /* libReact.a */,
388 | 3DAD3EA51DF850E9000B6D8A /* libyoga.a */,
389 | 3DAD3EA71DF850E9000B6D8A /* libyoga.a */,
390 | 3DAD3EA91DF850E9000B6D8A /* libcxxreact.a */,
391 | 3DAD3EAB1DF850E9000B6D8A /* libcxxreact.a */,
392 | 3DAD3EAD1DF850E9000B6D8A /* libjschelpers.a */,
393 | 3DAD3EAF1DF850E9000B6D8A /* libjschelpers.a */,
394 | );
395 | name = Products;
396 | sourceTree = '';
397 | };
398 | 5E91572E1DD0AC6500FF2AA8 /* Products */ = {
399 | isa = PBXGroup;
400 | children = (
401 | 5E9157331DD0AC6500FF2AA8 /* libRCTAnimation.a */,
402 | 5E9157351DD0AC6500FF2AA8 /* libRCTAnimation-tvOS.a */,
403 | );
404 | name = Products;
405 | sourceTree = '';
406 | };
407 | 78C398B11ACF4ADC00677621 /* Products */ = {
408 | isa = PBXGroup;
409 | children = (
410 | 78C398B91ACF4ADC00677621 /* libRCTLinking.a */,
411 | 3DAD3E881DF850E9000B6D8A /* libRCTLinking-tvOS.a */,
412 | );
413 | name = Products;
414 | sourceTree = '';
415 | };
416 | 832341AE1AAA6A7D00B99B32 /* Libraries */ = {
417 | isa = PBXGroup;
418 | children = (
419 | 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */,
420 | 146833FF1AC3E56700842450 /* React.xcodeproj */,
421 | 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */,
422 | 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */,
423 | 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */,
424 | 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */,
425 | 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */,
426 | 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */,
427 | 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */,
428 | 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */,
429 | 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */,
430 | 281724D44A0A4A658A38C847 /* RNVectorIcons.xcodeproj */,
431 | );
432 | name = Libraries;
433 | sourceTree = '';
434 | };
435 | 832341B11AAA6A8300B99B32 /* Products */ = {
436 | isa = PBXGroup;
437 | children = (
438 | 832341B51AAA6A8300B99B32 /* libRCTText.a */,
439 | 3DAD3E941DF850E9000B6D8A /* libRCTText-tvOS.a */,
440 | );
441 | name = Products;
442 | sourceTree = '';
443 | };
444 | 83CBB9F61A601CBA00E9B192 = {
445 | isa = PBXGroup;
446 | children = (
447 | 13B07FAE1A68108700A75B9A /* RNFormsExample */,
448 | 832341AE1AAA6A7D00B99B32 /* Libraries */,
449 | 00E356EF1AD99517003FC87E /* RNFormsExampleTests */,
450 | 83CBBA001A601CBA00E9B192 /* Products */,
451 | 7333D8D395D5435C9708225E /* Resources */,
452 | );
453 | indentWidth = 2;
454 | sourceTree = '';
455 | tabWidth = 2;
456 | };
457 | 83CBBA001A601CBA00E9B192 /* Products */ = {
458 | isa = PBXGroup;
459 | children = (
460 | 13B07F961A680F5B00A75B9A /* RNFormsExample.app */,
461 | 00E356EE1AD99517003FC87E /* RNFormsExampleTests.xctest */,
462 | );
463 | name = Products;
464 | sourceTree = '';
465 | };
466 | 7333D8D395D5435C9708225E /* Resources */ = {
467 | isa = PBXGroup;
468 | children = (
469 | 3F4F30AE6BB4447BA2136B1D /* Entypo.ttf */,
470 | D7F3120A7BF24A1AA1B1D48D /* EvilIcons.ttf */,
471 | B4A389FD267547F78ED01696 /* FontAwesome.ttf */,
472 | C6A30B4EA5604232AF87A050 /* Foundation.ttf */,
473 | F44D7B1671D54B55BDCFB5CB /* Ionicons.ttf */,
474 | 3B5ECF0F96E149F99AB9B14E /* MaterialCommunityIcons.ttf */,
475 | A4DC32F7FFFE457BB0AB2D14 /* MaterialIcons.ttf */,
476 | F5D673761891428C93754C95 /* Octicons.ttf */,
477 | 573D82E57F86429F8BCA30FB /* SimpleLineIcons.ttf */,
478 | 8BDC3B35B9FF4A1295F472C6 /* Zocial.ttf */,
479 | );
480 | name = Resources;
481 | path = '';
482 | sourceTree = '';
483 | };
484 | /* End PBXGroup section */
485 |
486 | /* Begin PBXNativeTarget section */
487 | 00E356ED1AD99517003FC87E /* RNFormsExampleTests */ = {
488 | isa = PBXNativeTarget;
489 | buildConfigurationList = 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget 'RNFormsExampleTests' */;
490 | buildPhases = (
491 | 00E356EA1AD99517003FC87E /* Sources */,
492 | 00E356EB1AD99517003FC87E /* Frameworks */,
493 | 00E356EC1AD99517003FC87E /* Resources */,
494 | );
495 | buildRules = (
496 | );
497 | dependencies = (
498 | 00E356F51AD99517003FC87E /* PBXTargetDependency */,
499 | );
500 | name = RNFormsExampleTests;
501 | productName = RNFormsExampleTests;
502 | productReference = 00E356EE1AD99517003FC87E /* RNFormsExampleTests.xctest */;
503 | productType = 'com.apple.product-type.bundle.unit-test';
504 | };
505 | 13B07F861A680F5B00A75B9A /* RNFormsExample */ = {
506 | isa = PBXNativeTarget;
507 | buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget 'RNFormsExample' */;
508 | buildPhases = (
509 | 13B07F871A680F5B00A75B9A /* Sources */,
510 | 13B07F8C1A680F5B00A75B9A /* Frameworks */,
511 | 13B07F8E1A680F5B00A75B9A /* Resources */,
512 | 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */,
513 | );
514 | buildRules = (
515 | );
516 | dependencies = (
517 | );
518 | name = RNFormsExample;
519 | productName = 'Hello World';
520 | productReference = 13B07F961A680F5B00A75B9A /* RNFormsExample.app */;
521 | productType = 'com.apple.product-type.application';
522 | };
523 | /* End PBXNativeTarget section */
524 |
525 | /* Begin PBXProject section */
526 | 83CBB9F71A601CBA00E9B192 /* Project object */ = {
527 | isa = PBXProject;
528 | attributes = {
529 | LastUpgradeCheck = 610;
530 | ORGANIZATIONNAME = Facebook;
531 | TargetAttributes = {
532 | 00E356ED1AD99517003FC87E = {
533 | CreatedOnToolsVersion = 6.2;
534 | TestTargetID = 13B07F861A680F5B00A75B9A;
535 | };
536 | };
537 | };
538 | buildConfigurationList = 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject 'RNFormsExample' */;
539 | compatibilityVersion = 'Xcode 3.2';
540 | developmentRegion = English;
541 | hasScannedForEncodings = 0;
542 | knownRegions = (
543 | en,
544 | Base,
545 | );
546 | mainGroup = 83CBB9F61A601CBA00E9B192;
547 | productRefGroup = 83CBBA001A601CBA00E9B192 /* Products */;
548 | projectDirPath = '';
549 | projectReferences = (
550 | {
551 | ProductGroup = 00C302A81ABCB8CE00DB3ED1 /* Products */;
552 | ProjectRef = 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */;
553 | },
554 | {
555 | ProductGroup = 5E91572E1DD0AC6500FF2AA8 /* Products */;
556 | ProjectRef = 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */;
557 | },
558 | {
559 | ProductGroup = 00C302B61ABCB90400DB3ED1 /* Products */;
560 | ProjectRef = 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */;
561 | },
562 | {
563 | ProductGroup = 00C302BC1ABCB91800DB3ED1 /* Products */;
564 | ProjectRef = 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */;
565 | },
566 | {
567 | ProductGroup = 78C398B11ACF4ADC00677621 /* Products */;
568 | ProjectRef = 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */;
569 | },
570 | {
571 | ProductGroup = 00C302D41ABCB9D200DB3ED1 /* Products */;
572 | ProjectRef = 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */;
573 | },
574 | {
575 | ProductGroup = 139105B71AF99BAD00B5F7CC /* Products */;
576 | ProjectRef = 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */;
577 | },
578 | {
579 | ProductGroup = 832341B11AAA6A8300B99B32 /* Products */;
580 | ProjectRef = 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */;
581 | },
582 | {
583 | ProductGroup = 00C302E01ABCB9EE00DB3ED1 /* Products */;
584 | ProjectRef = 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */;
585 | },
586 | {
587 | ProductGroup = 139FDEE71B06529A00C62182 /* Products */;
588 | ProjectRef = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */;
589 | },
590 | {
591 | ProductGroup = 146834001AC3E56700842450 /* Products */;
592 | ProjectRef = 146833FF1AC3E56700842450 /* React.xcodeproj */;
593 | },
594 | );
595 | projectRoot = '';
596 | targets = (
597 | 13B07F861A680F5B00A75B9A /* RNFormsExample */,
598 | 00E356ED1AD99517003FC87E /* RNFormsExampleTests */,
599 | );
600 | };
601 | /* End PBXProject section */
602 |
603 | /* Begin PBXReferenceProxy section */
604 | 00C302AC1ABCB8CE00DB3ED1 /* libRCTActionSheet.a */ = {
605 | isa = PBXReferenceProxy;
606 | fileType = archive.ar;
607 | path = libRCTActionSheet.a;
608 | remoteRef = 00C302AB1ABCB8CE00DB3ED1 /* PBXContainerItemProxy */;
609 | sourceTree = BUILT_PRODUCTS_DIR;
610 | };
611 | 00C302BA1ABCB90400DB3ED1 /* libRCTGeolocation.a */ = {
612 | isa = PBXReferenceProxy;
613 | fileType = archive.ar;
614 | path = libRCTGeolocation.a;
615 | remoteRef = 00C302B91ABCB90400DB3ED1 /* PBXContainerItemProxy */;
616 | sourceTree = BUILT_PRODUCTS_DIR;
617 | };
618 | 00C302C01ABCB91800DB3ED1 /* libRCTImage.a */ = {
619 | isa = PBXReferenceProxy;
620 | fileType = archive.ar;
621 | path = libRCTImage.a;
622 | remoteRef = 00C302BF1ABCB91800DB3ED1 /* PBXContainerItemProxy */;
623 | sourceTree = BUILT_PRODUCTS_DIR;
624 | };
625 | 00C302DC1ABCB9D200DB3ED1 /* libRCTNetwork.a */ = {
626 | isa = PBXReferenceProxy;
627 | fileType = archive.ar;
628 | path = libRCTNetwork.a;
629 | remoteRef = 00C302DB1ABCB9D200DB3ED1 /* PBXContainerItemProxy */;
630 | sourceTree = BUILT_PRODUCTS_DIR;
631 | };
632 | 00C302E41ABCB9EE00DB3ED1 /* libRCTVibration.a */ = {
633 | isa = PBXReferenceProxy;
634 | fileType = archive.ar;
635 | path = libRCTVibration.a;
636 | remoteRef = 00C302E31ABCB9EE00DB3ED1 /* PBXContainerItemProxy */;
637 | sourceTree = BUILT_PRODUCTS_DIR;
638 | };
639 | 139105C11AF99BAD00B5F7CC /* libRCTSettings.a */ = {
640 | isa = PBXReferenceProxy;
641 | fileType = archive.ar;
642 | path = libRCTSettings.a;
643 | remoteRef = 139105C01AF99BAD00B5F7CC /* PBXContainerItemProxy */;
644 | sourceTree = BUILT_PRODUCTS_DIR;
645 | };
646 | 139FDEF41B06529B00C62182 /* libRCTWebSocket.a */ = {
647 | isa = PBXReferenceProxy;
648 | fileType = archive.ar;
649 | path = libRCTWebSocket.a;
650 | remoteRef = 139FDEF31B06529B00C62182 /* PBXContainerItemProxy */;
651 | sourceTree = BUILT_PRODUCTS_DIR;
652 | };
653 | 146834041AC3E56700842450 /* libReact.a */ = {
654 | isa = PBXReferenceProxy;
655 | fileType = archive.ar;
656 | path = libReact.a;
657 | remoteRef = 146834031AC3E56700842450 /* PBXContainerItemProxy */;
658 | sourceTree = BUILT_PRODUCTS_DIR;
659 | };
660 | 3DAD3E841DF850E9000B6D8A /* libRCTImage-tvOS.a */ = {
661 | isa = PBXReferenceProxy;
662 | fileType = archive.ar;
663 | path = 'libRCTImage-tvOS.a';
664 | remoteRef = 3DAD3E831DF850E9000B6D8A /* PBXContainerItemProxy */;
665 | sourceTree = BUILT_PRODUCTS_DIR;
666 | };
667 | 3DAD3E881DF850E9000B6D8A /* libRCTLinking-tvOS.a */ = {
668 | isa = PBXReferenceProxy;
669 | fileType = archive.ar;
670 | path = 'libRCTLinking-tvOS.a';
671 | remoteRef = 3DAD3E871DF850E9000B6D8A /* PBXContainerItemProxy */;
672 | sourceTree = BUILT_PRODUCTS_DIR;
673 | };
674 | 3DAD3E8C1DF850E9000B6D8A /* libRCTNetwork-tvOS.a */ = {
675 | isa = PBXReferenceProxy;
676 | fileType = archive.ar;
677 | path = 'libRCTNetwork-tvOS.a';
678 | remoteRef = 3DAD3E8B1DF850E9000B6D8A /* PBXContainerItemProxy */;
679 | sourceTree = BUILT_PRODUCTS_DIR;
680 | };
681 | 3DAD3E901DF850E9000B6D8A /* libRCTSettings-tvOS.a */ = {
682 | isa = PBXReferenceProxy;
683 | fileType = archive.ar;
684 | path = 'libRCTSettings-tvOS.a';
685 | remoteRef = 3DAD3E8F1DF850E9000B6D8A /* PBXContainerItemProxy */;
686 | sourceTree = BUILT_PRODUCTS_DIR;
687 | };
688 | 3DAD3E941DF850E9000B6D8A /* libRCTText-tvOS.a */ = {
689 | isa = PBXReferenceProxy;
690 | fileType = archive.ar;
691 | path = 'libRCTText-tvOS.a';
692 | remoteRef = 3DAD3E931DF850E9000B6D8A /* PBXContainerItemProxy */;
693 | sourceTree = BUILT_PRODUCTS_DIR;
694 | };
695 | 3DAD3E991DF850E9000B6D8A /* libRCTWebSocket-tvOS.a */ = {
696 | isa = PBXReferenceProxy;
697 | fileType = archive.ar;
698 | path = 'libRCTWebSocket-tvOS.a';
699 | remoteRef = 3DAD3E981DF850E9000B6D8A /* PBXContainerItemProxy */;
700 | sourceTree = BUILT_PRODUCTS_DIR;
701 | };
702 | 3DAD3EA31DF850E9000B6D8A /* libReact.a */ = {
703 | isa = PBXReferenceProxy;
704 | fileType = archive.ar;
705 | path = libReact.a;
706 | remoteRef = 3DAD3EA21DF850E9000B6D8A /* PBXContainerItemProxy */;
707 | sourceTree = BUILT_PRODUCTS_DIR;
708 | };
709 | 3DAD3EA51DF850E9000B6D8A /* libyoga.a */ = {
710 | isa = PBXReferenceProxy;
711 | fileType = archive.ar;
712 | path = libyoga.a;
713 | remoteRef = 3DAD3EA41DF850E9000B6D8A /* PBXContainerItemProxy */;
714 | sourceTree = BUILT_PRODUCTS_DIR;
715 | };
716 | 3DAD3EA71DF850E9000B6D8A /* libyoga.a */ = {
717 | isa = PBXReferenceProxy;
718 | fileType = archive.ar;
719 | path = libyoga.a;
720 | remoteRef = 3DAD3EA61DF850E9000B6D8A /* PBXContainerItemProxy */;
721 | sourceTree = BUILT_PRODUCTS_DIR;
722 | };
723 | 3DAD3EA91DF850E9000B6D8A /* libcxxreact.a */ = {
724 | isa = PBXReferenceProxy;
725 | fileType = archive.ar;
726 | path = libcxxreact.a;
727 | remoteRef = 3DAD3EA81DF850E9000B6D8A /* PBXContainerItemProxy */;
728 | sourceTree = BUILT_PRODUCTS_DIR;
729 | };
730 | 3DAD3EAB1DF850E9000B6D8A /* libcxxreact.a */ = {
731 | isa = PBXReferenceProxy;
732 | fileType = archive.ar;
733 | path = libcxxreact.a;
734 | remoteRef = 3DAD3EAA1DF850E9000B6D8A /* PBXContainerItemProxy */;
735 | sourceTree = BUILT_PRODUCTS_DIR;
736 | };
737 | 3DAD3EAD1DF850E9000B6D8A /* libjschelpers.a */ = {
738 | isa = PBXReferenceProxy;
739 | fileType = archive.ar;
740 | path = libjschelpers.a;
741 | remoteRef = 3DAD3EAC1DF850E9000B6D8A /* PBXContainerItemProxy */;
742 | sourceTree = BUILT_PRODUCTS_DIR;
743 | };
744 | 3DAD3EAF1DF850E9000B6D8A /* libjschelpers.a */ = {
745 | isa = PBXReferenceProxy;
746 | fileType = archive.ar;
747 | path = libjschelpers.a;
748 | remoteRef = 3DAD3EAE1DF850E9000B6D8A /* PBXContainerItemProxy */;
749 | sourceTree = BUILT_PRODUCTS_DIR;
750 | };
751 | 5E9157331DD0AC6500FF2AA8 /* libRCTAnimation.a */ = {
752 | isa = PBXReferenceProxy;
753 | fileType = archive.ar;
754 | path = libRCTAnimation.a;
755 | remoteRef = 5E9157321DD0AC6500FF2AA8 /* PBXContainerItemProxy */;
756 | sourceTree = BUILT_PRODUCTS_DIR;
757 | };
758 | 5E9157351DD0AC6500FF2AA8 /* libRCTAnimation-tvOS.a */ = {
759 | isa = PBXReferenceProxy;
760 | fileType = archive.ar;
761 | path = 'libRCTAnimation-tvOS.a';
762 | remoteRef = 5E9157341DD0AC6500FF2AA8 /* PBXContainerItemProxy */;
763 | sourceTree = BUILT_PRODUCTS_DIR;
764 | };
765 | 78C398B91ACF4ADC00677621 /* libRCTLinking.a */ = {
766 | isa = PBXReferenceProxy;
767 | fileType = archive.ar;
768 | path = libRCTLinking.a;
769 | remoteRef = 78C398B81ACF4ADC00677621 /* PBXContainerItemProxy */;
770 | sourceTree = BUILT_PRODUCTS_DIR;
771 | };
772 | 832341B51AAA6A8300B99B32 /* libRCTText.a */ = {
773 | isa = PBXReferenceProxy;
774 | fileType = archive.ar;
775 | path = libRCTText.a;
776 | remoteRef = 832341B41AAA6A8300B99B32 /* PBXContainerItemProxy */;
777 | sourceTree = BUILT_PRODUCTS_DIR;
778 | };
779 | /* End PBXReferenceProxy section */
780 |
781 | /* Begin PBXResourcesBuildPhase section */
782 | 00E356EC1AD99517003FC87E /* Resources */ = {
783 | isa = PBXResourcesBuildPhase;
784 | buildActionMask = 2147483647;
785 | files = (
786 | );
787 | runOnlyForDeploymentPostprocessing = 0;
788 | };
789 | 13B07F8E1A680F5B00A75B9A /* Resources */ = {
790 | isa = PBXResourcesBuildPhase;
791 | buildActionMask = 2147483647;
792 | files = (
793 | 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */,
794 | 13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */,
795 | FEAA548A083B4BEE831FFCA3 /* Entypo.ttf in Resources */,
796 | 32D7C1C1B1104324A2F563B3 /* EvilIcons.ttf in Resources */,
797 | 21F2AC39137B47CB9FA3F54B /* FontAwesome.ttf in Resources */,
798 | C24AD9EB7A8F4B65B7DB7CC1 /* Foundation.ttf in Resources */,
799 | 200DE7474DA747119CD02C97 /* Ionicons.ttf in Resources */,
800 | A88D0AE39E2A4FFB9F1BB7F3 /* MaterialCommunityIcons.ttf in Resources */,
801 | 27813136D99D4FC6A4C0C83C /* MaterialIcons.ttf in Resources */,
802 | 903087577D6C4972BC988C10 /* Octicons.ttf in Resources */,
803 | 94E298F124114187A2A898F2 /* SimpleLineIcons.ttf in Resources */,
804 | 37754247697A4F70822BDB7A /* Zocial.ttf in Resources */,
805 | );
806 | runOnlyForDeploymentPostprocessing = 0;
807 | };
808 | /* End PBXResourcesBuildPhase section */
809 |
810 | /* Begin PBXShellScriptBuildPhase section */
811 | 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */ = {
812 | isa = PBXShellScriptBuildPhase;
813 | buildActionMask = 2147483647;
814 | files = (
815 | );
816 | inputPaths = (
817 | );
818 | name = 'Bundle React Native code and images';
819 | outputPaths = (
820 | );
821 | runOnlyForDeploymentPostprocessing = 0;
822 | shellPath = /bin/sh;
823 | shellScript = 'export NODE_BINARY=node\n../node_modules/react-native/packager/react-native-xcode.sh';
824 | };
825 | /* End PBXShellScriptBuildPhase section */
826 |
827 | /* Begin PBXSourcesBuildPhase section */
828 | 00E356EA1AD99517003FC87E /* Sources */ = {
829 | isa = PBXSourcesBuildPhase;
830 | buildActionMask = 2147483647;
831 | files = (
832 | 00E356F31AD99517003FC87E /* RNFormsExampleTests.m in Sources */,
833 | );
834 | runOnlyForDeploymentPostprocessing = 0;
835 | };
836 | 13B07F871A680F5B00A75B9A /* Sources */ = {
837 | isa = PBXSourcesBuildPhase;
838 | buildActionMask = 2147483647;
839 | files = (
840 | 13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */,
841 | 13B07FC11A68108700A75B9A /* main.m in Sources */,
842 | );
843 | runOnlyForDeploymentPostprocessing = 0;
844 | };
845 | /* End PBXSourcesBuildPhase section */
846 |
847 | /* Begin PBXTargetDependency section */
848 | 00E356F51AD99517003FC87E /* PBXTargetDependency */ = {
849 | isa = PBXTargetDependency;
850 | target = 13B07F861A680F5B00A75B9A /* RNFormsExample */;
851 | targetProxy = 00E356F41AD99517003FC87E /* PBXContainerItemProxy */;
852 | };
853 | /* End PBXTargetDependency section */
854 |
855 | /* Begin PBXVariantGroup section */
856 | 13B07FB11A68108700A75B9A /* LaunchScreen.xib */ = {
857 | isa = PBXVariantGroup;
858 | children = (
859 | 13B07FB21A68108700A75B9A /* Base */,
860 | );
861 | name = LaunchScreen.xib;
862 | path = RNFormsExample;
863 | sourceTree = '';
864 | };
865 | /* End PBXVariantGroup section */
866 |
867 | /* Begin XCBuildConfiguration section */
868 | 00E356F61AD99517003FC87E /* Debug */ = {
869 | isa = XCBuildConfiguration;
870 | buildSettings = {
871 | BUNDLE_LOADER = '$(TEST_HOST)';
872 | GCC_PREPROCESSOR_DEFINITIONS = (
873 | 'DEBUG=1',
874 | '$(inherited)',
875 | );
876 | INFOPLIST_FILE = RNFormsExampleTests/Info.plist;
877 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
878 | LD_RUNPATH_SEARCH_PATHS = '$(inherited) @executable_path/Frameworks @loader_path/Frameworks';
879 | PRODUCT_NAME = '$(TARGET_NAME)';
880 | TEST_HOST = '$(BUILT_PRODUCTS_DIR)/RNFormsExample.app/RNFormsExample';
881 | LIBRARY_SEARCH_PATHS = (
882 | '$(inherited)',
883 | '\'$(SRCROOT)/$(TARGET_NAME)\'',
884 | );
885 | };
886 | name = Debug;
887 | };
888 | 00E356F71AD99517003FC87E /* Release */ = {
889 | isa = XCBuildConfiguration;
890 | buildSettings = {
891 | BUNDLE_LOADER = '$(TEST_HOST)';
892 | COPY_PHASE_STRIP = NO;
893 | INFOPLIST_FILE = RNFormsExampleTests/Info.plist;
894 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
895 | LD_RUNPATH_SEARCH_PATHS = '$(inherited) @executable_path/Frameworks @loader_path/Frameworks';
896 | PRODUCT_NAME = '$(TARGET_NAME)';
897 | TEST_HOST = '$(BUILT_PRODUCTS_DIR)/RNFormsExample.app/RNFormsExample';
898 | LIBRARY_SEARCH_PATHS = (
899 | '$(inherited)',
900 | '\'$(SRCROOT)/$(TARGET_NAME)\'',
901 | );
902 | };
903 | name = Release;
904 | };
905 | 13B07F941A680F5B00A75B9A /* Debug */ = {
906 | isa = XCBuildConfiguration;
907 | buildSettings = {
908 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
909 | CURRENT_PROJECT_VERSION = 1;
910 | DEAD_CODE_STRIPPING = NO;
911 | INFOPLIST_FILE = RNFormsExample/Info.plist;
912 | LD_RUNPATH_SEARCH_PATHS = '$(inherited) @executable_path/Frameworks';
913 | OTHER_LDFLAGS = (
914 | '$(inherited)',
915 | '-ObjC',
916 | '-lc++',
917 | );
918 | PRODUCT_NAME = RNFormsExample;
919 | VERSIONING_SYSTEM = 'apple-generic';
920 | };
921 | name = Debug;
922 | };
923 | 13B07F951A680F5B00A75B9A /* Release */ = {
924 | isa = XCBuildConfiguration;
925 | buildSettings = {
926 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
927 | CURRENT_PROJECT_VERSION = 1;
928 | INFOPLIST_FILE = RNFormsExample/Info.plist;
929 | LD_RUNPATH_SEARCH_PATHS = '$(inherited) @executable_path/Frameworks';
930 | OTHER_LDFLAGS = (
931 | '$(inherited)',
932 | '-ObjC',
933 | '-lc++',
934 | );
935 | PRODUCT_NAME = RNFormsExample;
936 | VERSIONING_SYSTEM = 'apple-generic';
937 | };
938 | name = Release;
939 | };
940 | 83CBBA201A601CBA00E9B192 /* Debug */ = {
941 | isa = XCBuildConfiguration;
942 | buildSettings = {
943 | ALWAYS_SEARCH_USER_PATHS = NO;
944 | CLANG_CXX_LANGUAGE_STANDARD = 'gnu++0x';
945 | CLANG_CXX_LIBRARY = 'libc++';
946 | CLANG_ENABLE_MODULES = YES;
947 | CLANG_ENABLE_OBJC_ARC = YES;
948 | CLANG_WARN_BOOL_CONVERSION = YES;
949 | CLANG_WARN_CONSTANT_CONVERSION = YES;
950 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
951 | CLANG_WARN_EMPTY_BODY = YES;
952 | CLANG_WARN_ENUM_CONVERSION = YES;
953 | CLANG_WARN_INT_CONVERSION = YES;
954 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
955 | CLANG_WARN_UNREACHABLE_CODE = YES;
956 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
957 | 'CODE_SIGN_IDENTITY[sdk=iphoneos*]' = 'iPhone Developer';
958 | COPY_PHASE_STRIP = NO;
959 | ENABLE_STRICT_OBJC_MSGSEND = YES;
960 | GCC_C_LANGUAGE_STANDARD = gnu99;
961 | GCC_DYNAMIC_NO_PIC = NO;
962 | GCC_OPTIMIZATION_LEVEL = 0;
963 | GCC_PREPROCESSOR_DEFINITIONS = (
964 | 'DEBUG=1',
965 | '$(inherited)',
966 | );
967 | GCC_SYMBOLS_PRIVATE_EXTERN = NO;
968 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
969 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
970 | GCC_WARN_UNDECLARED_SELECTOR = YES;
971 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
972 | GCC_WARN_UNUSED_FUNCTION = YES;
973 | GCC_WARN_UNUSED_VARIABLE = YES;
974 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
975 | MTL_ENABLE_DEBUG_INFO = YES;
976 | ONLY_ACTIVE_ARCH = YES;
977 | SDKROOT = iphoneos;
978 | };
979 | name = Debug;
980 | };
981 | 83CBBA211A601CBA00E9B192 /* Release */ = {
982 | isa = XCBuildConfiguration;
983 | buildSettings = {
984 | ALWAYS_SEARCH_USER_PATHS = NO;
985 | CLANG_CXX_LANGUAGE_STANDARD = 'gnu++0x';
986 | CLANG_CXX_LIBRARY = 'libc++';
987 | CLANG_ENABLE_MODULES = YES;
988 | CLANG_ENABLE_OBJC_ARC = YES;
989 | CLANG_WARN_BOOL_CONVERSION = YES;
990 | CLANG_WARN_CONSTANT_CONVERSION = YES;
991 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
992 | CLANG_WARN_EMPTY_BODY = YES;
993 | CLANG_WARN_ENUM_CONVERSION = YES;
994 | CLANG_WARN_INT_CONVERSION = YES;
995 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
996 | CLANG_WARN_UNREACHABLE_CODE = YES;
997 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
998 | 'CODE_SIGN_IDENTITY[sdk=iphoneos*]' = 'iPhone Developer';
999 | COPY_PHASE_STRIP = YES;
1000 | ENABLE_NS_ASSERTIONS = NO;
1001 | ENABLE_STRICT_OBJC_MSGSEND = YES;
1002 | GCC_C_LANGUAGE_STANDARD = gnu99;
1003 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
1004 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
1005 | GCC_WARN_UNDECLARED_SELECTOR = YES;
1006 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
1007 | GCC_WARN_UNUSED_FUNCTION = YES;
1008 | GCC_WARN_UNUSED_VARIABLE = YES;
1009 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
1010 | MTL_ENABLE_DEBUG_INFO = NO;
1011 | SDKROOT = iphoneos;
1012 | VALIDATE_PRODUCT = YES;
1013 | };
1014 | name = Release;
1015 | };
1016 | /* End XCBuildConfiguration section */
1017 |
1018 | /* Begin XCConfigurationList section */
1019 | 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget 'RNFormsExampleTests' */ = {
1020 | isa = XCConfigurationList;
1021 | buildConfigurations = (
1022 | 00E356F61AD99517003FC87E /* Debug */,
1023 | 00E356F71AD99517003FC87E /* Release */,
1024 | );
1025 | defaultConfigurationIsVisible = 0;
1026 | defaultConfigurationName = Release;
1027 | };
1028 | 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget 'RNFormsExample' */ = {
1029 | isa = XCConfigurationList;
1030 | buildConfigurations = (
1031 | 13B07F941A680F5B00A75B9A /* Debug */,
1032 | 13B07F951A680F5B00A75B9A /* Release */,
1033 | );
1034 | defaultConfigurationIsVisible = 0;
1035 | defaultConfigurationName = Release;
1036 | };
1037 | 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject 'RNFormsExample' */ = {
1038 | isa = XCConfigurationList;
1039 | buildConfigurations = (
1040 | 83CBBA201A601CBA00E9B192 /* Debug */,
1041 | 83CBBA211A601CBA00E9B192 /* Release */,
1042 | );
1043 | defaultConfigurationIsVisible = 0;
1044 | defaultConfigurationName = Release;
1045 | };
1046 | /* End XCConfigurationList section */
1047 | };
1048 | rootObject = 83CBB9F71A601CBA00E9B192 /* Project object */;
1049 | }
1050 |
--------------------------------------------------------------------------------
/RNFormsExample/ios/RNFormsExample.xcodeproj/xcshareddata/xcschemes/RNFormsExample.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
29 |
35 |
36 |
37 |
43 |
49 |
50 |
51 |
52 |
53 |
58 |
59 |
61 |
67 |
68 |
69 |
70 |
71 |
77 |
78 |
79 |
80 |
81 |
82 |
92 |
94 |
100 |
101 |
102 |
103 |
104 |
105 |
111 |
113 |
119 |
120 |
121 |
122 |
124 |
125 |
128 |
129 |
130 |
--------------------------------------------------------------------------------
/RNFormsExample/ios/RNFormsExample/AppDelegate.h:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) 2015-present, Facebook, Inc.
3 | * All rights reserved.
4 | *
5 | * This source code is licensed under the BSD-style license found in the
6 | * LICENSE file in the root directory of this source tree. An additional grant
7 | * of patent rights can be found in the PATENTS file in the same directory.
8 | */
9 |
10 | #import
11 |
12 | @interface AppDelegate : UIResponder
13 |
14 | @property (nonatomic, strong) UIWindow *window;
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/RNFormsExample/ios/RNFormsExample/AppDelegate.m:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) 2015-present, Facebook, Inc.
3 | * All rights reserved.
4 | *
5 | * This source code is licensed under the BSD-style license found in the
6 | * LICENSE file in the root directory of this source tree. An additional grant
7 | * of patent rights can be found in the PATENTS file in the same directory.
8 | */
9 |
10 | #import 'AppDelegate.h'
11 |
12 | #import
13 | #import
14 |
15 | @implementation AppDelegate
16 |
17 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
18 | {
19 | NSURL *jsCodeLocation;
20 |
21 | jsCodeLocation = [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@'index.ios' fallbackResource:nil];
22 |
23 | RCTRootView *rootView = [[RCTRootView alloc] initWithBundleURL:jsCodeLocation
24 | moduleName:@'RNFormsExample'
25 | initialProperties:nil
26 | launchOptions:launchOptions];
27 | rootView.backgroundColor = [[UIColor alloc] initWithRed:1.0f green:1.0f blue:1.0f alpha:1];
28 |
29 | self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
30 | UIViewController *rootViewController = [UIViewController new];
31 | rootViewController.view = rootView;
32 | self.window.rootViewController = rootViewController;
33 | [self.window makeKeyAndVisible];
34 | return YES;
35 | }
36 |
37 | @end
38 |
--------------------------------------------------------------------------------
/RNFormsExample/ios/RNFormsExample/Base.lproj/LaunchScreen.xib:
--------------------------------------------------------------------------------
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 |
39 |
40 |
41 |
42 |
43 |
--------------------------------------------------------------------------------
/RNFormsExample/ios/RNFormsExample/Images.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | 'images' : [
3 | {
4 | 'idiom' : 'iphone',
5 | 'size' : '29x29',
6 | 'scale' : '2x'
7 | },
8 | {
9 | 'idiom' : 'iphone',
10 | 'size' : '29x29',
11 | 'scale' : '3x'
12 | },
13 | {
14 | 'idiom' : 'iphone',
15 | 'size' : '40x40',
16 | 'scale' : '2x'
17 | },
18 | {
19 | 'idiom' : 'iphone',
20 | 'size' : '40x40',
21 | 'scale' : '3x'
22 | },
23 | {
24 | 'idiom' : 'iphone',
25 | 'size' : '60x60',
26 | 'scale' : '2x'
27 | },
28 | {
29 | 'idiom' : 'iphone',
30 | 'size' : '60x60',
31 | 'scale' : '3x'
32 | }
33 | ],
34 | 'info' : {
35 | 'version' : 1,
36 | 'author' : 'xcode'
37 | }
38 | }
--------------------------------------------------------------------------------
/RNFormsExample/ios/RNFormsExample/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | APPL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1
23 | LSRequiresIPhoneOS
24 |
25 | UILaunchStoryboardName
26 | LaunchScreen
27 | UIRequiredDeviceCapabilities
28 |
29 | armv7
30 |
31 | UISupportedInterfaceOrientations
32 |
33 | UIInterfaceOrientationPortrait
34 | UIInterfaceOrientationLandscapeLeft
35 | UIInterfaceOrientationLandscapeRight
36 |
37 | UIViewControllerBasedStatusBarAppearance
38 |
39 | NSLocationWhenInUseUsageDescription
40 |
41 | NSAppTransportSecurity
42 |
43 | NSExceptionDomains
44 |
45 | localhost
46 |
47 | NSExceptionAllowsInsecureHTTPLoads
48 |
49 |
50 |
51 |
52 | UIAppFonts
53 |
54 | Entypo.ttf
55 | EvilIcons.ttf
56 | FontAwesome.ttf
57 | Foundation.ttf
58 | Ionicons.ttf
59 | MaterialCommunityIcons.ttf
60 | MaterialIcons.ttf
61 | Octicons.ttf
62 | SimpleLineIcons.ttf
63 | Zocial.ttf
64 |
65 |
66 |
--------------------------------------------------------------------------------
/RNFormsExample/ios/RNFormsExample/main.m:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) 2015-present, Facebook, Inc.
3 | * All rights reserved.
4 | *
5 | * This source code is licensed under the BSD-style license found in the
6 | * LICENSE file in the root directory of this source tree. An additional grant
7 | * of patent rights can be found in the PATENTS file in the same directory.
8 | */
9 |
10 | #import
11 |
12 | #import 'AppDelegate.h'
13 |
14 | int main(int argc, char * argv[]) {
15 | @autoreleasepool {
16 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/RNFormsExample/ios/RNFormsExampleTests/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | BNDL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1
23 |
24 |
25 |
--------------------------------------------------------------------------------
/RNFormsExample/ios/RNFormsExampleTests/RNFormsExampleTests.m:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) 2015-present, Facebook, Inc.
3 | * All rights reserved.
4 | *
5 | * This source code is licensed under the BSD-style license found in the
6 | * LICENSE file in the root directory of this source tree. An additional grant
7 | * of patent rights can be found in the PATENTS file in the same directory.
8 | */
9 |
10 | #import
11 | #import
12 |
13 | #import
14 | #import
15 |
16 | #define TIMEOUT_SECONDS 600
17 | #define TEXT_TO_LOOK_FOR @'Welcome to React Native!'
18 |
19 | @interface RNFormsExampleTests : XCTestCase
20 |
21 | @end
22 |
23 | @implementation RNFormsExampleTests
24 |
25 | - (BOOL)findSubviewInView:(UIView *)view matching:(BOOL(^)(UIView *view))test
26 | {
27 | if (test(view)) {
28 | return YES;
29 | }
30 | for (UIView *subview in [view subviews]) {
31 | if ([self findSubviewInView:subview matching:test]) {
32 | return YES;
33 | }
34 | }
35 | return NO;
36 | }
37 |
38 | - (void)testRendersWelcomeScreen
39 | {
40 | UIViewController *vc = [[[[UIApplication sharedApplication] delegate] window] rootViewController];
41 | NSDate *date = [NSDate dateWithTimeIntervalSinceNow:TIMEOUT_SECONDS];
42 | BOOL foundElement = NO;
43 |
44 | __block NSString *redboxError = nil;
45 | RCTSetLogFunction(^(RCTLogLevel level, RCTLogSource source, NSString *fileName, NSNumber *lineNumber, NSString *message) {
46 | if (level >= RCTLogLevelError) {
47 | redboxError = message;
48 | }
49 | });
50 |
51 | while ([date timeIntervalSinceNow] > 0 && !foundElement && !redboxError) {
52 | [[NSRunLoop mainRunLoop] runMode:NSDefaultRunLoopMode beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]];
53 | [[NSRunLoop mainRunLoop] runMode:NSRunLoopCommonModes beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]];
54 |
55 | foundElement = [self findSubviewInView:vc.view matching:^BOOL(UIView *view) {
56 | if ([view.accessibilityLabel isEqualToString:TEXT_TO_LOOK_FOR]) {
57 | return YES;
58 | }
59 | return NO;
60 | }];
61 | }
62 |
63 | RCTSetLogFunction(RCTDefaultLogFunction);
64 |
65 | XCTAssertNil(redboxError, @'RedBox error: %@', redboxError);
66 | XCTAssertTrue(foundElement, @'Couldn't find element with text '%@' in %d seconds', TEXT_TO_LOOK_FOR, TIMEOUT_SECONDS);
67 | }
68 |
69 |
70 | @end
71 |
--------------------------------------------------------------------------------
/RNFormsExample/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "RNFormsExample",
3 | "version": "0.0.1",
4 | "private": true,
5 | "scripts": {
6 | "start": "node node_modules/react-native/local-cli/cli.js start",
7 | "test": "jest"
8 | },
9 | "dependencies": {
10 | "react": "15.4.2",
11 | "react-native": "0.40.0",
12 | "react-native-forms": "^1.0.0",
13 | "react-native-vector-icons": "^4.0.0"
14 | },
15 | "devDependencies": {
16 | "babel-jest": "18.0.0",
17 | "babel-preset-react-native": "1.9.1",
18 | "jest": "18.1.0",
19 | "react-test-renderer": "15.4.2"
20 | },
21 | "jest": {
22 | "preset": "react-native"
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/img/AndroidScreenshot.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/img/AndroidScreenshot.png
--------------------------------------------------------------------------------
/img/ExampleScreenshot.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/michaelhelvey/react-native-forms/474c02b2d9a2f15b569584c13814f70f3093060d/img/ExampleScreenshot.png
--------------------------------------------------------------------------------
/index.js:
--------------------------------------------------------------------------------
1 | import {
2 | ActionSheetCell,
3 | ButtonCell,
4 | createValidator,
5 | DatePickerCell,
6 | emailValidator,
7 | Form,
8 | PushButtonCell,
9 | Section,
10 | SwitchCell,
11 | TextInputCell,
12 | } from './lib';
13 |
14 | module.exports = {
15 | ActionSheetCell,
16 | ButtonCell,
17 | createValidator,
18 | DatePickerCell,
19 | emailValidator,
20 | Form,
21 | PushButtonCell,
22 | Section,
23 | SwitchCell,
24 | TextInputCell,
25 | };
26 |
--------------------------------------------------------------------------------
/lib/ActionSheetCell.js:
--------------------------------------------------------------------------------
1 | import React, { PropTypes } from 'react';
2 | import {
3 | ActionSheetIOS,
4 | Platform,
5 | Text,
6 | TouchableOpacity,
7 | View,
8 | } from 'react-native';
9 | import { FormSettings, ASStyles } from './DefaultStyles';
10 |
11 | export default class ActionSheetCell extends React.Component {
12 |
13 | constructor(props) {
14 | super(props);
15 | this.state = {
16 | value: this.getValueTextFromIndex(props.selectedValueIndex) || '',
17 | };
18 |
19 | if (this.state.value.length) {
20 | props.onChange && props.onChange(this.state.value);
21 | }
22 | }
23 |
24 |
25 | getWrappedChildren(titleText, valueText) {
26 | const children = [];
27 | if (this.props.icon) {
28 | children.push(
29 | React.cloneElement(this.props.icon, {
30 | key: `${this.props.icon.type}titleTextIcon`,
31 | style: ASStyles.icon,
32 | })
33 | );
34 | }
35 | children.push(titleText);
36 | children.push(valueText);
37 | return (
38 |
39 | {children}
40 |
41 | );
42 | }
43 |
44 | getValueTextFromIndex(index) {
45 | if (typeof(index) !== 'undefined') {
46 | return this.props.options[index];
47 | }
48 | return undefined;
49 | }
50 |
51 | handleChange(index) {
52 | const value = this.getValueTextFromIndex(index);
53 | this.setState({
54 | value,
55 | });
56 | this.props.onChange && this.props.onChange(value);
57 | try {
58 | this.props.validator && this.props.validator(value);
59 | this.props.onValidationPass && this.props.onValidationPass();
60 | } catch (e) {
61 | this.props.onValidationError && this.props.onValidationError(e);
62 | }
63 | }
64 |
65 | handlePress() {
66 | const cancelButtonIndex = this.props.options.length;
67 | ActionSheetIOS.showActionSheetWithOptions({
68 | options: [...this.props.options, 'Cancel'],
69 | cancelButtonIndex,
70 | }, (index) => {
71 | if (index !== cancelButtonIndex) {
72 | this.handleChange.bind(this)(index);
73 | }
74 | });
75 | }
76 |
77 | render() {
78 | if (Platform.OS === 'android') {
79 | return null;
80 | }
81 | const titleStyle = this.props.titleStyle || ASStyles.defaultTitleStyle;
82 | const titleText = (
83 |
87 | {this.props.title}
88 |
89 | );
90 | const valueStyle = this.props.valueStyle || ASStyles.defaultValueStyle;
91 | const valueText = (
92 |
96 | {this.state.value}
97 |
98 | );
99 | const wrapped = this.getWrappedChildren.bind(this)(titleText, valueText);
100 | const containerStyle = this.props.containerStyle || ASStyles.container;
101 | const cellHeight = this.props.cellHeight || FormSettings.defaultCellHeight;
102 | return (
103 |
110 | {wrapped}
111 |
112 | );
113 | }
114 | }
115 |
116 | ActionSheetCell.propTypes = {
117 | cellHeight: PropTypes.number,
118 | containerStyle: PropTypes.object,
119 | icon: PropTypes.element,
120 | onChange: PropTypes.func,
121 | onValidationError: PropTypes.func,
122 | onValidationPass: PropTypes.func,
123 | options: PropTypes.array.isRequired,
124 | selectedValueIndex: PropTypes.number,
125 | title: PropTypes.string,
126 | titleStyle: PropTypes.object,
127 | validator: PropTypes.func,
128 | valueStyle: PropTypes.object,
129 | };
130 |
--------------------------------------------------------------------------------
/lib/ButtonCell.js:
--------------------------------------------------------------------------------
1 | import React, { PropTypes } from 'react';
2 | import {
3 | Text,
4 | TouchableHighlight,
5 | } from 'react-native';
6 | import { FormSettings, BCStyles } from './DefaultStyles';
7 |
8 | export default class ButtonCell extends React.Component {
9 |
10 | handlePress() {
11 | this.props.onPress && this.props.onPress();
12 | }
13 |
14 | render() {
15 | const height = this.props.cellHeight || FormSettings.defaultCellHeight;
16 |
17 | const containerStyle = this.props.containerStyle || BCStyles.container;
18 | const textStyle = this.props.textStyle || BCStyles.titleStyle;
19 |
20 | const customTextTyles = { backgroundColor: 'transparent' };
21 | if (this.props.titleColor) {
22 | customTextTyles.color = this.props.titleColor;
23 | }
24 |
25 | if (this.props.textAlign) {
26 | customTextTyles.textAlign = this.props.textAlign;
27 | }
28 |
29 | return (
30 |
35 |
38 | {this.props.title}
39 |
40 |
41 | );
42 | }
43 | }
44 |
45 | ButtonCell.propTypes = {
46 | cellHeight: PropTypes.number,
47 | containerStyle: PropTypes.object,
48 | onPress: PropTypes.func,
49 | textAlign: PropTypes.string,
50 | textStyle: PropTypes.object,
51 | title: PropTypes.string,
52 | titleColor: PropTypes.string,
53 | };
54 |
--------------------------------------------------------------------------------
/lib/DatePickerCell.js:
--------------------------------------------------------------------------------
1 | import React, { PropTypes } from 'react';
2 | import {
3 | Platform,
4 | Text,
5 | TouchableOpacity,
6 | View,
7 | DatePickerIOS,
8 | } from 'react-native';
9 | import { FormSettings, DPStyles } from './DefaultStyles';
10 |
11 | export default class DatePickerCell extends React.Component {
12 |
13 | constructor(props) {
14 | super(props);
15 | this.state = {
16 | value: props.value || new Date(),
17 | isShowingPicker: false,
18 | };
19 | this.startPressY = 0;
20 | this.endPressY = 0;
21 | if (props.value) {
22 | props.onChange && props.onChange(props.value);
23 | }
24 | }
25 |
26 | getWrappedChildren(titleText, valueText) {
27 | const children = [];
28 | if (this.props.icon) {
29 | children.push(
30 | React.cloneElement(this.props.icon, {
31 | key: `${this.props.icon.type}titleTextIcon`,
32 | style: DPStyles.icon,
33 | })
34 | );
35 | }
36 | children.push(titleText);
37 | children.push(valueText);
38 | return (
39 |
40 | {children}
41 |
42 | );
43 | }
44 |
45 | getValueTextFromDate(date) {
46 | if (!date) {
47 | return '';
48 | }
49 | if (this.props.getDateString) {
50 | return this.props.getDateString(date);
51 | }
52 | const value = date.toLocaleDateString ? date.toLocaleDateString() : '';
53 | return value;
54 | }
55 |
56 | getPicker() {
57 | if (!this.state.isShowingPicker) {
58 | return null;
59 | }
60 | return (
61 |
66 | );
67 | }
68 |
69 | handleChange(date) {
70 | this.setState({
71 | value: date,
72 | });
73 | this.props.onChange && this.props.onChange(date);
74 | try {
75 | this.props.validator && this.props.validator(date);
76 | this.props.onValidationPass && this.props.onValidationPass();
77 | } catch (e) {
78 | this.props.onValidationError && this.props.onValidationError(e);
79 | }
80 | }
81 |
82 | handlePressIn(event) {
83 | this.startPressY = event.nativeEvent.locationY;
84 | }
85 |
86 | handlePressOut(event) {
87 | this.endPressY = event.nativeEvent.locationY;
88 | const cellHeight = this.props.cellHeight || FormSettings.defaultCellHeight;
89 | if (Math.abs(this.startPressY - this.endPressY) < 3) {
90 | if (event.nativeEvent.locationY <= cellHeight && event.nativeEvent.locationY > 0) {
91 | this.setState({ isShowingPicker: !this.state.isShowingPicker });
92 | }
93 | }
94 | }
95 |
96 | render() {
97 | if (Platform.OS === 'android') {
98 | return null;
99 | }
100 | const titleStyle = this.props.titleStyle || DPStyles.defaultTitleStyle;
101 | const titleText = (
102 |
106 | {this.props.title}
107 |
108 | );
109 | const valueStyle = this.props.valueStyle || DPStyles.defaultValueStyle;
110 | const valueText = (
111 |
115 | {this.getValueTextFromDate.bind(this)(this.state.value)}
116 |
117 | );
118 | const wrapped = this.getWrappedChildren.bind(this)(titleText, valueText);
119 | const containerStyle = this.props.containerStyle || DPStyles.container;
120 | const cellHeight = this.props.cellHeight || FormSettings.defaultCellHeight;
121 | let styleProp;
122 | if (!this.state.isShowingPicker) {
123 | styleProp = [
124 | containerStyle,
125 | { height: cellHeight },
126 | ];
127 | } else {
128 | styleProp = [
129 | containerStyle,
130 | { paddingTop: 12 },
131 | ];
132 | }
133 | return (
134 |
139 |
140 | {wrapped}
141 | {this.getPicker.bind(this)()}
142 |
143 |
144 | );
145 | }
146 | }
147 |
148 | DatePickerCell.propTypes = {
149 | cellHeight: PropTypes.number,
150 | containerStyle: PropTypes.object,
151 | datePickerProps: PropTypes.object,
152 | getDateString: PropTypes.func,
153 | icon: PropTypes.element,
154 | onChange: PropTypes.func,
155 | onValidationError: PropTypes.func,
156 | onValidationPass: PropTypes.func,
157 | title: PropTypes.string,
158 | titleStyle: PropTypes.object,
159 | validator: PropTypes.func,
160 | value: PropTypes.object, // must be a Date object
161 | valueStyle: PropTypes.object,
162 | };
163 |
--------------------------------------------------------------------------------
/lib/DefaultStyles.js:
--------------------------------------------------------------------------------
1 | import { StyleSheet } from 'react-native';
2 |
3 | export const FormSettings = {
4 | textMarginLeft: 15,
5 | defaultCellHeight: 44,
6 | };
7 |
8 | export const FCStyles = StyleSheet.create({
9 | container: {
10 | backgroundColor: '#EFEFF4',
11 | },
12 | });
13 |
14 | export const BCStyles = StyleSheet.create({
15 | container: {
16 | flexDirection: 'row',
17 | },
18 | titleStyle: {
19 | alignSelf: 'center',
20 | backgroundColor: 'white',
21 | color: '#007AFF',
22 | flex: 1,
23 | fontSize: 16,
24 | marginLeft: FormSettings.textMarginLeft,
25 | textAlign: 'left',
26 | },
27 | });
28 |
29 | export const ASStyles = StyleSheet.create({
30 | container: {
31 | flex: 1,
32 | flexDirection: 'row',
33 | },
34 | defaultTitleStyle: {
35 | flex: 1,
36 | marginLeft: FormSettings.textMarginLeft,
37 | alignSelf: 'center',
38 | fontSize: 16,
39 | },
40 | defaultValueStyle: {
41 | marginRight: FormSettings.textMarginLeft,
42 | fontSize: 16,
43 | alignSelf: 'center',
44 | color: '#696969',
45 | },
46 | icon: {
47 | paddingLeft: 10,
48 | alignSelf: 'center',
49 | },
50 | });
51 |
52 | export const DPStyles = StyleSheet.create({
53 | container: {
54 | flex: 1,
55 | flexDirection: 'row',
56 | },
57 | defaultTitleStyle: {
58 | flex: 1,
59 | marginLeft: FormSettings.textMarginLeft,
60 | alignSelf: 'center',
61 | fontSize: 16,
62 | },
63 | defaultValueStyle: {
64 | marginRight: FormSettings.textMarginLeft,
65 | fontSize: 16,
66 | alignSelf: 'center',
67 | color: '#696969',
68 | },
69 | icon: {
70 | paddingLeft: 10,
71 | alignSelf: 'center',
72 | },
73 | });
74 |
75 | export const PBStyles = StyleSheet.create({
76 | container: {
77 | flexDirection: 'row',
78 | alignSelf: 'center',
79 | },
80 | titleStyle: {
81 | flex: 1,
82 | marginLeft: FormSettings.textMarginLeft,
83 | fontSize: 16,
84 | backgroundColor: 'white',
85 | alignSelf: 'center',
86 | },
87 | rightIcon: {
88 | marginRight: 10,
89 | alignSelf: 'center',
90 | },
91 | icon: {
92 | marginLeft: 10,
93 | alignSelf: 'center',
94 | },
95 | });
96 |
97 | export const SectionStyles = StyleSheet.create({
98 | container: {
99 | marginTop: 15,
100 | marginBottom: 15,
101 | },
102 | sectionWrapper: {
103 | backgroundColor: 'white',
104 | borderBottomWidth: StyleSheet.hairlineWidth,
105 | borderBottomColor: '#D3D3D3',
106 | borderTopWidth: StyleSheet.hairlineWidth,
107 | borderTopColor: '#D3D3D3',
108 | },
109 | sectionTitle: {
110 | color: '#808080',
111 | fontSize: 14,
112 | marginBottom: 10,
113 | marginLeft: FormSettings.textMarginLeft,
114 | },
115 | sectionHelpText: {
116 | color: '#808080',
117 | fontSize: 13,
118 | marginTop: 10,
119 | marginLeft: FormSettings.textMarginLeft,
120 | marginRight: FormSettings.textMarginLeft,
121 | },
122 | });
123 |
124 | export const SCStyles = StyleSheet.create({
125 | container: {
126 | flexDirection: 'row',
127 | },
128 | titleStyle: {
129 | flex: 1,
130 | marginLeft: FormSettings.textMarginLeft,
131 | fontSize: 16,
132 | backgroundColor: 'white',
133 | alignSelf: 'center',
134 | },
135 | switch: {
136 | marginRight: 20,
137 | alignSelf: 'center',
138 | },
139 | icon: {
140 | marginLeft: 10,
141 | alignSelf: 'center',
142 | },
143 | });
144 |
145 | export const TIStyles = StyleSheet.create({
146 | container: {
147 | flexDirection: 'row',
148 | },
149 | defaultInputStyle: {
150 | flex: 1,
151 | marginLeft: FormSettings.textMarginLeft,
152 | fontSize: 16,
153 | backgroundColor: 'white',
154 | },
155 | icon: {
156 | paddingLeft: 10,
157 | alignSelf: 'center',
158 | },
159 | });
160 |
--------------------------------------------------------------------------------
/lib/Form.js:
--------------------------------------------------------------------------------
1 | import React, { PropTypes } from 'react';
2 | import { ScrollView } from 'react-native';
3 | import {
4 | KeyboardAwareScrollView,
5 | } from 'react-native-keyboard-aware-scroll-view';
6 | import { FCStyles } from './DefaultStyles';
7 | import isEqual from 'lodash.isequal';
8 |
9 | export default class Form extends React.Component {
10 |
11 | constructor(props) {
12 | super(props);
13 | this.data = {};
14 | this.validationErrors = {};
15 | this.getData = this.getData.bind(this);
16 | }
17 |
18 | getData() {
19 | return { ...this.data };
20 | }
21 |
22 | getValidationErrors() {
23 | return { ...this.validationErrors };
24 | }
25 |
26 | handleOnChange(ref, value) {
27 | const oldData = { ...this.data };
28 | this.data[ref] = value;
29 | if (this.props.onChange) {
30 | // diff the old and new for display
31 | Object.keys(oldData).forEach(key => {
32 | if (!isEqual(this.data[key], oldData[key])) {
33 | Object.keys(oldData[key]).forEach(k => {
34 | if (this.data[key][k] !== oldData[key][k]) {
35 | this.props.onChange(k, this.data[key][k]);
36 | }
37 | });
38 | }
39 | });
40 | }
41 | }
42 |
43 | handleValidationError(ref, message) {
44 | this.validationErrors[ref] = message;
45 | this.props.onValidationError && this.props.onValidationError(ref, message);
46 | }
47 |
48 | handleValidationPass(ref, child) {
49 | this.validationErrors[ref] = child;
50 | }
51 |
52 | handleOnPress(ref) {
53 | this.props.onPress && this.props.onPress(ref);
54 | }
55 |
56 | render() {
57 | const wrapped = React.Children.map(this.props.children,
58 | (child, i) => React.cloneElement(child, {
59 | key: child.ref || child.type + i,
60 | ref: child.ref,
61 | onPress: this.handleOnPress.bind(this),
62 | onChange: this.handleOnChange.bind(this, child.ref),
63 | onValidationError: this.handleValidationError.bind(this, child.ref),
64 | onValidationPass: this.handleValidationPass.bind(this, child.ref),
65 | }),
66 | this);
67 |
68 | const containerStyle = this.props.containerStyle || FCStyles.container;
69 |
70 | if (this.props.keyboardAware) {
71 | return (
72 |
78 | {wrapped}
79 |
80 | );
81 | }
82 | return (
83 |
88 | {wrapped}
89 |
90 | );
91 | }
92 | }
93 |
94 | Form.propTypes = {
95 | containerStyle: PropTypes.object,
96 | keyboardAware: PropTypes.bool,
97 | onChange: PropTypes.func,
98 | onPress: PropTypes.func,
99 | onValidationError: PropTypes.func,
100 | };
101 |
--------------------------------------------------------------------------------
/lib/Line.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import {
3 | View,
4 | StyleSheet,
5 | } from 'react-native';
6 |
7 | export default class Line extends React.Component {
8 |
9 | shouldComponentUpdate() {
10 | return false;
11 | }
12 |
13 | render() {
14 | return (
15 |
22 | );
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/lib/PushButtonCell.js:
--------------------------------------------------------------------------------
1 | import React, { PropTypes } from 'react';
2 | import {
3 | View,
4 | Text,
5 | TouchableHighlight,
6 | } from 'react-native';
7 | import { FormSettings, PBStyles } from './DefaultStyles';
8 |
9 | export default class PushButtonCell extends React.Component {
10 |
11 | getWrappedChildren(text) {
12 | const children = [];
13 | if (this.props.icon) {
14 | children.push(
15 | React.cloneElement(this.props.icon, {
16 | key: `${this.props.icon.type}PushButtonLeftIcon`,
17 | style: PBStyles.icon,
18 | })
19 | );
20 | }
21 | children.push(React.cloneElement(text, {
22 | key: `${this.props.rightIcon.type}PushButtonTitle`,
23 | }));
24 | if (this.props.rightIcon) {
25 | children.push(
26 | React.cloneElement(this.props.rightIcon, {
27 | key: `${this.props.rightIcon.type}PushButtonRightIcon`,
28 | style: PBStyles.rightIcon,
29 | })
30 | );
31 | }
32 | return children;
33 | }
34 |
35 | handlePress() {
36 | this.props.onPress && this.props.onPress();
37 | }
38 |
39 | render() {
40 | const height = this.props.cellHeight || FormSettings.defaultCellHeight;
41 | const containerStyle = this.props.containerStyle || PBStyles.container;
42 | const titleStyle = this.props.titleStyle || PBStyles.titleStyle;
43 |
44 | const customTitleStyle = { backgroundColor: 'transparent' };
45 | if (this.props.titleColor) {
46 | customTitleStyle.color = this.props.titleColor;
47 | }
48 |
49 | const text = (
50 |
51 | {this.props.title}
52 |
53 | );
54 | const children = this.getWrappedChildren.bind(this)(text);
55 |
56 | return (
57 |
62 |
63 | {children}
64 |
65 |
66 | );
67 | }
68 | }
69 |
70 | PushButtonCell.propTypes = {
71 | cellHeight: PropTypes.number,
72 | containerStyle: PropTypes.object,
73 | icon: PropTypes.element,
74 | onPress: PropTypes.func,
75 | rightIcon: PropTypes.element,
76 | title: PropTypes.string,
77 | titleColor: PropTypes.string,
78 | titleStyle: PropTypes.string,
79 | };
80 |
--------------------------------------------------------------------------------
/lib/Section.js:
--------------------------------------------------------------------------------
1 | import React, { PropTypes } from 'react';
2 | import {
3 | Text,
4 | View,
5 | } from 'react-native';
6 | import { FormSettings, SectionStyles } from './DefaultStyles';
7 | import Line from './Line';
8 |
9 | export default class Section extends React.Component {
10 |
11 | constructor(props) {
12 | super(props);
13 | this.data = {};
14 | this.validationErrors = {};
15 | this.getData = this.getData.bind(this);
16 | }
17 |
18 | shouldComponentUpdate() {
19 | return false;
20 | }
21 |
22 | getData() {
23 | return { ...this.data };
24 | }
25 |
26 | getValidationErrors() {
27 | return { ...this.validationErrors };
28 | }
29 |
30 | getFinalWrapped(wrapped) {
31 | const finalWrapped = [];
32 | if (this.props.title) {
33 | finalWrapped.push((
34 |
38 | {this.props.title}
39 |
40 | ));
41 | }
42 | finalWrapped.push(
43 |
47 | {wrapped}
48 |
49 | );
50 | if (this.props.helpText) {
51 | finalWrapped.push((
52 |
56 | {this.props.helpText}
57 |
58 | ));
59 | }
60 | return finalWrapped;
61 | }
62 |
63 | handleOnChange(ref, value) {
64 | this.data[ref] = value;
65 | this.props.onChange && this.props.onChange(this.getData());
66 | }
67 |
68 | handleOnPress(ref) {
69 | this.props.onPress && this.props.onPress(ref);
70 | }
71 |
72 | handleValidationError(ref, message) {
73 | this.validationErrors[ref] = message;
74 | this.props.onValidationError && this.props.onValidationError(this.getValidationErrors());
75 | }
76 |
77 | handleValidationPass(ref) {
78 | delete this.validationErrors[ref];
79 | this.props.onValidationPass && this.props.onValidationPass(this.getValidationErrors());
80 | }
81 |
82 | render() {
83 | const wrapped = React.Children.map(this.props.children, (child, i) => {
84 | const newChild = React.cloneElement(child, {
85 | key: child.ref || child.type + i,
86 | ref: child.ref,
87 | onPress: this.handleOnPress.bind(this, child.ref),
88 | onChange: this.handleOnChange.bind(this, child.ref),
89 | onValidationError: this.handleValidationError.bind(this, child.ref),
90 | onValidationPass: this.handleValidationPass.bind(this, child.ref),
91 | });
92 |
93 | let wrappedLine;
94 | if ((i !== this.props.children.length - 1)
95 | && this.props.children.length && !this.props.hideLine) {
96 | const marginLeft = child.props.icon ? 35 : FormSettings.textMarginLeft;
97 | wrappedLine = (
98 |
99 | {newChild}
100 |
101 |
102 | );
103 | } else {
104 | wrappedLine = newChild;
105 | }
106 |
107 | return wrappedLine;
108 | }, this);
109 |
110 | return (
111 |
112 | {this.getFinalWrapped.bind(this)(wrapped)}
113 |
114 | );
115 | }
116 | }
117 |
118 | Section.propTypes = {
119 | containerStyle: PropTypes.object,
120 | helpText: PropTypes.string,
121 | hideLine: PropTypes.bool,
122 | onChange: PropTypes.func,
123 | onPress: PropTypes.func,
124 | onValidationError: PropTypes.func,
125 | onValidationPass: PropTypes.func,
126 | title: PropTypes.string,
127 | };
128 |
--------------------------------------------------------------------------------
/lib/SwitchCell.js:
--------------------------------------------------------------------------------
1 | import React, { PropTypes } from 'react';
2 | import {
3 | View,
4 | Text,
5 | Switch,
6 | } from 'react-native';
7 | import { FormSettings, SCStyles } from './DefaultStyles';
8 |
9 | export default class SwitchCell extends React.Component {
10 |
11 | constructor(props) {
12 | super(props);
13 | this.state = {
14 | value: props.value,
15 | };
16 | props.onChange && props.onChange(props.value || false);
17 | }
18 |
19 | getSwitch(propsTint) {
20 | if (propsTint) {
21 | return (
22 |
28 | );
29 | }
30 | return (
31 |
36 | );
37 | }
38 |
39 | getRightIcon(props) {
40 | if (props.icon) {
41 | return React.cloneElement(props.icon, {
42 | style: SCStyles.icon,
43 | });
44 | }
45 | return null;
46 | }
47 |
48 | handleChange(value) {
49 | this.setState({
50 | value,
51 | });
52 | this.props.onChange && this.props.onChange(value);
53 | }
54 |
55 | render() {
56 | const height = this.props.cellHeight || FormSettings.defaultCellHeight;
57 | const containerStyle = this.props.containerStyle || SCStyles.container;
58 | const titleStyle = this.props.titleStyle || SCStyles.titleStyle;
59 | return (
60 |
61 | {this.getRightIcon(this.props)}
62 |
63 | {this.props.title}
64 |
65 | {this.getSwitch(this.props.switchTintColor)}
66 |
67 | );
68 | }
69 | }
70 |
71 | SwitchCell.propTypes = {
72 | cellHeight: PropTypes.number,
73 | containerStyle: PropTypes.object,
74 | onChange: PropTypes.func,
75 | switchTintColor: PropTypes.string,
76 | title: PropTypes.string,
77 | titleColor: PropTypes.string,
78 | titleStyle: PropTypes.object,
79 | icon: PropTypes.element,
80 | value: PropTypes.bool,
81 | };
82 |
--------------------------------------------------------------------------------
/lib/TextInputCell.js:
--------------------------------------------------------------------------------
1 | import React, { PropTypes } from 'react';
2 | import {
3 | View,
4 | TextInput,
5 | } from 'react-native';
6 | import { FormSettings, TIStyles } from './DefaultStyles';
7 |
8 | export default class TextInputCell extends React.Component {
9 |
10 | constructor(props) {
11 | super(props);
12 | this.state = {
13 | value: props.value || '',
14 | };
15 |
16 | if (props.value) {
17 | props.onChange && props.onChange(props.value);
18 | }
19 | }
20 |
21 | getWrappedChildren(textInput) {
22 | const children = [];
23 | if (this.props.icon) {
24 | children.push(
25 | React.cloneElement(this.props.icon, {
26 | key: `${this.props.icon.type}textInputIcon`,
27 | style: TIStyles.icon,
28 | })
29 | );
30 | }
31 | children.push(textInput);
32 | return children;
33 | }
34 |
35 | handleChange(event) {
36 | const value = event.nativeEvent.text;
37 | this.setState({
38 | value,
39 | });
40 | this.props.onChange && this.props.onChange(value);
41 | try {
42 | this.props.validator && this.props.validator(value);
43 | this.props.onValidationPass && this.props.onValidationPass();
44 | } catch (e) {
45 | this.props.onValidationError && this.props.onValidationError(e.message);
46 | }
47 | }
48 |
49 | render() {
50 | const inputStyle = this.props.inputStyle || TIStyles.defaultInputStyle;
51 | const textInput = (
52 |
59 | );
60 | const wrapped = this.getWrappedChildren.bind(this)(textInput);
61 | const height = this.props.cellHeight || FormSettings.defaultCellHeight;
62 | const containerStyle = this.props.containerStyle || TIStyles.container;
63 | return (
64 |
65 | {wrapped}
66 |
67 | );
68 | }
69 | }
70 |
71 | TextInputCell.propTypes = {
72 | cellHeight: PropTypes.number,
73 | containerStyle: PropTypes.object,
74 | icon: PropTypes.element,
75 | inputProps: PropTypes.object,
76 | inputStyle: PropTypes.object,
77 | onChange: PropTypes.func,
78 | onValidationError: PropTypes.func,
79 | onValidationPass: PropTypes.func,
80 | validator: PropTypes.func,
81 | value: PropTypes.string,
82 | };
83 |
--------------------------------------------------------------------------------
/lib/index.js:
--------------------------------------------------------------------------------
1 | import ActionSheetCell from './ActionSheetCell';
2 | import ButtonCell from './ButtonCell';
3 | import Form from './Form';
4 | import PushButtonCell from './PushButtonCell';
5 | import Section from './Section';
6 | import SwitchCell from './SwitchCell';
7 | import TextInputCell from './TextInputCell';
8 | import DatePickerCell from './DatePickerCell';
9 | import { createValidator, emailValidator } from './validators';
10 |
11 | module.exports = {
12 | ActionSheetCell,
13 | ButtonCell,
14 | createValidator,
15 | DatePickerCell,
16 | emailValidator,
17 | Form,
18 | PushButtonCell,
19 | Section,
20 | SwitchCell,
21 | TextInputCell,
22 | };
23 |
--------------------------------------------------------------------------------
/lib/validators.js:
--------------------------------------------------------------------------------
1 | export function createValidator(validator, options) {
2 | return (value) => {
3 | const result = validator(value);
4 | if (!result) {
5 | throw new Error(options.errorMessage || '');
6 | }
7 | };
8 | }
9 |
10 | export function emailValidator(email) {
11 | // eslint-disable-next-line
12 | const re = /^(([^<>()\[\]\\.,;:\s@']+(\.[^<>()\[\]\\.,;:\s@']+)*)|('.+'))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;
13 | return re.test(email);
14 | }
15 |
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "react-native-forms",
3 | "version": "1.0.1",
4 | "description": "A simple, declarative API for creating cross-platform, native-appearing forms with React Native.",
5 | "main": "index.js",
6 | "repository": "https://github.com/michaelhelvey/react-native-forms",
7 | "scripts": {
8 | "test": "echo \"Error: no test specified\" && exit 1",
9 | "lint": "./node_modules/.bin/eslint RNFormsExample/*.js lib/**"
10 | },
11 | "keywords": [
12 | "react",
13 | "native",
14 | "form",
15 | "react",
16 | "native",
17 | "form",
18 | "ios",
19 | "android",
20 | "react",
21 | "component"
22 | ],
23 | "author": "Michael Helvey",
24 | "license": "MIT",
25 | "devDependencies": {
26 | "babel-eslint": "^6.1.2",
27 | "eslint": "^3.0.1",
28 | "eslint-config-airbnb": "^9.0.1",
29 | "eslint-plugin-import": "^1.10.2",
30 | "eslint-plugin-jsx-a11y": "^1.5.5",
31 | "eslint-plugin-react": "^5.2.2"
32 | },
33 | "peerDependencies": {
34 | "react-native": ">=0.27"
35 | },
36 | "dependencies": {
37 | "lodash.isequal": "^4.2.0",
38 | "react-native-keyboard-aware-scroll-view": "^0.1.2"
39 | }
40 | }
41 |
--------------------------------------------------------------------------------