├── .editorconfig ├── .eslintignore ├── .eslintrc.js ├── .flowconfig ├── .github └── demo.gif ├── .gitignore ├── .npmignore ├── .vscode └── settings.json ├── Example ├── .babelrc ├── .gitattributes ├── .gitignore ├── .watchmanconfig ├── App.js ├── android │ ├── app │ │ ├── build.gradle │ │ ├── proguard-rules.pro │ │ └── src │ │ │ └── main │ │ │ ├── AndroidManifest.xml │ │ │ ├── java │ │ │ └── com │ │ │ │ └── example │ │ │ │ ├── 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 │ │ └── debug.keystore.properties │ └── settings.gradle ├── app.json ├── index.js ├── ios │ ├── Example-tvOS │ │ └── Info.plist │ ├── Example-tvOSTests │ │ └── Info.plist │ ├── Example.xcodeproj │ │ ├── project.pbxproj │ │ └── xcshareddata │ │ │ └── xcschemes │ │ │ ├── Example-tvOS.xcscheme │ │ │ └── Example.xcscheme │ ├── Example │ │ ├── AppDelegate.h │ │ ├── AppDelegate.m │ │ ├── Base.lproj │ │ │ └── LaunchScreen.xib │ │ ├── Images.xcassets │ │ │ ├── AppIcon.appiconset │ │ │ │ └── Contents.json │ │ │ └── Contents.json │ │ ├── Info.plist │ │ └── main.m │ └── ExampleTests │ │ ├── ExampleTests.m │ │ └── Info.plist ├── jsconfig.json ├── package.json ├── rn-cli.config.js └── yarn.lock ├── LICENSE ├── README.md ├── commitlint.config.js ├── dist └── index.js ├── jsconfig.json ├── package.json ├── rollup.config.js ├── src ├── flow │ ├── .eslintrc.js │ └── react-swipeable-views-native.js └── index.js └── yarn.lock /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | indent_style = space 5 | indent_size = 2 6 | end_of_line = lf 7 | charset = utf-8 8 | trim_trailing_whitespace = true 9 | insert_final_newline = true 10 | 11 | [*.md] 12 | trim_trailing_whitespace = false 13 | -------------------------------------------------------------------------------- /.eslintignore: -------------------------------------------------------------------------------- 1 | /node_modules 2 | /Example/node_modules 3 | /dist 4 | -------------------------------------------------------------------------------- /.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | extends: [ 3 | 'anvilabs', 4 | 'anvilabs-react/native', 5 | 'anvilabs/flowtype', 6 | ], 7 | rules: { 8 | 'no-use-before-define': 'off', 9 | // https://github.com/benmosher/eslint-plugin-import 10 | 'import/no-internal-modules': 'off', 11 | // https://github.com/yannickcr/eslint-plugin-react 12 | 'react/prop-types': 'off', 13 | 'react/require-default-props': 'off', 14 | 'react/sort-comp': 'off', 15 | // https://github.com/Intellicode/eslint-plugin-react-native 16 | 'react-native/no-color-literals': 'off', 17 | 'react/jsx-filename-extension': 'off', 18 | }, 19 | }; 20 | -------------------------------------------------------------------------------- /.flowconfig: -------------------------------------------------------------------------------- 1 | [ignore] 2 | .*/*[.]android.js 3 | .*/node_modules/react-native/\.buckd/ 4 | .*/node_modules/.*/__test__/ 5 | .*/node_modules/.*/__tests__/ 6 | .*/node_modules/.*/test/ 7 | .*/node_modules/.*/tests/ 8 | .*/node_modules/.*/node_modules/fbjs/.* 9 | .*/Libraries/react-native/React.js 10 | .*/Libraries/polyfills/.* 11 | .*/node_modules/react-swipeable-views-native/.* 12 | /Example/ 13 | /dist/ 14 | 15 | [include] 16 | 17 | [libs] 18 | node_modules/react-native/Libraries/react-native/react-native-interface.js 19 | node_modules/react-native/flow/ 20 | src/flow 21 | 22 | [options] 23 | emoji=true 24 | 25 | module.system=haste 26 | 27 | munge_underscores=true 28 | 29 | 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' 30 | 31 | suppress_type=$FlowIssue 32 | suppress_type=$FlowFixMe 33 | suppress_type=$FlowFixMeProps 34 | suppress_type=$FlowFixMeState 35 | suppress_type=$FixMe 36 | 37 | suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(5[0-6]\\|[1-4][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\) 38 | suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(5[0-6]\\|[1-4][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+ 39 | suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy 40 | suppress_comment=\\(.\\|\n\\)*\\$FlowExpectedError 41 | 42 | unsafe.enable_getters_and_setters=true 43 | 44 | [version] 45 | ^0.56.0 46 | -------------------------------------------------------------------------------- /.github/demo.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anvilabs/react-native-image-carousel/71e5e5b2af551b1ac39c103acd6f32e9f594615f/.github/demo.gif -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # macOS 2 | # 3 | .DS_Store 4 | 5 | # node.js 6 | # 7 | /node_modules/ 8 | /npm-debug.log 9 | /yarn-error.log 10 | 11 | # VSCode 12 | # 13 | /.vscode/typings/ 14 | 15 | # ESLint 16 | # 17 | /.eslintcache 18 | 19 | # Flow 20 | # 21 | /flow-coverage/ 22 | 23 | # Webstorm 24 | # 25 | .idea/ 26 | -------------------------------------------------------------------------------- /.npmignore: -------------------------------------------------------------------------------- 1 | * 2 | !dist/ 3 | -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "editor.insertSpaces": true, 3 | "editor.rulers": [80], 4 | "editor.tabSize": 2, 5 | 6 | "eslint.autoFixOnSave": true, 7 | 8 | "flow.useNPMPackagedFlow": true, 9 | 10 | "javascript.validate.enable": false, 11 | 12 | "vsicons.presets.angular": false 13 | } 14 | -------------------------------------------------------------------------------- /Example/.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": [ 3 | "react-native" 4 | ] 5 | } 6 | -------------------------------------------------------------------------------- /Example/.gitattributes: -------------------------------------------------------------------------------- 1 | *.pbxproj -text 2 | -------------------------------------------------------------------------------- /Example/.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 | yarn-error.log 38 | 39 | # BUCK 40 | buck-out/ 41 | \.buckd/ 42 | *.keystore 43 | -------------------------------------------------------------------------------- /Example/.watchmanconfig: -------------------------------------------------------------------------------- 1 | {} -------------------------------------------------------------------------------- /Example/App.js: -------------------------------------------------------------------------------- 1 | /* @flow */ 2 | 3 | import { 4 | Image, 5 | StatusBar, 6 | StyleSheet, 7 | Text, 8 | TouchableWithoutFeedback, 9 | View, 10 | } from 'react-native'; 11 | import ImageCarousel from 'react-native-image-carousel'; 12 | import React, {Component} from 'react'; 13 | 14 | const urls = [ 15 | 'https://d919ce141ef35c47fc40-b9166a60eccf0f83d2d9c63fa65b9129.ssl.cf5.rackcdn.com/images/67003.max-620x600.jpg', 16 | 'https://d919ce141ef35c47fc40-b9166a60eccf0f83d2d9c63fa65b9129.ssl.cf5.rackcdn.com/images/51681.max-620x600.jpg', 17 | 'https://d919ce141ef35c47fc40-b9166a60eccf0f83d2d9c63fa65b9129.ssl.cf5.rackcdn.com/images/66812.max-620x600.jpg', 18 | 'https://myanimelist.cdn-dena.com/s/common/uploaded_files/1438960604-925d1997518b66f8508c749f36810793.jpeg', 19 | ]; 20 | 21 | class App extends Component { 22 | imageCarousel: React$Element<*>; 23 | 24 | componentDidMount() { 25 | StatusBar.setBarStyle('dark-content'); 26 | } 27 | 28 | captureImageCarousel = (imageCarousel: React$Element<*>) => { 29 | this.imageCarousel = imageCarousel; 30 | }; 31 | 32 | handleHeaderPress = () => (this.imageCarousel: $FlowFixMe).close(); 33 | 34 | renderHeader = (): React$Element<*> => ( 35 | 36 | 37 | Exit 38 | 39 | 40 | ); 41 | 42 | renderFooter = (): React$Element<*> => ( 43 | Footer! 44 | ); 45 | 46 | renderImage = (idx: number) => ( 47 | 52 | ); 53 | 54 | render() { 55 | return ( 56 | 57 | IMAGES 58 | 59 | 63 | {urls.map(url => ( 64 | 70 | ))} 71 | 72 | 73 | 74 | ); 75 | } 76 | } 77 | 78 | const styles = StyleSheet.create({ 79 | container: { 80 | flex: 1, 81 | justifyContent: 'center', 82 | }, 83 | closeText: { 84 | color: 'white', 85 | textAlign: 'right', 86 | padding: 10, 87 | }, 88 | footerText: { 89 | color: 'white', 90 | textAlign: 'center', 91 | }, 92 | image: { 93 | marginRight: 2, 94 | height: 100, 95 | }, 96 | }); 97 | 98 | export default App; 99 | -------------------------------------------------------------------------------- /Example/android/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: "com.android.application" 2 | 3 | import com.android.build.OutputFile 4 | 5 | /** 6 | * The react.gradle file registers a task for each build variant (e.g. bundleDebugJsAndAssets 7 | * and bundleReleaseJsAndAssets). 8 | * These basically call `react-native bundle` with the correct arguments during the Android build 9 | * cycle. By default, bundleDebugJsAndAssets is skipped, as in debug/dev mode we prefer to load the 10 | * bundle directly from the development server. Below you can see all the possible configurations 11 | * and their defaults. If you decide to add a configuration block, make sure to add it before the 12 | * `apply from: "../../node_modules/react-native/react.gradle"` line. 13 | * 14 | * project.ext.react = [ 15 | * // the name of the generated asset file containing your JS bundle 16 | * bundleAssetName: "index.android.bundle", 17 | * 18 | * // the entry file for bundle generation 19 | * entryFile: "index.android.js", 20 | * 21 | * // 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 | * // whether to disable dev mode in custom build variants (by default only disabled in release) 37 | * // for example: to disable dev mode in the staging build type (if configured) 38 | * devDisabledInStaging: true, 39 | * // The configuration property can be in the following formats 40 | * // 'devDisabledIn${productFlavor}${buildType}' 41 | * // 'devDisabledIn${buildType}' 42 | * 43 | * // the root of your project, i.e. where "package.json" lives 44 | * root: "../../", 45 | * 46 | * // where to put the JS bundle asset in debug mode 47 | * jsBundleDirDebug: "$buildDir/intermediates/assets/debug", 48 | * 49 | * // where to put the JS bundle asset in release mode 50 | * jsBundleDirRelease: "$buildDir/intermediates/assets/release", 51 | * 52 | * // where to put drawable resources / React Native assets, e.g. the ones you use via 53 | * // require('./image.png')), in debug mode 54 | * resourcesDirDebug: "$buildDir/intermediates/res/merged/debug", 55 | * 56 | * // where to put drawable resources / React Native assets, e.g. the ones you use via 57 | * // require('./image.png')), in release mode 58 | * resourcesDirRelease: "$buildDir/intermediates/res/merged/release", 59 | * 60 | * // by default the gradle tasks are skipped if none of the JS files or assets change; this means 61 | * // that we don't look at files in android/ or ios/ to determine whether the tasks are up to 62 | * // date; if you have any other folders that you want to ignore for performance reasons (gradle 63 | * // indexes the entire tree), add them here. Alternatively, if you have JS files in android/ 64 | * // for example, you might want to remove it from here. 65 | * inputExcludes: ["android/**", "ios/**"], 66 | * 67 | * // override which node gets called and with what additional arguments 68 | * nodeExecutableAndArgs: ["node"], 69 | * 70 | * // supply additional arguments to the packager 71 | * extraPackagerArgs: [] 72 | * ] 73 | */ 74 | 75 | project.ext.react = [ 76 | entryFile: "index.js" 77 | ] 78 | 79 | apply from: "../../node_modules/react-native/react.gradle" 80 | 81 | /** 82 | * Set this to true to create two separate APKs instead of one: 83 | * - An APK that only works on ARM devices 84 | * - An APK that only works on x86 devices 85 | * The advantage is the size of the APK is reduced by about 4MB. 86 | * Upload all the APKs to the Play Store and people will download 87 | * the correct one based on the CPU architecture of their device. 88 | */ 89 | def enableSeparateBuildPerCPUArchitecture = false 90 | 91 | /** 92 | * Run Proguard to shrink the Java bytecode in release builds. 93 | */ 94 | def enableProguardInReleaseBuilds = false 95 | 96 | android { 97 | compileSdkVersion 23 98 | buildToolsVersion "23.0.1" 99 | 100 | defaultConfig { 101 | applicationId "com.example" 102 | minSdkVersion 16 103 | targetSdkVersion 22 104 | versionCode 1 105 | versionName "1.0" 106 | ndk { 107 | abiFilters "armeabi-v7a", "x86" 108 | } 109 | } 110 | splits { 111 | abi { 112 | reset() 113 | enable enableSeparateBuildPerCPUArchitecture 114 | universalApk false // If true, also generate a universal APK 115 | include "armeabi-v7a", "x86" 116 | } 117 | } 118 | buildTypes { 119 | release { 120 | minifyEnabled enableProguardInReleaseBuilds 121 | proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro" 122 | } 123 | } 124 | // applicationVariants are e.g. debug, release 125 | applicationVariants.all { variant -> 126 | variant.outputs.each { output -> 127 | // For each separate APK per architecture, set a unique version code as described here: 128 | // http://tools.android.com/tech-docs/new-build-system/user-guide/apk-splits 129 | def versionCodes = ["armeabi-v7a":1, "x86":2] 130 | def abi = output.getFilter(OutputFile.ABI) 131 | if (abi != null) { // null for the universal-debug, universal-release variants 132 | output.versionCodeOverride = 133 | versionCodes.get(abi) * 1048576 + defaultConfig.versionCode 134 | } 135 | } 136 | } 137 | } 138 | 139 | dependencies { 140 | compile fileTree(dir: "libs", include: ["*.jar"]) 141 | compile "com.android.support:appcompat-v7:23.0.1" 142 | compile "com.facebook.react:react-native:+" // From node_modules 143 | } 144 | -------------------------------------------------------------------------------- /Example/android/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /usr/local/Cellar/android-sdk/24.3.3/tools/proguard/proguard-android.txt 4 | # You can edit the include path and order by changing the proguardFiles 5 | # directive in build.gradle. 6 | # 7 | # For more details, see 8 | # http://developer.android.com/guide/developing/tools/proguard.html 9 | 10 | # Add any project specific keep options here: 11 | 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 | # TextLayoutBuilder uses a non-public Android constructor within StaticLayout. 54 | # See libs/proxy/src/main/java/com/facebook/fbui/textlayoutbuilder/proxy for details. 55 | -dontwarn android.text.StaticLayout 56 | 57 | # okhttp 58 | 59 | -keepattributes Signature 60 | -keepattributes *Annotation* 61 | -keep class okhttp3.** { *; } 62 | -keep interface okhttp3.** { *; } 63 | -dontwarn okhttp3.** 64 | 65 | # okio 66 | 67 | -keep class sun.misc.Unsafe { *; } 68 | -dontwarn java.nio.file.* 69 | -dontwarn org.codehaus.mojo.animal_sniffer.IgnoreJRERequirement 70 | -dontwarn okio.** 71 | -------------------------------------------------------------------------------- /Example/android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 12 | 13 | 19 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /Example/android/app/src/main/java/com/example/MainActivity.java: -------------------------------------------------------------------------------- 1 | package com.example; 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 "Example"; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Example/android/app/src/main/java/com/example/MainApplication.java: -------------------------------------------------------------------------------- 1 | package com.example; 2 | 3 | import android.app.Application; 4 | 5 | import com.facebook.react.ReactApplication; 6 | import com.facebook.react.ReactNativeHost; 7 | import com.facebook.react.ReactPackage; 8 | import com.facebook.react.shell.MainReactPackage; 9 | import com.facebook.soloader.SoLoader; 10 | 11 | import java.util.Arrays; 12 | import java.util.List; 13 | 14 | public class MainApplication extends Application implements ReactApplication { 15 | 16 | private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) { 17 | @Override 18 | public boolean getUseDeveloperSupport() { 19 | return BuildConfig.DEBUG; 20 | } 21 | 22 | @Override 23 | protected List getPackages() { 24 | return Arrays.asList( 25 | new MainReactPackage() 26 | ); 27 | } 28 | 29 | @Override 30 | protected String getJSMainModuleName() { 31 | return "index"; 32 | } 33 | }; 34 | 35 | @Override 36 | public ReactNativeHost getReactNativeHost() { 37 | return mReactNativeHost; 38 | } 39 | 40 | @Override 41 | public void onCreate() { 42 | super.onCreate(); 43 | SoLoader.init(this, /* native exopackage */ false); 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /Example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anvilabs/react-native-image-carousel/71e5e5b2af551b1ac39c103acd6f32e9f594615f/Example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /Example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anvilabs/react-native-image-carousel/71e5e5b2af551b1ac39c103acd6f32e9f594615f/Example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /Example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anvilabs/react-native-image-carousel/71e5e5b2af551b1ac39c103acd6f32e9f594615f/Example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /Example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anvilabs/react-native-image-carousel/71e5e5b2af551b1ac39c103acd6f32e9f594615f/Example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /Example/android/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | Example 3 | 4 | -------------------------------------------------------------------------------- /Example/android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Example/android/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | repositories { 5 | jcenter() 6 | } 7 | dependencies { 8 | classpath 'com.android.tools.build:gradle:2.2.3' 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 | -------------------------------------------------------------------------------- /Example/android/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | 3 | # IDE (e.g. Android Studio) users: 4 | # Gradle settings configured through the IDE *will override* 5 | # any settings specified in this file. 6 | 7 | # For more details on how to configure your build environment visit 8 | # http://www.gradle.org/docs/current/userguide/build_environment.html 9 | 10 | # Specifies the JVM arguments used for the daemon process. 11 | # The setting is particularly useful for tweaking memory settings. 12 | # Default value: -Xmx10248m -XX:MaxPermSize=256m 13 | # org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 14 | 15 | # When configured, Gradle will run in incubating parallel mode. 16 | # This option should only be used with decoupled projects. More details, visit 17 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 18 | # org.gradle.parallel=true 19 | 20 | android.useDeprecatedNdk=true 21 | -------------------------------------------------------------------------------- /Example/android/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anvilabs/react-native-image-carousel/71e5e5b2af551b1ac39c103acd6f32e9f594615f/Example/android/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /Example/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.14.1-all.zip 6 | -------------------------------------------------------------------------------- /Example/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 | -------------------------------------------------------------------------------- /Example/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 | -------------------------------------------------------------------------------- /Example/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 | -------------------------------------------------------------------------------- /Example/android/settings.gradle: -------------------------------------------------------------------------------- 1 | rootProject.name = 'Example' 2 | 3 | include ':app' 4 | -------------------------------------------------------------------------------- /Example/app.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Example", 3 | "displayName": "Example" 4 | } -------------------------------------------------------------------------------- /Example/index.js: -------------------------------------------------------------------------------- 1 | /* @flow */ 2 | 3 | import {AppRegistry} from 'react-native'; 4 | 5 | import App from './App'; 6 | 7 | AppRegistry.registerComponent('Example', () => App); 8 | -------------------------------------------------------------------------------- /Example/ios/Example-tvOS/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 | 44 | NSExceptionDomains 45 | 46 | localhost 47 | 48 | NSExceptionAllowsInsecureHTTPLoads 49 | 50 | 51 | 52 | 53 | 54 | 55 | -------------------------------------------------------------------------------- /Example/ios/Example-tvOSTests/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 | -------------------------------------------------------------------------------- /Example/ios/Example.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 00C302E51ABCBA2D00DB3ED1 /* libRCTActionSheet.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302AC1ABCB8CE00DB3ED1 /* libRCTActionSheet.a */; }; 11 | 00C302E71ABCBA2D00DB3ED1 /* libRCTGeolocation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302BA1ABCB90400DB3ED1 /* libRCTGeolocation.a */; }; 12 | 00C302E81ABCBA2D00DB3ED1 /* libRCTImage.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302C01ABCB91800DB3ED1 /* libRCTImage.a */; }; 13 | 00C302E91ABCBA2D00DB3ED1 /* libRCTNetwork.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302DC1ABCB9D200DB3ED1 /* libRCTNetwork.a */; }; 14 | 00C302EA1ABCBA2D00DB3ED1 /* libRCTVibration.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302E41ABCB9EE00DB3ED1 /* libRCTVibration.a */; }; 15 | 00E356F31AD99517003FC87E /* ExampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* ExampleTests.m */; }; 16 | 133E29F31AD74F7200F7D852 /* libRCTLinking.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 78C398B91ACF4ADC00677621 /* libRCTLinking.a */; }; 17 | 139105C61AF99C1200B5F7CC /* libRCTSettings.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 139105C11AF99BAD00B5F7CC /* libRCTSettings.a */; }; 18 | 139FDEF61B0652A700C62182 /* libRCTWebSocket.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 139FDEF41B06529B00C62182 /* libRCTWebSocket.a */; }; 19 | 13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.m */; }; 20 | 13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB11A68108700A75B9A /* LaunchScreen.xib */; }; 21 | 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; }; 22 | 13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; }; 23 | 140ED2AC1D01E1AD002B40FF /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 146834041AC3E56700842450 /* libReact.a */; }; 24 | 146834051AC3E58100842450 /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 146834041AC3E56700842450 /* libReact.a */; }; 25 | 2D02E4BC1E0B4A80006451C7 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.m */; }; 26 | 2D02E4BD1E0B4A84006451C7 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; }; 27 | 2D02E4BF1E0B4AB3006451C7 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; }; 28 | 2D02E4C21E0B4AEC006451C7 /* libRCTAnimation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5E9157351DD0AC6500FF2AA8 /* libRCTAnimation.a */; }; 29 | 2D02E4C31E0B4AEC006451C7 /* libRCTImage-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E841DF850E9000B6D8A /* libRCTImage-tvOS.a */; }; 30 | 2D02E4C41E0B4AEC006451C7 /* libRCTLinking-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E881DF850E9000B6D8A /* libRCTLinking-tvOS.a */; }; 31 | 2D02E4C51E0B4AEC006451C7 /* libRCTNetwork-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E8C1DF850E9000B6D8A /* libRCTNetwork-tvOS.a */; }; 32 | 2D02E4C61E0B4AEC006451C7 /* libRCTSettings-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E901DF850E9000B6D8A /* libRCTSettings-tvOS.a */; }; 33 | 2D02E4C71E0B4AEC006451C7 /* libRCTText-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E941DF850E9000B6D8A /* libRCTText-tvOS.a */; }; 34 | 2D02E4C81E0B4AEC006451C7 /* libRCTWebSocket-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E991DF850E9000B6D8A /* libRCTWebSocket-tvOS.a */; }; 35 | 2D02E4C91E0B4AEC006451C7 /* libReact-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3EA31DF850E9000B6D8A /* libReact-tvOS.a */; }; 36 | 2DCD954D1E0B4F2C00145EB5 /* ExampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* ExampleTests.m */; }; 37 | 5E9157361DD0AC6A00FF2AA8 /* libRCTAnimation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5E9157331DD0AC6500FF2AA8 /* libRCTAnimation.a */; }; 38 | 832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 832341B51AAA6A8300B99B32 /* libRCTText.a */; }; 39 | ADBDB9381DFEBF1600ED6528 /* libRCTBlob.a in Frameworks */ = {isa = PBXBuildFile; fileRef = ADBDB9271DFEBF0700ED6528 /* libRCTBlob.a */; }; 40 | /* End PBXBuildFile section */ 41 | 42 | /* Begin PBXContainerItemProxy section */ 43 | 00C302AB1ABCB8CE00DB3ED1 /* PBXContainerItemProxy */ = { 44 | isa = PBXContainerItemProxy; 45 | containerPortal = 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */; 46 | proxyType = 2; 47 | remoteGlobalIDString = 134814201AA4EA6300B7C361; 48 | remoteInfo = RCTActionSheet; 49 | }; 50 | 00C302B91ABCB90400DB3ED1 /* PBXContainerItemProxy */ = { 51 | isa = PBXContainerItemProxy; 52 | containerPortal = 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */; 53 | proxyType = 2; 54 | remoteGlobalIDString = 134814201AA4EA6300B7C361; 55 | remoteInfo = RCTGeolocation; 56 | }; 57 | 00C302BF1ABCB91800DB3ED1 /* PBXContainerItemProxy */ = { 58 | isa = PBXContainerItemProxy; 59 | containerPortal = 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */; 60 | proxyType = 2; 61 | remoteGlobalIDString = 58B5115D1A9E6B3D00147676; 62 | remoteInfo = RCTImage; 63 | }; 64 | 00C302DB1ABCB9D200DB3ED1 /* PBXContainerItemProxy */ = { 65 | isa = PBXContainerItemProxy; 66 | containerPortal = 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */; 67 | proxyType = 2; 68 | remoteGlobalIDString = 58B511DB1A9E6C8500147676; 69 | remoteInfo = RCTNetwork; 70 | }; 71 | 00C302E31ABCB9EE00DB3ED1 /* PBXContainerItemProxy */ = { 72 | isa = PBXContainerItemProxy; 73 | containerPortal = 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */; 74 | proxyType = 2; 75 | remoteGlobalIDString = 832C81801AAF6DEF007FA2F7; 76 | remoteInfo = RCTVibration; 77 | }; 78 | 00E356F41AD99517003FC87E /* PBXContainerItemProxy */ = { 79 | isa = PBXContainerItemProxy; 80 | containerPortal = 83CBB9F71A601CBA00E9B192 /* Project object */; 81 | proxyType = 1; 82 | remoteGlobalIDString = 13B07F861A680F5B00A75B9A; 83 | remoteInfo = Example; 84 | }; 85 | 139105C01AF99BAD00B5F7CC /* PBXContainerItemProxy */ = { 86 | isa = PBXContainerItemProxy; 87 | containerPortal = 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */; 88 | proxyType = 2; 89 | remoteGlobalIDString = 134814201AA4EA6300B7C361; 90 | remoteInfo = RCTSettings; 91 | }; 92 | 139FDEF31B06529B00C62182 /* PBXContainerItemProxy */ = { 93 | isa = PBXContainerItemProxy; 94 | containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */; 95 | proxyType = 2; 96 | remoteGlobalIDString = 3C86DF461ADF2C930047B81A; 97 | remoteInfo = RCTWebSocket; 98 | }; 99 | 146834031AC3E56700842450 /* PBXContainerItemProxy */ = { 100 | isa = PBXContainerItemProxy; 101 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 102 | proxyType = 2; 103 | remoteGlobalIDString = 83CBBA2E1A601D0E00E9B192; 104 | remoteInfo = React; 105 | }; 106 | 2D02E4911E0B4A5D006451C7 /* PBXContainerItemProxy */ = { 107 | isa = PBXContainerItemProxy; 108 | containerPortal = 83CBB9F71A601CBA00E9B192 /* Project object */; 109 | proxyType = 1; 110 | remoteGlobalIDString = 2D02E47A1E0B4A5D006451C7; 111 | remoteInfo = "Example-tvOS"; 112 | }; 113 | 3A15EA041FAF384800A3DE6F /* PBXContainerItemProxy */ = { 114 | isa = PBXContainerItemProxy; 115 | containerPortal = ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */; 116 | proxyType = 2; 117 | remoteGlobalIDString = ADD01A681E09402E00F6D226; 118 | remoteInfo = "RCTBlob-tvOS"; 119 | }; 120 | 3A15EA161FAF384900A3DE6F /* PBXContainerItemProxy */ = { 121 | isa = PBXContainerItemProxy; 122 | containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */; 123 | proxyType = 2; 124 | remoteGlobalIDString = 3DBE0D001F3B181A0099AA32; 125 | remoteInfo = fishhook; 126 | }; 127 | 3A15EA181FAF384900A3DE6F /* PBXContainerItemProxy */ = { 128 | isa = PBXContainerItemProxy; 129 | containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */; 130 | proxyType = 2; 131 | remoteGlobalIDString = 3DBE0D0D1F3B181C0099AA32; 132 | remoteInfo = "fishhook-tvOS"; 133 | }; 134 | 3DAD3E831DF850E9000B6D8A /* PBXContainerItemProxy */ = { 135 | isa = PBXContainerItemProxy; 136 | containerPortal = 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */; 137 | proxyType = 2; 138 | remoteGlobalIDString = 2D2A283A1D9B042B00D4039D; 139 | remoteInfo = "RCTImage-tvOS"; 140 | }; 141 | 3DAD3E871DF850E9000B6D8A /* PBXContainerItemProxy */ = { 142 | isa = PBXContainerItemProxy; 143 | containerPortal = 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */; 144 | proxyType = 2; 145 | remoteGlobalIDString = 2D2A28471D9B043800D4039D; 146 | remoteInfo = "RCTLinking-tvOS"; 147 | }; 148 | 3DAD3E8B1DF850E9000B6D8A /* PBXContainerItemProxy */ = { 149 | isa = PBXContainerItemProxy; 150 | containerPortal = 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */; 151 | proxyType = 2; 152 | remoteGlobalIDString = 2D2A28541D9B044C00D4039D; 153 | remoteInfo = "RCTNetwork-tvOS"; 154 | }; 155 | 3DAD3E8F1DF850E9000B6D8A /* PBXContainerItemProxy */ = { 156 | isa = PBXContainerItemProxy; 157 | containerPortal = 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */; 158 | proxyType = 2; 159 | remoteGlobalIDString = 2D2A28611D9B046600D4039D; 160 | remoteInfo = "RCTSettings-tvOS"; 161 | }; 162 | 3DAD3E931DF850E9000B6D8A /* PBXContainerItemProxy */ = { 163 | isa = PBXContainerItemProxy; 164 | containerPortal = 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */; 165 | proxyType = 2; 166 | remoteGlobalIDString = 2D2A287B1D9B048500D4039D; 167 | remoteInfo = "RCTText-tvOS"; 168 | }; 169 | 3DAD3E981DF850E9000B6D8A /* PBXContainerItemProxy */ = { 170 | isa = PBXContainerItemProxy; 171 | containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */; 172 | proxyType = 2; 173 | remoteGlobalIDString = 2D2A28881D9B049200D4039D; 174 | remoteInfo = "RCTWebSocket-tvOS"; 175 | }; 176 | 3DAD3EA21DF850E9000B6D8A /* PBXContainerItemProxy */ = { 177 | isa = PBXContainerItemProxy; 178 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 179 | proxyType = 2; 180 | remoteGlobalIDString = 2D2A28131D9B038B00D4039D; 181 | remoteInfo = "React-tvOS"; 182 | }; 183 | 3DAD3EA41DF850E9000B6D8A /* PBXContainerItemProxy */ = { 184 | isa = PBXContainerItemProxy; 185 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 186 | proxyType = 2; 187 | remoteGlobalIDString = 3D3C059A1DE3340900C268FA; 188 | remoteInfo = yoga; 189 | }; 190 | 3DAD3EA61DF850E9000B6D8A /* PBXContainerItemProxy */ = { 191 | isa = PBXContainerItemProxy; 192 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 193 | proxyType = 2; 194 | remoteGlobalIDString = 3D3C06751DE3340C00C268FA; 195 | remoteInfo = "yoga-tvOS"; 196 | }; 197 | 3DAD3EA81DF850E9000B6D8A /* PBXContainerItemProxy */ = { 198 | isa = PBXContainerItemProxy; 199 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 200 | proxyType = 2; 201 | remoteGlobalIDString = 3D3CD9251DE5FBEC00167DC4; 202 | remoteInfo = cxxreact; 203 | }; 204 | 3DAD3EAA1DF850E9000B6D8A /* PBXContainerItemProxy */ = { 205 | isa = PBXContainerItemProxy; 206 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 207 | proxyType = 2; 208 | remoteGlobalIDString = 3D3CD9321DE5FBEE00167DC4; 209 | remoteInfo = "cxxreact-tvOS"; 210 | }; 211 | 3DAD3EAC1DF850E9000B6D8A /* PBXContainerItemProxy */ = { 212 | isa = PBXContainerItemProxy; 213 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 214 | proxyType = 2; 215 | remoteGlobalIDString = 3D3CD90B1DE5FBD600167DC4; 216 | remoteInfo = jschelpers; 217 | }; 218 | 3DAD3EAE1DF850E9000B6D8A /* PBXContainerItemProxy */ = { 219 | isa = PBXContainerItemProxy; 220 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 221 | proxyType = 2; 222 | remoteGlobalIDString = 3D3CD9181DE5FBD800167DC4; 223 | remoteInfo = "jschelpers-tvOS"; 224 | }; 225 | 5E9157321DD0AC6500FF2AA8 /* PBXContainerItemProxy */ = { 226 | isa = PBXContainerItemProxy; 227 | containerPortal = 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */; 228 | proxyType = 2; 229 | remoteGlobalIDString = 134814201AA4EA6300B7C361; 230 | remoteInfo = RCTAnimation; 231 | }; 232 | 5E9157341DD0AC6500FF2AA8 /* PBXContainerItemProxy */ = { 233 | isa = PBXContainerItemProxy; 234 | containerPortal = 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */; 235 | proxyType = 2; 236 | remoteGlobalIDString = 2D2A28201D9B03D100D4039D; 237 | remoteInfo = "RCTAnimation-tvOS"; 238 | }; 239 | 78C398B81ACF4ADC00677621 /* PBXContainerItemProxy */ = { 240 | isa = PBXContainerItemProxy; 241 | containerPortal = 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */; 242 | proxyType = 2; 243 | remoteGlobalIDString = 134814201AA4EA6300B7C361; 244 | remoteInfo = RCTLinking; 245 | }; 246 | 832341B41AAA6A8300B99B32 /* PBXContainerItemProxy */ = { 247 | isa = PBXContainerItemProxy; 248 | containerPortal = 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */; 249 | proxyType = 2; 250 | remoteGlobalIDString = 58B5119B1A9E6C1200147676; 251 | remoteInfo = RCTText; 252 | }; 253 | ADBDB9261DFEBF0700ED6528 /* PBXContainerItemProxy */ = { 254 | isa = PBXContainerItemProxy; 255 | containerPortal = ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */; 256 | proxyType = 2; 257 | remoteGlobalIDString = 358F4ED71D1E81A9004DF814; 258 | remoteInfo = RCTBlob; 259 | }; 260 | /* End PBXContainerItemProxy section */ 261 | 262 | /* Begin PBXFileReference section */ 263 | 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTActionSheet.xcodeproj; path = "../node_modules/react-native/Libraries/ActionSheetIOS/RCTActionSheet.xcodeproj"; sourceTree = ""; }; 264 | 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTGeolocation.xcodeproj; path = "../node_modules/react-native/Libraries/Geolocation/RCTGeolocation.xcodeproj"; sourceTree = ""; }; 265 | 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTImage.xcodeproj; path = "../node_modules/react-native/Libraries/Image/RCTImage.xcodeproj"; sourceTree = ""; }; 266 | 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTNetwork.xcodeproj; path = "../node_modules/react-native/Libraries/Network/RCTNetwork.xcodeproj"; sourceTree = ""; }; 267 | 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTVibration.xcodeproj; path = "../node_modules/react-native/Libraries/Vibration/RCTVibration.xcodeproj"; sourceTree = ""; }; 268 | 00E356EE1AD99517003FC87E /* ExampleTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = ExampleTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 269 | 00E356F11AD99517003FC87E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 270 | 00E356F21AD99517003FC87E /* ExampleTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ExampleTests.m; sourceTree = ""; }; 271 | 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTSettings.xcodeproj; path = "../node_modules/react-native/Libraries/Settings/RCTSettings.xcodeproj"; sourceTree = ""; }; 272 | 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTWebSocket.xcodeproj; path = "../node_modules/react-native/Libraries/WebSocket/RCTWebSocket.xcodeproj"; sourceTree = ""; }; 273 | 13B07F961A680F5B00A75B9A /* Example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Example.app; sourceTree = BUILT_PRODUCTS_DIR; }; 274 | 13B07FAF1A68108700A75B9A /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = Example/AppDelegate.h; sourceTree = ""; }; 275 | 13B07FB01A68108700A75B9A /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = AppDelegate.m; path = Example/AppDelegate.m; sourceTree = ""; }; 276 | 13B07FB21A68108700A75B9A /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = ""; }; 277 | 13B07FB51A68108700A75B9A /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = Example/Images.xcassets; sourceTree = ""; }; 278 | 13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = Example/Info.plist; sourceTree = ""; }; 279 | 13B07FB71A68108700A75B9A /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = Example/main.m; sourceTree = ""; }; 280 | 146833FF1AC3E56700842450 /* React.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = React.xcodeproj; path = "../node_modules/react-native/React/React.xcodeproj"; sourceTree = ""; }; 281 | 2D02E47B1E0B4A5D006451C7 /* Example-tvOS.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Example-tvOS.app"; sourceTree = BUILT_PRODUCTS_DIR; }; 282 | 2D02E4901E0B4A5D006451C7 /* Example-tvOSTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "Example-tvOSTests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; }; 283 | 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTAnimation.xcodeproj; path = "../node_modules/react-native/Libraries/NativeAnimation/RCTAnimation.xcodeproj"; sourceTree = ""; }; 284 | 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTLinking.xcodeproj; path = "../node_modules/react-native/Libraries/LinkingIOS/RCTLinking.xcodeproj"; sourceTree = ""; }; 285 | 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTText.xcodeproj; path = "../node_modules/react-native/Libraries/Text/RCTText.xcodeproj"; sourceTree = ""; }; 286 | ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTBlob.xcodeproj; path = "../node_modules/react-native/Libraries/Blob/RCTBlob.xcodeproj"; sourceTree = ""; }; 287 | /* End PBXFileReference section */ 288 | 289 | /* Begin PBXFrameworksBuildPhase section */ 290 | 00E356EB1AD99517003FC87E /* Frameworks */ = { 291 | isa = PBXFrameworksBuildPhase; 292 | buildActionMask = 2147483647; 293 | files = ( 294 | 140ED2AC1D01E1AD002B40FF /* libReact.a in Frameworks */, 295 | ); 296 | runOnlyForDeploymentPostprocessing = 0; 297 | }; 298 | 13B07F8C1A680F5B00A75B9A /* Frameworks */ = { 299 | isa = PBXFrameworksBuildPhase; 300 | buildActionMask = 2147483647; 301 | files = ( 302 | ADBDB9381DFEBF1600ED6528 /* libRCTBlob.a in Frameworks */, 303 | 5E9157361DD0AC6A00FF2AA8 /* libRCTAnimation.a in Frameworks */, 304 | 146834051AC3E58100842450 /* libReact.a in Frameworks */, 305 | 5E9157361DD0AC6A00FF2AA8 /* libRCTAnimation.a in Frameworks */, 306 | 00C302E51ABCBA2D00DB3ED1 /* libRCTActionSheet.a in Frameworks */, 307 | 00C302E71ABCBA2D00DB3ED1 /* libRCTGeolocation.a in Frameworks */, 308 | 00C302E81ABCBA2D00DB3ED1 /* libRCTImage.a in Frameworks */, 309 | 133E29F31AD74F7200F7D852 /* libRCTLinking.a in Frameworks */, 310 | 00C302E91ABCBA2D00DB3ED1 /* libRCTNetwork.a in Frameworks */, 311 | 139105C61AF99C1200B5F7CC /* libRCTSettings.a in Frameworks */, 312 | 832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */, 313 | 00C302EA1ABCBA2D00DB3ED1 /* libRCTVibration.a in Frameworks */, 314 | 139FDEF61B0652A700C62182 /* libRCTWebSocket.a in Frameworks */, 315 | ); 316 | runOnlyForDeploymentPostprocessing = 0; 317 | }; 318 | 2D02E4781E0B4A5D006451C7 /* Frameworks */ = { 319 | isa = PBXFrameworksBuildPhase; 320 | buildActionMask = 2147483647; 321 | files = ( 322 | 2D02E4C91E0B4AEC006451C7 /* libReact-tvOS.a in Frameworks */, 323 | 2D02E4C21E0B4AEC006451C7 /* libRCTAnimation.a in Frameworks */, 324 | 2D02E4C31E0B4AEC006451C7 /* libRCTImage-tvOS.a in Frameworks */, 325 | 2D02E4C41E0B4AEC006451C7 /* libRCTLinking-tvOS.a in Frameworks */, 326 | 2D02E4C51E0B4AEC006451C7 /* libRCTNetwork-tvOS.a in Frameworks */, 327 | 2D02E4C61E0B4AEC006451C7 /* libRCTSettings-tvOS.a in Frameworks */, 328 | 2D02E4C71E0B4AEC006451C7 /* libRCTText-tvOS.a in Frameworks */, 329 | 2D02E4C81E0B4AEC006451C7 /* libRCTWebSocket-tvOS.a in Frameworks */, 330 | ); 331 | runOnlyForDeploymentPostprocessing = 0; 332 | }; 333 | 2D02E48D1E0B4A5D006451C7 /* Frameworks */ = { 334 | isa = PBXFrameworksBuildPhase; 335 | buildActionMask = 2147483647; 336 | files = ( 337 | ); 338 | runOnlyForDeploymentPostprocessing = 0; 339 | }; 340 | /* End PBXFrameworksBuildPhase section */ 341 | 342 | /* Begin PBXGroup section */ 343 | 00C302A81ABCB8CE00DB3ED1 /* Products */ = { 344 | isa = PBXGroup; 345 | children = ( 346 | 00C302AC1ABCB8CE00DB3ED1 /* libRCTActionSheet.a */, 347 | ); 348 | name = Products; 349 | sourceTree = ""; 350 | }; 351 | 00C302B61ABCB90400DB3ED1 /* Products */ = { 352 | isa = PBXGroup; 353 | children = ( 354 | 00C302BA1ABCB90400DB3ED1 /* libRCTGeolocation.a */, 355 | ); 356 | name = Products; 357 | sourceTree = ""; 358 | }; 359 | 00C302BC1ABCB91800DB3ED1 /* Products */ = { 360 | isa = PBXGroup; 361 | children = ( 362 | 00C302C01ABCB91800DB3ED1 /* libRCTImage.a */, 363 | 3DAD3E841DF850E9000B6D8A /* libRCTImage-tvOS.a */, 364 | ); 365 | name = Products; 366 | sourceTree = ""; 367 | }; 368 | 00C302D41ABCB9D200DB3ED1 /* Products */ = { 369 | isa = PBXGroup; 370 | children = ( 371 | 00C302DC1ABCB9D200DB3ED1 /* libRCTNetwork.a */, 372 | 3DAD3E8C1DF850E9000B6D8A /* libRCTNetwork-tvOS.a */, 373 | ); 374 | name = Products; 375 | sourceTree = ""; 376 | }; 377 | 00C302E01ABCB9EE00DB3ED1 /* Products */ = { 378 | isa = PBXGroup; 379 | children = ( 380 | 00C302E41ABCB9EE00DB3ED1 /* libRCTVibration.a */, 381 | ); 382 | name = Products; 383 | sourceTree = ""; 384 | }; 385 | 00E356EF1AD99517003FC87E /* ExampleTests */ = { 386 | isa = PBXGroup; 387 | children = ( 388 | 00E356F21AD99517003FC87E /* ExampleTests.m */, 389 | 00E356F01AD99517003FC87E /* Supporting Files */, 390 | ); 391 | path = ExampleTests; 392 | sourceTree = ""; 393 | }; 394 | 00E356F01AD99517003FC87E /* Supporting Files */ = { 395 | isa = PBXGroup; 396 | children = ( 397 | 00E356F11AD99517003FC87E /* Info.plist */, 398 | ); 399 | name = "Supporting Files"; 400 | sourceTree = ""; 401 | }; 402 | 139105B71AF99BAD00B5F7CC /* Products */ = { 403 | isa = PBXGroup; 404 | children = ( 405 | 139105C11AF99BAD00B5F7CC /* libRCTSettings.a */, 406 | 3DAD3E901DF850E9000B6D8A /* libRCTSettings-tvOS.a */, 407 | ); 408 | name = Products; 409 | sourceTree = ""; 410 | }; 411 | 139FDEE71B06529A00C62182 /* Products */ = { 412 | isa = PBXGroup; 413 | children = ( 414 | 139FDEF41B06529B00C62182 /* libRCTWebSocket.a */, 415 | 3DAD3E991DF850E9000B6D8A /* libRCTWebSocket-tvOS.a */, 416 | 3A15EA171FAF384900A3DE6F /* libfishhook.a */, 417 | 3A15EA191FAF384900A3DE6F /* libfishhook-tvOS.a */, 418 | ); 419 | name = Products; 420 | sourceTree = ""; 421 | }; 422 | 13B07FAE1A68108700A75B9A /* Example */ = { 423 | isa = PBXGroup; 424 | children = ( 425 | 13B07FAF1A68108700A75B9A /* AppDelegate.h */, 426 | 13B07FB01A68108700A75B9A /* AppDelegate.m */, 427 | 13B07FB51A68108700A75B9A /* Images.xcassets */, 428 | 13B07FB61A68108700A75B9A /* Info.plist */, 429 | 13B07FB11A68108700A75B9A /* LaunchScreen.xib */, 430 | 13B07FB71A68108700A75B9A /* main.m */, 431 | ); 432 | name = Example; 433 | sourceTree = ""; 434 | }; 435 | 146834001AC3E56700842450 /* Products */ = { 436 | isa = PBXGroup; 437 | children = ( 438 | 146834041AC3E56700842450 /* libReact.a */, 439 | 3DAD3EA51DF850E9000B6D8A /* libyoga.a */, 440 | 3DAD3EA71DF850E9000B6D8A /* libyoga.a */, 441 | 3DAD3EA91DF850E9000B6D8A /* libcxxreact.a */, 442 | 3DAD3EAB1DF850E9000B6D8A /* libcxxreact.a */, 443 | 3DAD3EAD1DF850E9000B6D8A /* libjschelpers.a */, 444 | 3DAD3EAF1DF850E9000B6D8A /* libjschelpers.a */, 445 | 3DAD3EA31DF850E9000B6D8A /* libReact-tvOS.a */, 446 | ); 447 | name = Products; 448 | sourceTree = ""; 449 | }; 450 | 5E91572E1DD0AC6500FF2AA8 /* Products */ = { 451 | isa = PBXGroup; 452 | children = ( 453 | 5E9157331DD0AC6500FF2AA8 /* libRCTAnimation.a */, 454 | 5E9157351DD0AC6500FF2AA8 /* libRCTAnimation.a */, 455 | ); 456 | name = Products; 457 | sourceTree = ""; 458 | }; 459 | 78C398B11ACF4ADC00677621 /* Products */ = { 460 | isa = PBXGroup; 461 | children = ( 462 | 78C398B91ACF4ADC00677621 /* libRCTLinking.a */, 463 | 3DAD3E881DF850E9000B6D8A /* libRCTLinking-tvOS.a */, 464 | ); 465 | name = Products; 466 | sourceTree = ""; 467 | }; 468 | 832341AE1AAA6A7D00B99B32 /* Libraries */ = { 469 | isa = PBXGroup; 470 | children = ( 471 | 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */, 472 | 146833FF1AC3E56700842450 /* React.xcodeproj */, 473 | 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */, 474 | ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */, 475 | 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */, 476 | 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */, 477 | 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */, 478 | 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */, 479 | 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */, 480 | 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */, 481 | 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */, 482 | 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */, 483 | ); 484 | name = Libraries; 485 | sourceTree = ""; 486 | }; 487 | 832341B11AAA6A8300B99B32 /* Products */ = { 488 | isa = PBXGroup; 489 | children = ( 490 | 832341B51AAA6A8300B99B32 /* libRCTText.a */, 491 | 3DAD3E941DF850E9000B6D8A /* libRCTText-tvOS.a */, 492 | ); 493 | name = Products; 494 | sourceTree = ""; 495 | }; 496 | 83CBB9F61A601CBA00E9B192 = { 497 | isa = PBXGroup; 498 | children = ( 499 | 13B07FAE1A68108700A75B9A /* Example */, 500 | 832341AE1AAA6A7D00B99B32 /* Libraries */, 501 | 00E356EF1AD99517003FC87E /* ExampleTests */, 502 | 83CBBA001A601CBA00E9B192 /* Products */, 503 | ); 504 | indentWidth = 2; 505 | sourceTree = ""; 506 | tabWidth = 2; 507 | usesTabs = 0; 508 | }; 509 | 83CBBA001A601CBA00E9B192 /* Products */ = { 510 | isa = PBXGroup; 511 | children = ( 512 | 13B07F961A680F5B00A75B9A /* Example.app */, 513 | 00E356EE1AD99517003FC87E /* ExampleTests.xctest */, 514 | 2D02E47B1E0B4A5D006451C7 /* Example-tvOS.app */, 515 | 2D02E4901E0B4A5D006451C7 /* Example-tvOSTests.xctest */, 516 | ); 517 | name = Products; 518 | sourceTree = ""; 519 | }; 520 | ADBDB9201DFEBF0600ED6528 /* Products */ = { 521 | isa = PBXGroup; 522 | children = ( 523 | ADBDB9271DFEBF0700ED6528 /* libRCTBlob.a */, 524 | 3A15EA051FAF384800A3DE6F /* libRCTBlob-tvOS.a */, 525 | ); 526 | name = Products; 527 | sourceTree = ""; 528 | }; 529 | /* End PBXGroup section */ 530 | 531 | /* Begin PBXNativeTarget section */ 532 | 00E356ED1AD99517003FC87E /* ExampleTests */ = { 533 | isa = PBXNativeTarget; 534 | buildConfigurationList = 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "ExampleTests" */; 535 | buildPhases = ( 536 | 00E356EA1AD99517003FC87E /* Sources */, 537 | 00E356EB1AD99517003FC87E /* Frameworks */, 538 | 00E356EC1AD99517003FC87E /* Resources */, 539 | ); 540 | buildRules = ( 541 | ); 542 | dependencies = ( 543 | 00E356F51AD99517003FC87E /* PBXTargetDependency */, 544 | ); 545 | name = ExampleTests; 546 | productName = ExampleTests; 547 | productReference = 00E356EE1AD99517003FC87E /* ExampleTests.xctest */; 548 | productType = "com.apple.product-type.bundle.unit-test"; 549 | }; 550 | 13B07F861A680F5B00A75B9A /* Example */ = { 551 | isa = PBXNativeTarget; 552 | buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "Example" */; 553 | buildPhases = ( 554 | 13B07F871A680F5B00A75B9A /* Sources */, 555 | 13B07F8C1A680F5B00A75B9A /* Frameworks */, 556 | 13B07F8E1A680F5B00A75B9A /* Resources */, 557 | 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */, 558 | ); 559 | buildRules = ( 560 | ); 561 | dependencies = ( 562 | ); 563 | name = Example; 564 | productName = "Hello World"; 565 | productReference = 13B07F961A680F5B00A75B9A /* Example.app */; 566 | productType = "com.apple.product-type.application"; 567 | }; 568 | 2D02E47A1E0B4A5D006451C7 /* Example-tvOS */ = { 569 | isa = PBXNativeTarget; 570 | buildConfigurationList = 2D02E4BA1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "Example-tvOS" */; 571 | buildPhases = ( 572 | 2D02E4771E0B4A5D006451C7 /* Sources */, 573 | 2D02E4781E0B4A5D006451C7 /* Frameworks */, 574 | 2D02E4791E0B4A5D006451C7 /* Resources */, 575 | 2D02E4CB1E0B4B27006451C7 /* Bundle React Native Code And Images */, 576 | ); 577 | buildRules = ( 578 | ); 579 | dependencies = ( 580 | ); 581 | name = "Example-tvOS"; 582 | productName = "Example-tvOS"; 583 | productReference = 2D02E47B1E0B4A5D006451C7 /* Example-tvOS.app */; 584 | productType = "com.apple.product-type.application"; 585 | }; 586 | 2D02E48F1E0B4A5D006451C7 /* Example-tvOSTests */ = { 587 | isa = PBXNativeTarget; 588 | buildConfigurationList = 2D02E4BB1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "Example-tvOSTests" */; 589 | buildPhases = ( 590 | 2D02E48C1E0B4A5D006451C7 /* Sources */, 591 | 2D02E48D1E0B4A5D006451C7 /* Frameworks */, 592 | 2D02E48E1E0B4A5D006451C7 /* Resources */, 593 | ); 594 | buildRules = ( 595 | ); 596 | dependencies = ( 597 | 2D02E4921E0B4A5D006451C7 /* PBXTargetDependency */, 598 | ); 599 | name = "Example-tvOSTests"; 600 | productName = "Example-tvOSTests"; 601 | productReference = 2D02E4901E0B4A5D006451C7 /* Example-tvOSTests.xctest */; 602 | productType = "com.apple.product-type.bundle.unit-test"; 603 | }; 604 | /* End PBXNativeTarget section */ 605 | 606 | /* Begin PBXProject section */ 607 | 83CBB9F71A601CBA00E9B192 /* Project object */ = { 608 | isa = PBXProject; 609 | attributes = { 610 | LastUpgradeCheck = 0610; 611 | ORGANIZATIONNAME = Facebook; 612 | TargetAttributes = { 613 | 00E356ED1AD99517003FC87E = { 614 | CreatedOnToolsVersion = 6.2; 615 | TestTargetID = 13B07F861A680F5B00A75B9A; 616 | }; 617 | 2D02E47A1E0B4A5D006451C7 = { 618 | CreatedOnToolsVersion = 8.2.1; 619 | ProvisioningStyle = Automatic; 620 | }; 621 | 2D02E48F1E0B4A5D006451C7 = { 622 | CreatedOnToolsVersion = 8.2.1; 623 | ProvisioningStyle = Automatic; 624 | TestTargetID = 2D02E47A1E0B4A5D006451C7; 625 | }; 626 | }; 627 | }; 628 | buildConfigurationList = 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "Example" */; 629 | compatibilityVersion = "Xcode 3.2"; 630 | developmentRegion = English; 631 | hasScannedForEncodings = 0; 632 | knownRegions = ( 633 | en, 634 | Base, 635 | ); 636 | mainGroup = 83CBB9F61A601CBA00E9B192; 637 | productRefGroup = 83CBBA001A601CBA00E9B192 /* Products */; 638 | projectDirPath = ""; 639 | projectReferences = ( 640 | { 641 | ProductGroup = 00C302A81ABCB8CE00DB3ED1 /* Products */; 642 | ProjectRef = 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */; 643 | }, 644 | { 645 | ProductGroup = 5E91572E1DD0AC6500FF2AA8 /* Products */; 646 | ProjectRef = 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */; 647 | }, 648 | { 649 | ProductGroup = ADBDB9201DFEBF0600ED6528 /* Products */; 650 | ProjectRef = ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */; 651 | }, 652 | { 653 | ProductGroup = 00C302B61ABCB90400DB3ED1 /* Products */; 654 | ProjectRef = 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */; 655 | }, 656 | { 657 | ProductGroup = 00C302BC1ABCB91800DB3ED1 /* Products */; 658 | ProjectRef = 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */; 659 | }, 660 | { 661 | ProductGroup = 78C398B11ACF4ADC00677621 /* Products */; 662 | ProjectRef = 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */; 663 | }, 664 | { 665 | ProductGroup = 00C302D41ABCB9D200DB3ED1 /* Products */; 666 | ProjectRef = 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */; 667 | }, 668 | { 669 | ProductGroup = 139105B71AF99BAD00B5F7CC /* Products */; 670 | ProjectRef = 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */; 671 | }, 672 | { 673 | ProductGroup = 832341B11AAA6A8300B99B32 /* Products */; 674 | ProjectRef = 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */; 675 | }, 676 | { 677 | ProductGroup = 00C302E01ABCB9EE00DB3ED1 /* Products */; 678 | ProjectRef = 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */; 679 | }, 680 | { 681 | ProductGroup = 139FDEE71B06529A00C62182 /* Products */; 682 | ProjectRef = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */; 683 | }, 684 | { 685 | ProductGroup = 146834001AC3E56700842450 /* Products */; 686 | ProjectRef = 146833FF1AC3E56700842450 /* React.xcodeproj */; 687 | }, 688 | ); 689 | projectRoot = ""; 690 | targets = ( 691 | 13B07F861A680F5B00A75B9A /* Example */, 692 | 00E356ED1AD99517003FC87E /* ExampleTests */, 693 | 2D02E47A1E0B4A5D006451C7 /* Example-tvOS */, 694 | 2D02E48F1E0B4A5D006451C7 /* Example-tvOSTests */, 695 | ); 696 | }; 697 | /* End PBXProject section */ 698 | 699 | /* Begin PBXReferenceProxy section */ 700 | 00C302AC1ABCB8CE00DB3ED1 /* libRCTActionSheet.a */ = { 701 | isa = PBXReferenceProxy; 702 | fileType = archive.ar; 703 | path = libRCTActionSheet.a; 704 | remoteRef = 00C302AB1ABCB8CE00DB3ED1 /* PBXContainerItemProxy */; 705 | sourceTree = BUILT_PRODUCTS_DIR; 706 | }; 707 | 00C302BA1ABCB90400DB3ED1 /* libRCTGeolocation.a */ = { 708 | isa = PBXReferenceProxy; 709 | fileType = archive.ar; 710 | path = libRCTGeolocation.a; 711 | remoteRef = 00C302B91ABCB90400DB3ED1 /* PBXContainerItemProxy */; 712 | sourceTree = BUILT_PRODUCTS_DIR; 713 | }; 714 | 00C302C01ABCB91800DB3ED1 /* libRCTImage.a */ = { 715 | isa = PBXReferenceProxy; 716 | fileType = archive.ar; 717 | path = libRCTImage.a; 718 | remoteRef = 00C302BF1ABCB91800DB3ED1 /* PBXContainerItemProxy */; 719 | sourceTree = BUILT_PRODUCTS_DIR; 720 | }; 721 | 00C302DC1ABCB9D200DB3ED1 /* libRCTNetwork.a */ = { 722 | isa = PBXReferenceProxy; 723 | fileType = archive.ar; 724 | path = libRCTNetwork.a; 725 | remoteRef = 00C302DB1ABCB9D200DB3ED1 /* PBXContainerItemProxy */; 726 | sourceTree = BUILT_PRODUCTS_DIR; 727 | }; 728 | 00C302E41ABCB9EE00DB3ED1 /* libRCTVibration.a */ = { 729 | isa = PBXReferenceProxy; 730 | fileType = archive.ar; 731 | path = libRCTVibration.a; 732 | remoteRef = 00C302E31ABCB9EE00DB3ED1 /* PBXContainerItemProxy */; 733 | sourceTree = BUILT_PRODUCTS_DIR; 734 | }; 735 | 139105C11AF99BAD00B5F7CC /* libRCTSettings.a */ = { 736 | isa = PBXReferenceProxy; 737 | fileType = archive.ar; 738 | path = libRCTSettings.a; 739 | remoteRef = 139105C01AF99BAD00B5F7CC /* PBXContainerItemProxy */; 740 | sourceTree = BUILT_PRODUCTS_DIR; 741 | }; 742 | 139FDEF41B06529B00C62182 /* libRCTWebSocket.a */ = { 743 | isa = PBXReferenceProxy; 744 | fileType = archive.ar; 745 | path = libRCTWebSocket.a; 746 | remoteRef = 139FDEF31B06529B00C62182 /* PBXContainerItemProxy */; 747 | sourceTree = BUILT_PRODUCTS_DIR; 748 | }; 749 | 146834041AC3E56700842450 /* libReact.a */ = { 750 | isa = PBXReferenceProxy; 751 | fileType = archive.ar; 752 | path = libReact.a; 753 | remoteRef = 146834031AC3E56700842450 /* PBXContainerItemProxy */; 754 | sourceTree = BUILT_PRODUCTS_DIR; 755 | }; 756 | 3A15EA051FAF384800A3DE6F /* libRCTBlob-tvOS.a */ = { 757 | isa = PBXReferenceProxy; 758 | fileType = archive.ar; 759 | path = "libRCTBlob-tvOS.a"; 760 | remoteRef = 3A15EA041FAF384800A3DE6F /* PBXContainerItemProxy */; 761 | sourceTree = BUILT_PRODUCTS_DIR; 762 | }; 763 | 3A15EA171FAF384900A3DE6F /* libfishhook.a */ = { 764 | isa = PBXReferenceProxy; 765 | fileType = archive.ar; 766 | path = libfishhook.a; 767 | remoteRef = 3A15EA161FAF384900A3DE6F /* PBXContainerItemProxy */; 768 | sourceTree = BUILT_PRODUCTS_DIR; 769 | }; 770 | 3A15EA191FAF384900A3DE6F /* libfishhook-tvOS.a */ = { 771 | isa = PBXReferenceProxy; 772 | fileType = archive.ar; 773 | path = "libfishhook-tvOS.a"; 774 | remoteRef = 3A15EA181FAF384900A3DE6F /* PBXContainerItemProxy */; 775 | sourceTree = BUILT_PRODUCTS_DIR; 776 | }; 777 | 3DAD3E841DF850E9000B6D8A /* libRCTImage-tvOS.a */ = { 778 | isa = PBXReferenceProxy; 779 | fileType = archive.ar; 780 | path = "libRCTImage-tvOS.a"; 781 | remoteRef = 3DAD3E831DF850E9000B6D8A /* PBXContainerItemProxy */; 782 | sourceTree = BUILT_PRODUCTS_DIR; 783 | }; 784 | 3DAD3E881DF850E9000B6D8A /* libRCTLinking-tvOS.a */ = { 785 | isa = PBXReferenceProxy; 786 | fileType = archive.ar; 787 | path = "libRCTLinking-tvOS.a"; 788 | remoteRef = 3DAD3E871DF850E9000B6D8A /* PBXContainerItemProxy */; 789 | sourceTree = BUILT_PRODUCTS_DIR; 790 | }; 791 | 3DAD3E8C1DF850E9000B6D8A /* libRCTNetwork-tvOS.a */ = { 792 | isa = PBXReferenceProxy; 793 | fileType = archive.ar; 794 | path = "libRCTNetwork-tvOS.a"; 795 | remoteRef = 3DAD3E8B1DF850E9000B6D8A /* PBXContainerItemProxy */; 796 | sourceTree = BUILT_PRODUCTS_DIR; 797 | }; 798 | 3DAD3E901DF850E9000B6D8A /* libRCTSettings-tvOS.a */ = { 799 | isa = PBXReferenceProxy; 800 | fileType = archive.ar; 801 | path = "libRCTSettings-tvOS.a"; 802 | remoteRef = 3DAD3E8F1DF850E9000B6D8A /* PBXContainerItemProxy */; 803 | sourceTree = BUILT_PRODUCTS_DIR; 804 | }; 805 | 3DAD3E941DF850E9000B6D8A /* libRCTText-tvOS.a */ = { 806 | isa = PBXReferenceProxy; 807 | fileType = archive.ar; 808 | path = "libRCTText-tvOS.a"; 809 | remoteRef = 3DAD3E931DF850E9000B6D8A /* PBXContainerItemProxy */; 810 | sourceTree = BUILT_PRODUCTS_DIR; 811 | }; 812 | 3DAD3E991DF850E9000B6D8A /* libRCTWebSocket-tvOS.a */ = { 813 | isa = PBXReferenceProxy; 814 | fileType = archive.ar; 815 | path = "libRCTWebSocket-tvOS.a"; 816 | remoteRef = 3DAD3E981DF850E9000B6D8A /* PBXContainerItemProxy */; 817 | sourceTree = BUILT_PRODUCTS_DIR; 818 | }; 819 | 3DAD3EA31DF850E9000B6D8A /* libReact-tvOS.a */ = { 820 | isa = PBXReferenceProxy; 821 | fileType = archive.ar; 822 | path = "libReact-tvOS.a"; 823 | remoteRef = 3DAD3EA21DF850E9000B6D8A /* PBXContainerItemProxy */; 824 | sourceTree = BUILT_PRODUCTS_DIR; 825 | }; 826 | 3DAD3EA51DF850E9000B6D8A /* libyoga.a */ = { 827 | isa = PBXReferenceProxy; 828 | fileType = archive.ar; 829 | path = libyoga.a; 830 | remoteRef = 3DAD3EA41DF850E9000B6D8A /* PBXContainerItemProxy */; 831 | sourceTree = BUILT_PRODUCTS_DIR; 832 | }; 833 | 3DAD3EA71DF850E9000B6D8A /* libyoga.a */ = { 834 | isa = PBXReferenceProxy; 835 | fileType = archive.ar; 836 | path = libyoga.a; 837 | remoteRef = 3DAD3EA61DF850E9000B6D8A /* PBXContainerItemProxy */; 838 | sourceTree = BUILT_PRODUCTS_DIR; 839 | }; 840 | 3DAD3EA91DF850E9000B6D8A /* libcxxreact.a */ = { 841 | isa = PBXReferenceProxy; 842 | fileType = archive.ar; 843 | path = libcxxreact.a; 844 | remoteRef = 3DAD3EA81DF850E9000B6D8A /* PBXContainerItemProxy */; 845 | sourceTree = BUILT_PRODUCTS_DIR; 846 | }; 847 | 3DAD3EAB1DF850E9000B6D8A /* libcxxreact.a */ = { 848 | isa = PBXReferenceProxy; 849 | fileType = archive.ar; 850 | path = libcxxreact.a; 851 | remoteRef = 3DAD3EAA1DF850E9000B6D8A /* PBXContainerItemProxy */; 852 | sourceTree = BUILT_PRODUCTS_DIR; 853 | }; 854 | 3DAD3EAD1DF850E9000B6D8A /* libjschelpers.a */ = { 855 | isa = PBXReferenceProxy; 856 | fileType = archive.ar; 857 | path = libjschelpers.a; 858 | remoteRef = 3DAD3EAC1DF850E9000B6D8A /* PBXContainerItemProxy */; 859 | sourceTree = BUILT_PRODUCTS_DIR; 860 | }; 861 | 3DAD3EAF1DF850E9000B6D8A /* libjschelpers.a */ = { 862 | isa = PBXReferenceProxy; 863 | fileType = archive.ar; 864 | path = libjschelpers.a; 865 | remoteRef = 3DAD3EAE1DF850E9000B6D8A /* PBXContainerItemProxy */; 866 | sourceTree = BUILT_PRODUCTS_DIR; 867 | }; 868 | 5E9157331DD0AC6500FF2AA8 /* libRCTAnimation.a */ = { 869 | isa = PBXReferenceProxy; 870 | fileType = archive.ar; 871 | path = libRCTAnimation.a; 872 | remoteRef = 5E9157321DD0AC6500FF2AA8 /* PBXContainerItemProxy */; 873 | sourceTree = BUILT_PRODUCTS_DIR; 874 | }; 875 | 5E9157351DD0AC6500FF2AA8 /* libRCTAnimation.a */ = { 876 | isa = PBXReferenceProxy; 877 | fileType = archive.ar; 878 | path = libRCTAnimation.a; 879 | remoteRef = 5E9157341DD0AC6500FF2AA8 /* PBXContainerItemProxy */; 880 | sourceTree = BUILT_PRODUCTS_DIR; 881 | }; 882 | 78C398B91ACF4ADC00677621 /* libRCTLinking.a */ = { 883 | isa = PBXReferenceProxy; 884 | fileType = archive.ar; 885 | path = libRCTLinking.a; 886 | remoteRef = 78C398B81ACF4ADC00677621 /* PBXContainerItemProxy */; 887 | sourceTree = BUILT_PRODUCTS_DIR; 888 | }; 889 | 832341B51AAA6A8300B99B32 /* libRCTText.a */ = { 890 | isa = PBXReferenceProxy; 891 | fileType = archive.ar; 892 | path = libRCTText.a; 893 | remoteRef = 832341B41AAA6A8300B99B32 /* PBXContainerItemProxy */; 894 | sourceTree = BUILT_PRODUCTS_DIR; 895 | }; 896 | ADBDB9271DFEBF0700ED6528 /* libRCTBlob.a */ = { 897 | isa = PBXReferenceProxy; 898 | fileType = archive.ar; 899 | path = libRCTBlob.a; 900 | remoteRef = ADBDB9261DFEBF0700ED6528 /* PBXContainerItemProxy */; 901 | sourceTree = BUILT_PRODUCTS_DIR; 902 | }; 903 | /* End PBXReferenceProxy section */ 904 | 905 | /* Begin PBXResourcesBuildPhase section */ 906 | 00E356EC1AD99517003FC87E /* Resources */ = { 907 | isa = PBXResourcesBuildPhase; 908 | buildActionMask = 2147483647; 909 | files = ( 910 | ); 911 | runOnlyForDeploymentPostprocessing = 0; 912 | }; 913 | 13B07F8E1A680F5B00A75B9A /* Resources */ = { 914 | isa = PBXResourcesBuildPhase; 915 | buildActionMask = 2147483647; 916 | files = ( 917 | 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */, 918 | 13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */, 919 | ); 920 | runOnlyForDeploymentPostprocessing = 0; 921 | }; 922 | 2D02E4791E0B4A5D006451C7 /* Resources */ = { 923 | isa = PBXResourcesBuildPhase; 924 | buildActionMask = 2147483647; 925 | files = ( 926 | 2D02E4BD1E0B4A84006451C7 /* Images.xcassets in Resources */, 927 | ); 928 | runOnlyForDeploymentPostprocessing = 0; 929 | }; 930 | 2D02E48E1E0B4A5D006451C7 /* Resources */ = { 931 | isa = PBXResourcesBuildPhase; 932 | buildActionMask = 2147483647; 933 | files = ( 934 | ); 935 | runOnlyForDeploymentPostprocessing = 0; 936 | }; 937 | /* End PBXResourcesBuildPhase section */ 938 | 939 | /* Begin PBXShellScriptBuildPhase section */ 940 | 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */ = { 941 | isa = PBXShellScriptBuildPhase; 942 | buildActionMask = 2147483647; 943 | files = ( 944 | ); 945 | inputPaths = ( 946 | ); 947 | name = "Bundle React Native code and images"; 948 | outputPaths = ( 949 | ); 950 | runOnlyForDeploymentPostprocessing = 0; 951 | shellPath = /bin/sh; 952 | shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh"; 953 | }; 954 | 2D02E4CB1E0B4B27006451C7 /* Bundle React Native Code And Images */ = { 955 | isa = PBXShellScriptBuildPhase; 956 | buildActionMask = 2147483647; 957 | files = ( 958 | ); 959 | inputPaths = ( 960 | ); 961 | name = "Bundle React Native Code And Images"; 962 | outputPaths = ( 963 | ); 964 | runOnlyForDeploymentPostprocessing = 0; 965 | shellPath = /bin/sh; 966 | shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh"; 967 | }; 968 | /* End PBXShellScriptBuildPhase section */ 969 | 970 | /* Begin PBXSourcesBuildPhase section */ 971 | 00E356EA1AD99517003FC87E /* Sources */ = { 972 | isa = PBXSourcesBuildPhase; 973 | buildActionMask = 2147483647; 974 | files = ( 975 | 00E356F31AD99517003FC87E /* ExampleTests.m in Sources */, 976 | ); 977 | runOnlyForDeploymentPostprocessing = 0; 978 | }; 979 | 13B07F871A680F5B00A75B9A /* Sources */ = { 980 | isa = PBXSourcesBuildPhase; 981 | buildActionMask = 2147483647; 982 | files = ( 983 | 13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */, 984 | 13B07FC11A68108700A75B9A /* main.m in Sources */, 985 | ); 986 | runOnlyForDeploymentPostprocessing = 0; 987 | }; 988 | 2D02E4771E0B4A5D006451C7 /* Sources */ = { 989 | isa = PBXSourcesBuildPhase; 990 | buildActionMask = 2147483647; 991 | files = ( 992 | 2D02E4BF1E0B4AB3006451C7 /* main.m in Sources */, 993 | 2D02E4BC1E0B4A80006451C7 /* AppDelegate.m in Sources */, 994 | ); 995 | runOnlyForDeploymentPostprocessing = 0; 996 | }; 997 | 2D02E48C1E0B4A5D006451C7 /* Sources */ = { 998 | isa = PBXSourcesBuildPhase; 999 | buildActionMask = 2147483647; 1000 | files = ( 1001 | 2DCD954D1E0B4F2C00145EB5 /* ExampleTests.m in Sources */, 1002 | ); 1003 | runOnlyForDeploymentPostprocessing = 0; 1004 | }; 1005 | /* End PBXSourcesBuildPhase section */ 1006 | 1007 | /* Begin PBXTargetDependency section */ 1008 | 00E356F51AD99517003FC87E /* PBXTargetDependency */ = { 1009 | isa = PBXTargetDependency; 1010 | target = 13B07F861A680F5B00A75B9A /* Example */; 1011 | targetProxy = 00E356F41AD99517003FC87E /* PBXContainerItemProxy */; 1012 | }; 1013 | 2D02E4921E0B4A5D006451C7 /* PBXTargetDependency */ = { 1014 | isa = PBXTargetDependency; 1015 | target = 2D02E47A1E0B4A5D006451C7 /* Example-tvOS */; 1016 | targetProxy = 2D02E4911E0B4A5D006451C7 /* PBXContainerItemProxy */; 1017 | }; 1018 | /* End PBXTargetDependency section */ 1019 | 1020 | /* Begin PBXVariantGroup section */ 1021 | 13B07FB11A68108700A75B9A /* LaunchScreen.xib */ = { 1022 | isa = PBXVariantGroup; 1023 | children = ( 1024 | 13B07FB21A68108700A75B9A /* Base */, 1025 | ); 1026 | name = LaunchScreen.xib; 1027 | path = Example; 1028 | sourceTree = ""; 1029 | }; 1030 | /* End PBXVariantGroup section */ 1031 | 1032 | /* Begin XCBuildConfiguration section */ 1033 | 00E356F61AD99517003FC87E /* Debug */ = { 1034 | isa = XCBuildConfiguration; 1035 | buildSettings = { 1036 | BUNDLE_LOADER = "$(TEST_HOST)"; 1037 | GCC_PREPROCESSOR_DEFINITIONS = ( 1038 | "DEBUG=1", 1039 | "$(inherited)", 1040 | ); 1041 | INFOPLIST_FILE = ExampleTests/Info.plist; 1042 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 1043 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 1044 | OTHER_LDFLAGS = ( 1045 | "-ObjC", 1046 | "-lc++", 1047 | ); 1048 | PRODUCT_NAME = "$(TARGET_NAME)"; 1049 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Example.app/Example"; 1050 | }; 1051 | name = Debug; 1052 | }; 1053 | 00E356F71AD99517003FC87E /* Release */ = { 1054 | isa = XCBuildConfiguration; 1055 | buildSettings = { 1056 | BUNDLE_LOADER = "$(TEST_HOST)"; 1057 | COPY_PHASE_STRIP = NO; 1058 | INFOPLIST_FILE = ExampleTests/Info.plist; 1059 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 1060 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 1061 | OTHER_LDFLAGS = ( 1062 | "-ObjC", 1063 | "-lc++", 1064 | ); 1065 | PRODUCT_NAME = "$(TARGET_NAME)"; 1066 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Example.app/Example"; 1067 | }; 1068 | name = Release; 1069 | }; 1070 | 13B07F941A680F5B00A75B9A /* Debug */ = { 1071 | isa = XCBuildConfiguration; 1072 | buildSettings = { 1073 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 1074 | CURRENT_PROJECT_VERSION = 1; 1075 | DEAD_CODE_STRIPPING = NO; 1076 | INFOPLIST_FILE = Example/Info.plist; 1077 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 1078 | OTHER_LDFLAGS = ( 1079 | "$(inherited)", 1080 | "-ObjC", 1081 | "-lc++", 1082 | ); 1083 | PRODUCT_NAME = Example; 1084 | VERSIONING_SYSTEM = "apple-generic"; 1085 | }; 1086 | name = Debug; 1087 | }; 1088 | 13B07F951A680F5B00A75B9A /* Release */ = { 1089 | isa = XCBuildConfiguration; 1090 | buildSettings = { 1091 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 1092 | CURRENT_PROJECT_VERSION = 1; 1093 | INFOPLIST_FILE = Example/Info.plist; 1094 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 1095 | OTHER_LDFLAGS = ( 1096 | "$(inherited)", 1097 | "-ObjC", 1098 | "-lc++", 1099 | ); 1100 | PRODUCT_NAME = Example; 1101 | VERSIONING_SYSTEM = "apple-generic"; 1102 | }; 1103 | name = Release; 1104 | }; 1105 | 2D02E4971E0B4A5E006451C7 /* Debug */ = { 1106 | isa = XCBuildConfiguration; 1107 | buildSettings = { 1108 | ASSETCATALOG_COMPILER_APPICON_NAME = "App Icon & Top Shelf Image"; 1109 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage; 1110 | CLANG_ANALYZER_NONNULL = YES; 1111 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 1112 | CLANG_WARN_INFINITE_RECURSION = YES; 1113 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 1114 | DEBUG_INFORMATION_FORMAT = dwarf; 1115 | ENABLE_TESTABILITY = YES; 1116 | GCC_NO_COMMON_BLOCKS = YES; 1117 | INFOPLIST_FILE = "Example-tvOS/Info.plist"; 1118 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 1119 | OTHER_LDFLAGS = ( 1120 | "-ObjC", 1121 | "-lc++", 1122 | ); 1123 | PRODUCT_BUNDLE_IDENTIFIER = "com.facebook.REACT.Example-tvOS"; 1124 | PRODUCT_NAME = "$(TARGET_NAME)"; 1125 | SDKROOT = appletvos; 1126 | TARGETED_DEVICE_FAMILY = 3; 1127 | TVOS_DEPLOYMENT_TARGET = 9.2; 1128 | }; 1129 | name = Debug; 1130 | }; 1131 | 2D02E4981E0B4A5E006451C7 /* Release */ = { 1132 | isa = XCBuildConfiguration; 1133 | buildSettings = { 1134 | ASSETCATALOG_COMPILER_APPICON_NAME = "App Icon & Top Shelf Image"; 1135 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage; 1136 | CLANG_ANALYZER_NONNULL = YES; 1137 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 1138 | CLANG_WARN_INFINITE_RECURSION = YES; 1139 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 1140 | COPY_PHASE_STRIP = NO; 1141 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 1142 | GCC_NO_COMMON_BLOCKS = YES; 1143 | INFOPLIST_FILE = "Example-tvOS/Info.plist"; 1144 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 1145 | OTHER_LDFLAGS = ( 1146 | "-ObjC", 1147 | "-lc++", 1148 | ); 1149 | PRODUCT_BUNDLE_IDENTIFIER = "com.facebook.REACT.Example-tvOS"; 1150 | PRODUCT_NAME = "$(TARGET_NAME)"; 1151 | SDKROOT = appletvos; 1152 | TARGETED_DEVICE_FAMILY = 3; 1153 | TVOS_DEPLOYMENT_TARGET = 9.2; 1154 | }; 1155 | name = Release; 1156 | }; 1157 | 2D02E4991E0B4A5E006451C7 /* Debug */ = { 1158 | isa = XCBuildConfiguration; 1159 | buildSettings = { 1160 | BUNDLE_LOADER = "$(TEST_HOST)"; 1161 | CLANG_ANALYZER_NONNULL = YES; 1162 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 1163 | CLANG_WARN_INFINITE_RECURSION = YES; 1164 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 1165 | DEBUG_INFORMATION_FORMAT = dwarf; 1166 | ENABLE_TESTABILITY = YES; 1167 | GCC_NO_COMMON_BLOCKS = YES; 1168 | INFOPLIST_FILE = "Example-tvOSTests/Info.plist"; 1169 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 1170 | PRODUCT_BUNDLE_IDENTIFIER = "com.facebook.REACT.Example-tvOSTests"; 1171 | PRODUCT_NAME = "$(TARGET_NAME)"; 1172 | SDKROOT = appletvos; 1173 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Example-tvOS.app/Example-tvOS"; 1174 | TVOS_DEPLOYMENT_TARGET = 10.1; 1175 | }; 1176 | name = Debug; 1177 | }; 1178 | 2D02E49A1E0B4A5E006451C7 /* Release */ = { 1179 | isa = XCBuildConfiguration; 1180 | buildSettings = { 1181 | BUNDLE_LOADER = "$(TEST_HOST)"; 1182 | CLANG_ANALYZER_NONNULL = YES; 1183 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 1184 | CLANG_WARN_INFINITE_RECURSION = YES; 1185 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 1186 | COPY_PHASE_STRIP = NO; 1187 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 1188 | GCC_NO_COMMON_BLOCKS = YES; 1189 | INFOPLIST_FILE = "Example-tvOSTests/Info.plist"; 1190 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 1191 | PRODUCT_BUNDLE_IDENTIFIER = "com.facebook.REACT.Example-tvOSTests"; 1192 | PRODUCT_NAME = "$(TARGET_NAME)"; 1193 | SDKROOT = appletvos; 1194 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Example-tvOS.app/Example-tvOS"; 1195 | TVOS_DEPLOYMENT_TARGET = 10.1; 1196 | }; 1197 | name = Release; 1198 | }; 1199 | 83CBBA201A601CBA00E9B192 /* Debug */ = { 1200 | isa = XCBuildConfiguration; 1201 | buildSettings = { 1202 | ALWAYS_SEARCH_USER_PATHS = NO; 1203 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 1204 | CLANG_CXX_LIBRARY = "libc++"; 1205 | CLANG_ENABLE_MODULES = YES; 1206 | CLANG_ENABLE_OBJC_ARC = YES; 1207 | CLANG_WARN_BOOL_CONVERSION = YES; 1208 | CLANG_WARN_CONSTANT_CONVERSION = YES; 1209 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 1210 | CLANG_WARN_EMPTY_BODY = YES; 1211 | CLANG_WARN_ENUM_CONVERSION = YES; 1212 | CLANG_WARN_INT_CONVERSION = YES; 1213 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 1214 | CLANG_WARN_UNREACHABLE_CODE = YES; 1215 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 1216 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 1217 | COPY_PHASE_STRIP = NO; 1218 | ENABLE_STRICT_OBJC_MSGSEND = YES; 1219 | GCC_C_LANGUAGE_STANDARD = gnu99; 1220 | GCC_DYNAMIC_NO_PIC = NO; 1221 | GCC_OPTIMIZATION_LEVEL = 0; 1222 | GCC_PREPROCESSOR_DEFINITIONS = ( 1223 | "DEBUG=1", 1224 | "$(inherited)", 1225 | ); 1226 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 1227 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 1228 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 1229 | GCC_WARN_UNDECLARED_SELECTOR = YES; 1230 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 1231 | GCC_WARN_UNUSED_FUNCTION = YES; 1232 | GCC_WARN_UNUSED_VARIABLE = YES; 1233 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 1234 | MTL_ENABLE_DEBUG_INFO = YES; 1235 | ONLY_ACTIVE_ARCH = YES; 1236 | SDKROOT = iphoneos; 1237 | }; 1238 | name = Debug; 1239 | }; 1240 | 83CBBA211A601CBA00E9B192 /* Release */ = { 1241 | isa = XCBuildConfiguration; 1242 | buildSettings = { 1243 | ALWAYS_SEARCH_USER_PATHS = NO; 1244 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 1245 | CLANG_CXX_LIBRARY = "libc++"; 1246 | CLANG_ENABLE_MODULES = YES; 1247 | CLANG_ENABLE_OBJC_ARC = YES; 1248 | CLANG_WARN_BOOL_CONVERSION = YES; 1249 | CLANG_WARN_CONSTANT_CONVERSION = YES; 1250 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 1251 | CLANG_WARN_EMPTY_BODY = YES; 1252 | CLANG_WARN_ENUM_CONVERSION = YES; 1253 | CLANG_WARN_INT_CONVERSION = YES; 1254 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 1255 | CLANG_WARN_UNREACHABLE_CODE = YES; 1256 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 1257 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 1258 | COPY_PHASE_STRIP = YES; 1259 | ENABLE_NS_ASSERTIONS = NO; 1260 | ENABLE_STRICT_OBJC_MSGSEND = YES; 1261 | GCC_C_LANGUAGE_STANDARD = gnu99; 1262 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 1263 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 1264 | GCC_WARN_UNDECLARED_SELECTOR = YES; 1265 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 1266 | GCC_WARN_UNUSED_FUNCTION = YES; 1267 | GCC_WARN_UNUSED_VARIABLE = YES; 1268 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 1269 | MTL_ENABLE_DEBUG_INFO = NO; 1270 | SDKROOT = iphoneos; 1271 | VALIDATE_PRODUCT = YES; 1272 | }; 1273 | name = Release; 1274 | }; 1275 | /* End XCBuildConfiguration section */ 1276 | 1277 | /* Begin XCConfigurationList section */ 1278 | 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "ExampleTests" */ = { 1279 | isa = XCConfigurationList; 1280 | buildConfigurations = ( 1281 | 00E356F61AD99517003FC87E /* Debug */, 1282 | 00E356F71AD99517003FC87E /* Release */, 1283 | ); 1284 | defaultConfigurationIsVisible = 0; 1285 | defaultConfigurationName = Release; 1286 | }; 1287 | 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "Example" */ = { 1288 | isa = XCConfigurationList; 1289 | buildConfigurations = ( 1290 | 13B07F941A680F5B00A75B9A /* Debug */, 1291 | 13B07F951A680F5B00A75B9A /* Release */, 1292 | ); 1293 | defaultConfigurationIsVisible = 0; 1294 | defaultConfigurationName = Release; 1295 | }; 1296 | 2D02E4BA1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "Example-tvOS" */ = { 1297 | isa = XCConfigurationList; 1298 | buildConfigurations = ( 1299 | 2D02E4971E0B4A5E006451C7 /* Debug */, 1300 | 2D02E4981E0B4A5E006451C7 /* Release */, 1301 | ); 1302 | defaultConfigurationIsVisible = 0; 1303 | defaultConfigurationName = Release; 1304 | }; 1305 | 2D02E4BB1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "Example-tvOSTests" */ = { 1306 | isa = XCConfigurationList; 1307 | buildConfigurations = ( 1308 | 2D02E4991E0B4A5E006451C7 /* Debug */, 1309 | 2D02E49A1E0B4A5E006451C7 /* Release */, 1310 | ); 1311 | defaultConfigurationIsVisible = 0; 1312 | defaultConfigurationName = Release; 1313 | }; 1314 | 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "Example" */ = { 1315 | isa = XCConfigurationList; 1316 | buildConfigurations = ( 1317 | 83CBBA201A601CBA00E9B192 /* Debug */, 1318 | 83CBBA211A601CBA00E9B192 /* Release */, 1319 | ); 1320 | defaultConfigurationIsVisible = 0; 1321 | defaultConfigurationName = Release; 1322 | }; 1323 | /* End XCConfigurationList section */ 1324 | }; 1325 | rootObject = 83CBB9F71A601CBA00E9B192 /* Project object */; 1326 | } 1327 | -------------------------------------------------------------------------------- /Example/ios/Example.xcodeproj/xcshareddata/xcschemes/Example-tvOS.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 | -------------------------------------------------------------------------------- /Example/ios/Example.xcodeproj/xcshareddata/xcschemes/Example.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 29 | 35 | 36 | 37 | 43 | 49 | 50 | 51 | 52 | 53 | 59 | 60 | 62 | 68 | 69 | 70 | 71 | 72 | 78 | 79 | 80 | 81 | 82 | 83 | 94 | 96 | 102 | 103 | 104 | 105 | 106 | 107 | 113 | 115 | 121 | 122 | 123 | 124 | 126 | 127 | 130 | 131 | 132 | -------------------------------------------------------------------------------- /Example/ios/Example/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 | -------------------------------------------------------------------------------- /Example/ios/Example/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" fallbackResource:nil]; 22 | 23 | RCTRootView *rootView = [[RCTRootView alloc] initWithBundleURL:jsCodeLocation 24 | moduleName:@"Example" 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 | -------------------------------------------------------------------------------- /Example/ios/Example/Base.lproj/LaunchScreen.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 21 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | -------------------------------------------------------------------------------- /Example/ios/Example/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 | } -------------------------------------------------------------------------------- /Example/ios/Example/Images.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /Example/ios/Example/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleDisplayName 8 | Example 9 | CFBundleExecutable 10 | $(EXECUTABLE_NAME) 11 | CFBundleIdentifier 12 | org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | $(PRODUCT_NAME) 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | 1.0 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | 1 25 | LSRequiresIPhoneOS 26 | 27 | UILaunchStoryboardName 28 | LaunchScreen 29 | UIRequiredDeviceCapabilities 30 | 31 | armv7 32 | 33 | UISupportedInterfaceOrientations 34 | 35 | UIInterfaceOrientationPortrait 36 | UIInterfaceOrientationLandscapeLeft 37 | UIInterfaceOrientationLandscapeRight 38 | 39 | UIViewControllerBasedStatusBarAppearance 40 | 41 | NSLocationWhenInUseUsageDescription 42 | 43 | NSAppTransportSecurity 44 | 45 | 46 | NSExceptionDomains 47 | 48 | localhost 49 | 50 | NSExceptionAllowsInsecureHTTPLoads 51 | 52 | 53 | 54 | 55 | 56 | 57 | -------------------------------------------------------------------------------- /Example/ios/Example/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 | -------------------------------------------------------------------------------- /Example/ios/ExampleTests/ExampleTests.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 ExampleTests : XCTestCase 20 | 21 | @end 22 | 23 | @implementation ExampleTests 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 = [[[RCTSharedApplication() 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 | -------------------------------------------------------------------------------- /Example/ios/ExampleTests/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 | -------------------------------------------------------------------------------- /Example/jsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "allowJs": true, 4 | "allowSyntheticDefaultImports": true 5 | }, 6 | "exclude": [ 7 | "node_modules" 8 | ] 9 | } 10 | -------------------------------------------------------------------------------- /Example/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Example", 3 | "version": "0.0.1", 4 | "private": true, 5 | "scripts": { 6 | "postinstall": "rm -rf node_modules/react-native-image-carousel/{node_modules,Example}", 7 | "start": "node node_modules/react-native/local-cli/cli.js start" 8 | }, 9 | "dependencies": { 10 | "react": "16.0.0", 11 | "react-native": "0.50.1", 12 | "react-native-image-carousel": "file:../" 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Example/rn-cli.config.js: -------------------------------------------------------------------------------- 1 | const path = require('path'); 2 | 3 | // See https://github.com/facebook/metro-bundler/issues/68 4 | const extraNodeModulesGetter = { 5 | get: (target, name) => path.join(process.cwd(), `node_modules/${name}`), 6 | }; 7 | 8 | module.exports = { 9 | extraNodeModules: new Proxy({}, extraNodeModulesGetter), 10 | }; 11 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2016 Anvilabs LLC 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # react-native-image-carousel 2 | > Image carousel with support for heading, captions, fullscreen mode, image swiping and pinch-to-zoom in fullscreen mode. 3 | 4 | Supports both Android and iOS. Zoom feature works on iOS only. 5 | 6 | ## Demo 7 | 8 | Demo 9 | 10 | ## Installation 11 | 12 | `npm install --save react-native-image-carousel` 13 | 14 | ## Usage 15 | 16 | ```javascript 17 | import ImageCarousel from 'react-native-image-carousel'; 18 | 19 | export default class App extends Component { 20 | _imageCarousel: ImageCarousel; 21 | 22 | componentWillMount() { 23 | (this: any)._renderHeader = this._renderHeader.bind(this); 24 | } 25 | 26 | _renderHeader(): ReactElement { 27 | return ( 28 | 29 | 30 | Exit 31 | 32 | 33 | ); 34 | } 35 | 36 | _renderFooter(): ReactElement { 37 | return ( 38 | Footer! 39 | ); 40 | } 41 | 42 | _renderContent(idx: number): ReactElement { 43 | return ( 44 | 49 | ); 50 | } 51 | 52 | render(): ReactElement { 53 | return ( 54 | 55 | { 57 | this._imageCarousel = imageCarousel; 58 | }} 59 | renderContent={this._renderContent} 60 | renderHeader={this._renderHeader} 61 | renderFooter={this._renderFooter} 62 | > 63 | {urls.map((url: string): ReactElement => ( 64 | 70 | ))} 71 | 72 | 73 | ); 74 | } 75 | } 76 | ``` 77 | 78 | Check full example in _Example_ folder. 79 | 80 | ### Props and methods 81 | 82 | _Every prop is optional._ 83 | 84 | | Name | Type | Description | 85 | |---|---|---| 86 | | `activeProps?` | `Object` | Props of each child when in fullscreen mode. (For a component to fill the screen activeProp's style must be `flex: 1`). This prop is ignored in case `renderContent` prop is provided. | 87 | | `activeComponents?` | `[ReactElement]` | Active components' bounds will be used for opening/closing fullscreen mode animations. If not provided, the immediate children are used. | 88 | | `zoomEnabled?` | `boolean` | `true` by default, if `false`, children are not zoomable. | 89 | | `hideStatusBarOnOpen?` | `boolean` | `true` by default, if `false`, status bar does not fade out on open. | 90 | | `renderContent?` | `(idx: number) => ReactElement` | Component to render in fullscreen mode for the given index. | 91 | | `renderHeader?` | `() => ReactElement` | Component to render at the top when in fullscreen mode. | 92 | | `renderFooter?` | `() => ReactElement` | Component to render at the bottom when in fullscreen mode. | 93 | | `onIdxChange?` | `(idx: number)` | Fired on index change in fullscreen mode. | 94 | | `onOpen?` | `() => void` | Fired on fullscreen mode open. | 95 | | `onClose?` | `() => void` | Fired on fullscreen mode close. | 96 | 97 | react-native-image-carousel also provides two methods for opening and closing the fullscreen mode respectively: 98 | 99 | `open(startIdx: number)`, `close`. 100 | 101 | ## License 102 | 103 | [MIT License](./LICENSE) © Anvilabs LLC 104 | -------------------------------------------------------------------------------- /commitlint.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | extends: ['@commitlint/config-angular'], 3 | rules: { 4 | 'scope-case': [0], 5 | }, 6 | }; 7 | -------------------------------------------------------------------------------- /dist/index.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; } 4 | 5 | var reactNative = require('react-native'); 6 | var React = require('react'); 7 | var SwipeableViews = _interopDefault(require('react-swipeable-views-native')); 8 | 9 | var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); 10 | 11 | function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } 12 | 13 | function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } 14 | 15 | function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } 16 | 17 | /* */ 18 | 19 | var ANIM_CONFIG = { duration: 300 }; 20 | var screenSize = reactNative.Dimensions.get('window'); 21 | var screenWidth = screenSize.width; 22 | var screenHeight = screenSize.height - reactNative.Platform.select({ ios: 0, android: reactNative.StatusBar.currentHeight }); 23 | 24 | var ImageCarousel = function (_React$Component) { 25 | _inherits(ImageCarousel, _React$Component); 26 | 27 | function ImageCarousel() { 28 | var _ref; 29 | 30 | var _temp, _this, _ret; 31 | 32 | _classCallCheck(this, ImageCarousel); 33 | 34 | for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { 35 | args[_key] = arguments[_key]; 36 | } 37 | 38 | return _ret = (_temp = (_this = _possibleConstructorReturn(this, (_ref = ImageCarousel.__proto__ || Object.getPrototypeOf(ImageCarousel)).call.apply(_ref, [this].concat(args))), _this), _this.openAnim = new reactNative.Animated.Value(0), _this.pan = new reactNative.Animated.Value(0), _this.carouselItems = Array.isArray(_this.props.children) ? _this.props.children.map(function () { 39 | return null; 40 | }) : [null], _this.state = { 41 | origin: { 42 | x: 0, 43 | y: 0, 44 | width: 0, 45 | height: 0 46 | }, 47 | target: { 48 | x: 0, 49 | y: 0, 50 | opacity: 1 51 | }, 52 | fullscreen: false, 53 | selectedIdx: 0, 54 | animating: false, 55 | panning: false, 56 | selectedImageHidden: false, 57 | slidesDown: false 58 | }, _this.open = function (startIdx) { 59 | var activeComponent = _this.getComponentAtIdx(startIdx); 60 | 61 | if (!activeComponent) return; 62 | 63 | var _this$props = _this.props, 64 | hideStatusBarOnOpen = _this$props.hideStatusBarOnOpen, 65 | onIdxChange = _this$props.onIdxChange, 66 | onOpen = _this$props.onOpen; 67 | 68 | 69 | if (hideStatusBarOnOpen && reactNative.Platform.OS === 'ios') { 70 | reactNative.StatusBar.setHidden(true, 'fade'); 71 | } 72 | 73 | activeComponent.measure( 74 | // eslint-disable-next-line max-params 75 | function (rx, ry, width, height, x, y) { 76 | _this.setState({ 77 | fullscreen: true, 78 | selectedIdx: startIdx, 79 | animating: true, 80 | origin: { x: x, y: y, width: width, height: height }, 81 | target: { x: 0, y: 0, opacity: 1 } 82 | }, function () { 83 | if (onIdxChange) { 84 | onIdxChange(startIdx); 85 | } 86 | 87 | _this.animateOpenAnimToValue(1, onOpen); 88 | }); 89 | }); 90 | }, _this.close = function () { 91 | var activeComponent = _this.getComponentAtIdx(_this.state.selectedIdx); 92 | 93 | if (!activeComponent) return; 94 | 95 | var _this$props2 = _this.props, 96 | hideStatusBarOnOpen = _this$props2.hideStatusBarOnOpen, 97 | onClose = _this$props2.onClose; 98 | 99 | 100 | if (hideStatusBarOnOpen && reactNative.Platform.OS === 'ios') { 101 | reactNative.StatusBar.setHidden(false, 'fade'); 102 | } 103 | 104 | _this.setState({ animating: true }); 105 | 106 | activeComponent.measure( 107 | // eslint-disable-next-line max-params 108 | function (rx, ry, width, height, x, y) { 109 | _this.setState({ 110 | origin: { x: x, y: y, width: width, height: height }, 111 | slidesDown: x + width < 0 || x > screenWidth 112 | }); 113 | 114 | _this.animateOpenAnimToValue(0, function () { 115 | _this.setState({ 116 | fullscreen: false, 117 | selectedImageHidden: false, 118 | slidesDown: false 119 | }); 120 | 121 | if (onClose) { 122 | onClose(); 123 | } 124 | }); 125 | }); 126 | }, _this.captureCarouselItem = function (ref, idx) { 127 | // $FlowFixMe 128 | _this.carouselItems[idx] = ref; 129 | }, _this.getChildren = function () { 130 | var children = _this.props.children; 131 | 132 | 133 | if (Array.isArray(children)) { 134 | return children; 135 | } else if (children) { 136 | return [children]; 137 | } 138 | 139 | return []; 140 | }, _this.getComponentAtIdx = function (idx) { 141 | var activeComponents = _this.props.activeComponents; 142 | 143 | 144 | return activeComponents ? activeComponents[idx] : _this.carouselItems[idx]; 145 | }, _this.animateOpenAnimToValue = function (toValue, onComplete) { 146 | return reactNative.Animated.timing(_this.openAnim, Object.assign({}, ANIM_CONFIG, { 147 | toValue: toValue 148 | })).start(function () { 149 | _this.setState({ animating: false }); 150 | if (onComplete) { 151 | onComplete(); 152 | } 153 | }); 154 | }, _this.handlePanEnd = function (evt, gestureState) { 155 | // eslint-disable-next-line no-magic-numbers 156 | if (Math.abs(gestureState.dy) > 150) { 157 | _this.setState({ 158 | panning: false, 159 | target: { 160 | x: gestureState.dx, 161 | y: gestureState.dy, 162 | opacity: 1 - Math.abs(gestureState.dy / screenHeight) 163 | } 164 | }); 165 | 166 | _this.close(); 167 | } else { 168 | reactNative.Animated.timing(_this.pan, Object.assign({ 169 | toValue: 0 170 | }, ANIM_CONFIG)).start(function () { 171 | return _this.setState({ panning: false }); 172 | }); 173 | } 174 | }, _this.getSwipeableStyle = function (idx) { 175 | var _this$state = _this.state, 176 | fullscreen = _this$state.fullscreen, 177 | origin = _this$state.origin, 178 | selectedIdx = _this$state.selectedIdx, 179 | slidesDown = _this$state.slidesDown, 180 | target = _this$state.target; 181 | 182 | 183 | if (!fullscreen || idx !== selectedIdx) { 184 | return { flex: 1 }; 185 | } 186 | 187 | var inputRange = [0, 1]; 188 | 189 | return !slidesDown ? { 190 | left: _this.openAnim.interpolate({ 191 | inputRange: inputRange, 192 | outputRange: [origin.x, target.x] 193 | }), 194 | top: _this.openAnim.interpolate({ 195 | inputRange: inputRange, 196 | outputRange: [origin.y, target.y] 197 | }), 198 | width: _this.openAnim.interpolate({ 199 | inputRange: inputRange, 200 | outputRange: [origin.width, screenWidth] 201 | }), 202 | height: _this.openAnim.interpolate({ 203 | inputRange: inputRange, 204 | outputRange: [origin.height, screenHeight] 205 | }) 206 | } : { 207 | left: 0, 208 | right: 0, 209 | height: screenHeight, 210 | top: _this.openAnim.interpolate({ 211 | inputRange: inputRange, 212 | outputRange: [screenHeight, target.y] 213 | }) 214 | }; 215 | }, _this.handleModalShow = function () { 216 | var _this$state2 = _this.state, 217 | animating = _this$state2.animating, 218 | selectedImageHidden = _this$state2.selectedImageHidden; 219 | 220 | 221 | if (!selectedImageHidden && animating) { 222 | _this.setState({ selectedImageHidden: true }); 223 | } 224 | }, _this.handleChangeIdx = function (idx) { 225 | _this.setState({ selectedIdx: idx }); 226 | if (_this.props.onIdxChange) { 227 | _this.props.onIdxChange(idx); 228 | } 229 | }, _this.renderFullscreenContent = function (child, idx) { 230 | var _this$props3 = _this.props, 231 | renderContent = _this$props3.renderContent, 232 | zoomEnabled = _this$props3.zoomEnabled; 233 | var _this$state3 = _this.state, 234 | selectedIdx = _this$state3.selectedIdx, 235 | panning = _this$state3.panning; 236 | 237 | 238 | var content = renderContent && renderContent(idx); 239 | var containerStyle = [_this.getSwipeableStyle(idx), selectedIdx === idx && panning && { top: _this.pan }]; 240 | 241 | return React.createElement( 242 | reactNative.Animated.View, 243 | { key: idx, style: containerStyle }, 244 | React.createElement( 245 | reactNative.ScrollView, 246 | { 247 | ref: function ref(_ref2) { 248 | if (_ref2) { 249 | // https://github.com/facebook/react-native/issues/11206 250 | // eslint-disable-next-line no-param-reassign 251 | _ref2.scrollResponderHandleStartShouldSetResponder = function () { 252 | return true; 253 | }; 254 | } 255 | }, 256 | contentContainerStyle: styles.fill, 257 | maximumZoomScale: zoomEnabled ? 2 : 1 // eslint-disable-line no-magic-numbers 258 | , alwaysBounceVertical: false 259 | }, 260 | content ? React.cloneElement(content, Object.assign({}, content.props, _this.panResponder.panHandlers)) : React.cloneElement(child, Object.assign({}, child.props, _this.props.activeProps, _this.panResponder.panHandlers)) 261 | ) 262 | ); 263 | }, _this.renderDefaultHeader = function () { 264 | return React.createElement( 265 | reactNative.TouchableWithoutFeedback, 266 | { onPress: _this.close }, 267 | React.createElement( 268 | reactNative.View, 269 | null, 270 | React.createElement( 271 | reactNative.Text, 272 | { style: styles.closeText }, 273 | 'Close' 274 | ) 275 | ) 276 | ); 277 | }, _this.getFullscreenOpacity = function () { 278 | var _this$state4 = _this.state, 279 | panning = _this$state4.panning, 280 | target = _this$state4.target; 281 | 282 | 283 | return { 284 | opacity: panning ? _this.pan.interpolate({ 285 | inputRange: [-screenHeight, 0, screenHeight], 286 | outputRange: [0, 1, 0] 287 | }) : _this.openAnim.interpolate({ 288 | inputRange: [0, 1], 289 | outputRange: [0, target.opacity] 290 | }) 291 | }; 292 | }, _this.renderFullscreen = function () { 293 | var _this$props4 = _this.props, 294 | renderHeader = _this$props4.renderHeader, 295 | renderFooter = _this$props4.renderFooter; 296 | var _this$state5 = _this.state, 297 | animating = _this$state5.animating, 298 | panning = _this$state5.panning, 299 | fullscreen = _this$state5.fullscreen, 300 | selectedIdx = _this$state5.selectedIdx; 301 | 302 | 303 | var opacity = _this.getFullscreenOpacity(); 304 | 305 | var header = renderHeader && renderHeader(selectedIdx); 306 | var footer = renderFooter && renderFooter(selectedIdx); 307 | 308 | return React.createElement( 309 | reactNative.Modal, 310 | { 311 | transparent: true, 312 | visible: fullscreen, 313 | onShow: _this.handleModalShow, 314 | onRequestClose: _this.close 315 | }, 316 | React.createElement(reactNative.Animated.View, { style: [styles.modalBackground, opacity] }), 317 | React.createElement( 318 | SwipeableViews, 319 | { 320 | disabled: animating || panning, 321 | index: selectedIdx, 322 | onChangeIndex: _this.handleChangeIdx 323 | }, 324 | _this.getChildren().map(_this.renderFullscreenContent) 325 | ), 326 | React.createElement( 327 | reactNative.Animated.View, 328 | { style: [opacity, styles.headerContainer] }, 329 | header ? React.cloneElement(header, Object.assign({}, header.props, { 330 | style: [header.props.style] 331 | })) : _this.renderDefaultHeader() 332 | ), 333 | footer && React.createElement( 334 | reactNative.Animated.View, 335 | { style: [opacity, styles.footerContainer] }, 336 | footer 337 | ) 338 | ); 339 | }, _temp), _possibleConstructorReturn(_this, _ret); 340 | } 341 | 342 | // eslint-disable-line flowtype/no-weak-types 343 | 344 | 345 | _createClass(ImageCarousel, [{ 346 | key: 'componentWillMount', 347 | value: function componentWillMount() { 348 | var _this2 = this; 349 | 350 | this.panResponder = reactNative.PanResponder.create({ 351 | onStartShouldSetPanResponder: function onStartShouldSetPanResponder() { 352 | return !_this2.state.animating; 353 | }, 354 | onStartShouldSetPanResponderCapture: function onStartShouldSetPanResponderCapture() { 355 | return !_this2.state.animating; 356 | }, 357 | onMoveShouldSetPanResponder: function onMoveShouldSetPanResponder() { 358 | return !_this2.state.animating; 359 | }, 360 | onMoveShouldSetPanResponderCapture: function onMoveShouldSetPanResponderCapture() { 361 | return !_this2.state.animating; 362 | }, 363 | onPanResponderTerminationRequest: function onPanResponderTerminationRequest() { 364 | return true; 365 | }, 366 | // eslint-disable-next-line flowtype/no-weak-types 367 | onPanResponderMove: function onPanResponderMove(evt, gestureState) { 368 | _this2.pan.setValue(gestureState.dy); 369 | 370 | // eslint-disable-next-line no-magic-numbers 371 | if (Math.abs(gestureState.dy) > 15 && !_this2.state.panning) { 372 | _this2.pan.setValue(0); 373 | _this2.setState({ panning: true }); 374 | } 375 | }, 376 | onPanResponderRelease: this.handlePanEnd, 377 | onPanResponderTerminate: this.handlePanEnd 378 | }); 379 | } 380 | 381 | // eslint-disable-next-line flowtype/no-weak-types 382 | 383 | }, { 384 | key: 'render', 385 | value: function render() { 386 | var _this3 = this; 387 | 388 | var _props = this.props, 389 | style = _props.style, 390 | _props$horizontal = _props.horizontal, 391 | horizontal = _props$horizontal === undefined ? true : _props$horizontal, 392 | contentContainerStyle = _props.contentContainerStyle; 393 | var _state = this.state, 394 | fullscreen = _state.fullscreen, 395 | animating = _state.animating, 396 | selectedImageHidden = _state.selectedImageHidden, 397 | selectedIdx = _state.selectedIdx; 398 | 399 | 400 | var getOpacity = function getOpacity(idx) { 401 | return { 402 | opacity: selectedImageHidden && selectedIdx === idx ? 0 : 1 403 | }; 404 | }; 405 | 406 | return React.createElement( 407 | reactNative.View, 408 | { style: style }, 409 | React.createElement( 410 | reactNative.ScrollView, 411 | { 412 | horizontal: horizontal, 413 | contentContainerStyle: contentContainerStyle, 414 | scrollEnabled: !animating, 415 | alwaysBounceHorizontal: false, 416 | showsHorizontalScrollIndicator: false 417 | }, 418 | this.getChildren().map(function (child, idx) { 419 | return React.createElement( 420 | reactNative.TouchableWithoutFeedback, 421 | { 422 | key: 'slider-image-' + idx // eslint-disable-line react/no-array-index-key 423 | , onPress: function onPress() { 424 | return _this3.open(idx); 425 | } 426 | }, 427 | React.createElement( 428 | reactNative.View, 429 | { 430 | ref: function ref(_ref3) { 431 | _this3.captureCarouselItem(_ref3, idx); 432 | }, 433 | style: getOpacity(idx) 434 | }, 435 | child 436 | ) 437 | ); 438 | }) 439 | ), 440 | fullscreen && this.renderFullscreen() 441 | ); 442 | } 443 | }]); 444 | 445 | return ImageCarousel; 446 | }(React.Component); 447 | 448 | ImageCarousel.defaultProps = { 449 | zoomEnabled: true, 450 | hideStatusBarOnOpen: true 451 | }; 452 | 453 | 454 | var styles = reactNative.StyleSheet.create({ 455 | fill: { 456 | flex: 1 457 | }, 458 | modalBackground: Object.assign({}, reactNative.StyleSheet.absoluteFillObject, { 459 | backgroundColor: 'black' 460 | }), 461 | headerContainer: { 462 | position: 'absolute', 463 | top: 0, 464 | left: 0, 465 | right: 0 466 | }, 467 | footerContainer: { 468 | position: 'absolute', 469 | bottom: 0, 470 | left: 0, 471 | right: 0 472 | }, 473 | closeText: { 474 | color: 'white', 475 | textAlign: 'right', 476 | padding: 10 477 | } 478 | }); 479 | 480 | module.exports = ImageCarousel; 481 | -------------------------------------------------------------------------------- /jsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "include": [ 3 | "src/**/*.js" 4 | ] 5 | } 6 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "react-native-image-carousel", 3 | "version": "0.4.6", 4 | "description": "Image carousel with support for fullscreen mode with swiping and pinch-to-zoom.", 5 | "homepage": "https://github.com/anvilabs/react-native-image-carousel", 6 | "author": "Binur Konarbai ", 7 | "repository": "anvilabs/react-native-image-carousel", 8 | "license": "MIT", 9 | "keywords": [ 10 | "react-native", 11 | "image", 12 | "carousel", 13 | "fullscreen", 14 | "lightbox", 15 | "gallery", 16 | "swipe", 17 | "slide" 18 | ], 19 | "main": "dist/index.js", 20 | "engines": { 21 | "node": ">=6.0.0" 22 | }, 23 | "scripts": { 24 | "typecheck": "flow .", 25 | "lint": "eslint --cache .", 26 | "lint:fix": "eslint --cache --fix .", 27 | "test": "run-p --silent typecheck lint", 28 | "build": "rollup -c", 29 | "precommit": "lint-staged", 30 | "commitmsg": "commitlint -e", 31 | "prepush": "nyr test" 32 | }, 33 | "lint-staged": { 34 | "{src,Example/app}/**/*.js": [ 35 | "eslint --cache --fix", 36 | "git add" 37 | ] 38 | }, 39 | "dependencies": { 40 | "react-swipeable-views-native": "^0.13.2" 41 | }, 42 | "peerDependencies": { 43 | "react": "*", 44 | "react-native": "*" 45 | }, 46 | "devDependencies": { 47 | "@commitlint/cli": "^4.2.2", 48 | "@commitlint/config-angular": "^4.2.1", 49 | "babel-core": "^6.26.0", 50 | "babel-plugin-transform-class-properties": "^6.24.1", 51 | "babel-plugin-transform-object-rest-spread": "^6.26.0", 52 | "babel-plugin-transform-react-jsx": "^6.24.1", 53 | "babel-preset-env": "^1.6.1", 54 | "babel-preset-es2015": "^6.24.1", 55 | "eslint": "^4.10.0", 56 | "eslint-config-anvilabs": "^16.0.0", 57 | "eslint-config-anvilabs-react": "^16.0.0", 58 | "flow-bin": "^0.56.0", 59 | "husky": "^0.14.3", 60 | "lint-staged": "^4.3.0", 61 | "npm-run-all": "^4.1.1", 62 | "nyr": "^1.1.0", 63 | "prettier": "^1.7.4", 64 | "react": "^16.0.0", 65 | "react-native": "^0.50.1", 66 | "rollup": "^0.50.0", 67 | "rollup-plugin-babel": "^3.0.2", 68 | "rollup-plugin-flow": "^1.1.1" 69 | } 70 | } 71 | -------------------------------------------------------------------------------- /rollup.config.js: -------------------------------------------------------------------------------- 1 | /* @flow */ 2 | 3 | import babel from 'rollup-plugin-babel'; 4 | import flow from 'rollup-plugin-flow'; 5 | 6 | const config = { 7 | entry: 'src/index.js', 8 | dest: 'dist/index.js', 9 | format: 'cjs', 10 | external: ['react', 'react-native', 'react-swipeable-views-native'], 11 | plugins: [ 12 | flow(), 13 | babel({ 14 | babelrc: false, 15 | runtimeHelpers: true, 16 | presets: [ 17 | [ 18 | 'es2015', 19 | { 20 | modules: false, 21 | }, 22 | ], 23 | ], 24 | plugins: [ 25 | 'babel-plugin-transform-react-jsx', 26 | 'babel-plugin-transform-class-properties', 27 | [ 28 | 'transform-object-rest-spread', 29 | { 30 | useBuiltIns: true, 31 | }, 32 | ], 33 | ], 34 | exclude: 'node_modules/**', 35 | }), 36 | ], 37 | }; 38 | 39 | export default config; 40 | -------------------------------------------------------------------------------- /src/flow/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | rules: { 3 | 'no-undef': 'off', 4 | }, 5 | }; 6 | -------------------------------------------------------------------------------- /src/flow/react-swipeable-views-native.js: -------------------------------------------------------------------------------- 1 | /* @flow */ 2 | 3 | declare module 'react-swipeable-views-native' { 4 | declare module.exports: any; 5 | } 6 | 7 | declare module 'react-swipeable-views-native/lib/SwipeableViews.scroll' { 8 | declare module.exports: any; 9 | } 10 | -------------------------------------------------------------------------------- /src/index.js: -------------------------------------------------------------------------------- 1 | /* @flow */ 2 | 3 | import { 4 | Animated, 5 | Dimensions, 6 | Modal, 7 | PanResponder, 8 | Platform, 9 | ScrollView, 10 | StatusBar, 11 | StyleSheet, 12 | Text, 13 | TouchableWithoutFeedback, 14 | View, 15 | } from 'react-native'; 16 | import * as React from 'react'; 17 | import SwipeableViews from 'react-swipeable-views-native'; 18 | import type {StyleObj} from 'react-native/Libraries/StyleSheet/StyleSheetTypes'; 19 | 20 | const ANIM_CONFIG = {duration: 300}; 21 | const screenSize = Dimensions.get('window'); 22 | const screenWidth = screenSize.width; 23 | const screenHeight = 24 | screenSize.height - 25 | Platform.select({ios: 0, android: StatusBar.currentHeight}); 26 | 27 | type PropsType = {| 28 | style?: ?StyleObj, 29 | contentContainerStyle?: ?StyleObj, 30 | activeProps?: ?{[key: string]: mixed}, 31 | activeComponents?: $ReadOnlyArray>, 32 | children?: React.Element<*> | $ReadOnlyArray>, 33 | zoomEnabled: boolean, 34 | hideStatusBarOnOpen: boolean, 35 | renderHeader?: ?(idx: number) => React.Element<*>, 36 | renderFooter?: ?(idx: number) => React.Element<*>, 37 | renderContent?: ?(idx: number) => React.Element<*>, 38 | onIdxChange?: ?(idx: number) => void, 39 | onOpen?: ?() => void, 40 | onClose?: ?() => void, 41 | horizontal?: boolean, 42 | snapToAlignment?: 'start' | 'center' | 'end', 43 | snapToInterval?: number, 44 | |}; 45 | type StateType = {| 46 | origin: {| 47 | x: number, 48 | y: number, 49 | width: number, 50 | height: number, 51 | |}, 52 | target: {| 53 | x: number, 54 | y: number, 55 | opacity: number, 56 | |}, 57 | fullscreen: boolean, 58 | selectedIdx: number, 59 | animating: boolean, 60 | panning: boolean, 61 | selectedImageHidden: boolean, 62 | slidesDown: boolean, 63 | |}; 64 | 65 | class ImageCarousel extends React.Component { 66 | static defaultProps = { 67 | zoomEnabled: true, 68 | hideStatusBarOnOpen: true, 69 | }; 70 | 71 | panResponder: Object; // eslint-disable-line flowtype/no-weak-types 72 | openAnim = new Animated.Value(0); 73 | pan = new Animated.Value(0); 74 | carouselItems: $ReadOnlyArray> = Array.isArray( 75 | this.props.children, 76 | ) 77 | ? this.props.children.map(() => null) 78 | : [null]; 79 | 80 | state = { 81 | origin: { 82 | x: 0, 83 | y: 0, 84 | width: 0, 85 | height: 0, 86 | }, 87 | target: { 88 | x: 0, 89 | y: 0, 90 | opacity: 1, 91 | }, 92 | fullscreen: false, 93 | selectedIdx: 0, 94 | animating: false, 95 | panning: false, 96 | selectedImageHidden: false, 97 | slidesDown: false, 98 | }; 99 | 100 | componentDidMount() { 101 | this.panResponder = PanResponder.create({ 102 | onStartShouldSetPanResponder: () => !this.state.animating, 103 | onStartShouldSetPanResponderCapture: () => !this.state.animating, 104 | onMoveShouldSetPanResponder: () => !this.state.animating, 105 | onMoveShouldSetPanResponderCapture: () => !this.state.animating, 106 | onPanResponderTerminationRequest: () => true, 107 | // eslint-disable-next-line flowtype/no-weak-types 108 | onPanResponderMove: (evt: Object, gestureState: Object) => { 109 | this.pan.setValue(gestureState.dy); 110 | 111 | // eslint-disable-next-line no-magic-numbers 112 | if (Math.abs(gestureState.dy) > 15 && !this.state.panning) { 113 | this.pan.setValue(0); 114 | this.setState({panning: true}); 115 | } 116 | }, 117 | onPanResponderRelease: this.handlePanEnd, 118 | onPanResponderTerminate: this.handlePanEnd, 119 | }); 120 | } 121 | 122 | open = (startIdx: number) => { 123 | const activeComponent = this.getComponentAtIdx(startIdx); 124 | 125 | if (!activeComponent) return; 126 | 127 | const {hideStatusBarOnOpen, onIdxChange, onOpen} = this.props; 128 | 129 | if (hideStatusBarOnOpen && Platform.OS === 'ios') { 130 | StatusBar.setHidden(true, 'fade'); 131 | } 132 | 133 | (activeComponent: $FlowFixMe).measure( 134 | // eslint-disable-next-line max-params 135 | ( 136 | rx: number, 137 | ry: number, 138 | width: number, 139 | height: number, 140 | x: number, 141 | y: number, 142 | ) => { 143 | this.setState( 144 | { 145 | fullscreen: true, 146 | selectedIdx: startIdx, 147 | animating: true, 148 | origin: {x, y, width, height}, 149 | target: {x: 0, y: 0, opacity: 1}, 150 | }, 151 | () => { 152 | if (onIdxChange) { 153 | onIdxChange(startIdx); 154 | } 155 | 156 | this.animateOpenAnimToValue(1, onOpen); 157 | }, 158 | ); 159 | }, 160 | ); 161 | }; 162 | 163 | close = () => { 164 | const activeComponent = this.getComponentAtIdx(this.state.selectedIdx); 165 | 166 | if (!activeComponent) return; 167 | 168 | const {hideStatusBarOnOpen, onClose} = this.props; 169 | 170 | if (hideStatusBarOnOpen && Platform.OS === 'ios') { 171 | StatusBar.setHidden(false, 'fade'); 172 | } 173 | 174 | this.setState({animating: true}); 175 | 176 | (activeComponent: $FlowFixMe).measure( 177 | // eslint-disable-next-line max-params 178 | ( 179 | rx: number, 180 | ry: number, 181 | width: number, 182 | height: number, 183 | x: number, 184 | y: number, 185 | ) => { 186 | this.setState({ 187 | origin: {x, y, width, height}, 188 | slidesDown: x + width < 0 || x > screenWidth, 189 | }); 190 | 191 | this.animateOpenAnimToValue(0, () => { 192 | this.setState({ 193 | fullscreen: false, 194 | selectedImageHidden: false, 195 | slidesDown: false, 196 | }); 197 | 198 | if (onClose) { 199 | onClose(); 200 | } 201 | }); 202 | }, 203 | ); 204 | }; 205 | 206 | captureCarouselItem = (ref: ?React.Component, idx: number) => { 207 | // $FlowFixMe 208 | this.carouselItems[idx] = ref; 209 | }; 210 | 211 | getChildren = (): $ReadOnlyArray> => { 212 | const {children} = this.props; 213 | 214 | if (Array.isArray(children)) { 215 | return children; 216 | } else if (children) { 217 | return [children]; 218 | } 219 | 220 | return []; 221 | }; 222 | 223 | getComponentAtIdx = (idx: number): React.Node => { 224 | const {activeComponents} = this.props; 225 | 226 | return activeComponents ? activeComponents[idx] : this.carouselItems[idx]; 227 | }; 228 | 229 | animateOpenAnimToValue = (toValue: number, onComplete?: ?() => void) => 230 | Animated.timing(this.openAnim, { 231 | ...ANIM_CONFIG, 232 | toValue, 233 | }).start(() => { 234 | this.setState({animating: false}); 235 | if (onComplete) { 236 | onComplete(); 237 | } 238 | }); 239 | 240 | // eslint-disable-next-line flowtype/no-weak-types 241 | handlePanEnd = (evt: Object, gestureState: {dx: number, dy: number}) => { 242 | // eslint-disable-next-line no-magic-numbers 243 | if (Math.abs(gestureState.dy) > 150) { 244 | this.setState({ 245 | panning: false, 246 | target: { 247 | x: gestureState.dx, 248 | y: gestureState.dy, 249 | opacity: 1 - Math.abs(gestureState.dy / screenHeight), 250 | }, 251 | }); 252 | 253 | this.close(); 254 | } else { 255 | Animated.timing(this.pan, { 256 | toValue: 0, 257 | ...ANIM_CONFIG, 258 | }).start(() => this.setState({panning: false})); 259 | } 260 | }; 261 | 262 | getSwipeableStyle = (idx: number): StyleObj => { 263 | const {fullscreen, origin, selectedIdx, slidesDown, target} = this.state; 264 | 265 | if (!fullscreen || idx !== selectedIdx) { 266 | return {flex: 1}; 267 | } 268 | 269 | const inputRange = [0, 1]; 270 | 271 | return !slidesDown 272 | ? { 273 | left: this.openAnim.interpolate({ 274 | inputRange, 275 | outputRange: [origin.x, target.x], 276 | }), 277 | top: this.openAnim.interpolate({ 278 | inputRange, 279 | outputRange: [origin.y, target.y], 280 | }), 281 | width: this.openAnim.interpolate({ 282 | inputRange, 283 | outputRange: [origin.width, screenWidth], 284 | }), 285 | height: this.openAnim.interpolate({ 286 | inputRange, 287 | outputRange: [origin.height, screenHeight], 288 | }), 289 | } 290 | : { 291 | left: 0, 292 | right: 0, 293 | height: screenHeight, 294 | top: this.openAnim.interpolate({ 295 | inputRange, 296 | outputRange: [screenHeight, target.y], 297 | }), 298 | }; 299 | }; 300 | 301 | handleModalShow = () => { 302 | const {animating, selectedImageHidden} = this.state; 303 | 304 | if (!selectedImageHidden && animating) { 305 | this.setState({selectedImageHidden: true}); 306 | } 307 | }; 308 | 309 | handleChangeIdx = (idx: number) => { 310 | this.setState({selectedIdx: idx}); 311 | if (this.props.onIdxChange) { 312 | this.props.onIdxChange(idx); 313 | } 314 | }; 315 | 316 | renderFullscreenContent = (child: React$Element<*>, idx: number) => { 317 | const {renderContent, zoomEnabled} = this.props; 318 | const {selectedIdx, panning} = this.state; 319 | 320 | const content = renderContent && renderContent(idx); 321 | const containerStyle = [ 322 | this.getSwipeableStyle(idx), 323 | selectedIdx === idx && panning && {top: this.pan}, 324 | ]; 325 | 326 | return ( 327 | 328 | { 330 | if (ref) { 331 | // https://github.com/facebook/react-native/issues/11206 332 | // eslint-disable-next-line no-param-reassign 333 | ref.scrollResponderHandleStartShouldSetResponder = () => true; 334 | } 335 | }} 336 | contentContainerStyle={styles.fill} 337 | maximumZoomScale={zoomEnabled ? 2 : 1} // eslint-disable-line no-magic-numbers 338 | alwaysBounceVertical={false} 339 | > 340 | {content 341 | ? React.cloneElement(content, { 342 | ...content.props, 343 | ...this.panResponder.panHandlers, 344 | }) 345 | : React.cloneElement(child, { 346 | ...child.props, 347 | ...this.props.activeProps, 348 | ...this.panResponder.panHandlers, 349 | })} 350 | 351 | 352 | ); 353 | }; 354 | 355 | renderDefaultHeader = () => ( 356 | 357 | 358 | Close 359 | 360 | 361 | ); 362 | 363 | getFullscreenOpacity = () => { 364 | const {panning, target} = this.state; 365 | 366 | return { 367 | opacity: panning 368 | ? this.pan.interpolate({ 369 | inputRange: [-screenHeight, 0, screenHeight], 370 | outputRange: [0, 1, 0], 371 | }) 372 | : this.openAnim.interpolate({ 373 | inputRange: [0, 1], 374 | outputRange: [0, target.opacity], 375 | }), 376 | }; 377 | }; 378 | 379 | renderFullscreen = () => { 380 | const {renderHeader, renderFooter} = this.props; 381 | const {animating, panning, fullscreen, selectedIdx} = this.state; 382 | 383 | const opacity = this.getFullscreenOpacity(); 384 | 385 | const header = renderHeader && renderHeader(selectedIdx); 386 | const footer = renderFooter && renderFooter(selectedIdx); 387 | 388 | return ( 389 | 395 | 396 | 401 | {this.getChildren().map(this.renderFullscreenContent)} 402 | 403 | 404 | {header 405 | ? React.cloneElement(header, { 406 | ...header.props, 407 | style: [header.props.style], 408 | }) 409 | : this.renderDefaultHeader()} 410 | 411 | {footer && ( 412 | 413 | {footer} 414 | 415 | )} 416 | 417 | ); 418 | }; 419 | 420 | render() { 421 | const { 422 | style, 423 | horizontal = true, 424 | contentContainerStyle, 425 | snapToAlignment, 426 | snapToInterval, 427 | } = this.props; 428 | const { 429 | fullscreen, 430 | animating, 431 | selectedImageHidden, 432 | selectedIdx, 433 | } = this.state; 434 | 435 | const getOpacity = (idx: number) => ({ 436 | opacity: selectedImageHidden && selectedIdx === idx ? 0 : 1, 437 | }); 438 | 439 | return ( 440 | 441 | 450 | {this.getChildren().map((child, idx) => ( 451 | this.open(idx)} 454 | > 455 | { 457 | this.captureCarouselItem(ref, idx); 458 | }} 459 | style={getOpacity(idx)} 460 | > 461 | {child} 462 | 463 | 464 | ))} 465 | 466 | {fullscreen && this.renderFullscreen()} 467 | 468 | ); 469 | } 470 | } 471 | 472 | const styles = StyleSheet.create({ 473 | fill: { 474 | flex: 1, 475 | }, 476 | modalBackground: { 477 | ...StyleSheet.absoluteFillObject, 478 | backgroundColor: 'black', 479 | }, 480 | headerContainer: { 481 | position: 'absolute', 482 | top: 0, 483 | left: 0, 484 | right: 0, 485 | }, 486 | footerContainer: { 487 | position: 'absolute', 488 | bottom: 0, 489 | left: 0, 490 | right: 0, 491 | }, 492 | closeText: { 493 | color: 'white', 494 | textAlign: 'right', 495 | padding: 10, 496 | }, 497 | }); 498 | 499 | export default ImageCarousel; 500 | --------------------------------------------------------------------------------