mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Compare commits
127
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2a41509480 | ||
|
|
2563503d0c | ||
|
|
ee60c11f75 | ||
|
|
847a6f9eec | ||
|
|
f7f400fb7e | ||
|
|
2f70001c6c | ||
|
|
9775308458 | ||
|
|
2c63f49269 | ||
|
|
f7bd2a333c | ||
|
|
9b877d6692 | ||
|
|
cf19833ad8 | ||
|
|
df8da3b6c4 | ||
|
|
997bfb50e1 | ||
|
|
b4375b4606 | ||
|
|
0b996577e3 | ||
|
|
49cbca7464 | ||
|
|
dd4611721d | ||
|
|
82b123e744 | ||
|
|
7c3a61f3b6 | ||
|
|
796122d8f3 | ||
|
|
aebb34a294 | ||
|
|
ab972708a8 | ||
|
|
7f58189605 | ||
|
|
b9b7fabf98 | ||
|
|
b0319f3293 | ||
|
|
bbedf2da9a | ||
|
|
3bd89867d6 | ||
|
|
b2848a54b0 | ||
|
|
a8d4666651 | ||
|
|
11a495cb32 | ||
|
|
a1a0a69546 | ||
|
|
b826596700 | ||
|
|
870bc4807a | ||
|
|
c75612219e | ||
|
|
67a3c42d1a | ||
|
|
9a36872f0c | ||
|
|
79902f99b8 | ||
|
|
9c67e749d8 | ||
|
|
183c316f4c | ||
|
|
6b95c4fb14 | ||
|
|
e5c2a66897 | ||
|
|
d85da86dc7 | ||
|
|
6627d7723c | ||
|
|
0a9e652bdd | ||
|
|
28968e2c0b | ||
|
|
654d7595fe | ||
|
|
c3139d798a | ||
|
|
e46ea8c737 | ||
|
|
c491b22233 | ||
|
|
176a578238 | ||
|
|
b2a251948f | ||
|
|
f96f9c5fd6 | ||
|
|
d9e5b313bb | ||
|
|
af226ef949 | ||
|
|
f71f4e7906 | ||
|
|
2815ada238 | ||
|
|
0356cbd13b | ||
|
|
46be5bf71c | ||
|
|
e3c6f38773 | ||
|
|
45e6fcdba0 | ||
|
|
c49d249fd7 | ||
|
|
33d710e8c5 | ||
|
|
e57a43b97a | ||
|
|
c9ff0bc212 | ||
|
|
ddd65f1ba9 | ||
|
|
a8391bde7d | ||
|
|
fa574c6092 | ||
|
|
52f350a9cb | ||
|
|
d3b41e0da3 | ||
|
|
4d33080f0f | ||
|
|
f9e742aadf | ||
|
|
0ec1017660 | ||
|
|
1fd7315c3b | ||
|
|
80f9e1f7de | ||
|
|
56a42e57d0 | ||
|
|
33a2e533b7 | ||
|
|
a6a66c5b39 | ||
|
|
4a1bb8fe8d | ||
|
|
4fbfbe6bb0 | ||
|
|
85ff264445 | ||
|
|
6661633390 | ||
|
|
33da6047a3 | ||
|
|
4e767013ed | ||
|
|
b750e3b21b | ||
|
|
077c3ab349 | ||
|
|
a163f70f87 | ||
|
|
3559e42c55 | ||
|
|
c547f783c4 | ||
|
|
7ff6657985 | ||
|
|
489b98bf10 | ||
|
|
ba31d29dc9 | ||
|
|
4cdbb77c33 | ||
|
|
0b5e8b4852 | ||
|
|
fc5e340e89 | ||
|
|
4216cdef13 | ||
|
|
a0ff8c7706 | ||
|
|
2e008bc464 | ||
|
|
f9f40cd3e4 | ||
|
|
9b147a53d1 | ||
|
|
5ea5683d01 | ||
|
|
59c7967627 | ||
|
|
0ae4c47daa | ||
|
|
c79246dbc6 | ||
|
|
7d1dedadd7 | ||
|
|
4996b9aeb4 | ||
|
|
19a9c5e41d | ||
|
|
5c8481e836 | ||
|
|
6ad1f0957a | ||
|
|
a010a0cebd | ||
|
|
f1055bcac8 | ||
|
|
30da2622e2 | ||
|
|
2679f3efb6 | ||
|
|
d89901fa60 | ||
|
|
350377f57c | ||
|
|
632f1202ab | ||
|
|
dabb78b127 | ||
|
|
0673ac25f1 | ||
|
|
15cd98b782 | ||
|
|
3852c42ad8 | ||
|
|
2668dc8e1b | ||
|
|
d2dc451407 | ||
|
|
b263560c73 | ||
|
|
099b28006b | ||
|
|
b8e60a3ca3 | ||
|
|
c01a171ed8 | ||
|
|
2789ba016b | ||
|
|
4803419dc8 |
+106
-96
@@ -1,41 +1,35 @@
|
||||
aliases:
|
||||
- &restore-node-cache
|
||||
keys:
|
||||
- v1-dependencies-{{ arch }}-{{ .Branch }}-{{ checksum "package.json" }}
|
||||
- v1-dependencies-{{ arch }}-{{ checksum "package.json" }}
|
||||
# Fallback in case checksum fails
|
||||
- v1-dependencies-{{ arch }}-{{ .Branch }}-
|
||||
- v1-dependencies-{{ arch }}-
|
||||
|
||||
- &save-node-cache
|
||||
paths:
|
||||
- node_modules
|
||||
key: v1-dependencies-{{ arch }}-{{ .Branch }}-{{ checksum "package.json" }}
|
||||
key: v1-dependencies-{{ arch }}-{{ checksum "package.json" }}
|
||||
|
||||
- &restore-cache-analysis
|
||||
keys:
|
||||
- v1-analysis-dependencies-{{ arch }}-{{ .Branch }}-{{ checksum "package.json" }}{{ checksum "danger/package.json" }}
|
||||
- v1-analysis-dependencies-{{ arch }}-{{ checksum "package.json" }}{{ checksum "danger/package.json" }}
|
||||
# Fallback in case checksum fails
|
||||
- v1-analysis-dependencies-{{ arch }}-{{ .Branch }}-
|
||||
- v1-analysis-dependencies-{{ arch }}-
|
||||
- &save-cache-analysis
|
||||
paths:
|
||||
- danger/node_modules
|
||||
- node_modules
|
||||
key: v1-analysis-dependencies-{{ arch }}-{{ .Branch }}-{{ checksum "package.json" }}{{ checksum "danger/package.json" }}
|
||||
key: v1-analysis-dependencies-{{ arch }}-{{ checksum "package.json" }}{{ checksum "danger/package.json" }}
|
||||
|
||||
- &restore-cache-android-packages
|
||||
keys:
|
||||
- v1-android-sdkmanager-packages-{{ arch }}-{{ checksum "scripts/circle-ci-android-setup.sh" }}
|
||||
- v2-android-sdkmanager-packages-{{ arch }}-{{ checksum "scripts/circle-ci-android-setup.sh" }}
|
||||
# Fallback in case checksum fails
|
||||
- v1-android-sdkmanager-packages-{{ arch }}-
|
||||
- v2-android-sdkmanager-packages-{{ arch }}-
|
||||
- &save-cache-android-packages
|
||||
paths:
|
||||
- /opt/android/sdk/system-images/android-23
|
||||
- /opt/android/sdk/system-images/android-19
|
||||
- /opt/android/sdk/platforms/android-26
|
||||
- /opt/android/sdk/platforms/android-23
|
||||
- /opt/android/sdk/platforms/android-19
|
||||
- /opt/android/sdk/build-tools/23.0.1
|
||||
- /opt/android/sdk/add-ons/addon-google_apis-google-23
|
||||
key: v1-android-sdkmanager-packages-{{ arch }}-{{ checksum "scripts/circle-ci-android-setup.sh" }}
|
||||
- /opt/android/sdk
|
||||
key: v2-android-sdkmanager-packages-{{ arch }}-{{ checksum "scripts/circle-ci-android-setup.sh" }}
|
||||
|
||||
- &restore-cache-ndk
|
||||
keys:
|
||||
@@ -50,23 +44,13 @@ aliases:
|
||||
- /opt/ndk
|
||||
key: v1-android-ndk-{{ arch }}-r10e-32-64
|
||||
|
||||
- &restore-cache-buck-downloads
|
||||
keys:
|
||||
- v1-buck-downloads-{{ arch }}-{{ .Branch }}-{{ checksum "ReactAndroid/build.gradle" }}
|
||||
# Fallback in case checksum fails
|
||||
- v1-buck-downloads-{{ arch }}-{{ .Branch }}-
|
||||
- &save-cache-buck-downloads
|
||||
paths:
|
||||
- "ReactAndroid/build/downloads"
|
||||
key: v1-buck-downloads-{{ arch }}-{{ .Branch }}-{{ checksum "ReactAndroid/build.gradle" }}
|
||||
|
||||
- &restore-cache-buck
|
||||
keys:
|
||||
- v1-buck-{{ arch }}-v2017.11.16.01
|
||||
- v2-buck-{{ arch }}-v2017.09.04.02
|
||||
- &save-cache-buck
|
||||
paths:
|
||||
- ~/buck
|
||||
key: v1-buck-{{ arch }}-v2017.11.16.01
|
||||
key: v2-buck-{{ arch }}-v2017.09.04.02
|
||||
|
||||
- &restore-cache-watchman
|
||||
keys:
|
||||
@@ -96,9 +80,16 @@ aliases:
|
||||
- &run-node-tests
|
||||
|
|
||||
npm test -- --maxWorkers=2
|
||||
|
||||
- &run-lint-checks
|
||||
|
|
||||
npm run lint
|
||||
|
||||
- &run-flow-checks
|
||||
|
|
||||
npm run flow -- check
|
||||
|
||||
|
||||
- &filter-only-master-stable
|
||||
branches:
|
||||
only:
|
||||
@@ -144,14 +135,45 @@ aliases:
|
||||
sudo apt-get update -y
|
||||
sudo apt-get install ant autoconf automake g++ gcc libqt5widgets5 lib32z1 lib32stdc++6 make maven python-dev python3-dev qml-module-qtquick-controls qtdeclarative5-dev file -y
|
||||
|
||||
- &install-android-app-dependencies
|
||||
|
|
||||
buck fetch ReactAndroid/src/test/java/com/facebook/react/modules
|
||||
buck fetch ReactAndroid/src/main/java/com/facebook/react
|
||||
buck fetch ReactAndroid/src/main/java/com/facebook/react/shell
|
||||
buck fetch ReactAndroid/src/test/...
|
||||
buck fetch ReactAndroid/src/androidTest/...
|
||||
./gradlew :ReactAndroid:downloadBoost :ReactAndroid:downloadDoubleConversion :ReactAndroid:downloadFolly :ReactAndroid:downloadGlog :ReactAndroid:downloadJSCHeaders
|
||||
- &build-android-app
|
||||
name: Build Android App
|
||||
command: |
|
||||
buck build ReactAndroid/src/main/java/com/facebook/react
|
||||
buck build ReactAndroid/src/main/java/com/facebook/react/shell
|
||||
|
||||
- &wait-for-avd
|
||||
name: Wait for Android Virtual Device
|
||||
command: source scripts/circle-ci-android-setup.sh && waitForAVD
|
||||
|
||||
- &check-js-bundle
|
||||
name: Check for JavaScript Bundle
|
||||
command: |
|
||||
if [[ ! -e ReactAndroid/src/androidTest/assets/AndroidTestBundle.js ]]; then
|
||||
echo "JavaScript bundle missing, verify build-js-bundle step"; exit 1;
|
||||
else
|
||||
echo "JavaScript bundle found.";
|
||||
fi
|
||||
|
||||
- &compile-native-libs
|
||||
name: Compile Native Libs for Unit and Integration Tests
|
||||
command: ./gradlew :ReactAndroid:packageReactNdkLibsForBuck -Pjobs=$BUILD_THREADS -Pcom.android.build.threadPoolSize=1
|
||||
no_output_timeout: 6m
|
||||
|
||||
- &run-android-unit-tests
|
||||
name: Unit Tests
|
||||
command: buck test ReactAndroid/src/test/... --config build.threads=$BUILD_THREADS
|
||||
|
||||
- &run-android-integration-tests
|
||||
name: Build and Install Test APK
|
||||
command: source scripts/circle-ci-android-setup.sh && NO_BUCKD=1 retry3 buck install ReactAndroid/src/androidTest/buck-runner:instrumentation-tests --config build.threads=$BUILD_THREADS
|
||||
|
||||
- &collect-android-test-results
|
||||
name: Collect Test Results
|
||||
command: |
|
||||
mkdir -p ~/junit/
|
||||
find . -type f -regex ".*/build/test-results/debug/.*xml" -exec cp {} ~/junit/ \;
|
||||
find . -type f -regex ".*/outputs/androidTest-results/connected/.*xml" -exec cp {} ~/junit/ \;
|
||||
when: always
|
||||
|
||||
defaults: &defaults
|
||||
working_directory: ~/react-native
|
||||
@@ -171,6 +193,19 @@ android_defaults: &android_defaults
|
||||
|
||||
version: 2
|
||||
jobs:
|
||||
# Runs JavaScript lint and flow checks
|
||||
run-js-checks:
|
||||
<<: *defaults
|
||||
docker:
|
||||
- image: circleci/node:8
|
||||
steps:
|
||||
- checkout
|
||||
- restore-cache: *restore-node-cache
|
||||
- run: *install-node-dependencies
|
||||
- save-cache: *save-node-cache
|
||||
- run: *run-lint-checks
|
||||
- run: *run-flow-checks
|
||||
|
||||
# Runs JavaScript tests on Node 8
|
||||
test-js-node-8:
|
||||
<<: *defaults
|
||||
@@ -187,19 +222,7 @@ jobs:
|
||||
test-js-node-6:
|
||||
<<: *defaults
|
||||
docker:
|
||||
- image: circleci/node:6.11.0
|
||||
steps:
|
||||
- checkout
|
||||
- restore-cache: *restore-node-cache
|
||||
- run: *install-node-dependencies
|
||||
- save-cache: *save-node-cache
|
||||
- run: *run-node-tests
|
||||
|
||||
# Runs JavaScript tests on Node 4
|
||||
test-js-node-4:
|
||||
<<: *defaults
|
||||
docker:
|
||||
- image: circleci/node:4.8.4
|
||||
- image: circleci/node:6
|
||||
steps:
|
||||
- checkout
|
||||
- restore-cache: *restore-node-cache
|
||||
@@ -287,9 +310,12 @@ jobs:
|
||||
- restore-cache: *restore-node-cache
|
||||
- run: *install-node-dependencies
|
||||
- save-cache: *save-node-cache
|
||||
- restore-cache: *restore-cache-buck-downloads
|
||||
- run: *install-android-app-dependencies
|
||||
- save-cache: *save-cache-buck-downloads
|
||||
- run: buck fetch ReactAndroid/src/test/java/com/facebook/react/modules
|
||||
- run: buck fetch ReactAndroid/src/main/java/com/facebook/react
|
||||
- run: buck fetch ReactAndroid/src/main/java/com/facebook/react/shell
|
||||
- run: buck fetch ReactAndroid/src/test/...
|
||||
- run: buck fetch ReactAndroid/src/androidTest/...
|
||||
- run: ./gradlew :ReactAndroid:downloadBoost :ReactAndroid:downloadDoubleConversion :ReactAndroid:downloadFolly :ReactAndroid:downloadGlog :ReactAndroid:downloadJSCHeaders
|
||||
|
||||
- run:
|
||||
name: Publish React Native Package
|
||||
@@ -351,63 +377,42 @@ jobs:
|
||||
- restore-cache: *restore-cache-ndk
|
||||
- run: *install-ndk
|
||||
- save-cache: *save-cache-ndk
|
||||
|
||||
- restore-cache: *restore-cache-buck
|
||||
- run: *install-buck
|
||||
- save-cache: *save-cache-buck
|
||||
|
||||
- run: *install-node
|
||||
|
||||
- restore-cache: *restore-node-cache
|
||||
- run: *install-node-dependencies
|
||||
- save-cache: *save-node-cache
|
||||
- restore-cache: *restore-cache-buck-downloads
|
||||
- run: *install-android-app-dependencies
|
||||
- save-cache: *save-cache-buck-downloads
|
||||
|
||||
- run:
|
||||
name: Build Android App
|
||||
command: |
|
||||
buck build ReactAndroid/src/main/java/com/facebook/react
|
||||
buck build ReactAndroid/src/main/java/com/facebook/react/shell
|
||||
|
||||
# Wait for AVD to finish booting before running tests
|
||||
- run:
|
||||
name: Wait for Android Virtual Device
|
||||
command: source scripts/circle-ci-android-setup.sh && waitForAVD
|
||||
|
||||
- run: buck fetch ReactAndroid/src/test/java/com/facebook/react/modules
|
||||
- run: buck fetch ReactAndroid/src/main/java/com/facebook/react
|
||||
- run: buck fetch ReactAndroid/src/main/java/com/facebook/react/shell
|
||||
- run: buck fetch ReactAndroid/src/test/...
|
||||
- run: buck fetch ReactAndroid/src/androidTest/...
|
||||
- run: ./gradlew :ReactAndroid:downloadBoost :ReactAndroid:downloadDoubleConversion :ReactAndroid:downloadFolly :ReactAndroid:downloadGlog :ReactAndroid:downloadJSCHeaders
|
||||
|
||||
- run: *build-android-app
|
||||
- run: *compile-native-libs
|
||||
|
||||
# The JavaScript Bundle is built as part of the build-js-bundle workflow,
|
||||
# and is required for instrumentation tests.
|
||||
- attach_workspace:
|
||||
at: ReactAndroid/src/androidTest/assets/
|
||||
- run:
|
||||
name: Check for JavaScript Bundle
|
||||
command: |
|
||||
if [[ ! -e ReactAndroid/src/androidTest/assets/AndroidTestBundle.js ]]; then
|
||||
echo "JavaScript bundle missing, verify build-js-bundle step"; exit 1;
|
||||
else
|
||||
echo "JavaScript bundle found.";
|
||||
fi
|
||||
|
||||
- run: *check-js-bundle
|
||||
|
||||
# Wait for AVD to finish booting before running tests
|
||||
- run: *wait-for-avd
|
||||
|
||||
# Tests
|
||||
- run:
|
||||
name: Compile Native Libs for Unit and Integration Tests
|
||||
command: ./gradlew :ReactAndroid:packageReactNdkLibsForBuck -Pjobs=$BUILD_THREADS -Pcom.android.build.threadPoolSize=1
|
||||
no_output_timeout: 6m
|
||||
- run:
|
||||
name: Unit Tests
|
||||
command: buck test ReactAndroid/src/test/... --config build.threads=$BUILD_THREADS
|
||||
|
||||
# Integration Tests
|
||||
- run:
|
||||
name: Build and Install Test APK
|
||||
command: source scripts/circle-ci-android-setup.sh && NO_BUCKD=1 retry3 buck install ReactAndroid/src/androidTest/buck-runner:instrumentation-tests --config build.threads=$BUILD_THREADS
|
||||
- run: *run-android-unit-tests
|
||||
- run: *run-android-integration-tests
|
||||
|
||||
# post (always runs)
|
||||
- run:
|
||||
name: Collect Test Results
|
||||
command: |
|
||||
mkdir -p ~/junit/
|
||||
find . -type f -regex ".*/build/test-results/debug/.*xml" -exec cp {} ~/junit/ \;
|
||||
find . -type f -regex ".*/outputs/androidTest-results/connected/.*xml" -exec cp {} ~/junit/ \;
|
||||
when: always
|
||||
- run: *collect-android-test-results
|
||||
- store_test_results:
|
||||
path: ~/junit
|
||||
- store_artifacts:
|
||||
@@ -449,7 +454,8 @@ jobs:
|
||||
else
|
||||
echo "Skipping code analysis."
|
||||
fi
|
||||
|
||||
when: always
|
||||
|
||||
# Workflows enables us to run multiple jobs in parallel
|
||||
workflows:
|
||||
version: 2
|
||||
@@ -457,7 +463,11 @@ workflows:
|
||||
build:
|
||||
jobs:
|
||||
|
||||
# Test Javascript on Node 8 and 6
|
||||
# Run lint and flow checks
|
||||
- run-js-checks:
|
||||
filters: *filter-ignore-gh-pages
|
||||
|
||||
# Test JavaScript on Node 8 and 6
|
||||
- test-js-node-8:
|
||||
filters: *filter-ignore-gh-pages
|
||||
- test-js-node-6:
|
||||
|
||||
@@ -9,13 +9,15 @@
|
||||
|
||||
"env": {
|
||||
"es6": true,
|
||||
"jasmine": true,
|
||||
"jest": true,
|
||||
},
|
||||
|
||||
"plugins": [
|
||||
"eslint-comments",
|
||||
"flowtype",
|
||||
"prettier",
|
||||
"react"
|
||||
"react",
|
||||
"jest"
|
||||
],
|
||||
|
||||
// Map from global var to bool specifying if it can be redefined
|
||||
@@ -57,11 +59,6 @@
|
||||
},
|
||||
|
||||
"rules": {
|
||||
// Flow Plugin
|
||||
// The following rules are made available via `eslint-plugin-flowtype`
|
||||
"flowtype/define-flow-type": 1,
|
||||
"flowtype/use-flow-type": 1,
|
||||
|
||||
// General
|
||||
|
||||
// This must be disallowed in this repo because the minimum supported
|
||||
@@ -81,7 +78,7 @@
|
||||
"no-constant-condition": 0, // disallow use of constant expressions in conditions
|
||||
"no-control-regex": 1, // disallow control characters in regular expressions
|
||||
"no-debugger": 1, // disallow use of debugger
|
||||
"no-dupe-keys": 1, // disallow duplicate keys when creating object literals
|
||||
"no-dupe-keys": 2, // disallow duplicate keys when creating object literals
|
||||
"no-empty": 0, // disallow empty statements
|
||||
"no-ex-assign": 1, // disallow assigning to the exception in a catch block
|
||||
"no-extra-boolean-cast": 1, // disallow double-negation boolean casts in a boolean context
|
||||
@@ -95,7 +92,7 @@
|
||||
"no-regex-spaces": 1, // disallow multiple spaces in a regular expression literal
|
||||
"no-reserved-keys": 0, // disallow reserved words being used as object literal keys (off by default)
|
||||
"no-sparse-arrays": 1, // disallow sparse arrays
|
||||
"no-unreachable": 1, // disallow unreachable statements after a return, throw, continue, or break statement
|
||||
"no-unreachable": 2, // disallow unreachable statements after a return, throw, continue, or break statement
|
||||
"use-isnan": 1, // disallow comparisons with the value NaN
|
||||
"valid-jsdoc": 0, // Ensure JSDoc comments are valid (off by default)
|
||||
"valid-typeof": 1, // Ensure that the results of typeof are compared against a valid string
|
||||
@@ -116,7 +113,7 @@
|
||||
"no-div-regex": 1, // disallow division operators explicitly at beginning of regular expression (off by default)
|
||||
"no-else-return": 0, // disallow else after a return in an if (off by default)
|
||||
"no-eq-null": 0, // disallow comparisons to null without a type-checking operator (off by default)
|
||||
"no-eval": 1, // disallow use of eval()
|
||||
"no-eval": 2, // disallow use of eval()
|
||||
"no-extend-native": 1, // disallow adding to native types
|
||||
"no-extra-bind": 1, // disallow unnecessary function binding
|
||||
"no-fallthrough": 1, // disallow fallthrough of case statements
|
||||
@@ -129,7 +126,7 @@
|
||||
"no-multi-str": 0, // disallow use of multiline strings
|
||||
"no-native-reassign": 0, // disallow reassignments of native objects
|
||||
"no-new": 1, // disallow use of new operator when not part of the assignment or comparison
|
||||
"no-new-func": 1, // disallow use of new operator for Function object
|
||||
"no-new-func": 2, // disallow use of new operator for Function object
|
||||
"no-new-wrappers": 1, // disallows creating new instances of String,Number, and Boolean
|
||||
"no-octal": 1, // disallow use of octal literals
|
||||
"no-octal-escape": 1, // disallow use of octal escape sequences in string literals, such as var foo = "Copyright \251";
|
||||
@@ -174,6 +171,18 @@
|
||||
"no-restricted-modules": 1, // restrict usage of specified node modules (off by default)
|
||||
"no-sync": 0, // disallow use of synchronous methods (off by default)
|
||||
|
||||
// ESLint Comments Plugin
|
||||
// The following rules are made available via `eslint-plugin-eslint-comments`
|
||||
'eslint-comments/no-aggregating-enable': 1, // disallows eslint-enable comments for multiple eslint-disable comments
|
||||
'eslint-comments/no-unlimited-disable': 1, // disallows eslint-disable comments without rule names
|
||||
'eslint-comments/no-unused-disable': 1, // disallow disables that don't cover any errors
|
||||
'eslint-comments/no-unused-enable': 1, // // disallow enables that don't enable anything or enable rules that weren't disabled
|
||||
|
||||
// Flow Plugin
|
||||
// The following rules are made available via `eslint-plugin-flowtype`
|
||||
"flowtype/define-flow-type": 1,
|
||||
"flowtype/use-flow-type": 1,
|
||||
|
||||
// Prettier Plugin
|
||||
// https://github.com/prettier/eslint-plugin-prettier
|
||||
"prettier/prettier": [2, "fb", "@format"],
|
||||
@@ -183,12 +192,12 @@
|
||||
|
||||
"key-spacing": 0,
|
||||
"keyword-spacing": 1, // enforce spacing before and after keywords
|
||||
"jsx-quotes": [1, "prefer-double"],
|
||||
"jsx-quotes": [1, "prefer-double"], // enforces the usage of double quotes for all JSX attribute values which doesn’t contain a double quote
|
||||
"comma-spacing": 0,
|
||||
"no-multi-spaces": 0,
|
||||
"brace-style": 0, // enforce one true brace style (off by default)
|
||||
"camelcase": 0, // require camel case names
|
||||
"consistent-this": [1, "self"], // enforces consistent naming when capturing the current execution context (off by default)
|
||||
"consistent-this": 1, // enforces consistent naming when capturing the current execution context (off by default)
|
||||
"eol-last": 1, // enforce newline at the end of file, with no multiple empty lines
|
||||
"func-names": 0, // require function expressions to have a name (off by default)
|
||||
"func-style": 0, // enforces use of function declarations or expressions (off by default)
|
||||
@@ -196,6 +205,7 @@
|
||||
"new-parens": 1, // disallow the omission of parentheses when invoking a constructor with no arguments
|
||||
"no-nested-ternary": 0, // disallow nested ternary expressions (off by default)
|
||||
"no-array-constructor": 1, // disallow use of the Array constructor
|
||||
'no-empty-character-class': 1, // disallow the use of empty character classes in regular expressions
|
||||
"no-lonely-if": 0, // disallow if as the only statement in an else block (off by default)
|
||||
"no-new-object": 1, // disallow use of the Object constructor
|
||||
"no-spaced-func": 1, // disallow space between function identifier and application
|
||||
@@ -244,6 +254,13 @@
|
||||
"react/prop-types": 0,
|
||||
"react/react-in-jsx-scope": 1,
|
||||
"react/self-closing-comp": 1,
|
||||
"react/wrap-multilines": 0
|
||||
"react/wrap-multilines": 0,
|
||||
|
||||
// Jest Plugin
|
||||
// The following rules are made available via `eslint-plugin-jest`.
|
||||
"jest/no-disabled-tests": 1,
|
||||
"jest/no-focused-tests": 1,
|
||||
"jest/no-identical-title": 1,
|
||||
"jest/valid-expect": 1,
|
||||
}
|
||||
}
|
||||
|
||||
+1
-3
@@ -51,7 +51,5 @@ suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(<VERSION>\\)? *\\(site=[a-z,_]*
|
||||
suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy
|
||||
suppress_comment=\\(.\\|\n\\)*\\$FlowExpectedError
|
||||
|
||||
unsafe.enable_getters_and_setters=true
|
||||
|
||||
[version]
|
||||
^0.61.0
|
||||
^0.63.0
|
||||
|
||||
+1
-2
@@ -1,5 +1,3 @@
|
||||
docs/* @hramos
|
||||
blog/* @hramos
|
||||
Libraries/Animated/* @janicduplessis
|
||||
Libraries/NativeAnimation/* @janicduplessis
|
||||
Libraries/Image/* @shergin
|
||||
@@ -9,6 +7,7 @@ React/Views/* @shergin
|
||||
React/Modules/* @shergin
|
||||
React/CxxBridge/* @mhorowitz
|
||||
ReactAndroid/src/main/java/com/facebook/react/animated/* @janicduplessis
|
||||
**/*.md @hramos
|
||||
package.json @hramos
|
||||
local-cli/core/* @grabbou @kureev
|
||||
local-cli/link/* @grabbou @kureev
|
||||
|
||||
+10
-10
@@ -11,10 +11,10 @@ Facebook has adopted a Code of Conduct that we expect project participants to ad
|
||||
|
||||
There are many ways to contribute to React Native, and many of them do not involve writing any code. Here's a few ideas to get started:
|
||||
|
||||
* Simply start using React Native. Go through the [Getting Started](http://facebook.github.io/react-native/docs/getting-started.html) guide. Does everything work as expected? If not, we're always looking for improvements. Let us know by [opening an issue](http://facebook.github.io/react-native/docs/contributing.html#reporting-new-issues).
|
||||
* Look through the [open issues](https://github.com/facebook/react-native/issues). Provide workarounds, ask for clarification, or suggest labels. Help [triage issues](http://facebook.github.io/react-native/docs/contributing.html#triaging-issues-and-pull-requests).
|
||||
* If you find an issue you would like to fix, [open a pull request](http://facebook.github.io/react-native/docs/contributing.html#your-first-pull-request). Issues tagged as [_Good first issue_](https://github.com/facebook/react-native/labels/Good%20first%20issue) are a good place to get started.
|
||||
* Read through the [React Native docs](http://facebook.github.io/react-native/docs). If you find anything that is confusing or can be improved, you can make edits by clicking "Improve this page" at the bottom of most docs.
|
||||
* Simply start using React Native. Go through the [Getting Started](https://facebook.github.io/react-native/docs/getting-started.html) guide. Does everything work as expected? If not, we're always looking for improvements. Let us know by [opening an issue](https://facebook.github.io/react-native/docs/contributing.html#reporting-new-issues).
|
||||
* Look through the [open issues](https://github.com/facebook/react-native/issues). Provide workarounds, ask for clarification, or suggest labels. Help [triage issues](https://facebook.github.io/react-native/docs/contributing.html#triaging-issues-and-pull-requests).
|
||||
* If you find an issue you would like to fix, [open a pull request](https://facebook.github.io/react-native/docs/contributing.html#your-first-pull-request). Issues tagged as [_Good first issue_](https://github.com/facebook/react-native/labels/Good%20first%20issue) are a good place to get started.
|
||||
* Read through the [React Native docs](https://facebook.github.io/react-native/docs/getting-started.html). If you find anything that is confusing or can be improved, you can make edits by clicking "Improve this page" at the bottom of most docs.
|
||||
* Browse [Stack Overflow](https://stackoverflow.com/questions/tagged/react-native) and answer questions. This will help you get familiarized with common pitfalls or misunderstandings, which can be useful when contributing updates to the documentation.
|
||||
* Take a look at the [features requested](https://react-native.canny.io/feature-requests) by others in the community and consider opening a pull request if you see something you want to work on.
|
||||
|
||||
@@ -43,13 +43,13 @@ When a change made on GitHub is approved, it will first be imported into Faceboo
|
||||
|
||||
We will do our best to keep `master` in good shape, with tests passing at all times. But in order to move fast, we will make API changes that your application might not be compatible with. We will do our best to [communicate these changes](https://github.com/facebook/react-native/releases) and version appropriately so you can lock into a specific version if need be.
|
||||
|
||||
To see what changes are coming and provide better feedback to React Native contributors, use the [latest release candidate](http://facebook.github.io/react-native/versions.html) when possible. By the time a release candidate is released, the changes it contains will have been shipped in production Facebook apps for over two weeks.
|
||||
To see what changes are coming and provide better feedback to React Native contributors, use the [latest release candidate](https://facebook.github.io/react-native/versions.html) when possible. By the time a release candidate is released, the changes it contains will have been shipped in production Facebook apps for over two weeks.
|
||||
|
||||
## Bugs
|
||||
|
||||
We use [GitHub Issues](https://github.com/facebook/react-native/issues) for our public bugs. If you would like to report a problem, take a look around and see if someone already opened an issue about it. If you a are certain this is a new, unreported bug, you can submit a [bug report](http://facebook.github.io/react-native/docs/contributing.html#reporting-new-issues).
|
||||
We use [GitHub Issues](https://github.com/facebook/react-native/issues) for our public bugs. If you would like to report a problem, take a look around and see if someone already opened an issue about it. If you a are certain this is a new, unreported bug, you can submit a [bug report](https://facebook.github.io/react-native/docs/contributing.html#reporting-new-issues).
|
||||
|
||||
If you have questions about using React Native, the [Community page](http://facebook.github.io/react-native/support.html) list various resources that should help you get started.
|
||||
If you have questions about using React Native, the [Community page](https://facebook.github.io/react-native/help.html) list various resources that should help you get started.
|
||||
|
||||
We also have a [place where you can request features or enhancements](https://react-native.canny.io/feature-requests). If you see anything you'd like to be implemented, vote it up and explain your use case.
|
||||
|
||||
@@ -60,9 +60,9 @@ When [opening a new issue](https://github.com/facebook/react-native/issues/new),
|
||||
* **One issue, one bug:** Please report a single bug per issue.
|
||||
* **Provide a Snack:** The best way to get attention on your issue is to provide a reduced test case. You can use [Snack](https://snack.expo.io/) to demonstrate the issue.
|
||||
* **Provide reproduction steps:** List all the steps necessary to reproduce the issue. Provide a Snack or upload a sample project to GitHub. The person reading your bug report should be able to follow these steps to reproduce your issue with minimal effort.
|
||||
* **Try out the latest version:** Verify that the issue can be reproduced locally by updating your project to use [React Native from `master`](http://facebook.github.io/react-native/versions.html). The bug may have already been fixed!
|
||||
* **Try out the latest version:** Verify that the issue can be reproduced locally by updating your project to use [React Native from `master`](https://facebook.github.io/react-native/versions.html). The bug may have already been fixed!
|
||||
|
||||
We're not able to provide support through GitHub Issues. If you're looking for help with your code, consider asking on [Stack Overflow](http://stackoverflow.com/questions/tagged/react-native) or reaching out to the community through [other channels](https://facebook.github.io/react-native/support.html).
|
||||
We're not able to provide support through GitHub Issues. If you're looking for help with your code, consider asking on [Stack Overflow](https://stackoverflow.com/questions/tagged/react-native) or reaching out to the community through [other channels](https://facebook.github.io/react-native/support.html).
|
||||
|
||||
### Security bugs
|
||||
|
||||
@@ -117,7 +117,7 @@ See [What is a Test Plan?](https://medium.com/@martinkonicek/what-is-a-test-plan
|
||||
|
||||
Make sure all **tests pass** on [Circle CI][circle]. PRs that break tests are unlikely to be merged. Learn more about [testing your changes here](https://facebook.github.io/react-native/docs/testing.html).
|
||||
|
||||
[circle]: http://circleci.com/gh/facebook/react-native
|
||||
[circle]: https://circleci.com/gh/facebook/react-native
|
||||
|
||||
#### Breaking changes
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
FROM containership/android-base:latest
|
||||
FROM hramos/android-base:latest
|
||||
|
||||
# set default environment variables
|
||||
ENV GRADLE_OPTS="-Dorg.gradle.jvmargs=\"-Xmx512m -XX:+HeapDumpOnOutOfMemoryError\""
|
||||
ENV GRADLE_OPTS="-Dorg.gradle.daemon=false -Dorg.gradle.jvmargs=\"-Xmx512m -XX:+HeapDumpOnOutOfMemoryError\""
|
||||
ENV JAVA_TOOL_OPTIONS="-Dfile.encoding=UTF8"
|
||||
|
||||
# add ReactAndroid directory
|
||||
@@ -46,9 +46,5 @@ RUN cd $(npm root -g)/npm && npm install fs-extra && sed -i -e s/graceful-fs/fs-
|
||||
|
||||
# build node dependencies
|
||||
RUN npm install
|
||||
RUN npm install github@0.2.4
|
||||
|
||||
WORKDIR /app/website
|
||||
RUN npm install
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
FROM library/ubuntu:16.04
|
||||
|
||||
# set default build arguments
|
||||
ARG ANDROID_VERSION=25.2.3
|
||||
ARG BUCK_VERSION=f3452a6a7ab15a60e94c962e686293acbe677473
|
||||
ARG ANDROID_TOOLS_VERSION=25.2.5
|
||||
ARG BUCK_VERSION=v2017.11.16.01
|
||||
ARG NDK_VERSION=10e
|
||||
ARG NODE_VERSION=6.2.0
|
||||
ARG WATCHMAN_VERSION=4.7.0
|
||||
@@ -12,7 +12,7 @@ ENV ADB_INSTALL_TIMEOUT=10
|
||||
ENV PATH=${PATH}:/opt/buck/bin/
|
||||
ENV ANDROID_HOME=/opt/android
|
||||
ENV ANDROID_SDK_HOME=${ANDROID_HOME}
|
||||
ENV PATH=${PATH}:${ANDROID_HOME}/tools:${ANDROID_HOME}/platform-tools
|
||||
ENV PATH=${PATH}:${ANDROID_HOME}/tools:${ANDROID_HOME}/tools/bin:${ANDROID_HOME}/platform-tools
|
||||
ENV ANDROID_NDK=/opt/ndk/android-ndk-r$NDK_VERSION
|
||||
ENV PATH=${PATH}:${ANDROID_NDK}
|
||||
|
||||
@@ -28,9 +28,8 @@ RUN npm install n -g
|
||||
RUN n $NODE_VERSION
|
||||
|
||||
# download buck
|
||||
RUN git clone https://github.com/facebook/buck.git /opt/buck
|
||||
RUN git clone https://github.com/facebook/buck.git /opt/buck --branch $BUCK_VERSION --depth=1
|
||||
WORKDIR /opt/buck
|
||||
RUN git checkout $BUCK_VERSION
|
||||
|
||||
# build buck
|
||||
RUN ant
|
||||
@@ -46,10 +45,11 @@ RUN ./configure
|
||||
RUN make
|
||||
RUN make install
|
||||
|
||||
# Full reference at https://dl.google.com/android/repository/repository2-1.xml
|
||||
# download and unpack android
|
||||
RUN mkdir /opt/android
|
||||
WORKDIR /opt/android
|
||||
RUN curl --silent https://dl.google.com/android/repository/tools_r$ANDROID_VERSION-linux.zip > android.zip
|
||||
RUN curl --silent https://dl.google.com/android/repository/tools_r$ANDROID_TOOLS_VERSION-linux.zip > android.zip
|
||||
RUN unzip android.zip
|
||||
RUN rm android.zip
|
||||
|
||||
@@ -63,39 +63,15 @@ RUN unzip ndk.zip
|
||||
RUN rm ndk.zip
|
||||
|
||||
# Add android SDK tools
|
||||
|
||||
# Android SDK Platform-tools, revision 25.0.4
|
||||
RUN echo "y" | android update sdk -u -a -t $(android list sdk -a | grep "Android SDK Platform-tools, revision 25.0.4" | awk '{ print $1 }' | sed 's/.$//')
|
||||
|
||||
# Android SDK Build-tools, revision 23.0.1
|
||||
RUN echo "y" | android update sdk -u -a -t $(android list sdk -a | grep "Android SDK Build-tools, revision 23.0.1" | awk '{ print $1 }' | sed 's/.$//')
|
||||
|
||||
# SDK Platform Android 6.0, API 23, revision 3
|
||||
RUN echo "y" | android update sdk -u -a -t $(android list sdk -a | grep "SDK Platform Android 6.0, API 23" | awk '{ print $1 }' | sed 's/.$//')
|
||||
|
||||
# SDK Platform Android 4.4.2, API 19, revision 4
|
||||
RUN echo "y" | android update sdk -u -a -t $(android list sdk -a | grep "SDK Platform Android 4.4.2, API 19, revision 4" | awk '{ print $1 }' | sed 's/.$//')
|
||||
|
||||
# ARM EABI v7a System Image, Android API 19, revision 5
|
||||
RUN echo "y" | android update sdk -u -a -t $(android list sdk -a | grep "ARM EABI v7a System Image, Android API 19, revision 5" | awk '{ print $1 }' | sed 's/.$//')
|
||||
|
||||
# Intel x86 Atom System Image, Android API 19, revision 5
|
||||
RUN echo "y" | android update sdk -u -a -t $(android list sdk -a | grep "Intel x86 Atom System Image, Android API 19, revision 5" | awk '{ print $1 }' | sed 's/.$//')
|
||||
|
||||
# Google APIs, Android API 23, revision 1
|
||||
RUN echo "y" | android update sdk -u -a -t $(android list sdk -a | grep "Google APIs, Android API 23, revision 1" | awk '{ print $1 }' | sed 's/.$//')
|
||||
|
||||
# Android Support Repository, revision 45
|
||||
RUN echo "y" | android update sdk -u -a -t $(android list sdk -a | grep "Android Support Repository" | awk '{ print $1 }' | sed 's/.$//')
|
||||
RUN echo "y" | sdkmanager "system-images;android-19;google_apis;armeabi-v7a"
|
||||
RUN echo "y" | sdkmanager "platforms;android-23"
|
||||
RUN echo "y" | sdkmanager "platforms;android-19"
|
||||
RUN echo "y" | sdkmanager "build-tools;23.0.1"
|
||||
RUN echo "y" | sdkmanager "add-ons;addon-google_apis-google-23"
|
||||
RUN echo "y" | sdkmanager "extras;android;m2repository"
|
||||
|
||||
# Link adb executable
|
||||
RUN ln -s /opt/android/platform-tools/adb /usr/bin/adb
|
||||
|
||||
# Install google-chrome
|
||||
RUN curl -fsSL https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add - \
|
||||
&& echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" > /etc/apt/sources.list.d/google-chrome.list \
|
||||
&& apt-get update \
|
||||
&& apt-get install -y google-chrome-stable
|
||||
|
||||
# clean up unnecessary directories
|
||||
RUN rm -rf /opt/android/system-images/android-19/default/x86
|
||||
|
||||
@@ -20,7 +20,6 @@
|
||||
* --package - com.facebook.react.tests
|
||||
* --retries [num] - how many times to retry possible flaky commands: npm install and running tests, default 1
|
||||
*/
|
||||
/*eslint-disable no-undef */
|
||||
|
||||
const argv = require('yargs').argv;
|
||||
const async = require('async');
|
||||
|
||||
@@ -15,6 +15,15 @@
|
||||
|
||||
@implementation ARTSurfaceView
|
||||
|
||||
- (instancetype)initWithFrame:(CGRect)frame
|
||||
{
|
||||
if (self = [super initWithFrame:frame]) {
|
||||
self.opaque = NO;
|
||||
}
|
||||
|
||||
return self;
|
||||
}
|
||||
|
||||
- (void)insertReactSubview:(UIView *)subview atIndex:(NSInteger)atIndex
|
||||
{
|
||||
[super insertReactSubview:subview atIndex:atIndex];
|
||||
@@ -46,9 +55,4 @@
|
||||
}
|
||||
}
|
||||
|
||||
- (void)reactSetInheritedBackgroundColor:(UIColor *)inheritedBackgroundColor
|
||||
{
|
||||
self.backgroundColor = inheritedBackgroundColor;
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
@@ -80,7 +80,7 @@ describe('Native Animated', () => {
|
||||
|
||||
anim.setValue(0.5);
|
||||
|
||||
expect(nativeAnimatedModule.setAnimatedNodeValue).toBeCalledWith(jasmine.any(Number), 0.5);
|
||||
expect(nativeAnimatedModule.setAnimatedNodeValue).toBeCalledWith(expect.any(Number), 0.5);
|
||||
expect(c.refs.node.setNativeProps).not.toHaveBeenCalled();
|
||||
});
|
||||
|
||||
@@ -95,12 +95,12 @@ describe('Native Animated', () => {
|
||||
});
|
||||
|
||||
expect(nativeAnimatedModule.createAnimatedNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
expect.any(Number),
|
||||
{type: 'value', value: 0, offset: 10},
|
||||
);
|
||||
anim.setOffset(20);
|
||||
expect(nativeAnimatedModule.setAnimatedNodeOffset)
|
||||
.toBeCalledWith(jasmine.any(Number), 20);
|
||||
.toBeCalledWith(expect.any(Number), 20);
|
||||
});
|
||||
|
||||
it('should flatten offset', () => {
|
||||
@@ -113,12 +113,12 @@ describe('Native Animated', () => {
|
||||
});
|
||||
|
||||
expect(nativeAnimatedModule.createAnimatedNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
expect.any(Number),
|
||||
{type: 'value', value: 0, offset: 0},
|
||||
);
|
||||
anim.flattenOffset();
|
||||
expect(nativeAnimatedModule.flattenAnimatedNodeOffset)
|
||||
.toBeCalledWith(jasmine.any(Number));
|
||||
.toBeCalledWith(expect.any(Number));
|
||||
});
|
||||
|
||||
it('should extract offset', () => {
|
||||
@@ -131,12 +131,12 @@ describe('Native Animated', () => {
|
||||
});
|
||||
|
||||
expect(nativeAnimatedModule.createAnimatedNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
expect.any(Number),
|
||||
{type: 'value', value: 0, offset: 0},
|
||||
);
|
||||
anim.extractOffset();
|
||||
expect(nativeAnimatedModule.extractAnimatedNodeOffset)
|
||||
.toBeCalledWith(jasmine.any(Number));
|
||||
.toBeCalledWith(expect.any(Number));
|
||||
});
|
||||
});
|
||||
|
||||
@@ -214,14 +214,14 @@ describe('Native Animated', () => {
|
||||
);
|
||||
const c = createAndMountComponent(Animated.View, {onTouchMove: event});
|
||||
expect(nativeAnimatedModule.addAnimatedEventToView).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
expect.any(Number),
|
||||
'onTouchMove',
|
||||
{nativeEventPath: ['state', 'foo'], animatedValueTag: value.__getNativeTag()},
|
||||
);
|
||||
|
||||
c.componentWillUnmount();
|
||||
expect(nativeAnimatedModule.removeAnimatedEventFromView).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
expect.any(Number),
|
||||
'onTouchMove',
|
||||
value.__getNativeTag(),
|
||||
);
|
||||
@@ -271,10 +271,10 @@ describe('Native Animated', () => {
|
||||
expect(nativeAnimatedModule.connectAnimatedNodes).toHaveBeenCalledTimes(2);
|
||||
|
||||
expect(nativeAnimatedModule.startAnimatingNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
jasmine.any(Number),
|
||||
{type: 'frames', frames: jasmine.any(Array), toValue: jasmine.any(Number), iterations: 1},
|
||||
jasmine.any(Function)
|
||||
expect.any(Number),
|
||||
expect.any(Number),
|
||||
{type: 'frames', frames: expect.any(Array), toValue: expect.any(Number), iterations: 1},
|
||||
expect.any(Function)
|
||||
);
|
||||
|
||||
expect(nativeAnimatedModule.disconnectAnimatedNodes).toHaveBeenCalledTimes(2);
|
||||
@@ -292,11 +292,11 @@ describe('Native Animated', () => {
|
||||
Animated.timing(anim, {toValue: 10, duration: 1000, useNativeDriver: true}).start();
|
||||
|
||||
expect(nativeAnimatedModule.createAnimatedNode)
|
||||
.toBeCalledWith(jasmine.any(Number), {type: 'value', value: 0, offset: 0});
|
||||
.toBeCalledWith(expect.any(Number), {type: 'value', value: 0, offset: 0});
|
||||
expect(nativeAnimatedModule.createAnimatedNode)
|
||||
.toBeCalledWith(jasmine.any(Number), {type: 'style', style: {opacity: jasmine.any(Number)}});
|
||||
.toBeCalledWith(expect.any(Number), {type: 'style', style: {opacity: expect.any(Number)}});
|
||||
expect(nativeAnimatedModule.createAnimatedNode)
|
||||
.toBeCalledWith(jasmine.any(Number), {type: 'props', props: {style: jasmine.any(Number)}});
|
||||
.toBeCalledWith(expect.any(Number), {type: 'props', props: {style: expect.any(Number)}});
|
||||
});
|
||||
|
||||
it('sends a valid graph description for Animated.add nodes', () => {
|
||||
@@ -312,8 +312,8 @@ describe('Native Animated', () => {
|
||||
});
|
||||
|
||||
expect(nativeAnimatedModule.createAnimatedNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
{type: 'addition', input: jasmine.any(Array)},
|
||||
expect.any(Number),
|
||||
{type: 'addition', input: expect.any(Array)},
|
||||
);
|
||||
const additionCalls = nativeAnimatedModule.createAnimatedNode.mock.calls.filter(
|
||||
(call) => call[1].type === 'addition'
|
||||
@@ -344,8 +344,8 @@ describe('Native Animated', () => {
|
||||
});
|
||||
|
||||
expect(nativeAnimatedModule.createAnimatedNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
{type: 'multiplication', input: jasmine.any(Array)},
|
||||
expect.any(Number),
|
||||
{type: 'multiplication', input: expect.any(Array)},
|
||||
);
|
||||
const multiplicationCalls = nativeAnimatedModule.createAnimatedNode.mock.calls.filter(
|
||||
(call) => call[1].type === 'multiplication'
|
||||
@@ -376,7 +376,7 @@ describe('Native Animated', () => {
|
||||
});
|
||||
|
||||
expect(nativeAnimatedModule.createAnimatedNode)
|
||||
.toBeCalledWith(jasmine.any(Number), {type: 'division', input: jasmine.any(Array)});
|
||||
.toBeCalledWith(expect.any(Number), {type: 'division', input: expect.any(Array)});
|
||||
const divisionCalls = nativeAnimatedModule.createAnimatedNode.mock.calls.filter(
|
||||
(call) => call[1].type === 'division'
|
||||
);
|
||||
@@ -404,8 +404,8 @@ describe('Native Animated', () => {
|
||||
});
|
||||
|
||||
expect(nativeAnimatedModule.createAnimatedNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
{type: 'modulus', modulus: 4, input: jasmine.any(Number)},
|
||||
expect.any(Number),
|
||||
{type: 'modulus', modulus: 4, input: expect.any(Number)},
|
||||
);
|
||||
const moduloCalls = nativeAnimatedModule.createAnimatedNode.mock.calls.filter(
|
||||
(call) => call[1].type === 'modulus'
|
||||
@@ -435,11 +435,11 @@ describe('Native Animated', () => {
|
||||
});
|
||||
|
||||
expect(nativeAnimatedModule.createAnimatedNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
expect.any(Number),
|
||||
{type: 'value', value: 10, offset: 0}
|
||||
);
|
||||
expect(nativeAnimatedModule.createAnimatedNode)
|
||||
.toBeCalledWith(jasmine.any(Number), {
|
||||
.toBeCalledWith(expect.any(Number), {
|
||||
type: 'interpolation',
|
||||
inputRange: [10, 20],
|
||||
outputRange: [0, 1],
|
||||
@@ -466,11 +466,11 @@ describe('Native Animated', () => {
|
||||
});
|
||||
|
||||
expect(nativeAnimatedModule.createAnimatedNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
expect.any(Number),
|
||||
{
|
||||
type: 'transform',
|
||||
transforms: [{
|
||||
nodeTag: jasmine.any(Number),
|
||||
nodeTag: expect.any(Number),
|
||||
property: 'translateX',
|
||||
type: 'animated',
|
||||
}, {
|
||||
@@ -493,8 +493,8 @@ describe('Native Animated', () => {
|
||||
});
|
||||
|
||||
expect(nativeAnimatedModule.createAnimatedNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
{type: 'diffclamp', input: jasmine.any(Number), max: 20, min: 0},
|
||||
expect.any(Number),
|
||||
{type: 'diffclamp', input: expect.any(Number), max: 20, min: 0},
|
||||
);
|
||||
const diffClampCalls = nativeAnimatedModule.createAnimatedNode.mock.calls.filter(
|
||||
(call) => call[1].type === 'diffclamp'
|
||||
@@ -570,9 +570,9 @@ describe('Native Animated', () => {
|
||||
});
|
||||
|
||||
expect(nativeAnimatedModule.createAnimatedNode)
|
||||
.toBeCalledWith(jasmine.any(Number), { type: 'style', style: { opacity: jasmine.any(Number) }});
|
||||
.toBeCalledWith(expect.any(Number), { type: 'style', style: { opacity: expect.any(Number) }});
|
||||
expect(nativeAnimatedModule.createAnimatedNode)
|
||||
.toBeCalledWith(jasmine.any(Number), { type: 'props', props: { style: jasmine.any(Number) }});
|
||||
.toBeCalledWith(expect.any(Number), { type: 'props', props: { style: expect.any(Number) }});
|
||||
});
|
||||
});
|
||||
|
||||
@@ -582,10 +582,10 @@ describe('Native Animated', () => {
|
||||
Animated.timing(anim, {toValue: 10, duration: 1000, useNativeDriver: true}).start();
|
||||
|
||||
expect(nativeAnimatedModule.startAnimatingNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
jasmine.any(Number),
|
||||
{type: 'frames', frames: jasmine.any(Array), toValue: jasmine.any(Number), iterations: 1},
|
||||
jasmine.any(Function)
|
||||
expect.any(Number),
|
||||
expect.any(Number),
|
||||
{type: 'frames', frames: expect.any(Array), toValue: expect.any(Number), iterations: 1},
|
||||
expect.any(Function)
|
||||
);
|
||||
});
|
||||
|
||||
@@ -593,8 +593,8 @@ describe('Native Animated', () => {
|
||||
const anim = new Animated.Value(0);
|
||||
Animated.spring(anim, {toValue: 10, friction: 5, tension: 164, useNativeDriver: true}).start();
|
||||
expect(nativeAnimatedModule.startAnimatingNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
jasmine.any(Number),
|
||||
expect.any(Number),
|
||||
expect.any(Number),
|
||||
{
|
||||
type: 'spring',
|
||||
stiffness: 679.08,
|
||||
@@ -607,7 +607,7 @@ describe('Native Animated', () => {
|
||||
toValue: 10,
|
||||
iterations: 1,
|
||||
},
|
||||
jasmine.any(Function)
|
||||
expect.any(Function)
|
||||
);
|
||||
|
||||
Animated.spring(anim, {
|
||||
@@ -618,8 +618,8 @@ describe('Native Animated', () => {
|
||||
useNativeDriver: true
|
||||
}).start();
|
||||
expect(nativeAnimatedModule.startAnimatingNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
jasmine.any(Number),
|
||||
expect.any(Number),
|
||||
expect.any(Number),
|
||||
{
|
||||
type: 'spring',
|
||||
stiffness: 1000,
|
||||
@@ -632,13 +632,13 @@ describe('Native Animated', () => {
|
||||
toValue: 10,
|
||||
iterations: 1,
|
||||
},
|
||||
jasmine.any(Function)
|
||||
expect.any(Function)
|
||||
);
|
||||
|
||||
Animated.spring(anim, {toValue: 10, bounciness: 8, speed: 10, useNativeDriver: true}).start();
|
||||
expect(nativeAnimatedModule.startAnimatingNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
jasmine.any(Number),
|
||||
expect.any(Number),
|
||||
expect.any(Number),
|
||||
{
|
||||
type: 'spring',
|
||||
damping: 23.05223140901191,
|
||||
@@ -651,7 +651,7 @@ describe('Native Animated', () => {
|
||||
toValue: 10,
|
||||
iterations: 1,
|
||||
},
|
||||
jasmine.any(Function)
|
||||
expect.any(Function)
|
||||
);
|
||||
});
|
||||
|
||||
@@ -660,10 +660,10 @@ describe('Native Animated', () => {
|
||||
Animated.decay(anim, {velocity: 10, deceleration: 0.1, useNativeDriver: true}).start();
|
||||
|
||||
expect(nativeAnimatedModule.startAnimatingNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
jasmine.any(Number),
|
||||
expect.any(Number),
|
||||
expect.any(Number),
|
||||
{type: 'decay', deceleration: 0.1, velocity: 10, iterations: 1},
|
||||
jasmine.any(Function)
|
||||
expect.any(Function)
|
||||
);
|
||||
});
|
||||
|
||||
@@ -675,10 +675,10 @@ describe('Native Animated', () => {
|
||||
).start();
|
||||
|
||||
expect(nativeAnimatedModule.startAnimatingNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
jasmine.any(Number),
|
||||
expect.any(Number),
|
||||
expect.any(Number),
|
||||
{type: 'decay', deceleration: 0.1, velocity: 10, iterations: 10},
|
||||
jasmine.any(Function)
|
||||
expect.any(Function)
|
||||
);
|
||||
});
|
||||
|
||||
@@ -688,10 +688,10 @@ describe('Native Animated', () => {
|
||||
|
||||
animation.start();
|
||||
expect(nativeAnimatedModule.startAnimatingNode).toBeCalledWith(
|
||||
jasmine.any(Number),
|
||||
jasmine.any(Number),
|
||||
{type: 'frames', frames: jasmine.any(Array), toValue: jasmine.any(Number), iterations: 1},
|
||||
jasmine.any(Function)
|
||||
expect.any(Number),
|
||||
expect.any(Number),
|
||||
{type: 'frames', frames: expect.any(Array), toValue: expect.any(Number), iterations: 1},
|
||||
expect.any(Function)
|
||||
);
|
||||
const animationId = nativeAnimatedModule.startAnimatingNode.mock.calls[0][0];
|
||||
|
||||
|
||||
@@ -5,100 +5,132 @@
|
||||
* @copyright 2014-2015 Gaetan Renaudeau. MIT License.
|
||||
* @noflow
|
||||
* @emails oncall+react_native
|
||||
* @format
|
||||
*/
|
||||
|
||||
/* eslint-disable */
|
||||
|
||||
'use strict';
|
||||
|
||||
var bezier = require('bezier');
|
||||
|
||||
var identity = function (x) { return x; };
|
||||
var identity = function(x) {
|
||||
return x;
|
||||
};
|
||||
|
||||
function assertClose (a, b, precision = 3) {
|
||||
function assertClose(a, b, precision = 3) {
|
||||
expect(a).toBeCloseTo(b, precision);
|
||||
}
|
||||
|
||||
function makeAssertCloseWithPrecision (precision) {
|
||||
return function (a, b) {
|
||||
function makeAssertCloseWithPrecision(precision) {
|
||||
return function(a, b) {
|
||||
assertClose(a, b, precision);
|
||||
};
|
||||
}
|
||||
|
||||
function allEquals (be1, be2, samples, assertion) {
|
||||
if (!assertion) assertion = assertClose;
|
||||
for (var i=0; i<=samples; ++i) {
|
||||
function allEquals(be1, be2, samples, assertion) {
|
||||
if (!assertion) {
|
||||
assertion = assertClose;
|
||||
}
|
||||
for (var i = 0; i <= samples; ++i) {
|
||||
var x = i / samples;
|
||||
assertion(be1(x), be2(x));
|
||||
}
|
||||
}
|
||||
|
||||
function repeat (n) {
|
||||
return function (f) {
|
||||
for (var i=0; i<n; ++i) f(i);
|
||||
function repeat(n) {
|
||||
return function(f) {
|
||||
for (var i = 0; i < n; ++i) {
|
||||
f(i);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
describe('bezier', function(){
|
||||
it('should be a function', function(){
|
||||
describe('bezier', function() {
|
||||
it('should be a function', function() {
|
||||
expect(typeof bezier === 'function').toBe(true);
|
||||
});
|
||||
it('should creates an object', function(){
|
||||
it('should creates an object', function() {
|
||||
expect(typeof bezier(0, 0, 1, 1) === 'function').toBe(true);
|
||||
});
|
||||
it('should fail with wrong arguments', function () {
|
||||
expect(function () { bezier(0.5, 0.5, -5, 0.5); }).toThrow();
|
||||
expect(function () { bezier(0.5, 0.5, 5, 0.5); }).toThrow();
|
||||
expect(function () { bezier(-2, 0.5, 0.5, 0.5); }).toThrow();
|
||||
expect(function () { bezier(2, 0.5, 0.5, 0.5); }).toThrow();
|
||||
it('should fail with wrong arguments', function() {
|
||||
expect(function() {
|
||||
bezier(0.5, 0.5, -5, 0.5);
|
||||
}).toThrow();
|
||||
expect(function() {
|
||||
bezier(0.5, 0.5, 5, 0.5);
|
||||
}).toThrow();
|
||||
expect(function() {
|
||||
bezier(-2, 0.5, 0.5, 0.5);
|
||||
}).toThrow();
|
||||
expect(function() {
|
||||
bezier(2, 0.5, 0.5, 0.5);
|
||||
}).toThrow();
|
||||
});
|
||||
describe('linear curves', function () {
|
||||
it('should be linear', function () {
|
||||
describe('linear curves', function() {
|
||||
it('should be linear', function() {
|
||||
allEquals(bezier(0, 0, 1, 1), bezier(1, 1, 0, 0), 100);
|
||||
allEquals(bezier(0, 0, 1, 1), identity, 100);
|
||||
});
|
||||
});
|
||||
describe('common properties', function () {
|
||||
it('should be the right value at extremes', function () {
|
||||
repeat(10)(function () {
|
||||
var a = Math.random(), b = 2*Math.random()-0.5, c = Math.random(), d = 2*Math.random()-0.5;
|
||||
describe('common properties', function() {
|
||||
it('should be the right value at extremes', function() {
|
||||
repeat(10)(function() {
|
||||
var a = Math.random(),
|
||||
b = 2 * Math.random() - 0.5,
|
||||
c = Math.random(),
|
||||
d = 2 * Math.random() - 0.5;
|
||||
var easing = bezier(a, b, c, d);
|
||||
expect(easing(0)).toBe(0);
|
||||
expect(easing(1)).toBe(1);
|
||||
});
|
||||
});
|
||||
|
||||
it('should approach the projected value of its x=y projected curve', function () {
|
||||
repeat(10)(function () {
|
||||
var a = Math.random(), b = Math.random(), c = Math.random(), d = Math.random();
|
||||
it('should approach the projected value of its x=y projected curve', function() {
|
||||
repeat(10)(function() {
|
||||
var a = Math.random(),
|
||||
b = Math.random(),
|
||||
c = Math.random(),
|
||||
d = Math.random();
|
||||
var easing = bezier(a, b, c, d);
|
||||
var projected = bezier(b, a, d, c);
|
||||
var composed = function (x) { return projected(easing(x)); };
|
||||
var composed = function(x) {
|
||||
return projected(easing(x));
|
||||
};
|
||||
allEquals(identity, composed, 100, makeAssertCloseWithPrecision(2));
|
||||
});
|
||||
});
|
||||
});
|
||||
describe('two same instances', function () {
|
||||
it('should be strictly equals', function () {
|
||||
repeat(10)(function () {
|
||||
var a = Math.random(), b = 2*Math.random()-0.5, c = Math.random(), d = 2*Math.random()-0.5;
|
||||
describe('two same instances', function() {
|
||||
it('should be strictly equals', function() {
|
||||
repeat(10)(function() {
|
||||
var a = Math.random(),
|
||||
b = 2 * Math.random() - 0.5,
|
||||
c = Math.random(),
|
||||
d = 2 * Math.random() - 0.5;
|
||||
allEquals(bezier(a, b, c, d), bezier(a, b, c, d), 100, 0);
|
||||
});
|
||||
});
|
||||
});
|
||||
describe('symetric curves', function () {
|
||||
it('should have a central value y~=0.5 at x=0.5', function () {
|
||||
repeat(10)(function () {
|
||||
var a = Math.random(), b = 2*Math.random()-0.5, c = 1-a, d = 1-b;
|
||||
describe('symetric curves', function() {
|
||||
it('should have a central value y~=0.5 at x=0.5', function() {
|
||||
repeat(10)(function() {
|
||||
var a = Math.random(),
|
||||
b = 2 * Math.random() - 0.5,
|
||||
c = 1 - a,
|
||||
d = 1 - b;
|
||||
var easing = bezier(a, b, c, d);
|
||||
assertClose(easing(0.5), 0.5, 2);
|
||||
});
|
||||
});
|
||||
it('should be symetrical', function () {
|
||||
repeat(10)(function () {
|
||||
var a = Math.random(), b = 2*Math.random()-0.5, c = 1-a, d = 1-b;
|
||||
it('should be symetrical', function() {
|
||||
repeat(10)(function() {
|
||||
var a = Math.random(),
|
||||
b = 2 * Math.random() - 0.5,
|
||||
c = 1 - a,
|
||||
d = 1 - b;
|
||||
var easing = bezier(a, b, c, d);
|
||||
var sym = function (x) { return 1 - easing(1-x); };
|
||||
var sym = function(x) {
|
||||
return 1 - easing(1 - x);
|
||||
};
|
||||
allEquals(easing, sym, 100, makeAssertCloseWithPrecision(2));
|
||||
});
|
||||
});
|
||||
|
||||
@@ -54,10 +54,10 @@ describe('MessageQueue', function() {
|
||||
});
|
||||
|
||||
it('should call a local function with the function name', () => {
|
||||
MessageQueueTestModule.testHook2 = jasmine.createSpy();
|
||||
expect(MessageQueueTestModule.testHook2.calls.count()).toEqual(0);
|
||||
MessageQueueTestModule.testHook2 = jest.fn();
|
||||
expect(MessageQueueTestModule.testHook2.mock.calls.length).toEqual(0);
|
||||
queue.__callFunction('MessageQueueTestModule', 'testHook2', [2]);
|
||||
expect(MessageQueueTestModule.testHook2.calls.count()).toEqual(1);
|
||||
expect(MessageQueueTestModule.testHook2.mock.calls.length).toEqual(1);
|
||||
});
|
||||
|
||||
it('should store callbacks', () => {
|
||||
|
||||
@@ -57,8 +57,8 @@ describe('MessageQueue', function() {
|
||||
});
|
||||
|
||||
it('should make round trip and clear memory', function() {
|
||||
const onFail = jasmine.createSpy();
|
||||
const onSucc = jasmine.createSpy();
|
||||
const onFail = jest.fn();
|
||||
const onSucc = jest.fn();
|
||||
|
||||
// Perform communication
|
||||
NativeModules.RemoteModule1.promiseMethod('paloAlto', 'menloPark', onFail, onSucc);
|
||||
@@ -98,8 +98,8 @@ describe('MessageQueue', function() {
|
||||
expect(function() {
|
||||
BatchedBridge.__invokeCallback(firstSuccCBID, ['firstSucc']);
|
||||
}).toThrow();
|
||||
expect(onFail.calls.count()).toBe(1);
|
||||
expect(onSucc.calls.count()).toBe(0);
|
||||
expect(onFail.mock.calls.length).toBe(1);
|
||||
expect(onSucc.mock.calls.length).toBe(0);
|
||||
|
||||
// Handle the second remote invocation by signaling success.
|
||||
BatchedBridge.__invokeCallback(secondSuccCBID, ['secondSucc']);
|
||||
@@ -107,7 +107,7 @@ describe('MessageQueue', function() {
|
||||
expect(function() {
|
||||
BatchedBridge.__invokeCallback(secondFailCBID, ['secondFail']);
|
||||
}).toThrow();
|
||||
expect(onFail.calls.count()).toBe(1);
|
||||
expect(onSucc.calls.count()).toBe(1);
|
||||
expect(onFail.mock.calls.length).toBe(1);
|
||||
expect(onSucc.mock.calls.length).toBe(1);
|
||||
});
|
||||
});
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
*/
|
||||
'use strict';
|
||||
|
||||
const LayoutAnimation = require('LayoutAnimation');
|
||||
const invariant = require('fbjs/lib/invariant');
|
||||
const NativeEventEmitter = require('NativeEventEmitter');
|
||||
const KeyboardObserver = require('NativeModules').KeyboardObserver;
|
||||
@@ -25,16 +26,18 @@ type KeyboardEventName =
|
||||
| 'keyboardWillChangeFrame'
|
||||
| 'keyboardDidChangeFrame';
|
||||
|
||||
type KeyboardEventData = {
|
||||
endCoordinates: {
|
||||
width: number,
|
||||
height: number,
|
||||
screenX: number,
|
||||
screenY: number,
|
||||
},
|
||||
};
|
||||
export type KeyboardEvent = {|
|
||||
+duration?: number,
|
||||
+easing?: string,
|
||||
+endCoordinates: {|
|
||||
+width: number,
|
||||
+height: number,
|
||||
+screenX: number,
|
||||
+screenY: number,
|
||||
|},
|
||||
|};
|
||||
|
||||
type KeyboardEventListener = (e: KeyboardEventData) => void;
|
||||
type KeyboardEventListener = (e: KeyboardEvent) => void;
|
||||
|
||||
// The following object exists for documentation purposes
|
||||
// Actual work happens in
|
||||
@@ -134,11 +137,31 @@ let Keyboard = {
|
||||
*/
|
||||
dismiss() {
|
||||
invariant(false, 'Dummy method used for documentation');
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Useful for syncing TextInput (or other keyboard accessory view) size of
|
||||
* position changes with keyboard movements.
|
||||
*/
|
||||
scheduleLayoutAnimation(event: KeyboardEvent) {
|
||||
invariant(false, 'Dummy method used for documentation');
|
||||
},
|
||||
};
|
||||
|
||||
// Throw away the dummy object and reassign it to original module
|
||||
Keyboard = KeyboardEventEmitter;
|
||||
Keyboard.dismiss = dismissKeyboard;
|
||||
Keyboard.scheduleLayoutAnimation = function(event: KeyboardEvent) {
|
||||
const {duration, easing} = event;
|
||||
if (duration) {
|
||||
LayoutAnimation.configureNext({
|
||||
duration: duration,
|
||||
update: {
|
||||
duration: duration,
|
||||
type: (easing && LayoutAnimation.Types[easing]) || 'keyboard',
|
||||
},
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
module.exports = Keyboard;
|
||||
|
||||
@@ -11,27 +11,21 @@
|
||||
*/
|
||||
'use strict';
|
||||
|
||||
var Dimensions = require('Dimensions');
|
||||
var FrameRateLogger = require('FrameRateLogger');
|
||||
var Keyboard = require('Keyboard');
|
||||
var ReactNative = require('ReactNative');
|
||||
var Subscribable = require('Subscribable');
|
||||
var TextInputState = require('TextInputState');
|
||||
var UIManager = require('UIManager');
|
||||
const Dimensions = require('Dimensions');
|
||||
const FrameRateLogger = require('FrameRateLogger');
|
||||
const Keyboard = require('Keyboard');
|
||||
const ReactNative = require('ReactNative');
|
||||
const Subscribable = require('Subscribable');
|
||||
const TextInputState = require('TextInputState');
|
||||
const UIManager = require('UIManager');
|
||||
|
||||
var invariant = require('fbjs/lib/invariant');
|
||||
var nullthrows = require('fbjs/lib/nullthrows');
|
||||
/* $FlowFixMe(>=0.54.0 site=react_native_oss) This comment suppresses an error
|
||||
* found when Flow v0.54 was deployed. To see the error delete this comment and
|
||||
* run Flow. */
|
||||
var performanceNow = require('fbjs/lib/performanceNow');
|
||||
/* $FlowFixMe(>=0.54.0 site=react_native_oss) This comment suppresses an error
|
||||
* found when Flow v0.54 was deployed. To see the error delete this comment and
|
||||
* run Flow. */
|
||||
var warning = require('fbjs/lib/warning');
|
||||
const invariant = require('fbjs/lib/invariant');
|
||||
const nullthrows = require('fbjs/lib/nullthrows');
|
||||
const performanceNow = require('fbjs/lib/performanceNow');
|
||||
const warning = require('fbjs/lib/warning');
|
||||
|
||||
var { ScrollViewManager } = require('NativeModules');
|
||||
var { getInstanceFromNode } = require('ReactNativeComponentTree');
|
||||
const { ScrollViewManager } = require('NativeModules');
|
||||
const { getInstanceFromNode } = require('ReactNativeComponentTree');
|
||||
|
||||
/**
|
||||
* Mixin that can be integrated in order to handle scrolling that plays well
|
||||
@@ -111,7 +105,7 @@ var { getInstanceFromNode } = require('ReactNativeComponentTree');
|
||||
* this.props.onKeyboardDidHide
|
||||
*/
|
||||
|
||||
var IS_ANIMATING_TOUCH_START_THRESHOLD_MS = 16;
|
||||
const IS_ANIMATING_TOUCH_START_THRESHOLD_MS = 16;
|
||||
|
||||
type State = {
|
||||
isTouching: boolean,
|
||||
@@ -123,15 +117,15 @@ type State = {
|
||||
type Event = Object;
|
||||
|
||||
function isTagInstanceOfTextInput(tag) {
|
||||
var instance = getInstanceFromNode(tag);
|
||||
const instance = getInstanceFromNode(tag);
|
||||
return instance && instance.viewConfig && (
|
||||
instance.viewConfig.uiViewClassName === 'AndroidTextInput' ||
|
||||
instance.viewConfig.uiViewClassName === 'RCTTextView' ||
|
||||
instance.viewConfig.uiViewClassName === 'RCTTextField'
|
||||
instance.viewConfig.uiViewClassName === 'RCTMultilineTextInputView' ||
|
||||
instance.viewConfig.uiViewClassName === 'RCTSinglelineTextInputView'
|
||||
);
|
||||
}
|
||||
|
||||
var ScrollResponderMixin = {
|
||||
const ScrollResponderMixin = {
|
||||
mixins: [Subscribable.Mixin],
|
||||
scrollResponderMixinGetInitialState: function(): State {
|
||||
return {
|
||||
@@ -182,7 +176,7 @@ var ScrollResponderMixin = {
|
||||
*
|
||||
*/
|
||||
scrollResponderHandleStartShouldSetResponder: function(e: Event): boolean {
|
||||
var currentlyFocusedTextInput = TextInputState.currentlyFocusedField();
|
||||
const currentlyFocusedTextInput = TextInputState.currentlyFocusedField();
|
||||
|
||||
if (this.props.keyboardShouldPersistTaps === 'handled' &&
|
||||
currentlyFocusedTextInput != null &&
|
||||
@@ -205,9 +199,9 @@ var ScrollResponderMixin = {
|
||||
*/
|
||||
scrollResponderHandleStartShouldSetResponderCapture: function(e: Event): boolean {
|
||||
// First see if we want to eat taps while the keyboard is up
|
||||
var currentlyFocusedTextInput = TextInputState.currentlyFocusedField();
|
||||
var {keyboardShouldPersistTaps} = this.props;
|
||||
var keyboardNeverPersistTaps = !keyboardShouldPersistTaps ||
|
||||
const currentlyFocusedTextInput = TextInputState.currentlyFocusedField();
|
||||
const {keyboardShouldPersistTaps} = this.props;
|
||||
const keyboardNeverPersistTaps = !keyboardShouldPersistTaps ||
|
||||
keyboardShouldPersistTaps === 'never';
|
||||
if (keyboardNeverPersistTaps &&
|
||||
currentlyFocusedTextInput != null &&
|
||||
@@ -255,7 +249,7 @@ var ScrollResponderMixin = {
|
||||
* @param {SyntheticEvent} e Event.
|
||||
*/
|
||||
scrollResponderHandleTouchEnd: function(e: Event) {
|
||||
var nativeEvent = e.nativeEvent;
|
||||
const nativeEvent = e.nativeEvent;
|
||||
this.state.isTouching = nativeEvent.touches.length !== 0;
|
||||
this.props.onTouchEnd && this.props.onTouchEnd(e);
|
||||
},
|
||||
@@ -278,7 +272,7 @@ var ScrollResponderMixin = {
|
||||
|
||||
// By default scroll views will unfocus a textField
|
||||
// if another touch occurs outside of it
|
||||
var currentlyFocusedTextInput = TextInputState.currentlyFocusedField();
|
||||
const currentlyFocusedTextInput = TextInputState.currentlyFocusedField();
|
||||
if (this.props.keyboardShouldPersistTaps !== true &&
|
||||
this.props.keyboardShouldPersistTaps !== 'always' &&
|
||||
currentlyFocusedTextInput != null &&
|
||||
@@ -388,9 +382,9 @@ var ScrollResponderMixin = {
|
||||
* a touch has just started or ended.
|
||||
*/
|
||||
scrollResponderIsAnimating: function(): boolean {
|
||||
var now = performanceNow();
|
||||
var timeSinceLastMomentumScrollEnd = now - this.state.lastMomentumScrollEndTime;
|
||||
var isAnimating = timeSinceLastMomentumScrollEnd < IS_ANIMATING_TOUCH_START_THRESHOLD_MS ||
|
||||
const now = performanceNow();
|
||||
const timeSinceLastMomentumScrollEnd = now - this.state.lastMomentumScrollEndTime;
|
||||
const isAnimating = timeSinceLastMomentumScrollEnd < IS_ANIMATING_TOUCH_START_THRESHOLD_MS ||
|
||||
this.state.lastMomentumScrollEndTime < this.state.lastMomentumScrollBeginTime;
|
||||
return isAnimating;
|
||||
},
|
||||
@@ -469,15 +463,13 @@ var ScrollResponderMixin = {
|
||||
* @platform ios
|
||||
*/
|
||||
scrollResponderZoomTo: function(
|
||||
rect: { x: number, y: number, width: number, height: number, animated?: boolean },
|
||||
rect: {| x: number, y: number, width: number, height: number, animated?: boolean |},
|
||||
animated?: boolean // deprecated, put this inside the rect argument instead
|
||||
) {
|
||||
invariant(ScrollViewManager && ScrollViewManager.zoomToRect, 'zoomToRect is not implemented');
|
||||
if ('animated' in rect) {
|
||||
/* $FlowFixMe(>=0.60.0 site=react_native_fb) This comment suppresses an
|
||||
* error found when Flow v0.60 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
var { animated, ...rect } = rect;
|
||||
animated = rect.animated;
|
||||
delete rect.animated;
|
||||
} else if (typeof animated !== 'undefined') {
|
||||
console.warn('`scrollResponderZoomTo` `animated` argument is deprecated. Use `options.animated` instead');
|
||||
}
|
||||
@@ -527,11 +519,11 @@ var ScrollResponderMixin = {
|
||||
* @param {number} height Height of the text input.
|
||||
*/
|
||||
scrollResponderInputMeasureAndScrollToKeyboard: function(left: number, top: number, width: number, height: number) {
|
||||
var keyboardScreenY = Dimensions.get('window').height;
|
||||
let keyboardScreenY = Dimensions.get('window').height;
|
||||
if (this.keyboardWillOpenTo) {
|
||||
keyboardScreenY = this.keyboardWillOpenTo.endCoordinates.screenY;
|
||||
}
|
||||
var scrollOffsetY = top - keyboardScreenY + height + this.additionalScrollOffset;
|
||||
let scrollOffsetY = top - keyboardScreenY + height + this.additionalScrollOffset;
|
||||
|
||||
// By default, this can scroll with negative offset, pulling the content
|
||||
// down so that the target component's bottom meets the keyboard's top.
|
||||
@@ -557,7 +549,7 @@ var ScrollResponderMixin = {
|
||||
* The `keyboardWillShow` is called before input focus.
|
||||
*/
|
||||
componentWillMount: function() {
|
||||
var {keyboardShouldPersistTaps} = this.props;
|
||||
const {keyboardShouldPersistTaps} = this.props;
|
||||
warning(
|
||||
typeof keyboardShouldPersistTaps !== 'boolean',
|
||||
`'keyboardShouldPersistTaps={${keyboardShouldPersistTaps}}' is deprecated. `
|
||||
@@ -626,7 +618,7 @@ var ScrollResponderMixin = {
|
||||
|
||||
};
|
||||
|
||||
var ScrollResponder = {
|
||||
const ScrollResponder = {
|
||||
Mixin: ScrollResponderMixin,
|
||||
};
|
||||
|
||||
|
||||
@@ -256,6 +256,15 @@ const ScrollView = createReactClass({
|
||||
* events can be controlled using the `scrollEventThrottle` prop.
|
||||
*/
|
||||
onScroll: PropTypes.func,
|
||||
/**
|
||||
* Called when the user begins to drag the scroll view.
|
||||
*/
|
||||
onScrollBeginDrag: PropTypes.func,
|
||||
/**
|
||||
* Called when the user stops dragging the scroll view and it either stops
|
||||
* or begins to glide.
|
||||
*/
|
||||
onScrollEndDrag: PropTypes.func,
|
||||
/**
|
||||
* Called when scrollable content view of the ScrollView changes.
|
||||
*
|
||||
@@ -335,10 +344,10 @@ const ScrollView = createReactClass({
|
||||
* When set, causes the scroll view to stop at multiples of the value of
|
||||
* `snapToInterval`. This can be used for paginating through children
|
||||
* that have lengths smaller than the scroll view. Typically used in
|
||||
* combination with `snapToAlignment` and `decelerationRate="fast"`.
|
||||
* combination with `snapToAlignment` and `decelerationRate="fast"` on ios.
|
||||
* Overrides less configurable `pagingEnabled` prop.
|
||||
*
|
||||
* @platform ios
|
||||
* Supported for horizontal scrollview on android.
|
||||
*/
|
||||
snapToInterval: PropTypes.number,
|
||||
/**
|
||||
@@ -602,7 +611,7 @@ const ScrollView = createReactClass({
|
||||
_handleScroll: function(e: Object) {
|
||||
if (__DEV__) {
|
||||
if (this.props.onScroll && this.props.scrollEventThrottle == null && Platform.OS === 'ios') {
|
||||
console.log( // eslint-disable-line no-console
|
||||
console.log(
|
||||
'You specified `onScroll` on a <ScrollView> but not ' +
|
||||
'`scrollEventThrottle`. You will only receive one event. ' +
|
||||
'Using `16` you get all the events but be aware that it may ' +
|
||||
|
||||
@@ -50,8 +50,8 @@ const onlyMultiline = {
|
||||
if (Platform.OS === 'android') {
|
||||
var AndroidTextInput = requireNativeComponent('AndroidTextInput', null);
|
||||
} else if (Platform.OS === 'ios') {
|
||||
var RCTTextView = requireNativeComponent('RCTTextView', null);
|
||||
var RCTTextField = requireNativeComponent('RCTTextField', null);
|
||||
var RCTMultilineTextInputView = requireNativeComponent('RCTMultilineTextInputView', null);
|
||||
var RCTSinglelineTextInputView = requireNativeComponent('RCTSinglelineTextInputView', null);
|
||||
}
|
||||
|
||||
type Event = Object;
|
||||
@@ -219,13 +219,6 @@ const TextInput = createReactClass({
|
||||
* The default value is `false`.
|
||||
*/
|
||||
autoFocus: PropTypes.bool,
|
||||
/**
|
||||
* If true, will increase the height of the textbox if need be. If false,
|
||||
* the textbox will become scrollable once the height is reached. The
|
||||
* default value is false.
|
||||
* @platform android
|
||||
*/
|
||||
autoGrow: PropTypes.bool,
|
||||
/**
|
||||
* Specifies whether fonts should scale to respect Text Size accessibility settings. The
|
||||
* default is `true`.
|
||||
@@ -351,11 +344,6 @@ const TextInput = createReactClass({
|
||||
* instead of implementing the logic in JS to avoid flicker.
|
||||
*/
|
||||
maxLength: PropTypes.number,
|
||||
/**
|
||||
* If autogrow is `true`, limits the height that the TextInput box can grow
|
||||
* to. Once it reaches this height, the TextInput becomes scrollable.
|
||||
*/
|
||||
maxHeight: PropTypes.number,
|
||||
/**
|
||||
* Sets the number of lines for a `TextInput`. Use it with multiline set to
|
||||
* `true` to be able to fill the lines.
|
||||
@@ -434,7 +422,6 @@ const TextInput = createReactClass({
|
||||
* where `keyValue` is `'Enter'` or `'Backspace'` for respective keys and
|
||||
* the typed-in character otherwise including `' '` for space.
|
||||
* Fires before `onChange` callbacks.
|
||||
* @platform ios
|
||||
*/
|
||||
onKeyPress: PropTypes.func,
|
||||
/**
|
||||
@@ -612,10 +599,6 @@ const TextInput = createReactClass({
|
||||
*/
|
||||
mixins: [NativeMethodsMixin, TimerMixin],
|
||||
|
||||
getInitialState: function() {
|
||||
return {layoutHeight: this._layoutHeight};
|
||||
},
|
||||
|
||||
/**
|
||||
* Returns `true` if the input is currently focused; `false` otherwise.
|
||||
*/
|
||||
@@ -633,7 +616,6 @@ const TextInput = createReactClass({
|
||||
_focusSubscription: (undefined: ?Function),
|
||||
_lastNativeText: (undefined: ?string),
|
||||
_lastNativeSelection: (undefined: ?Selection),
|
||||
_layoutHeight: (-1: number),
|
||||
|
||||
componentDidMount: function() {
|
||||
this._lastNativeText = this.props.value;
|
||||
@@ -724,7 +706,7 @@ const TextInput = createReactClass({
|
||||
}
|
||||
}
|
||||
textContainer =
|
||||
<RCTTextField
|
||||
<RCTSinglelineTextInputView
|
||||
ref={this._setNativeRef}
|
||||
{...props}
|
||||
onFocus={this._onFocus}
|
||||
@@ -750,7 +732,7 @@ const TextInput = createReactClass({
|
||||
}
|
||||
props.style.unshift(styles.multilineInput);
|
||||
textContainer =
|
||||
<RCTTextView
|
||||
<RCTMultilineTextInputView
|
||||
ref={this._setNativeRef}
|
||||
{...props}
|
||||
children={children}
|
||||
@@ -766,6 +748,7 @@ const TextInput = createReactClass({
|
||||
onScroll={this._onScroll}
|
||||
/>;
|
||||
}
|
||||
|
||||
return (
|
||||
<TouchableWithoutFeedback
|
||||
onLayout={props.onLayout}
|
||||
@@ -783,10 +766,7 @@ const TextInput = createReactClass({
|
||||
|
||||
_renderAndroid: function() {
|
||||
const props = Object.assign({}, this.props);
|
||||
props.style = this.props.style;
|
||||
if (this.state.layoutHeight >= 0) {
|
||||
props.style = [props.style, {height: this.state.layoutHeight}];
|
||||
}
|
||||
props.style = [this.props.style];
|
||||
props.autoCapitalize =
|
||||
UIManager.AndroidTextInput.Constants.AutoCapitalizationType[
|
||||
props.autoCapitalize || 'sentences'
|
||||
@@ -804,9 +784,11 @@ const TextInput = createReactClass({
|
||||
if (childCount > 1) {
|
||||
children = <Text>{children}</Text>;
|
||||
}
|
||||
|
||||
if (props.selection && props.selection.end == null) {
|
||||
props.selection = {start: props.selection.start, end: props.selection.start};
|
||||
}
|
||||
|
||||
const textContainer =
|
||||
<AndroidTextInput
|
||||
ref={this._setNativeRef}
|
||||
@@ -815,7 +797,6 @@ const TextInput = createReactClass({
|
||||
onFocus={this._onFocus}
|
||||
onBlur={this._onBlur}
|
||||
onChange={this._onChange}
|
||||
onContentSizeChange={this._onContentSizeChange}
|
||||
onSelectionChange={this._onSelectionChange}
|
||||
onTextInput={this._onTextInput}
|
||||
text={this._getText()}
|
||||
@@ -878,26 +859,6 @@ const TextInput = createReactClass({
|
||||
this.forceUpdate();
|
||||
},
|
||||
|
||||
_onContentSizeChange: function(event: Event) {
|
||||
let contentHeight = event.nativeEvent.contentSize.height;
|
||||
if (this.props.autoGrow) {
|
||||
if (this.props.maxHeight) {
|
||||
contentHeight = Math.min(this.props.maxHeight, contentHeight);
|
||||
}
|
||||
this.setState({layoutHeight: Math.max(this._layoutHeight, contentHeight)});
|
||||
}
|
||||
|
||||
this.props.onContentSizeChange && this.props.onContentSizeChange(event);
|
||||
},
|
||||
|
||||
_onLayout: function(event: Event) {
|
||||
const height = event.nativeEvent.layout.height;
|
||||
if (height) {
|
||||
this._layoutHeight = event.nativeEvent.layout.height;
|
||||
}
|
||||
this.props.onLayout && this.props.onLayout(event);
|
||||
},
|
||||
|
||||
_onSelectionChange: function(event: Event) {
|
||||
this.props.onSelectionChange && this.props.onSelectionChange(event);
|
||||
|
||||
@@ -964,8 +925,8 @@ const TextInput = createReactClass({
|
||||
|
||||
var styles = StyleSheet.create({
|
||||
multilineInput: {
|
||||
// This default top inset makes RCTTextView seem as close as possible
|
||||
// to single-line RCTTextField defaults, using the system defaults
|
||||
// This default top inset makes RCTMultilineTextInputView seem as close as possible
|
||||
// to single-line RCTSinglelineTextInputView defaults, using the system defaults
|
||||
// of font size 17 and a height of 31 points.
|
||||
paddingTop: 5,
|
||||
},
|
||||
|
||||
@@ -26,7 +26,7 @@ const ViewPropTypes = require('ViewPropTypes');
|
||||
const createReactClass = require('create-react-class');
|
||||
const ensurePositiveDelayProps = require('ensurePositiveDelayProps');
|
||||
|
||||
import type {Event} from 'TouchableWithoutFeedback';
|
||||
import type {PressEvent} from 'CoreEventTypes';
|
||||
|
||||
const DEFAULT_PROPS = {
|
||||
activeOpacity: 0.85,
|
||||
@@ -216,21 +216,21 @@ const TouchableHighlight = createReactClass({
|
||||
* `Touchable.Mixin` self callbacks. The mixin will invoke these if they are
|
||||
* defined on your component.
|
||||
*/
|
||||
touchableHandleActivePressIn: function(e: Event) {
|
||||
touchableHandleActivePressIn: function(e: PressEvent) {
|
||||
clearTimeout(this._hideTimeout);
|
||||
this._hideTimeout = null;
|
||||
this._showUnderlay();
|
||||
this.props.onPressIn && this.props.onPressIn(e);
|
||||
},
|
||||
|
||||
touchableHandleActivePressOut: function(e: Event) {
|
||||
touchableHandleActivePressOut: function(e: PressEvent) {
|
||||
if (!this._hideTimeout) {
|
||||
this._hideUnderlay();
|
||||
}
|
||||
this.props.onPressOut && this.props.onPressOut(e);
|
||||
},
|
||||
|
||||
touchableHandlePress: function(e: Event) {
|
||||
touchableHandlePress: function(e: PressEvent) {
|
||||
clearTimeout(this._hideTimeout);
|
||||
this._showUnderlay();
|
||||
this._hideTimeout = setTimeout(
|
||||
@@ -240,7 +240,7 @@ const TouchableHighlight = createReactClass({
|
||||
this.props.onPress && this.props.onPress(e);
|
||||
},
|
||||
|
||||
touchableHandleLongPress: function(e: Event) {
|
||||
touchableHandleLongPress: function(e: PressEvent) {
|
||||
this.props.onLongPress && this.props.onLongPress(e);
|
||||
},
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ const {
|
||||
AccessibilityTraits,
|
||||
} = require('ViewAccessibility');
|
||||
|
||||
export type Event = Object;
|
||||
import type {PressEvent} from 'CoreEventTypes';
|
||||
|
||||
const PRESS_RETENTION_OFFSET = {top: 20, left: 20, right: 20, bottom: 30};
|
||||
|
||||
@@ -130,19 +130,19 @@ const TouchableWithoutFeedback = createReactClass({
|
||||
* `Touchable.Mixin` self callbacks. The mixin will invoke these if they are
|
||||
* defined on your component.
|
||||
*/
|
||||
touchableHandlePress: function(e: Event) {
|
||||
touchableHandlePress: function(e: PressEvent) {
|
||||
this.props.onPress && this.props.onPress(e);
|
||||
},
|
||||
|
||||
touchableHandleActivePressIn: function(e: Event) {
|
||||
touchableHandleActivePressIn: function(e: PressEvent) {
|
||||
this.props.onPressIn && this.props.onPressIn(e);
|
||||
},
|
||||
|
||||
touchableHandleActivePressOut: function(e: Event) {
|
||||
touchableHandleActivePressOut: function(e: PressEvent) {
|
||||
this.props.onPressOut && this.props.onPressOut(e);
|
||||
},
|
||||
|
||||
touchableHandleLongPress: function(e: Event) {
|
||||
touchableHandleLongPress: function(e: PressEvent) {
|
||||
this.props.onLongPress && this.props.onLongPress(e);
|
||||
},
|
||||
|
||||
|
||||
@@ -28,11 +28,11 @@ let register = function () {
|
||||
if (__DEV__) {
|
||||
const AppState = require('AppState');
|
||||
const WebSocket = require('WebSocket');
|
||||
const {PlatformConstants} = require('NativeModules');
|
||||
/* $FlowFixMe(>=0.54.0 site=react_native_oss) This comment suppresses an
|
||||
* error found when Flow v0.54 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
const reactDevTools = require('react-devtools-core');
|
||||
const getDevServer = require('getDevServer');
|
||||
|
||||
// Initialize dev tools only if the native module for WebSocket is available
|
||||
if (WebSocket.isAvailable) {
|
||||
@@ -42,10 +42,11 @@ if (__DEV__) {
|
||||
// or the code will throw for bundles that don't have it.
|
||||
const isAppActive = () => AppState.currentState !== 'background';
|
||||
|
||||
// Special case: Genymotion is running on a different host.
|
||||
const host = PlatformConstants && PlatformConstants.ServerHost ?
|
||||
PlatformConstants.ServerHost.split(':')[0] :
|
||||
'localhost';
|
||||
// Get hostname from development server (packager)
|
||||
const devServer = getDevServer();
|
||||
const host = devServer.bundleLoadedFromServer
|
||||
? devServer.url.replace(/https?:\/\//, '').split(':')[0]
|
||||
: 'localhost';
|
||||
|
||||
reactDevTools.connectToDevTools({
|
||||
isAppActive,
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
* @flow
|
||||
*/
|
||||
|
||||
/* eslint-disable strict */
|
||||
/* globals window: true */
|
||||
|
||||
/**
|
||||
@@ -115,9 +114,7 @@ if (!global.__fbDisableExceptionsManager) {
|
||||
try {
|
||||
ExceptionsManager.handleException(e, isFatal);
|
||||
} catch (ee) {
|
||||
/* eslint-disable no-console */
|
||||
console.log('Failed to print error: ', ee.message);
|
||||
/* eslint-enable no-console */
|
||||
throw e;
|
||||
}
|
||||
};
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
|
||||
exports.version = {
|
||||
major: 0,
|
||||
minor: 0,
|
||||
patch: 0,
|
||||
minor: 53,
|
||||
patch: 3,
|
||||
prerelease: null,
|
||||
};
|
||||
|
||||
@@ -687,6 +687,9 @@ class CellRenderer extends React.Component<CellProps> {
|
||||
}
|
||||
};
|
||||
componentWillUnmount() {
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses an
|
||||
* error found when Flow v0.63 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
clearTimeout(this._timeout);
|
||||
this.props.onProgressChange({rowKey: this.props.rowKey, inProgress: false});
|
||||
this.props.onWillUnmount(this.props.rowKey);
|
||||
|
||||
@@ -52,19 +52,15 @@ class AssetSourceResolver {
|
||||
serverUrl: ?string;
|
||||
// where the jsbundle is being run from
|
||||
jsbundleUrl: ?string;
|
||||
// where the embedded bundle in the app is stored
|
||||
embeddedBundleUrl: ?string;
|
||||
// the asset to resolve
|
||||
asset: PackagerAsset;
|
||||
|
||||
constructor(serverUrl: ?string,
|
||||
jsbundleUrl: ?string,
|
||||
embeddedBundleUrl: ?string,
|
||||
asset: PackagerAsset
|
||||
) {
|
||||
this.serverUrl = serverUrl;
|
||||
this.jsbundleUrl = jsbundleUrl;
|
||||
this.embeddedBundleUrl = embeddedBundleUrl;
|
||||
this.asset = asset;
|
||||
}
|
||||
|
||||
@@ -76,10 +72,6 @@ class AssetSourceResolver {
|
||||
return !!(this.jsbundleUrl && this.jsbundleUrl.startsWith('file://'));
|
||||
}
|
||||
|
||||
canLoadFromEmbeddedBundledLocation(): boolean {
|
||||
return !!this.embeddedBundleUrl;
|
||||
}
|
||||
|
||||
defaultAsset(): ResolvedAssetSource {
|
||||
if (this.isLoadedFromServer()) {
|
||||
return this.assetServerURL();
|
||||
@@ -123,15 +115,6 @@ class AssetSourceResolver {
|
||||
return this.fromSource(path + getScaledAssetPath(this.asset));
|
||||
}
|
||||
|
||||
/**
|
||||
* Resolves to the asset that was bundled with the app, with a scaled asset filename
|
||||
* E.g. 'file:///sdcard/bundle/assets/AwesomeModule/icon@2x.png'
|
||||
*/
|
||||
scaledAssetURLInEmbeddedBundleUrl(): ResolvedAssetSource {
|
||||
const path = this.embeddedBundleUrl || 'file://';
|
||||
return this.fromSource(path + getScaledAssetPath(this.asset));
|
||||
}
|
||||
|
||||
/**
|
||||
* The default location of assets bundled with the app, located by
|
||||
* resource identifier
|
||||
|
||||
@@ -19,7 +19,7 @@ const NativeModules = require('NativeModules');
|
||||
|
||||
import type { ResolvedAssetSource } from 'AssetSourceResolver';
|
||||
|
||||
let _customSourceTransformer, _serverURL, _scriptURL, _embeddedBundleURL;
|
||||
let _customSourceTransformer, _serverURL, _scriptURL;
|
||||
|
||||
function getDevServerURL(): ?string {
|
||||
if (_serverURL === undefined) {
|
||||
@@ -60,12 +60,6 @@ function getScriptURL(): ?string {
|
||||
return _scriptURL;
|
||||
}
|
||||
|
||||
function getEmbeddedBundledURL(): ?string {
|
||||
const scriptURL = NativeModules.SourceCode.embeddedBundleURL;
|
||||
_embeddedBundleURL = _coerceLocalScriptURL(scriptURL);
|
||||
return _embeddedBundleURL;
|
||||
}
|
||||
|
||||
function setCustomSourceTransformer(
|
||||
transformer: (resolver: AssetSourceResolver) => ResolvedAssetSource,
|
||||
): void {
|
||||
@@ -89,7 +83,6 @@ function resolveAssetSource(source: any): ?ResolvedAssetSource {
|
||||
const resolver = new AssetSourceResolver(
|
||||
getDevServerURL(),
|
||||
getScriptURL(),
|
||||
getEmbeddedBundledURL(),
|
||||
asset,
|
||||
);
|
||||
if (_customSourceTransformer) {
|
||||
|
||||
@@ -10,8 +10,6 @@
|
||||
* @flow
|
||||
*/
|
||||
|
||||
/* eslint-disable dot-notation, no-dimensions-get-window */
|
||||
|
||||
'use strict';
|
||||
|
||||
const Dimensions = require('Dimensions');
|
||||
@@ -101,6 +99,9 @@ class Inspector extends React.Component<{
|
||||
attachToDevtools = (agent: Object) => {
|
||||
let _hideWait = null;
|
||||
const hlSub = agent.sub('highlight', ({node, name, props}) => {
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses an
|
||||
* error found when Flow v0.63 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
clearTimeout(_hideWait);
|
||||
|
||||
if (typeof node !== 'number') {
|
||||
|
||||
@@ -168,6 +168,9 @@ declare function setImmediate(callback: any, ...args: Array<any>): number;
|
||||
function _scheduleUpdate() {
|
||||
if (!_nextUpdateHandle) {
|
||||
if (_deadline > 0) {
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses an
|
||||
* error found when Flow v0.63 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
_nextUpdateHandle = setTimeout(_processUpdate, 0 + DEBUG_DELAY);
|
||||
} else {
|
||||
_nextUpdateHandle = setImmediate(_processUpdate);
|
||||
|
||||
@@ -11,8 +11,6 @@
|
||||
* @format
|
||||
*/
|
||||
|
||||
/* eslint-disable no-console */
|
||||
|
||||
'use strict';
|
||||
|
||||
/* $FlowFixMe(>=0.54.0 site=react_native_oss) This comment suppresses an error
|
||||
|
||||
@@ -462,6 +462,9 @@ class FlatList<ItemT> extends React.PureComponent<Props<ItemT>, void> {
|
||||
}),
|
||||
);
|
||||
} else if (this.props.onViewableItemsChanged) {
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses an
|
||||
* error found when Flow v0.63 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
this._virtualizedListPairs.push({
|
||||
viewabilityConfig: this.props.viewabilityConfig,
|
||||
onViewableItemsChanged: this._createOnViewableItemsChanged(
|
||||
@@ -555,6 +558,9 @@ class FlatList<ItemT> extends React.PureComponent<Props<ItemT>, void> {
|
||||
.map((it, kk) => keyExtractor(it, index * numColumns + kk))
|
||||
.join(':');
|
||||
} else {
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses an
|
||||
* error found when Flow v0.63 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
return keyExtractor(items, index);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -71,7 +71,7 @@ type OptionalProps<SectionT: SectionBase<any>> = {
|
||||
/**
|
||||
* Default renderer for every item in every section. Can be over-ridden on a per-section basis.
|
||||
*/
|
||||
renderItem: (info: {
|
||||
renderItem?: (info: {
|
||||
item: Item,
|
||||
index: number,
|
||||
section: SectionT,
|
||||
|
||||
@@ -74,6 +74,9 @@ export type ViewabilityConfig = {|
|
||||
class ViewabilityHelper {
|
||||
_config: ViewabilityConfig;
|
||||
_hasInteracted: boolean = false;
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses an error
|
||||
* found when Flow v0.63 was deployed. To see the error delete this comment
|
||||
* and run Flow. */
|
||||
_timers: Set<number> = new Set();
|
||||
_viewableIndices: Array<number> = [];
|
||||
_viewableItems: Map<string, ViewToken> = new Map();
|
||||
|
||||
@@ -25,17 +25,19 @@ function elementsThatOverlapOffsets(
|
||||
getFrameMetrics: (index: number) => {length: number, offset: number},
|
||||
): Array<number> {
|
||||
const out = [];
|
||||
let outLength = 0;
|
||||
for (let ii = 0; ii < itemCount; ii++) {
|
||||
const frame = getFrameMetrics(ii);
|
||||
const trailingOffset = frame.offset + frame.length;
|
||||
for (let kk = 0; kk < offsets.length; kk++) {
|
||||
if (out[kk] == null && trailingOffset >= offsets[kk]) {
|
||||
out[kk] = ii;
|
||||
outLength++;
|
||||
if (kk === offsets.length - 1) {
|
||||
invariant(
|
||||
out.length === offsets.length,
|
||||
'bad offsets input, should be in increasing order ' +
|
||||
JSON.stringify(offsets),
|
||||
outLength === offsets.length,
|
||||
'bad offsets input, should be in increasing order: %s',
|
||||
JSON.stringify(offsets),
|
||||
);
|
||||
return out;
|
||||
}
|
||||
@@ -114,6 +116,15 @@ function computeWindowedRenderLimits(
|
||||
);
|
||||
const overscanEnd = Math.max(0, visibleEnd + leadFactor * overscanLength);
|
||||
|
||||
const lastItemOffset = getFrameMetricsApprox(itemCount - 1).offset;
|
||||
if (lastItemOffset < overscanBegin) {
|
||||
// Entire list is before our overscan window
|
||||
return {
|
||||
first: Math.max(0, itemCount - 1 - maxToRenderPerBatch),
|
||||
last: itemCount - 1,
|
||||
};
|
||||
}
|
||||
|
||||
// Find the indices that correspond to the items at the render boundaries we're targetting.
|
||||
let [overscanFirst, first, last, overscanLast] = elementsThatOverlapOffsets(
|
||||
[overscanBegin, visibleBegin, visibleEnd, overscanEnd],
|
||||
|
||||
@@ -20,6 +20,7 @@ const ReactNative = require('ReactNative');
|
||||
const RefreshControl = require('RefreshControl');
|
||||
const ScrollView = require('ScrollView');
|
||||
const StyleSheet = require('StyleSheet');
|
||||
const UIManager = require('UIManager');
|
||||
const View = require('View');
|
||||
const ViewabilityHelper = require('ViewabilityHelper');
|
||||
|
||||
@@ -129,6 +130,12 @@ type OptionalProps = {
|
||||
* a rendered element.
|
||||
*/
|
||||
ListHeaderComponent?: ?(React.ComponentType<any> | React.Element<any>),
|
||||
/**
|
||||
* A unique identifier for this list. If there are multiple VirtualizedLists at the same level of
|
||||
* nesting within another VirtualizedList, this key is necessary for virtualization to
|
||||
* work properly.
|
||||
*/
|
||||
listKey?: string,
|
||||
/**
|
||||
* The maximum number of items to render in each incremental render batch. The more rendered at
|
||||
* once, the better the fill rate, but responsiveness my suffer because rendering content may
|
||||
@@ -206,6 +213,19 @@ export type Props = RequiredProps & OptionalProps;
|
||||
|
||||
let _usedIndexForKey = false;
|
||||
|
||||
type Frame = {
|
||||
offset: number,
|
||||
length: number,
|
||||
index: number,
|
||||
inLayout: boolean,
|
||||
};
|
||||
|
||||
type ChildListState = {
|
||||
first: number,
|
||||
last: number,
|
||||
frames: {[key: number]: Frame},
|
||||
};
|
||||
|
||||
type State = {first: number, last: number};
|
||||
|
||||
/**
|
||||
@@ -412,26 +432,99 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
};
|
||||
|
||||
static contextTypes = {
|
||||
virtualizedCell: PropTypes.shape({
|
||||
cellKey: PropTypes.string,
|
||||
}),
|
||||
virtualizedList: PropTypes.shape({
|
||||
getScrollMetrics: PropTypes.func,
|
||||
horizontal: PropTypes.bool,
|
||||
getOutermostParentListRef: PropTypes.func,
|
||||
registerAsNestedChild: PropTypes.func,
|
||||
unregisterAsNestedChild: PropTypes.func,
|
||||
}),
|
||||
};
|
||||
|
||||
static childContextTypes = {
|
||||
virtualizedList: PropTypes.shape({
|
||||
getScrollMetrics: PropTypes.func,
|
||||
horizontal: PropTypes.bool,
|
||||
getOutermostParentListRef: PropTypes.func,
|
||||
registerAsNestedChild: PropTypes.func,
|
||||
unregisterAsNestedChild: PropTypes.func,
|
||||
}),
|
||||
};
|
||||
|
||||
getChildContext() {
|
||||
return {
|
||||
virtualizedList: {
|
||||
getScrollMetrics: this._getScrollMetrics,
|
||||
horizontal: this.props.horizontal,
|
||||
// TODO: support nested virtualization and onViewableItemsChanged
|
||||
getOutermostParentListRef: this._getOutermostParentListRef,
|
||||
registerAsNestedChild: this._registerAsNestedChild,
|
||||
unregisterAsNestedChild: this._unregisterAsNestedChild,
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
_getCellKey(): string {
|
||||
return (
|
||||
(this.context.virtualizedCell && this.context.virtualizedCell.cellKey) ||
|
||||
'rootList'
|
||||
);
|
||||
}
|
||||
|
||||
_getScrollMetrics = () => {
|
||||
return this._scrollMetrics;
|
||||
};
|
||||
|
||||
hasMore(): boolean {
|
||||
return this._hasMore;
|
||||
}
|
||||
|
||||
_getOutermostParentListRef = () => {
|
||||
if (this._isNestedWithSameOrientation()) {
|
||||
return this.context.virtualizedList.getOutermostParentListRef();
|
||||
} else {
|
||||
return this;
|
||||
}
|
||||
};
|
||||
|
||||
_registerAsNestedChild = (childList: {
|
||||
cellKey: string,
|
||||
key: string,
|
||||
ref: VirtualizedList,
|
||||
}): ?ChildListState => {
|
||||
// Register the mapping between this child key and the cellKey for its cell
|
||||
const childListsInCell =
|
||||
this._cellKeysToChildListKeys.get(childList.cellKey) || new Set();
|
||||
childListsInCell.add(childList.key);
|
||||
this._cellKeysToChildListKeys.set(childList.cellKey, childListsInCell);
|
||||
|
||||
const existingChildData = this._nestedChildLists.get(childList.key);
|
||||
invariant(
|
||||
!(existingChildData && existingChildData.ref !== null),
|
||||
'A VirtualizedList contains a cell which itself contains ' +
|
||||
'more than one VirtualizedList of the same orientation as the parent ' +
|
||||
'list. You must pass a unique listKey prop to each sibling list.',
|
||||
);
|
||||
this._nestedChildLists.set(childList.key, {
|
||||
ref: childList.ref,
|
||||
state: null,
|
||||
});
|
||||
|
||||
return existingChildData && existingChildData.state;
|
||||
};
|
||||
|
||||
_unregisterAsNestedChild = (childList: {
|
||||
key: string,
|
||||
state: ChildListState,
|
||||
}): void => {
|
||||
this._nestedChildLists.set(childList.key, {
|
||||
ref: null,
|
||||
state: childList.state,
|
||||
});
|
||||
};
|
||||
|
||||
state: State;
|
||||
|
||||
constructor(props: Props, context: Object) {
|
||||
@@ -441,10 +534,10 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
'Components based on VirtualizedList must be wrapped with Animated.createAnimatedComponent ' +
|
||||
'to support native onScroll events with useNativeDriver',
|
||||
);
|
||||
|
||||
invariant(
|
||||
!(this._isNestedWithSameOrientation() && props.onViewableItemsChanged),
|
||||
'Nesting lists that scroll in the same direction does not support onViewableItemsChanged' +
|
||||
'on the inner list.',
|
||||
props.windowSize > 0,
|
||||
'VirtualizedList: The windowSize prop must be present and set to a value greater than 0.',
|
||||
);
|
||||
|
||||
this._fillRateHelper = new FillRateHelper(this._getFrameMetrics);
|
||||
@@ -467,7 +560,7 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
});
|
||||
}
|
||||
|
||||
this.state = {
|
||||
let initialState = {
|
||||
first: this.props.initialScrollIndex || 0,
|
||||
last:
|
||||
Math.min(
|
||||
@@ -475,12 +568,30 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
(this.props.initialScrollIndex || 0) + this.props.initialNumToRender,
|
||||
) - 1,
|
||||
};
|
||||
|
||||
if (this._isNestedWithSameOrientation()) {
|
||||
const storedState = this.context.virtualizedList.registerAsNestedChild({
|
||||
cellKey: this._getCellKey(),
|
||||
key: this.props.listKey || this._getCellKey(),
|
||||
ref: this,
|
||||
});
|
||||
if (storedState) {
|
||||
initialState = storedState;
|
||||
this.state = storedState;
|
||||
this._frames = storedState.frames;
|
||||
}
|
||||
}
|
||||
|
||||
this.state = initialState;
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
if (this.props.initialScrollIndex) {
|
||||
this._initialScrollIndexTimeout = setTimeout(
|
||||
() =>
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses
|
||||
* an error found when Flow v0.63 was deployed. To see the error
|
||||
* delete this comment and run Flow. */
|
||||
this.scrollToIndex({
|
||||
animated: false,
|
||||
index: this.props.initialScrollIndex,
|
||||
@@ -491,12 +602,25 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
}
|
||||
|
||||
componentWillUnmount() {
|
||||
if (this._isNestedWithSameOrientation()) {
|
||||
this.context.virtualizedList.unregisterAsNestedChild({
|
||||
key: this.props.listKey || this._getCellKey(),
|
||||
state: {
|
||||
first: this.state.first,
|
||||
last: this.state.last,
|
||||
frames: this._frames,
|
||||
},
|
||||
});
|
||||
}
|
||||
this._updateViewableItems(null);
|
||||
this._updateCellsToRenderBatcher.dispose();
|
||||
this._updateCellsToRenderBatcher.dispose({abort: true});
|
||||
this._viewabilityTuples.forEach(tuple => {
|
||||
tuple.viewabilityHelper.dispose();
|
||||
});
|
||||
this._fillRateHelper.deactivateAndFlush();
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses an
|
||||
* error found when Flow v0.63 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
clearTimeout(this._initialScrollIndexTimeout);
|
||||
}
|
||||
|
||||
@@ -549,6 +673,7 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
for (let ii = first; ii <= last; ii++) {
|
||||
const item = getItem(data, ii);
|
||||
const key = keyExtractor(item, ii);
|
||||
this._indicesToKeys.set(ii, key);
|
||||
if (stickyIndicesFromProps.has(ii + stickyOffset)) {
|
||||
stickyHeaderIndices.push(cells.length);
|
||||
}
|
||||
@@ -585,9 +710,7 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
};
|
||||
|
||||
_isVirtualizationDisabled(): boolean {
|
||||
return (
|
||||
this.props.disableVirtualization || this._isNestedWithSameOrientation()
|
||||
);
|
||||
return this.props.disableVirtualization;
|
||||
}
|
||||
|
||||
_isNestedWithSameOrientation(): boolean {
|
||||
@@ -606,7 +729,6 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
'Consider using `numColumns` with `FlatList` instead.',
|
||||
);
|
||||
}
|
||||
|
||||
const {
|
||||
ListEmptyComponent,
|
||||
ListFooterComponent,
|
||||
@@ -633,12 +755,13 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
<ListHeaderComponent />
|
||||
);
|
||||
cells.push(
|
||||
<View
|
||||
key="$header"
|
||||
onLayout={this._onLayoutHeader}
|
||||
style={inversionStyle}>
|
||||
{element}
|
||||
</View>,
|
||||
<VirtualizedCellWrapper
|
||||
cellKey={this._getCellKey() + '-header'}
|
||||
key="$header">
|
||||
<View onLayout={this._onLayoutHeader} style={inversionStyle}>
|
||||
{element}
|
||||
</View>
|
||||
</VirtualizedCellWrapper>,
|
||||
);
|
||||
}
|
||||
const itemCount = this.props.getItemCount(data);
|
||||
@@ -757,12 +880,13 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
<ListFooterComponent />
|
||||
);
|
||||
cells.push(
|
||||
<View
|
||||
key="$footer"
|
||||
onLayout={this._onLayoutFooter}
|
||||
style={inversionStyle}>
|
||||
{element}
|
||||
</View>,
|
||||
<VirtualizedCellWrapper
|
||||
cellKey={this._getCellKey() + '-footer'}
|
||||
key="$footer">
|
||||
<View onLayout={this._onLayoutFooter} style={inversionStyle}>
|
||||
{element}
|
||||
</View>
|
||||
</VirtualizedCellWrapper>,
|
||||
);
|
||||
}
|
||||
const scrollProps = {
|
||||
@@ -779,6 +903,10 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
if (inversionStyle) {
|
||||
scrollProps.style = [inversionStyle, this.props.style];
|
||||
}
|
||||
|
||||
this._hasMore =
|
||||
this.state.last < this.props.getItemCount(this.props.data) - 1;
|
||||
|
||||
const ret = React.cloneElement(
|
||||
(this.props.renderScrollComponent || this._defaultRenderScrollComponent)(
|
||||
scrollProps,
|
||||
@@ -805,15 +933,25 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
}
|
||||
|
||||
_averageCellLength = 0;
|
||||
// Maps a cell key to the set of keys for all outermost child lists within that cell
|
||||
_cellKeysToChildListKeys: Map<string, Set<string>> = new Map();
|
||||
_cellRefs = {};
|
||||
_hasDataChangedSinceEndReached = true;
|
||||
_hasWarned = {};
|
||||
_highestMeasuredFrameIndex = 0;
|
||||
_headerLength = 0;
|
||||
_initialScrollIndexTimeout = 0;
|
||||
_fillRateHelper: FillRateHelper;
|
||||
_frames = {};
|
||||
_footerLength = 0;
|
||||
_hasDataChangedSinceEndReached = true;
|
||||
_hasMore = false;
|
||||
_hasWarned = {};
|
||||
_highestMeasuredFrameIndex = 0;
|
||||
_headerLength = 0;
|
||||
_indicesToKeys: Map<number, string> = new Map();
|
||||
_initialScrollIndexTimeout = 0;
|
||||
_nestedChildLists: Map<
|
||||
string,
|
||||
{ref: ?VirtualizedList, state: ?ChildListState},
|
||||
> = new Map();
|
||||
_offsetFromParentVirtualizedList: number = 0;
|
||||
_prevParentOffset: number = 0;
|
||||
_scrollMetrics = {
|
||||
contentLength: 0,
|
||||
dOffset: 0,
|
||||
@@ -910,10 +1048,41 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
}
|
||||
};
|
||||
|
||||
_onLayout = (e: Object) => {
|
||||
this._scrollMetrics.visibleLength = this._selectLength(
|
||||
e.nativeEvent.layout,
|
||||
_measureLayoutRelativeToContainingList(): void {
|
||||
UIManager.measureLayout(
|
||||
ReactNative.findNodeHandle(this),
|
||||
ReactNative.findNodeHandle(
|
||||
this.context.virtualizedList.getOutermostParentListRef(),
|
||||
),
|
||||
error => {
|
||||
console.warn(
|
||||
"VirtualizedList: Encountered an error while measuring a list's" +
|
||||
' offset from its containing VirtualizedList.',
|
||||
);
|
||||
},
|
||||
(x, y, width, height) => {
|
||||
this._offsetFromParentVirtualizedList = this._selectOffset({x, y});
|
||||
this._scrollMetrics.contentLength = this._selectLength({width, height});
|
||||
|
||||
const scrollMetrics = this._convertParentScrollMetrics(
|
||||
this.context.virtualizedList.getScrollMetrics(),
|
||||
);
|
||||
this._scrollMetrics.visibleLength = scrollMetrics.visibleLength;
|
||||
this._scrollMetrics.offset = scrollMetrics.offset;
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
_onLayout = (e: Object) => {
|
||||
if (this._isNestedWithSameOrientation()) {
|
||||
// Need to adjust our scroll metrics to be relative to our containing
|
||||
// VirtualizedList before we can make claims about list item viewability
|
||||
this._measureLayoutRelativeToContainingList();
|
||||
} else {
|
||||
this._scrollMetrics.visibleLength = this._selectLength(
|
||||
e.nativeEvent.layout,
|
||||
);
|
||||
}
|
||||
this.props.onLayout && this.props.onLayout(e);
|
||||
this._scheduleCellsToRenderUpdate();
|
||||
this._maybeCallOnEndReached();
|
||||
@@ -1013,6 +1182,9 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
if (
|
||||
onEndReached &&
|
||||
this.state.last === getItemCount(data) - 1 &&
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses an
|
||||
* error found when Flow v0.63 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
distanceFromEnd < onEndReachedThreshold * visibleLength &&
|
||||
(this._hasDataChangedSinceEndReached ||
|
||||
this._scrollMetrics.contentLength !== this._sentEndForContentLength)
|
||||
@@ -1033,17 +1205,63 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
this._maybeCallOnEndReached();
|
||||
};
|
||||
|
||||
/* Translates metrics from a scroll event in a parent VirtualizedList into
|
||||
* coordinates relative to the child list.
|
||||
*/
|
||||
_convertParentScrollMetrics = (metrics: {
|
||||
visibleLength: number,
|
||||
offset: number,
|
||||
}) => {
|
||||
// Offset of the top of the nested list relative to the top of its parent's viewport
|
||||
const offset = metrics.offset - this._offsetFromParentVirtualizedList;
|
||||
// Child's visible length is the same as its parent's
|
||||
const visibleLength = metrics.visibleLength;
|
||||
const dOffset = offset - this._scrollMetrics.offset;
|
||||
const contentLength = this._scrollMetrics.contentLength;
|
||||
|
||||
return {
|
||||
visibleLength,
|
||||
contentLength,
|
||||
offset,
|
||||
dOffset,
|
||||
};
|
||||
};
|
||||
|
||||
_onScroll = (e: Object) => {
|
||||
this._nestedChildLists.forEach(childList => {
|
||||
childList.ref && childList.ref._onScroll(e);
|
||||
});
|
||||
if (this.props.onScroll) {
|
||||
this.props.onScroll(e);
|
||||
}
|
||||
const timestamp = e.timeStamp;
|
||||
const visibleLength = this._selectLength(e.nativeEvent.layoutMeasurement);
|
||||
const contentLength = this._selectLength(e.nativeEvent.contentSize);
|
||||
const offset = this._selectOffset(e.nativeEvent.contentOffset);
|
||||
let visibleLength = this._selectLength(e.nativeEvent.layoutMeasurement);
|
||||
let contentLength = this._selectLength(e.nativeEvent.contentSize);
|
||||
let offset = this._selectOffset(e.nativeEvent.contentOffset);
|
||||
let dOffset = offset - this._scrollMetrics.offset;
|
||||
|
||||
if (this._isNestedWithSameOrientation()) {
|
||||
if (this._scrollMetrics.contentLength === 0) {
|
||||
// Ignore scroll events until onLayout has been called and we
|
||||
// know our offset from our offset from our parent
|
||||
return;
|
||||
}
|
||||
({
|
||||
visibleLength,
|
||||
contentLength,
|
||||
offset,
|
||||
dOffset,
|
||||
} = this._convertParentScrollMetrics({
|
||||
visibleLength,
|
||||
offset,
|
||||
}));
|
||||
}
|
||||
|
||||
const dt = this._scrollMetrics.timestamp
|
||||
? Math.max(1, timestamp - this._scrollMetrics.timestamp)
|
||||
: 1;
|
||||
const velocity = dOffset / dt;
|
||||
|
||||
if (
|
||||
dt > 500 &&
|
||||
this._scrollMetrics.dt > 500 &&
|
||||
@@ -1058,8 +1276,6 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
);
|
||||
this._hasWarned.perf = true;
|
||||
}
|
||||
const dOffset = offset - this._scrollMetrics.offset;
|
||||
const velocity = dOffset / dt;
|
||||
this._scrollMetrics = {
|
||||
contentLength,
|
||||
dt,
|
||||
@@ -1091,6 +1307,9 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
const distBottom =
|
||||
this._getFrameMetricsApprox(last).offset - (offset + visibleLength);
|
||||
const scrollingThreshold =
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses an
|
||||
* error found when Flow v0.63 was deployed. To see the error delete
|
||||
* this comment and run Flow. */
|
||||
this.props.onEndReachedThreshold * visibleLength / 2;
|
||||
hiPri =
|
||||
Math.min(distTop, distBottom) < 0 ||
|
||||
@@ -1167,6 +1386,9 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
const {contentLength, offset, visibleLength} = this._scrollMetrics;
|
||||
const distanceFromEnd = contentLength - visibleLength - offset;
|
||||
const renderAhead =
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses
|
||||
* an error found when Flow v0.63 was deployed. To see the error
|
||||
* delete this comment and run Flow. */
|
||||
distanceFromEnd < onEndReachedThreshold * visibleLength
|
||||
? this.props.maxToRenderPerBatch
|
||||
: 0;
|
||||
@@ -1175,6 +1397,36 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
last: Math.min(state.last + renderAhead, getItemCount(data) - 1),
|
||||
};
|
||||
}
|
||||
if (newState && this._nestedChildLists.size > 0) {
|
||||
const newFirst = newState.first;
|
||||
const newLast = newState.last;
|
||||
// If some cell in the new state has a child list in it, we should only render
|
||||
// up through that item, so that we give that list a chance to render.
|
||||
// Otherwise there's churn from multiple child lists mounting and un-mounting
|
||||
// their items.
|
||||
for (let ii = newFirst; ii <= newLast; ii++) {
|
||||
const cellKeyForIndex = this._indicesToKeys.get(ii);
|
||||
const childListKeys =
|
||||
cellKeyForIndex &&
|
||||
this._cellKeysToChildListKeys.get(cellKeyForIndex);
|
||||
if (!childListKeys) {
|
||||
continue;
|
||||
}
|
||||
let someChildHasMore = false;
|
||||
// For each cell, need to check whether any child list in it has more elements to render
|
||||
for (let childKey of childListKeys) {
|
||||
const childList = this._nestedChildLists.get(childKey);
|
||||
if (childList && childList.ref && childList.ref.hasMore()) {
|
||||
someChildHasMore = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (someChildHasMore) {
|
||||
newState.last = ii;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return newState;
|
||||
});
|
||||
};
|
||||
@@ -1244,6 +1496,9 @@ class VirtualizedList extends React.PureComponent<Props, State> {
|
||||
}
|
||||
}
|
||||
}
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses an
|
||||
* error found when Flow v0.63 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
return frame;
|
||||
};
|
||||
|
||||
@@ -1292,6 +1547,20 @@ class CellRenderer extends React.Component<
|
||||
},
|
||||
};
|
||||
|
||||
static childContextTypes = {
|
||||
virtualizedCell: PropTypes.shape({
|
||||
cellKey: PropTypes.string,
|
||||
}),
|
||||
};
|
||||
|
||||
getChildContext() {
|
||||
return {
|
||||
virtualizedCell: {
|
||||
cellKey: this.props.cellKey,
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
// TODO: consider factoring separator stuff out of VirtualizedList into FlatList since it's not
|
||||
// reused by SectionList and we can keep VirtualizedList simpler.
|
||||
_separators = {
|
||||
@@ -1378,6 +1647,29 @@ class CellRenderer extends React.Component<
|
||||
}
|
||||
}
|
||||
|
||||
class VirtualizedCellWrapper extends React.Component<{
|
||||
cellKey: string,
|
||||
children: React.Node,
|
||||
}> {
|
||||
static childContextTypes = {
|
||||
virtualizedCell: PropTypes.shape({
|
||||
cellKey: PropTypes.string,
|
||||
}),
|
||||
};
|
||||
|
||||
getChildContext() {
|
||||
return {
|
||||
virtualizedCell: {
|
||||
cellKey: this.props.cellKey,
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
render() {
|
||||
return this.props.children;
|
||||
}
|
||||
}
|
||||
|
||||
const styles = StyleSheet.create({
|
||||
verticallyInverted: {
|
||||
transform: [{scaleY: -1}],
|
||||
|
||||
@@ -233,6 +233,9 @@ class VirtualizedSectionList<SectionT: SectionBase> extends React.PureComponent<
|
||||
return {
|
||||
...viewable,
|
||||
index: info.index,
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses an
|
||||
* error found when Flow v0.63 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
key: keyExtractor(viewable.item, info.index),
|
||||
section: info.section,
|
||||
};
|
||||
|
||||
@@ -89,6 +89,9 @@ module.exports = {
|
||||
|
||||
testBadSectionsShape(): React.Element<*> {
|
||||
const sections = [
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses an
|
||||
* error found when Flow v0.63 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
{
|
||||
key: 'a',
|
||||
items: [
|
||||
|
||||
@@ -81,4 +81,15 @@ describe('elementsThatOverlapOffsets', function() {
|
||||
elementsThatOverlapOffsets(offsets, frames.length, ii => frames[ii]),
|
||||
).toEqual([1]);
|
||||
});
|
||||
it('errors on non-increasing offsets', function() {
|
||||
const offsets = [150, 50];
|
||||
const frames = [
|
||||
{offset: 0, length: 50},
|
||||
{offset: 50, length: 150},
|
||||
{offset: 250, length: 100},
|
||||
];
|
||||
expect(() => {
|
||||
elementsThatOverlapOffsets(offsets, frames.length, ii => frames[ii]);
|
||||
}).toThrowErrorMatchingSnapshot();
|
||||
});
|
||||
});
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`elementsThatOverlapOffsets errors on non-increasing offsets 1`] = `"bad offsets input, should be in increasing order: [150,50]"`;
|
||||
@@ -10,7 +10,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
/* eslint-disable */
|
||||
/* globals Headers, Request, Response */
|
||||
|
||||
'use strict';
|
||||
|
||||
|
||||
@@ -186,13 +186,12 @@ expectErrorBlock:(BOOL(^)(NSString *error))expectErrorBlock
|
||||
[bridge invalidate];
|
||||
}
|
||||
|
||||
// Wait for bridge to disappear before continuing to the next test
|
||||
// Give the bridge a chance to disappear before continuing to the next test.
|
||||
NSDate *invalidateTimeout = [NSDate dateWithTimeIntervalSinceNow:30];
|
||||
while (invalidateTimeout.timeIntervalSinceNow > 0 && batchedBridge != nil) {
|
||||
[[NSRunLoop mainRunLoop] runMode:NSDefaultRunLoopMode beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]];
|
||||
[[NSRunLoop mainRunLoop] runMode:NSRunLoopCommonModes beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]];
|
||||
}
|
||||
RCTAssert(batchedBridge == nil, @"Bridge should be deallocated after the test");
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
@@ -33,6 +33,9 @@ function flattenStyle(style: ?StyleObj): ?Object {
|
||||
invariant(style !== true, 'style may be false but not true');
|
||||
|
||||
if (!Array.isArray(style)) {
|
||||
/* $FlowFixMe(>=0.63.0 site=react_native_fb) This comment suppresses an
|
||||
* error found when Flow v0.63 was deployed. To see the error delete this
|
||||
* comment and run Flow. */
|
||||
return getStyle(style);
|
||||
}
|
||||
|
||||
|
||||
@@ -16,10 +16,16 @@
|
||||
#import <React/RCTSurface.h>
|
||||
#import <React/RCTSurfaceView.h>
|
||||
|
||||
#import "RCTSurfaceHostingComponentController.h"
|
||||
#import "RCTSurfaceHostingComponentState.h"
|
||||
|
||||
@implementation RCTSurfaceHostingComponent
|
||||
|
||||
+ (Class<CKComponentControllerProtocol>)controllerClass
|
||||
{
|
||||
return [RCTSurfaceHostingComponentController class];
|
||||
}
|
||||
|
||||
+ (id)initialState
|
||||
{
|
||||
return [RCTSurfaceHostingComponentState new];
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
#import <React/RCTShadowView.h>
|
||||
|
||||
@interface RCTShadowRawText : RCTShadowView
|
||||
@interface RCTRawTextShadowView : RCTShadowView
|
||||
|
||||
@property (nonatomic, copy) NSString *text;
|
||||
|
||||
@@ -7,11 +7,11 @@
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTShadowRawText.h"
|
||||
#import "RCTRawTextShadowView.h"
|
||||
|
||||
#import <React/RCTUIManager.h>
|
||||
|
||||
@implementation RCTShadowRawText
|
||||
@implementation RCTRawTextShadowView
|
||||
|
||||
- (instancetype)init
|
||||
{
|
||||
@@ -9,6 +9,6 @@
|
||||
|
||||
#import <React/RCTViewManager.h>
|
||||
|
||||
@interface RCTRawTextManager : RCTViewManager
|
||||
@interface RCTRawTextViewManager : RCTViewManager
|
||||
|
||||
@end
|
||||
@@ -7,17 +7,17 @@
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTRawTextManager.h"
|
||||
#import "RCTRawTextViewManager.h"
|
||||
|
||||
#import "RCTShadowRawText.h"
|
||||
#import "RCTRawTextShadowView.h"
|
||||
|
||||
@implementation RCTRawTextManager
|
||||
@implementation RCTRawTextViewManager
|
||||
|
||||
RCT_EXPORT_MODULE()
|
||||
RCT_EXPORT_MODULE(RCTRawText)
|
||||
|
||||
- (RCTShadowView *)shadowView
|
||||
{
|
||||
return [RCTShadowRawText new];
|
||||
return [RCTRawTextShadowView new];
|
||||
}
|
||||
|
||||
RCT_EXPORT_SHADOW_PROPERTY(text, NSString)
|
||||
@@ -7,45 +7,86 @@
|
||||
objects = {
|
||||
|
||||
/* Begin PBXBuildFile section */
|
||||
131B6AC01AF0CD0600FFC3E0 /* RCTTextView.m in Sources */ = {isa = PBXBuildFile; fileRef = 131B6ABD1AF0CD0600FFC3E0 /* RCTTextView.m */; };
|
||||
131B6AC11AF0CD0600FFC3E0 /* RCTTextViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 131B6ABF1AF0CD0600FFC3E0 /* RCTTextViewManager.m */; };
|
||||
1362F1001B4D51F400E06D8C /* RCTTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = 1362F0FD1B4D51F400E06D8C /* RCTTextField.m */; };
|
||||
1362F1011B4D51F400E06D8C /* RCTTextFieldManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 1362F0FF1B4D51F400E06D8C /* RCTTextFieldManager.m */; };
|
||||
19FC5C851D41A4120090108F /* RCTTextSelection.m in Sources */ = {isa = PBXBuildFile; fileRef = 19FC5C841D41A4120090108F /* RCTTextSelection.m */; };
|
||||
2D3B5F331D9B102D00451313 /* RCTTextSelection.m in Sources */ = {isa = PBXBuildFile; fileRef = 19FC5C841D41A4120090108F /* RCTTextSelection.m */; };
|
||||
2D3B5F341D9B103100451313 /* RCTRawTextManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 58B511C71A9E6C5C00147676 /* RCTRawTextManager.m */; };
|
||||
2D3B5F351D9B103300451313 /* RCTShadowRawText.m in Sources */ = {isa = PBXBuildFile; fileRef = 58B511C91A9E6C5C00147676 /* RCTShadowRawText.m */; };
|
||||
2D3B5F361D9B106F00451313 /* RCTShadowText.m in Sources */ = {isa = PBXBuildFile; fileRef = 58B511CB1A9E6C5C00147676 /* RCTShadowText.m */; };
|
||||
2D3B5F371D9B106F00451313 /* RCTText.m in Sources */ = {isa = PBXBuildFile; fileRef = 58B512141A9E6EFF00147676 /* RCTText.m */; };
|
||||
2D3B5F381D9B106F00451313 /* RCTTextManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 58B511CD1A9E6C5C00147676 /* RCTTextManager.m */; };
|
||||
2D3B5F391D9B106F00451313 /* RCTTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = 1362F0FD1B4D51F400E06D8C /* RCTTextField.m */; };
|
||||
2D3B5F3A1D9B106F00451313 /* RCTTextFieldManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 1362F0FF1B4D51F400E06D8C /* RCTTextFieldManager.m */; };
|
||||
2D3B5F3B1D9B106F00451313 /* RCTTextView.m in Sources */ = {isa = PBXBuildFile; fileRef = 131B6ABD1AF0CD0600FFC3E0 /* RCTTextView.m */; };
|
||||
2D3B5F3C1D9B106F00451313 /* RCTTextViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 131B6ABF1AF0CD0600FFC3E0 /* RCTTextViewManager.m */; };
|
||||
2DEAB2901F84BA4300FC6B42 /* RCTFontAttributes.m in Sources */ = {isa = PBXBuildFile; fileRef = A85C82991F742AA20036C019 /* RCTFontAttributes.m */; };
|
||||
58B511CE1A9E6C5C00147676 /* RCTRawTextManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 58B511C71A9E6C5C00147676 /* RCTRawTextManager.m */; };
|
||||
58B511CF1A9E6C5C00147676 /* RCTShadowRawText.m in Sources */ = {isa = PBXBuildFile; fileRef = 58B511C91A9E6C5C00147676 /* RCTShadowRawText.m */; };
|
||||
58B511D01A9E6C5C00147676 /* RCTShadowText.m in Sources */ = {isa = PBXBuildFile; fileRef = 58B511CB1A9E6C5C00147676 /* RCTShadowText.m */; };
|
||||
58B511D11A9E6C5C00147676 /* RCTTextManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 58B511CD1A9E6C5C00147676 /* RCTTextManager.m */; };
|
||||
58B512161A9E6EFF00147676 /* RCTText.m in Sources */ = {isa = PBXBuildFile; fileRef = 58B512141A9E6EFF00147676 /* RCTText.m */; };
|
||||
598F41261F145D4900B8495B /* RCTBackedTextInputDelegateAdapter.m in Sources */ = {isa = PBXBuildFile; fileRef = 598F41251F145D4900B8495B /* RCTBackedTextInputDelegateAdapter.m */; };
|
||||
598F41271F145D4900B8495B /* RCTBackedTextInputDelegateAdapter.m in Sources */ = {isa = PBXBuildFile; fileRef = 598F41251F145D4900B8495B /* RCTBackedTextInputDelegateAdapter.m */; };
|
||||
599DF25F1F0306660079B53E /* RCTBackedTextInputViewProtocol.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 599DF25D1F0304B30079B53E /* RCTBackedTextInputViewProtocol.h */; };
|
||||
599DF2611F0306C30079B53E /* RCTBackedTextInputViewProtocol.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 599DF25D1F0304B30079B53E /* RCTBackedTextInputViewProtocol.h */; };
|
||||
599DF2641F03076D0079B53E /* RCTTextInput.m in Sources */ = {isa = PBXBuildFile; fileRef = 599DF2631F03076D0079B53E /* RCTTextInput.m */; };
|
||||
599DF2651F03076D0079B53E /* RCTTextInput.m in Sources */ = {isa = PBXBuildFile; fileRef = 599DF2631F03076D0079B53E /* RCTTextInput.m */; };
|
||||
599DF2661F0307D10079B53E /* RCTTextInput.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 599DF2621F03076D0079B53E /* RCTTextInput.h */; };
|
||||
599DF2671F0307D90079B53E /* RCTTextInput.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 599DF2621F03076D0079B53E /* RCTTextInput.h */; };
|
||||
59AF89AA1EDCBCC700F004B1 /* RCTUITextField.m in Sources */ = {isa = PBXBuildFile; fileRef = 59AF89A91EDCBCC700F004B1 /* RCTUITextField.m */; };
|
||||
59AF89AB1EDCBCC700F004B1 /* RCTUITextField.m in Sources */ = {isa = PBXBuildFile; fileRef = 59AF89A91EDCBCC700F004B1 /* RCTUITextField.m */; };
|
||||
59B125C91E6E4E15004E2A67 /* RCTUITextView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59B125C81E6E4E15004E2A67 /* RCTUITextView.m */; };
|
||||
59B125CA1E6E4E15004E2A67 /* RCTUITextView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59B125C81E6E4E15004E2A67 /* RCTUITextView.m */; };
|
||||
5989E14D20018A2200EA444A /* RCTBaseTextInputViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 5989E14C20018A2200EA444A /* RCTBaseTextInputViewManager.m */; };
|
||||
5989E14E20018A6600EA444A /* RCTBaseTextInputViewManager.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 5989E14B20018A2200EA444A /* RCTBaseTextInputViewManager.h */; };
|
||||
5989E14F20018A7800EA444A /* RCTBaseTextInputViewManager.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 5989E14B20018A2200EA444A /* RCTBaseTextInputViewManager.h */; };
|
||||
59E604521FE9CAF100BD90C5 /* RCTTextShadowView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E6042F1FE9CAF100BD90C5 /* RCTTextShadowView.m */; };
|
||||
59E604531FE9CAF100BD90C5 /* RCTTextShadowView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E6042F1FE9CAF100BD90C5 /* RCTTextShadowView.m */; };
|
||||
59E604541FE9CAF100BD90C5 /* RCTTextView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604311FE9CAF100BD90C5 /* RCTTextView.m */; };
|
||||
59E604551FE9CAF100BD90C5 /* RCTTextView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604311FE9CAF100BD90C5 /* RCTTextView.m */; };
|
||||
59E604561FE9CAF100BD90C5 /* RCTTextViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604331FE9CAF100BD90C5 /* RCTTextViewManager.m */; };
|
||||
59E604571FE9CAF100BD90C5 /* RCTTextViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604331FE9CAF100BD90C5 /* RCTTextViewManager.m */; };
|
||||
59E604581FE9CAF100BD90C5 /* RCTRawTextShadowView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604341FE9CAF100BD90C5 /* RCTRawTextShadowView.m */; };
|
||||
59E604591FE9CAF100BD90C5 /* RCTRawTextShadowView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604341FE9CAF100BD90C5 /* RCTRawTextShadowView.m */; };
|
||||
59E6045A1FE9CAF100BD90C5 /* RCTRawTextViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604361FE9CAF100BD90C5 /* RCTRawTextViewManager.m */; };
|
||||
59E6045B1FE9CAF100BD90C5 /* RCTRawTextViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604361FE9CAF100BD90C5 /* RCTRawTextViewManager.m */; };
|
||||
59E6045C1FE9CAF100BD90C5 /* RCTMultilineTextInputShadowView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E6043A1FE9CAF100BD90C5 /* RCTMultilineTextInputShadowView.m */; };
|
||||
59E6045D1FE9CAF100BD90C5 /* RCTMultilineTextInputShadowView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E6043A1FE9CAF100BD90C5 /* RCTMultilineTextInputShadowView.m */; };
|
||||
59E6045E1FE9CAF100BD90C5 /* RCTMultilineTextInputView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E6043C1FE9CAF100BD90C5 /* RCTMultilineTextInputView.m */; };
|
||||
59E6045F1FE9CAF100BD90C5 /* RCTMultilineTextInputView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E6043C1FE9CAF100BD90C5 /* RCTMultilineTextInputView.m */; };
|
||||
59E604601FE9CAF100BD90C5 /* RCTMultilineTextInputViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E6043E1FE9CAF100BD90C5 /* RCTMultilineTextInputViewManager.m */; };
|
||||
59E604611FE9CAF100BD90C5 /* RCTMultilineTextInputViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E6043E1FE9CAF100BD90C5 /* RCTMultilineTextInputViewManager.m */; };
|
||||
59E604621FE9CAF100BD90C5 /* RCTUITextView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604401FE9CAF100BD90C5 /* RCTUITextView.m */; };
|
||||
59E604631FE9CAF100BD90C5 /* RCTUITextView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604401FE9CAF100BD90C5 /* RCTUITextView.m */; };
|
||||
59E604641FE9CAF100BD90C5 /* RCTBackedTextInputDelegateAdapter.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604431FE9CAF100BD90C5 /* RCTBackedTextInputDelegateAdapter.m */; };
|
||||
59E604651FE9CAF100BD90C5 /* RCTBackedTextInputDelegateAdapter.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604431FE9CAF100BD90C5 /* RCTBackedTextInputDelegateAdapter.m */; };
|
||||
59E604661FE9CAF100BD90C5 /* RCTBaseTextInputView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604461FE9CAF100BD90C5 /* RCTBaseTextInputView.m */; };
|
||||
59E604671FE9CAF100BD90C5 /* RCTBaseTextInputView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604461FE9CAF100BD90C5 /* RCTBaseTextInputView.m */; };
|
||||
59E604681FE9CAF100BD90C5 /* RCTTextSelection.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604481FE9CAF100BD90C5 /* RCTTextSelection.m */; };
|
||||
59E604691FE9CAF100BD90C5 /* RCTTextSelection.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604481FE9CAF100BD90C5 /* RCTTextSelection.m */; };
|
||||
59E6046A1FE9CAF100BD90C5 /* RCTSinglelineTextInputShadowView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E6044B1FE9CAF100BD90C5 /* RCTSinglelineTextInputShadowView.m */; };
|
||||
59E6046B1FE9CAF100BD90C5 /* RCTSinglelineTextInputShadowView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E6044B1FE9CAF100BD90C5 /* RCTSinglelineTextInputShadowView.m */; };
|
||||
59E6046C1FE9CAF100BD90C5 /* RCTSinglelineTextInputView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E6044D1FE9CAF100BD90C5 /* RCTSinglelineTextInputView.m */; };
|
||||
59E6046D1FE9CAF100BD90C5 /* RCTSinglelineTextInputView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E6044D1FE9CAF100BD90C5 /* RCTSinglelineTextInputView.m */; };
|
||||
59E6046E1FE9CAF100BD90C5 /* RCTSinglelineTextInputViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E6044F1FE9CAF100BD90C5 /* RCTSinglelineTextInputViewManager.m */; };
|
||||
59E6046F1FE9CAF100BD90C5 /* RCTSinglelineTextInputViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E6044F1FE9CAF100BD90C5 /* RCTSinglelineTextInputViewManager.m */; };
|
||||
59E604701FE9CAF100BD90C5 /* RCTUITextField.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604511FE9CAF100BD90C5 /* RCTUITextField.m */; };
|
||||
59E604711FE9CAF100BD90C5 /* RCTUITextField.m in Sources */ = {isa = PBXBuildFile; fileRef = 59E604511FE9CAF100BD90C5 /* RCTUITextField.m */; };
|
||||
59E604721FE9CB3F00BD90C5 /* RCTConvert+Text.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = AF3225F71DE5574F00D3E7E7 /* RCTConvert+Text.h */; };
|
||||
59E604731FE9CB3F00BD90C5 /* RCTFontAttributes.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = A85C82981F742AA20036C019 /* RCTFontAttributes.h */; };
|
||||
59E604741FE9CB3F00BD90C5 /* RCTFontAttributesDelegate.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = A85C82BA1F742D8F0036C019 /* RCTFontAttributesDelegate.h */; };
|
||||
59E604751FE9CB3F00BD90C5 /* RCTRawTextShadowView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6042C1FE9CAF100BD90C5 /* RCTRawTextShadowView.h */; };
|
||||
59E604761FE9CB3F00BD90C5 /* RCTRawTextViewManager.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604351FE9CAF100BD90C5 /* RCTRawTextViewManager.h */; };
|
||||
59E604771FE9CB3F00BD90C5 /* RCTTextShadowView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6042E1FE9CAF100BD90C5 /* RCTTextShadowView.h */; };
|
||||
59E604781FE9CB3F00BD90C5 /* RCTTextView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604301FE9CAF100BD90C5 /* RCTTextView.h */; };
|
||||
59E604791FE9CB3F00BD90C5 /* RCTTextViewManager.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604321FE9CAF100BD90C5 /* RCTTextViewManager.h */; };
|
||||
59E6047A1FE9CB3F00BD90C5 /* RCTMultilineTextInputShadowView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604391FE9CAF100BD90C5 /* RCTMultilineTextInputShadowView.h */; };
|
||||
59E6047B1FE9CB3F00BD90C5 /* RCTMultilineTextInputView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6043B1FE9CAF100BD90C5 /* RCTMultilineTextInputView.h */; };
|
||||
59E6047C1FE9CB3F00BD90C5 /* RCTMultilineTextInputViewManager.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6043D1FE9CAF100BD90C5 /* RCTMultilineTextInputViewManager.h */; };
|
||||
59E6047D1FE9CB3F00BD90C5 /* RCTUITextView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6043F1FE9CAF100BD90C5 /* RCTUITextView.h */; };
|
||||
59E6047E1FE9CB3F00BD90C5 /* RCTBackedTextInputDelegate.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604411FE9CAF100BD90C5 /* RCTBackedTextInputDelegate.h */; };
|
||||
59E6047F1FE9CB3F00BD90C5 /* RCTBackedTextInputDelegateAdapter.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604421FE9CAF100BD90C5 /* RCTBackedTextInputDelegateAdapter.h */; };
|
||||
59E604801FE9CB3F00BD90C5 /* RCTBackedTextInputViewProtocol.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604441FE9CAF100BD90C5 /* RCTBackedTextInputViewProtocol.h */; };
|
||||
59E604811FE9CB3F00BD90C5 /* RCTBaseTextInputView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604451FE9CAF100BD90C5 /* RCTBaseTextInputView.h */; };
|
||||
59E604821FE9CB3F00BD90C5 /* RCTTextSelection.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604471FE9CAF100BD90C5 /* RCTTextSelection.h */; };
|
||||
59E604831FE9CB3F00BD90C5 /* RCTSinglelineTextInputShadowView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6044A1FE9CAF100BD90C5 /* RCTSinglelineTextInputShadowView.h */; };
|
||||
59E604841FE9CB3F00BD90C5 /* RCTSinglelineTextInputView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6044C1FE9CAF100BD90C5 /* RCTSinglelineTextInputView.h */; };
|
||||
59E604851FE9CB3F00BD90C5 /* RCTSinglelineTextInputViewManager.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6044E1FE9CAF100BD90C5 /* RCTSinglelineTextInputViewManager.h */; };
|
||||
59E604861FE9CB3F00BD90C5 /* RCTUITextField.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604501FE9CAF100BD90C5 /* RCTUITextField.h */; };
|
||||
59E604871FE9CB4A00BD90C5 /* RCTConvert+Text.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = AF3225F71DE5574F00D3E7E7 /* RCTConvert+Text.h */; };
|
||||
59E604881FE9CB4A00BD90C5 /* RCTFontAttributes.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = A85C82981F742AA20036C019 /* RCTFontAttributes.h */; };
|
||||
59E604891FE9CB4A00BD90C5 /* RCTFontAttributesDelegate.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = A85C82BA1F742D8F0036C019 /* RCTFontAttributesDelegate.h */; };
|
||||
59E6048A1FE9CB4A00BD90C5 /* RCTRawTextShadowView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6042C1FE9CAF100BD90C5 /* RCTRawTextShadowView.h */; };
|
||||
59E6048B1FE9CB4A00BD90C5 /* RCTRawTextViewManager.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604351FE9CAF100BD90C5 /* RCTRawTextViewManager.h */; };
|
||||
59E6048C1FE9CB4A00BD90C5 /* RCTTextShadowView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6042E1FE9CAF100BD90C5 /* RCTTextShadowView.h */; };
|
||||
59E6048D1FE9CB4A00BD90C5 /* RCTTextView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604301FE9CAF100BD90C5 /* RCTTextView.h */; };
|
||||
59E6048E1FE9CB4A00BD90C5 /* RCTTextViewManager.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604321FE9CAF100BD90C5 /* RCTTextViewManager.h */; };
|
||||
59E6048F1FE9CB4A00BD90C5 /* RCTMultilineTextInputShadowView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604391FE9CAF100BD90C5 /* RCTMultilineTextInputShadowView.h */; };
|
||||
59E604901FE9CB4A00BD90C5 /* RCTMultilineTextInputView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6043B1FE9CAF100BD90C5 /* RCTMultilineTextInputView.h */; };
|
||||
59E604911FE9CB4A00BD90C5 /* RCTMultilineTextInputViewManager.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6043D1FE9CAF100BD90C5 /* RCTMultilineTextInputViewManager.h */; };
|
||||
59E604921FE9CB4A00BD90C5 /* RCTUITextView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6043F1FE9CAF100BD90C5 /* RCTUITextView.h */; };
|
||||
59E604931FE9CB4A00BD90C5 /* RCTBackedTextInputDelegate.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604411FE9CAF100BD90C5 /* RCTBackedTextInputDelegate.h */; };
|
||||
59E604941FE9CB4A00BD90C5 /* RCTBackedTextInputDelegateAdapter.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604421FE9CAF100BD90C5 /* RCTBackedTextInputDelegateAdapter.h */; };
|
||||
59E604951FE9CB4A00BD90C5 /* RCTBackedTextInputViewProtocol.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604441FE9CAF100BD90C5 /* RCTBackedTextInputViewProtocol.h */; };
|
||||
59E604961FE9CB4A00BD90C5 /* RCTBaseTextInputView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604451FE9CAF100BD90C5 /* RCTBaseTextInputView.h */; };
|
||||
59E604971FE9CB4A00BD90C5 /* RCTTextSelection.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604471FE9CAF100BD90C5 /* RCTTextSelection.h */; };
|
||||
59E604981FE9CB4A00BD90C5 /* RCTSinglelineTextInputShadowView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6044A1FE9CAF100BD90C5 /* RCTSinglelineTextInputShadowView.h */; };
|
||||
59E604991FE9CB4A00BD90C5 /* RCTSinglelineTextInputView.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6044C1FE9CAF100BD90C5 /* RCTSinglelineTextInputView.h */; };
|
||||
59E6049A1FE9CB4A00BD90C5 /* RCTSinglelineTextInputViewManager.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E6044E1FE9CAF100BD90C5 /* RCTSinglelineTextInputViewManager.h */; };
|
||||
59E6049B1FE9CB4A00BD90C5 /* RCTUITextField.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = 59E604501FE9CAF100BD90C5 /* RCTUITextField.h */; };
|
||||
59E8C5CC1F8833D100204F5E /* RCTFontAttributes.m in Sources */ = {isa = PBXBuildFile; fileRef = A85C82991F742AA20036C019 /* RCTFontAttributes.m */; };
|
||||
59F60E911E661BDD0081153B /* RCTShadowTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = 59F60E8E1E661BDD0081153B /* RCTShadowTextField.m */; };
|
||||
59F60E921E661BDD0081153B /* RCTShadowTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = 59F60E8E1E661BDD0081153B /* RCTShadowTextField.m */; };
|
||||
59F60E931E661BDD0081153B /* RCTShadowTextView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59F60E901E661BDD0081153B /* RCTShadowTextView.m */; };
|
||||
59F60E941E661BDD0081153B /* RCTShadowTextView.m in Sources */ = {isa = PBXBuildFile; fileRef = 59F60E901E661BDD0081153B /* RCTShadowTextView.m */; };
|
||||
A85C829A1F742AA20036C019 /* RCTFontAttributes.m in Sources */ = {isa = PBXBuildFile; fileRef = A85C82991F742AA20036C019 /* RCTFontAttributes.m */; };
|
||||
AD50D1DF20067E6F00A34797 /* RCTBaseTextInputViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 5989E14C20018A2200EA444A /* RCTBaseTextInputViewManager.m */; };
|
||||
AF3225F91DE5574F00D3E7E7 /* RCTConvert+Text.m in Sources */ = {isa = PBXBuildFile; fileRef = AF3225F81DE5574F00D3E7E7 /* RCTConvert+Text.m */; };
|
||||
AF3225FA1DE5574F00D3E7E7 /* RCTConvert+Text.m in Sources */ = {isa = PBXBuildFile; fileRef = AF3225F81DE5574F00D3E7E7 /* RCTConvert+Text.m */; };
|
||||
/* End PBXBuildFile section */
|
||||
@@ -57,8 +98,28 @@
|
||||
dstPath = include/RCTText;
|
||||
dstSubfolderSpec = 16;
|
||||
files = (
|
||||
599DF2671F0307D90079B53E /* RCTTextInput.h in Copy Headers */,
|
||||
599DF25F1F0306660079B53E /* RCTBackedTextInputViewProtocol.h in Copy Headers */,
|
||||
5989E14E20018A6600EA444A /* RCTBaseTextInputViewManager.h in Copy Headers */,
|
||||
59E604871FE9CB4A00BD90C5 /* RCTConvert+Text.h in Copy Headers */,
|
||||
59E604881FE9CB4A00BD90C5 /* RCTFontAttributes.h in Copy Headers */,
|
||||
59E604891FE9CB4A00BD90C5 /* RCTFontAttributesDelegate.h in Copy Headers */,
|
||||
59E6048A1FE9CB4A00BD90C5 /* RCTRawTextShadowView.h in Copy Headers */,
|
||||
59E6048B1FE9CB4A00BD90C5 /* RCTRawTextViewManager.h in Copy Headers */,
|
||||
59E6048C1FE9CB4A00BD90C5 /* RCTTextShadowView.h in Copy Headers */,
|
||||
59E6048D1FE9CB4A00BD90C5 /* RCTTextView.h in Copy Headers */,
|
||||
59E6048E1FE9CB4A00BD90C5 /* RCTTextViewManager.h in Copy Headers */,
|
||||
59E6048F1FE9CB4A00BD90C5 /* RCTMultilineTextInputShadowView.h in Copy Headers */,
|
||||
59E604901FE9CB4A00BD90C5 /* RCTMultilineTextInputView.h in Copy Headers */,
|
||||
59E604911FE9CB4A00BD90C5 /* RCTMultilineTextInputViewManager.h in Copy Headers */,
|
||||
59E604921FE9CB4A00BD90C5 /* RCTUITextView.h in Copy Headers */,
|
||||
59E604931FE9CB4A00BD90C5 /* RCTBackedTextInputDelegate.h in Copy Headers */,
|
||||
59E604941FE9CB4A00BD90C5 /* RCTBackedTextInputDelegateAdapter.h in Copy Headers */,
|
||||
59E604951FE9CB4A00BD90C5 /* RCTBackedTextInputViewProtocol.h in Copy Headers */,
|
||||
59E604961FE9CB4A00BD90C5 /* RCTBaseTextInputView.h in Copy Headers */,
|
||||
59E604971FE9CB4A00BD90C5 /* RCTTextSelection.h in Copy Headers */,
|
||||
59E604981FE9CB4A00BD90C5 /* RCTSinglelineTextInputShadowView.h in Copy Headers */,
|
||||
59E604991FE9CB4A00BD90C5 /* RCTSinglelineTextInputView.h in Copy Headers */,
|
||||
59E6049A1FE9CB4A00BD90C5 /* RCTSinglelineTextInputViewManager.h in Copy Headers */,
|
||||
59E6049B1FE9CB4A00BD90C5 /* RCTUITextField.h in Copy Headers */,
|
||||
);
|
||||
name = "Copy Headers";
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
@@ -69,8 +130,28 @@
|
||||
dstPath = include/RCTText;
|
||||
dstSubfolderSpec = 16;
|
||||
files = (
|
||||
599DF2661F0307D10079B53E /* RCTTextInput.h in Copy Headers */,
|
||||
599DF2611F0306C30079B53E /* RCTBackedTextInputViewProtocol.h in Copy Headers */,
|
||||
5989E14F20018A7800EA444A /* RCTBaseTextInputViewManager.h in Copy Headers */,
|
||||
59E604721FE9CB3F00BD90C5 /* RCTConvert+Text.h in Copy Headers */,
|
||||
59E604731FE9CB3F00BD90C5 /* RCTFontAttributes.h in Copy Headers */,
|
||||
59E604741FE9CB3F00BD90C5 /* RCTFontAttributesDelegate.h in Copy Headers */,
|
||||
59E604751FE9CB3F00BD90C5 /* RCTRawTextShadowView.h in Copy Headers */,
|
||||
59E604761FE9CB3F00BD90C5 /* RCTRawTextViewManager.h in Copy Headers */,
|
||||
59E604771FE9CB3F00BD90C5 /* RCTTextShadowView.h in Copy Headers */,
|
||||
59E604781FE9CB3F00BD90C5 /* RCTTextView.h in Copy Headers */,
|
||||
59E604791FE9CB3F00BD90C5 /* RCTTextViewManager.h in Copy Headers */,
|
||||
59E6047A1FE9CB3F00BD90C5 /* RCTMultilineTextInputShadowView.h in Copy Headers */,
|
||||
59E6047B1FE9CB3F00BD90C5 /* RCTMultilineTextInputView.h in Copy Headers */,
|
||||
59E6047C1FE9CB3F00BD90C5 /* RCTMultilineTextInputViewManager.h in Copy Headers */,
|
||||
59E6047D1FE9CB3F00BD90C5 /* RCTUITextView.h in Copy Headers */,
|
||||
59E6047E1FE9CB3F00BD90C5 /* RCTBackedTextInputDelegate.h in Copy Headers */,
|
||||
59E6047F1FE9CB3F00BD90C5 /* RCTBackedTextInputDelegateAdapter.h in Copy Headers */,
|
||||
59E604801FE9CB3F00BD90C5 /* RCTBackedTextInputViewProtocol.h in Copy Headers */,
|
||||
59E604811FE9CB3F00BD90C5 /* RCTBaseTextInputView.h in Copy Headers */,
|
||||
59E604821FE9CB3F00BD90C5 /* RCTTextSelection.h in Copy Headers */,
|
||||
59E604831FE9CB3F00BD90C5 /* RCTSinglelineTextInputShadowView.h in Copy Headers */,
|
||||
59E604841FE9CB3F00BD90C5 /* RCTSinglelineTextInputView.h in Copy Headers */,
|
||||
59E604851FE9CB3F00BD90C5 /* RCTSinglelineTextInputViewManager.h in Copy Headers */,
|
||||
59E604861FE9CB3F00BD90C5 /* RCTUITextField.h in Copy Headers */,
|
||||
);
|
||||
name = "Copy Headers";
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
@@ -78,42 +159,44 @@
|
||||
/* End PBXCopyFilesBuildPhase section */
|
||||
|
||||
/* Begin PBXFileReference section */
|
||||
131B6ABC1AF0CD0600FFC3E0 /* RCTTextView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTTextView.h; sourceTree = "<group>"; };
|
||||
131B6ABD1AF0CD0600FFC3E0 /* RCTTextView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTTextView.m; sourceTree = "<group>"; };
|
||||
131B6ABE1AF0CD0600FFC3E0 /* RCTTextViewManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTTextViewManager.h; sourceTree = "<group>"; };
|
||||
131B6ABF1AF0CD0600FFC3E0 /* RCTTextViewManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTTextViewManager.m; sourceTree = "<group>"; };
|
||||
1362F0FC1B4D51F400E06D8C /* RCTTextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTTextField.h; sourceTree = "<group>"; };
|
||||
1362F0FD1B4D51F400E06D8C /* RCTTextField.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTTextField.m; sourceTree = "<group>"; };
|
||||
1362F0FE1B4D51F400E06D8C /* RCTTextFieldManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTTextFieldManager.h; sourceTree = "<group>"; };
|
||||
1362F0FF1B4D51F400E06D8C /* RCTTextFieldManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTTextFieldManager.m; sourceTree = "<group>"; };
|
||||
19FC5C841D41A4120090108F /* RCTTextSelection.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTTextSelection.m; sourceTree = "<group>"; };
|
||||
19FC5C861D41A4220090108F /* RCTTextSelection.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTTextSelection.h; sourceTree = "<group>"; };
|
||||
2D2A287B1D9B048500D4039D /* libRCTText-tvOS.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libRCTText-tvOS.a"; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
58B5119B1A9E6C1200147676 /* libRCTText.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libRCTText.a; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
58B511C61A9E6C5C00147676 /* RCTRawTextManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTRawTextManager.h; sourceTree = "<group>"; };
|
||||
58B511C71A9E6C5C00147676 /* RCTRawTextManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTRawTextManager.m; sourceTree = "<group>"; };
|
||||
58B511C81A9E6C5C00147676 /* RCTShadowRawText.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTShadowRawText.h; sourceTree = "<group>"; };
|
||||
58B511C91A9E6C5C00147676 /* RCTShadowRawText.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTShadowRawText.m; sourceTree = "<group>"; };
|
||||
58B511CA1A9E6C5C00147676 /* RCTShadowText.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTShadowText.h; sourceTree = "<group>"; };
|
||||
58B511CB1A9E6C5C00147676 /* RCTShadowText.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTShadowText.m; sourceTree = "<group>"; };
|
||||
58B511CC1A9E6C5C00147676 /* RCTTextManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTTextManager.h; sourceTree = "<group>"; };
|
||||
58B511CD1A9E6C5C00147676 /* RCTTextManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTTextManager.m; sourceTree = "<group>"; };
|
||||
58B512141A9E6EFF00147676 /* RCTText.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTText.m; sourceTree = "<group>"; };
|
||||
58B512151A9E6EFF00147676 /* RCTText.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTText.h; sourceTree = "<group>"; };
|
||||
598F41231F145D4900B8495B /* RCTBackedTextInputDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTBackedTextInputDelegate.h; sourceTree = "<group>"; };
|
||||
598F41241F145D4900B8495B /* RCTBackedTextInputDelegateAdapter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTBackedTextInputDelegateAdapter.h; sourceTree = "<group>"; };
|
||||
598F41251F145D4900B8495B /* RCTBackedTextInputDelegateAdapter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTBackedTextInputDelegateAdapter.m; sourceTree = "<group>"; };
|
||||
599DF25D1F0304B30079B53E /* RCTBackedTextInputViewProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTBackedTextInputViewProtocol.h; sourceTree = "<group>"; };
|
||||
599DF2621F03076D0079B53E /* RCTTextInput.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTTextInput.h; sourceTree = "<group>"; };
|
||||
599DF2631F03076D0079B53E /* RCTTextInput.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTTextInput.m; sourceTree = "<group>"; };
|
||||
59AF89A81EDCBCC700F004B1 /* RCTUITextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTUITextField.h; sourceTree = "<group>"; };
|
||||
59AF89A91EDCBCC700F004B1 /* RCTUITextField.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTUITextField.m; sourceTree = "<group>"; };
|
||||
59B125C71E6E4E15004E2A67 /* RCTUITextView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTUITextView.h; sourceTree = "<group>"; };
|
||||
59B125C81E6E4E15004E2A67 /* RCTUITextView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTUITextView.m; sourceTree = "<group>"; };
|
||||
59F60E8D1E661BDD0081153B /* RCTShadowTextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTShadowTextField.h; sourceTree = "<group>"; };
|
||||
59F60E8E1E661BDD0081153B /* RCTShadowTextField.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTShadowTextField.m; sourceTree = "<group>"; };
|
||||
59F60E8F1E661BDD0081153B /* RCTShadowTextView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTShadowTextView.h; sourceTree = "<group>"; };
|
||||
59F60E901E661BDD0081153B /* RCTShadowTextView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTShadowTextView.m; sourceTree = "<group>"; };
|
||||
5989E14B20018A2200EA444A /* RCTBaseTextInputViewManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTBaseTextInputViewManager.h; sourceTree = "<group>"; };
|
||||
5989E14C20018A2200EA444A /* RCTBaseTextInputViewManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTBaseTextInputViewManager.m; sourceTree = "<group>"; };
|
||||
59E6042C1FE9CAF100BD90C5 /* RCTRawTextShadowView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTRawTextShadowView.h; sourceTree = "<group>"; };
|
||||
59E6042E1FE9CAF100BD90C5 /* RCTTextShadowView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTTextShadowView.h; sourceTree = "<group>"; };
|
||||
59E6042F1FE9CAF100BD90C5 /* RCTTextShadowView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTTextShadowView.m; sourceTree = "<group>"; };
|
||||
59E604301FE9CAF100BD90C5 /* RCTTextView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTTextView.h; sourceTree = "<group>"; };
|
||||
59E604311FE9CAF100BD90C5 /* RCTTextView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTTextView.m; sourceTree = "<group>"; };
|
||||
59E604321FE9CAF100BD90C5 /* RCTTextViewManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTTextViewManager.h; sourceTree = "<group>"; };
|
||||
59E604331FE9CAF100BD90C5 /* RCTTextViewManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTTextViewManager.m; sourceTree = "<group>"; };
|
||||
59E604341FE9CAF100BD90C5 /* RCTRawTextShadowView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTRawTextShadowView.m; sourceTree = "<group>"; };
|
||||
59E604351FE9CAF100BD90C5 /* RCTRawTextViewManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTRawTextViewManager.h; sourceTree = "<group>"; };
|
||||
59E604361FE9CAF100BD90C5 /* RCTRawTextViewManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTRawTextViewManager.m; sourceTree = "<group>"; };
|
||||
59E604391FE9CAF100BD90C5 /* RCTMultilineTextInputShadowView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMultilineTextInputShadowView.h; sourceTree = "<group>"; };
|
||||
59E6043A1FE9CAF100BD90C5 /* RCTMultilineTextInputShadowView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMultilineTextInputShadowView.m; sourceTree = "<group>"; };
|
||||
59E6043B1FE9CAF100BD90C5 /* RCTMultilineTextInputView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMultilineTextInputView.h; sourceTree = "<group>"; };
|
||||
59E6043C1FE9CAF100BD90C5 /* RCTMultilineTextInputView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMultilineTextInputView.m; sourceTree = "<group>"; };
|
||||
59E6043D1FE9CAF100BD90C5 /* RCTMultilineTextInputViewManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMultilineTextInputViewManager.h; sourceTree = "<group>"; };
|
||||
59E6043E1FE9CAF100BD90C5 /* RCTMultilineTextInputViewManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMultilineTextInputViewManager.m; sourceTree = "<group>"; };
|
||||
59E6043F1FE9CAF100BD90C5 /* RCTUITextView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTUITextView.h; sourceTree = "<group>"; };
|
||||
59E604401FE9CAF100BD90C5 /* RCTUITextView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTUITextView.m; sourceTree = "<group>"; };
|
||||
59E604411FE9CAF100BD90C5 /* RCTBackedTextInputDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTBackedTextInputDelegate.h; sourceTree = "<group>"; };
|
||||
59E604421FE9CAF100BD90C5 /* RCTBackedTextInputDelegateAdapter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTBackedTextInputDelegateAdapter.h; sourceTree = "<group>"; };
|
||||
59E604431FE9CAF100BD90C5 /* RCTBackedTextInputDelegateAdapter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTBackedTextInputDelegateAdapter.m; sourceTree = "<group>"; };
|
||||
59E604441FE9CAF100BD90C5 /* RCTBackedTextInputViewProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTBackedTextInputViewProtocol.h; sourceTree = "<group>"; };
|
||||
59E604451FE9CAF100BD90C5 /* RCTBaseTextInputView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTBaseTextInputView.h; sourceTree = "<group>"; };
|
||||
59E604461FE9CAF100BD90C5 /* RCTBaseTextInputView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTBaseTextInputView.m; sourceTree = "<group>"; };
|
||||
59E604471FE9CAF100BD90C5 /* RCTTextSelection.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTTextSelection.h; sourceTree = "<group>"; };
|
||||
59E604481FE9CAF100BD90C5 /* RCTTextSelection.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTTextSelection.m; sourceTree = "<group>"; };
|
||||
59E6044A1FE9CAF100BD90C5 /* RCTSinglelineTextInputShadowView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTSinglelineTextInputShadowView.h; sourceTree = "<group>"; };
|
||||
59E6044B1FE9CAF100BD90C5 /* RCTSinglelineTextInputShadowView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTSinglelineTextInputShadowView.m; sourceTree = "<group>"; };
|
||||
59E6044C1FE9CAF100BD90C5 /* RCTSinglelineTextInputView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTSinglelineTextInputView.h; sourceTree = "<group>"; };
|
||||
59E6044D1FE9CAF100BD90C5 /* RCTSinglelineTextInputView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTSinglelineTextInputView.m; sourceTree = "<group>"; };
|
||||
59E6044E1FE9CAF100BD90C5 /* RCTSinglelineTextInputViewManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTSinglelineTextInputViewManager.h; sourceTree = "<group>"; };
|
||||
59E6044F1FE9CAF100BD90C5 /* RCTSinglelineTextInputViewManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTSinglelineTextInputViewManager.m; sourceTree = "<group>"; };
|
||||
59E604501FE9CAF100BD90C5 /* RCTUITextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTUITextField.h; sourceTree = "<group>"; };
|
||||
59E604511FE9CAF100BD90C5 /* RCTUITextField.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTUITextField.m; sourceTree = "<group>"; };
|
||||
A85C82981F742AA20036C019 /* RCTFontAttributes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTFontAttributes.h; sourceTree = "<group>"; };
|
||||
A85C82991F742AA20036C019 /* RCTFontAttributes.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTFontAttributes.m; sourceTree = "<group>"; };
|
||||
A85C82BA1F742D8F0036C019 /* RCTFontAttributesDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTFontAttributesDelegate.h; sourceTree = "<group>"; };
|
||||
@@ -126,45 +209,17 @@
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
58B5119C1A9E6C1200147676 /* Products */,
|
||||
598F41231F145D4900B8495B /* RCTBackedTextInputDelegate.h */,
|
||||
598F41241F145D4900B8495B /* RCTBackedTextInputDelegateAdapter.h */,
|
||||
598F41251F145D4900B8495B /* RCTBackedTextInputDelegateAdapter.m */,
|
||||
599DF25D1F0304B30079B53E /* RCTBackedTextInputViewProtocol.h */,
|
||||
AF3225F71DE5574F00D3E7E7 /* RCTConvert+Text.h */,
|
||||
AF3225F81DE5574F00D3E7E7 /* RCTConvert+Text.m */,
|
||||
A85C82981F742AA20036C019 /* RCTFontAttributes.h */,
|
||||
A85C82991F742AA20036C019 /* RCTFontAttributes.m */,
|
||||
A85C82BA1F742D8F0036C019 /* RCTFontAttributesDelegate.h */,
|
||||
58B511C61A9E6C5C00147676 /* RCTRawTextManager.h */,
|
||||
58B511C71A9E6C5C00147676 /* RCTRawTextManager.m */,
|
||||
58B511C81A9E6C5C00147676 /* RCTShadowRawText.h */,
|
||||
58B511C91A9E6C5C00147676 /* RCTShadowRawText.m */,
|
||||
58B511CA1A9E6C5C00147676 /* RCTShadowText.h */,
|
||||
58B511CB1A9E6C5C00147676 /* RCTShadowText.m */,
|
||||
59F60E8D1E661BDD0081153B /* RCTShadowTextField.h */,
|
||||
59F60E8E1E661BDD0081153B /* RCTShadowTextField.m */,
|
||||
59F60E8F1E661BDD0081153B /* RCTShadowTextView.h */,
|
||||
59F60E901E661BDD0081153B /* RCTShadowTextView.m */,
|
||||
58B512151A9E6EFF00147676 /* RCTText.h */,
|
||||
58B512141A9E6EFF00147676 /* RCTText.m */,
|
||||
1362F0FC1B4D51F400E06D8C /* RCTTextField.h */,
|
||||
1362F0FD1B4D51F400E06D8C /* RCTTextField.m */,
|
||||
1362F0FE1B4D51F400E06D8C /* RCTTextFieldManager.h */,
|
||||
1362F0FF1B4D51F400E06D8C /* RCTTextFieldManager.m */,
|
||||
599DF2621F03076D0079B53E /* RCTTextInput.h */,
|
||||
599DF2631F03076D0079B53E /* RCTTextInput.m */,
|
||||
58B511CC1A9E6C5C00147676 /* RCTTextManager.h */,
|
||||
58B511CD1A9E6C5C00147676 /* RCTTextManager.m */,
|
||||
19FC5C861D41A4220090108F /* RCTTextSelection.h */,
|
||||
19FC5C841D41A4120090108F /* RCTTextSelection.m */,
|
||||
131B6ABC1AF0CD0600FFC3E0 /* RCTTextView.h */,
|
||||
131B6ABD1AF0CD0600FFC3E0 /* RCTTextView.m */,
|
||||
131B6ABE1AF0CD0600FFC3E0 /* RCTTextViewManager.h */,
|
||||
131B6ABF1AF0CD0600FFC3E0 /* RCTTextViewManager.m */,
|
||||
59AF89A81EDCBCC700F004B1 /* RCTUITextField.h */,
|
||||
59AF89A91EDCBCC700F004B1 /* RCTUITextField.m */,
|
||||
59B125C71E6E4E15004E2A67 /* RCTUITextView.h */,
|
||||
59B125C81E6E4E15004E2A67 /* RCTUITextView.m */,
|
||||
59E6042C1FE9CAF100BD90C5 /* RCTRawTextShadowView.h */,
|
||||
59E604341FE9CAF100BD90C5 /* RCTRawTextShadowView.m */,
|
||||
59E604351FE9CAF100BD90C5 /* RCTRawTextViewManager.h */,
|
||||
59E604361FE9CAF100BD90C5 /* RCTRawTextViewManager.m */,
|
||||
59E6042D1FE9CAF100BD90C5 /* Text */,
|
||||
59E604371FE9CAF100BD90C5 /* TextInput */,
|
||||
);
|
||||
indentWidth = 2;
|
||||
sourceTree = "<group>";
|
||||
@@ -180,6 +235,68 @@
|
||||
name = Products;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
59E6042D1FE9CAF100BD90C5 /* Text */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
59E6042E1FE9CAF100BD90C5 /* RCTTextShadowView.h */,
|
||||
59E6042F1FE9CAF100BD90C5 /* RCTTextShadowView.m */,
|
||||
59E604301FE9CAF100BD90C5 /* RCTTextView.h */,
|
||||
59E604311FE9CAF100BD90C5 /* RCTTextView.m */,
|
||||
59E604321FE9CAF100BD90C5 /* RCTTextViewManager.h */,
|
||||
59E604331FE9CAF100BD90C5 /* RCTTextViewManager.m */,
|
||||
);
|
||||
path = Text;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
59E604371FE9CAF100BD90C5 /* TextInput */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
59E604381FE9CAF100BD90C5 /* Multiline */,
|
||||
59E604411FE9CAF100BD90C5 /* RCTBackedTextInputDelegate.h */,
|
||||
59E604421FE9CAF100BD90C5 /* RCTBackedTextInputDelegateAdapter.h */,
|
||||
59E604431FE9CAF100BD90C5 /* RCTBackedTextInputDelegateAdapter.m */,
|
||||
59E604441FE9CAF100BD90C5 /* RCTBackedTextInputViewProtocol.h */,
|
||||
59E604451FE9CAF100BD90C5 /* RCTBaseTextInputView.h */,
|
||||
59E604461FE9CAF100BD90C5 /* RCTBaseTextInputView.m */,
|
||||
5989E14B20018A2200EA444A /* RCTBaseTextInputViewManager.h */,
|
||||
5989E14C20018A2200EA444A /* RCTBaseTextInputViewManager.m */,
|
||||
59E604471FE9CAF100BD90C5 /* RCTTextSelection.h */,
|
||||
59E604481FE9CAF100BD90C5 /* RCTTextSelection.m */,
|
||||
59E604491FE9CAF100BD90C5 /* Singleline */,
|
||||
);
|
||||
path = TextInput;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
59E604381FE9CAF100BD90C5 /* Multiline */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
59E604391FE9CAF100BD90C5 /* RCTMultilineTextInputShadowView.h */,
|
||||
59E6043A1FE9CAF100BD90C5 /* RCTMultilineTextInputShadowView.m */,
|
||||
59E6043B1FE9CAF100BD90C5 /* RCTMultilineTextInputView.h */,
|
||||
59E6043C1FE9CAF100BD90C5 /* RCTMultilineTextInputView.m */,
|
||||
59E6043D1FE9CAF100BD90C5 /* RCTMultilineTextInputViewManager.h */,
|
||||
59E6043E1FE9CAF100BD90C5 /* RCTMultilineTextInputViewManager.m */,
|
||||
59E6043F1FE9CAF100BD90C5 /* RCTUITextView.h */,
|
||||
59E604401FE9CAF100BD90C5 /* RCTUITextView.m */,
|
||||
);
|
||||
path = Multiline;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
59E604491FE9CAF100BD90C5 /* Singleline */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
59E6044A1FE9CAF100BD90C5 /* RCTSinglelineTextInputShadowView.h */,
|
||||
59E6044B1FE9CAF100BD90C5 /* RCTSinglelineTextInputShadowView.m */,
|
||||
59E6044C1FE9CAF100BD90C5 /* RCTSinglelineTextInputView.h */,
|
||||
59E6044D1FE9CAF100BD90C5 /* RCTSinglelineTextInputView.m */,
|
||||
59E6044E1FE9CAF100BD90C5 /* RCTSinglelineTextInputViewManager.h */,
|
||||
59E6044F1FE9CAF100BD90C5 /* RCTSinglelineTextInputViewManager.m */,
|
||||
59E604501FE9CAF100BD90C5 /* RCTUITextField.h */,
|
||||
59E604511FE9CAF100BD90C5 /* RCTUITextField.m */,
|
||||
);
|
||||
path = Singleline;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
/* End PBXGroup section */
|
||||
|
||||
/* Begin PBXNativeTarget section */
|
||||
@@ -256,24 +373,25 @@
|
||||
isa = PBXSourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
2D3B5F371D9B106F00451313 /* RCTText.m in Sources */,
|
||||
2D3B5F381D9B106F00451313 /* RCTTextManager.m in Sources */,
|
||||
2D3B5F391D9B106F00451313 /* RCTTextField.m in Sources */,
|
||||
2D3B5F361D9B106F00451313 /* RCTShadowText.m in Sources */,
|
||||
2D3B5F3B1D9B106F00451313 /* RCTTextView.m in Sources */,
|
||||
59AF89AB1EDCBCC700F004B1 /* RCTUITextField.m in Sources */,
|
||||
598F41271F145D4900B8495B /* RCTBackedTextInputDelegateAdapter.m in Sources */,
|
||||
59E6046F1FE9CAF100BD90C5 /* RCTSinglelineTextInputViewManager.m in Sources */,
|
||||
59E604671FE9CAF100BD90C5 /* RCTBaseTextInputView.m in Sources */,
|
||||
59E604631FE9CAF100BD90C5 /* RCTUITextView.m in Sources */,
|
||||
59E604571FE9CAF100BD90C5 /* RCTTextViewManager.m in Sources */,
|
||||
59E604531FE9CAF100BD90C5 /* RCTTextShadowView.m in Sources */,
|
||||
59E6045D1FE9CAF100BD90C5 /* RCTMultilineTextInputShadowView.m in Sources */,
|
||||
59E604591FE9CAF100BD90C5 /* RCTRawTextShadowView.m in Sources */,
|
||||
59E604551FE9CAF100BD90C5 /* RCTTextView.m in Sources */,
|
||||
AD50D1DF20067E6F00A34797 /* RCTBaseTextInputViewManager.m in Sources */,
|
||||
59E604691FE9CAF100BD90C5 /* RCTTextSelection.m in Sources */,
|
||||
59E6045F1FE9CAF100BD90C5 /* RCTMultilineTextInputView.m in Sources */,
|
||||
59E604611FE9CAF100BD90C5 /* RCTMultilineTextInputViewManager.m in Sources */,
|
||||
59E604711FE9CAF100BD90C5 /* RCTUITextField.m in Sources */,
|
||||
59E6046D1FE9CAF100BD90C5 /* RCTSinglelineTextInputView.m in Sources */,
|
||||
59E8C5CC1F8833D100204F5E /* RCTFontAttributes.m in Sources */,
|
||||
2D3B5F3A1D9B106F00451313 /* RCTTextFieldManager.m in Sources */,
|
||||
599DF2651F03076D0079B53E /* RCTTextInput.m in Sources */,
|
||||
2D3B5F341D9B103100451313 /* RCTRawTextManager.m in Sources */,
|
||||
59F60E921E661BDD0081153B /* RCTShadowTextField.m in Sources */,
|
||||
59E6045B1FE9CAF100BD90C5 /* RCTRawTextViewManager.m in Sources */,
|
||||
59E604651FE9CAF100BD90C5 /* RCTBackedTextInputDelegateAdapter.m in Sources */,
|
||||
AF3225FA1DE5574F00D3E7E7 /* RCTConvert+Text.m in Sources */,
|
||||
59B125CA1E6E4E15004E2A67 /* RCTUITextView.m in Sources */,
|
||||
2D3B5F3C1D9B106F00451313 /* RCTTextViewManager.m in Sources */,
|
||||
59F60E941E661BDD0081153B /* RCTShadowTextView.m in Sources */,
|
||||
2D3B5F331D9B102D00451313 /* RCTTextSelection.m in Sources */,
|
||||
2D3B5F351D9B103300451313 /* RCTShadowRawText.m in Sources */,
|
||||
59E6046B1FE9CAF100BD90C5 /* RCTSinglelineTextInputShadowView.m in Sources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
@@ -281,24 +399,25 @@
|
||||
isa = PBXSourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
58B511D11A9E6C5C00147676 /* RCTTextManager.m in Sources */,
|
||||
131B6AC01AF0CD0600FFC3E0 /* RCTTextView.m in Sources */,
|
||||
58B511CE1A9E6C5C00147676 /* RCTRawTextManager.m in Sources */,
|
||||
19FC5C851D41A4120090108F /* RCTTextSelection.m in Sources */,
|
||||
1362F1001B4D51F400E06D8C /* RCTTextField.m in Sources */,
|
||||
59AF89AA1EDCBCC700F004B1 /* RCTUITextField.m in Sources */,
|
||||
598F41261F145D4900B8495B /* RCTBackedTextInputDelegateAdapter.m in Sources */,
|
||||
59E6046E1FE9CAF100BD90C5 /* RCTSinglelineTextInputViewManager.m in Sources */,
|
||||
59E604661FE9CAF100BD90C5 /* RCTBaseTextInputView.m in Sources */,
|
||||
59E604621FE9CAF100BD90C5 /* RCTUITextView.m in Sources */,
|
||||
59E604561FE9CAF100BD90C5 /* RCTTextViewManager.m in Sources */,
|
||||
59E604521FE9CAF100BD90C5 /* RCTTextShadowView.m in Sources */,
|
||||
59E6045C1FE9CAF100BD90C5 /* RCTMultilineTextInputShadowView.m in Sources */,
|
||||
59E604581FE9CAF100BD90C5 /* RCTRawTextShadowView.m in Sources */,
|
||||
59E604541FE9CAF100BD90C5 /* RCTTextView.m in Sources */,
|
||||
5989E14D20018A2200EA444A /* RCTBaseTextInputViewManager.m in Sources */,
|
||||
59E604681FE9CAF100BD90C5 /* RCTTextSelection.m in Sources */,
|
||||
59E6045E1FE9CAF100BD90C5 /* RCTMultilineTextInputView.m in Sources */,
|
||||
59E604601FE9CAF100BD90C5 /* RCTMultilineTextInputViewManager.m in Sources */,
|
||||
59E604701FE9CAF100BD90C5 /* RCTUITextField.m in Sources */,
|
||||
59E6046C1FE9CAF100BD90C5 /* RCTSinglelineTextInputView.m in Sources */,
|
||||
A85C829A1F742AA20036C019 /* RCTFontAttributes.m in Sources */,
|
||||
58B512161A9E6EFF00147676 /* RCTText.m in Sources */,
|
||||
599DF2641F03076D0079B53E /* RCTTextInput.m in Sources */,
|
||||
1362F1011B4D51F400E06D8C /* RCTTextFieldManager.m in Sources */,
|
||||
59F60E911E661BDD0081153B /* RCTShadowTextField.m in Sources */,
|
||||
59E6045A1FE9CAF100BD90C5 /* RCTRawTextViewManager.m in Sources */,
|
||||
59E604641FE9CAF100BD90C5 /* RCTBackedTextInputDelegateAdapter.m in Sources */,
|
||||
AF3225F91DE5574F00D3E7E7 /* RCTConvert+Text.m in Sources */,
|
||||
59B125C91E6E4E15004E2A67 /* RCTUITextView.m in Sources */,
|
||||
131B6AC11AF0CD0600FFC3E0 /* RCTTextViewManager.m in Sources */,
|
||||
59F60E931E661BDD0081153B /* RCTShadowTextView.m in Sources */,
|
||||
58B511CF1A9E6C5C00147676 /* RCTShadowRawText.m in Sources */,
|
||||
58B511D01A9E6C5C00147676 /* RCTShadowText.m in Sources */,
|
||||
59E6046A1FE9CAF100BD90C5 /* RCTSinglelineTextInputShadowView.m in Sources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
@@ -432,6 +551,7 @@
|
||||
58B511B01A9E6C1300147676 /* Debug */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
||||
CLANG_STATIC_ANALYZER_MODE = deep;
|
||||
OTHER_LDFLAGS = "-ObjC";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
@@ -442,6 +562,7 @@
|
||||
58B511B11A9E6C1300147676 /* Release */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
||||
CLANG_STATIC_ANALYZER_MODE = deep;
|
||||
OTHER_LDFLAGS = "-ObjC";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
|
||||
@@ -1,14 +0,0 @@
|
||||
/**
|
||||
* Copyright (c) 2015-present, Facebook, Inc.
|
||||
* All rights reserved.
|
||||
*
|
||||
* This source code is licensed under the BSD-style license found in the
|
||||
* LICENSE file in the root directory of this source tree. An additional grant
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import <React/RCTViewManager.h>
|
||||
|
||||
@interface RCTTextManager : RCTViewManager
|
||||
|
||||
@end
|
||||
@@ -1,90 +0,0 @@
|
||||
/**
|
||||
* Copyright (c) 2015-present, Facebook, Inc.
|
||||
* All rights reserved.
|
||||
*
|
||||
* This source code is licensed under the BSD-style license found in the
|
||||
* LICENSE file in the root directory of this source tree. An additional grant
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTTextViewManager.h"
|
||||
|
||||
#import <React/RCTBridge.h>
|
||||
#import <React/RCTConvert.h>
|
||||
#import <React/RCTFont.h>
|
||||
#import <React/RCTShadowView+Layout.h>
|
||||
#import <React/RCTShadowView.h>
|
||||
|
||||
#import "RCTConvert+Text.h"
|
||||
#import "RCTShadowTextView.h"
|
||||
#import "RCTTextView.h"
|
||||
|
||||
@implementation RCTTextViewManager
|
||||
|
||||
RCT_EXPORT_MODULE()
|
||||
|
||||
- (RCTShadowView *)shadowView
|
||||
{
|
||||
return [RCTShadowTextView new];
|
||||
}
|
||||
|
||||
- (UIView *)view
|
||||
{
|
||||
return [[RCTTextView alloc] initWithBridge:self.bridge];
|
||||
}
|
||||
|
||||
#pragma mark - Unified <TextInput> properties
|
||||
|
||||
RCT_REMAP_VIEW_PROPERTY(allowFontScaling, fontAttributes.allowFontScaling, BOOL)
|
||||
RCT_REMAP_VIEW_PROPERTY(autoCapitalize, backedTextInputView.autocapitalizationType, UITextAutocapitalizationType)
|
||||
RCT_REMAP_VIEW_PROPERTY(autoCorrect, backedTextInputView.autocorrectionType, UITextAutocorrectionType)
|
||||
RCT_REMAP_VIEW_PROPERTY(color, backedTextInputView.textColor, UIColor)
|
||||
RCT_REMAP_VIEW_PROPERTY(editable, backedTextInputView.editable, BOOL)
|
||||
RCT_REMAP_VIEW_PROPERTY(enablesReturnKeyAutomatically, backedTextInputView.enablesReturnKeyAutomatically, BOOL)
|
||||
RCT_REMAP_VIEW_PROPERTY(fontSize, fontAttributes.fontSize, NSNumber)
|
||||
RCT_REMAP_VIEW_PROPERTY(fontWeight, fontAttributes.fontWeight, NSString)
|
||||
RCT_REMAP_VIEW_PROPERTY(fontStyle, fontAttributes.fontStyle, NSString)
|
||||
RCT_REMAP_VIEW_PROPERTY(fontFamily, fontAttributes.fontFamily, NSString)
|
||||
RCT_REMAP_VIEW_PROPERTY(keyboardAppearance, backedTextInputView.keyboardAppearance, UIKeyboardAppearance)
|
||||
RCT_REMAP_VIEW_PROPERTY(keyboardType, backedTextInputView.keyboardType, UIKeyboardType)
|
||||
RCT_REMAP_VIEW_PROPERTY(placeholder, backedTextInputView.placeholder, NSString)
|
||||
RCT_REMAP_VIEW_PROPERTY(placeholderTextColor, backedTextInputView.placeholderColor, UIColor)
|
||||
RCT_REMAP_VIEW_PROPERTY(returnKeyType, backedTextInputView.returnKeyType, UIReturnKeyType)
|
||||
RCT_REMAP_VIEW_PROPERTY(secureTextEntry, backedTextInputView.secureTextEntry, BOOL)
|
||||
RCT_REMAP_VIEW_PROPERTY(selectionColor, backedTextInputView.tintColor, UIColor)
|
||||
RCT_REMAP_VIEW_PROPERTY(spellCheck, backedTextInputView.spellCheckingType, UITextSpellCheckingType)
|
||||
RCT_REMAP_VIEW_PROPERTY(textAlign, backedTextInputView.textAlignment, NSTextAlignment)
|
||||
RCT_EXPORT_VIEW_PROPERTY(blurOnSubmit, BOOL)
|
||||
RCT_EXPORT_VIEW_PROPERTY(clearTextOnFocus, BOOL)
|
||||
RCT_EXPORT_VIEW_PROPERTY(maxLength, NSNumber)
|
||||
RCT_EXPORT_VIEW_PROPERTY(selectTextOnFocus, BOOL)
|
||||
RCT_EXPORT_VIEW_PROPERTY(selection, RCTTextSelection)
|
||||
RCT_EXPORT_VIEW_PROPERTY(text, NSString)
|
||||
|
||||
#pragma mark - Multiline <TextInput> (aka TextView) specific properties
|
||||
|
||||
RCT_EXPORT_VIEW_PROPERTY(onChange, RCTBubblingEventBlock)
|
||||
RCT_EXPORT_VIEW_PROPERTY(onContentSizeChange, RCTBubblingEventBlock)
|
||||
RCT_EXPORT_VIEW_PROPERTY(onSelectionChange, RCTDirectEventBlock)
|
||||
RCT_EXPORT_VIEW_PROPERTY(onScroll, RCTDirectEventBlock)
|
||||
RCT_EXPORT_VIEW_PROPERTY(onTextInput, RCTDirectEventBlock)
|
||||
|
||||
RCT_EXPORT_VIEW_PROPERTY(mostRecentEventCount, NSInteger)
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
RCT_REMAP_VIEW_PROPERTY(dataDetectorTypes, backedTextInputView.dataDetectorTypes, UIDataDetectorTypes)
|
||||
#endif
|
||||
|
||||
- (RCTViewManagerUIBlock)uiBlockToAmendWithShadowView:(RCTShadowView *)shadowView
|
||||
{
|
||||
NSNumber *reactTag = shadowView.reactTag;
|
||||
UIEdgeInsets borderAsInsets = shadowView.borderAsInsets;
|
||||
UIEdgeInsets paddingAsInsets = shadowView.paddingAsInsets;
|
||||
return ^(RCTUIManager *uiManager, NSDictionary<NSNumber *, RCTTextInput *> *viewRegistry) {
|
||||
RCTTextInput *view = viewRegistry[reactTag];
|
||||
view.reactBorderInsets = borderAsInsets;
|
||||
view.reactPaddingInsets = paddingAsInsets;
|
||||
};
|
||||
}
|
||||
|
||||
@end
|
||||
@@ -21,9 +21,10 @@ typedef NS_ENUM(NSInteger, RCTSizeComparison)
|
||||
extern NSString *const RCTIsHighlightedAttributeName;
|
||||
extern NSString *const RCTReactTagAttributeName;
|
||||
|
||||
@interface RCTShadowText : RCTShadowView
|
||||
@interface RCTTextShadowView : RCTShadowView
|
||||
|
||||
@property (nonatomic, strong) UIColor *color;
|
||||
@property (nonatomic, strong) UIColor *backgroundColor;
|
||||
@property (nonatomic, copy) NSString *fontFamily;
|
||||
@property (nonatomic, assign) CGFloat fontSize;
|
||||
@property (nonatomic, copy) NSString *fontWeight;
|
||||
@@ -7,7 +7,7 @@
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTShadowText.h"
|
||||
#import "RCTTextShadowView.h"
|
||||
|
||||
#import <React/RCTAccessibilityManager.h>
|
||||
#import <React/RCTBridge.h>
|
||||
@@ -18,9 +18,9 @@
|
||||
#import <React/RCTUIManager.h>
|
||||
#import <React/RCTUtils.h>
|
||||
|
||||
#import "RCTShadowRawText.h"
|
||||
#import "RCTText.h"
|
||||
#import "RCTRawTextShadowView.h"
|
||||
#import "RCTTextView.h"
|
||||
#import "RCTMultilineTextInputView.h"
|
||||
|
||||
NSString *const RCTIsHighlightedAttributeName = @"IsHighlightedAttributeName";
|
||||
NSString *const RCTReactTagAttributeName = @"ReactTagAttributeName";
|
||||
@@ -31,7 +31,7 @@ static CGFloat const kAutoSizeWidthErrorMargin = 0.05f;
|
||||
static CGFloat const kAutoSizeHeightErrorMargin = 0.025f;
|
||||
static CGFloat const kAutoSizeGranularity = 0.001f;
|
||||
|
||||
@implementation RCTShadowText
|
||||
@implementation RCTTextShadowView
|
||||
{
|
||||
NSTextStorage *_cachedTextStorage;
|
||||
CGFloat _cachedTextStorageWidth;
|
||||
@@ -43,7 +43,7 @@ static CGFloat const kAutoSizeGranularity = 0.001f;
|
||||
|
||||
static YGSize RCTMeasure(YGNodeRef node, float width, YGMeasureMode widthMode, float height, YGMeasureMode heightMode)
|
||||
{
|
||||
RCTShadowText *shadowText = (__bridge RCTShadowText *)YGNodeGetContext(node);
|
||||
RCTTextShadowView *shadowText = (__bridge RCTTextShadowView *)YGNodeGetContext(node);
|
||||
NSTextStorage *textStorage = [shadowText buildTextStorageForWidth:width widthMode:widthMode];
|
||||
[shadowText calculateTextFrame:textStorage];
|
||||
NSLayoutManager *layoutManager = textStorage.layoutManagers.firstObject;
|
||||
@@ -74,7 +74,7 @@ static YGSize RCTMeasure(YGNodeRef node, float width, YGMeasureMode widthMode, f
|
||||
_writingDirection = NSWritingDirectionNatural;
|
||||
_cachedLayoutDirection = UIUserInterfaceLayoutDirectionLeftToRight;
|
||||
|
||||
YGNodeSetMeasureFunc(self.yogaNode, RCTMeasure);
|
||||
YGNodeSetMeasureFunc(self.yogaNode, RCTMeasure);
|
||||
|
||||
[[NSNotificationCenter defaultCenter] addObserver:self
|
||||
selector:@selector(contentSizeMultiplierDidChange:)
|
||||
@@ -109,7 +109,7 @@ static YGSize RCTMeasure(YGNodeRef node, float width, YGMeasureMode widthMode, f
|
||||
- (NSDictionary<NSString *, id> *)processUpdatedProperties:(NSMutableSet<RCTApplierBlock> *)applierBlocks
|
||||
parentProperties:(NSDictionary<NSString *, id> *)parentProperties
|
||||
{
|
||||
if ([[self reactSuperview] isKindOfClass:[RCTShadowText class]]) {
|
||||
if ([[self reactSuperview] isKindOfClass:[RCTTextShadowView class]]) {
|
||||
return parentProperties;
|
||||
}
|
||||
|
||||
@@ -122,7 +122,7 @@ static YGSize RCTMeasure(YGNodeRef node, float width, YGMeasureMode widthMode, f
|
||||
CGRect textFrame = [self calculateTextFrame:textStorage];
|
||||
BOOL selectable = _selectable;
|
||||
[applierBlocks addObject:^(NSDictionary<NSNumber *, UIView *> *viewRegistry) {
|
||||
RCTText *view = (RCTText *)viewRegistry[self.reactTag];
|
||||
RCTTextView *view = (RCTTextView *)viewRegistry[self.reactTag];
|
||||
view.textFrame = textFrame;
|
||||
view.textStorage = textStorage;
|
||||
view.selectable = selectable;
|
||||
@@ -130,14 +130,14 @@ static YGSize RCTMeasure(YGNodeRef node, float width, YGMeasureMode widthMode, f
|
||||
/**
|
||||
* NOTE: this logic is included to support rich text editing inside multiline
|
||||
* `<TextInput>` controls. It is required in order to ensure that the
|
||||
* textStorage (aka attributed string) is copied over from the RCTShadowText
|
||||
* to the RCTText view in time to be used to update the editable text content.
|
||||
* TODO: we should establish a delegate relationship betweeen RCTTextView
|
||||
* and its contaned RCTText element when they get inserted and get rid of this
|
||||
* textStorage (aka attributed string) is copied over from the RCTTextShadowView
|
||||
* to the RCTTextView view in time to be used to update the editable text content.
|
||||
* TODO: we should establish a delegate relationship betweeen RCTMultilineTextInputView
|
||||
* and its contaned RCTTextView element when they get inserted and get rid of this
|
||||
*/
|
||||
UIView *parentView = viewRegistry[parentTag];
|
||||
if ([parentView respondsToSelector:@selector(performTextUpdate)]) {
|
||||
[(RCTTextView *)parentView performTextUpdate];
|
||||
[(RCTMultilineTextInputView *)parentView performTextUpdate];
|
||||
}
|
||||
}];
|
||||
|
||||
@@ -308,8 +308,8 @@ static YGSize RCTMeasure(YGNodeRef node, float width, YGMeasureMode widthMode, f
|
||||
CGFloat heightOfTallestSubview = 0.0;
|
||||
NSMutableAttributedString *attributedString = [NSMutableAttributedString new];
|
||||
for (RCTShadowView *child in [self reactSubviews]) {
|
||||
if ([child isKindOfClass:[RCTShadowText class]]) {
|
||||
RCTShadowText *shadowText = (RCTShadowText *)child;
|
||||
if ([child isKindOfClass:[RCTTextShadowView class]]) {
|
||||
RCTTextShadowView *shadowText = (RCTTextShadowView *)child;
|
||||
[attributedString appendAttributedString:
|
||||
[shadowText _attributedStringWithFontFamily:fontFamily
|
||||
fontSize:fontSize
|
||||
@@ -321,8 +321,8 @@ static YGSize RCTMeasure(YGNodeRef node, float width, YGMeasureMode widthMode, f
|
||||
backgroundColor:shadowText.backgroundColor ?: backgroundColor
|
||||
opacity:opacity * shadowText.opacity]];
|
||||
[child setTextComputed];
|
||||
} else if ([child isKindOfClass:[RCTShadowRawText class]]) {
|
||||
RCTShadowRawText *shadowRawText = (RCTShadowRawText *)child;
|
||||
} else if ([child isKindOfClass:[RCTRawTextShadowView class]]) {
|
||||
RCTRawTextShadowView *shadowRawText = (RCTRawTextShadowView *)child;
|
||||
[attributedString appendAttributedString:[[NSAttributedString alloc] initWithString:shadowRawText.text ?: @""]];
|
||||
[child setTextComputed];
|
||||
} else {
|
||||
@@ -340,7 +340,7 @@ static YGSize RCTMeasure(YGNodeRef node, float width, YGMeasureMode widthMode, f
|
||||
if (height > heightOfTallestSubview) {
|
||||
heightOfTallestSubview = height;
|
||||
}
|
||||
// Don't call setTextComputed on this child. RCTTextManager takes care of
|
||||
// Don't call setTextComputed on this child. RCTTextViewManager takes care of
|
||||
// processing inline UIViews.
|
||||
}
|
||||
}
|
||||
@@ -620,12 +620,6 @@ static YGSize RCTMeasure(YGNodeRef node, float width, YGMeasureMode widthMode, f
|
||||
return requiredSize;
|
||||
}
|
||||
|
||||
- (void)setBackgroundColor:(UIColor *)backgroundColor
|
||||
{
|
||||
super.backgroundColor = backgroundColor;
|
||||
[self dirtyText];
|
||||
}
|
||||
|
||||
#define RCT_TEXT_PROPERTY(setProp, ivar, type) \
|
||||
- (void)set##setProp:(type)value; \
|
||||
{ \
|
||||
@@ -659,8 +653,8 @@ RCT_TEXT_PROPERTY(TextShadowColor, _textShadowColor, UIColor *);
|
||||
{
|
||||
_allowFontScaling = allowFontScaling;
|
||||
for (RCTShadowView *child in [self reactSubviews]) {
|
||||
if ([child isKindOfClass:[RCTShadowText class]]) {
|
||||
((RCTShadowText *)child).allowFontScaling = allowFontScaling;
|
||||
if ([child isKindOfClass:[RCTTextShadowView class]]) {
|
||||
((RCTTextShadowView *)child).allowFontScaling = allowFontScaling;
|
||||
}
|
||||
}
|
||||
[self dirtyText];
|
||||
@@ -674,8 +668,8 @@ RCT_TEXT_PROPERTY(TextShadowColor, _textShadowColor, UIColor *);
|
||||
_fontSizeMultiplier = 1.0;
|
||||
}
|
||||
for (RCTShadowView *child in [self reactSubviews]) {
|
||||
if ([child isKindOfClass:[RCTShadowText class]]) {
|
||||
((RCTShadowText *)child).fontSizeMultiplier = fontSizeMultiplier;
|
||||
if ([child isKindOfClass:[RCTTextShadowView class]]) {
|
||||
((RCTTextShadowView *)child).fontSizeMultiplier = fontSizeMultiplier;
|
||||
}
|
||||
}
|
||||
[self dirtyText];
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
#import <UIKit/UIKit.h>
|
||||
|
||||
@interface RCTText : UIView
|
||||
@interface RCTTextView : UIView
|
||||
|
||||
@property (nonatomic, assign) UIEdgeInsets contentInset;
|
||||
@property (nonatomic, strong) NSTextStorage *textStorage;
|
||||
@@ -7,27 +7,27 @@
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTText.h"
|
||||
#import "RCTTextView.h"
|
||||
|
||||
#import <MobileCoreServices/UTCoreTypes.h>
|
||||
|
||||
#import <React/RCTUtils.h>
|
||||
#import <React/UIView+React.h>
|
||||
|
||||
#import "RCTShadowText.h"
|
||||
#import "RCTTextShadowView.h"
|
||||
|
||||
static void collectNonTextDescendants(RCTText *view, NSMutableArray *nonTextDescendants)
|
||||
static void collectNonTextDescendants(RCTTextView *view, NSMutableArray *nonTextDescendants)
|
||||
{
|
||||
for (UIView *child in view.reactSubviews) {
|
||||
if ([child isKindOfClass:[RCTText class]]) {
|
||||
collectNonTextDescendants((RCTText *)child, nonTextDescendants);
|
||||
if ([child isKindOfClass:[RCTTextView class]]) {
|
||||
collectNonTextDescendants((RCTTextView *)child, nonTextDescendants);
|
||||
} else if (!CGRectEqualToRect(child.frame, CGRectZero)) {
|
||||
[nonTextDescendants addObject:child];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@implementation RCTText
|
||||
@implementation RCTTextView
|
||||
{
|
||||
NSTextStorage *_textStorage;
|
||||
CAShapeLayer *_highlightLayer;
|
||||
@@ -7,7 +7,7 @@
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTTextManager.h"
|
||||
#import "RCTTextViewManager.h"
|
||||
|
||||
#import <React/RCTAccessibilityManager.h>
|
||||
#import <React/RCTAssert.h>
|
||||
@@ -17,16 +17,16 @@
|
||||
#import <React/UIView+React.h>
|
||||
#import <yoga/Yoga.h>
|
||||
|
||||
#import "RCTShadowRawText.h"
|
||||
#import "RCTShadowText.h"
|
||||
#import "RCTText.h"
|
||||
#import "RCTRawTextShadowView.h"
|
||||
#import "RCTTextShadowView.h"
|
||||
#import "RCTTextView.h"
|
||||
#import "RCTMultilineTextInputView.h"
|
||||
|
||||
static void collectDirtyNonTextDescendants(RCTShadowText *shadowView, NSMutableArray *nonTextDescendants) {
|
||||
static void collectDirtyNonTextDescendants(RCTTextShadowView *shadowView, NSMutableArray *nonTextDescendants) {
|
||||
for (RCTShadowView *child in shadowView.reactSubviews) {
|
||||
if ([child isKindOfClass:[RCTShadowText class]]) {
|
||||
collectDirtyNonTextDescendants((RCTShadowText *)child, nonTextDescendants);
|
||||
} else if ([child isKindOfClass:[RCTShadowRawText class]]) {
|
||||
if ([child isKindOfClass:[RCTTextShadowView class]]) {
|
||||
collectDirtyNonTextDescendants((RCTTextShadowView *)child, nonTextDescendants);
|
||||
} else if ([child isKindOfClass:[RCTRawTextShadowView class]]) {
|
||||
// no-op
|
||||
} else if ([child isTextDirty]) {
|
||||
[nonTextDescendants addObject:child];
|
||||
@@ -34,30 +34,31 @@ static void collectDirtyNonTextDescendants(RCTShadowText *shadowView, NSMutableA
|
||||
}
|
||||
}
|
||||
|
||||
@interface RCTShadowText (Private)
|
||||
@interface RCTTextShadowView (Private)
|
||||
|
||||
- (NSTextStorage *)buildTextStorageForWidth:(CGFloat)width widthMode:(YGMeasureMode)widthMode;
|
||||
|
||||
@end
|
||||
|
||||
|
||||
@implementation RCTTextManager
|
||||
@implementation RCTTextViewManager
|
||||
|
||||
RCT_EXPORT_MODULE()
|
||||
RCT_EXPORT_MODULE(RCTText)
|
||||
|
||||
- (UIView *)view
|
||||
{
|
||||
return [RCTText new];
|
||||
return [RCTTextView new];
|
||||
}
|
||||
|
||||
- (RCTShadowView *)shadowView
|
||||
{
|
||||
return [RCTShadowText new];
|
||||
return [RCTTextShadowView new];
|
||||
}
|
||||
|
||||
#pragma mark - Shadow properties
|
||||
|
||||
RCT_EXPORT_SHADOW_PROPERTY(color, UIColor)
|
||||
RCT_EXPORT_SHADOW_PROPERTY(backgroundColor, UIColor)
|
||||
RCT_EXPORT_SHADOW_PROPERTY(fontFamily, NSString)
|
||||
RCT_EXPORT_SHADOW_PROPERTY(fontSize, CGFloat)
|
||||
RCT_EXPORT_SHADOW_PROPERTY(fontWeight, NSString)
|
||||
@@ -100,13 +101,13 @@ RCT_EXPORT_SHADOW_PROPERTY(selectable, BOOL)
|
||||
RCTShadowView *shadowView = queue[i];
|
||||
RCTAssert([shadowView isTextDirty], @"Don't process any nodes that don't have dirty text");
|
||||
|
||||
if ([shadowView isKindOfClass:[RCTShadowText class]]) {
|
||||
((RCTShadowText *)shadowView).fontSizeMultiplier = self.bridge.accessibilityManager.multiplier;
|
||||
[(RCTShadowText *)shadowView recomputeText];
|
||||
collectDirtyNonTextDescendants((RCTShadowText *)shadowView, queue);
|
||||
} else if ([shadowView isKindOfClass:[RCTShadowRawText class]]) {
|
||||
if ([shadowView isKindOfClass:[RCTTextShadowView class]]) {
|
||||
((RCTTextShadowView *)shadowView).fontSizeMultiplier = self.bridge.accessibilityManager.multiplier;
|
||||
[(RCTTextShadowView *)shadowView recomputeText];
|
||||
collectDirtyNonTextDescendants((RCTTextShadowView *)shadowView, queue);
|
||||
} else if ([shadowView isKindOfClass:[RCTRawTextShadowView class]]) {
|
||||
RCTLogError(@"Raw text cannot be used outside of a <Text> tag. Not rendering string: '%@'",
|
||||
[(RCTShadowRawText *)shadowView text]);
|
||||
[(RCTRawTextShadowView *)shadowView text]);
|
||||
} else {
|
||||
for (RCTShadowView *child in [shadowView reactSubviews]) {
|
||||
if ([child isTextDirty]) {
|
||||
@@ -122,13 +123,13 @@ RCT_EXPORT_SHADOW_PROPERTY(selectable, BOOL)
|
||||
return nil;
|
||||
}
|
||||
|
||||
- (RCTViewManagerUIBlock)uiBlockToAmendWithShadowView:(RCTShadowText *)shadowView
|
||||
- (RCTViewManagerUIBlock)uiBlockToAmendWithShadowView:(RCTTextShadowView *)shadowView
|
||||
{
|
||||
NSNumber *reactTag = shadowView.reactTag;
|
||||
UIEdgeInsets padding = shadowView.paddingAsInsets;
|
||||
|
||||
return ^(RCTUIManager *uiManager, NSDictionary<NSNumber *, RCTText *> *viewRegistry) {
|
||||
RCTText *text = viewRegistry[reactTag];
|
||||
return ^(RCTUIManager *uiManager, NSDictionary<NSNumber *, RCTTextView *> *viewRegistry) {
|
||||
RCTTextView *text = viewRegistry[reactTag];
|
||||
text.contentInset = padding;
|
||||
};
|
||||
}
|
||||
+1
-1
@@ -9,6 +9,6 @@
|
||||
|
||||
#import <React/RCTShadowView.h>
|
||||
|
||||
@interface RCTShadowTextView : RCTShadowView
|
||||
@interface RCTMultilineTextInputShadowView : RCTShadowView
|
||||
|
||||
@end
|
||||
+2
-2
@@ -7,9 +7,9 @@
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTShadowTextView.h"
|
||||
#import "RCTMultilineTextInputShadowView.h"
|
||||
|
||||
@implementation RCTShadowTextView
|
||||
@implementation RCTMultilineTextInputShadowView
|
||||
|
||||
- (BOOL)isYogaLeafNode
|
||||
{
|
||||
+2
-2
@@ -12,11 +12,11 @@
|
||||
#import <React/RCTView.h>
|
||||
#import <React/UIView+React.h>
|
||||
|
||||
#import "RCTTextInput.h"
|
||||
#import "RCTBaseTextInputView.h"
|
||||
|
||||
@class RCTBridge;
|
||||
|
||||
@interface RCTTextView : RCTTextInput
|
||||
@interface RCTMultilineTextInputView : RCTBaseTextInputView
|
||||
|
||||
@property (nonatomic, assign) UITextAutocorrectionType autocorrectionType;
|
||||
@property (nonatomic, assign) UITextSpellCheckingType spellCheckingType;
|
||||
+8
-8
@@ -7,7 +7,7 @@
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTTextView.h"
|
||||
#import "RCTMultilineTextInputView.h"
|
||||
|
||||
#import <React/RCTConvert.h>
|
||||
#import <React/RCTEventDispatcher.h>
|
||||
@@ -16,19 +16,19 @@
|
||||
#import <React/RCTUtils.h>
|
||||
#import <React/UIView+React.h>
|
||||
|
||||
#import "RCTShadowText.h"
|
||||
#import "RCTText.h"
|
||||
#import "RCTTextShadowView.h"
|
||||
#import "RCTTextView.h"
|
||||
#import "RCTTextSelection.h"
|
||||
#import "RCTUITextView.h"
|
||||
|
||||
@interface RCTTextView () <RCTBackedTextInputDelegate>
|
||||
@interface RCTMultilineTextInputView () <RCTBackedTextInputDelegate>
|
||||
|
||||
@end
|
||||
|
||||
@implementation RCTTextView
|
||||
@implementation RCTMultilineTextInputView
|
||||
{
|
||||
RCTUITextView *_backedTextInput;
|
||||
RCTText *_richTextView;
|
||||
RCTTextView *_richTextView;
|
||||
NSAttributedString *_pendingAttributedText;
|
||||
|
||||
NSString *_predictedText;
|
||||
@@ -77,11 +77,11 @@ RCT_NOT_IMPLEMENTED(- (instancetype)initWithCoder:(NSCoder *)aDecoder)
|
||||
{
|
||||
[super insertReactSubview:subview atIndex:index];
|
||||
|
||||
if ([subview isKindOfClass:[RCTText class]]) {
|
||||
if ([subview isKindOfClass:[RCTTextView class]]) {
|
||||
if (_richTextView) {
|
||||
RCTLogError(@"Tried to insert a second <Text> into <TextInput> - there can only be one.");
|
||||
}
|
||||
_richTextView = (RCTText *)subview;
|
||||
_richTextView = (RCTTextView *)subview;
|
||||
|
||||
// If this <TextInput> is in rich text editing mode, and the child <Text> node providing rich text
|
||||
// styling has a backgroundColor, then the attributedText produced by the child <Text> node will have an
|
||||
@@ -0,0 +1,14 @@
|
||||
/**
|
||||
* Copyright (c) 2015-present, Facebook, Inc.
|
||||
* All rights reserved.
|
||||
*
|
||||
* This source code is licensed under the BSD-style license found in the
|
||||
* LICENSE file in the root directory of this source tree. An additional grant
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTBaseTextInputViewManager.h"
|
||||
|
||||
@interface RCTMultilineTextInputViewManager : RCTBaseTextInputViewManager
|
||||
|
||||
@end
|
||||
@@ -0,0 +1,48 @@
|
||||
/**
|
||||
* Copyright (c) 2015-present, Facebook, Inc.
|
||||
* All rights reserved.
|
||||
*
|
||||
* This source code is licensed under the BSD-style license found in the
|
||||
* LICENSE file in the root directory of this source tree. An additional grant
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTMultilineTextInputViewManager.h"
|
||||
|
||||
#import <React/RCTBridge.h>
|
||||
#import <React/RCTConvert.h>
|
||||
#import <React/RCTFont.h>
|
||||
#import <React/RCTShadowView+Layout.h>
|
||||
#import <React/RCTShadowView.h>
|
||||
|
||||
#import "RCTConvert+Text.h"
|
||||
#import "RCTMultilineTextInputShadowView.h"
|
||||
#import "RCTMultilineTextInputView.h"
|
||||
|
||||
@implementation RCTMultilineTextInputViewManager
|
||||
|
||||
RCT_EXPORT_MODULE()
|
||||
|
||||
- (RCTShadowView *)shadowView
|
||||
{
|
||||
return [RCTMultilineTextInputShadowView new];
|
||||
}
|
||||
|
||||
- (UIView *)view
|
||||
{
|
||||
return [[RCTMultilineTextInputView alloc] initWithBridge:self.bridge];
|
||||
}
|
||||
|
||||
#pragma mark - Multiline <TextInput> (aka TextView) specific properties
|
||||
|
||||
RCT_EXPORT_VIEW_PROPERTY(onChange, RCTBubblingEventBlock)
|
||||
RCT_EXPORT_VIEW_PROPERTY(onContentSizeChange, RCTBubblingEventBlock)
|
||||
RCT_EXPORT_VIEW_PROPERTY(onSelectionChange, RCTDirectEventBlock)
|
||||
RCT_EXPORT_VIEW_PROPERTY(onScroll, RCTDirectEventBlock)
|
||||
RCT_EXPORT_VIEW_PROPERTY(onTextInput, RCTDirectEventBlock)
|
||||
|
||||
#if !TARGET_OS_TV
|
||||
RCT_REMAP_VIEW_PROPERTY(dataDetectorTypes, backedTextInputView.dataDetectorTypes, UIDataDetectorTypes)
|
||||
#endif
|
||||
|
||||
@end
|
||||
@@ -19,7 +19,7 @@
|
||||
@class RCTEventDispatcher;
|
||||
@class RCTTextSelection;
|
||||
|
||||
@interface RCTTextInput : RCTView <RCTFontAttributesDelegate> {
|
||||
@interface RCTBaseTextInputView : RCTView <RCTFontAttributesDelegate> {
|
||||
@protected
|
||||
__weak RCTBridge *_bridge;
|
||||
RCTEventDispatcher *_eventDispatcher;
|
||||
@@ -7,7 +7,7 @@
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTTextInput.h"
|
||||
#import "RCTBaseTextInputView.h"
|
||||
|
||||
#import <React/RCTAccessibilityManager.h>
|
||||
#import <React/RCTBridge.h>
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
#import "RCTTextSelection.h"
|
||||
|
||||
@implementation RCTTextInput {
|
||||
@implementation RCTBaseTextInputView {
|
||||
CGSize _previousContentSize;
|
||||
BOOL _hasInputAccesoryView;
|
||||
}
|
||||
@@ -44,7 +44,7 @@ RCT_NOT_IMPLEMENTED(- (instancetype)initWithFrame:(CGRect)frame)
|
||||
|
||||
- (id<RCTBackedTextInputViewProtocol>)backedTextInputView
|
||||
{
|
||||
RCTAssert(NO, @"-[RCTTextInput backedTextInputView] must be implemented in subclass.");
|
||||
RCTAssert(NO, @"-[RCTBaseTextInputView backedTextInputView] must be implemented in subclass.");
|
||||
return nil;
|
||||
}
|
||||
|
||||
+1
-1
@@ -9,6 +9,6 @@
|
||||
|
||||
#import <React/RCTViewManager.h>
|
||||
|
||||
@interface RCTTextFieldManager : RCTViewManager
|
||||
@interface RCTBaseTextInputViewManager : RCTViewManager
|
||||
|
||||
@end
|
||||
+6
-23
@@ -7,32 +7,21 @@
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTTextFieldManager.h"
|
||||
#import "RCTBaseTextInputViewManager.h"
|
||||
|
||||
#import <React/RCTBridge.h>
|
||||
#import <React/RCTConvert.h>
|
||||
#import <React/RCTFont.h>
|
||||
#import <React/RCTShadowView+Layout.h>
|
||||
#import <React/RCTShadowView.h>
|
||||
|
||||
#import "RCTConvert+Text.h"
|
||||
#import "RCTShadowTextField.h"
|
||||
#import "RCTTextField.h"
|
||||
#import "RCTUITextField.h"
|
||||
#import "RCTBaseTextInputView.h"
|
||||
|
||||
@implementation RCTTextFieldManager
|
||||
@implementation RCTBaseTextInputViewManager
|
||||
|
||||
RCT_EXPORT_MODULE()
|
||||
|
||||
- (RCTShadowView *)shadowView
|
||||
{
|
||||
return [RCTShadowTextField new];
|
||||
}
|
||||
|
||||
- (UIView *)view
|
||||
{
|
||||
return [[RCTTextField alloc] initWithBridge:self.bridge];
|
||||
}
|
||||
|
||||
#pragma mark - Unified <TextInput> properties
|
||||
|
||||
RCT_REMAP_VIEW_PROPERTY(allowFontScaling, fontAttributes.allowFontScaling, BOOL)
|
||||
@@ -61,12 +50,6 @@ RCT_EXPORT_VIEW_PROPERTY(selectTextOnFocus, BOOL)
|
||||
RCT_EXPORT_VIEW_PROPERTY(selection, RCTTextSelection)
|
||||
RCT_EXPORT_VIEW_PROPERTY(text, NSString)
|
||||
|
||||
#pragma mark - Singleline <TextInput> (aka TextField) specific properties
|
||||
|
||||
RCT_REMAP_VIEW_PROPERTY(caretHidden, backedTextInputView.caretHidden, BOOL)
|
||||
RCT_REMAP_VIEW_PROPERTY(clearButtonMode, backedTextInputView.clearButtonMode, UITextFieldViewMode)
|
||||
RCT_EXPORT_VIEW_PROPERTY(onSelectionChange, RCTDirectEventBlock)
|
||||
|
||||
RCT_EXPORT_VIEW_PROPERTY(mostRecentEventCount, NSInteger)
|
||||
|
||||
- (RCTViewManagerUIBlock)uiBlockToAmendWithShadowView:(RCTShadowView *)shadowView
|
||||
@@ -74,8 +57,8 @@ RCT_EXPORT_VIEW_PROPERTY(mostRecentEventCount, NSInteger)
|
||||
NSNumber *reactTag = shadowView.reactTag;
|
||||
UIEdgeInsets borderAsInsets = shadowView.borderAsInsets;
|
||||
UIEdgeInsets paddingAsInsets = shadowView.paddingAsInsets;
|
||||
return ^(RCTUIManager *uiManager, NSDictionary<NSNumber *, RCTTextInput *> *viewRegistry) {
|
||||
RCTTextInput *view = viewRegistry[reactTag];
|
||||
return ^(RCTUIManager *uiManager, NSDictionary<NSNumber *, RCTBaseTextInputView *> *viewRegistry) {
|
||||
RCTBaseTextInputView *view = viewRegistry[reactTag];
|
||||
view.reactBorderInsets = borderAsInsets;
|
||||
view.reactPaddingInsets = paddingAsInsets;
|
||||
};
|
||||
+1
-1
@@ -9,6 +9,6 @@
|
||||
|
||||
#import <React/RCTShadowView.h>
|
||||
|
||||
@interface RCTShadowTextField : RCTShadowView
|
||||
@interface RCTSinglelineTextInputShadowView : RCTShadowView
|
||||
|
||||
@end
|
||||
+2
-2
@@ -7,9 +7,9 @@
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTShadowTextField.h"
|
||||
#import "RCTSinglelineTextInputShadowView.h"
|
||||
|
||||
@implementation RCTShadowTextField
|
||||
@implementation RCTSinglelineTextInputShadowView
|
||||
|
||||
- (BOOL)isYogaLeafNode
|
||||
{
|
||||
+2
-2
@@ -12,11 +12,11 @@
|
||||
#import <React/RCTComponent.h>
|
||||
#import <React/RCTView.h>
|
||||
|
||||
#import "RCTTextInput.h"
|
||||
#import "RCTBaseTextInputView.h"
|
||||
|
||||
@class RCTUITextField;
|
||||
|
||||
@interface RCTTextField : RCTTextInput
|
||||
@interface RCTSinglelineTextInputView : RCTBaseTextInputView
|
||||
|
||||
@property (nonatomic, assign) BOOL caretHidden;
|
||||
@property (nonatomic, strong) NSNumber *maxLength;
|
||||
+3
-3
@@ -7,7 +7,7 @@
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTTextField.h"
|
||||
#import "RCTSinglelineTextInputView.h"
|
||||
|
||||
#import <React/RCTBridge.h>
|
||||
#import <React/RCTConvert.h>
|
||||
@@ -21,11 +21,11 @@
|
||||
#import "RCTTextSelection.h"
|
||||
#import "RCTUITextField.h"
|
||||
|
||||
@interface RCTTextField () <RCTBackedTextInputDelegate>
|
||||
@interface RCTSinglelineTextInputView () <RCTBackedTextInputDelegate>
|
||||
|
||||
@end
|
||||
|
||||
@implementation RCTTextField
|
||||
@implementation RCTSinglelineTextInputView
|
||||
{
|
||||
RCTUITextField *_backedTextInput;
|
||||
BOOL _submitted;
|
||||
@@ -0,0 +1,14 @@
|
||||
/**
|
||||
* Copyright (c) 2015-present, Facebook, Inc.
|
||||
* All rights reserved.
|
||||
*
|
||||
* This source code is licensed under the BSD-style license found in the
|
||||
* LICENSE file in the root directory of this source tree. An additional grant
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTBaseTextInputViewManager.h"
|
||||
|
||||
@interface RCTSinglelineTextInputViewManager : RCTBaseTextInputViewManager
|
||||
|
||||
@end
|
||||
@@ -0,0 +1,42 @@
|
||||
/**
|
||||
* Copyright (c) 2015-present, Facebook, Inc.
|
||||
* All rights reserved.
|
||||
*
|
||||
* This source code is licensed under the BSD-style license found in the
|
||||
* LICENSE file in the root directory of this source tree. An additional grant
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*/
|
||||
|
||||
#import "RCTSinglelineTextInputViewManager.h"
|
||||
|
||||
#import <React/RCTBridge.h>
|
||||
#import <React/RCTFont.h>
|
||||
#import <React/RCTShadowView+Layout.h>
|
||||
#import <React/RCTShadowView.h>
|
||||
|
||||
#import "RCTConvert+Text.h"
|
||||
#import "RCTSinglelineTextInputShadowView.h"
|
||||
#import "RCTSinglelineTextInputView.h"
|
||||
#import "RCTUITextField.h"
|
||||
|
||||
@implementation RCTSinglelineTextInputViewManager
|
||||
|
||||
RCT_EXPORT_MODULE()
|
||||
|
||||
- (RCTShadowView *)shadowView
|
||||
{
|
||||
return [RCTSinglelineTextInputShadowView new];
|
||||
}
|
||||
|
||||
- (UIView *)view
|
||||
{
|
||||
return [[RCTSinglelineTextInputView alloc] initWithBridge:self.bridge];
|
||||
}
|
||||
|
||||
#pragma mark - Singleline <TextInput> (aka TextField) specific properties
|
||||
|
||||
RCT_REMAP_VIEW_PROPERTY(caretHidden, backedTextInputView.caretHidden, BOOL)
|
||||
RCT_REMAP_VIEW_PROPERTY(clearButtonMode, backedTextInputView.clearButtonMode, UITextFieldViewMode)
|
||||
RCT_EXPORT_VIEW_PROPERTY(onSelectionChange, RCTDirectEventBlock)
|
||||
|
||||
@end
|
||||
@@ -0,0 +1,55 @@
|
||||
/**
|
||||
* Copyright (c) 2013-present, Facebook, Inc.
|
||||
* All rights reserved.
|
||||
*
|
||||
* This source code is licensed under the BSD-style license found in the
|
||||
* LICENSE file in the root directory of this source tree. An additional grant
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*
|
||||
* @providesModule TextProps
|
||||
* @flow
|
||||
* @format
|
||||
*/
|
||||
|
||||
'use strict';
|
||||
|
||||
import type {Node} from 'react';
|
||||
|
||||
import type {LayoutEvent} from 'CoreEventTypes';
|
||||
import type {TextStyleProp} from 'StyleSheetTypes';
|
||||
|
||||
type PressRetentionOffset = {
|
||||
top: number,
|
||||
left: number,
|
||||
bottom: number,
|
||||
right: number,
|
||||
};
|
||||
|
||||
/**
|
||||
* @see https://facebook.github.io/react-native/docs/text.html#reference
|
||||
*/
|
||||
export type TextProps = {|
|
||||
accessible?: boolean,
|
||||
allowFontScaling?: boolean,
|
||||
children: Node,
|
||||
ellipsizeMode?: 'clip' | 'head' | 'middle' | 'tail',
|
||||
nativeID?: string,
|
||||
numberOfLines?: number,
|
||||
onLayout?: ?(event: LayoutEvent) => void,
|
||||
onLongPress?: ?() => void,
|
||||
onPress?: ?() => void,
|
||||
pressRetentionOffset?: PressRetentionOffset,
|
||||
selectable?: boolean,
|
||||
style?: TextStyleProp,
|
||||
testID?: string,
|
||||
|
||||
// Android Only
|
||||
disabled?: boolean,
|
||||
selectionColor?: string,
|
||||
textBreakStrategy?: 'balanced' | 'highQuality' | 'simple',
|
||||
|
||||
// iOS Only
|
||||
adjustsFontSizeToFit?: boolean,
|
||||
minimumFontScale?: number,
|
||||
suppressHighlighting?: boolean,
|
||||
|};
|
||||
@@ -25,3 +25,5 @@ export type LayoutEvent = {|
|
||||
|},
|
||||
+persist: () => void,
|
||||
|};
|
||||
|
||||
export type PressEvent = Object;
|
||||
|
||||
@@ -107,7 +107,7 @@ Error: ${e.message}`
|
||||
// evaluating code) but on Chrome we can simply use eval
|
||||
const injectFunction = typeof global.nativeInjectHMRUpdate === 'function'
|
||||
? global.nativeInjectHMRUpdate
|
||||
: eval;
|
||||
: eval; // eslint-disable-line no-eval
|
||||
|
||||
injectFunction(code, sourceURLs[i]);
|
||||
});
|
||||
@@ -121,7 +121,7 @@ Error: ${e.message}`
|
||||
}
|
||||
case 'error': {
|
||||
HMRLoadingView.hide();
|
||||
throw new Error(data.body.type + ' ' + data.body.description);
|
||||
throw new Error(`${data.body.type}: ${data.body.message}`);
|
||||
}
|
||||
default: {
|
||||
throw new Error(`Unexpected message: ${data}`);
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* Intentional info-level logging for clear separation from ad-hoc console debug logging.
|
||||
*/
|
||||
function infoLog(...args) {
|
||||
return console.log(...args); // eslint-disable-line no-console
|
||||
return console.log(...args);
|
||||
}
|
||||
|
||||
module.exports = infoLog;
|
||||
|
||||
@@ -433,6 +433,11 @@
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
EXECUTABLE_PREFIX = lib;
|
||||
GCC_PREPROCESSOR_DEFINITIONS = (
|
||||
"DEBUG=1",
|
||||
"RCT_METRO_PORT=${RCT_METRO_PORT}",
|
||||
"$(inherited)",
|
||||
);
|
||||
GCC_TREAT_WARNINGS_AS_ERRORS = NO;
|
||||
OTHER_LDFLAGS = "-ObjC";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
@@ -443,6 +448,7 @@
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
EXECUTABLE_PREFIX = lib;
|
||||
GCC_PREPROCESSOR_DEFINITIONS = "RCT_METRO_PORT=${RCT_METRO_PORT}";
|
||||
GCC_TREAT_WARNINGS_AS_ERRORS = NO;
|
||||
OTHER_LDFLAGS = "-ObjC";
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
|
||||
@@ -54,7 +54,7 @@ RCT_EXPORT_MODULE()
|
||||
- (void)setUp
|
||||
{
|
||||
if (!_url) {
|
||||
NSInteger port = [[[_bridge bundleURL] port] integerValue] ?: 8081;
|
||||
NSInteger port = [[[_bridge bundleURL] port] integerValue] ?: RCT_METRO_PORT;
|
||||
NSString *host = [[_bridge bundleURL] host] ?: @"localhost";
|
||||
NSString *URLString = [NSString stringWithFormat:@"http://%@:%lld/debugger-proxy?role=client", host, (long long)port];
|
||||
_url = [RCTConvert NSURL:URLString];
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
|
||||
#import <React/RCTBridge.h>
|
||||
#import <React/RCTUIManager.h>
|
||||
#import <React/RCTShadowView+Layout.h>
|
||||
|
||||
#import "RCTWrapperView.h"
|
||||
|
||||
@@ -27,7 +28,7 @@
|
||||
static YGSize RCTWrapperShadowViewMeasure(YGNodeRef node, float width, YGMeasureMode widthMode, float height, YGMeasureMode heightMode)
|
||||
{
|
||||
CGSize minimumSize = CGSizeMake(0, 0);
|
||||
CGSize maximumSize = CGSizeMake(INFINITY, INFINITY);
|
||||
CGSize maximumSize = CGSizeMake(CGFLOAT_MAX, CGFLOAT_MAX);
|
||||
|
||||
switch (widthMode) {
|
||||
case YGMeasureModeUndefined:
|
||||
@@ -55,7 +56,11 @@ static YGSize RCTWrapperShadowViewMeasure(YGNodeRef node, float width, YGMeasure
|
||||
|
||||
RCTWrapperShadowView *shadowView = (__bridge RCTWrapperShadowView *)YGNodeGetContext(node);
|
||||
CGSize size = [shadowView measureWithMinimumSize:minimumSize maximumSize:maximumSize];
|
||||
return (YGSize){size.width, size.height};
|
||||
|
||||
return (YGSize){
|
||||
RCTYogaFloatFromCoreGraphicsFloat(size.width),
|
||||
RCTYogaFloatFromCoreGraphicsFloat(size.height)
|
||||
};
|
||||
}
|
||||
|
||||
- (CGSize)measureWithMinimumSize:(CGSize)minimumSize maximumSize:(CGSize)maximumSize
|
||||
|
||||
@@ -77,14 +77,14 @@
|
||||
|
||||
- (CGSize)intrinsicContentSize
|
||||
{
|
||||
return [self sizeThatFits:CGSizeMake(INFINITY, INFINITY)];
|
||||
return [self sizeThatFits:CGSizeMake(CGFLOAT_MAX, CGFLOAT_MAX)];
|
||||
}
|
||||
|
||||
- (CGSize)sizeThatFits:(CGSize)size
|
||||
{
|
||||
UIView *contentView = self.contentView;
|
||||
if (!contentView) {
|
||||
return size;
|
||||
return [super sizeThatFits:size];
|
||||
}
|
||||
|
||||
return [contentView sizeThatFits:size];
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
* @nolint
|
||||
*/
|
||||
|
||||
/* eslint-disable */
|
||||
/* eslint-disable consistent-this */
|
||||
|
||||
/**
|
||||
* Creates an array from array like objects.
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
* @nolint
|
||||
*/
|
||||
|
||||
/* eslint-disable */
|
||||
/* eslint-disable no-bitwise, no-extend-native, radix, no-self-compare */
|
||||
|
||||
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/findIndex
|
||||
function findIndex(predicate, context) {
|
||||
|
||||
@@ -11,8 +11,6 @@
|
||||
* @nolint
|
||||
*/
|
||||
|
||||
/* eslint-disable strict */
|
||||
|
||||
if (Number.EPSILON === undefined) {
|
||||
Object.defineProperty(Number, 'EPSILON', {
|
||||
value: Math.pow(2, -52),
|
||||
@@ -29,7 +27,6 @@ if (Number.MIN_SAFE_INTEGER === undefined) {
|
||||
});
|
||||
}
|
||||
if (!Number.isNaN) {
|
||||
// eslint-disable-next-line max-len
|
||||
// https://github.com/dherman/tc39-codex-wiki/blob/master/data/es6/number/index.md#polyfill-for-numberisnan
|
||||
const globalIsNaN = global.isNaN;
|
||||
Object.defineProperty(Number, 'isNaN', {
|
||||
|
||||
@@ -11,8 +11,6 @@
|
||||
* @nolint
|
||||
*/
|
||||
|
||||
/* eslint-disable strict */
|
||||
|
||||
// WARNING: This is an optimized version that fails on hasOwnProperty checks
|
||||
// and non objects. It's not spec-compliant. It's a perf optimization.
|
||||
// This is only needed for iOS 8 and current Android JSC.
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
* @nolint
|
||||
*/
|
||||
|
||||
/* eslint-disable strict, no-extend-native, no-bitwise */
|
||||
/* eslint-disable no-extend-native, no-bitwise */
|
||||
|
||||
/*
|
||||
* NOTE: We use (Number(x) || 0) to replace NaN values with zero.
|
||||
|
||||
@@ -9,8 +9,6 @@
|
||||
* @emails oncall+jsinfra
|
||||
*/
|
||||
|
||||
/* eslint-disable fb-www/object-create-only-one-param */
|
||||
|
||||
'use strict';
|
||||
|
||||
describe('Object (ES7)', () => {
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
* @nolint
|
||||
*/
|
||||
|
||||
/* eslint-disable */
|
||||
/* eslint-disable quotes, curly, no-proto, no-undef-init, dot-notation */
|
||||
|
||||
// Created by running:
|
||||
// require('babel-core').buildExternalHelpers('_extends classCallCheck createClass createRawReactElement defineProperty get inherits interopRequireDefault interopRequireWildcard objectWithoutProperties possibleConstructorReturn slicedToArray taggedTemplateLiteral toArray toConsumableArray '.split(' '))
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
* @format
|
||||
*/
|
||||
|
||||
/* eslint-disable */
|
||||
/* eslint-disable no-shadow, eqeqeq, curly, no-unused-vars, no-void */
|
||||
|
||||
/**
|
||||
* This pipes all of our console logging functions to native logging so that
|
||||
|
||||
@@ -11,8 +11,6 @@
|
||||
* @nolint
|
||||
*/
|
||||
|
||||
/* eslint-disable strict */
|
||||
|
||||
let _inGuard = 0;
|
||||
|
||||
/**
|
||||
|
||||
@@ -27,8 +27,8 @@ Supported operating systems are >= Android 4.1 (API 16) and >= iOS 8.0.
|
||||
Follow the [Getting Started guide](https://facebook.github.io/react-native/docs/getting-started.html). The recommended way to install React Native depends on your project. Here you can find short guides for the most common scenarios:
|
||||
|
||||
- [Trying out React Native](https://snack.expo.io/BJ-uC-nrb)
|
||||
- [Creating a New Application](http://facebook.github.io/react-native/docs/getting-started.html)
|
||||
- [Adding React Native to an Existing Application](http://facebook.github.io/react-native/docs/integration-with-existing-apps.html)
|
||||
- [Creating a New Application](https://facebook.github.io/react-native/docs/getting-started.html)
|
||||
- [Adding React Native to an Existing Application](https://facebook.github.io/react-native/docs/integration-with-existing-apps.html)
|
||||
|
||||
---
|
||||
|
||||
|
||||
@@ -412,6 +412,20 @@
|
||||
remoteGlobalIDString = 3DBE0D0D1F3B181C0099AA32;
|
||||
remoteInfo = "fishhook-tvOS";
|
||||
};
|
||||
3DCE53211FEAB1C500613583 /* PBXContainerItemProxy */ = {
|
||||
isa = PBXContainerItemProxy;
|
||||
containerPortal = 14AADEFF1AC3DB95002390C9 /* React.xcodeproj */;
|
||||
proxyType = 2;
|
||||
remoteGlobalIDString = EBF21BDC1FC498900052F4D5;
|
||||
remoteInfo = jsinspector;
|
||||
};
|
||||
3DCE53231FEAB1C500613583 /* PBXContainerItemProxy */ = {
|
||||
isa = PBXContainerItemProxy;
|
||||
containerPortal = 14AADEFF1AC3DB95002390C9 /* React.xcodeproj */;
|
||||
proxyType = 2;
|
||||
remoteGlobalIDString = EBF21BFA1FC4989A0052F4D5;
|
||||
remoteInfo = "jsinspector-tvOS";
|
||||
};
|
||||
5281CA501EEAC9A700AC40CD /* PBXContainerItemProxy */ = {
|
||||
isa = PBXContainerItemProxy;
|
||||
containerPortal = 5281CA4B1EEAC9A700AC40CD /* RCTBlob.xcodeproj */;
|
||||
@@ -826,6 +840,8 @@
|
||||
3D05748E1DE6008900184BB4 /* libcxxreact.a */,
|
||||
3D0574901DE6008900184BB4 /* libjschelpers.a */,
|
||||
3D0574921DE6008900184BB4 /* libjschelpers.a */,
|
||||
3DCE53221FEAB1C500613583 /* libjsinspector.a */,
|
||||
3DCE53241FEAB1C500613583 /* libjsinspector-tvOS.a */,
|
||||
3D507F421EBC88B700B56834 /* libthird-party.a */,
|
||||
2D66FF8C1ECA405900F0A767 /* libthird-party.a */,
|
||||
3D507F441EBC88B700B56834 /* libdouble-conversion.a */,
|
||||
@@ -1497,6 +1513,20 @@
|
||||
remoteRef = 3DBE0D341F3B18670099AA32 /* PBXContainerItemProxy */;
|
||||
sourceTree = BUILT_PRODUCTS_DIR;
|
||||
};
|
||||
3DCE53221FEAB1C500613583 /* libjsinspector.a */ = {
|
||||
isa = PBXReferenceProxy;
|
||||
fileType = archive.ar;
|
||||
path = libjsinspector.a;
|
||||
remoteRef = 3DCE53211FEAB1C500613583 /* PBXContainerItemProxy */;
|
||||
sourceTree = BUILT_PRODUCTS_DIR;
|
||||
};
|
||||
3DCE53241FEAB1C500613583 /* libjsinspector-tvOS.a */ = {
|
||||
isa = PBXReferenceProxy;
|
||||
fileType = archive.ar;
|
||||
path = "libjsinspector-tvOS.a";
|
||||
remoteRef = 3DCE53231FEAB1C500613583 /* PBXContainerItemProxy */;
|
||||
sourceTree = BUILT_PRODUCTS_DIR;
|
||||
};
|
||||
5281CA511EEAC9A700AC40CD /* libRCTBlob.a */ = {
|
||||
isa = PBXReferenceProxy;
|
||||
fileType = archive.ar;
|
||||
|
||||
@@ -110,6 +110,7 @@
|
||||
3D4153641F277011005B8EFE /* libART-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3D4153621F276FF9005B8EFE /* libART-tvOS.a */; };
|
||||
3D56F9F11D6F6E9B00F53A06 /* RNTesterBundle.bundle in Resources */ = {isa = PBXBuildFile; fileRef = 3D13F83E1D6F6AE000E69E0E /* RNTesterBundle.bundle */; };
|
||||
3DB99D0C1BA0340600302749 /* RNTesterIntegrationTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 3DB99D0B1BA0340600302749 /* RNTesterIntegrationTests.m */; };
|
||||
3DCE52BC1FEAAF8F00613583 /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 1380DC9B1E70C0DD00E7C47D /* libReact.a */; };
|
||||
3DD981D61D33C6FB007DC7BE /* RNTesterUnitTestsBundle.js in Resources */ = {isa = PBXBuildFile; fileRef = 3DD981D51D33C6FB007DC7BE /* RNTesterUnitTestsBundle.js */; };
|
||||
68FF44381CF6111500720EFD /* RCTBundleURLProviderTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 68FF44371CF6111500720EFD /* RCTBundleURLProviderTests.m */; };
|
||||
834C36EC1AF8DED70019C93C /* libRCTSettings.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 834C36D21AF8DA610019C93C /* libRCTSettings.a */; };
|
||||
@@ -535,6 +536,7 @@
|
||||
isa = PBXFrameworksBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
3DCE52BC1FEAAF8F00613583 /* libReact.a in Frameworks */,
|
||||
3D4153641F277011005B8EFE /* libART-tvOS.a in Frameworks */,
|
||||
2DD323E31DA2DE3F000FE1B8 /* libRCTAnimation.a in Frameworks */,
|
||||
3D302F221DF8285100D6DDAE /* libRCTImage-tvOS.a in Frameworks */,
|
||||
@@ -833,6 +835,13 @@
|
||||
name = Products;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
3DCE52B31FEAAF8F00613583 /* Frameworks */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
);
|
||||
name = Frameworks;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
58005BE51ABA80530062E044 /* Products */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
@@ -862,6 +871,7 @@
|
||||
14D6D6EA1B2205C0001FB087 /* OCMock */,
|
||||
2DD323911DA2DD8B000FE1B8 /* RNTester-tvOS */,
|
||||
83CBBA001A601CBA00E9B192 /* Products */,
|
||||
3DCE52B31FEAAF8F00613583 /* Frameworks */,
|
||||
);
|
||||
indentWidth = 2;
|
||||
sourceTree = "<group>";
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user