mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8fb6ae12c9 | ||
|
|
794bb0b6f7 | ||
|
|
666820fa98 | ||
|
|
c6b6132112 | ||
|
|
8593306b34 | ||
|
|
d6fe029858 | ||
|
|
bb592ef0dd | ||
|
|
568031ecb2 | ||
|
|
9d6a740bf7 | ||
|
|
ddbf5f804b | ||
|
|
c38cdb60ca | ||
|
|
022a9f7835 | ||
|
|
5761ad6437 | ||
|
|
7538386fbe | ||
|
|
4b38d73792 | ||
|
|
ab19fd6aef | ||
|
|
3df6a77468 | ||
|
|
d323b14ae4 | ||
|
|
028e2f0d6e | ||
|
|
c74602fe47 | ||
|
|
aeb629623f | ||
|
|
0bc2dd03c1 | ||
|
|
16a605b6a3 | ||
|
|
bdc0ef3466 | ||
|
|
b0a27d2b4b | ||
|
|
4b386c9e87 | ||
|
|
a2b3631075 | ||
|
|
287482e57f | ||
|
|
14361bf74b | ||
|
|
d419a1f845 | ||
|
|
fa9486227e | ||
|
|
6e55926372 | ||
|
|
37de064b15 | ||
|
|
9c2efff20d | ||
|
|
63bb3ba5a9 | ||
|
|
647e09dc4c | ||
|
|
5a671c130b | ||
|
|
f6107b6c79 | ||
|
|
7399bbbd02 | ||
|
|
e4ab2b2d58 | ||
|
|
4f82350679 | ||
|
|
a90485a957 | ||
|
|
bfd26b7514 | ||
|
|
843043c088 | ||
|
|
22d1e89cbb | ||
|
|
209e743dc9 | ||
|
|
f8c03d18ed | ||
|
|
b3c7a5d4cc | ||
|
|
7636e4c102 | ||
|
|
c68ef7f84d | ||
|
|
49d16d5aef | ||
|
|
f59db07bf5 | ||
|
|
fc1abe1d69 | ||
|
|
9ce27c7d3a | ||
|
|
2b06a75631 | ||
|
|
7ea7d946c6 | ||
|
|
b7644aa5d3 | ||
|
|
42a088803d | ||
|
|
da5ed0d10b | ||
|
|
69804c70cb | ||
|
|
5bd1a4256e | ||
|
|
91b172dddb | ||
|
|
f2c0514225 | ||
|
|
c11e0f5d44 | ||
|
|
fd8a19d5e2 | ||
|
|
dfdc97a1ca | ||
|
|
4e92d67068 | ||
|
|
3be3a7d1a2 | ||
|
|
1564d4dabb | ||
|
|
ed9ef9811b | ||
|
|
3f61b5f979 | ||
|
|
a582ca59f4 | ||
|
|
fa33e76b08 | ||
|
|
97620164a3 | ||
|
|
b245919be1 | ||
|
|
b8040b95f0 | ||
|
|
d2a8739565 | ||
|
|
a93778c4de | ||
|
|
4bf4c470fe | ||
|
|
fb76526260 | ||
|
|
0dda452eb7 | ||
|
|
1fbfd8c7bb | ||
|
|
6115ce53a2 | ||
|
|
843d57ecc1 | ||
|
|
9be29593c8 | ||
|
|
256e25c792 | ||
|
|
181bd38c96 | ||
|
|
77bd902229 | ||
|
|
2e2ce8a2f9 | ||
|
|
e89d23c9f4 | ||
|
|
ba4c2f5db0 | ||
|
|
644a3da893 | ||
|
|
d14595789b | ||
|
|
e7122dfb4b | ||
|
|
8ad64961f6 | ||
|
|
0d3600b94a | ||
|
|
a0a2301224 | ||
|
|
030ab8e0f1 | ||
|
|
509f8f261e | ||
|
|
0010c3807d | ||
|
|
5162e0b903 | ||
|
|
e137040cb4 | ||
|
|
1d282daf07 | ||
|
|
e49285830a | ||
|
|
98f346b587 | ||
|
|
bf490d379f | ||
|
|
8c20bb7c0c | ||
|
|
4c3bc24893 | ||
|
|
ec3681143e | ||
|
|
0d3c70b636 | ||
|
|
a413e3e979 | ||
|
|
96dc2c164f | ||
|
|
7488e9a37a | ||
|
|
1d22e29146 | ||
|
|
e0d92c64cd | ||
|
|
be199f8973 | ||
|
|
291cc0af10 | ||
|
|
0f8d942eb4 | ||
|
|
41a633d818 | ||
|
|
f4546bfbb2 | ||
|
|
56f2aa4f6b | ||
|
|
2755f4171d | ||
|
|
3df4a79c3d | ||
|
|
6c5088f763 | ||
|
|
267b31aadc | ||
|
|
cbaf4c8da2 | ||
|
|
f2bfe912cf | ||
|
|
de512cd127 | ||
|
|
d60da2324e | ||
|
|
67ea1f1a0d | ||
|
|
c92e98a0f9 | ||
|
|
4a0b11aba9 | ||
|
|
9c4d0a8695 | ||
|
|
20a6fbd373 | ||
|
|
ac635f96ee | ||
|
|
411491e2c0 | ||
|
|
d9321c0866 | ||
|
|
a3f205a27b | ||
|
|
4b84888a90 | ||
|
|
60f0a71060 | ||
|
|
e9460f2a67 | ||
|
|
ad1ddc241a | ||
|
|
374d87418a | ||
|
|
fbe9e2ea70 | ||
|
|
92fc32aa05 | ||
|
|
66a47e18dc | ||
|
|
712efaf44a | ||
|
|
0b440d5475 | ||
|
|
785bc8d97b | ||
|
|
9aa9ee7967 | ||
|
|
77936fa640 | ||
|
|
76ca8e2dc9 | ||
|
|
5f536be2d8 | ||
|
|
4d3e7f8ba1 | ||
|
|
1a92cdb38b | ||
|
|
88196cdf7d | ||
|
|
8329cfab7e | ||
|
|
4650ef36e3 | ||
|
|
1f9926f851 | ||
|
|
c4a995d59a | ||
|
|
e13929eae3 | ||
|
|
fb393fb57c | ||
|
|
3d105113ff | ||
|
|
0193030d00 | ||
|
|
ac5d743153 | ||
|
|
681714ef22 | ||
|
|
85efd37ad4 | ||
|
|
a436d44e8a | ||
|
|
938257915f | ||
|
|
9f82b9cdd8 | ||
|
|
0ff82dfd09 | ||
|
|
a7876989ca | ||
|
|
9ed85c0cc7 | ||
|
|
3978b7ce82 | ||
|
|
6734d92256 | ||
|
|
416463c406 | ||
|
|
b868970037 | ||
|
|
56423e2046 | ||
|
|
36e9d8743a | ||
|
|
1d64766c32 | ||
|
|
e4051c66fa | ||
|
|
89be5ab023 | ||
|
|
38e5fa6a96 | ||
|
|
3d8152e58b | ||
|
|
7bdeed61ba | ||
|
|
44f81c0023 | ||
|
|
6bdde47342 | ||
|
|
870ce571d3 | ||
|
|
c6bfbf9bed | ||
|
|
112bfeecfa | ||
|
|
77b977f89c | ||
|
|
df7c92ff4c | ||
|
|
5f3c1e1f6b | ||
|
|
4f94577d42 | ||
|
|
5a251ba7c5 | ||
|
|
7dee5e7d85 | ||
|
|
06e85773c6 | ||
|
|
22f920f75a | ||
|
|
6ece074edf | ||
|
|
52df783b1e | ||
|
|
9519a0d68a | ||
|
|
ce3eefe12c | ||
|
|
f7b35c0d43 | ||
|
|
5b32348add | ||
|
|
aaa795bcae | ||
|
|
a0ee98dfee | ||
|
|
dc1b20d495 | ||
|
|
ed08edd966 | ||
|
|
de1136359c | ||
|
|
1bd3831cc5 | ||
|
|
213c26c23d | ||
|
|
fd28032be6 | ||
|
|
f04f067aae | ||
|
|
696f4b5c39 | ||
|
|
f9ab91c3ab | ||
|
|
9b7618856f | ||
|
|
8770b2724a | ||
|
|
754524ea9d | ||
|
|
172f23a2ee | ||
|
|
1b5066c21d | ||
|
|
98ad3996c8 | ||
|
|
f65dfa86ab | ||
|
|
621d901e10 | ||
|
|
caa79b7c01 | ||
|
|
e2e6ee363f | ||
|
|
415d6a8858 | ||
|
|
c9a5090f48 | ||
|
|
3fb93e1901 | ||
|
|
abd615f7e3 | ||
|
|
a0ba567b00 | ||
|
|
05d6574a18 | ||
|
|
407a8c0b47 | ||
|
|
b0eec6d4a7 | ||
|
|
d4220ccfb7 | ||
|
|
c5042e5ce7 | ||
|
|
c6fa633597 | ||
|
|
ed16fdbbb8 | ||
|
|
0edcbc30c8 | ||
|
|
ed895c5624 | ||
|
|
13785cf60f | ||
|
|
832c0af408 | ||
|
|
4e5fc68672 | ||
|
|
dbdd973434 | ||
|
|
c8ef8462dd | ||
|
|
3a218104da | ||
|
|
5c41024d85 | ||
|
|
0f6ec5a8b4 | ||
|
|
d1831a7094 | ||
|
|
d7dd64194e | ||
|
|
b34bde2a91 | ||
|
|
4ba52ac555 | ||
|
|
e108e9ebf1 | ||
|
|
89cac88028 | ||
|
|
67b74e7a9b | ||
|
|
a7a43f8445 | ||
|
|
f283877c21 | ||
|
|
5cffb4fa00 | ||
|
|
804d2b5bf1 | ||
|
|
9628e56125 | ||
|
|
f27947431b | ||
|
|
b89efc8473 | ||
|
|
b1bf8c51d0 | ||
|
|
658d7dd52e | ||
|
|
38465f2d18 | ||
|
|
aa2b243bc5 | ||
|
|
49c0267b66 | ||
|
|
0d90a44adf | ||
|
|
1739139c7c | ||
|
|
79f785760f | ||
|
|
9979e38c70 | ||
|
|
18b847fa28 | ||
|
|
8f2c7ff9f2 | ||
|
|
a7792da695 | ||
|
|
fc1dbb8f0b | ||
|
|
ba1a9defbb | ||
|
|
6107793fda | ||
|
|
78c8e49d0a | ||
|
|
e809e4b1ec | ||
|
|
67c373ff3a | ||
|
|
ceaebc6975 | ||
|
|
05646f8f38 | ||
|
|
0ad1c53443 | ||
|
|
c9fd1dd56e | ||
|
|
572ada9308 | ||
|
|
362e1974fe | ||
|
|
61baa751c9 | ||
|
|
cd875420e8 | ||
|
|
c36c33c613 | ||
|
|
e5fba33a94 | ||
|
|
16c32f920e | ||
|
|
ea22ee6bf6 | ||
|
|
adfd21e035 | ||
|
|
41c56db95d | ||
|
|
8d11cb4b9c | ||
|
|
5e5d29e43c | ||
|
|
3624b47768 | ||
|
|
99bcbad2b2 | ||
|
|
4eda46f7f5 | ||
|
|
08430bf214 | ||
|
|
adcdb366da | ||
|
|
df737b09b1 | ||
|
|
b310f2b078 | ||
|
|
ea0cd5b7ca | ||
|
|
d02b51332e | ||
|
|
8c488d8757 | ||
|
|
c63ea4c3a0 | ||
|
|
d587e0c2a5 | ||
|
|
79bb531416 | ||
|
|
775d5cd00c | ||
|
|
7ef7d99f1c | ||
|
|
83c8163540 | ||
|
|
229be89121 | ||
|
|
2c26c8fded | ||
|
|
60129ab7ac | ||
|
|
41a80f2ee2 | ||
|
|
94b1165a44 | ||
|
|
e4f23f4783 | ||
|
|
27c32b2d71 | ||
|
|
5c9f160764 | ||
|
|
4d0be144bf | ||
|
|
32931b19b1 | ||
|
|
ea9dd430a6 | ||
|
|
c4a7e46976 | ||
|
|
b8f8ac0e1c | ||
|
|
8e3b62019e | ||
|
|
0f72abfc03 | ||
|
|
c9a3c5749b | ||
|
|
fd5e282290 | ||
|
|
39798cfa91 | ||
|
|
741d102476 | ||
|
|
49278df494 | ||
|
|
e59cf2db64 | ||
|
|
ae677efb57 | ||
|
|
41bf725ada | ||
|
|
becb47ccb6 | ||
|
|
f0054e1e30 | ||
|
|
936d69e7a1 | ||
|
|
151498a122 | ||
|
|
94cea1edda | ||
|
|
5f656e98c9 |
@@ -1,8 +0,0 @@
|
||||
{
|
||||
"presets": [
|
||||
"module:metro-react-native-babel-preset"
|
||||
],
|
||||
"plugins": [
|
||||
"babel-plugin-transform-flow-enums"
|
||||
]
|
||||
}
|
||||
@@ -15,6 +15,3 @@
|
||||
|
||||
[alias]
|
||||
rntester = //packages/rn-tester/android/app:app
|
||||
|
||||
[buildfile]
|
||||
includes = //tools/build_defs/oss/preload.bzl
|
||||
|
||||
@@ -14,31 +14,42 @@
|
||||
# and build a Android application that can be used to run the
|
||||
# tests specified in the scripts/ directory.
|
||||
#
|
||||
FROM reactnativecommunity/react-native-android:7.0
|
||||
FROM reactnativecommunity/react-native-android:6.2
|
||||
|
||||
LABEL Description="React Native Android Test Image"
|
||||
LABEL maintainer="Héctor Ramos <hector@fb.com>"
|
||||
|
||||
# set default environment variables
|
||||
ENV GRADLE_OPTS="-Dorg.gradle.daemon=false -Dfile.encoding=utf-8 -Dorg.gradle.jvmargs=\"-Xmx512m -XX:+HeapDumpOnOutOfMemoryError\""
|
||||
ENV KOTLIN_HOME="packages/react-native/third-party/kotlin"
|
||||
ENV GRADLE_OPTS="-Dorg.gradle.daemon=false -Dorg.gradle.jvmargs=\"-Xmx512m -XX:+HeapDumpOnOutOfMemoryError\""
|
||||
ENV KOTLIN_HOME="third-party/kotlin"
|
||||
|
||||
ADD .buckconfig /app/.buckconfig
|
||||
ADD .buckjavaargs /app/.buckjavaargs
|
||||
ADD BUCK /app/BUCK
|
||||
ADD packages/react-native/Libraries /app/packages/react-native/Libraries
|
||||
ADD packages/react-native/ReactAndroid /app/packages/react-native/ReactAndroid
|
||||
ADD packages/react-native/ReactCommon /app/packages/react-native/ReactCommon
|
||||
ADD packages/react-native/React /app/packages/react-native/React
|
||||
ADD Libraries /app/Libraries
|
||||
ADD ReactAndroid /app/ReactAndroid
|
||||
ADD ReactCommon /app/ReactCommon
|
||||
ADD React /app/React
|
||||
ADD keystores /app/keystores
|
||||
ADD packages/react-native-codegen /app/packages/react-native-codegen
|
||||
ADD tools /app/tools
|
||||
ADD scripts /app/scripts
|
||||
add scripts /app/scripts
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
RUN scripts/download-kotlin-compiler-with-buck.sh
|
||||
|
||||
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 buck build ReactAndroid/src/main/java/com/facebook/react
|
||||
RUN buck build ReactAndroid/src/main/java/com/facebook/react/shell
|
||||
|
||||
ADD . /app
|
||||
|
||||
RUN yarn
|
||||
|
||||
RUN ./gradlew :packages:react-native:ReactAndroid:assembleDebug
|
||||
RUN ./gradlew :ReactAndroid:assembleDebug
|
||||
|
||||
@@ -141,7 +141,7 @@ function e2e_suite() {
|
||||
fi
|
||||
fi
|
||||
|
||||
if ! (cd packages/react-native && FILENAME=$(npm pack | tail -1) && mv "$FILENAME" ../../)
|
||||
if ! npm pack
|
||||
then
|
||||
echo "Failed to pack react-native"
|
||||
return 1
|
||||
|
||||
+229
-241
@@ -34,6 +34,10 @@ references:
|
||||
attach_workspace:
|
||||
at: *hermes_workspace_root
|
||||
|
||||
main_only: &main_only
|
||||
filters:
|
||||
branches:
|
||||
only: main
|
||||
main_or_stable_only: &main_or_stable_only
|
||||
filters:
|
||||
branches:
|
||||
@@ -46,7 +50,7 @@ references:
|
||||
# Dependency Anchors
|
||||
# -------------------------
|
||||
dependency_versions:
|
||||
xcode_version: &xcode_version "14.3.0"
|
||||
xcode_version: &xcode_version "14.0.1"
|
||||
nodelts_image: &nodelts_image "cimg/node:18.12.1"
|
||||
nodeprevlts_image: &nodeprevlts_image "cimg/node:16.18.1"
|
||||
|
||||
@@ -56,26 +60,24 @@ references:
|
||||
# Anchors for the cache keys
|
||||
|
||||
cache_keys:
|
||||
checkout_cache_key: &checkout_cache_key v1-checkout
|
||||
checkout_cache_key: &checkout_cache_key v5-checkout
|
||||
gems_cache_key: &gems_cache_key v1-gems-{{ checksum "Gemfile.lock" }}
|
||||
gradle_cache_key: &gradle_cache_key v1-gradle-{{ checksum "gradle/wrapper/gradle-wrapper.properties" }}-{{ checksum "packages/react-native/ReactAndroid/gradle.properties" }}
|
||||
gradle_cache_key: &gradle_cache_key v1-gradle-{{ checksum "gradle/wrapper/gradle-wrapper.properties" }}-{{ checksum "ReactAndroid/gradle.properties" }}
|
||||
hermes_workspace_cache_key: &hermes_workspace_cache_key v4-hermes-{{ .Environment.CIRCLE_JOB }}-{{ checksum "/tmp/hermes/hermesversion" }}
|
||||
hermes_workspace_debug_cache_key: &hermes_workspace_debug_cache_key v2-hermes-{{ .Environment.CIRCLE_JOB }}-debug-{{ checksum "/tmp/hermes/hermesversion" }}-{{ checksum "/tmp/react-native-version" }}
|
||||
hermes_workspace_release_cache_key: &hermes_workspace_release_cache_key v2-hermes-{{ .Environment.CIRCLE_JOB }}-release-{{ checksum "/tmp/hermes/hermesversion" }}-{{ checksum "/tmp/react-native-version" }}
|
||||
hermes_workspace_debug_cache_key: &hermes_workspace_debug_cache_key v2-hermes-{{ .Environment.CIRCLE_JOB }}-debug-{{ checksum "/tmp/hermes/hermesversion" }}-{{ checksum "/tmp/react-native-version" }}-{{ checksum "sdks/hermes-engine/utils/build-apple-framework.sh" }}
|
||||
hermes_workspace_release_cache_key: &hermes_workspace_release_cache_key v2-hermes-{{ .Environment.CIRCLE_JOB }}-release-{{ checksum "/tmp/hermes/hermesversion" }}-{{ checksum "/tmp/react-native-version" }}-{{ checksum "sdks/hermes-engine/utils/build-apple-framework.sh" }}
|
||||
hermes_linux_cache_key: &hermes_linux_cache_key v1-hermes-{{ .Environment.CIRCLE_JOB }}-linux-{{ checksum "/tmp/hermes/hermesversion" }}-{{ checksum "/tmp/react-native-version" }}
|
||||
hermes_windows_cache_key: &hermes_windows_cache_key v2-hermes-{{ .Environment.CIRCLE_JOB }}-windows-{{ checksum "/Users/circleci/project/tmp/hermes/hermesversion" }}-{{ checksum "/tmp/react-native-version" }}
|
||||
hermes_tarball_debug_cache_key: &hermes_tarball_debug_cache_key v4-hermes-tarball-debug-{{ checksum "/tmp/hermes/hermesversion" }}-{{ checksum "/tmp/react-native-version" }}
|
||||
hermes_tarball_release_cache_key: &hermes_tarball_release_cache_key v3-hermes-tarball-release-{{ checksum "/tmp/hermes/hermesversion" }}-{{ checksum "/tmp/react-native-version" }}
|
||||
pods_cache_key: &pods_cache_key v8-pods-{{ .Environment.CIRCLE_JOB }}-{{ checksum "packages/rn-tester/Podfile.lock.bak" }}-{{ checksum "packages/rn-tester/Podfile" }}
|
||||
windows_yarn_cache_key: &windows_yarn_cache_key v1-win-yarn-cache-{{ arch }}-{{ checksum "yarn.lock" }}
|
||||
windows_choco_cache_key: &windows_choco_cache_key v1-win-choco-cache-{{ .Environment.CIRCLE_JOB }}
|
||||
yarn_cache_key: &yarn_cache_key v5-yarn-cache-{{ .Environment.CIRCLE_JOB }}
|
||||
rbenv_cache_key: &rbenv_cache_key v1-rbenv-{{ checksum "/tmp/required_ruby" }}
|
||||
|
||||
cache_paths:
|
||||
hermes_workspace_macos_cache_paths: &hermes_workspace_macos_cache_paths
|
||||
- ~/react-native/packages/react-native/sdks/hermes/build_macosx
|
||||
- ~/react-native/packages/react-native/sdks/hermes/destroot
|
||||
- ~/react-native/sdks/hermes/build_macosx
|
||||
- ~/react-native/sdks/hermes/destroot
|
||||
hermes_tarball_cache_paths: &hermes_tarball_cache_paths
|
||||
- *hermes_tarball_artifacts_dir
|
||||
|
||||
@@ -113,12 +115,12 @@ executors:
|
||||
reactnativeandroid:
|
||||
<<: *defaults
|
||||
docker:
|
||||
- image: reactnativecommunity/react-native-android:7.0
|
||||
- image: reactnativecommunity/react-native-android:6.2
|
||||
resource_class: "xlarge"
|
||||
environment:
|
||||
- TERM: "dumb"
|
||||
- ADB_INSTALL_TIMEOUT: 10
|
||||
- GRADLE_OPTS: '-Dorg.gradle.daemon=false -Dfile.encoding=utf-8 -Dorg.gradle.jvmargs="-XX:+HeapDumpOnOutOfMemoryError"'
|
||||
- GRADLE_OPTS: '-Dorg.gradle.daemon=false -Dorg.gradle.jvmargs="-XX:+HeapDumpOnOutOfMemoryError"'
|
||||
- BUILD_THREADS: 2
|
||||
# Repeated here, as the environment key in this executor will overwrite the one in defaults
|
||||
- PUBLIC_ANALYSISBOT_GITHUB_TOKEN_A: *github_analysisbot_token_a
|
||||
@@ -131,7 +133,7 @@ executors:
|
||||
xcode: *xcode_version
|
||||
resource_class: macos.x86.medium.gen2
|
||||
environment:
|
||||
- BUILD_FROM_SOURCE: true
|
||||
- REACT_NATIVE_CI: true
|
||||
|
||||
# -------------------------
|
||||
# COMMANDS
|
||||
@@ -159,55 +161,14 @@ commands:
|
||||
command: mkdir -p ./reports/{buck,build,junit,outputs}
|
||||
|
||||
setup_ruby:
|
||||
parameters:
|
||||
ruby_version:
|
||||
default: "2.6.10"
|
||||
type: string
|
||||
steps:
|
||||
- restore_cache:
|
||||
key: *gems_cache_key
|
||||
- run:
|
||||
name: Set Required Ruby
|
||||
command: echo << parameters.ruby_version >> > /tmp/required_ruby
|
||||
- restore_cache:
|
||||
key: *rbenv_cache_key
|
||||
- run:
|
||||
name: Bundle Install
|
||||
command: |
|
||||
# Check if rbenv is installed. CircleCI is migrating to rbenv so we may not need to always install it.
|
||||
|
||||
if [[ -z "$(command -v rbenv)" ]]; then
|
||||
brew install rbenv ruby-build
|
||||
# Load and init rbenv
|
||||
(rbenv init 2> /dev/null) || true
|
||||
echo '' >> ~/.bash_profile
|
||||
echo 'eval "$(rbenv init - bash)"' >> ~/.bash_profile
|
||||
source ~/.bash_profile
|
||||
else
|
||||
echo "rbenv found; Skipping installation"
|
||||
fi
|
||||
|
||||
brew reinstall libyaml
|
||||
gem install psych -- --with-libyaml-dir=$(brew --prefix libyaml)
|
||||
export RUBY_CONFIGURE_OPTS=--with-libyaml-dir=$(brew --prefix libyaml)
|
||||
|
||||
# Install the right version of ruby
|
||||
if [[ -z "$(rbenv versions | grep << parameters.ruby_version >>)" ]]; then
|
||||
# ensure that `ruby-build` can see all the available versions of Ruby
|
||||
# some PRs received machines in a weird state, this should make the pipelines
|
||||
# more robust.
|
||||
brew update && brew upgrade ruby-build
|
||||
rbenv install << parameters.ruby_version >>
|
||||
fi
|
||||
|
||||
# Set ruby dependencies
|
||||
rbenv global << parameters.ruby_version >>
|
||||
gem install bundler
|
||||
source /usr/local/share/chruby/auto.sh
|
||||
bundle check || bundle install --path vendor/bundle --clean
|
||||
- save_cache:
|
||||
key: *rbenv_cache_key
|
||||
paths:
|
||||
- ~/.rbenv
|
||||
- save_cache:
|
||||
key: *gems_cache_key
|
||||
paths:
|
||||
@@ -246,7 +207,7 @@ commands:
|
||||
steps:
|
||||
- run:
|
||||
name: "Brew: Install << parameters.package >>"
|
||||
command: brew install << parameters.package >>
|
||||
command: brew install << parameters.package >> >/dev/null
|
||||
|
||||
with_rntester_pods_cache_span:
|
||||
parameters:
|
||||
@@ -315,7 +276,7 @@ commands:
|
||||
- run:
|
||||
name: Get React Native version
|
||||
command: |
|
||||
VERSION=$(cat packages/react-native/package.json | jq -r '.version')
|
||||
VERSION=$(cat package.json | jq -r '.version')
|
||||
# Save the react native version we are building in a file so we can use that file as part of the cache key.
|
||||
echo "$VERSION" > /tmp/react-native-version
|
||||
echo "React Native Version is $(cat /tmp/react-native-version)"
|
||||
@@ -382,7 +343,7 @@ commands:
|
||||
exit 0
|
||||
fi
|
||||
|
||||
TARBALL_FILENAME=$(node ~/react-native/packages/react-native/scripts/hermes/get-tarball-name.js --buildType "<< parameters.flavor >>")
|
||||
TARBALL_FILENAME=$(node ~/react-native/scripts/hermes/get-tarball-name.js --buildType "<< parameters.flavor >>")
|
||||
TARBALL_PATH=$HERMES_TARBALL_ARTIFACTS_DIR/$TARBALL_FILENAME
|
||||
|
||||
echo "Looking for $TARBALL_FILENAME in $HERMES_TARBALL_ARTIFACTS_DIR"
|
||||
@@ -399,7 +360,7 @@ commands:
|
||||
name: Print Hermes version
|
||||
command: |
|
||||
HERMES_TARBALL_ARTIFACTS_DIR=<< parameters.hermes_tarball_artifacts_dir >>
|
||||
TARBALL_FILENAME=$(node ~/react-native/packages/react-native/scripts/hermes/get-tarball-name.js --buildType "<< parameters.flavor >>")
|
||||
TARBALL_FILENAME=$(node ~/react-native/scripts/hermes/get-tarball-name.js --buildType "<< parameters.flavor >>")
|
||||
TARBALL_PATH=$HERMES_TARBALL_ARTIFACTS_DIR/$TARBALL_FILENAME
|
||||
if [[ -e $TARBALL_PATH ]]; then
|
||||
tar -xf $TARBALL_PATH
|
||||
@@ -466,8 +427,8 @@ commands:
|
||||
hermesc_artifacts_path=<< parameters.artifacts_dir >>/<< parameters.flavor >>/hermesc
|
||||
|
||||
hermesc_bin_path=bin/hermesc
|
||||
hermes_build_dir_macos=$(pwd)/packages/react-native/sdks/hermes/build_macosx
|
||||
hermes_build_dir_ios=$(pwd)/packages/react-native/sdks/hermes/build_iphoneos
|
||||
hermes_build_dir_macos=$(pwd)/sdks/hermes/build_macosx
|
||||
hermes_build_dir_ios=$(pwd)/sdks/hermes/build_iphoneos
|
||||
|
||||
function export_hermesc_cmake_path {
|
||||
build_dir=$1
|
||||
@@ -504,9 +465,24 @@ jobs:
|
||||
steps:
|
||||
- checkout
|
||||
- run_yarn
|
||||
|
||||
|
||||
# Note: The yarn gpg key needs to be refreshed to work around https://github.com/yarnpkg/yarn/issues/7866
|
||||
- run:
|
||||
name: Install additional GitHub bot dependencies
|
||||
# TEMP: Added workaround from https://github.com/nodesource/distributions/issues/1266#issuecomment-932583579
|
||||
command: |
|
||||
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add -
|
||||
apt update && apt install -y shellcheck jq
|
||||
apt-get -y install openssl ca-certificates
|
||||
update-ca-certificates
|
||||
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add -
|
||||
apt update && apt install -y shellcheck jq
|
||||
|
||||
- run:
|
||||
name: Run linters against modified files (analysis-bot)
|
||||
command: GITHUB_TOKEN="$PUBLIC_ANALYSISBOT_GITHUB_TOKEN_A""$PUBLIC_ANALYSISBOT_GITHUB_TOKEN_B" yarn lint-ci
|
||||
when: always
|
||||
|
||||
# -------------------------
|
||||
# JOBS: Analyze Code
|
||||
@@ -583,8 +559,17 @@ jobs:
|
||||
- run:
|
||||
name: "Run Tests: JavaScript Tests"
|
||||
command: node ./scripts/run-ci-javascript-tests.js --maxWorkers 2
|
||||
- run_e2e:
|
||||
platform: js
|
||||
|
||||
# When not in 0.XX-stable branch, run e2e tests
|
||||
- when:
|
||||
condition:
|
||||
not:
|
||||
matches:
|
||||
pattern: "0.[0-9]{2}-stable"
|
||||
value: << pipeline.git.branch >>
|
||||
steps:
|
||||
- run_e2e:
|
||||
platform: js
|
||||
|
||||
# Optionally, run disabled tests
|
||||
- when:
|
||||
@@ -618,23 +603,16 @@ jobs:
|
||||
description: Which JavaScript engine to use. Must be one of "Hermes", "JSC".
|
||||
type: enum
|
||||
enum: ["Hermes", "JSC"]
|
||||
ruby_version:
|
||||
default: "2.6.10"
|
||||
description: The version of ruby that must be used
|
||||
type: string
|
||||
environment:
|
||||
- REPORTS_DIR: "./reports/junit"
|
||||
steps:
|
||||
- checkout_code_with_cache
|
||||
- setup_artifacts
|
||||
- setup_ruby:
|
||||
ruby_version: << parameters.ruby_version >>
|
||||
- brew_install:
|
||||
package: xcbeautify
|
||||
- setup_ruby
|
||||
- run:
|
||||
name: Run Ruby Tests
|
||||
command: |
|
||||
cd packages/react-native/scripts
|
||||
cd scripts
|
||||
sh run_ruby_tests.sh
|
||||
- run_yarn
|
||||
- *attach_hermes_workspace
|
||||
@@ -653,7 +631,7 @@ jobs:
|
||||
|
||||
- run:
|
||||
name: "Brew: Tap wix/brew"
|
||||
command: brew tap wix/brew
|
||||
command: brew tap wix/brew >/dev/null
|
||||
- brew_install:
|
||||
package: applesimutils watchman
|
||||
|
||||
@@ -670,8 +648,7 @@ jobs:
|
||||
|
||||
- run:
|
||||
name: Setup the CocoaPods environment
|
||||
command: |
|
||||
bundle exec pod setup
|
||||
command: bundle exec pod setup
|
||||
|
||||
- with_hermes_tarball_cache_span:
|
||||
set_tarball_path: True
|
||||
@@ -685,9 +662,7 @@ jobs:
|
||||
export USE_HERMES=0
|
||||
fi
|
||||
|
||||
cd packages/rn-tester
|
||||
bundle install
|
||||
bundle exec pod install --verbose
|
||||
cd packages/rn-tester && bundle install && bundle exec pod install --verbose
|
||||
|
||||
# -------------------------
|
||||
# Runs iOS unit tests
|
||||
@@ -733,6 +708,64 @@ jobs:
|
||||
- store_test_results:
|
||||
path: ./reports/junit
|
||||
|
||||
# -------------------------
|
||||
# JOBS: Test Buck
|
||||
# -------------------------
|
||||
test_buck:
|
||||
executor: reactnativeandroid
|
||||
environment:
|
||||
KOTLIN_HOME=third-party/kotlin
|
||||
steps:
|
||||
- checkout
|
||||
- setup_artifacts
|
||||
- run_yarn
|
||||
|
||||
- run:
|
||||
name: Download Dependencies Using Buck
|
||||
command: ./scripts/circleci/buck_fetch.sh
|
||||
|
||||
- run:
|
||||
name: Build & Test React Native using Buck
|
||||
command: |
|
||||
buck build ReactAndroid/src/main/java/com/facebook/react
|
||||
buck build ReactAndroid/src/main/java/com/facebook/react/shell
|
||||
- run:
|
||||
name: Run Tests - Android Unit Tests with Buck
|
||||
command: buck test ReactAndroid/src/test/... --config build.threads=$BUILD_THREADS --xml ./reports/buck/all-results-raw.xml
|
||||
|
||||
- store_test_results:
|
||||
path: ~/react-native/ReactAndroid/build/test-results
|
||||
|
||||
- store_test_results:
|
||||
path: ~/react-native/packages/react-native-gradle-plugin/build/test-results
|
||||
|
||||
- run:
|
||||
name: Build JavaScript Bundle for instrumentation tests
|
||||
command: node cli.js bundle --max-workers 2 --platform android --dev true --entry-file ReactAndroid/src/androidTest/js/TestBundle.js --bundle-output ReactAndroid/src/androidTest/assets/AndroidTestBundle.js
|
||||
|
||||
- run:
|
||||
name: Build Tests - Android Instrumentation Tests with Buck
|
||||
# Here, just build the instrumentation tests. There is a known issue with installing the APK to android-21+ emulator.
|
||||
command: |
|
||||
if [[ ! -e ReactAndroid/src/androidTest/assets/AndroidTestBundle.js ]]; then
|
||||
echo "JavaScript bundle missing, cannot run instrumentation tests. Verify Build JavaScript Bundle step completed successfully."; exit 1;
|
||||
fi
|
||||
source scripts/android-setup.sh && NO_BUCKD=1 scripts/retry3 timeout 300 buck build ReactAndroid/src/androidTest/buck-runner:instrumentation-tests --config build.threads=$BUILD_THREADS
|
||||
|
||||
- run:
|
||||
name: Collect Test Results
|
||||
command: |
|
||||
find . -type f -regex ".*/build/test-results/debug/.*xml" -exec cp {} ./reports/build/ \;
|
||||
find . -type f -regex ".*/outputs/androidTest-results/connected/.*xml" -exec cp {} ./reports/outputs/ \;
|
||||
find . -type f -regex ".*/buck-out/gen/ReactAndroid/src/test/.*/.*xml" -exec cp {} ./reports/buck/ \;
|
||||
if [ -f ~/react-native/reports/buck/all-results-raw.xml ]; then
|
||||
~/react-native/scripts/circleci/buckToJunit/buckToJunit.sh ~/react-native/reports/buck/all-results-raw.xml ~/react-native/reports/junit/results.xml
|
||||
fi
|
||||
when: always
|
||||
|
||||
- store_test_results:
|
||||
path: ./reports/junit
|
||||
|
||||
# -------------------------
|
||||
# JOBS: Test Android
|
||||
# -------------------------
|
||||
@@ -746,11 +779,30 @@ jobs:
|
||||
- checkout
|
||||
- setup_artifacts
|
||||
- run_yarn
|
||||
|
||||
# Starting emulator in advance as it takes some time to boot.
|
||||
- run:
|
||||
name: Create Android Virtual Device
|
||||
command: source scripts/android-setup.sh && createAVD
|
||||
- run:
|
||||
name: Launch Android Virtual Device in Background
|
||||
command: source scripts/android-setup.sh && launchAVD
|
||||
background: true
|
||||
|
||||
- download_gradle_dependencies
|
||||
|
||||
- run:
|
||||
name: Build & Test React Native using Gradle
|
||||
command: ./gradlew build
|
||||
command: ./gradlew buildAll
|
||||
|
||||
- run:
|
||||
name: Build RN Tester for Release using Gradle
|
||||
command: ./gradlew packages:rn-tester:android:app:assembleRelease
|
||||
|
||||
# Wait for AVD to finish booting before running tests
|
||||
- run:
|
||||
name: Wait for Android Virtual Device
|
||||
command: source scripts/android-setup.sh && waitForAVD
|
||||
|
||||
- report_bundle_size:
|
||||
platform: android
|
||||
@@ -767,18 +819,6 @@ jobs:
|
||||
- run_e2e:
|
||||
platform: android
|
||||
|
||||
# -------------------------
|
||||
# JOBS: Test Android Docker Image
|
||||
# -------------------------
|
||||
test_android_docker_image:
|
||||
machine:
|
||||
image: ubuntu-2004:202010-01
|
||||
steps:
|
||||
- checkout
|
||||
- run:
|
||||
name: Try to build React Native inside the Docker Container
|
||||
command: npm run docker-build-android
|
||||
|
||||
# -------------------------
|
||||
# JOBS: Test Android Template
|
||||
# -------------------------
|
||||
@@ -812,7 +852,7 @@ jobs:
|
||||
command: |
|
||||
REPO_ROOT=$(pwd)
|
||||
node ./scripts/set-rn-template-version.js "file:$REPO_ROOT/build/$(cat build/react-native-package-version)"
|
||||
node ./scripts/template/initialize.js --reactNativeRootPath $REPO_ROOT --templateName $PROJECT_NAME --templateConfigPath "$REPO_ROOT/packages/react-native" --directory "/tmp/$PROJECT_NAME"
|
||||
node ./scripts/template/initialize.js --reactNativeRootPath $REPO_ROOT --templateName $PROJECT_NAME --templateConfigPath $REPO_ROOT --directory "/tmp/$PROJECT_NAME"
|
||||
- run:
|
||||
name: Build the template application for << parameters.flavor >> with Architecture set to << parameters.architecture >>, and using the << parameters.jsengine>> JS engine.
|
||||
command: |
|
||||
@@ -829,10 +869,6 @@ jobs:
|
||||
fi
|
||||
./gradlew assemble<< parameters.flavor >> -PREACT_NATIVE_MAVEN_LOCAL_REPO=/root/react-native/maven-local
|
||||
|
||||
- store_artifacts:
|
||||
path: /tmp/$PROJECT_NAME/android/app/build/outputs/apk/
|
||||
destination: template-apk
|
||||
|
||||
# -------------------------
|
||||
# JOBS: Test iOS Template
|
||||
# -------------------------
|
||||
@@ -864,10 +900,6 @@ jobs:
|
||||
description: Which kind of option we want to use for `use_frameworks!`
|
||||
type: enum
|
||||
enum: ["StaticLibraries", "StaticFrameworks", "DynamicFrameworks"]
|
||||
ruby_version:
|
||||
default: "2.6.10"
|
||||
description: The version of ruby that must be used
|
||||
type: string
|
||||
environment:
|
||||
- PROJECT_NAME: "iOSTemplateProject"
|
||||
- HERMES_WS_DIR: *hermes_workspace_root
|
||||
@@ -877,8 +909,6 @@ jobs:
|
||||
- attach_workspace:
|
||||
at: .
|
||||
- *attach_hermes_workspace
|
||||
- setup_ruby:
|
||||
ruby_version: << parameters.ruby_version >>
|
||||
- when:
|
||||
condition:
|
||||
equal: ["Hermes", << parameters.jsengine >>]
|
||||
@@ -887,7 +917,7 @@ jobs:
|
||||
name: Set HERMES_ENGINE_TARBALL_PATH
|
||||
command: |
|
||||
BUILD_TYPE="<< parameters.flavor >>"
|
||||
TARBALL_FILENAME=$(node ./packages/react-native/scripts/hermes/get-tarball-name.js --buildType "$BUILD_TYPE")
|
||||
TARBALL_FILENAME=$(node ./scripts/hermes/get-tarball-name.js --buildType "$BUILD_TYPE")
|
||||
echo "export HERMES_ENGINE_TARBALL_PATH=$HERMES_WS_DIR/hermes-runtime-darwin/$TARBALL_FILENAME" >> $BASH_ENV
|
||||
- run:
|
||||
name: Create iOS template project
|
||||
@@ -896,12 +926,14 @@ jobs:
|
||||
PACKAGE=$(cat build/react-native-package-version)
|
||||
PATH_TO_PACKAGE="$REPO_ROOT/build/$PACKAGE"
|
||||
node ./scripts/set-rn-template-version.js "file:$PATH_TO_PACKAGE"
|
||||
node ./scripts/template/initialize.js --reactNativeRootPath $REPO_ROOT --templateName $PROJECT_NAME --templateConfigPath "$REPO_ROOT/packages/react-native" --directory "/tmp/$PROJECT_NAME"
|
||||
node ./scripts/template/initialize.js --reactNativeRootPath $REPO_ROOT --templateName $PROJECT_NAME --templateConfigPath $REPO_ROOT --directory "/tmp/$PROJECT_NAME"
|
||||
- run:
|
||||
name: Install iOS dependencies - Configuration << parameters.flavor >>; New Architecture << parameters.architecture >>; JS Engine << parameters.jsengine>>; Flipper << parameters.flipper >>
|
||||
command: |
|
||||
cd /tmp/$PROJECT_NAME/ios
|
||||
|
||||
bundle install
|
||||
|
||||
if [[ << parameters.flavor >> == "Release" ]]; then
|
||||
export PRODUCTION=1
|
||||
fi
|
||||
@@ -924,7 +956,6 @@ jobs:
|
||||
export USE_FRAMEWORKS=dynamic
|
||||
fi
|
||||
|
||||
bundle install
|
||||
bundle exec pod install
|
||||
- run:
|
||||
name: Build template project
|
||||
@@ -951,10 +982,6 @@ jobs:
|
||||
description: Which React Native architecture to use. Must be one of "OldArch", "NewArch".
|
||||
type: enum
|
||||
enum: ["NewArch", "OldArch"]
|
||||
ruby_version:
|
||||
default: "2.6.10"
|
||||
description: The version of ruby that must be used
|
||||
type: string
|
||||
steps:
|
||||
- checkout_code_with_cache
|
||||
- run_yarn
|
||||
@@ -967,8 +994,7 @@ jobs:
|
||||
name: Delete iOS Simulators
|
||||
background: true
|
||||
command: sudo rm -rf /Library/Developer/CoreSimulator/Profiles/Runtimes/
|
||||
- setup_ruby:
|
||||
ruby_version: << parameters.ruby_version >>
|
||||
|
||||
- with_hermes_tarball_cache_span:
|
||||
set_tarball_path: True
|
||||
steps:
|
||||
@@ -985,10 +1011,7 @@ jobs:
|
||||
export USE_HERMES=0
|
||||
fi
|
||||
|
||||
cd packages/rn-tester
|
||||
|
||||
bundle install
|
||||
bundle exec pod install
|
||||
cd packages/rn-tester && bundle install && bundle exec pod install
|
||||
|
||||
- run:
|
||||
name: Build RNTester
|
||||
@@ -1014,23 +1037,9 @@ jobs:
|
||||
- ANDROID_BUILD_VERSION: 33
|
||||
- ANDROID_TOOLS_VERSION: 33.0.0
|
||||
- GRADLE_OPTS: -Dorg.gradle.daemon=false
|
||||
- CHOCO_CACHE_DIR: "C:\\ChocoCache"
|
||||
steps:
|
||||
- checkout_code_with_cache
|
||||
|
||||
- restore_cache:
|
||||
keys:
|
||||
- *windows_choco_cache_key
|
||||
|
||||
- run:
|
||||
name: Choco cache
|
||||
# Cache our dependencies which can be flakey to download
|
||||
command: |
|
||||
if (!Test-Path $env:CHOCO_CACHE_DIR) {
|
||||
mkdir $env:CHOCO_CACHE_DIR
|
||||
}
|
||||
choco config set --name cacheLocation --value $env:CHOCO_CACHE_DIR
|
||||
|
||||
- run:
|
||||
name: Disable NVM
|
||||
# Use choco to manage node versions due to https://github.com/npm/cli/issues/4234
|
||||
@@ -1046,9 +1055,6 @@ jobs:
|
||||
name: Enable Yarn with corepack
|
||||
command: corepack enable
|
||||
|
||||
# it looks like that, last week, envinfo released version 7.9.0 which does not works
|
||||
# with Windows. I have opened an issue here: https://github.com/tabrindle/envinfo/issues/238
|
||||
# TODO: T156811874 - Revert this to npx envinfo@latest when the issue is addressed
|
||||
- run:
|
||||
name: Display Environment info
|
||||
command: |
|
||||
@@ -1062,20 +1068,16 @@ jobs:
|
||||
- run:
|
||||
name: "Yarn: Install Dependencies"
|
||||
command: yarn install --frozen-lockfile --non-interactive
|
||||
|
||||
- save_cache:
|
||||
key: *windows_yarn_cache_key
|
||||
paths:
|
||||
- C:\Users\circleci\AppData\Local\Yarn
|
||||
|
||||
# Try to install the SDK up to 3 times, since network flakiness can cause install failures
|
||||
# Using a timeout of 9 mins, as circle ci will timeout if there is no output for 10 mins
|
||||
- run:
|
||||
name: Install Android SDK Tools
|
||||
command: choco install android-sdk;
|
||||
|
||||
- save_cache:
|
||||
key: *windows_choco_cache_key
|
||||
paths:
|
||||
- $env:CHOCO_CACHE_DIR
|
||||
command: choco install android-sdk --timeout 540; if (!$?) { choco install android-sdk --timeout 540 --force --forcedependencies}; if (!$?) { choco install android-sdk --force --forcedependencies}
|
||||
|
||||
- run:
|
||||
name: Setup Android SDKs
|
||||
@@ -1141,15 +1143,23 @@ jobs:
|
||||
- image: debian:11
|
||||
environment:
|
||||
- HERMES_WS_DIR: *hermes_workspace_root
|
||||
- HERMES_VERSION_FILE: "packages/react-native/sdks/.hermesversion"
|
||||
- BUILD_FROM_SOURCE: true
|
||||
- HERMES_VERSION_FILE: "sdks/.hermesversion"
|
||||
- REACT_NATIVE_CI: true
|
||||
steps:
|
||||
- run:
|
||||
name: Install dependencies
|
||||
command: |
|
||||
apt update
|
||||
apt install -y wget git curl
|
||||
curl -sL https://deb.nodesource.com/setup_16.x | bash -
|
||||
|
||||
apt-get update
|
||||
apt-get install -y ca-certificates curl gnupg
|
||||
mkdir -p /etc/apt/keyrings
|
||||
curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg
|
||||
NODE_MAJOR=16
|
||||
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list
|
||||
apt-get update
|
||||
|
||||
apt install -y nodejs
|
||||
npm install --global yarn
|
||||
- checkout
|
||||
@@ -1160,10 +1170,8 @@ jobs:
|
||||
mkdir -p "/tmp/hermes" "/tmp/hermes/download" "/tmp/hermes/hermes"
|
||||
|
||||
if [ -f "$HERMES_VERSION_FILE" ]; then
|
||||
echo "Hermes version file found. Using the latest commit"
|
||||
cat $HERMES_VERSION_FILE > /tmp/hermes/hermesversion
|
||||
else
|
||||
echo "No hermes version file found. Using the latest commit"
|
||||
HERMES_TAG_SHA=$(git ls-remote https://github.com/facebook/hermes main | cut -f 1 | tr -d '[:space:]')
|
||||
echo $HERMES_TAG_SHA > /tmp/hermes/hermesversion
|
||||
fi
|
||||
@@ -1173,9 +1181,9 @@ jobs:
|
||||
- run:
|
||||
name: Download Hermes tarball
|
||||
command: |
|
||||
node packages/react-native/scripts/hermes/prepare-hermes-for-build $CIRCLE_PULL_REQUEST
|
||||
cp packages/react-native/sdks/download/* $HERMES_WS_DIR/download/.
|
||||
cp -r packages/react-native/sdks/hermes/* $HERMES_WS_DIR/hermes/.
|
||||
node scripts/hermes/prepare-hermes-for-build $CIRCLE_PULL_REQUEST
|
||||
cp sdks/download/* $HERMES_WS_DIR/download/.
|
||||
cp -r sdks/hermes/* $HERMES_WS_DIR/hermes/.
|
||||
|
||||
cat /tmp/hermes/hermesversion
|
||||
- save_cache:
|
||||
@@ -1269,9 +1277,9 @@ jobs:
|
||||
- run:
|
||||
name: Set up workspace
|
||||
command: |
|
||||
mkdir -p $HERMES_OSXBIN_ARTIFACTS_DIR ./packages/react-native/sdks/hermes
|
||||
cp -r $HERMES_WS_DIR/hermes/* ./packages/react-native/sdks/hermes/.
|
||||
cp -r ./packages/react-native/sdks/hermes-engine/utils ./packages/react-native/sdks/hermes/.
|
||||
mkdir -p $HERMES_OSXBIN_ARTIFACTS_DIR ./sdks/hermes
|
||||
cp -r $HERMES_WS_DIR/hermes/* ./sdks/hermes/.
|
||||
cp -r ./sdks/hermes-engine/utils ./sdks/hermes/.
|
||||
- brew_install:
|
||||
package: cmake
|
||||
- with_hermes_tarball_cache_span:
|
||||
@@ -1283,12 +1291,12 @@ jobs:
|
||||
- run:
|
||||
name: Build the Hermes Mac frameworks
|
||||
command: |
|
||||
cd ./packages/react-native/sdks/hermes || exit 1
|
||||
cd ./sdks/hermes || exit 1
|
||||
BUILD_TYPE="<< parameters.flavor >>" ./utils/build-mac-framework.sh
|
||||
- run:
|
||||
name: Build the Hermes iOS frameworks
|
||||
command: |
|
||||
cd ./packages/react-native/sdks/hermes || exit 1
|
||||
cd ./sdks/hermes || exit 1
|
||||
BUILD_TYPE="<< parameters.flavor >>" ./utils/build-ios-framework.sh
|
||||
- run:
|
||||
name: Package the Hermes Apple frameworks
|
||||
@@ -1298,12 +1306,12 @@ jobs:
|
||||
|
||||
TARBALL_OUTPUT_DIR=$(mktemp -d /tmp/hermes-tarball-output-XXXXXXXX)
|
||||
|
||||
TARBALL_FILENAME=$(node ./packages/react-native/scripts/hermes/get-tarball-name.js --buildType "$BUILD_TYPE")
|
||||
TARBALL_FILENAME=$(node ./scripts/hermes/get-tarball-name.js --buildType "$BUILD_TYPE")
|
||||
|
||||
echo "Packaging Hermes Apple frameworks for $BUILD_TYPE build type"
|
||||
|
||||
TARBALL_OUTPUT_PATH=$(node ./packages/react-native/scripts/hermes/create-tarball.js \
|
||||
--inputDir ./packages/react-native/sdks/hermes \
|
||||
TARBALL_OUTPUT_PATH=$(node ./scripts/hermes/create-tarball.js \
|
||||
--inputDir ./sdks/hermes \
|
||||
--buildType "$BUILD_TYPE" \
|
||||
--outputDir $TARBALL_OUTPUT_DIR)
|
||||
|
||||
@@ -1467,29 +1475,31 @@ jobs:
|
||||
- run:
|
||||
name: Copy Hermes binaries
|
||||
command: |
|
||||
mkdir -p ./packages/react-native/sdks/hermesc ./packages/react-native/sdks/hermesc/osx-bin ./packages/react-native/sdks/hermesc/win64-bin ./packages/react-native/sdks/hermesc/linux64-bin
|
||||
mkdir -p ./sdks/hermesc ./sdks/hermesc/osx-bin ./sdks/hermesc/win64-bin ./sdks/hermesc/linux64-bin
|
||||
|
||||
# When build_hermes_macos runs as a matrix, it outputs
|
||||
if [[ -d $HERMES_WS_DIR/osx-bin/Release ]]; then
|
||||
cp -r $HERMES_WS_DIR/osx-bin/Release/* ./packages/react-native/sdks/hermesc/osx-bin/.
|
||||
cp -r $HERMES_WS_DIR/osx-bin/Release/* ./sdks/hermesc/osx-bin/.
|
||||
elif [[ -d $HERMES_WS_DIR/osx-bin/Debug ]]; then
|
||||
cp -r $HERMES_WS_DIR/osx-bin/Debug/* ./packages/react-native/sdks/hermesc/osx-bin/.
|
||||
cp -r $HERMES_WS_DIR/osx-bin/Debug/* ./sdks/hermesc/osx-bin/.
|
||||
else
|
||||
ls $HERMES_WS_DIR/osx-bin || echo "hermesc macOS artifacts directory missing."
|
||||
echo "Could not locate macOS hermesc binary."; exit 1;
|
||||
fi
|
||||
|
||||
cp -r $HERMES_WS_DIR/win64-bin/* ./packages/react-native/sdks/hermesc/win64-bin/.
|
||||
cp -r $HERMES_WS_DIR/linux64-bin/* ./packages/react-native/sdks/hermesc/linux64-bin/.
|
||||
mkdir -p ./packages/react-native/ReactAndroid/external-artifacts/artifacts/
|
||||
cp $HERMES_WS_DIR/hermes-runtime-darwin/hermes-ios-debug.tar.gz ./packages/react-native/ReactAndroid/external-artifacts/artifacts/hermes-ios-debug.tar.gz
|
||||
cp $HERMES_WS_DIR/hermes-runtime-darwin/hermes-ios-release.tar.gz ./packages/react-native/ReactAndroid/external-artifacts/artifacts/hermes-ios-release.tar.gz
|
||||
cp -r $HERMES_WS_DIR/win64-bin/* ./sdks/hermesc/win64-bin/.
|
||||
cp -r $HERMES_WS_DIR/linux64-bin/* ./sdks/hermesc/linux64-bin/.
|
||||
mkdir -p ./ReactAndroid/external-artifacts/artifacts/
|
||||
cp $HERMES_WS_DIR/hermes-runtime-darwin/hermes-ios-debug.tar.gz ./ReactAndroid/external-artifacts/artifacts/hermes-ios-debug.tar.gz
|
||||
cp $HERMES_WS_DIR/hermes-runtime-darwin/hermes-ios-release.tar.gz ./ReactAndroid/external-artifacts/artifacts/hermes-ios-release.tar.gz
|
||||
|
||||
- run_yarn
|
||||
- download_gradle_dependencies
|
||||
|
||||
# START: Stables and nightlies
|
||||
# This conditional step sets up the necessary credentials for publishing react-native to npm.
|
||||
# This conditional step sets up the necessary credentials for publishing react-native to npm,
|
||||
# and for interacting with GitHub as the react-native-bot account. Important: these steps
|
||||
# should not be allowed to run on commits from pull requests.
|
||||
- when:
|
||||
condition:
|
||||
or:
|
||||
@@ -1502,7 +1512,7 @@ jobs:
|
||||
- run: node ./scripts/publish-npm.js --<< parameters.release_type >>
|
||||
- run:
|
||||
name: Zip Hermes Native Symbols
|
||||
command: zip -r /tmp/hermes-native-symbols.zip ~/react-native/packages/react-native/ReactAndroid/hermes-engine/build/intermediates/cmake/
|
||||
command: zip -r /tmp/hermes-native-symbols.zip ~/react-native/ReactAndroid/hermes-engine/build/intermediates/cmake/
|
||||
- store_artifacts:
|
||||
path: /tmp/hermes-native-symbols.zip
|
||||
- run:
|
||||
@@ -1525,10 +1535,8 @@ jobs:
|
||||
name: Build release package as a job artifact
|
||||
command: |
|
||||
mkdir -p build
|
||||
|
||||
FILENAME=$(cd packages/react-native; npm pack | tail -1)
|
||||
mv packages/react-native/$FILENAME build/
|
||||
|
||||
FILENAME=$(npm pack)
|
||||
mv $FILENAME build/
|
||||
echo $FILENAME > build/react-native-package-version
|
||||
- store_artifacts:
|
||||
path: ~/react-native/build/
|
||||
@@ -1564,6 +1572,19 @@ jobs:
|
||||
-d "{\"event_type\": \"publish\", \"client_payload\": { \"version\": \"${CIRCLE_TAG:1}\" }}"
|
||||
# END: Stable releases
|
||||
|
||||
poll_maven:
|
||||
docker:
|
||||
- image: cimg/node:current
|
||||
resource_class: small
|
||||
steps:
|
||||
- checkout_code_with_cache
|
||||
- run_yarn
|
||||
- run:
|
||||
name: Poll Maven for Artifacts
|
||||
command: |
|
||||
node scripts/circleci/poll-maven.js
|
||||
|
||||
|
||||
# -------------------------
|
||||
# JOBS: Nightly
|
||||
# -------------------------
|
||||
@@ -1593,7 +1614,7 @@ jobs:
|
||||
# PIPELINE PARAMETERS
|
||||
# -------------------------
|
||||
parameters:
|
||||
run_release_workflow:
|
||||
run_package_release_workflow_only:
|
||||
default: false
|
||||
type: boolean
|
||||
|
||||
@@ -1605,32 +1626,18 @@ parameters:
|
||||
default: "9999"
|
||||
type: string
|
||||
|
||||
run_nightly_workflow:
|
||||
default: false
|
||||
type: boolean
|
||||
|
||||
# -------------------------
|
||||
# WORKFLOWS
|
||||
#
|
||||
# When creating a new workflow, make sure to include condition:
|
||||
#
|
||||
# when:
|
||||
# and:
|
||||
# - equal: [ false, << pipeline.parameters.run_release_workflow >> ]
|
||||
# - equal: [ false, << pipeline.parameters.run_nightly_workflow >> ]
|
||||
# WORK FLOWS
|
||||
#
|
||||
# When creating a new workflow, make sure to include condition `unless: << pipeline.parameters.run_package_release_workflow_only >>`
|
||||
# It's setup this way so we can trigger a release via a POST
|
||||
# See limitations: https://support.circleci.com/hc/en-us/articles/360050351292-How-to-trigger-a-workflow-via-CircleCI-API-v2
|
||||
# -------------------------
|
||||
|
||||
workflows:
|
||||
version: 2
|
||||
|
||||
tests:
|
||||
when:
|
||||
and:
|
||||
- equal: [ false, << pipeline.parameters.run_release_workflow >> ]
|
||||
- equal: [ false, << pipeline.parameters.run_nightly_workflow >> ]
|
||||
unless: << pipeline.parameters.run_package_release_workflow_only >>
|
||||
jobs:
|
||||
- prepare_hermes_workspace
|
||||
- build_hermesc_linux:
|
||||
@@ -1656,7 +1663,6 @@ workflows:
|
||||
run_disabled_tests: false
|
||||
- test_android:
|
||||
run_disabled_tests: false
|
||||
- test_android_docker_image
|
||||
- test_android_template:
|
||||
requires:
|
||||
- build_npm_package
|
||||
@@ -1665,20 +1671,7 @@ workflows:
|
||||
architecture: ["NewArch", "OldArch"]
|
||||
jsengine: ["Hermes", "JSC"]
|
||||
flavor: ["Debug", "Release"]
|
||||
- test_ios_template:
|
||||
requires:
|
||||
- build_npm_package
|
||||
name: "Test Template with Ruby 2.7.7"
|
||||
ruby_version: "2.7.7"
|
||||
architecture: "NewArch"
|
||||
flavor: "Debug"
|
||||
- test_ios_template:
|
||||
requires:
|
||||
- build_npm_package
|
||||
name: "Test Template with Ruby 3.2.0"
|
||||
ruby_version: "3.2.0"
|
||||
architecture: "NewArch"
|
||||
flavor: "Debug"
|
||||
- test_buck
|
||||
- test_ios_template:
|
||||
requires:
|
||||
- build_npm_package
|
||||
@@ -1705,6 +1698,11 @@ workflows:
|
||||
jsengine: "Hermes"
|
||||
flipper: "WithFlipper"
|
||||
use_frameworks: "DynamicFrameworks"
|
||||
- architecture: "NewArch"
|
||||
flavor: "Release"
|
||||
jsengine: "Hermes"
|
||||
flipper: "WithoutFlipper"
|
||||
use_frameworks: "StaticFrameworks"
|
||||
- architecture: "NewArch"
|
||||
flavor: "Release"
|
||||
jsengine: "Hermes"
|
||||
@@ -1725,6 +1723,11 @@ workflows:
|
||||
jsengine: "JSC"
|
||||
flipper: "WithFlipper"
|
||||
use_frameworks: "DynamicFrameworks"
|
||||
- architecture: "NewArch"
|
||||
flavor: "Release"
|
||||
jsengine: "JSC"
|
||||
flipper: "WithoutFlipper"
|
||||
use_frameworks: "StaticFrameworks"
|
||||
- architecture: "NewArch"
|
||||
flavor: "Release"
|
||||
jsengine: "JSC"
|
||||
@@ -1765,11 +1768,21 @@ workflows:
|
||||
jsengine: "Hermes"
|
||||
flipper: "WithFlipper"
|
||||
use_frameworks: "StaticFrameworks"
|
||||
- architecture: "NewArch"
|
||||
flavor: "Debug"
|
||||
jsengine: "Hermes"
|
||||
flipper: "WithoutFlipper"
|
||||
use_frameworks: "StaticFrameworks"
|
||||
- architecture: "NewArch"
|
||||
flavor: "Debug"
|
||||
jsengine: "JSC"
|
||||
flipper: "WithFlipper"
|
||||
use_frameworks: "StaticFrameworks"
|
||||
- architecture: "NewArch"
|
||||
flavor: "Debug"
|
||||
jsengine: "JSC"
|
||||
flipper: "WithoutFlipper"
|
||||
use_frameworks: "StaticFrameworks"
|
||||
- architecture: "OldArch"
|
||||
flavor: "Debug"
|
||||
jsengine: "Hermes"
|
||||
@@ -1810,18 +1823,6 @@ workflows:
|
||||
jsengine: "JSC"
|
||||
flipper: "WithFlipper"
|
||||
use_frameworks: "DynamicFrameworks"
|
||||
- test_ios_rntester:
|
||||
requires:
|
||||
- build_hermes_macos
|
||||
name: "Test RNTester with Ruby 2.7.7"
|
||||
ruby_version: "2.7.7"
|
||||
architecture: "NewArch"
|
||||
- test_ios_rntester:
|
||||
requires:
|
||||
- build_hermes_macos
|
||||
name: "Test RNTester with Ruby 3.2.0"
|
||||
ruby_version: "3.2.0"
|
||||
architecture: "NewArch"
|
||||
- test_ios_rntester:
|
||||
requires:
|
||||
- build_hermes_macos
|
||||
@@ -1829,18 +1830,6 @@ workflows:
|
||||
parameters:
|
||||
architecture: ["NewArch", "OldArch"]
|
||||
jsengine: ["Hermes", "JSC"]
|
||||
- test_ios:
|
||||
name: "Test iOS with Ruby 2.7.7"
|
||||
run_unit_tests: true
|
||||
requires:
|
||||
- build_hermes_macos
|
||||
ruby_version: "2.7.7"
|
||||
- test_ios:
|
||||
name: "Test iOS with Ruby 3.2.0"
|
||||
run_unit_tests: true
|
||||
requires:
|
||||
- build_hermes_macos
|
||||
ruby_version: "3.2.0"
|
||||
- test_ios:
|
||||
run_unit_tests: true
|
||||
requires:
|
||||
@@ -1863,16 +1852,16 @@ workflows:
|
||||
|
||||
# This workflow should only be triggered by release script
|
||||
package_release:
|
||||
when: << pipeline.parameters.run_release_workflow >>
|
||||
when: << pipeline.parameters.run_package_release_workflow_only >>
|
||||
jobs:
|
||||
# This job will push a tag that will trigger the publish_release workflow
|
||||
# This job will trigger publish_release workflow
|
||||
- prepare_package_for_release:
|
||||
name: prepare_package_for_release
|
||||
version: << pipeline.parameters.release_version >>
|
||||
latest : << pipeline.parameters.release_latest >>
|
||||
|
||||
# This job will run only when a tag is published due to all the jobs being filtered.
|
||||
publish_release:
|
||||
unless: << pipeline.parameters.run_package_release_workflow_only >>
|
||||
jobs:
|
||||
- prepare_hermes_workspace:
|
||||
filters: *only_release_tags
|
||||
@@ -1894,18 +1883,18 @@ workflows:
|
||||
# This job will trigger when a version tag is pushed (by package_release)
|
||||
- build_npm_package:
|
||||
name: build_and_publish_npm_package
|
||||
context: react-native-bot
|
||||
release_type: "release"
|
||||
filters: *only_release_tags
|
||||
requires:
|
||||
- build_hermesc_linux
|
||||
- build_hermes_macos
|
||||
- build_hermesc_windows
|
||||
- poll_maven:
|
||||
requires:
|
||||
- build_and_publish_npm_package
|
||||
|
||||
package_and_publish_release_dryrun:
|
||||
when:
|
||||
and:
|
||||
- equal: [ false, << pipeline.parameters.run_release_workflow >> ]
|
||||
- equal: [ false, << pipeline.parameters.run_nightly_workflow >> ]
|
||||
jobs:
|
||||
- prepare_package_for_release:
|
||||
name: prepare_package_for_release
|
||||
@@ -1929,6 +1918,7 @@ workflows:
|
||||
- prepare_hermes_workspace
|
||||
- build_npm_package:
|
||||
name: build_and_publish_npm_package
|
||||
context: react-native-bot
|
||||
release_type: "dry-run"
|
||||
requires:
|
||||
- build_hermesc_linux
|
||||
@@ -1936,10 +1926,7 @@ workflows:
|
||||
- build_hermesc_windows
|
||||
|
||||
analysis:
|
||||
when:
|
||||
and:
|
||||
- equal: [ false, << pipeline.parameters.run_release_workflow >> ]
|
||||
- equal: [ false, << pipeline.parameters.run_nightly_workflow >> ]
|
||||
unless: << pipeline.parameters.run_package_release_workflow_only >>
|
||||
jobs:
|
||||
# Run lints on every commit
|
||||
- analyze_code
|
||||
@@ -1951,9 +1938,14 @@ workflows:
|
||||
- js_coverage
|
||||
|
||||
nightly:
|
||||
when: << pipeline.parameters.run_nightly_workflow >>
|
||||
unless: << pipeline.parameters.run_package_release_workflow_only >>
|
||||
triggers:
|
||||
- schedule:
|
||||
<<: *main_only
|
||||
cron: "0 20 * * *"
|
||||
jobs:
|
||||
- nightly_job
|
||||
|
||||
- prepare_hermes_workspace
|
||||
- build_hermesc_linux:
|
||||
requires:
|
||||
@@ -1975,10 +1967,6 @@ workflows:
|
||||
- build_hermesc_windows
|
||||
|
||||
publish_bumped_packages:
|
||||
when:
|
||||
and:
|
||||
- equal: [ false, << pipeline.parameters.run_release_workflow >> ]
|
||||
- equal: [ false, << pipeline.parameters.run_nightly_workflow >> ]
|
||||
jobs:
|
||||
- find_and_publish_bumped_packages:
|
||||
<<: *main_or_stable_only
|
||||
|
||||
+13
-5
@@ -15,15 +15,23 @@ uplinks:
|
||||
maxSockets: 40
|
||||
maxFreeSockets: 10
|
||||
packages:
|
||||
# Get @react-native/normalize-color from npm registry, since its used in deprecated-react-native-prop-types package
|
||||
'@react-native/normalize-color':
|
||||
access: $all
|
||||
publish: $authenticated
|
||||
proxy: npmjs
|
||||
# Group and isolate all local packages, avoid being proxy from outside
|
||||
'@react-native/*':
|
||||
access: $all
|
||||
publish: $all
|
||||
# The below specific entries can be removed once they are renamed and have the @react-native prefix
|
||||
'@react-native-community/eslint-config':
|
||||
access: $all
|
||||
publish: $all
|
||||
'@react-native-community/eslint-plugin':
|
||||
access: $all
|
||||
publish: $all
|
||||
'react-native-codegen':
|
||||
access: $all
|
||||
publish: $all
|
||||
'react-native-gradle-plugin':
|
||||
access: $all
|
||||
publish: $all
|
||||
'@*/*':
|
||||
access: $all
|
||||
publish: $authenticated
|
||||
|
||||
+3
-3
@@ -1,9 +1,9 @@
|
||||
**/main.js
|
||||
**/staticBundle.js
|
||||
docs/generatedComponentApiDocs.js
|
||||
packages/react-native/flow/
|
||||
packages/react-native/Libraries/Renderer/*
|
||||
packages/react-native/Libraries/vendor/**/*
|
||||
flow/
|
||||
Libraries/Renderer/*
|
||||
Libraries/vendor/**/*
|
||||
node_modules/
|
||||
packages/*/node_modules
|
||||
packages/react-native-codegen/lib
|
||||
|
||||
+5
-15
@@ -16,7 +16,7 @@ require('eslint-plugin-lint').load(path.join(__dirname, 'tools/eslint/rules'));
|
||||
module.exports = {
|
||||
root: true,
|
||||
|
||||
extends: ['@react-native'],
|
||||
extends: ['@react-native-community'],
|
||||
|
||||
plugins: ['@react-native/eslint-plugin-specs', 'lint'],
|
||||
|
||||
@@ -36,9 +36,9 @@ module.exports = {
|
||||
},
|
||||
|
||||
{
|
||||
files: ['packages/react-native/Libraries/**/*.js'],
|
||||
files: ['Libraries/**/*.js'],
|
||||
rules: {
|
||||
'@react-native/platform-colors': 2,
|
||||
'@react-native-community/platform-colors': 2,
|
||||
'@react-native/specs/react-native-modules': 2,
|
||||
'lint/no-haste-imports': 2,
|
||||
'lint/no-react-native-imports': 2,
|
||||
@@ -47,7 +47,7 @@ module.exports = {
|
||||
},
|
||||
},
|
||||
{
|
||||
files: ['packages/react-native/flow-typed/**/*.js'],
|
||||
files: ['flow-typed/**/*.js'],
|
||||
rules: {
|
||||
'lint/valid-flow-typed-signature': 2,
|
||||
'no-unused-vars': 0,
|
||||
@@ -59,7 +59,7 @@ module.exports = {
|
||||
'**/__fixtures__/**/*.js',
|
||||
'**/__mocks__/**/*.js',
|
||||
'**/__tests__/**/*.js',
|
||||
'packages/react-native/jest/**/*.js',
|
||||
'jest/**/*.js',
|
||||
'packages/rn-tester/**/*.js',
|
||||
],
|
||||
globals: {
|
||||
@@ -91,15 +91,5 @@ module.exports = {
|
||||
'react/self-closing-comp': 'off',
|
||||
},
|
||||
},
|
||||
{
|
||||
files: ['**/*.d.ts'],
|
||||
plugins: ['redundant-undefined'],
|
||||
rules: {
|
||||
'redundant-undefined/redundant-undefined': [
|
||||
'error',
|
||||
{followExactOptionalPropertyTypes: true},
|
||||
],
|
||||
},
|
||||
},
|
||||
],
|
||||
};
|
||||
|
||||
+10
-11
@@ -3,7 +3,7 @@
|
||||
.*/*[.]android.js
|
||||
|
||||
; Ignore templates for 'react-native init'
|
||||
<PROJECT_ROOT>/packages/react-native/template/.*
|
||||
<PROJECT_ROOT>/template/.*
|
||||
|
||||
; Ignore the Dangerfile
|
||||
<PROJECT_ROOT>/packages/react-native-bots/dangerfile.js
|
||||
@@ -12,7 +12,7 @@
|
||||
<PROJECT_ROOT>/\.buckd/
|
||||
|
||||
; Flow doesn't support platforms
|
||||
.*/packages/react-native/Libraries/Utilities/LoadingView.js
|
||||
.*/Libraries/Utilities/LoadingView.js
|
||||
|
||||
.*/node_modules/resolve/test/resolver/malformed_package_json/package\.json$
|
||||
|
||||
@@ -25,13 +25,10 @@
|
||||
.*/node_modules/.*
|
||||
|
||||
[libs]
|
||||
packages/react-native/interface.js
|
||||
packages/react-native/flow/
|
||||
packages/react-native/flow-typed/
|
||||
interface.js
|
||||
flow/
|
||||
|
||||
[options]
|
||||
enums=true
|
||||
|
||||
emoji=true
|
||||
|
||||
exact_by_default=true
|
||||
@@ -44,9 +41,9 @@ module.file_ext=.ios.js
|
||||
|
||||
munge_underscores=true
|
||||
|
||||
module.name_mapper='^react-native$' -> '<PROJECT_ROOT>/packages/react-native/index.js'
|
||||
module.name_mapper='^react-native/\(.*\)$' -> '<PROJECT_ROOT>/packages/react-native\1'
|
||||
module.name_mapper='^@?[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> '<PROJECT_ROOT>/packages/react-native/Libraries/Image/RelativeImageStub'
|
||||
module.name_mapper='^react-native$' -> '<PROJECT_ROOT>/index.js'
|
||||
module.name_mapper='^react-native/\(.*\)$' -> '<PROJECT_ROOT>/\1'
|
||||
module.name_mapper='^@?[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> '<PROJECT_ROOT>/Libraries/Image/RelativeImageStub'
|
||||
|
||||
suppress_type=$FlowIssue
|
||||
suppress_type=$FlowFixMe
|
||||
@@ -54,6 +51,8 @@ suppress_type=$FlowFixMeProps
|
||||
suppress_type=$FlowFixMeState
|
||||
suppress_type=$FlowFixMeEmpty
|
||||
|
||||
inference_mode=constrain_writes
|
||||
|
||||
[lints]
|
||||
sketchy-null-number=warn
|
||||
sketchy-null-mixed=warn
|
||||
@@ -74,4 +73,4 @@ untyped-import
|
||||
untyped-type-import
|
||||
|
||||
[version]
|
||||
^0.202.0
|
||||
^0.191.0
|
||||
|
||||
+10
-11
@@ -3,7 +3,7 @@
|
||||
.*/*[.]ios.js
|
||||
|
||||
; Ignore templates for 'react-native init'
|
||||
<PROJECT_ROOT>/packages/react-native/template/.*
|
||||
<PROJECT_ROOT>/template/.*
|
||||
|
||||
; Ignore the Dangerfile
|
||||
<PROJECT_ROOT>/packages/react-native-bots/dangerfile.js
|
||||
@@ -12,7 +12,7 @@
|
||||
<PROJECT_ROOT>/\.buckd/
|
||||
|
||||
; Flow doesn't support platforms
|
||||
.*/packages/react-native/Libraries/Utilities/LoadingView.js
|
||||
.*/Libraries/Utilities/LoadingView.js
|
||||
|
||||
.*/node_modules/resolve/test/resolver/malformed_package_json/package\.json$
|
||||
|
||||
@@ -25,13 +25,10 @@
|
||||
.*/node_modules/.*
|
||||
|
||||
[libs]
|
||||
packages/react-native/interface.js
|
||||
packages/react-native/flow/
|
||||
packages/react-native/flow-typed/
|
||||
interface.js
|
||||
flow/
|
||||
|
||||
[options]
|
||||
enums=true
|
||||
|
||||
emoji=true
|
||||
|
||||
exact_by_default=true
|
||||
@@ -44,9 +41,9 @@ module.file_ext=.android.js
|
||||
|
||||
munge_underscores=true
|
||||
|
||||
module.name_mapper='^react-native$' -> '<PROJECT_ROOT>/packages/react-native/index.js'
|
||||
module.name_mapper='^react-native/\(.*\)$' -> '<PROJECT_ROOT>/packages/react-native\1'
|
||||
module.name_mapper='^@?[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> '<PROJECT_ROOT>/packages/react-native/Libraries/Image/RelativeImageStub'
|
||||
module.name_mapper='^react-native$' -> '<PROJECT_ROOT>/index.js'
|
||||
module.name_mapper='^react-native/\(.*\)$' -> '<PROJECT_ROOT>/\1'
|
||||
module.name_mapper='^@?[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> '<PROJECT_ROOT>/Libraries/Image/RelativeImageStub'
|
||||
|
||||
suppress_type=$FlowIssue
|
||||
suppress_type=$FlowFixMe
|
||||
@@ -54,6 +51,8 @@ suppress_type=$FlowFixMeProps
|
||||
suppress_type=$FlowFixMeState
|
||||
suppress_type=$FlowFixMeEmpty
|
||||
|
||||
inference_mode=constrain_writes
|
||||
|
||||
[lints]
|
||||
sketchy-null-number=warn
|
||||
sketchy-null-mixed=warn
|
||||
@@ -74,4 +73,4 @@ untyped-import
|
||||
untyped-type-import
|
||||
|
||||
[version]
|
||||
^0.202.0
|
||||
^0.191.0
|
||||
|
||||
@@ -10,15 +10,15 @@ body:
|
||||
id: description
|
||||
attributes:
|
||||
label: Description
|
||||
description: Please provide a clear and concise description of what the bug is. Include screenshots if needed. Test using the [latest React Native release](https://github.com/facebook/react-native/releases/latest) to make sure your issue has not already been fixed.
|
||||
description: Please provide a clear and concise description of what the bug is. Include screenshots if needed. Please test using the latest React Native release to make sure your issue has not already been fixed - https://reactnative.dev/docs/upgrading.html
|
||||
validations:
|
||||
required: true
|
||||
- type: input
|
||||
id: version
|
||||
attributes:
|
||||
label: React Native Version
|
||||
description: What is the latest version of react-native that this issue reproduces on? Please only list the highest version you tested. Bear in mind that only issues on [supported versions](https://github.com/reactwg/react-native-releases#which-versions-are-currently-supported) will be looked into.
|
||||
placeholder: ex. 0.71.0
|
||||
label: Version
|
||||
description: What react-native version does this appear on?
|
||||
placeholder: ex. 0.66.0
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
@@ -43,6 +43,6 @@ body:
|
||||
Please provide a Snack (https://snack.expo.dev/), a link to a repository on GitHub, or provide a minimal code example that reproduces the problem.
|
||||
You may provide a screenshot of the application if you think it is relevant to your bug report.
|
||||
Here are some tips for providing a minimal example: https://stackoverflow.com/help/mcve
|
||||
Please note that a reproducer is **mandatory**. Issues without reproducer are more likely to stall and will be closed.
|
||||
Please note that a reproducer is mandatory. Issues without reproducer are more likely to stall and will be closed.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
@@ -21,9 +21,9 @@ body:
|
||||
- type: input
|
||||
id: version
|
||||
attributes:
|
||||
label: React Native Version
|
||||
description: What is the latest version of react-native that this issue reproduces on? Please test against the latest stable version, and list only the highest version you tested. Bug reports against older versions are more likely to stall.
|
||||
placeholder: ex. 0.71.0
|
||||
label: Version
|
||||
description: What react-native version does this appear on? Please test against the latest stable version. Bug reports against older versions are more likely to stall.
|
||||
placeholder: ex. 0.68.0
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
@@ -48,6 +48,6 @@ body:
|
||||
Please provide a Snack (https://snack.expo.dev/), a link to a repository on GitHub, or provide a minimal code example that reproduces the problem.
|
||||
You may provide a screenshot of the application if you think it is relevant to your bug report.
|
||||
Here are some tips for providing a minimal example: https://stackoverflow.com/help/mcve
|
||||
Please note that a reproducer is **mandatory**. Issues without reproducer are more likely to stall and will be closed.
|
||||
Please note that a reproducer is mandatory. Issues without reproducer are more likely to stall and will be closed.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
@@ -5,7 +5,7 @@ body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Please use this form to file an issue if you have upgraded or are upgrading to [latest stable release](https://github.com/facebook/react-native/releases/latest) and have experienced a regression (something that used to work in previous version).
|
||||
Please use this form to file an issue if you have upgarded or are upgrading to [latest stable release](https://github.com/facebook/react-native/releases/latest) and have experienced a regression (something that used to work in previous version).
|
||||
- type: input
|
||||
id: new-version
|
||||
attributes:
|
||||
|
||||
@@ -6,16 +6,12 @@
|
||||
|
||||
## Changelog
|
||||
|
||||
<!-- Help reviewers and the release process by writing your own changelog entry.
|
||||
|
||||
Pick one each for the category and type tags:
|
||||
|
||||
[ANDROID|GENERAL|IOS|INTERNAL] [BREAKING|ADDED|CHANGED|DEPRECATED|REMOVED|FIXED|SECURITY] - Message
|
||||
|
||||
For more details, see:
|
||||
<!-- Help reviewers and the release process by writing your own changelog entry. For an example, see:
|
||||
https://reactnative.dev/contributing/changelogs-in-pull-requests
|
||||
-->
|
||||
|
||||
[CATEGORY] [TYPE] - Message
|
||||
|
||||
## Test Plan
|
||||
|
||||
<!-- Demonstrate the code is solid. Example: The exact commands you ran and their output, screenshots / videos if the pull request changes the user interface. -->
|
||||
|
||||
@@ -0,0 +1,52 @@
|
||||
# Configuration for Respond To Issue Based on Label https://github.com/marketplace/actions/respond-to-issue-based-on-label
|
||||
|
||||
"Type: Invalid":
|
||||
close: true
|
||||
"Type: Question":
|
||||
comment: >
|
||||
We are using GitHub issues exclusively to track bugs in React Native. GitHub may not be the ideal place to ask a question, but you can try asking over on [Stack Overflow](http://stackoverflow.com/questions/tagged/react-native), or on [Reactiflux](https://www.reactiflux.com/).
|
||||
close: true
|
||||
"Type: Docs":
|
||||
comment: >
|
||||
Please report documentation issues in the [`react-native-website`](https://github.com/facebook/react-native-website/issues) repository.
|
||||
close: true
|
||||
"Resolution: For Stack Overflow":
|
||||
comment: >
|
||||
We are using GitHub issues exclusively to track bugs in the core React Native library. Please try asking over on [Stack Overflow](http://stackoverflow.com/questions/tagged/react-native) as it is better suited for this type of question.
|
||||
close: true
|
||||
"Needs: Issue Template":
|
||||
comment: >
|
||||
<table><tbody><tr><th width="50">:warning:</th><th width="100%">
|
||||
Missing Required Fields
|
||||
</th></tr><tr><td>:information_source:</td><td>
|
||||
It looks like your issue may be missing some necessary information. GitHub provides an example template whenever a <a href="https://github.com/facebook/react-native/issues/new?template=bug_report.md">new issue is created</a>. Could you go back and make sure to fill out the template? You may edit this issue, or close it and open a new one.
|
||||
</td></tr></tbody></table>
|
||||
labels:
|
||||
- "Needs: Author Feedback"
|
||||
"Needs: Environment Info":
|
||||
comment: >
|
||||
<table><tbody><tr><th width="50">:warning:</th><th width="100%">
|
||||
Missing Environment Information
|
||||
</th></tr><tr><td>:information_source:</td><td>
|
||||
Your issue may be missing information about your development environment. You can obtain the missing information by running <code>react-native info</code> in a console.
|
||||
</td></tr></tbody></table>
|
||||
labels:
|
||||
- "Needs: Author Feedback"
|
||||
"Needs: Verify on Latest Version":
|
||||
comment: >
|
||||
<table><tbody><tr><th width="50">:warning:</th><th width="100%">
|
||||
Using Old Version
|
||||
</th></tr><tr><td>:information_source:</td><td>
|
||||
It looks like you are using an older version of React Native. Please <a href="https://reactnative.dev/docs/upgrading">upgrade</a> to the latest version, and verify if the issue persists. If it does not, please let us know so we can close out this issue. This helps us ensure we are looking at issues that still exist in the current release.
|
||||
</td></tr></tbody></table>
|
||||
labels:
|
||||
- "Needs: Author Feedback"
|
||||
"Needs: Repro":
|
||||
comment: >
|
||||
<table><tbody><tr><th width="50">:warning:</th><th width="100%">
|
||||
Missing Reproducible Example
|
||||
</th></tr><tr><td>:information_source:</td><td>
|
||||
It looks like your issue is missing a reproducible example. Please provide a <a href="https://snack.expo.dev">Snack</a> or a repository that demonstrates the issue you are reporting in a <a href="https://stackoverflow.com/help/minimal-reproducible-example">minimal, complete, and reproducible</a> manner.
|
||||
</td></tr></tbody></table>
|
||||
labels:
|
||||
- "Needs: Author Feedback"
|
||||
@@ -1,137 +0,0 @@
|
||||
/**
|
||||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @format
|
||||
*/
|
||||
|
||||
module.exports = async (github, context, label) => {
|
||||
const closeIssue = async () => {
|
||||
await github.rest.issues.update({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
state: 'closed',
|
||||
});
|
||||
};
|
||||
|
||||
const addComment = async comment => {
|
||||
await github.rest.issues.createComment({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
body: comment,
|
||||
});
|
||||
};
|
||||
|
||||
const requestAuthorFeedback = async () => {
|
||||
// Remove the triage label if it exists (ignore the 404 if not; it's not expected to always be there)
|
||||
try {
|
||||
await github.rest.issues.removeLabel({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
name: 'Needs: Triage :mag:',
|
||||
});
|
||||
} catch {}
|
||||
|
||||
await github.rest.issues.addLabels({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
labels: ['Needs: Author Feedback'],
|
||||
});
|
||||
};
|
||||
|
||||
switch (label) {
|
||||
case 'Type: Invalid':
|
||||
await addComment(
|
||||
`| :warning: | Issue is Invalid |\n` +
|
||||
`| --- | --- |\n` +
|
||||
`| :information_source: | This issue doesn't match any of the expected types for this repository - closing. |`,
|
||||
);
|
||||
await closeIssue();
|
||||
return;
|
||||
case 'Type: Question':
|
||||
await addComment(
|
||||
`| :warning: | Issue is a Question |\n` +
|
||||
`| --- | --- |\n` +
|
||||
`| :information_source: | We are using GitHub issues exclusively to track bugs in React Native. GitHub may not be the ideal place to ask a question, but you can try asking over on [Stack Overflow](http://stackoverflow.com/questions/tagged/react-native), or on [Reactiflux](https://www.reactiflux.com/). |`,
|
||||
);
|
||||
await closeIssue();
|
||||
return;
|
||||
case 'Type: Docs':
|
||||
await addComment(
|
||||
`| :warning: | Documentation Issue |\n` +
|
||||
`| --- | --- |\n` +
|
||||
`| :information_source: | Please report documentation issues in the [react-native-website](https://github.com/facebook/react-native-website/issues) repository. |`,
|
||||
);
|
||||
await closeIssue();
|
||||
return;
|
||||
case 'Resolution: For Stack Overflow':
|
||||
await addComment(
|
||||
`| :warning: | Issue is a Question |\n` +
|
||||
`| --- | --- |\n` +
|
||||
`| :information_source: | We are using GitHub issues exclusively to track bugs in the core React Native library. Please try asking over on [Stack Overflow](http://stackoverflow.com/questions/tagged/react-native) as it is better suited for this type of question. |`,
|
||||
);
|
||||
await closeIssue();
|
||||
return;
|
||||
case 'Type: Expo':
|
||||
await addComment(
|
||||
`| :warning: | Issue is Related to Expo |\n` +
|
||||
`| --- | --- |\n` +
|
||||
`| :information_source: | It looks like your issue is related to Expo and not React Native core. Please open your issue in [Expo's repository](https://github.com/expo/expo/issues/new). If you are able to create a repro that showcases that this issue is also happening in React Native vanilla, we will be happy to re-open. |`,
|
||||
);
|
||||
await closeIssue();
|
||||
return;
|
||||
case 'Needs: Issue Template':
|
||||
await addComment(
|
||||
`| :warning: | Missing Required Fields |\n` +
|
||||
`| --- | --- |\n` +
|
||||
`| :information_source: | It looks like your issue may be missing some necessary information. GitHub provides an example template whenever a [new issue is created](https://github.com/facebook/react-native/issues/new?template=bug_report.md). Could you go back and make sure to fill out the template? You may edit this issue, or close it and open a new one. |`,
|
||||
);
|
||||
await requestAuthorFeedback();
|
||||
return;
|
||||
case 'Needs: Environment Info':
|
||||
await addComment(
|
||||
`| :warning: | Missing Environment Information |\n` +
|
||||
`| --- | --- |\n` +
|
||||
`| :information_source: | Your issue may be missing information about your development environment. You can obtain the missing information by running <code>react-native info</code> in a console. |`,
|
||||
);
|
||||
await requestAuthorFeedback();
|
||||
return;
|
||||
case 'Needs: Verify on Latest Version':
|
||||
await addComment(
|
||||
`| :warning: | Newer Version of React Native is Available! |\n` +
|
||||
`| --- | --- |\n` +
|
||||
`| :information_source: | You are on a supported minor version, but it looks like there's a newer patch available. Please [upgrade](https://reactnative.dev/docs/upgrading) to the highest patch for your minor or latest and verify if the issue persists (alternatively, create a new project and repro the issue in it). If it does not repro, please let us know so we can close out this issue. This helps us ensure we are looking at issues that still exist in the most recent releases. |`,
|
||||
);
|
||||
return;
|
||||
case 'Needs: Version Info':
|
||||
await addComment(
|
||||
`| :warning: | Add or Reformat Version Info |\n` +
|
||||
`| --- | --- |\n` +
|
||||
`| :information_source: | We could not find or parse the version number of React Native in your issue report. Please use the template, and report your version including major, minor, and patch numbers - e.g. 0.70.2 |`,
|
||||
);
|
||||
await requestAuthorFeedback();
|
||||
return;
|
||||
case 'Needs: Repro':
|
||||
await addComment(
|
||||
`| :warning: | Missing Reproducible Example |\n` +
|
||||
`| --- | --- |\n` +
|
||||
`| :information_source: | It looks like your issue is missing a reproducible example. Please provide a [Snack](https://snack.expo.dev) or a repository that demonstrates the issue you are reporting in a [minimal, complete, and reproducible](https://stackoverflow.com/help/minimal-reproducible-example) manner. |`,
|
||||
);
|
||||
await requestAuthorFeedback();
|
||||
return;
|
||||
case 'Type: Unsupported Version':
|
||||
await addComment(
|
||||
`| :warning: | Unsupported Version of React Native |\n` +
|
||||
`| --- | --- |\n` +
|
||||
`| :information_source: | It looks like your issue or the example you provided uses an [unsupported version of React Native](https://github.com/reactwg/react-native-releases/blob/main/README.md#releases-support-policy). Due to the number of issues we receive, we're currently only accepting new issues against one of the supported versions. Please [upgrade](https://reactnative.dev/docs/upgrading) to latest and verify if the issue persists (alternatively, create a new project and repro the issue in it). If you cannot upgrade, please open your issue on [StackOverflow](https://stackoverflow.com/questions/tagged/react-native) to get further community support. |`,
|
||||
);
|
||||
await requestAuthorFeedback();
|
||||
return;
|
||||
}
|
||||
};
|
||||
@@ -13,7 +13,6 @@ jobs:
|
||||
issues: write # for react-native-community/actions-apply-version-label to label issues
|
||||
runs-on: ubuntu-latest
|
||||
continue-on-error: true
|
||||
if: github.repository == 'facebook/react-native'
|
||||
|
||||
steps:
|
||||
- uses: react-native-community/actions-apply-version-label@v0.0.3
|
||||
|
||||
@@ -1,63 +0,0 @@
|
||||
name: Label closed PR as merged and leave a comment
|
||||
on:
|
||||
push
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
pull-requests: write
|
||||
|
||||
jobs:
|
||||
comment-and-label:
|
||||
runs-on: ubuntu-latest
|
||||
if: github.repository == 'facebook/react-native'
|
||||
steps:
|
||||
- uses: actions/github-script@v6
|
||||
with:
|
||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
script: |
|
||||
if(!context.payload.commits || !context.payload.commits.length) return;
|
||||
const sha = context.payload.commits[0].id;
|
||||
|
||||
const {commit, author} = (await github.rest.repos.getCommit({
|
||||
ref: sha,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
})).data;
|
||||
|
||||
// Looking at the commit message, checks which PR number, if any, was closed by this commit
|
||||
const getClosedPrIfExists = (commit) => {
|
||||
if(!commit || !commit.message) return;
|
||||
const prClosingRegex = /Closes https:\/\/github.com\/facebook\/react-native\/pull\/([0-9]+)|Pull Request resolved: https:\/\/github.com\/facebook\/react-native\/pull\/([0-9]+)/;
|
||||
const prClosingMatch = commit.message.match(prClosingRegex);
|
||||
if(!prClosingMatch || (!prClosingMatch[1] && ! prClosingMatch[2])) return;
|
||||
return prClosingMatch[1] ?? prClosingMatch[2];
|
||||
};
|
||||
|
||||
const closedPrNumber = getClosedPrIfExists(commit);
|
||||
if(!closedPrNumber) return;
|
||||
|
||||
const pr = (await github.rest.pulls.get({
|
||||
pull_number: closedPrNumber,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
})).data;
|
||||
|
||||
// If the PR has already been processed (labeled as Merged), skip it
|
||||
const mergedLabel = "Merged";
|
||||
if(pr.labels && pr.labels.some(label => label.name === mergedLabel)) return;
|
||||
|
||||
const authorName = author?.login ? `@${author.login}` : commit.author.name;
|
||||
|
||||
github.rest.issues.createComment({
|
||||
issue_number: closedPrNumber,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
body: `This pull request was successfully merged by ${authorName} in **${sha}**.\n\n<sup>[When will my fix make it into a release?](https://github.com/facebook/react-native/wiki/Release-FAQ#when-will-my-fix-make-it-into-a-release) | [Upcoming Releases](https://github.com/reactwg/react-native-releases/discussions/categories/releases)</sup>`
|
||||
});
|
||||
|
||||
github.rest.issues.addLabels({
|
||||
issue_number: closedPrNumber,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
labels: [mergedLabel]
|
||||
});
|
||||
@@ -15,7 +15,6 @@ permissions:
|
||||
jobs:
|
||||
danger:
|
||||
runs-on: ubuntu-latest
|
||||
if: github.repository == 'facebook/react-native'
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: Run Yarn Install on Root
|
||||
|
||||
@@ -14,7 +14,6 @@ jobs:
|
||||
issues: write # for hramos/needs-attention to label issues
|
||||
name: Apply Needs Attention Label
|
||||
runs-on: ubuntu-latest
|
||||
if: github.repository == 'facebook/react-native'
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: Apply Needs Attention Label
|
||||
|
||||
@@ -5,42 +5,18 @@ on:
|
||||
types: labeled
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
issues: write
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
# Runs automatic checks on issues labeled with "Needs: Triage",
|
||||
# then invokes actOnLabel to react to any added labels
|
||||
triage-issue:
|
||||
respondToIssueBasedOnLabel:
|
||||
permissions:
|
||||
contents: read # for hramos/respond-to-issue-based-on-label to fetch config file
|
||||
issues: write # for hramos/respond-to-issue-based-on-label to update issues
|
||||
name: Respond to Issue Based on Label
|
||||
runs-on: ubuntu-latest
|
||||
if: "${{ github.repository == 'facebook/react-native' && contains(github.event.label.name, 'Needs: Triage :mag:') }}"
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: actions/github-script@v6
|
||||
- name: Respond to Issue Based on Label
|
||||
uses: hramos/respond-to-issue-based-on-label@v2
|
||||
with:
|
||||
script: |
|
||||
const verifyVersion = require('./.github/workflows/verifyVersion.js')
|
||||
const labelToAdd = await verifyVersion(github, context);
|
||||
|
||||
if(labelToAdd) {
|
||||
await github.rest.issues.addLabels({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
labels: [labelToAdd]
|
||||
})
|
||||
|
||||
const actOnLabel = require('./.github/workflows/actOnLabel.js')
|
||||
await actOnLabel(github, context, labelToAdd)
|
||||
}
|
||||
# Reacts to the label that triggered this workflow (added manually or via other workflows)
|
||||
act-on-label:
|
||||
runs-on: ubuntu-latest
|
||||
if: github.repository == 'facebook/react-native'
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: actions/github-script@v6
|
||||
with:
|
||||
script: |
|
||||
const actOnLabel = require('./.github/workflows/actOnLabel.js')
|
||||
await actOnLabel(github, context, context.payload.label.name)
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
name: Mark stale issues and pull requests
|
||||
on:
|
||||
schedule:
|
||||
- cron: "0 0,6,12,18 * * *"
|
||||
- cron: "30 1 * * *"
|
||||
jobs:
|
||||
stale:
|
||||
runs-on: ubuntu-latest
|
||||
if: github.repository == 'facebook/react-native'
|
||||
permissions:
|
||||
issues: write
|
||||
pull-requests: write
|
||||
@@ -18,60 +17,3 @@ jobs:
|
||||
stale-pr-message: 'This PR is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 7 days.'
|
||||
close-issue-message: 'This issue was closed because it has been stalled for 7 days with no activity.'
|
||||
close-pr-message: 'This PR was closed because it has been stalled for 7 days with no activity.'
|
||||
exempt-issue-labels: Help Wanted :octocat:, Good first issue, Never gets stale
|
||||
exempt-pr-labels: Help Wanted :octocat:, Good first issue, Never gets stale
|
||||
stale-asc:
|
||||
runs-on: ubuntu-latest
|
||||
if: github.repository == 'facebook/react-native'
|
||||
permissions:
|
||||
issues: write
|
||||
pull-requests: write
|
||||
steps:
|
||||
- uses: actions/stale@v5
|
||||
with:
|
||||
ascending: true
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
days-before-stale: 180
|
||||
stale-issue-message: 'This issue is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 7 days.'
|
||||
stale-pr-message: 'This PR is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 7 days.'
|
||||
close-issue-message: 'This issue was closed because it has been stalled for 7 days with no activity.'
|
||||
close-pr-message: 'This PR was closed because it has been stalled for 7 days with no activity.'
|
||||
exempt-issue-labels: Help Wanted :octocat:, Good first issue, Never gets stale
|
||||
exempt-pr-labels: Help Wanted :octocat:, Good first issue, Never gets stale
|
||||
stale-needs-author-feedback:
|
||||
runs-on: ubuntu-latest
|
||||
if: github.repository == 'facebook/react-native'
|
||||
permissions:
|
||||
issues: write
|
||||
pull-requests: write
|
||||
steps:
|
||||
- uses: actions/stale@v5
|
||||
with:
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
any-of-labels: 'Needs: Author Feedback'
|
||||
days-before-stale: 24
|
||||
stale-issue-message: "This issue is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days."
|
||||
stale-pr-message: "This PR is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days"
|
||||
close-issue-message: "This issue was closed because the author hasn't provided the requested feedback after 7 days."
|
||||
close-pr-message: "This PR was closed because the author hasn't provided the requested feedback after 7 days."
|
||||
exempt-issue-labels: Help Wanted :octocat:, Good first issue, Never gets stale
|
||||
exempt-pr-labels: Help Wanted :octocat:, Good first issue, Never gets stale
|
||||
stale-needs-author-feedback-asc:
|
||||
runs-on: ubuntu-latest
|
||||
if: github.repository == 'facebook/react-native'
|
||||
permissions:
|
||||
issues: write
|
||||
pull-requests: write
|
||||
steps:
|
||||
- uses: actions/stale@v5
|
||||
with:
|
||||
ascending: true
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
any-of-labels: 'Needs: Author Feedback'
|
||||
days-before-stale: 24
|
||||
stale-issue-message: "This issue is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days."
|
||||
stale-pr-message: "This PR is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days"
|
||||
close-issue-message: "This issue was closed because the author hasn't provided the requested feedback after 7 days."
|
||||
close-pr-message: "This PR was closed because the author hasn't provided the requested feedback after 7 days."
|
||||
exempt-issue-labels: Help Wanted :octocat:, Good first issue, Never gets stale
|
||||
exempt-pr-labels: Help Wanted :octocat:, Good first issue, Never gets stale
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
name: Test Docker Android Image
|
||||
# This workflow is triggered on commits to main and pull requests.
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
pull_request:
|
||||
branches:
|
||||
- main
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
test-docker-android:
|
||||
name: Test Docker
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: Free up space by removing unnecessary folders
|
||||
run: |
|
||||
sudo rm -rf /usr/share/dotnet
|
||||
sudo rm -rf /opt/ghc
|
||||
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
|
||||
- name: Build Docker image with Android test app
|
||||
run: npm run docker-build-android
|
||||
@@ -1,117 +0,0 @@
|
||||
/**
|
||||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @format
|
||||
*/
|
||||
|
||||
module.exports = async (github, context) => {
|
||||
const issue = context.payload.issue;
|
||||
|
||||
// Ignore issues using upgrade template (they use a special label)
|
||||
if (issue.labels.find(label => label.name == 'Type: Upgrade Issue')) {
|
||||
return;
|
||||
}
|
||||
|
||||
const issueVersionUnparsed =
|
||||
getReactNativeVersionFromIssueBodyIfExists(issue);
|
||||
const issueVersion = parseVersionFromString(issueVersionUnparsed);
|
||||
|
||||
// Nightly versions are always supported
|
||||
if (reportedVersionIsNightly(issueVersionUnparsed, issueVersion)) return;
|
||||
|
||||
if (!issueVersion) {
|
||||
return 'Needs: Version Info';
|
||||
}
|
||||
|
||||
// Ensure the version matches one we support
|
||||
const recentReleases = (
|
||||
await github.rest.repos.listReleases({
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
})
|
||||
).data.map(release => release.name);
|
||||
|
||||
const latestRelease = (
|
||||
await github.rest.repos.getLatestRelease({
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
})
|
||||
).data;
|
||||
const latestVersion = parseVersionFromString(latestRelease.name);
|
||||
|
||||
if (!isVersionSupported(issueVersion, latestVersion)) {
|
||||
return 'Type: Unsupported Version';
|
||||
}
|
||||
|
||||
// We want to encourage users to repro the issue on the highest available patch for the given minor.
|
||||
const latestPatchForVersion = getLatestPatchForVersion(
|
||||
issueVersion,
|
||||
recentReleases,
|
||||
);
|
||||
if (latestPatchForVersion > issueVersion.patch) {
|
||||
return 'Needs: Verify on Latest Version';
|
||||
}
|
||||
};
|
||||
|
||||
// We support N-2 minor versions, and the latest major.
|
||||
function isVersionSupported(actualVersion, latestVersion) {
|
||||
return (
|
||||
actualVersion.major >= latestVersion.major &&
|
||||
actualVersion.minor >= latestVersion.minor - 2
|
||||
);
|
||||
}
|
||||
|
||||
// Assumes that releases are sorted in the order of recency (i.e. most recent releases are earlier in the list)
|
||||
// This enables us to stop looking as soon as we find the first release with a matching major/minor version, since
|
||||
// we know it's the most recent release, therefore the highest patch available.
|
||||
function getLatestPatchForVersion(version, releases) {
|
||||
for (releaseName of releases) {
|
||||
const release = parseVersionFromString(releaseName);
|
||||
if (
|
||||
release &&
|
||||
release.major == version.major &&
|
||||
release.minor == version.minor
|
||||
) {
|
||||
return release.patch;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function getReactNativeVersionFromIssueBodyIfExists(issue) {
|
||||
if (!issue || !issue.body) return;
|
||||
const rnVersionRegex = /React Native Version[\r\n]+(?<version>.+)[\r\n]*/;
|
||||
const rnVersionMatch = issue.body.match(rnVersionRegex);
|
||||
if (!rnVersionMatch || !rnVersionMatch.groups.version) return;
|
||||
return rnVersionMatch.groups.version;
|
||||
}
|
||||
|
||||
function reportedVersionIsNightly(unparsedVersionString, version) {
|
||||
if (!unparsedVersionString && !version) return false;
|
||||
const nightlyRegex = /nightly/i;
|
||||
const nightlyMatch = unparsedVersionString.match(nightlyRegex);
|
||||
const versionIsNightly = nightlyMatch && nightlyMatch[0];
|
||||
|
||||
const versionIsZero =
|
||||
version && version.major == 0 && version.minor == 0 && version.patch == 0;
|
||||
|
||||
return versionIsZero || versionIsNightly;
|
||||
}
|
||||
|
||||
function parseVersionFromString(version) {
|
||||
if (!version) return;
|
||||
// This will match the standard x.x.x semver format, as well as the non-standard prerelease x.x.x-rc.x
|
||||
const semverRegex =
|
||||
/(?<major>\d+)\.(?<minor>\d+)\.(?<patch>\d+)(-[rR]{1}[cC]{1}\.(?<prerelease>\d+))?/;
|
||||
const versionMatch = version.match(semverRegex);
|
||||
if (!versionMatch) return;
|
||||
const {major, minor, patch, prerelease} = versionMatch.groups;
|
||||
return {
|
||||
major: parseInt(major),
|
||||
minor: parseInt(minor),
|
||||
patch: parseInt(patch),
|
||||
prerelease: parseInt(prerelease),
|
||||
};
|
||||
}
|
||||
+36
-39
@@ -31,25 +31,25 @@ project.xcworkspace
|
||||
/packages/rn-tester/android/app/gradle/
|
||||
/packages/rn-tester/android/app/gradlew
|
||||
/packages/rn-tester/android/app/gradlew.bat
|
||||
/packages/react-native/ReactAndroid/build/
|
||||
/packages/react-native/ReactAndroid/.cxx/
|
||||
/packages/react-native/ReactAndroid/gradle/
|
||||
/packages/react-native/ReactAndroid/gradlew
|
||||
/packages/react-native/ReactAndroid/gradlew.bat
|
||||
/packages/react-native/ReactAndroid/external-artifacts/build/
|
||||
/packages/react-native/ReactAndroid/external-artifacts/artifacts/
|
||||
/packages/react-native/ReactAndroid/hermes-engine/build/
|
||||
/packages/react-native/ReactAndroid/hermes-engine/.cxx/
|
||||
/packages/react-native/template/android/app/build/
|
||||
/packages/react-native/template/android/build/
|
||||
/ReactAndroid/build/
|
||||
/ReactAndroid/.cxx/
|
||||
/ReactAndroid/gradle/
|
||||
/ReactAndroid/gradlew
|
||||
/ReactAndroid/gradlew.bat
|
||||
/ReactAndroid/external-artifacts/build/
|
||||
/ReactAndroid/external-artifacts/artifacts/
|
||||
/ReactAndroid/hermes-engine/build/
|
||||
/ReactAndroid/hermes-engine/.cxx/
|
||||
/template/android/app/build/
|
||||
/template/android/build/
|
||||
|
||||
# Buck
|
||||
.buckd
|
||||
buck-out
|
||||
/.lsp.buckd
|
||||
/.lsp-buck-out
|
||||
/packages/react-native/ReactAndroid/src/main/jni/prebuilt/lib/
|
||||
/packages/react-native/ReactAndroid/src/main/gen
|
||||
/ReactAndroid/src/main/jni/prebuilt/lib/
|
||||
/ReactAndroid/src/main/gen
|
||||
|
||||
# Android Studio
|
||||
.project
|
||||
@@ -64,8 +64,8 @@ buck-out
|
||||
.gradle
|
||||
local.properties
|
||||
*.iml
|
||||
/packages/react-native/android/*
|
||||
!/packages/react-native/android/README.md
|
||||
/android/*
|
||||
!/android/README.md
|
||||
|
||||
# Node
|
||||
node_modules
|
||||
@@ -77,41 +77,35 @@ package-lock.json
|
||||
.DS_Store
|
||||
|
||||
# Test generated files
|
||||
/packages/react-native/ReactAndroid/src/androidTest/assets/AndroidTestBundle.js
|
||||
/ReactAndroid/src/androidTest/assets/AndroidTestBundle.js
|
||||
*.js.meta
|
||||
|
||||
/coverage
|
||||
/third-party
|
||||
|
||||
# Test Reports
|
||||
/reports
|
||||
|
||||
# Stack Dumps generated when programs crash (Ex. bash.exe.stackdump on Win)
|
||||
*.stackdump
|
||||
|
||||
# Root dir shouldn't have Xcode project
|
||||
/*.xcodeproj
|
||||
|
||||
# ReactCommon subdir shouldn't have Xcode project
|
||||
/packages/react-native/ReactCommon/**/*.xcodeproj
|
||||
/ReactCommon/**/*.xcodeproj
|
||||
|
||||
# Libs that shouldn't have Xcode project
|
||||
/packages/react-native/Libraries/FBLazyVector/**/*.xcodeproj
|
||||
/packages/react-native/Libraries/RCTRequired/**/*.xcodeproj
|
||||
/packages/react-native/React/CoreModules/**/*.xcodeproj
|
||||
/packages/react-native/React/FBReactNativeSpec/**/*.xcodeproj
|
||||
/Libraries/FBLazyVector/**/*.xcodeproj
|
||||
/Libraries/RCTRequired/**/*.xcodeproj
|
||||
/React/CoreModules/**/*.xcodeproj
|
||||
/React/FBReactNativeSpec/**/*.xcodeproj
|
||||
/packages/react-native-codegen/**/*.xcodeproj
|
||||
|
||||
# Ruby Gems (Bundler)
|
||||
/packages/react-native/vendor
|
||||
/packages/react-native/template/vendor
|
||||
/vendor
|
||||
/template/vendor
|
||||
.ruby-version
|
||||
/**/.ruby-version
|
||||
|
||||
# iOS / CocoaPods
|
||||
/packages/react-native/template/ios/build/
|
||||
/packages/react-native/template/ios/Pods/
|
||||
/packages/react-native/template/ios/Podfile.lock
|
||||
/template/ios/build/
|
||||
/template/ios/Pods/
|
||||
/template/ios/Podfile.lock
|
||||
/packages/rn-tester/Gemfile.lock
|
||||
|
||||
# Ignore RNTester specific Pods, but keep the __offline_mirrors__ here.
|
||||
@@ -119,19 +113,19 @@ package-lock.json
|
||||
!/packages/rn-tester/Pods/__offline_mirrors_hermes__
|
||||
!/packages/rn-tester/Pods/__offline_mirrors_jsc__
|
||||
|
||||
# @react-native/codegen
|
||||
/packages/react-native/React/FBReactNativeSpec/FBReactNativeSpec
|
||||
# react-native-codegen
|
||||
/React/FBReactNativeSpec/FBReactNativeSpec
|
||||
/packages/react-native-codegen/lib
|
||||
/packages/react-native-codegen/tmp/
|
||||
/packages/react-native/ReactCommon/react/renderer/components/rncore/
|
||||
/ReactCommon/react/renderer/components/rncore/
|
||||
/packages/rn-tester/NativeModuleExample/ScreenshotManagerSpec*
|
||||
/**/RCTThirdPartyFabricComponentsProvider.*
|
||||
|
||||
|
||||
# Additional SDKs
|
||||
/packages/react-native/sdks/download
|
||||
/packages/react-native/sdks/hermes
|
||||
/packages/react-native/sdks/hermesc
|
||||
/sdks/download
|
||||
/sdks/hermes
|
||||
/sdks/hermesc
|
||||
/sdks/hermes-engine/build_host_hermesc
|
||||
|
||||
# Visual studio
|
||||
.vscode
|
||||
@@ -142,3 +136,6 @@ package-lock.json
|
||||
|
||||
# Temporary files created by Metro to check the health of the file watcher
|
||||
.metro-health-check*
|
||||
|
||||
# monorepo (main)
|
||||
packages/react-native/
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
18
|
||||
@@ -12,30 +12,28 @@ load(
|
||||
"//tools/build_defs/oss:rn_defs.bzl",
|
||||
"ANDROID",
|
||||
"APPLE",
|
||||
"CXX",
|
||||
"HERMES_BYTECODE_VERSION",
|
||||
"IOS",
|
||||
"RCT_IMAGE_DATA_DECODER_SOCKET",
|
||||
"RCT_IMAGE_URL_LOADER_SOCKET",
|
||||
"RCT_URL_REQUEST_HANDLER_SOCKET",
|
||||
"YOGA_CXX_TARGET",
|
||||
"fb_xplat_cxx_test",
|
||||
"get_react_native_ios_target_sdk_version",
|
||||
"react_cxx_module_plugin_provider",
|
||||
"react_fabric_component_plugin_provider",
|
||||
"react_module_plugin_providers",
|
||||
"react_native_root_target",
|
||||
"react_native_xplat_dep",
|
||||
"react_native_xplat_target",
|
||||
"rn_apple_library",
|
||||
"rn_apple_xplat_cxx_library",
|
||||
"rn_extra_build_flags",
|
||||
"rn_xplat_cxx_library",
|
||||
"rn_xplat_cxx_library2",
|
||||
"subdir_glob",
|
||||
)
|
||||
load("//tools/build_defs/third_party:yarn_defs.bzl", "yarn_workspace")
|
||||
|
||||
RCTCXXBRIDGE_PUBLIC_HEADERS = {
|
||||
"React/" + x: "packages/react-native/React/CxxBridge/" + x
|
||||
"React/" + x: "React/CxxBridge/" + x
|
||||
for x in [
|
||||
"JSCExecutorFactory.h",
|
||||
"NSDataBigString.h",
|
||||
@@ -49,6 +47,8 @@ fb_native.genrule(
|
||||
name = "codegen_rn_components_schema_rncore",
|
||||
srcs = glob(
|
||||
[
|
||||
"Libraries/**/*NativeComponent.js",
|
||||
"jest/**/*NativeComponent.js",
|
||||
"packages/**/*NativeComponent.js",
|
||||
],
|
||||
exclude = [
|
||||
@@ -70,15 +70,15 @@ rn_codegen_components(
|
||||
schema_target = ":codegen_rn_components_schema_rncore",
|
||||
)
|
||||
|
||||
rn_apple_xplat_cxx_library(
|
||||
rn_xplat_cxx_library2(
|
||||
name = "RCTCxxBridge",
|
||||
srcs = glob([
|
||||
"packages/react-native/React/CxxBridge/*.mm",
|
||||
"React/CxxBridge/*.mm",
|
||||
]),
|
||||
headers = subdir_glob(
|
||||
[
|
||||
(
|
||||
"packages/react-native/React/CxxBridge",
|
||||
"React/CxxBridge",
|
||||
"*.h",
|
||||
),
|
||||
],
|
||||
@@ -112,7 +112,7 @@ rn_apple_xplat_cxx_library(
|
||||
":RCTCxxUtils",
|
||||
":ReactInternal",
|
||||
"//fbobjc/Libraries/FBReactKit:RCTFBSystrace",
|
||||
react_native_root_target("packages/react-native/React/CoreModules:CoreModules"),
|
||||
react_native_root_target("React/CoreModules:CoreModules"),
|
||||
react_native_xplat_target("cxxreact:bridge"),
|
||||
react_native_xplat_target("cxxreact:jsbigstring"),
|
||||
react_native_xplat_target("jsc:JSCRuntime"),
|
||||
@@ -122,7 +122,7 @@ rn_apple_xplat_cxx_library(
|
||||
)
|
||||
|
||||
RCTCXXMODULE_PUBLIC_HEADERS = {
|
||||
"React/" + x: "packages/react-native/React/CxxModule/" + x
|
||||
"React/" + x: "React/CxxModule/" + x
|
||||
for x in [
|
||||
"RCTCxxMethod.h",
|
||||
"RCTCxxModule.h",
|
||||
@@ -130,15 +130,15 @@ RCTCXXMODULE_PUBLIC_HEADERS = {
|
||||
]
|
||||
}
|
||||
|
||||
rn_apple_xplat_cxx_library(
|
||||
rn_xplat_cxx_library2(
|
||||
name = "RCTCxxModule",
|
||||
srcs = glob([
|
||||
"packages/react-native/React/CxxModule/*.mm",
|
||||
"React/CxxModule/*.mm",
|
||||
]),
|
||||
headers = subdir_glob(
|
||||
[
|
||||
(
|
||||
"packages/react-native/React/CxxModule",
|
||||
"React/CxxModule",
|
||||
"*.h",
|
||||
),
|
||||
],
|
||||
@@ -171,16 +171,16 @@ rn_apple_xplat_cxx_library(
|
||||
],
|
||||
)
|
||||
|
||||
rn_apple_xplat_cxx_library(
|
||||
rn_xplat_cxx_library2(
|
||||
name = "RCTCxxUtils",
|
||||
srcs = glob([
|
||||
"packages/react-native/React/CxxUtils/*.mm",
|
||||
"React/CxxUtils/*.mm",
|
||||
]),
|
||||
header_namespace = "",
|
||||
exported_headers = subdir_glob(
|
||||
[
|
||||
(
|
||||
"packages/react-native/React/CxxUtils",
|
||||
"React/CxxUtils",
|
||||
"*.h",
|
||||
),
|
||||
],
|
||||
@@ -203,16 +203,16 @@ rn_apple_xplat_cxx_library(
|
||||
],
|
||||
)
|
||||
|
||||
rn_apple_xplat_cxx_library(
|
||||
rn_xplat_cxx_library2(
|
||||
name = "RCTCxxLogUtils",
|
||||
srcs = glob([
|
||||
"packages/react-native/React/CxxLogUtils/*.mm",
|
||||
"React/CxxLogUtils/*.mm",
|
||||
]),
|
||||
header_namespace = "",
|
||||
exported_headers = subdir_glob(
|
||||
[
|
||||
(
|
||||
"packages/react-native/React/CxxLogUtils",
|
||||
"React/CxxLogUtils",
|
||||
"*.h",
|
||||
),
|
||||
],
|
||||
@@ -231,15 +231,15 @@ rn_apple_xplat_cxx_library(
|
||||
],
|
||||
)
|
||||
|
||||
RCTLIB_PATH = "packages/react-native/Libraries/"
|
||||
RCTLIB_PATH = "Libraries/"
|
||||
|
||||
RCTBASE_PATH = "packages/react-native/React/Base/"
|
||||
RCTBASE_PATH = "React/Base/"
|
||||
|
||||
RCTDEVSUPPORT_PATH = "packages/react-native/React/DevSupport/"
|
||||
RCTDEVSUPPORT_PATH = "React/DevSupport/"
|
||||
|
||||
RCTMODULES_PATH = "packages/react-native/React/Modules/"
|
||||
RCTMODULES_PATH = "React/Modules/"
|
||||
|
||||
RCTVIEWS_PATH = "packages/react-native/React/Views/"
|
||||
RCTVIEWS_PATH = "React/Views/"
|
||||
|
||||
REACT_PUBLIC_HEADERS = {
|
||||
"React/RCTAnimationType.h": RCTVIEWS_PATH + "RCTAnimationType.h",
|
||||
@@ -278,9 +278,9 @@ REACT_PUBLIC_HEADERS = {
|
||||
"React/RCTI18nUtil.h": RCTMODULES_PATH + "RCTI18nUtil.h",
|
||||
"React/RCTImageSource.h": RCTBASE_PATH + "RCTImageSource.h",
|
||||
"React/RCTInitializing.h": RCTBASE_PATH + "RCTInitializing.h",
|
||||
"React/RCTInspector.h": "packages/react-native/React/Inspector/RCTInspector.h",
|
||||
"React/RCTInspector.h": "React/Inspector/RCTInspector.h",
|
||||
"React/RCTInspectorDevServerHelper.h": RCTDEVSUPPORT_PATH + "RCTInspectorDevServerHelper.h",
|
||||
"React/RCTInspectorPackagerConnection.h": "packages/react-native/React/Inspector/RCTInspectorPackagerConnection.h",
|
||||
"React/RCTInspectorPackagerConnection.h": "React/Inspector/RCTInspectorPackagerConnection.h",
|
||||
"React/RCTInvalidating.h": RCTBASE_PATH + "RCTInvalidating.h",
|
||||
"React/RCTJSScriptLoaderModule.h": RCTBASE_PATH + "RCTJSScriptLoaderModule.h",
|
||||
"React/RCTJSStackFrame.h": RCTBASE_PATH + "RCTJSStackFrame.h",
|
||||
@@ -307,7 +307,7 @@ REACT_PUBLIC_HEADERS = {
|
||||
"React/RCTPerformanceLogger.h": RCTBASE_PATH + "RCTPerformanceLogger.h",
|
||||
"React/RCTPerformanceLoggerLabels.h": RCTBASE_PATH + "RCTPerformanceLoggerLabels.h",
|
||||
"React/RCTPointerEvents.h": RCTVIEWS_PATH + "RCTPointerEvents.h",
|
||||
"React/RCTProfile.h": "packages/react-native/React/Profiler/RCTProfile.h",
|
||||
"React/RCTProfile.h": "React/Profiler/RCTProfile.h",
|
||||
"React/RCTPushNotificationManager.h": RCTLIB_PATH + "PushNotificationIOS/RCTPushNotificationManager.h",
|
||||
"React/RCTReconnectingWebSocket.h": RCTLIB_PATH + "WebSocket/RCTReconnectingWebSocket.h",
|
||||
"React/RCTRedBoxExtraDataViewController.h": RCTMODULES_PATH + "RCTRedBoxExtraDataViewController.h",
|
||||
@@ -318,6 +318,7 @@ REACT_PUBLIC_HEADERS = {
|
||||
"React/RCTRootShadowView.h": RCTVIEWS_PATH + "RCTRootShadowView.h",
|
||||
"React/RCTRootView.h": RCTBASE_PATH + "RCTRootView.h",
|
||||
"React/RCTRootViewDelegate.h": RCTBASE_PATH + "RCTRootViewDelegate.h",
|
||||
"React/RCTSRWebSocket.h": RCTLIB_PATH + "WebSocket/RCTSRWebSocket.h",
|
||||
"React/RCTScrollEvent.h": RCTVIEWS_PATH + "ScrollView/RCTScrollEvent.h",
|
||||
"React/RCTScrollView.h": RCTVIEWS_PATH + "ScrollView/RCTScrollView.h",
|
||||
"React/RCTScrollableProtocol.h": RCTVIEWS_PATH + "ScrollView/RCTScrollableProtocol.h",
|
||||
@@ -342,7 +343,7 @@ REACT_PUBLIC_HEADERS = {
|
||||
"React/RCTUIManager.h": RCTMODULES_PATH + "RCTUIManager.h",
|
||||
"React/RCTUIManagerObserverCoordinator.h": RCTMODULES_PATH + "RCTUIManagerObserverCoordinator.h",
|
||||
"React/RCTUIManagerUtils.h": RCTMODULES_PATH + "RCTUIManagerUtils.h",
|
||||
"React/RCTUIUtils.h": "packages/react-native/React/UIUtils/RCTUIUtils.h",
|
||||
"React/RCTUIUtils.h": "React/UIUtils/RCTUIUtils.h",
|
||||
"React/RCTURLRequestDelegate.h": RCTBASE_PATH + "RCTURLRequestDelegate.h",
|
||||
"React/RCTURLRequestHandler.h": RCTBASE_PATH + "RCTURLRequestHandler.h",
|
||||
"React/RCTUtils.h": RCTBASE_PATH + "RCTUtils.h",
|
||||
@@ -351,49 +352,50 @@ REACT_PUBLIC_HEADERS = {
|
||||
"React/RCTView.h": RCTVIEWS_PATH + "RCTView.h",
|
||||
"React/RCTViewManager.h": RCTVIEWS_PATH + "RCTViewManager.h",
|
||||
"React/RCTViewUtils.h": RCTVIEWS_PATH + "RCTViewUtils.h",
|
||||
"React/RCTWeakProxy.h": RCTBASE_PATH + "RCTWeakProxy.h",
|
||||
"React/RCTWrapperViewController.h": RCTVIEWS_PATH + "RCTWrapperViewController.h",
|
||||
"React/UIView+React.h": RCTVIEWS_PATH + "UIView+React.h",
|
||||
}
|
||||
|
||||
REACT_COMPONENTVIEWS_BASE_FILES = [
|
||||
"packages/react-native/React/Fabric/Mounting/ComponentViews/Image/*.mm",
|
||||
"packages/react-native/React/Fabric/RCTImageResponseObserverProxy.mm",
|
||||
"packages/react-native/React/Fabric/Mounting/ComponentViews/View/RCTViewComponentView.mm",
|
||||
"React/Fabric/Mounting/ComponentViews/Image/*.mm",
|
||||
"React/Fabric/RCTImageResponseObserverProxy.mm",
|
||||
"React/Fabric/Mounting/ComponentViews/View/RCTViewComponentView.mm",
|
||||
]
|
||||
|
||||
rn_apple_xplat_cxx_library(
|
||||
rn_xplat_cxx_library2(
|
||||
name = "ReactInternal",
|
||||
srcs = glob(
|
||||
[
|
||||
"packages/react-native/React/Base/**/*.m",
|
||||
"packages/react-native/React/Base/**/*.mm",
|
||||
"packages/react-native/React/DevSupport/**/*.m",
|
||||
"packages/react-native/React/DevSupport/**/*.mm",
|
||||
"packages/react-native/React/Inspector/**/*.m",
|
||||
"packages/react-native/React/Inspector/**/*.mm",
|
||||
"packages/react-native/React/Modules/**/*.m",
|
||||
"packages/react-native/React/Modules/**/*.mm",
|
||||
"packages/react-native/React/Profiler/**/*.m",
|
||||
"packages/react-native/React/Profiler/**/*.mm",
|
||||
"packages/react-native/React/Profiler/**/*.S",
|
||||
"packages/react-native/React/UIUtils/*.m",
|
||||
"packages/react-native/React/Views/**/*.m",
|
||||
"packages/react-native/React/Views/**/*.mm",
|
||||
"packages/react-native/Libraries/ActionSheetIOS/*.m",
|
||||
"packages/react-native/Libraries/WebSocket/*.m",
|
||||
"React/Base/**/*.m",
|
||||
"React/Base/**/*.mm",
|
||||
"React/DevSupport/**/*.m",
|
||||
"React/DevSupport/**/*.mm",
|
||||
"React/Inspector/**/*.m",
|
||||
"React/Inspector/**/*.mm",
|
||||
"React/Modules/**/*.m",
|
||||
"React/Modules/**/*.mm",
|
||||
"React/Profiler/**/*.m",
|
||||
"React/Profiler/**/*.mm",
|
||||
"React/Profiler/**/*.S",
|
||||
"React/UIUtils/*.m",
|
||||
"React/Views/**/*.m",
|
||||
"React/Views/**/*.mm",
|
||||
"Libraries/ActionSheetIOS/*.m",
|
||||
"Libraries/WebSocket/*.m",
|
||||
],
|
||||
),
|
||||
headers = glob(
|
||||
[
|
||||
"packages/react-native/React/Base/**/*.h",
|
||||
"packages/react-native/React/DevSupport/**/*.h",
|
||||
"packages/react-native/React/Inspector/**/*.h",
|
||||
"packages/react-native/React/Modules/**/*.h",
|
||||
"packages/react-native/React/Profiler/**/*.h",
|
||||
"packages/react-native/React/Views/**/*.h",
|
||||
"packages/react-native/React/UIUtils/**/*.h",
|
||||
"packages/react-native/Libraries/ActionSheetIOS/*.h",
|
||||
"packages/react-native/Libraries/WebSocket/*.h",
|
||||
"React/Base/**/*.h",
|
||||
"React/DevSupport/**/*.h",
|
||||
"React/Inspector/**/*.h",
|
||||
"React/Modules/**/*.h",
|
||||
"React/Profiler/**/*.h",
|
||||
"React/Views/**/*.h",
|
||||
"React/UIUtils/**/*.h",
|
||||
"Libraries/ActionSheetIOS/*.h",
|
||||
"Libraries/WebSocket/*.h",
|
||||
],
|
||||
),
|
||||
header_namespace = "",
|
||||
@@ -404,6 +406,12 @@ rn_apple_xplat_cxx_library(
|
||||
"-Wno-global-constructors",
|
||||
],
|
||||
contacts = ["oncall+react_native@xmail.facebook.com"],
|
||||
exported_linker_flags = [
|
||||
"-weak_framework",
|
||||
"UserNotifications",
|
||||
"-weak_framework",
|
||||
"WebKit",
|
||||
],
|
||||
exported_preprocessor_flags = rn_extra_build_flags(),
|
||||
fbobjc_enable_exceptions = True,
|
||||
frameworks = [
|
||||
@@ -418,7 +426,6 @@ rn_apple_xplat_cxx_library(
|
||||
"$SDKROOT/System/Library/Frameworks/SystemConfiguration.framework",
|
||||
"$SDKROOT/System/Library/Frameworks/UIKit.framework",
|
||||
"$SDKROOT/System/Library/Frameworks/UserNotifications.framework",
|
||||
"$SDKROOT/System/Library/Frameworks/WebKit.framework",
|
||||
],
|
||||
labels = [
|
||||
"depslint_never_add",
|
||||
@@ -443,59 +450,58 @@ rn_apple_xplat_cxx_library(
|
||||
"//fbobjc/Libraries/RCTPrerendering/...",
|
||||
"//fbobjc/VendorLib/react-native-maps:react-native-maps",
|
||||
"//xplat/js:",
|
||||
"//xplat/js/react-native-github/packages/react-native/React/...",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/nativemodule/core:",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/nativemodule/samples:",
|
||||
"//xplat/js/react-native-github/React/...",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/nativemodule/core:",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/nativemodule/samples:",
|
||||
"//xplat/js/react-native-github/packages/rn-tester:",
|
||||
"//xplat/rtc/manul/...",
|
||||
],
|
||||
deps = [
|
||||
YOGA_CXX_TARGET,
|
||||
"//fbobjc/VendorLib/SocketRocket:SocketRocket",
|
||||
react_native_xplat_target("cxxreact:bridge"),
|
||||
react_native_xplat_target("reactperflogger:reactperflogger"),
|
||||
],
|
||||
)
|
||||
|
||||
rn_apple_xplat_cxx_library(
|
||||
rn_xplat_cxx_library2(
|
||||
name = "RCTFabric",
|
||||
srcs = glob(
|
||||
[
|
||||
"packages/react-native/React/Fabric/**/*.cpp",
|
||||
"packages/react-native/React/Fabric/**/*.m",
|
||||
"packages/react-native/React/Fabric/**/*.mm",
|
||||
"React/Fabric/**/*.cpp",
|
||||
"React/Fabric/**/*.m",
|
||||
"React/Fabric/**/*.mm",
|
||||
],
|
||||
exclude = glob(REACT_COMPONENTVIEWS_BASE_FILES),
|
||||
),
|
||||
headers = glob(
|
||||
[
|
||||
"packages/react-native/React/Fabric/**/*.h",
|
||||
"React/Fabric/**/*.h",
|
||||
],
|
||||
),
|
||||
header_namespace = "",
|
||||
exported_headers = {
|
||||
"React/RCTComponentViewDescriptor.h": "packages/react-native/React/Fabric/Mounting/RCTComponentViewDescriptor.h",
|
||||
"React/RCTComponentViewFactory.h": "packages/react-native/React/Fabric/Mounting/RCTComponentViewFactory.h",
|
||||
"React/RCTComponentViewRegistry.h": "packages/react-native/React/Fabric/Mounting/RCTComponentViewRegistry.h",
|
||||
"React/RCTFabricSurface.h": "packages/react-native/React/Fabric/Surface/RCTFabricSurface.h",
|
||||
"React/RCTFabricSurfaceHostingProxyRootView.h": "packages/react-native/React/Fabric/Surface/RCTFabricSurfaceHostingProxyRootView.h",
|
||||
"React/RCTGenericDelegateSplitter.h": "packages/react-native/React/Fabric/Utils/RCTGenericDelegateSplitter.h",
|
||||
"React/RCTLegacyViewManagerInteropComponentView.h": "packages/react-native/React/Fabric/Mounting/ComponentViews/LegacyViewManagerInterop/RCTLegacyViewManagerInteropComponentView.h",
|
||||
"React/RCTLocalizationProvider.h": "packages/react-native/React/Fabric/RCTLocalizationProvider.h",
|
||||
"React/RCTModalHostViewComponentView.h": "packages/react-native/React/Fabric/Mounting/ComponentViews/Modal/RCTModalHostViewComponentView.h",
|
||||
"React/RCTMountingManager.h": "packages/react-native/React/Fabric/Mounting/RCTMountingManager.h",
|
||||
"React/RCTMountingManagerDelegate.h": "packages/react-native/React/Fabric/Mounting/RCTMountingManagerDelegate.h",
|
||||
"React/RCTMountingTransactionObserving.h": "packages/react-native/React/Fabric/Mounting/RCTMountingTransactionObserving.h",
|
||||
"React/RCTParagraphComponentAccessibilityProvider.h": "packages/react-native/React/Fabric/Mounting/ComponentViews/Text/RCTParagraphComponentAccessibilityProvider.h",
|
||||
"React/RCTParagraphComponentView.h": "packages/react-native/React/Fabric/Mounting/ComponentViews/Text/RCTParagraphComponentView.h",
|
||||
"React/RCTPrimitives.h": "packages/react-native/React/Fabric/RCTPrimitives.h",
|
||||
"React/RCTRootComponentView.h": "packages/react-native/React/Fabric/Mounting/ComponentViews/Root/RCTRootComponentView.h",
|
||||
"React/RCTScheduler.h": "packages/react-native/React/Fabric/RCTScheduler.h",
|
||||
"React/RCTScrollViewComponentView.h": "packages/react-native/React/Fabric/Mounting/ComponentViews/ScrollView/RCTScrollViewComponentView.h",
|
||||
"React/RCTSurfacePresenter.h": "packages/react-native/React/Fabric/RCTSurfacePresenter.h",
|
||||
"React/RCTSurfacePresenterBridgeAdapter.h": "packages/react-native/React/Fabric/RCTSurfacePresenterBridgeAdapter.h",
|
||||
"React/RCTSurfaceRegistry.h": "packages/react-native/React/Fabric/RCTSurfaceRegistry.h",
|
||||
"React/RCTSurfaceTouchHandler.h": "packages/react-native/React/Fabric/RCTSurfaceTouchHandler.h",
|
||||
"React/RCTComponentViewDescriptor.h": "React/Fabric/Mounting/RCTComponentViewDescriptor.h",
|
||||
"React/RCTComponentViewFactory.h": "React/Fabric/Mounting/RCTComponentViewFactory.h",
|
||||
"React/RCTComponentViewRegistry.h": "React/Fabric/Mounting/RCTComponentViewRegistry.h",
|
||||
"React/RCTFabricSurface.h": "React/Fabric/Surface/RCTFabricSurface.h",
|
||||
"React/RCTFabricSurfaceHostingProxyRootView.h": "React/Fabric/Surface/RCTFabricSurfaceHostingProxyRootView.h",
|
||||
"React/RCTGenericDelegateSplitter.h": "React/Fabric/Utils/RCTGenericDelegateSplitter.h",
|
||||
"React/RCTLegacyViewManagerInteropComponentView.h": "React/Fabric/Mounting/ComponentViews/LegacyViewManagerInterop/RCTLegacyViewManagerInteropComponentView.h",
|
||||
"React/RCTLocalizationProvider.h": "React/Fabric/RCTLocalizationProvider.h",
|
||||
"React/RCTModalHostViewComponentView.h": "React/Fabric/Mounting/ComponentViews/Modal/RCTModalHostViewComponentView.h",
|
||||
"React/RCTMountingManager.h": "React/Fabric/Mounting/RCTMountingManager.h",
|
||||
"React/RCTMountingManagerDelegate.h": "React/Fabric/Mounting/RCTMountingManagerDelegate.h",
|
||||
"React/RCTMountingTransactionObserving.h": "React/Fabric/Mounting/RCTMountingTransactionObserving.h",
|
||||
"React/RCTParagraphComponentAccessibilityProvider.h": "React/Fabric/Mounting/ComponentViews/Text/RCTParagraphComponentAccessibilityProvider.h",
|
||||
"React/RCTParagraphComponentView.h": "React/Fabric/Mounting/ComponentViews/Text/RCTParagraphComponentView.h",
|
||||
"React/RCTPrimitives.h": "React/Fabric/RCTPrimitives.h",
|
||||
"React/RCTRootComponentView.h": "React/Fabric/Mounting/ComponentViews/Root/RCTRootComponentView.h",
|
||||
"React/RCTScheduler.h": "React/Fabric/RCTScheduler.h",
|
||||
"React/RCTScrollViewComponentView.h": "React/Fabric/Mounting/ComponentViews/ScrollView/RCTScrollViewComponentView.h",
|
||||
"React/RCTSurfacePresenter.h": "React/Fabric/RCTSurfacePresenter.h",
|
||||
"React/RCTSurfacePresenterBridgeAdapter.h": "React/Fabric/RCTSurfacePresenterBridgeAdapter.h",
|
||||
"React/RCTSurfaceRegistry.h": "React/Fabric/RCTSurfaceRegistry.h",
|
||||
"React/RCTSurfaceTouchHandler.h": "React/Fabric/RCTSurfaceTouchHandler.h",
|
||||
},
|
||||
compiler_flags = [
|
||||
"-fexceptions",
|
||||
@@ -521,6 +527,7 @@ rn_apple_xplat_cxx_library(
|
||||
react_fabric_component_plugin_provider("ScrollView", "RCTScrollViewCls"),
|
||||
react_fabric_component_plugin_provider("PullToRefreshView", "RCTPullToRefreshViewCls"),
|
||||
react_fabric_component_plugin_provider("ActivityIndicatorView", "RCTActivityIndicatorViewCls"),
|
||||
react_fabric_component_plugin_provider("Slider", "RCTSliderCls"),
|
||||
react_fabric_component_plugin_provider("Switch", "RCTSwitchCls"),
|
||||
react_fabric_component_plugin_provider("UnimplementedNativeView", "RCTUnimplementedNativeViewCls"),
|
||||
react_fabric_component_plugin_provider("Paragraph", "RCTParagraphCls"),
|
||||
@@ -561,6 +568,7 @@ rn_apple_xplat_cxx_library(
|
||||
exported_deps = [
|
||||
react_native_xplat_target("react/renderer/animations:animations"),
|
||||
react_native_xplat_target("react/renderer/components/scrollview:scrollview"),
|
||||
react_native_xplat_target("react/renderer/components/slider:slider"),
|
||||
react_native_xplat_target("react/renderer/components/safeareaview:safeareaview"),
|
||||
react_native_xplat_target("react/renderer/components/modal:modal"),
|
||||
react_native_xplat_target("react/renderer/components/unimplementedview:unimplementedview"),
|
||||
@@ -579,17 +587,16 @@ rn_apple_xplat_cxx_library(
|
||||
rn_apple_library(
|
||||
name = "RCTTypeSafety",
|
||||
srcs = glob([
|
||||
"packages/react-native/Libraries/TypeSafety/**/*.mm",
|
||||
"Libraries/TypeSafety/**/*.mm",
|
||||
]),
|
||||
exported_headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/TypeSafety/**/*.h",
|
||||
"Libraries/TypeSafety/**/*.h",
|
||||
],
|
||||
),
|
||||
autoglob = False,
|
||||
complete_nullability = True,
|
||||
contacts = ["oncall+react_native@xmail.facebook.com"],
|
||||
disable_infer_precompiled_header = True,
|
||||
extension_api_only = True,
|
||||
frameworks = [
|
||||
"Foundation",
|
||||
@@ -605,7 +612,7 @@ rn_apple_library(
|
||||
deps = [
|
||||
":ReactInternalApple",
|
||||
"//xplat/folly:optionalApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/Libraries/FBLazyVector:FBLazyVector",
|
||||
"//xplat/js/react-native-github/Libraries/FBLazyVector:FBLazyVector",
|
||||
],
|
||||
)
|
||||
|
||||
@@ -619,7 +626,7 @@ yarn_workspace(
|
||||
|
||||
fb_apple_test(
|
||||
name = "TextTestsApple",
|
||||
srcs = ["packages/react-native/React/Tests/Text/RCTParagraphComponentViewTests.mm"],
|
||||
srcs = ["React/Tests/Text/RCTParagraphComponentViewTests.mm"],
|
||||
frameworks = [
|
||||
"$PLATFORM_DIR/Developer/Library/Frameworks/XCTest.framework",
|
||||
],
|
||||
@@ -629,20 +636,20 @@ fb_apple_test(
|
||||
react_native_xplat_target("react/renderer/element:elementApple"),
|
||||
"//xplat/js/react-native-github:RCTFabricComponentViewsBaseApple",
|
||||
"//xplat/js/react-native-github:RCTTextApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/renderer/attributedstring:attributedstringApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/renderer/componentregistry:componentregistryApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/renderer/components/legacyviewmanagerinterop:legacyviewmanagerinteropApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/renderer/components/text:textApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/renderer/components/textinput/iostextinput:iostextinputApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/renderer/scheduler:schedulerApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/renderer/textlayoutmanager:textlayoutmanagerApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/runtimeexecutor:runtimeexecutorApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/renderer/attributedstring:attributedstringApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/renderer/componentregistry:componentregistryApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/renderer/components/legacyviewmanagerinterop:legacyviewmanagerinteropApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/renderer/components/text:textApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/renderer/components/textinput/iostextinput:iostextinputApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/renderer/scheduler:schedulerApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/renderer/textlayoutmanager:textlayoutmanagerApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/runtimeexecutor:runtimeexecutorApple",
|
||||
],
|
||||
)
|
||||
|
||||
fb_apple_test(
|
||||
name = "MountingTestsApple",
|
||||
srcs = ["packages/react-native/React/Tests/Mounting/RCTComponentViewRegistryTests.mm"],
|
||||
srcs = ["React/Tests/Mounting/RCTComponentViewRegistryTests.mm"],
|
||||
frameworks = [
|
||||
"$PLATFORM_DIR/Developer/Library/Frameworks/XCTest.framework",
|
||||
],
|
||||
@@ -652,13 +659,13 @@ fb_apple_test(
|
||||
":RCTFabricApple",
|
||||
"//xplat/js/react-native-github:RCTFabricComponentViewsBaseApple",
|
||||
"//xplat/js/react-native-github:RCTTextApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/renderer/attributedstring:attributedstringApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/renderer/componentregistry:componentregistryApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/renderer/components/legacyviewmanagerinterop:legacyviewmanagerinteropApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/renderer/components/textinput/iostextinput:iostextinputApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/renderer/scheduler:schedulerApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/react/renderer/textlayoutmanager:textlayoutmanagerApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/ReactCommon/runtimeexecutor:runtimeexecutorApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/renderer/attributedstring:attributedstringApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/renderer/componentregistry:componentregistryApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/renderer/components/legacyviewmanagerinterop:legacyviewmanagerinteropApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/renderer/components/textinput/iostextinput:iostextinputApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/renderer/scheduler:schedulerApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/react/renderer/textlayoutmanager:textlayoutmanagerApple",
|
||||
"//xplat/js/react-native-github/ReactCommon/runtimeexecutor:runtimeexecutorApple",
|
||||
],
|
||||
)
|
||||
|
||||
@@ -683,19 +690,19 @@ rn_apple_library(
|
||||
# Ideally, each component view gets its own target, and each target uses react_fabric_component_plugin_provider.
|
||||
# For each component, an app can import the base component view, or an app-specific subclass.
|
||||
# i.e. Apps depend on "ImageView" target for RCTImageComponentView.h, and "FBReactImageView" target for FBReactImageComponentView.h
|
||||
rn_apple_xplat_cxx_library(
|
||||
rn_xplat_cxx_library2(
|
||||
name = "RCTFabricComponentViewsBase",
|
||||
srcs = glob(REACT_COMPONENTVIEWS_BASE_FILES),
|
||||
header_namespace = "",
|
||||
exported_headers = {
|
||||
"React/RCTComponentViewProtocol.h": "packages/react-native/React/Fabric/Mounting/RCTComponentViewProtocol.h",
|
||||
"React/RCTConversions.h": "packages/react-native/React/Fabric/RCTConversions.h",
|
||||
"React/RCTImageComponentView.h": "packages/react-native/React/Fabric/Mounting/ComponentViews/Image/RCTImageComponentView.h",
|
||||
"React/RCTImageResponseDelegate.h": "packages/react-native/React/Fabric/RCTImageResponseDelegate.h",
|
||||
"React/RCTImageResponseObserverProxy.h": "packages/react-native/React/Fabric/RCTImageResponseObserverProxy.h",
|
||||
"React/RCTTouchableComponentViewProtocol.h": "packages/react-native/React/Fabric/RCTTouchableComponentViewProtocol.h",
|
||||
"React/RCTViewComponentView.h": "packages/react-native/React/Fabric/Mounting/ComponentViews/View/RCTViewComponentView.h",
|
||||
"React/UIView+ComponentViewProtocol.h": "packages/react-native/React/Fabric/Mounting/UIView+ComponentViewProtocol.h",
|
||||
"React/RCTComponentViewProtocol.h": "React/Fabric/Mounting/RCTComponentViewProtocol.h",
|
||||
"React/RCTConversions.h": "React/Fabric/RCTConversions.h",
|
||||
"React/RCTImageComponentView.h": "React/Fabric/Mounting/ComponentViews/Image/RCTImageComponentView.h",
|
||||
"React/RCTImageResponseDelegate.h": "React/Fabric/RCTImageResponseDelegate.h",
|
||||
"React/RCTImageResponseObserverProxy.h": "React/Fabric/RCTImageResponseObserverProxy.h",
|
||||
"React/RCTTouchableComponentViewProtocol.h": "React/Fabric/RCTTouchableComponentViewProtocol.h",
|
||||
"React/RCTViewComponentView.h": "React/Fabric/Mounting/ComponentViews/View/RCTViewComponentView.h",
|
||||
"React/UIView+ComponentViewProtocol.h": "React/Fabric/Mounting/UIView+ComponentViewProtocol.h",
|
||||
},
|
||||
compiler_flags = ["-Wall"],
|
||||
contacts = ["oncall+react_native@xmail.facebook.com"],
|
||||
@@ -716,20 +723,18 @@ rn_apple_xplat_cxx_library(
|
||||
rn_library(
|
||||
name = "react-native",
|
||||
srcs = [
|
||||
"packages/react-native/package.json",
|
||||
"packages/react-native/index.js",
|
||||
"package.json",
|
||||
"index.js",
|
||||
] + glob(
|
||||
[
|
||||
"packages/react-native/Libraries/**/*.js",
|
||||
"packages/react-native/Libraries/NewAppScreen/**/*.png",
|
||||
"packages/react-native/Libraries/LogBox/**/*.png",
|
||||
"packages/virtualized-lists/**/*.js",
|
||||
"packages/virtualized-lists/**/*.json",
|
||||
"Libraries/**/*.js",
|
||||
"Libraries/NewAppScreen/**/*.png",
|
||||
"Libraries/LogBox/**/*.png",
|
||||
],
|
||||
exclude = [
|
||||
"**/__*__/**",
|
||||
"**/gulpfile.js",
|
||||
"packages/react-native/Libraries/Components/Switch/SwitchSchema.js",
|
||||
"Libraries/Components/Switch/SwitchSchema.js",
|
||||
"**/*._reactvr.js",
|
||||
],
|
||||
),
|
||||
@@ -743,7 +748,6 @@ rn_library(
|
||||
"//xplat/js:node_modules__base64_19js",
|
||||
"//xplat/js:node_modules__deprecated_19react_19native_19prop_19types",
|
||||
"//xplat/js:node_modules__event_19target_19shim",
|
||||
"//xplat/js:node_modules__flow_19enums_19runtime",
|
||||
"//xplat/js:node_modules__invariant",
|
||||
"//xplat/js:node_modules__memoize_19one",
|
||||
"//xplat/js:node_modules__nullthrows",
|
||||
@@ -778,7 +782,7 @@ rn_codegen(
|
||||
"pfh:ReactNative_CommonInfrastructurePlaceholder",
|
||||
],
|
||||
native_module_spec_name = "FBReactNativeSpec",
|
||||
src_prefix = "packages/react-native/Libraries/",
|
||||
src_prefix = "Libraries/",
|
||||
)
|
||||
|
||||
# TODO: Merge this into FBReactNativeSpec
|
||||
@@ -789,26 +793,26 @@ rn_codegen(
|
||||
library_labels = [
|
||||
"pfh:ReactNative_CommonInfrastructurePlaceholder",
|
||||
],
|
||||
src_prefix = "packages/react-native/Libraries/",
|
||||
src_prefix = "Libraries/",
|
||||
)
|
||||
|
||||
rn_apple_library(
|
||||
name = "RCTAnimationApple",
|
||||
srcs = glob([
|
||||
"packages/react-native/Libraries/NativeAnimation/**/*.m",
|
||||
"packages/react-native/Libraries/NativeAnimation/**/*.mm",
|
||||
"Libraries/NativeAnimation/**/*.m",
|
||||
"Libraries/NativeAnimation/**/*.mm",
|
||||
]),
|
||||
headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/NativeAnimation/**/*.h",
|
||||
"Libraries/NativeAnimation/**/*.h",
|
||||
],
|
||||
),
|
||||
header_namespace = "",
|
||||
exported_headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/NativeAnimation/*.h",
|
||||
"packages/react-native/Libraries/NativeAnimation/Drivers/*.h",
|
||||
"packages/react-native/Libraries/NativeAnimation/Nodes/*.h",
|
||||
"Libraries/NativeAnimation/*.h",
|
||||
"Libraries/NativeAnimation/Drivers/*.h",
|
||||
"Libraries/NativeAnimation/Nodes/*.h",
|
||||
],
|
||||
),
|
||||
autoglob = False,
|
||||
@@ -850,17 +854,17 @@ rn_apple_library(
|
||||
rn_apple_library(
|
||||
name = "RCTBlobApple",
|
||||
srcs = glob([
|
||||
"packages/react-native/Libraries/Blob/*.m",
|
||||
"packages/react-native/Libraries/Blob/*.mm",
|
||||
"Libraries/Blob/*.m",
|
||||
"Libraries/Blob/*.mm",
|
||||
]),
|
||||
headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/Blob/*.h",
|
||||
"Libraries/Blob/*.h",
|
||||
],
|
||||
),
|
||||
exported_headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/Blob/*.h",
|
||||
"Libraries/Blob/*.h",
|
||||
],
|
||||
),
|
||||
autoglob = False,
|
||||
@@ -900,7 +904,7 @@ rn_apple_library(
|
||||
"//xplat/js/react-native-github:RCTLinkingApple",
|
||||
"//xplat/js/react-native-github:RCTPushNotificationApple",
|
||||
"//xplat/js/react-native-github:ReactInternalApple",
|
||||
"//xplat/js/react-native-github/packages/react-native/React/CoreModules:CoreModulesApple",
|
||||
"//xplat/js/react-native-github/React/CoreModules:CoreModulesApple",
|
||||
"//xplat/jsi:jsiApple",
|
||||
],
|
||||
)
|
||||
@@ -908,17 +912,17 @@ rn_apple_library(
|
||||
rn_apple_library(
|
||||
name = "RCTLinkingApple",
|
||||
srcs = glob([
|
||||
"packages/react-native/Libraries/LinkingIOS/*.m",
|
||||
"packages/react-native/Libraries/LinkingIOS/*.mm",
|
||||
"Libraries/LinkingIOS/*.m",
|
||||
"Libraries/LinkingIOS/*.mm",
|
||||
]),
|
||||
headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/LinkingIOS/*.h",
|
||||
"Libraries/LinkingIOS/*.h",
|
||||
],
|
||||
),
|
||||
exported_headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/LinkingIOS/*.h",
|
||||
"Libraries/LinkingIOS/*.h",
|
||||
],
|
||||
),
|
||||
autoglob = False,
|
||||
@@ -957,17 +961,17 @@ rn_apple_library(
|
||||
rn_apple_library(
|
||||
name = "RCTPushNotificationApple",
|
||||
srcs = glob([
|
||||
"packages/react-native/Libraries/PushNotificationIOS/*.m",
|
||||
"packages/react-native/Libraries/PushNotificationIOS/*.mm",
|
||||
"Libraries/PushNotificationIOS/*.m",
|
||||
"Libraries/PushNotificationIOS/*.mm",
|
||||
]),
|
||||
headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/PushNotificationIOS/*.h",
|
||||
"Libraries/PushNotificationIOS/*.h",
|
||||
],
|
||||
),
|
||||
exported_headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/PushNotificationIOS/*.h",
|
||||
"Libraries/PushNotificationIOS/*.h",
|
||||
],
|
||||
),
|
||||
autoglob = False,
|
||||
@@ -1005,17 +1009,17 @@ rn_apple_library(
|
||||
rn_apple_library(
|
||||
name = "RCTImageApple",
|
||||
srcs = glob([
|
||||
"packages/react-native/Libraries/Image/*.m",
|
||||
"packages/react-native/Libraries/Image/*.mm",
|
||||
"Libraries/Image/*.m",
|
||||
"Libraries/Image/*.mm",
|
||||
]),
|
||||
headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/Image/*.h",
|
||||
"Libraries/Image/*.h",
|
||||
],
|
||||
),
|
||||
exported_headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/Image/*.h",
|
||||
"Libraries/Image/*.h",
|
||||
],
|
||||
),
|
||||
autoglob = False,
|
||||
@@ -1087,19 +1091,19 @@ rn_apple_library(
|
||||
)
|
||||
|
||||
RCTNETWORK_PUBLIC_HEADERS = [
|
||||
"packages/react-native/Libraries/Network/RCTNetworkTask.h",
|
||||
"packages/react-native/Libraries/Network/RCTNetworking.h",
|
||||
"Libraries/Network/RCTNetworkTask.h",
|
||||
"Libraries/Network/RCTNetworking.h",
|
||||
]
|
||||
|
||||
rn_apple_library(
|
||||
name = "RCTNetworkApple",
|
||||
srcs = glob([
|
||||
"packages/react-native/Libraries/Network/*.m",
|
||||
"packages/react-native/Libraries/Network/*.mm",
|
||||
"Libraries/Network/*.m",
|
||||
"Libraries/Network/*.mm",
|
||||
]),
|
||||
headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/Network/*.h",
|
||||
"Libraries/Network/*.h",
|
||||
],
|
||||
exclude = RCTNETWORK_PUBLIC_HEADERS,
|
||||
),
|
||||
@@ -1163,16 +1167,15 @@ rn_apple_library(
|
||||
rn_apple_library(
|
||||
name = "RCTSettingsApple",
|
||||
srcs = glob([
|
||||
"packages/react-native/Libraries/Settings/*.m",
|
||||
"packages/react-native/Libraries/Settings/*.mm",
|
||||
"Libraries/Settings/*.m",
|
||||
"Libraries/Settings/*.mm",
|
||||
]),
|
||||
exported_headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/Settings/*.h",
|
||||
"Libraries/Settings/*.h",
|
||||
],
|
||||
),
|
||||
autoglob = False,
|
||||
extension_api_only = True,
|
||||
frameworks = [
|
||||
"Foundation",
|
||||
],
|
||||
@@ -1198,50 +1201,50 @@ rn_apple_library(
|
||||
],
|
||||
)
|
||||
|
||||
rn_apple_xplat_cxx_library(
|
||||
rn_xplat_cxx_library2(
|
||||
name = "RCTText",
|
||||
srcs = glob([
|
||||
"packages/react-native/Libraries/Text/**/*.m",
|
||||
"packages/react-native/Libraries/Text/**/*.mm",
|
||||
"Libraries/Text/**/*.m",
|
||||
"Libraries/Text/**/*.mm",
|
||||
]),
|
||||
headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/Text/**/*.h",
|
||||
"Libraries/Text/**/*.h",
|
||||
],
|
||||
),
|
||||
header_namespace = "",
|
||||
exported_headers = subdir_glob(
|
||||
[
|
||||
(
|
||||
"packages/react-native/Libraries/Text",
|
||||
"Libraries/Text",
|
||||
"*.h",
|
||||
),
|
||||
(
|
||||
"packages/react-native/Libraries/Text/BaseText",
|
||||
"Libraries/Text/BaseText",
|
||||
"*.h",
|
||||
),
|
||||
(
|
||||
"packages/react-native/Libraries/Text/RawText",
|
||||
"Libraries/Text/RawText",
|
||||
"*.h",
|
||||
),
|
||||
(
|
||||
"packages/react-native/Libraries/Text/Text",
|
||||
"Libraries/Text/Text",
|
||||
"*.h",
|
||||
),
|
||||
(
|
||||
"packages/react-native/Libraries/Text/TextInput",
|
||||
"Libraries/Text/TextInput",
|
||||
"*.h",
|
||||
),
|
||||
(
|
||||
"packages/react-native/Libraries/Text/TextInput/Multiline",
|
||||
"Libraries/Text/TextInput/Multiline",
|
||||
"*.h",
|
||||
),
|
||||
(
|
||||
"packages/react-native/Libraries/Text/TextInput/Singleline",
|
||||
"Libraries/Text/TextInput/Singleline",
|
||||
"*.h",
|
||||
),
|
||||
(
|
||||
"packages/react-native/Libraries/Text/VirtualText",
|
||||
"Libraries/Text/VirtualText",
|
||||
"*.h",
|
||||
),
|
||||
],
|
||||
@@ -1267,12 +1270,12 @@ rn_apple_xplat_cxx_library(
|
||||
rn_apple_library(
|
||||
name = "RCTVibrationApple",
|
||||
srcs = glob([
|
||||
"packages/react-native/Libraries/Vibration/**/*.m",
|
||||
"packages/react-native/Libraries/Vibration/**/*.mm",
|
||||
"Libraries/Vibration/**/*.m",
|
||||
"Libraries/Vibration/**/*.mm",
|
||||
]),
|
||||
exported_headers = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/Vibration/*.h",
|
||||
"Libraries/Vibration/*.h",
|
||||
],
|
||||
),
|
||||
autoglob = False,
|
||||
@@ -1304,17 +1307,17 @@ rn_apple_library(
|
||||
],
|
||||
)
|
||||
|
||||
rn_apple_xplat_cxx_library(
|
||||
rn_xplat_cxx_library2(
|
||||
name = "RCTWrapper",
|
||||
srcs = glob([
|
||||
"packages/react-native/Libraries/Wrapper/*.m",
|
||||
"packages/react-native/Libraries/Wrapper/*.mm",
|
||||
"Libraries/Wrapper/*.m",
|
||||
"Libraries/Wrapper/*.mm",
|
||||
]),
|
||||
header_namespace = "",
|
||||
exported_headers = subdir_glob(
|
||||
[
|
||||
(
|
||||
"packages/react-native/Libraries/Wrapper",
|
||||
"Libraries/Wrapper",
|
||||
"*.h",
|
||||
),
|
||||
],
|
||||
@@ -1336,17 +1339,17 @@ rn_apple_xplat_cxx_library(
|
||||
],
|
||||
)
|
||||
|
||||
rn_apple_xplat_cxx_library(
|
||||
rn_xplat_cxx_library2(
|
||||
name = "RCTWrapperExample",
|
||||
srcs = glob([
|
||||
"packages/react-native/Libraries/Wrapper/Example/*.m",
|
||||
"packages/react-native/Libraries/Wrapper/Example/*.mm",
|
||||
"Libraries/Wrapper/Example/*.m",
|
||||
"Libraries/Wrapper/Example/*.mm",
|
||||
]),
|
||||
header_namespace = "",
|
||||
exported_headers = subdir_glob(
|
||||
[
|
||||
(
|
||||
"packages/react-native/Libraries/Wrapper/Example",
|
||||
"Libraries/Wrapper/Example",
|
||||
"*.h",
|
||||
),
|
||||
],
|
||||
@@ -1369,17 +1372,17 @@ rn_apple_xplat_cxx_library(
|
||||
],
|
||||
)
|
||||
|
||||
rn_apple_xplat_cxx_library(
|
||||
rn_xplat_cxx_library2(
|
||||
name = "RCTSurfaceHostingComponent",
|
||||
srcs = glob([
|
||||
"packages/react-native/Libraries/SurfaceHostingComponent/**/*.m",
|
||||
"packages/react-native/Libraries/SurfaceHostingComponent/**/*.mm",
|
||||
"Libraries/SurfaceHostingComponent/**/*.m",
|
||||
"Libraries/SurfaceHostingComponent/**/*.mm",
|
||||
]),
|
||||
header_namespace = "",
|
||||
exported_headers = subdir_glob(
|
||||
[
|
||||
(
|
||||
"packages/react-native/Libraries/SurfaceHostingComponent",
|
||||
"Libraries/SurfaceHostingComponent",
|
||||
"*.h",
|
||||
),
|
||||
],
|
||||
@@ -1404,17 +1407,17 @@ rn_apple_xplat_cxx_library(
|
||||
],
|
||||
)
|
||||
|
||||
rn_apple_xplat_cxx_library(
|
||||
rn_xplat_cxx_library2(
|
||||
name = "RCTSurfaceBackedComponent",
|
||||
srcs = glob([
|
||||
"packages/react-native/Libraries/SurfaceBackedComponent/**/*.m",
|
||||
"packages/react-native/Libraries/SurfaceBackedComponent/**/*.mm",
|
||||
"Libraries/SurfaceBackedComponent/**/*.m",
|
||||
"Libraries/SurfaceBackedComponent/**/*.mm",
|
||||
]),
|
||||
header_namespace = "",
|
||||
exported_headers = subdir_glob(
|
||||
[
|
||||
(
|
||||
"packages/react-native/Libraries/SurfaceBackedComponent",
|
||||
"Libraries/SurfaceBackedComponent",
|
||||
"*.h",
|
||||
),
|
||||
],
|
||||
@@ -1440,7 +1443,7 @@ rn_apple_xplat_cxx_library(
|
||||
],
|
||||
)
|
||||
|
||||
rn_apple_xplat_cxx_library(
|
||||
rn_xplat_cxx_library2(
|
||||
name = "RCTMapView_RNHeader",
|
||||
header_namespace = "",
|
||||
exported_headers = {
|
||||
@@ -1455,61 +1458,27 @@ rn_apple_xplat_cxx_library(
|
||||
],
|
||||
)
|
||||
|
||||
rn_xplat_cxx_library(
|
||||
rn_xplat_cxx_library2(
|
||||
name = "RCTWebPerformance",
|
||||
srcs = glob(
|
||||
[
|
||||
"packages/react-native/Libraries/WebPerformance/**/*.cpp",
|
||||
],
|
||||
exclude = ["packages/react-native/Libraries/WebPerformance/__tests__/*"],
|
||||
),
|
||||
srcs = glob([
|
||||
"Libraries/WebPerformance/**/*.cpp",
|
||||
]),
|
||||
header_namespace = "",
|
||||
exported_headers = subdir_glob(
|
||||
[("packages/react-native/Libraries/WebPerformance", "*.h")],
|
||||
[("Libraries/WebPerformance", "*.h")],
|
||||
prefix = "RCTWebPerformance",
|
||||
),
|
||||
compiler_flags_enable_exceptions = True,
|
||||
compiler_flags_enable_rtti = True,
|
||||
fbandroid_compiler_flags = [
|
||||
"-fexceptions",
|
||||
"-frtti",
|
||||
],
|
||||
labels = [
|
||||
"depslint_never_remove",
|
||||
"pfh:ReactNative_CommonInfrastructurePlaceholder",
|
||||
],
|
||||
platforms = (ANDROID, APPLE),
|
||||
plugins = [
|
||||
react_cxx_module_plugin_provider(
|
||||
name = "NativePerformanceCxx",
|
||||
function = "NativePerformanceModuleProvider",
|
||||
),
|
||||
react_cxx_module_plugin_provider(
|
||||
name = "NativePerformanceObserverCxx",
|
||||
function = "NativePerformanceObserverModuleProvider",
|
||||
),
|
||||
],
|
||||
platforms = (ANDROID, APPLE, CXX),
|
||||
visibility = ["PUBLIC"],
|
||||
deps = [
|
||||
":FBReactNativeSpecJSI",
|
||||
react_native_xplat_target("react/renderer/core:core"),
|
||||
react_native_xplat_target("cxxreact:bridge"),
|
||||
],
|
||||
)
|
||||
|
||||
fb_xplat_cxx_test(
|
||||
name = "RCTWebPerformance_tests",
|
||||
srcs = glob([
|
||||
"Libraries/WebPerformance/__tests__/*.cpp",
|
||||
]),
|
||||
headers = glob(["Libraries/WebPerformance/__tests__/*.h"]),
|
||||
header_namespace = "",
|
||||
compiler_flags = [
|
||||
"-fexceptions",
|
||||
"-frtti",
|
||||
"-std=c++17",
|
||||
"-Wall",
|
||||
],
|
||||
platforms = (ANDROID, APPLE),
|
||||
deps = [
|
||||
":RCTWebPerformance",
|
||||
"//xplat/third-party/gmock:gmock",
|
||||
"//xplat/third-party/gmock:gtest",
|
||||
],
|
||||
)
|
||||
|
||||
-677
@@ -1,597 +1,5 @@
|
||||
# Changelog
|
||||
|
||||
## v0.71.4
|
||||
|
||||
### Changed
|
||||
|
||||
- Make FlatList permissive of ArrayLike data ([c03de97fb4](https://github.com/facebook/react-native/commit/c03de97fb44f0aecbec8f930bd99fe26f37f9648) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Bumping RNGP to `^0.71.16` ([3df4a79c3d](https://github.com/facebook/react-native/commit/3df4a79c3d8e788ffb113fde801836251eed4c03) by [@kelset](https://github.com/kelset))
|
||||
- Update CLI to 10.2.0, Metro to 0.73.8 ([20a6fbd373](https://github.com/facebook/react-native/commit/20a6fbd37312ff4e6bb11f6f43b9abc2f559e1fb) by [@robhogan](https://github.com/robhogan)) - contains:
|
||||
- fix: Source maps may have invalid entries when using Terser minification. ((`metro/#928`)[https://github.com/facebook/metro/pull/928])
|
||||
- fix: Mitigate potential source map mismatches with concurrent transformations due to terser#1341. ((`metro/#929`)[https://github.com/facebook/metro/pull/929])
|
||||
- Bump Hermes Version ([291cc0af10](https://github.com/facebook/react-native/commit/291cc0af100fe2aa6201f04ebd6c8c889a018d45)) - contains:
|
||||
- use ConsecutiveStringStorage to dedup serialized literals ([62d58e](https://github.com/facebook/hermes/commit/62d58e5d6747da8b8ee9e18eb8d0f57469acf201))
|
||||
- Remove register stack size override in hermes.cpp ([6146eb](https://github.com/facebook/hermes/commit/6146eb39e9eb8e712169697eac75001c2aeab40d))
|
||||
- fix: specify currency in locale identifier when formatting currency plural ([21f15c](https://github.com/facebook/hermes/commit/21f15c537a49a39bdf1b5440cde0b7312497431d))
|
||||
- Increase default max stack size ([ee2588](https://github.com/facebook/hermes/commit/ee25883ea34374f687883a641c8101ac0d292fc6))
|
||||
- Refactor HBC test helper ([31fdcf](https://github.com/facebook/hermes/commit/31fdcf738940875c9bacf251e149006cf515d763))
|
||||
|
||||
#### Android specific
|
||||
|
||||
- Expose `rrc_root` via prefab. ([3418f65d88](https://github.com/facebook/react-native/commit/3418f65d88fa8be3473f757e932ecba1bbfce783) by [@tomekzaw](https://github.com/tomekzaw))
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fix touchable hitSlop type ([23607aea68](https://github.com/facebook/react-native/commit/23607aea688c950fe0cf424b280a2339636130fe) by [@bigcupcoffee](https://github.com/bigcupcoffee))
|
||||
- Fix TouchableOpacity componentDidUpdate causing an excessive number of pending callbacks ([8b1f6e09c1](https://github.com/facebook/react-native/commit/8b1f6e09c1b11e07096156d8d01aaff649745fbc) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
|
||||
#### Android specific
|
||||
|
||||
- ENTRY_FILE should resolve relative paths from root ([6dde1dc7cb](https://github.com/facebook/react-native/commit/6dde1dc7cb487271567aaa9c7e093bb76c0689ad) by [@cortinico](https://github.com/cortinico))
|
||||
- Better Monorepo support for New Architecture ([0487108461](https://github.com/facebook/react-native/commit/0487108461010154cf959bb0bf6ba9e82fdcc4d1) by [@cortinico](https://github.com/cortinico))
|
||||
|
||||
## v0.71.3
|
||||
|
||||
### Changed
|
||||
|
||||
- Bump package versions ([4b84888a90](https://github.com/facebook/react-native/commit/4b84888a90c9436a8a62cc8507176f1b946b9b93) by [@cipolleschi](https://github.com/cipolleschi)), ([60f0a71060](https://github.com/facebook/react-native/commit/60f0a71060078759b526f65926763274811977f9) by [@cipolleschi](https://github.com/cipolleschi)), ([a3f205a27b](https://github.com/facebook/react-native/commit/a3f205a27b75d4e76354dbcb3203653e1f93f3ee) by [@cipolleschi](https://github.com/cipolleschi)):
|
||||
- `react-native-codegen` to `0.71.5`
|
||||
- `react-native-gradle-plugin` to `0.71.15`
|
||||
|
||||
### Fixed
|
||||
|
||||
- (codegen) Add missing C++ include for prop conversion of complex array type ([92fc32aa](https://github.com/facebook/react-native/commit/92fc32aa053ac8401ad8c9f55dcfa1e48ae8fc1d) by [@rshest](https://github.com/rshest))
|
||||
|
||||
#### Android specific
|
||||
|
||||
- Fixed jscexecutor crash on Android which is caused from NDK incompatibility ([a232decbb1](https://github.com/facebook/react-native/commit/a232decbb1252ade0247a352f887ca4d97ee273c) by [@Kudo](https://github.com/Kudo))
|
||||
- Used relative paths for gradle commands ([bb02ccf13f](https://github.com/facebook/react-native/commit/bb02ccf13f76f46b8572e2a85d578fd8d4fd9467) by [@shivenmian](https://github.com/shivenmian))
|
||||
|
||||
#### iOS specific
|
||||
|
||||
- fix `pod install --project-directory=...` ([ad1ddc241a](https://github.com/facebook/react-native/commit/ad1ddc241af723a3f5da2058709f9684e51fb5ce) by [@tido64](https://github.com/tido64))
|
||||
|
||||
## v0.71.2
|
||||
|
||||
### Added
|
||||
|
||||
- Added AlertOptions argument to the type definition for Alert.prompt to bring it into parity with the js code. ([305ca337c0](https://github.com/facebook/react-native/commit/305ca337c0471c61cb74216bd93ae3f1a232a89f) by [@paulmand3l](https://github.com/paulmand3l))
|
||||
- Added missing `accessibilityLabelledBy` TypeScript type ([e162b07982](https://github.com/facebook/react-native/commit/e162b07982cf9481038de71f5dd7bd9b45387f0a) by [@DimitarNestorov](https://github.com/DimitarNestorov))
|
||||
- Added missing `accessibilityLanguage` TypeScript type ([71c4f57baf](https://github.com/facebook/react-native/commit/71c4f57baf6683ea4304e15c040d6b6c3b3d2b73) by [@DimitarNestorov](https://github.com/DimitarNestorov))
|
||||
|
||||
### Changed
|
||||
|
||||
- Bump `react-native-gradle-plugin` to `^0.71.14` in core, `@react-native-community/eslint-config` to `^3.2.0` in starting template ([785bc8d97b](https://github.com/facebook/react-native/commit/785bc8d97b824a2af86ffe46f321471f4952764c) by [@kelset](https://github.com/kelset))
|
||||
|
||||
### Fixed
|
||||
|
||||
- Add `TextInput`'s `inputMode` TypeScript types ([fac7859863](https://github.com/facebook/react-native/commit/fac7859863c7130740aacc95d0e62417bd8f789e) by [@eps1lon](https://github.com/eps1lon))
|
||||
- Fix crash by conditional value of aspectRatio style value ([a8166bd75b](https://github.com/facebook/react-native/commit/a8166bd75b221f967a859d5cc25b3394c4d35301) by [@mym0404](https://github.com/mym0404))
|
||||
- Fix TurboModuleRegistry TS type ([c289442848](https://github.com/facebook/react-native/commit/c28944284894a3188b97e3d8bb5b489755852160) by [@janicduplessis](https://github.com/janicduplessis))
|
||||
- Fix invariant violation when nesting VirtualizedList inside ListEmptyComponent ([1fef376812](https://github.com/facebook/react-native/commit/1fef37681298c828a07febcd0d975a32f6bc4403) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
|
||||
#### Android specific
|
||||
|
||||
- [RNGP] Properly set the `jsRootDir` default value ([c0004092f9](https://github.com/facebook/react-native/commit/c0004092f935ad892d4a1acf38fb184f1140bfd2) by [@cortinico](https://github.com/cortinico))
|
||||
- Do not use WindowInsetsCompat for Keyboard Events ([32f54877ff](https://github.com/facebook/react-native/commit/32f54877ff788240d24528d208c704ee78e4e761) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Mitigation for Samsung TextInput Hangs ([4650ef3](https://github.com/facebook/react-native/commit/4650ef36e3d63df6e6a31f00fcf323c53daff2d6) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
|
||||
#### iOS specific
|
||||
|
||||
- Add Back dynamic framework support for the Old Architecture with Hermes ([b3040ec624](https://github.com/facebook/react-native/commit/b3040ec6244da6ea274654abfd84516de4f5bf52) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Add Back dynamic framework support for the old architecture ([da270d038c](https://github.com/facebook/react-native/commit/da270d038c271d6b82de568621b49e38739372c6) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
|
||||
## v0.71.1
|
||||
|
||||
### Added
|
||||
|
||||
#### Android specific
|
||||
|
||||
- Add `jsinspector` to the prefab target ([a80cf96fc8](https://github.com/facebook/react-native/commit/a80cf96fc8821dcc07987c9b91dff0c839c8769c) by [@Kudo](https://github.com/Kudo))
|
||||
|
||||
#### iOS specific
|
||||
|
||||
- Add `initialProps` property to `RCTAppDelegate` ([b314e6f147](https://github.com/facebook/react-native/commit/b314e6f147fdfcd71e7ba3b17338bb44356df98e) by [@jblarriviere](https://github.com/jblarriviere))
|
||||
|
||||
### Changed
|
||||
|
||||
- Bump CLI to 10.1.3 ([b868970037](https://github.com/facebook/react-native/commit/b868970037f7fb510b23ac65d378ff1ba28e9af6) by [@kelset](https://github.com/kelset))
|
||||
- Bump RNGP to 0.71.13 ([416463c406](https://github.com/facebook/react-native/commit/416463c4068a3cdb5ed1e01f7e17f22d68c1b9ed) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fix(cli,metro,babel): bump cli and metro and babel to fix Windows+Metro issue ([df7c92ff4c](https://github.com/facebook/react-native/commit/df7c92ff4c095f5f6b3424de7287f5cb124d91d3) by [@kelset](https://github.com/kelset))
|
||||
|
||||
#### Android specific
|
||||
|
||||
- Fix ReactRootView crash when root view window insets are null ([4cdc2c48e8](https://github.com/facebook/react-native/commit/4cdc2c48e826f5bb762085fc38954ed09df6ef12) by [@enahum](https://github.com/enahum))
|
||||
- Fix for resources not correctly bundlded on release appbundles ([60b9d8c2b9](https://github.com/facebook/react-native/commit/60b9d8c2b9800135fdace5f58d94bebde2849510) by [@cortinico](https://github.com/cortinico))
|
||||
- RNGP - Honor the --active-arch-only when configuring the NDK ([470f79b617](https://github.com/facebook/react-native/commit/470f79b61734e085978b03507eda6ed026936b7b) by [@cortinico](https://github.com/cortinico))
|
||||
- Fixed typo in template build.gradle ([38e35df47c](https://github.com/facebook/react-native/commit/38e35df47c59e425fdac34d1f91540b8b8ca2908) by [@Titozzz](https://github.com/Titozzz))
|
||||
|
||||
|
||||
#### iOS specific
|
||||
|
||||
- Exclude `react-native-flipper` when `NO_FLIPPER=1` to prevent iOS build fail ([f47b5b8b5d](https://github.com/facebook/react-native/commit/f47b5b8b5def41aeb6d5b672928cc57e20fba49d) by [@retyui](https://github.com/retyui))
|
||||
- Fix RCTAlertController not showing when using SceneDelegate on iOS 13.0+. ([0c53420a7a](https://github.com/facebook/react-native/commit/0c53420a7af306d629350e1244e8e2ccae08a312))
|
||||
- Handle Null Exception to Validate input in RCTAlertController and in RCTDevLoadingView ([79e603c5ab](https://github.com/facebook/react-native/commit/79e603c5ab5972859153a6ece80cd91ff0a04fc5) by [@admirsaheta](https://github.com/admirsaheta))
|
||||
- Fixed the potential race condition when dismissing and presentating modal ([e948c79bda](https://github.com/facebook/react-native/commit/e948c79bda7f000427d56dac6fe5c70555db5701) by [@wood1986](https://github.com/wood1986))
|
||||
- Fix build errors when inheriting RCTAppDelegate in Swift modules ([5eb25d2186](https://github.com/facebook/react-native/commit/5eb25d2186fd94128ec2ae74fec02429da969e63) by [@Kudo](https://github.com/Kudo))
|
||||
- OnSelectionChange() is fired before onChange() on multiline TextInput ([64475aeb3b](https://github.com/facebook/react-native/commit/64475aeb3b1b0e37bdad2c2d5abb2116b2141c06) by [@s77rt](https://github.com/s77rt))
|
||||
- Build: remove deprecated File.exists() method from Hermes podspec. ([38e5fa6a96](https://github.com/facebook/react-native/commit/38e5fa6a9604ab42fef442e7a51ebfe185df90bb) by [@kelset](https://github.com/kelset))
|
||||
|
||||
## v0.71.0
|
||||
|
||||
Read the [announcement blogpost here](https://reactnative.dev/blog/2023/01/12/version-071).
|
||||
|
||||
⚠️ *Git Bash users on Windows might experience "Unable to resolve" red boxes, because of an issue with Metro (silently fails without discovering any files). It will be fixed in 0.71.1 next week, in the meantime you can set `resolver.useWatchman: false` in `metro.config.js`.*
|
||||
|
||||
### Breaking Changes
|
||||
|
||||
- **Changes to Console Logging:** `LogBox.ignoreLog` no longer filters console logs. This means you will start seeing logs in the console that you have silenced in LogBox. See [this comment](https://github.com/facebook/react-native/pull/34476#issuecomment-1240667794) for more details.
|
||||
- **Removed AsyncStorage and MaskedViewIOS**: These components have been deprecated since version [0.59](https://github.com/facebook/react-native/blob/main/CHANGELOG.md#deprecated-8), so it’s time we remove them entirely. For alternatives, please check [React Native Directory](https://reactnative.directory/) for community packages that cover those use cases.
|
||||
- **JSCRuntime moved to react-jsc:** react-jsi is now split into react-jsc and react-jsi. If you use JSCRuntime, you will need to add react-jsc as a dependency ([facebook/react-native@6b129d8](https://github.com/facebook/react-native/commit/6b129d81ed8cab301775d2a04971e255df9290de)).
|
||||
|
||||
### Added
|
||||
|
||||
- Add flex yoga bindings of `gap`, `column-gap` and `row-gap` ([9f3a3e13cc](https://github.com/facebook/react-native/commit/9f3a3e13cc7e083dc0151b6037fc483dbfeaeabc) by [@intergalacticspacehighway](https://github.com/intergalacticspacehighway))
|
||||
- Add back deprecated PropTypes ([b966d29724](https://github.com/facebook/react-native/commit/b966d297245a4c1e2c744cfe571396cfa7e5ffd3) by [@rickhanlonii](https://github.com/rickhanlonii))
|
||||
- Make the `prepare_package_for_release` fail if there is already a git tag with that version ([850f855eb6](https://github.com/facebook/react-native/commit/850f855eb67edfbf777b4bf89f8b6e8e884b853e) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Add a C++ only TurboModule example (for Android/iOS/macOS/Windows) ([d07575b1c6](https://github.com/facebook/react-native/commit/d07575b1c63c214f74fd72b329892c7cfde5df69) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
- Enable platform-specific Codegen Specs ([ab7b4d4cd8](https://github.com/facebook/react-native/commit/ab7b4d4cd89cf6a7cb76d2b6a60163919cc3c689) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Add "option" to available role values ([e3e635ef84](https://github.com/facebook/react-native/commit/e3e635ef84156a5283d378858f7c8deb44464fea) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Added support `Promise.any` ([475310dbba](https://github.com/facebook/react-native/commit/475310dbbaec8048411edefc6cdddab330df7966) by [@retyui](https://github.com/retyui))
|
||||
- Log Abnormal Closes to Metro Websocket ([3982a2c6bd](https://github.com/facebook/react-native/commit/3982a2c6bd116a6dcc6ee6889e4a246b710b70a7) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- `BlobModule` to `RCTCoreModulesClassProvider` ([279cfec55f](https://github.com/facebook/react-native/commit/279cfec55fdf404fdb9198edbb37d3adfdfb3bf1) by [@andrestone](https://github.com/andrestone))
|
||||
- Added `mixed` value for `aria-checked`. ([7a19af7fb6](https://github.com/facebook/react-native/commit/7a19af7fb6b3b62fbbd632c6569a4270c604fb86) by [@ankit-tailor](https://github.com/ankit-tailor))
|
||||
- Concurrent rendering safe implementation of ScrollViewStickyHeader ([925e81ab86](https://github.com/facebook/react-native/commit/925e81ab86c9807b66d405d914e857b978b194fd) by [@sammy-SC](https://github.com/sammy-SC))
|
||||
- Add DevToolsSettingsManager ([0fac9817df](https://github.com/facebook/react-native/commit/0fac9817df403e31d8256befe52409c948614706) by [@rbalicki2](https://github.com/rbalicki2))
|
||||
- Add enum example to Android/iOS rn-tester TurboModule ([02e4fcd825](https://github.com/facebook/react-native/commit/02e4fcd825fecc78ce2c93a1e3a9ba2b232c573b) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
- React-native-codegen: add Enum Type support for iOS/Android TurboModules ([745f3ee8c5](https://github.com/facebook/react-native/commit/745f3ee8c571560406629bc7af3cf4914ef1b211) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
- Parser interface to divide parser logic. ([5940d25cc1](https://github.com/facebook/react-native/commit/5940d25cc184241ed77aca85c62f4ee071210d9b) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Add role prop to Text component ([20718e6b8c](https://github.com/facebook/react-native/commit/20718e6b8ce4f5c3a8393067d5e8eb0da910751c) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Introduce `useAnimatedValue` hook to make it easier working with `Animated.Value`s in function components. ([e22217fe8b](https://github.com/facebook/react-native/commit/e22217fe8b9455e32695f88ca835e11442b0a937) by [@fabriziocucci](https://github.com/fabriziocucci))
|
||||
- Highlight elements on hover while mouse down for React DevTools element inspection. ([94429fb037](https://github.com/facebook/react-native/commit/94429fb037322652b6796ac2c40cef451795205e))
|
||||
- Implement method bindings for gap/row-gap/column-gap ([803a2978e5](https://github.com/facebook/react-native/commit/803a2978e5c0a33c6bb57b402a67218571382fbb) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Implement gap/row-gap/column-gap (within the C ABI) ([1373a7057b](https://github.com/facebook/react-native/commit/1373a7057b9d66830868832a9684ad80ae5d9d45) by [@NickGerleman](https://github.com/NickGerleman) and [@jacobp100](https://github.com/jacobp100))
|
||||
- Add destructuredArrayIgnorePattern to eslint config ([0c5ef573fe](https://github.com/facebook/react-native/commit/0c5ef573fed31698ff8906675ddfc12a35829723) by [@fwcd](https://github.com/fwcd))
|
||||
- Add aria-modal prop to basic component ([f353119113](https://github.com/facebook/react-native/commit/f353119113d6fc85491765ba1e90ac83cb00fd61) by [@dakshbhardwaj](https://github.com/dakshbhardwaj))
|
||||
- Add support for ImageSource and ImageRequest in the State. ([d7c41361dd](https://github.com/facebook/react-native/commit/d7c41361dd87930044473434aba6e63b63811bdb) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Generate custom Native State ([7490ad4a21](https://github.com/facebook/react-native/commit/7490ad4a213aa75bfff205b57733cc71c79ca62c) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Add support for platform-specific specs ([7680bdeb4f](https://github.com/facebook/react-native/commit/7680bdeb4f96a8092393372a59c77a9d7b729cae) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Added suppression for warnings about unused parameters in 'publish<Type E>()' func ([c1363984f1](https://github.com/facebook/react-native/commit/c1363984f1a418cb1be59d927895a69be7b9ed1e) by [@inobelar](https://github.com/inobelar))
|
||||
- Export YGInteropSetLogger method ([d9a5c66baa](https://github.com/facebook/react-native/commit/d9a5c66baac824923f373d52017067738654277a) by [@KimDaeWook](https://github.com/KimDaeWook))
|
||||
- Add instructions about how to add tests in the OSS ([75b688fba8](https://github.com/facebook/react-native/commit/75b688fba8335598c19b9333459b6939dcf0a32c) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Add YGGutter Enum ([87e7912b95](https://github.com/facebook/react-native/commit/87e7912b9580ea8c9229cd77c36cb1d653972722) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Add string support for aspectRatio ([14c91cdf59](https://github.com/facebook/react-native/commit/14c91cdf59949959dd2e39af4fed5bee01c3cba1) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Add alt prop to Image component ([71fda5e0c2](https://github.com/facebook/react-native/commit/71fda5e0c2093380d08761c945f1e3029af6697f) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Include `this.state.bottom` when calculating new keyboard height to fix android keyboard switching ([f85e2ecc40](https://github.com/facebook/react-native/commit/f85e2ecc4079a99b59f706254c5671f186b9c6f6) by [@pfulop](https://github.com/pfulop))
|
||||
- Implement custom Native State parsing in TypeScript ([bbb2fb212d](https://github.com/facebook/react-native/commit/bbb2fb212d112b9b96b9b47df5bc22074f24f7da) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Implement custom Native State parsing in Flow ([925b15351f](https://github.com/facebook/react-native/commit/925b15351f4a1c8a4e305b36fe7ab56e68a657bb) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Add string support to the transform property ([34db2d4e93](https://github.com/facebook/react-native/commit/34db2d4e939cab4c37e5a8e6ec95800cce227c98) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Add `types` folder to house TypeScript types. ([6b2a511cbb](https://github.com/facebook/react-native/commit/6b2a511cbb1f244133624e37e7b3215d8fed33af))
|
||||
- Add additional Systrace support ([9cb716ff76](https://github.com/facebook/react-native/commit/9cb716ff76e45583999b040be8a99b00f0e022e1) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
- Add space-separated string support for fontVariant ([09d420707f](https://github.com/facebook/react-native/commit/09d420707f586710bb0f00981aca989b00f8761a) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Add aria-modal prop to basic component ([095f19a681](https://github.com/facebook/react-native/commit/095f19a681e22bd5f9438758112cc9628499b631) by [@dakshbhardwaj](https://github.com/dakshbhardwaj))
|
||||
- Added support for number values in fontWeight. ([f1c1f8116b](https://github.com/facebook/react-native/commit/f1c1f8116ba1cfa9d10c5b8c30b98b796047b9c2) by [@ankit-tailor](https://github.com/ankit-tailor))
|
||||
- Add `aria-label` prop to `Button`, `View`, `Pressable` component ([720cdbc658](https://github.com/facebook/react-native/commit/720cdbc658aa0b513d106526eb81d749fa957c99) by [@Viraj-10](https://github.com/Viraj-10))
|
||||
- Add `aria-valuemax`, `aria-valuemin`, `aria-valuenow`, `aria-valuetext` as alias prop to `TouchableOpacity`, `View`, `Pressable` `TouchableHighlight` `TouchableBounce` `TouchableWithoutFeedback` `TouchableOpacity` components ([e8739e962d](https://github.com/facebook/react-native/commit/e8739e962de3398bc7e42675b1d87ab35993f705) by [@dakshbhardwaj](https://github.com/dakshbhardwaj))
|
||||
- Add support for objectFit style of Image. ([b2452ab216](https://github.com/facebook/react-native/commit/b2452ab216e28e004dc625dd8e1ad32351a79be9) by [@gedeagas](https://github.com/gedeagas))
|
||||
- Added aria-live alias for accessibilityLiveRegion. ([7ea54a4087](https://github.com/facebook/react-native/commit/7ea54a408734ccde9ee01a12942bf5722e9cf7c1) by [@mayank-96](https://github.com/mayank-96))
|
||||
- Add aria-disabled, aria-busy, aria-checked, aria-expanded and aria-selected prop to core components ([98d84e571d](https://github.com/facebook/react-native/commit/98d84e571df64b00e1ed3484923a1d8169dcfda1) by [@ankit-tailor](https://github.com/ankit-tailor))
|
||||
- Add support for `userSelect` style ([fc42d5bbb9](https://github.com/facebook/react-native/commit/fc42d5bbb9906c37c2f62d26c46f6e3191cccd01) by [@dakshbhardwaj](https://github.com/dakshbhardwaj))
|
||||
- Added a check to if `scrollEnabled` is not false, if so then fire the `VirtualizedList` error ([62f83a9fad](https://github.com/facebook/react-native/commit/62f83a9fad027ef0ed808f7e34973bb01cdf10e9))
|
||||
- Add proper support for fractional scrollIndex in VirtualizedList ([f44dfef923](https://github.com/facebook/react-native/commit/f44dfef923b887308300cee9ae5a55269414c45a) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Add expanded support for CSS Colors ([ac1fe3b7eb](https://github.com/facebook/react-native/commit/ac1fe3b7eb8e16f5feddeeac846ff70080dc119e) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Add aria-hidden prop to Pressable, View and Touchables components ([ebdb23c6e0](https://github.com/facebook/react-native/commit/ebdb23c6e060897112b060c25172135d50c78cd3) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Added role alias for accessibilityRole. ([a50e6fb341](https://github.com/facebook/react-native/commit/a50e6fb341eacd955071e4a7c6d734e7d3c94cd7) by [@madhav23bansal](https://github.com/madhav23bansal))
|
||||
- Added pointerEvents style equivalent to pointerEvents prop ([5c109b37a4](https://github.com/facebook/react-native/commit/5c109b37a42d16b35d8ddf2371d42d47f4d49fb2) by [@cyrus25](https://github.com/cyrus25))
|
||||
- Added an overlay similar to Inspector.js that allows directly selecting elements on RN from React DevTools ([c52df02f84](https://github.com/facebook/react-native/commit/c52df02f84f123a524259eac554f4d2407f1904c) by [@tyao1](https://github.com/tyao1))
|
||||
- Add tintColor prop to Image component ([7a6f0e44b2](https://github.com/facebook/react-native/commit/7a6f0e44b26b7a6eddb25d5e05948a1992a1629e) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Make babel-plugin-codegen work for TypeScript Spec files ([df0b6900ec](https://github.com/facebook/react-native/commit/df0b6900eca873417c867483b719e8e892a4b75d) by [@RSNara](https://github.com/RSNara))
|
||||
- Add inputMode prop to TextInput component ([9fac88574e](https://github.com/facebook/react-native/commit/9fac88574e2f8c2f46b7f081273845f833fe1b75) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- React-native-codegen: Add Enum Type support for C++ TurboModules ([b444f0e44e](https://github.com/facebook/react-native/commit/b444f0e44e0d8670139acea5f14c2de32c5e2ddc) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
- Add enterKeyHint prop to TextInput component ([8c882b4f3d](https://github.com/facebook/react-native/commit/8c882b4f3d361be715c8ec2793c545c687711b5e) by [@dakshbhardwaj](https://github.com/dakshbhardwaj))
|
||||
- React-native-codegen: Add Union Type support for C++ TurboModules ([355feafff6](https://github.com/facebook/react-native/commit/355feafff6129129533c939e707fadb5fc747c08) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
- Add readOnly prop to TextInput component ([de75a7a22e](https://github.com/facebook/react-native/commit/de75a7a22eebbe6b7106377bdd697a2d779b91b0) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Added ability to construct ArrayBuffers from existing memory buffers. ([3bae268782](https://github.com/facebook/react-native/commit/3bae268782c318b7f8bd6442682d3d683696eedf) by [@neildhar](https://github.com/neildhar))
|
||||
- Add ability to store and retrieve a list of MapBuffer ([fc065151ce](https://github.com/facebook/react-native/commit/fc065151ce3b2aa53d9f9b78a950d1c3dbce3c75) by [@sshic](https://github.com/sshic))
|
||||
- SyncCallback/AsyncCallback/AsyncPromise bridging types in C++ now allow wrapping JSI types. ([610bb7f688](https://github.com/facebook/react-native/commit/610bb7f68844df150503623297304dbb67984bfe) by [@nlutsenko](https://github.com/nlutsenko))
|
||||
- Add types for onFocusCapture/onBlurCapture ([aabb5df7ec](https://github.com/facebook/react-native/commit/aabb5df7ec884b7e08b8b8bef658727653406fd9) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Add `returnKeyAction` prop to `TextInput` component and remove usages of `blurOnSubmit` in native code and convert `blurOnSubmit` to `returnKeyAction` in the JavaScript conversion layer ([1e3cb91707](https://github.com/facebook/react-native/commit/1e3cb9170794afa03a3b4b15f75b711dace7a774))
|
||||
- Re-add support for using Yoga without exceptions ([793ebf6812](https://github.com/facebook/react-native/commit/793ebf6812f41ad9b07fe04d43a8509a55ebe45e) by [@Yannic](https://github.com/Yannic))
|
||||
|
||||
#### Android specific
|
||||
|
||||
- Added Flavor Support to React Native Gradle Plugin (RNGP) ([8ad86c70b6](https://github.com/facebook/react-native/commit/8ad86c70b6341f2e8bd40f5ba86f1a0d451008b0) by [@cortinico](https://github.com/cortinico))
|
||||
- Add ComponentWithState in Android ([b24f60f729](https://github.com/facebook/react-native/commit/b24f60f729bb3d4804f123eb38ed512f2bfc8cf9) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Add support for verticalAlign style ([32b6f319ba](https://github.com/facebook/react-native/commit/32b6f319bafbd6bc2fdab458d38f2d83b0514ad2) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Add tabIndex prop to View component ([621f4cf3b1](https://github.com/facebook/react-native/commit/621f4cf3b12979b62d2e1d49d63eaf85e0707026) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Add rows prop to TextInput component ([49c9ccd3f8](https://github.com/facebook/react-native/commit/49c9ccd3f8150c5478b502cd5ee158f44750a549) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Stop special-casing Android 11+ from large form-factor `keyboardShouldPersistTaps` behavior ([ef77a4218d](https://github.com/facebook/react-native/commit/ef77a4218db5bafd45ac844cd06e33e229ea534a) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Provide defaults for TurboModuleManagerDelegate and JSIModulePackage ([9a2eb9089f](https://github.com/facebook/react-native/commit/9a2eb9089f0854502b4b03cf4f74426c23b3f4e8) by [@cortinico](https://github.com/cortinico))
|
||||
- Expose UI_MODE_TYPE_VR_HEADSET in PlatformConstants ([77c256ca91](https://github.com/facebook/react-native/commit/77c256ca9115b8fd23a0e3fa43e12033cac3d634) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Expose `globalEvalWithSourceUrl` in production builds. ([333583bfbe](https://github.com/facebook/react-native/commit/333583bfbe7e3fbf6a6ebd0645019313ade86bea) by [@EvanBacon](https://github.com/EvanBacon))
|
||||
- Accessibility announcement for list and grid in FlatList ([463af23753](https://github.com/facebook/react-native/commit/463af237539b98289c88e5b491c85cbf53bcaf0c) by [@fabriziobertoglio1987](https://github.com/fabriziobertoglio1987))
|
||||
- Improve OSS systrace ([ccbfdd7167](https://github.com/facebook/react-native/commit/ccbfdd71670a958916c15e8e8e3c5fb94becbe22) by [@janicduplessis](https://github.com/janicduplessis))
|
||||
- Un-deprecate DisplayMetrics.getWindowDisplayMetrics() method ([4cbd263173](https://github.com/facebook/react-native/commit/4cbd263173b992c0a0dc7c640e39794f39ce1b34) by [@mdvacca](https://github.com/mdvacca))
|
||||
|
||||
#### iOS specific
|
||||
|
||||
- Bring back JSIDynamic and JSI ([3d7b53d456](https://github.com/facebook/react-native/commit/3d7b53d456f909029d4d470342419c191565b3e1) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Add Dynamic Type support for iOS (Paper and Fabric) ([11c8bf3137](https://github.com/facebook/react-native/commit/11c8bf313717a8c46165d48caba5e70b9f160d05))
|
||||
- Add support for parsing files w/ `:` in filename ([714b22bb43](https://github.com/facebook/react-native/commit/714b22bb431a7384a6e06141d5b3f367de2f75cd) by [@shwanton](https://github.com/shwanton))
|
||||
- Download Hermes from Maven while for -stables ([44e8462a03](https://github.com/facebook/react-native/commit/44e8462a036b8217344f56310719b13d4a551973) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- `anchor` option support for `Share` ([aeab38357f](https://github.com/facebook/react-native/commit/aeab38357ffdb0ca266da00748ae2651ca812a1a) by [@zhumingcheng697](https://github.com/zhumingcheng697))
|
||||
- Line break strategy for Text and TextInput components ([048194849b](https://github.com/facebook/react-native/commit/048194849bda980eecf7bb006ca4e71e2d60ff4c) by [@bang9](https://github.com/bang9))
|
||||
- Add more extension points for RCTAppDelegate ([dd607a8f2d](https://github.com/facebook/react-native/commit/dd607a8f2d337c01ebe0ff114263fe95b4498364) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Introduce sample component which work with the native state. ([1a9cceb20b](https://github.com/facebook/react-native/commit/1a9cceb20b25416eeb90b68c85daa6608cf5deef) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Add new APIs to `react_native_pods.rb` to simplify app migration ([34fafb2b88](https://github.com/facebook/react-native/commit/34fafb2b881751cdd998d7d5ef486d536607c9ce) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Test iOS template with both architectures and configurations ([4352459781](https://github.com/facebook/react-native/commit/435245978122d34a78014600562517c3bf96f92e) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Add new fontVariant values: stylistic-one(ss01) -> stylistic-twenty(ss20) ([163636db75](https://github.com/facebook/react-native/commit/163636db752b9a5544de54b256e264d3877bb6f7))
|
||||
- Added the RCTAppDelegate library ([7cc2d1a249](https://github.com/facebook/react-native/commit/7cc2d1a24983d00282fcc694986faad88991845e) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Support setting an Alert button as "preferred", to emphasize it without needing to set it as a "cancel" button. ([000bbe8013](https://github.com/facebook/react-native/commit/000bbe8013ec72d20f969c5c3a1f655b3f20c6ba) by [@robbie-c](https://github.com/robbie-c))
|
||||
- Added `borderCurve` style prop for smooth border radius (squircle effect) ([8993ffc82e](https://github.com/facebook/react-native/commit/8993ffc82e8d4010d82dcb1d69c33a609bb2771a) by [@eric-edouard](https://github.com/eric-edouard))
|
||||
- Automatically detect when use frameworks is used ([f7b35c0d43](https://github.com/facebook/react-native/commit/f7b35c0d434a5e98228311722926819ffe80c4b6) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Add compiler flag for the new Arch when enabled. ([5b32348add](https://github.com/facebook/react-native/commit/5b32348add5dbb8e348c4e37d12e7ce01496d87e) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Improve Codegen Cleanup ([aaa795b](https://github.com/facebook/react-native/commit/aaa795bcaec5265a9b0404333934d1115d148db8) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
|
||||
### Changed
|
||||
|
||||
- Bump CLI to 10.0.0 and Metro to 0.73.5 ([e1bca8f98c](https://github.com/facebook/react-native/commit/e1bca8f98c9d2f86cbd0de61e45728c59d548ba3) by [@thymikee](https://github.com/thymikee))
|
||||
- Upgrade to `deprecated-react-native-prop-types` 3.0.1: [changelog](https://github.com/facebook/react-native-deprecated-modules/blob/main/deprecated-react-native-prop-types/CHANGELOG.md) ([3e91415696](https://github.com/facebook/react-native/commit/3e91415696a77e5106cc9cd58077632fdf534b37) by [@yungsters](https://github.com/yungsters))
|
||||
- Upgrade Jest in React Native to ^29.2.1 ([45db65be7e](https://github.com/facebook/react-native/commit/45db65be7e8745a731093f43030965afa7581751) by [@robhogan](https://github.com/robhogan)), ([8f337538ae](https://github.com/facebook/react-native/commit/8f337538ae86b43f524044db3a7363c12e93d7d9) by [@kelset](https://github.com/kelset))
|
||||
- Bump `@react-native/normalize-color` to 2.1.0, `@react-native-community/eslint-plugin` to 1.3.0, `@react-native/babel-plugin-codegen` to 0.71.1, `@react-native-community/eslint-config` to 3.2.0 and `@react-native-community/eslint-plugin-specs` to 1.3.0, ([8183aac0b1](https://github.com/facebook/react-native/commit/8183aac0b1f55db8fd5d45d4fc6a8e596e3db32b))
|
||||
- Upgraded react-devtools-core dependency to 4.26.1 ([48263b8daf](https://github.com/facebook/react-native/commit/48263b8daf02fdea6eafa95e7fa80f161474fa54))
|
||||
- Bump `react-native-codegen` to `^0.71.3` and `react-native-gradle-plugin` to `0.71.12"` ([a7792da695](https://github.com/facebook/react-native/commit/a7792da695f77be8d46b5e84ab697631b884db91) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Bump Hermes for 0.71 version ([4e5fc68672](https://github.com/facebook/react-native/commit/4e5fc68672b469f7a3548822d6fca0b7b3f2d51e) by [@kelset](https://github.com/kelset))
|
||||
- Simplify Template ESLint Configuration ([68d6214a18](https://github.com/facebook/react-native/commit/68d6214a18b4d8272abddc2303b6b407b0defd7b) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Use `'react-native'` export conditions in Jest environment ([0376aa4856](https://github.com/facebook/react-native/commit/0376aa4856fb5141e89994873e4d80a1f597e0cb) by [@SimenB](https://github.com/SimenB))
|
||||
- Move JSCRuntime into a separate pod/prefab ([f3bf4d02ab](https://github.com/facebook/react-native/commit/f3bf4d02abf8d22bada8bfcee7ccfbd3bb524750) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Improve version checks ([f12b12c999](https://github.com/facebook/react-native/commit/f12b12c999fb36e66bcef242f7cf1f0751afedcd) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Read `.ruby-version` file in `Gemfile` ([cb7f1b1f0b](https://github.com/facebook/react-native/commit/cb7f1b1f0b9d50ae8a923043d0ed77b2171bf59f) by [@dcangulo](https://github.com/dcangulo))
|
||||
- Remove React Native version from Hermes tarball name ([e36c492ace](https://github.com/facebook/react-native/commit/e36c492ace5d3171dd64186b5f2024fbae37df36) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- RNTester: Migrate Dimensions to hooks ([745e26288c](https://github.com/facebook/react-native/commit/745e26288c656237b0f86f6cfc55643eeb0817ca) by [@Marcoo09](https://github.com/Marcoo09))
|
||||
- Do not filter errors/warnings from console ([fa2842d113](https://github.com/facebook/react-native/commit/fa2842d113f04c8d33d2f71f43d4232e470b77ac) by [@rickhanlonii](https://github.com/rickhanlonii))
|
||||
- RNTester: Migrate ActivityIndicator to hooks ([c868d5b26c](https://github.com/facebook/react-native/commit/c868d5b26c5d680603d3f653de9277124c1b539b) by [@Marcoo09](https://github.com/Marcoo09))
|
||||
- Refactor codegen: Dispatch props and events from a central place. ([affcfa7bde](https://github.com/facebook/react-native/commit/affcfa7bde9740c34cc025741d1e63423183e500) by [@ZihanChen-MSFT](https://github.com/ZihanChen-MSFT))
|
||||
- Add "EarlyJsError: " as prefix of early js error's message ([be6f65660f](https://github.com/facebook/react-native/commit/be6f65660f9c5b56795079b00f6d7eecade5a22f))
|
||||
- Move Jest config to use a custom react-native Jest env ([cb2dcd327c](https://github.com/facebook/react-native/commit/cb2dcd327c62edae58bb8571273add4c286fd2a8) by [@kelset](https://github.com/kelset))
|
||||
- Add Metro health check files to the template's `.gitignore` ([19715cf4fb](https://github.com/facebook/react-native/commit/19715cf4fb11640d07b973a3eb0e918ee27691ac) by [@motiz88](https://github.com/motiz88))
|
||||
- Ship VirtualizedList_EXPERIMENTAL ([971599317b](https://github.com/facebook/react-native/commit/971599317b7bdf1152157206f9503a23ac8c4162) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Typescript: update incorrect `SwitchChangeEvent` type ([5dd2f2e4b7](https://github.com/facebook/react-native/commit/5dd2f2e4b7669397f8bfa9b3845afee7e4e47626) by [@retyui](https://github.com/retyui))
|
||||
- Make `yarn` and `yarn jest react-native-codegen` works on Windows with git ([c4f9556f7e](https://github.com/facebook/react-native/commit/c4f9556f7e98454e2061ca7e121099ebbbddd4c9) by [@ZihanChen-MSFT](https://github.com/ZihanChen-MSFT))
|
||||
- Refactor in turbo module TypeScript codegen: process `(T)`, `T|U`, `T|undefined` and related stuff in a central place ([00b795642a](https://github.com/facebook/react-native/commit/00b795642a6562fb52d6df12e367b84674994623) by [@ZihanChen-MSFT](https://github.com/ZihanChen-MSFT))
|
||||
- Move and rename `hermes-inspector-msggen` to `react-native/hermes-inspector-msggen` ([530dae8a45](https://github.com/facebook/react-native/commit/530dae8a45a600ef67d01e76edd68824c4e610dd) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Fix interface support in turbo module TypeScript codegen (component only) ([8dc6bec719](https://github.com/facebook/react-native/commit/8dc6bec719eefcb289bb0306c8686afd34835938) by [@ZihanChen-MSFT](https://github.com/ZihanChen-MSFT))
|
||||
- Place TS Declarations Alongside Source Files ([8cdc9e7f04](https://github.com/facebook/react-native/commit/8cdc9e7f04e2dd3026d15dcd5765952bfb2c5c08) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Handle (T) and undefined properly in turbo module component codegen ([205cc9bc3b](https://github.com/facebook/react-native/commit/205cc9bc3b56d21a6ee21a97c1d171d22b6c79c3) by [@ZihanChen-MSFT](https://github.com/ZihanChen-MSFT))
|
||||
- Update `Clipboard` mock path ([2aba3522ab](https://github.com/facebook/react-native/commit/2aba3522ab7dfe113ec26131b747f7f6f0486194) by [@adrianha](https://github.com/adrianha))
|
||||
- Fix ImageLoader.getSize jest mock ([7be829f2c9](https://github.com/facebook/react-native/commit/7be829f2c9756f8973401644579dd2910b5d3209) by [@elliottkember](https://github.com/elliottkember))
|
||||
- Correct execution context ID in Debugger.scriptParsed event. ([545366aea3](https://github.com/facebook/react-native/commit/545366aea30c3db6cb28c77ce85208e9973cc1fb) by [@aeulitz](https://github.com/aeulitz))
|
||||
- Don't polyfill Promise in Jest setup ([f1fdc8b9b6](https://github.com/facebook/react-native/commit/f1fdc8b9b636e010ae5d5e737fc81a8da8f536d4) by [@robhogan](https://github.com/robhogan))
|
||||
- Codegen: support TypeScript type `(T)` for turbo module codegen (module only) ([624bdc7ec6](https://github.com/facebook/react-native/commit/624bdc7ec63fc10915236653185bb1a705c8460f) by [@ZihanChen-MSFT](https://github.com/ZihanChen-MSFT))
|
||||
- Unify TextInput autoComplete and textContentType props ([73abcba40f](https://github.com/facebook/react-native/commit/73abcba40f305634efaafea8969cdfeb4982df0e) by [@gabrieldonadel](https://github.com/gabrieldonadel))
|
||||
- Added `crossOrigin`, `referrerPolicy`, `width`, `height` and `srcSet` props to Image Component. ([47a05bc26a](https://github.com/facebook/react-native/commit/47a05bc26ab76add640183c1d9d8cbba39d7d0d2) by [@dhruvtailor7](https://github.com/dhruvtailor7))
|
||||
- Copied and refactored the current devtools highlighting code from Inspector into its own module and add to the top level `AppContainer`. The effect is that the highlight stills shows without Inspector opened. ([a63204800a](https://github.com/facebook/react-native/commit/a63204800a1aa23eb050b8f276be70f75057d1da) by [@tyao1](https://github.com/tyao1))
|
||||
- Minor change to PropTypes error message. ([7783f88d71](https://github.com/facebook/react-native/commit/7783f88d7160e9474164545309590c7f95f7f17f) by [@yungsters](https://github.com/yungsters))
|
||||
- Set back the `DANGER_GITHUB_API_TOKEN`. ([9344c7aa5a](https://github.com/facebook/react-native/commit/9344c7aa5a7845b250834c4c6a7d8d733be2d143) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Run ESLint in CI ([1bba59023d](https://github.com/facebook/react-native/commit/1bba59023d4976cb349bb58e66ae5b5b5a5288ed) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- `eslint-plugin-specs` package has prepack hook that changes `PACKAGE_USAGE` variable of `react-native-modules.js` to `true`. ([ee9c1a5260](https://github.com/facebook/react-native/commit/ee9c1a5260b6a50c952c415c39c9af45ba49f01e) by [@dmytrorykun](https://github.com/dmytrorykun))
|
||||
- Attach the `.hermes-cache-key-file` to the workspace to avoid race conditions for new PR landing on Hermes and changing the head commit between the time Hermes is built and the time it has to be consumed. ([ccdf9ac985](https://github.com/facebook/react-native/commit/ccdf9ac9853601a81ff21f8f42f5bd866dd4de75) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Build hermes when in CI and not when there is a tarball ([4b51207735](https://github.com/facebook/react-native/commit/4b512077354eb4702ce144e9958d7513c1607275) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Make sure we can build Hermes from source when PR are opened agains -stable ([361d939afd](https://github.com/facebook/react-native/commit/361d939afd0b43b2e9e6ea0d4c619482e91e82e3) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Update ktfmt component on FBS:master ([47548c1149](https://github.com/facebook/react-native/commit/47548c114993433ba03f32398876c1e11aeac0d3) by [@cgrushko](https://github.com/cgrushko))
|
||||
- Add explicit React useState annotations in xplat/js ([ff14ff3d92](https://github.com/facebook/react-native/commit/ff14ff3d92b2c32f851ee8d25d8e8ea6dfe2ec9e) by [@pieterv](https://github.com/pieterv))
|
||||
- Improve sample app ([03cb5aca3f](https://github.com/facebook/react-native/commit/03cb5aca3f5b8594287608265d4bde7104f07b87) by [@pieterv](https://github.com/pieterv))
|
||||
- Mirror fbcode directory structure for container targets ([10ea6fb9a3](https://github.com/facebook/react-native/commit/10ea6fb9a3f408bc23881235427427c3b9e97149))
|
||||
- Update ktfmt component on FBS:master ([0538f45e45](https://github.com/facebook/react-native/commit/0538f45e45acf494fdafda0757c090a60e730746) by [@cgrushko](https://github.com/cgrushko))
|
||||
- Rewrite CompactValue to avoid undefined behavior from the use of a union for type-punning ([e7a8d21df5](https://github.com/facebook/react-native/commit/e7a8d21df563e48e1812caace7fbe1f7cbc1c015) by [@htpiv](https://github.com/htpiv))
|
||||
|
||||
#### Android specific
|
||||
|
||||
- Bump AGP to 7.3.1 ([1f42ff0815](https://github.com/facebook/react-native/commit/1f42ff0815dbf9436904c4a5b1e6975854654172) by [@cortinico](https://github.com/cortinico))
|
||||
- Bump Android compile and target SDK to 33 ([394486eec5](https://github.com/facebook/react-native/commit/394486eec584a37920dad447a6c1d0ae24d225fc) by [@makovkastar](https://github.com/makovkastar))
|
||||
- Bump Soloader to 0.10.4 ([1237952d07](https://github.com/facebook/react-native/commit/1237952d070bfe28ff2c94cd9bf8ea19e6cdd395) by [@simpleton](https://github.com/simpleton))
|
||||
- Rename `POST_NOTIFICATION` to `POST_NOTIFICATIONS` ([910a750fbc](https://github.com/facebook/react-native/commit/910a750fbce42808350312dee1f5671e5d3e05b1) by [@dcangulo](https://github.com/dcangulo))
|
||||
- Void the Maven coordinates for react-native and hermes-engine ([55b1670aa6](https://github.com/facebook/react-native/commit/55b1670aa6c34f31491ffeba05997f131aae31e7) by [@cortinico](https://github.com/cortinico))
|
||||
- Provide easy registration of C++ TurboModules in rn-tester Android ([9cb02613e6](https://github.com/facebook/react-native/commit/9cb02613e6c2dfa7847b2f6356d91efe9a4a02f1) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
- Add feature flag enableAtomicRegisterSegment ([f207cfddf3](https://github.com/facebook/react-native/commit/f207cfddf37c01b5ff2c2f53b4d44a4cc7ad2484))
|
||||
- Update the template to load the correct JS engine at runtime ([2097278d2a](https://github.com/facebook/react-native/commit/2097278d2a91218274cb661ebf37cc8dbb78bf25) by [@cortinico](https://github.com/cortinico))
|
||||
- Do not import/use the deprecated ReactFlipperPlugin ([07252b81f6](https://github.com/facebook/react-native/commit/07252b81f6d13729dc08ac1444bad6581d852ddd) by [@cortinico](https://github.com/cortinico))
|
||||
- Update the template to use RNGP ([c96c76eb91](https://github.com/facebook/react-native/commit/c96c76eb9107ea92ff6dc2dcec114f3bd57102bd) by [@cortinico](https://github.com/cortinico))
|
||||
- Let RNGP set buildConfigFields for New Architecture and Hermes ([7d2f48c97d](https://github.com/facebook/react-native/commit/7d2f48c97d0dce602fc7fa06546060f4aa3aef17) by [@cortinico](https://github.com/cortinico))
|
||||
- Hide the C++/Cmake configuration from user space inside the framework ([c9e6a6056d](https://github.com/facebook/react-native/commit/c9e6a6056d9ee24c70826e598ba7219da25ae10d) by [@cortinico](https://github.com/cortinico))
|
||||
- Encapsulate the prefab configuration for consumers ([b39e77b3d7](https://github.com/facebook/react-native/commit/b39e77b3d725d7fa88abfb0a50780677d7ef7050) by [@cortinico](https://github.com/cortinico))
|
||||
- Cleanup the Android template after prefab support ([0b4417b43f](https://github.com/facebook/react-native/commit/0b4417b43f66e3de91e9d54099440be14d97434b) by [@cortinico](https://github.com/cortinico))
|
||||
- Simplify Accessibility Heading role implementation. ([353b1b0f8b](https://github.com/facebook/react-native/commit/353b1b0f8b1ca67efb553738f601552bd9ed897f) by [@blavalla](https://github.com/blavalla))
|
||||
- Update the OnLoad.cpp to use the facebook::react namespace ([aba82a503d](https://github.com/facebook/react-native/commit/aba82a503d39e7a341630aabdcf02762e392dbea) by [@cortinico](https://github.com/cortinico))
|
||||
- Remove internal buck rule arg for robolectric tests ([59dc7f1b20](https://github.com/facebook/react-native/commit/59dc7f1b2094063debd4d14957b48fd6ed0e9511))
|
||||
- Further simplify the New App Template by don't requiring the dynamic library name ([59ae0487ce](https://github.com/facebook/react-native/commit/59ae0487ce05333ba5df6d2244f7eca7ecf82625) by [@cortinico](https://github.com/cortinico))
|
||||
- Update the template to Reduce the amount of C++ code in user space for New Architecture ([b0aba1b6fa](https://github.com/facebook/react-native/commit/b0aba1b6fa7c3b0d43548371d8b9707d6a7da3b6) by [@cortinico](https://github.com/cortinico))
|
||||
- Reduce the amount of C++ code in user space for New Architecture ([e89bd4a375](https://github.com/facebook/react-native/commit/e89bd4a3751f71e9d2ede49ae91d3bb9221a7c60) by [@cortinico](https://github.com/cortinico))
|
||||
- Move setRootViewTag to earlier when RootView is created ([4d642a2250](https://github.com/facebook/react-native/commit/4d642a2250251d90d4afec8e81bf19848217c3f6) by [@sshic](https://github.com/sshic))
|
||||
- Replace Folly with MapBuffer for passing js error data ([e874e5facb](https://github.com/facebook/react-native/commit/e874e5facb60ff7057c0c95ca53948540ddb7137) by [@sshic](https://github.com/sshic))
|
||||
- Simplify the template for New Architecture using the .defaults package ([33bd2f6eae](https://github.com/facebook/react-native/commit/33bd2f6eaed3c583f5df852535a8789f8caadbaa) by [@cortinico](https://github.com/cortinico))
|
||||
- Enable -Wpedantic in OSS Android Targets ([06b55a3d04](https://github.com/facebook/react-native/commit/06b55a3d044a9fbbcd97df6e6531cad98dd34ca1) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Do not load Flipper via reflection ([9214da1238](https://github.com/facebook/react-native/commit/9214da12385fd88264ca5de3e5fdc78559ec3080) by [@cortinico](https://github.com/cortinico))
|
||||
- Collapse catch blocks in template ([a379879adf](https://github.com/facebook/react-native/commit/a379879adf99800d22da8bc10c3a22f06cb02e20) by [@danilobuerger](https://github.com/danilobuerger))
|
||||
- Bump git checkout cache key (fourth time) ([41a80f2ee2](https://github.com/facebook/react-native/commit/41a80f2ee20f6e2e7d754d6cd3d47d4cd558c49a) by [@kelset](https://github.com/kelset))
|
||||
- Replace Toast with Log.w on ReactImageView when null URL specified ([30411ae1a4](https://github.com/facebook/react-native/commit/30411ae1a42e46d0e5a2da494a39ed2767ba8808))
|
||||
- Views with overflow: hidden and borderRadius: >0 now render anti-aliased borders. ([7708cdccef](https://github.com/facebook/react-native/commit/7708cdcceff9a268ae19c196c2b8baeadf4d9d83))
|
||||
- Expose react_render_animations via prefab. ([98ad3996c8](https://github.com/facebook/react-native/commit/98ad3996c8b144bf80e1d3f9e6a79ee11e5a2142) by [@cortinico](https://github.com/cortinico))
|
||||
- Remove unnecessary repositories{} block from top level build.gradle ([f65dfa86ab](https://github.com/facebook/react-native/commit/f65dfa86abcba829c0d65c11ef5c98f1033e2905) by [@cortinico](https://github.com/cortinico))
|
||||
- Fix prefab prefix for fabricjni ([621d901e10](https://github.com/facebook/react-native/commit/621d901e105d6160a297f8e371889ba2fb631ce2) by [@cortinico](https://github.com/cortinico))
|
||||
- De-bump AGP to 7.3.1 and do not use addGeneratedSourceDirectory ([caa79b7c01](https://github.com/facebook/react-native/commit/caa79b7c017accd91c0e852bd701ef3f21ac0e6d) by [@cortinico](https://github.com/cortinico))
|
||||
|
||||
#### iOS specific
|
||||
|
||||
- Fix imports in React Bridging for Old Arch and frameworks ([c5de1eb1ba](https://github.com/facebook/react-native/commit/c5de1eb1bac0a4e653688d86654be131984d0e2f) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Abort pod install if bad HERMES_ENGINE_TARBALL_PATH is set. ([27e7295ca7](https://github.com/facebook/react-native/commit/27e7295ca76111c00bcf83327b0a151f21c23743))
|
||||
- Hermes is integrated into Xcode build. ([6b8e13f53c](https://github.com/facebook/react-native/commit/6b8e13f53c5fc9c5e794bb7491648e4b25ad5811))
|
||||
- Display a RedBox with the JS stack (instead of native stack) when an unhandled JS exceptions occurs ([ff398e4e26](https://github.com/facebook/react-native/commit/ff398e4e2632ece8a6f22d744e96e489ca3b9d92) by [@p-sun](https://github.com/p-sun))
|
||||
- Resolve JSI ODR violation, make hermes-engine the JSI provider when Hermes is enabled ([a68c418082](https://github.com/facebook/react-native/commit/a68c4180822e13ae6eecf86601864d1e9f2825a9) by [@hramos](https://github.com/hramos))
|
||||
- The JSC Runtime is now provided by the React-jsc Pod instead of React-jsi. Libraries that declared a dependency on React-jsi in order to specifically create a JSC runtime (`makeJSCRuntime()`) will need to add React-jsc to their dependencies. ([6b129d81ed](https://github.com/facebook/react-native/commit/6b129d81ed8cab301775d2a04971e255df9290de) by [@hramos](https://github.com/hramos))
|
||||
- Moved JSIDynamic out of React-jsi and into React-jsidynamic ([0db5178688](https://github.com/facebook/react-native/commit/0db5178688d838689ece5cc246e4ec1ec7f2e607) by [@hramos](https://github.com/hramos))
|
||||
- Do not load Hermes inspector in release builds ([2a21d5a28e](https://github.com/facebook/react-native/commit/2a21d5a28ea0ee0a1a332ce26b50b7fd61ac89a7) by [@hramos](https://github.com/hramos))
|
||||
- Remove debugger from Hermes when building for release ([2fc44ac8e1](https://github.com/facebook/react-native/commit/2fc44ac8e144b7d93e1ccc95163dd33c94d2a197) by [@hramos](https://github.com/hramos))
|
||||
- Use debug Hermes builds by default ([ce4aa93173](https://github.com/facebook/react-native/commit/ce4aa9317370cbbf4e8c80c0a8db3db5a80ef70b) by [@hramos](https://github.com/hramos))
|
||||
- Add function to simplify podspecs ([82e9c6ad61](https://github.com/facebook/react-native/commit/82e9c6ad611f1fb816de056ff031716f8cb24b4e) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Enable pedantic warnings in C++ podspecs ([545c82b490](https://github.com/facebook/react-native/commit/545c82b490f1389056cf2f945a547a22b1274f60) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Cleanup codegen build folder before installing the pods ([0e316ec671](https://github.com/facebook/react-native/commit/0e316ec671617f5e7c1985b4b05cd0d45bcea403) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Properly support both libraries and use_frameworks ([c6fa633597](https://github.com/facebook/react-native/commit/c6fa6335971459158efc8bf094822547a4333235) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Add link group label to talkios deps ([b33961d7a0](https://github.com/facebook/react-native/commit/b33961d7a0fbf5783513a81b217ec1a90700d817))
|
||||
- Add link group label to fbios deps ([065db683a2](https://github.com/facebook/react-native/commit/065db683a20b273ea3656dead29845327637669a))
|
||||
- Use an SDKRoot based Foundation framework ([ee4ce2df2f](https://github.com/facebook/react-native/commit/ee4ce2df2f57b07e523bfb4d4728543d73b5a009) by [@chatura-atapattu](https://github.com/chatura-atapattu))
|
||||
|
||||
### Removed
|
||||
|
||||
- remove AsyncStorage from JS ([20eeb1bfe3](https://github.com/facebook/react-native/commit/20eeb1bfe30eacf26abd185b6fa062b708deaf8a) by [@hoxyq](https://github.com/hoxyq))
|
||||
- Remove VirtualizedList `listKey` prop ([010da67bef](https://github.com/facebook/react-native/commit/010da67bef0c22418d0d41b7c2eae664672a4a27) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Remove MaskedViewIOS ([a67360b0f3](https://github.com/facebook/react-native/commit/a67360b0f3aec0e679be32715b02467429002c31) by [@sokolnickim](https://github.com/sokolnickim))
|
||||
- Back out parsing and generation of Custom Native State from Codegen ([62da9b8ce2](https://github.com/facebook/react-native/commit/62da9b8ce2097c9037ee2c766c9d4cb64eae2930) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Back out components with native state in RNTester ([aace6626c1](https://github.com/facebook/react-native/commit/aace6626c10916c022c9960ac61d54b780edd230) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- `react-native/eslint-plugin` no longer provides the `error-subclass-name` rule. ([4f83498462](https://github.com/facebook/react-native/commit/4f83498462133b4c5b9e89836c52482ef7098427) by [@yungsters](https://github.com/yungsters))
|
||||
- `react-native/eslint-plugin` no longer provides the `no-haste-imports` rule. ([1ec69b1823](https://github.com/facebook/react-native/commit/1ec69b1823c3fd0cc2a9209032e4e3e8e8166030) by [@yungsters](https://github.com/yungsters))
|
||||
- Remove listKey from TS typings ([773615bc9d](https://github.com/facebook/react-native/commit/773615bc9d8e43b569513a3233259caa965a4c0b) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Remove usages of listKey ([bc5cb7cd79](https://github.com/facebook/react-native/commit/bc5cb7cd7933da707c02ff0dd993c607ba7d40b3) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Remove unneed/obsolete job ([8e3b62019e](https://github.com/facebook/react-native/commit/8e3b62019ee412399ece0fbda91e58bb395f7e98) by [@kelset](https://github.com/kelset))
|
||||
- Remove flexlayout from react-native ([bf05df1723](https://github.com/facebook/react-native/commit/bf05df17230e1063ff29d5ae5d86feac85e122b3) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Remove remaining TV_OS fragments ([089684ee56](https://github.com/facebook/react-native/commit/089684ee5604a6a2a15a4fc03fe63c73a5de9fd0) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
|
||||
#### Android specific
|
||||
|
||||
- Removed `AsyncStorage` module ([5738fe6426](https://github.com/facebook/react-native/commit/5738fe642601237e16417105d6727f777e73aae3) by [@hoxyq](https://github.com/hoxyq))
|
||||
- Deprecate react.gradle ([af6aafff90](https://github.com/facebook/react-native/commit/af6aafff90c4d40abfe160c4cfc8e1ae8fa0d956) by [@cortinico](https://github.com/cortinico))
|
||||
- Removed deprecated UIImplementationProvider ([e7d7563195](https://github.com/facebook/react-native/commit/e7d75631959f1ce3f50a44f13056eacaf82378ff) by [@javache](https://github.com/javache))
|
||||
- Cleanup Buck usages from New App Template ([32fc551c55](https://github.com/facebook/react-native/commit/32fc551c55a203bc4a511c12ae362632acb3b286) by [@cortinico](https://github.com/cortinico))
|
||||
|
||||
#### iOS specific
|
||||
|
||||
- Removed `AsyncStorage` module ([4de2aaba50](https://github.com/facebook/react-native/commit/4de2aaba502b49f8360ee5622d6ee8a6d9a93a32) by [@hoxyq](https://github.com/hoxyq))
|
||||
- Remove `HERMES_BUILD_FROM_SOURCE` flag ([138af74e3f](https://github.com/facebook/react-native/commit/138af74e3f2aa429eedc8881c8feb6d4a7b5c253) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Removed `ImagePickerIOS` module native sources ([d03a29ce5f](https://github.com/facebook/react-native/commit/d03a29ce5f7a40b4b0d172b7f2eb957143684818) by [@hoxyq](https://github.com/hoxyq))
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fix TS Type for measureLayout optional parameter ([5928144302](https://github.com/facebook/react-native/commit/59281443021e271c9112d60a2c2276fe10a67e37) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Allow GNU coreutils to be used to build projects ([f5e5274e6a](https://github.com/facebook/react-native/commit/f5e5274e6ad1330ad8d005f08d6f1ec678ea9ffe) by [@shreeve](https://github.com/shreeve))
|
||||
- Reference App.tsx vs App.js in text of new typescript template ([81e441ae8a](https://github.com/facebook/react-native/commit/81e441ae8a7daed79d8804c72e1991b29f670411) by [@mikehardy](https://github.com/mikehardy))
|
||||
- Fix incorrect height when gap causes main axis to overflow and cross-axis is stretched ([1aa157b196](https://github.com/facebook/react-native/commit/1aa157b196b85d81e2e2115815c073fe8c0730c4) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Codegen for C++ TurboModules of optional method arguments was incorrect ([e81c98c842](https://github.com/facebook/react-native/commit/e81c98c842380d8b72c1dc8d4a6e64f760e2a58c) by [@javache](https://github.com/javache))
|
||||
- Fix incorrect height when gap causes main axis to overflow and cross-axis is stretched ([1aa157b196](https://github.com/facebook/react-native/commit/1aa157b196b85d81e2e2115815c073fe8c0730c4) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Fixup TS Organization ([5d26ceaa23](https://github.com/facebook/react-native/commit/5d26ceaa236684c7bd6d0d9001ff2c8908d88c29) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Fixed typo syncronization -> synchronization ([ad5e3f6b9a](https://github.com/facebook/react-native/commit/ad5e3f6b9ae870cbfcef2874511915c5dc309ce8) by [@pruthvip](https://github.com/pruthvip))
|
||||
- react-native-codegen : Add Map / indexed object support for TypeScript parser ([87c356d56c](https://github.com/facebook/react-native/commit/87c356d56c73c3289da3d5911288909720b11994) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
- Add wanted dependencies to remove yarn warnings ([cd25fb3240](https://github.com/facebook/react-native/commit/cd25fb324018ed97a42e1d7ec8d923c09eef4f63) by [@kelset](https://github.com/kelset))
|
||||
- Fixed crash when converting JS symbol to folly::dynamic ([428feb2f76](https://github.com/facebook/react-native/commit/428feb2f76c55d6ae5914b019095cd835aa514b0) by [@kassens](https://github.com/kassens))
|
||||
- Error reporting for module errors ([af0e6cdae5](https://github.com/facebook/react-native/commit/af0e6cdae5762346a013a60e9b3f095204292550) by [@rickhanlonii](https://github.com/rickhanlonii))
|
||||
- Support properly sending BigInts and Symbols over the Chrome DevTools Protocol. ([7208d15dce](https://github.com/facebook/react-native/commit/7208d15dce552289e530ed470d66c05a65a7239a))
|
||||
- Fixed React DevTools element highlighting throwing redbox errors ([c64f25ac85](https://github.com/facebook/react-native/commit/c64f25ac85d32186c0400b8aa27785280cdf2799))
|
||||
- Fix require cycle warning in VirtualizedList ([49cb7f28c8](https://github.com/facebook/react-native/commit/49cb7f28c8dee19c2f3f20aaf21bbf91e85fa5e6) by [@motiz88](https://github.com/motiz88))
|
||||
- Pressability for text with only `onPressIn` / `onPressOut` props ([f1f7824203](https://github.com/facebook/react-native/commit/f1f78242039438241a905eb43b37c57b73e03335))
|
||||
- Load react-native.config.js from correct path during codegen ([74fda10702](https://github.com/facebook/react-native/commit/74fda1070266df13e1b58680a670dde3acf9d205) by [@krystofwoldrich](https://github.com/krystofwoldrich))
|
||||
- Remove usage of the codegen spec filtering until we publish a new version of the codegen. ([ae3dd54fae](https://github.com/facebook/react-native/commit/ae3dd54faee02746b65eeafe36f40f1653b9049b) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Fix nightly build issues ([93c3effc72](https://github.com/facebook/react-native/commit/93c3effc7284cfd5e64a9280e1a56ee7e86127d1) by [@Kudo](https://github.com/Kudo))
|
||||
- Properly parse negative values ([f3c98c5fa2](https://github.com/facebook/react-native/commit/f3c98c5fa273dbdb17c32cd1193a3f078ef942b4) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Fixup Yoga Enum Generator ([5f9689a0d0](https://github.com/facebook/react-native/commit/5f9689a0d041d2ca81cd2e8e407d97db330b2c95) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Fix remaining NDK comment for new architecture ([fb1f53f7dc](https://github.com/facebook/react-native/commit/fb1f53f7dc09428d2133de8060e63d8194853608) by [@ken0nek](https://github.com/ken0nek))
|
||||
- Fixed missing Pressable hover props in typescript definition ([6ba5fa946d](https://github.com/facebook/react-native/commit/6ba5fa946d5076995f28f3f5060aa5cabd62619b) by [@Saadnajmi](https://github.com/Saadnajmi))
|
||||
- Remove Android.mk from internal Gradle task ([d0df6afe76](https://github.com/facebook/react-native/commit/d0df6afe7646032c77643ebd25fa69c507c9ef92) by [@Sunbreak](https://github.com/Sunbreak))
|
||||
- In RN devtools, call that method, and then set component state to not inspecting. ([bfb36c2163](https://github.com/facebook/react-native/commit/bfb36c21633526fc46f637783b1ff26f2ade1c56) by [@tyao1](https://github.com/tyao1))
|
||||
- Enable the `react-native-codegen` tests in the OSS. ([00458c9410](https://github.com/facebook/react-native/commit/00458c94109776251678efbec10052702a41c335) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Make style pointerEvents take priority over pointerEvents prop. FIxes requested changes in https://github.com/facebook/react-native/issues/34586 ([a789ead545](https://github.com/facebook/react-native/commit/a789ead5459b772a1ae9b17fce6565d4717554f8) by [@cyrus25](https://github.com/cyrus25))
|
||||
- Change Wrapper of `InspectorPanel` from `View` to `SafeAreaView` ([afad68f1a8](https://github.com/facebook/react-native/commit/afad68f1a83995eaa42a8f1c7c636ccef8914797) by [@raykle](https://github.com/raykle))
|
||||
- Typo in AssetSourceResolver ([a45eeea17a](https://github.com/facebook/react-native/commit/a45eeea17a330ccac391b5f0fc1a6f74b6b9e8ee) by [@dhruvtailor7](https://github.com/dhruvtailor7))
|
||||
- Run ExceptionsManager unit tests in both __DEV__ and prod mode ([a154207371](https://github.com/facebook/react-native/commit/a154207371e0498c93476d98f830ca8b15be8276) by [@GijsWeterings](https://github.com/GijsWeterings))
|
||||
- Avoid keypress event when text is pasted on macOS ([477663cba8](https://github.com/facebook/react-native/commit/477663cba8c353d950a9a928844929903d55933a) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
- Flipper now supports custom Xcode build configuration names ([1bc9ddbce3](https://github.com/facebook/react-native/commit/1bc9ddbce393be9466cb87124d3e34a19abb8e5d) by [@scarlac](https://github.com/scarlac))
|
||||
- Make clang-format work in M1 (Apple Silicon) ([377aa7a30f](https://github.com/facebook/react-native/commit/377aa7a30f5ca1f128fd9222b317ff543e9b0e4a) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
- Using SOURCEMAP_FILE during xcode build phase with Hermes enabled ([a98da32229](https://github.com/facebook/react-native/commit/a98da322293e2db777bcc599b5abb10f750a7816) by [@kidroca](https://github.com/kidroca))
|
||||
- Remove compiler-specific syntax. ([33dbb6c40c](https://github.com/facebook/react-native/commit/33dbb6c40ccf44e4b4c879270b6286e2829d057b) by [@chiaramooney](https://github.com/chiaramooney))
|
||||
- Fix reload hang after debugger break and continue ([60e7eb4d53](https://github.com/facebook/react-native/commit/60e7eb4d534298cb9888d5ab0c8b6a6b041dc299) by [@aeulitz](https://github.com/aeulitz))
|
||||
- Fix FlatList not calling render items for nullish values when numColumns > 1 ([cc19cdcdbe](https://github.com/facebook/react-native/commit/cc19cdcdbe927368ae1cf4c62a52edd838413252) by [@AntoineDoubovetzky](https://github.com/AntoineDoubovetzky))
|
||||
- Fix macro errors for Windows. ([fc26dbfce0](https://github.com/facebook/react-native/commit/fc26dbfce0ed16edf1efcfebc01dd4ca584eb902) by [@chiaramooney](https://github.com/chiaramooney))
|
||||
- Adding grid role to ViewAccessibility to fix flow errors. ([5ddb9977e6](https://github.com/facebook/react-native/commit/5ddb9977e662a1b41dd7203605ca8480432fc06a) by [@fabriziobertoglio1987](https://github.com/fabriziobertoglio1987))
|
||||
- Fix: use REACT_NATIVE_CI instead of CI envvar ([ed16fdbbb8](https://github.com/facebook/react-native/commit/ed16fdbbb8f9f5943d4bb9d9a0f40caf89904d33) by [@dmytrorykun](https://github.com/dmytrorykun))
|
||||
- Bypass tag check in dry run ([ba1a9defbb](https://github.com/facebook/react-native/commit/ba1a9defbbc3261dca43ba20bde41dc6613aa4cf) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Fix removal of version from Hermes tarball, part 2 ([6107793fda](https://github.com/facebook/react-native/commit/6107793fda11a85297b3a3e2b8f259930d6c0f41) by [@kelset](https://github.com/kelset))
|
||||
- Fix removal of version from Hermes tarball ([e809e4b1ec](https://github.com/facebook/react-native/commit/e809e4b1ecafc942463becfd6a5d62e5132f8f94) by [@kelset](https://github.com/kelset))
|
||||
- Better fix for param ([32931b19b1](https://github.com/facebook/react-native/commit/32931b19b1f83081dd9e1085ff0add922630f81b) by [@kelset](https://github.com/kelset))
|
||||
- Fix publish npm post strict ([0f72abfc03](https://github.com/facebook/react-native/commit/0f72abfc03532ca3919554cbbecc8a31d76c231b) by [@kelset](https://github.com/kelset))
|
||||
- Fix some issues exposed when making function statics sealed ([662115077a](https://github.com/facebook/react-native/commit/662115077a9d7dab260ec93d89c7ca02145a47f8) by [@gkz](https://github.com/gkz))
|
||||
- Fix measure inner dimensions ([11f47432ff](https://github.com/facebook/react-native/commit/11f47432ff10d0cfe81883f942256c469ac34140) by [@kinarobin](https://github.com/kinarobin))
|
||||
- Annotate empty objects in xplat ([abb21dd908](https://github.com/facebook/react-native/commit/abb21dd908729fa69daf2fa63366e488009b63bd) by [@SamChou19815](https://github.com/SamChou19815))
|
||||
- Fix comment typo 'layed out' to 'laid out' ([108c876206](https://github.com/facebook/react-native/commit/108c8762060c9d52e295a1e0f9cdeb6c6a44b53e) by [@lwyj123](https://github.com/lwyj123))
|
||||
- Fix missing dll exports ([619d115822](https://github.com/facebook/react-native/commit/619d115822bce7b0f6fa194c133d895dc77e717e) by [@justjavac](https://github.com/justjavac))
|
||||
- Fix FillRateHelper Accessing -1 Frame ([052617611d](https://github.com/facebook/react-native/commit/052617611d68042b0c228955ed5de10a07da203a) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Attempt fix #2 for `cellsAroundViewport` reaching out of bounds ([0ef770587f](https://github.com/facebook/react-native/commit/0ef770587f78389ea4c56f5ace4389d07281947c) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Attempt fix for `cellsAroundViewport` reaching out of bounds ([7aa203beda](https://github.com/facebook/react-native/commit/7aa203beda3cd358703c2fa535ed045771761612) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Reland D38460202 and fix tests ([c4ddaa8fdb](https://github.com/facebook/react-native/commit/c4ddaa8fdba54dd0a7e8587859a7c30ef0d6ce6c) by [@sshic](https://github.com/sshic))
|
||||
- Add missing class annotations and lock xplat/js ([0ccbe5f704](https://github.com/facebook/react-native/commit/0ccbe5f70463b5259ae1adcb65deeb89204b1948) by [@pieterv](https://github.com/pieterv))
|
||||
- Add missing class annotations xplat/js [suppressions] ([2e649006f1](https://github.com/facebook/react-native/commit/2e649006f1a78539f5504bce79cbd51816679e13) by [@pieterv](https://github.com/pieterv))
|
||||
- Add missing class annotations xplat/js ([ee3d3c248d](https://github.com/facebook/react-native/commit/ee3d3c248df4e8be3a331ead5f6eea75c1cf237a) by [@pieterv](https://github.com/pieterv))
|
||||
- Apply lint updates from buildifier in xplat ([a70354df12](https://github.com/facebook/react-native/commit/a70354df12ef71aec08583cca4f1fed5fb77d874) by [@chatura-atapattu](https://github.com/chatura-atapattu))
|
||||
- fix: remove gap if its last element in line (fix flex gap extra spacing when children determine parents main axis size)([](https://github.com/facebook/react-native/commit/a0ee98dfeec1a75e649a935b733c70ae2cc1628d) by [@intergalacticspacehighway](https://github.com/intergalacticspacehighway))
|
||||
- Add missing AccessibilityInfo Types to TS Typings ([dc1b20d495](https://github.com/facebook/react-native/commit/dc1b20d49514ec5962a6c165a99d9406a66ba67d) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Fix Errors with TypeScript Tests ([ed08edd966](https://github.com/facebook/react-native/commit/ed08edd966aa17764436042b8202704144d61861) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Add missing VirtualizedList Imperative Types ([de1136359c](https://github.com/facebook/react-native/commit/de1136359cf78fa3f2593388924893c36c526650) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Fix virtual list type ([1bd3831cc5](https://github.com/facebook/react-native/commit/1bd3831cc56bb77ada47c4a71fd6cd69fd731938) by [@aliakbarazizi](https://github.com/aliakbarazizi))
|
||||
- Add missing types for AppRegistry ([213c26c23d](https://github.com/facebook/react-native/commit/213c26c23d91ee994d86f0f9e0e886f4e8a1837e) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Add type for RootTagContext ([fd28032be6](https://github.com/facebook/react-native/commit/fd28032be621ce50e9c8785b35f853b51c44df9d) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Add missing types to PushNotificationIOS ([f04f067aae](https://github.com/facebook/react-native/commit/f04f067aae8c07faa8dce19500eeb7f2dcca99ad) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Fix missing animation type (CircleCI Break) ([696f4b5c39](https://github.com/facebook/react-native/commit/696f4b5c39d67bf62d4eae6cfd497293f2c1bd08) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Fix types for deprecated scrollTo fields ([f9ab91c3ab](https://github.com/facebook/react-native/commit/f9ab91c3abe9baef520255e580005b24be282991) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Fix Vibration.vibrate() allowing null params ([9b7618856f](https://github.com/facebook/react-native/commit/9b7618856f6e1fd423f302cdfab7121f913caf7f) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Mark scrollToEnd animated as optional ([8770b2724a](https://github.com/facebook/react-native/commit/8770b2724ae9783b649824249fa252ec7900471d) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Fix type for StyleSheet.compose() ([754524ea9d](https://github.com/facebook/react-native/commit/754524ea9d2f4b5f8c3eb9e05b2fd25a3e0c3418) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Remove testID from TS ViewStyle ([172f23a2ee](https://github.com/facebook/react-native/commit/172f23a2ee167c322bd84e9d43d3f39fed51116b) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Add missing type for AnimatedValue.resetAnimation() and AnimatedValue.animate() ([1b5066c21d](https://github.com/facebook/react-native/commit/1b5066c21dde90f31753d6d84bce3d8817071451) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
|
||||
#### Android specific
|
||||
|
||||
- `findPackageJsonFile` should return `null` if `package.json` does not exist ([913ebd207c](https://github.com/facebook/react-native/commit/913ebd207c2e7bc1182eab0bd8d82e7d9d7ee567) by [@tido64](https://github.com/tido64))
|
||||
- Fix crash on initialize modal ([15656342a8](https://github.com/facebook/react-native/commit/15656342a8401eb599090da7962928dd48d7d890) by [@alpha0010](https://github.com/alpha0010))
|
||||
- Fix Android autolinking failing because of not expanded variable ([4c1d5ad9c6](https://github.com/facebook/react-native/commit/4c1d5ad9c67b8d0184d27e4e7f6e1cd5b7f8e8b9) by [@kkafar](https://github.com/kkafar))
|
||||
- On instance destroy, websockets are correctly closed ([b5ea5a2c4d](https://github.com/facebook/react-native/commit/b5ea5a2c4d053cc0962305a7b4f834c28f6d8ddf) by [@javache](https://github.com/javache))
|
||||
- Sets the namespace via Gradle and not via AndroidManifest ([cec9a34f6c](https://github.com/facebook/react-native/commit/cec9a34f6cd2a82bba76e15761da6b588bc3f574) by [@cortinico](https://github.com/cortinico))
|
||||
- RNGP - Do the .so cleanup using pickFirst and exclude ([2ff08e8bd8](https://github.com/facebook/react-native/commit/2ff08e8bd8b1303f1ef6f3052031c3a216565053) by [@cortinico](https://github.com/cortinico))
|
||||
- Fixed an issue on Android API 31+ where modals would turn status bar icons white by default ([5c5220a46d](https://github.com/facebook/react-native/commit/5c5220a46d05fa070e9f5f990bd741efa2b09309) by [@Abbondanzo](https://github.com/Abbondanzo))
|
||||
- TextInputs may not get focused when switching inputs in a ScrollView ([370bbd705b](https://github.com/facebook/react-native/commit/370bbd705b21947f1c334e158816c812825546d4) by [@javache](https://github.com/javache))
|
||||
- Fix react.gradle's detectCliPath's for finding the path from Node ([121184bb8f](https://github.com/facebook/react-native/commit/121184bb8f02e884f378a6712950162a8eb15695) by [@liamjones](https://github.com/liamjones))
|
||||
- Fix crash on release versions after AGP 7.3 bump ([6125f1f866](https://github.com/facebook/react-native/commit/6125f1f866da129dbdc01f5b9e4fac27fa77ed8a) by [@cortinico](https://github.com/cortinico))
|
||||
- Gracefully handle crash if no WebView provider is found on the device ([3f3394a566](https://github.com/facebook/react-native/commit/3f3394a5668d515e3476933aec67f07794c6e765) by [@rachitmishra](https://github.com/rachitmishra))
|
||||
- Text with onPress or onLongPress handler is not accessible with TalkBack ([f3847eeec2](https://github.com/facebook/react-native/commit/f3847eeec2679450fcb4fe52e351b9a9c3b0d2a6) by [@fabriziobertoglio1987](https://github.com/fabriziobertoglio1987))
|
||||
- Align android image style / source logic with ios ([6bdcb49966](https://github.com/facebook/react-native/commit/6bdcb49966882bcf696d42066e289783c003dcfc) by [@danilobuerger](https://github.com/danilobuerger))
|
||||
- Emit the right bubbling event for ReactSliderEvent ([b7e7e7ff1e](https://github.com/facebook/react-native/commit/b7e7e7ff1e74b45709def1f6753fb6421c57a448))
|
||||
- Typo in build.gradle ([ed21a3e20f](https://github.com/facebook/react-native/commit/ed21a3e20fcbba131792f469fe004f8cf97a4018) by [@jeremybarbet](https://github.com/jeremybarbet))
|
||||
- Border width top/bottom not matching the border radius ([cd6a91343e](https://github.com/facebook/react-native/commit/cd6a91343ee24af83c7437b3f2449b41e97760e9) by [@hurali97](https://github.com/hurali97))
|
||||
- Re-implement accessibilityHint on Android to use AccessibililltyNodeInfo#setToolTipText instead of contentDescription ([0b70b38547](https://github.com/facebook/react-native/commit/0b70b38547685b6b978cacedf3ff36723d79a594) by [@fabriziobertoglio1987](https://github.com/fabriziobertoglio1987))
|
||||
- Removed unused variable `NODE_MODULES_DIR` from `build.gradle` in app template ([50b1270298](https://github.com/facebook/react-native/commit/50b12702987c7f6550d4272ce7c94262ec47b6c3) by [@tomekzaw](https://github.com/tomekzaw))
|
||||
- AccessibilityLabelledBy use DynamicFromObject to parse String to Dynamic ([9f4358142e](https://github.com/facebook/react-native/commit/9f4358142ea7d8f110bbb09dbe3896f5859d56b3) by [@fabriziobertoglio1987](https://github.com/fabriziobertoglio1987))
|
||||
- Bug with view transforms when view recycling is enabled ([e0be14a310](https://github.com/facebook/react-native/commit/e0be14a310009f085e6f5abb52528a528bc923f3) by [@javache](https://github.com/javache))
|
||||
- Use WindowInsetsCompat for Keyboard Events ([1e48274223](https://github.com/facebook/react-native/commit/1e48274223ee647ac4fc2c21822b5240f3c47e4c) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Adding importantForAccessibility for Text, Button, ImageBackground ([62021eb8d1](https://github.com/facebook/react-native/commit/62021eb8d1721af3a44da1b83c8a6cb59d9d6244) by [@fabriziobertoglio1987](https://github.com/fabriziobertoglio1987))
|
||||
- Fix regression when setting shadow node properties. ([a142a78473](https://github.com/facebook/react-native/commit/a142a784733bc7e37042a7e4d3cdbeff99aa1fa7) by [@rshest](https://github.com/rshest))
|
||||
- Fix occasionally incorrect ScrollView fling behavior ([c7c263dda8](https://github.com/facebook/react-native/commit/c7c263dda8324ec8192ef6389f491a243a100a58) by [@dhleong](https://github.com/dhleong))
|
||||
- Migrate `needsCustomLayoutForChildren` check to the new architecture ([e24ce708ab](https://github.com/facebook/react-native/commit/e24ce708abffee8ec4521ba8162ea8964eb4429f) by [@grahammendick](https://github.com/grahammendick))
|
||||
- Remove extra indexOf call in BackHandler.removeEventListener ([14c207d9e1](https://github.com/facebook/react-native/commit/14c207d9e1ffbfa8eeb3b2c6d2a6e334168a4d73) by [@vitalii-tb](https://github.com/vitalii-tb))
|
||||
- Fix such that when the scrollviews call `onChildStartedNativeGesture`, they appropriately call `onChildEndedNativeGesture` to unlock the native gesture such that `JSTouchDispatcher` or `JSPointerDispatcher` will continue to emit events. ([143a0f74b8](https://github.com/facebook/react-native/commit/143a0f74b86bf2593dd29ce3c85d73d703d7a9f5))
|
||||
- Fix `AttributedString` comparison logic for TextInput state updates ([089c9a5c9c](https://github.com/facebook/react-native/commit/089c9a5c9c9a60b6bbff6dda0c9eefa9d501a092) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Invoke closeAndReleaseSonatypeStagingRepository in the publish gradle invocation ([e4f23f4783](https://github.com/facebook/react-native/commit/e4f23f4783968e40924ab0f3500018dc79c2d366) by [@cortinico](https://github.com/cortinico))
|
||||
- Do not eat taps/clicks in ScrollView when soft-keyboard is detached from viewport ([fd1e82a10f](https://github.com/facebook/react-native/commit/fd1e82a10f80c76bd37e7eef65c0dc2220c6bb8d) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Add missing class annotations xplat/js ([c687dd3a77](https://github.com/facebook/react-native/commit/c687dd3a77e28b7318514e5ab318be302f0e7643) by [@pieterv](https://github.com/pieterv))
|
||||
|
||||
#### iOS specific
|
||||
|
||||
- Don't use the internal `native_modules.rb` script yet, as it hides a hard-coded path ([4df793f75b](https://github.com/facebook/react-native/commit/4df793f75bb178ffd0217ff745de1e1c10b14098) by [@tido64](https://github.com/tido64))
|
||||
- Exclude redirector to `LongLivedObject.h` from ReactCommon podspec ([dd0bf83481](https://github.com/facebook/react-native/commit/dd0bf834818bcd330b0837b6ada9b848a595e4fe) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Fix incorrect codegen CLI paths in monorepo projects ([4a4cceef25](https://github.com/facebook/react-native/commit/4a4cceef2570c2a68ae91db0648aaaf08cf6c426) by [@byCedric](https://github.com/byCedric))
|
||||
- Remove hermesc build dir for non-Hermes build. ([c05e6c47df](https://github.com/facebook/react-native/commit/c05e6c47df95f36f0afa94a7aa6725a34bee4095))
|
||||
- Remove `Copy Hermes Framework` script phase for non-Hermes build. ([7f60bcceac](https://github.com/facebook/react-native/commit/7f60bcceac736aee99e4a8deaadcad30e94f43bc))
|
||||
- Make sure that the React-Codegen.podspec does not enforce specific versions of its dependencies. ([bc074a300d](https://github.com/facebook/react-native/commit/bc074a300dc8a1d26a11965520dafd8f3e190e01) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Various fixes for Hermes build-from-source behaviour. ([5dd0f7327b](https://github.com/facebook/react-native/commit/5dd0f7327bf6ef1e2d559e6f65769dab3c84fb19))
|
||||
- Correctly set -DCMAKE_BUILD_TYPE for Hermes on iOS ([c63133202b](https://github.com/facebook/react-native/commit/c63133202b015adc6cd94e77069586a619aca4a8) by [@cortinico](https://github.com/cortinico))
|
||||
- Https://github.com/facebook/react-native/pull/35047 reverted. ([bbd432e999](https://github.com/facebook/react-native/commit/bbd432e9994eb3b3114d429913bb8ce1a4f6e877))
|
||||
- Make sure that libraries created with `install_modules_dependencies` has the right C++ version. ([40ad31eacf](https://github.com/facebook/react-native/commit/40ad31eacf29e83ba91031b714c4de1f4d22e469) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Make ManagedObjectWrapper compile on macOS ([76c7ccaa60](https://github.com/facebook/react-native/commit/76c7ccaa60c4e820757c5d8cd8ccc80a2cb5f4a0) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
- Map `accessibilityRole: grid` to `UIAccessibilityTraitNone` ([f3d9f2ea23](https://github.com/facebook/react-native/commit/f3d9f2ea233304870bd4ab67d9682af6eb0ae16f) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
- Remove unused #import <UIKit/UIGestureRecognizerSubclass.h> import which breaks macOS ([84737e0069](https://github.com/facebook/react-native/commit/84737e0069f820bdb4b210e979d5faa2ec85ed3e) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
- Fix Text.allowFontScaling prop in the new architecture ([e9b89b5ff2](https://github.com/facebook/react-native/commit/e9b89b5ff2b0085128bec2879d761352747d6714) by [@sammy-SC](https://github.com/sammy-SC))
|
||||
- Make the nightly work with the proper Hermes tarball ([1546666a6d](https://github.com/facebook/react-native/commit/1546666a6d713ef756b2f11de9581e3b2bbe08dc) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Add MARKETING_VERSION to template project ([33e140fd05](https://github.com/facebook/react-native/commit/33e140fd059c1eca3d07ebb76a9be36cf9189b74) by [@kelset](https://github.com/kelset))
|
||||
- Automatically following version on xcode. ([dcd21143bc](https://github.com/facebook/react-native/commit/dcd21143bc735ff15add4d4b4ba26e3c30ff0dc9) by [@erfinbadrian](https://github.com/erfinbadrian))
|
||||
- Fix race condition in RCTLoggingTests integration tests ([540ae39487](https://github.com/facebook/react-native/commit/540ae394871148f803bea0697a41763478262bb9))
|
||||
- Add missing react/renderer/mapbuffer module to podspec ([00458637da](https://github.com/facebook/react-native/commit/00458637da8473bd58e10c7e5a06be1d7ca8559d))
|
||||
- RedBox title font by using a monospace font on iOS +13. ([5933b6a3ba](https://github.com/facebook/react-native/commit/5933b6a3baaaf7071eafc7c1bde13106407759fd) by [@EvanBacon](https://github.com/EvanBacon))
|
||||
- Update usage of UIApplication.sharedApplication in RCTKeyCommands ([5e79fa8441](https://github.com/facebook/react-native/commit/5e79fa84412111cf8b8ea4828d82f83672c9dc9f) by [@evoactivity](https://github.com/evoactivity))
|
||||
- Change hermes logic in build scripts for Apple to use the correct files ([cc13b0273f](https://github.com/facebook/react-native/commit/cc13b0273fc533a38c06fddd5e6b74f77319afa6) by [@kelset](https://github.com/kelset))
|
||||
- Fix error in the Codegen template for ThirdPartyFabricComponentsProvider ([2f6b2127d9](https://github.com/facebook/react-native/commit/2f6b2127d933094f864523749d13cfbb140b5b63) by [@gispada](https://github.com/gispada))
|
||||
- `HERMES_ENABLED` check fixed in react-native-xcode.sh ([8745a148b6](https://github.com/facebook/react-native/commit/8745a148b6d8358702b5300d73f4686c3aedb413) by [@nvojnovic](https://github.com/nvojnovic))
|
||||
- Make sure to turn on the `RCT_NEW_ACRH_ENABLED` flag ([f31134af7d](https://github.com/facebook/react-native/commit/f31134af7d7fbd39a09e120907bffcb8bd40108f) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Fix `Alert` not showing in an app using `UIScene` ([153aedce41](https://github.com/facebook/react-native/commit/153aedce413ef73f5e026abdfcf1346a37cec219) by [@tido64](https://github.com/tido64))
|
||||
- Image Component will not update correctly when passing in new url ([5c211f2bce](https://github.com/facebook/react-native/commit/5c211f2bce6665468628bc0aa3a8174a474450af) by [@matpaul](https://github.com/matpaul))
|
||||
- Fixed Time.h:52:17: error when a folder in the file path has a space ([9e169da3ae](https://github.com/facebook/react-native/commit/9e169da3ae44854e0cbfe6d95739a669290105c8) by [@gaberogan](https://github.com/gaberogan))
|
||||
- Fix: RCTAlertController's UserInterfaceStyle to follow root window ([18542b6ef5](https://github.com/facebook/react-native/commit/18542b6ef5ae12f6b4b8e1ebb66ab85a2db0bd5c) by [@vonovak](https://github.com/vonovak))
|
||||
- CI broken due to Hermes Commit ([ff7f5a332f](https://github.com/facebook/react-native/commit/ff7f5a332f62e7b13a52d71fabc573224f812816) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Typo in AppDelegate.mm ([0a59c284a9](https://github.com/facebook/react-native/commit/0a59c284a91acb04053bcf2f2e6c47f7f53ddbfe) by [@jeremybarbet](https://github.com/jeremybarbet))
|
||||
- When source maps are enabled, clean up temporary files from the build directory. Reduces bundle size by at least 1MB. ([e0a71fc7b5](https://github.com/facebook/react-native/commit/e0a71fc7b5cb8c264000147099be5b2575931193) by [@dmytrorykun](https://github.com/dmytrorykun))
|
||||
- USE_HERMES envvar check fixed in react-native-xcode.sh. Now source maps are generated by default. ([03de19745e](https://github.com/facebook/react-native/commit/03de19745eec9a0d4d1075bac48639ecf1d41352) by [@dmytrorykun](https://github.com/dmytrorykun))
|
||||
- Fix keyboard accessory button not triggering onSubmitEditing ([98d74d6eb9](https://github.com/facebook/react-native/commit/98d74d6eb98c602a3c76adf54cc45767fb58b555))
|
||||
- Possible fix for convertIdToFollyDynamic crash in RCTBaseTextInputView and RCTEventDispatcher ([8b174a57c8](https://github.com/facebook/react-native/commit/8b174a57c8e732bbfe7c69e7a5f66f48cb300539) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
- Fix exception thrown by [RCTTextView description] on macOS ([7db6c080f5](https://github.com/facebook/react-native/commit/7db6c080f5992df76b10930908c2373634cd1911) by [@christophpurrer](https://github.com/christophpurrer))
|
||||
- Allow preferred Alert button regardless of the style ([653a19a8cd](https://github.com/facebook/react-native/commit/653a19a8cde60e7ab337559492c17d3aa0a860f6) by [@danilobuerger](https://github.com/danilobuerger))
|
||||
- Fix `contentInsetAdjustmentBehavior` set to `automatic` on `ScrollView` in the new architecture ([27fe6f1079](https://github.com/facebook/react-native/commit/27fe6f10796ecd47314279b1ae7cdfe29c16d1f0) by [@grahammendick](https://github.com/grahammendick))
|
||||
- Use readlink instead of realpath in packager.sh ([698b14789c](https://github.com/facebook/react-native/commit/698b14789cb0777961fe5f1d4363387f9f185b1b) by [@dminkovsky](https://github.com/dminkovsky))
|
||||
- Fix cocoapods cli native_modules require for pnpm node_modules ([af3dfbaa47](https://github.com/facebook/react-native/commit/af3dfbaa47f4d58f3f3f892a5debd8d54113c2c3) by [@danilobuerger](https://github.com/danilobuerger))
|
||||
- Use the right logic for build from source ([49c0267b66](https://github.com/facebook/react-native/commit/49c0267b6695199651e5eb3cc3bb10647fb5e37e) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Remove the hermes engine cache in the clean script ([9979e38c70](https://github.com/facebook/react-native/commit/9979e38c7093ba78db5d5b4b11456c78592ea8c5) by [@kelset](https://github.com/kelset))
|
||||
- Make sure to export a single version for hermes artifacts and wipe Podfile.lock while in release ([41bf725ada](https://github.com/facebook/react-native/commit/41bf725ada85ed4752006e2c2dcf43037e5c53e4) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Let React Native decide the Hermes version to use in the Codegen ([becb47ccb6](https://github.com/facebook/react-native/commit/becb47ccb6a6ed77e81b5488561ef6d683933ffe) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Fix copy-hermes-xcode.sh ([fc1dbb8f0b](https://github.com/facebook/react-native/commit/fc1dbb8f0be19d83653566e9b4340785350c7aba) by [@dmytrorykun](https://github.com/dmytrorykun))
|
||||
- Merge pull request #35188 from dmytrorykun/export-D40979350 ([151498a122](https://github.com/facebook/react-native/commit/151498a1224dde415c839833cbce36c94ed3410b) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
- Center text if line height isn't 0 ([70cc27c901](https://github.com/facebook/react-native/commit/70cc27c901aeb447910e30ac3ceac85990d3c16d) by [@sammy-SC](https://github.com/sammy-SC))
|
||||
- Fix cleanup not working on template app ([ce3eefe12c](https://github.com/facebook/react-native/commit/ce3eefe12c89378773c83cb3311e8997fd35e2b8) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
|
||||
### Security
|
||||
|
||||
- Bump terser minor version to mitigate CVE-2022-25858 ([743f9ff63b](https://github.com/facebook/react-native/commit/743f9ff63bf1e3825a1788978a9f6bad8ebddc0d) by [@GijsWeterings](https://github.com/GijsWeterings))
|
||||
|
||||
## v0.70.7
|
||||
|
||||
### Fixed
|
||||
|
||||
#### Android specific
|
||||
|
||||
- Mitigation for Samsung TextInput Hangs ([be69c8b5a7](https://github.com/facebook/react-native/commit/be69c8b5a77ae60cced1b2af64e48b90d9955be5) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
|
||||
#### iOS Specific
|
||||
|
||||
- Fix the potential race condition when dismissing and presenting modal ([279fb52e03](https://github.com/facebook/react-native/commit/279fb52e033daba60393e400e1ee585e7d067090) by [@wood1986](https://github.com/wood1986))
|
||||
|
||||
### Added
|
||||
|
||||
#### Android Specific
|
||||
|
||||
- Add `POST_NOTIFICATIONS` and deprecate `POST_NOTIFICATION` ([b5280bbc93](https://github.com/facebook/react-native/commit/b5280bbc93218bd15e2166b8689c1689200bb92c) by [@dcangulo](https://github.com/dcangulo))
|
||||
|
||||
## v0.70.6
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fixed regression: @jest/create-cache-key-function dependency was inadvertedly bumped to 29.x. We are bringing it back to 27.0.1. ([fb0e88beb9](https://github.com/facebook/react-native/commit/fb0e88beb9dc443abed3886e459e7a7715738adc) by [@kelset](https://github.com/kelset))
|
||||
|
||||
### Changed
|
||||
|
||||
- Bump version of Promise from 8.0.3 to 8.3.0, enabling `Promise.allSettled` and `Promise.any` ([475310dbba](https://github.com/facebook/react-native/commit/475310dbbaec8048411edefc6cdddab330df7966) by [@retyui](https://github.com/retyui))
|
||||
- Bump CLI to 9.3.2 ([9bcc5e0373](https://github.com/facebook/react-native/commit/9bcc5e037391b45315dac3cb5f566e290cbf48cb) by [@kelset](https://github.com/kelset))
|
||||
|
||||
#### iOS specific
|
||||
|
||||
- Cleanup codegen build folder before installing the pods ([0e316ec671](https://github.com/facebook/react-native/commit/0e316ec671617f5e7c1985b4b05cd0d45bcea403) by [@cipolleschi](https://github.com/cipolleschi))
|
||||
|
||||
## v0.70.5
|
||||
|
||||
### Fixed
|
||||
|
||||
- Force dependencies resolution to minor series for 0.70 ([59407a4d34](https://github.com/facebook/react-native/commit/59407a4d3442dddb7f4c29049bf56bbc345f950f) by [@cortinico](https://github.com/cortinico))
|
||||
|
||||
## v0.70.4
|
||||
|
||||
### Changed
|
||||
|
||||
- Bump CLI to 9.2.1 ([a24c8946e0](https://github.com/facebook/react-native/commit/a24c8946e065ca89048e574abd7c2dc0434a350b) by [@kelset](https://github.com/kelset))
|
||||
- Bump react-native-codegen to 0.70.6 ([866021b58c](https://github.com/facebook/react-native/commit/866021b58c28a1f1c394294ddc4ed69d4ecef10a) by [@dmytrorykun](https://github.com/dmytrorykun))
|
||||
|
||||
### Fixed
|
||||
|
||||
- Load react-native.config.js from correct path during codegen ([74fda10702](https://github.com/facebook/react-native/commit/74fda1070266df13e1b58680a670dde3acf9d205) by [@krystofwoldrich](https://github.com/krystofwoldrich))
|
||||
|
||||
#### iOS specific
|
||||
|
||||
- Fix error in the Codegen template for ThirdPartyFabricComponentsProvider ([2f6b2127d9](https://github.com/facebook/react-native/commit/2f6b2127d933094f864523749d13cfbb140b5b63) by [@gispada](https://github.com/gispada))
|
||||
- Center text if line height isn't 0 ([70cc27c901](https://github.com/facebook/react-native/commit/70cc27c901aeb447910e30ac3ceac85990d3c16d) by [@sammy-SC](https://github.com/sammy-SC))
|
||||
|
||||
## v0.70.3
|
||||
|
||||
### Fixed
|
||||
@@ -843,28 +251,6 @@ Read the [announcement blogpost here](https://reactnative.dev/blog/2023/01/12/ve
|
||||
- Add GitHub token permissions for workflows ([3da3d82320](https://github.com/facebook/react-native/commit/3da3d82320bd035c6bd361a82ea12a70dba4e851) by [@varunsh-coder](https://github.com/varunsh-coder))
|
||||
- Bump RCT-Folly to 2021-07-22 ([68f3a42fc7](https://github.com/facebook/react-native/commit/68f3a42fc7380051714253f43b42175de361f8bd) by [@luissantana](https://github.com/luissantana))
|
||||
|
||||
## v0.69.8
|
||||
|
||||
### Fixed
|
||||
|
||||
#### Android specific
|
||||
|
||||
- Mitigation for Samsung TextInput Hangs ([be69c8b5a7](https://github.com/facebook/react-native/commit/be69c8b5a77ae60cced1b2af64e48b90d9955be5) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
|
||||
## v0.69.8
|
||||
|
||||
### Fixed
|
||||
|
||||
#### Android specific
|
||||
|
||||
- Mitigation for Samsung TextInput Hangs ([be69c8b5a7](https://github.com/facebook/react-native/commit/be69c8b5a77ae60cced1b2af64e48b90d9955be5) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
|
||||
## v0.69.7
|
||||
|
||||
### Fixed
|
||||
|
||||
- Force dependencies resolution to minor series for 0.69 ([c4da74c463](https://github.com/facebook/react-native/commit/c4da74c4636cbbd6bbf681d39a8a8cca49f11f56) by [@Titozzz](https://github.com/Titozzz))
|
||||
|
||||
## v0.69.6
|
||||
|
||||
### Changed
|
||||
@@ -1159,28 +545,6 @@ Read the [announcement blogpost here](https://reactnative.dev/blog/2023/01/12/ve
|
||||
|
||||
- Encode URL params in URLSearchParams.toString() ([1042a8012f](https://github.com/facebook/react-native/commit/1042a8012fb472bd5c882b469fe507dd6279d562) by [@sshic](https://github.com/sshic))
|
||||
|
||||
## v0.68.6
|
||||
|
||||
### Fixed
|
||||
|
||||
#### Android specific
|
||||
|
||||
- Mitigation for Samsung TextInput Hangs ([be69c8b5a7](https://github.com/facebook/react-native/commit/be69c8b5a77ae60cced1b2af64e48b90d9955be5) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
|
||||
## v0.68.6
|
||||
|
||||
### Fixed
|
||||
|
||||
#### Android specific
|
||||
|
||||
- Mitigation for Samsung TextInput Hangs ([be69c8b5a7](https://github.com/facebook/react-native/commit/be69c8b5a77ae60cced1b2af64e48b90d9955be5) by [@NickGerleman](https://github.com/NickGerleman))
|
||||
|
||||
## v0.68.5
|
||||
|
||||
### Fixed
|
||||
|
||||
- Force dependencies resolution to minor series for 0.68 ([edcb3ca996](https://github.com/facebook/react-native/commit/edcb3ca996fb3296762af300a36c1d46356f1b24) by [@Titozzz](https://github.com/Titozzz))
|
||||
|
||||
## v0.68.4
|
||||
|
||||
### Changed
|
||||
@@ -1443,13 +807,6 @@ Read the [announcement blogpost here](https://reactnative.dev/blog/2023/01/12/ve
|
||||
|
||||
- Remove RCTUIManagerObserver from RCTNativeAnimatedTurboModule ([e9ed115bab](https://github.com/facebook/react-native/commit/e9ed115babbc82968380dae22fa928d4ce3cd6da) by [@p-sun](https://github.com/p-sun))
|
||||
|
||||
## v0.67.5
|
||||
|
||||
🚨 **IMPORTANT:** This is an exceptional release on an unsupported version. We recommend you upgrade to one of [the supported versions, listed here](https://github.com/reactwg/react-native-releases#which-versions-are-currently-supported).
|
||||
|
||||
### Fixed
|
||||
|
||||
- Force dependencies resolution to minor series for 0.67 ([9f2acda1b8](https://github.com/facebook/react-native/commit/9f2acda1b807e790b3e7562ce3436b93bcc2ad09) by [@cortinico](https://github.com/cortinico))
|
||||
|
||||
## v0.67.4
|
||||
|
||||
@@ -1592,14 +949,6 @@ Read the [announcement blogpost here](https://reactnative.dev/blog/2023/01/12/ve
|
||||
|
||||
- Avoiding logging root view params outside of dev / debug mode builds ([e612d3a116](https://github.com/facebook/react-native/commit/e612d3a116f39ab354169643bab0d4bb9cfc1a85) by [@sterlingwes](https://github.com/sterlingwes))
|
||||
|
||||
## v0.66.5
|
||||
|
||||
🚨 **IMPORTANT:** This is an exceptional release on an unsupported version. We recommend you upgrade to one of [the supported versions, listed here](https://github.com/reactwg/react-native-releases#which-versions-are-currently-supported).
|
||||
|
||||
### Fixed
|
||||
|
||||
- Force dependencies resolution to minor series for 0.66 ([201824c89e](https://github.com/facebook/react-native/commit/201824c89ecebd749ba7e603415edbe6a5b9b73d) by [@cortinico](https://github.com/cortinico))
|
||||
|
||||
## v0.66.4
|
||||
|
||||
### Fixed
|
||||
@@ -1770,14 +1119,6 @@ Read the [announcement blogpost here](https://reactnative.dev/blog/2023/01/12/ve
|
||||
- <TextInput> content is reset when emoji is entered at the max length ([f3b8d4976f](https://github.com/facebook/react-native/commit/f3b8d4976f8608c2cda1f071923f14b6d4538967))
|
||||
- Use `actionName` in accessibility event callback ([fed6ad5bad](https://github.com/facebook/react-native/commit/fed6ad5badb4196a1895370fc81c522572cb34b4) by [@ShikaSD](https://github.com/ShikaSD))
|
||||
|
||||
## v0.65.3
|
||||
|
||||
🚨 **IMPORTANT:** This is an exceptional release on an unsupported version. We recommend you upgrade to one of [the supported versions, listed here](https://github.com/reactwg/react-native-releases#which-versions-are-currently-supported).
|
||||
|
||||
### Fixed
|
||||
|
||||
- Force dependencies resolution to minor series for 0.65 ([9548eaea74](https://github.com/facebook/react-native/commit/9548eaea74c6ad242c015d1984503c4b7eb19b6f) by [@kelset](https://github.com/kelset))
|
||||
|
||||
## v0.65.2
|
||||
|
||||
### Fixed
|
||||
@@ -2017,15 +1358,6 @@ Read the [announcement blogpost here](https://reactnative.dev/blog/2023/01/12/ve
|
||||
- Fix builds on Xcode 12.5 ([36b58a824e](https://github.com/facebook/react-native/commit/36b58a824ea20daa22fe7c528a3bf0ff4e6a4cb5) by [@PeteTheHeat](https://github.com/PeteTheHeat))
|
||||
- Fix running React Native project with Xcode 12 in Release on iPhone Simulator ([fdcacd7f76](https://github.com/facebook/react-native/commit/fdcacd7f76ea8ca6dafda32ac431c8adc7bdad00) by [@grabbou](https://github.com/grabbou))
|
||||
|
||||
## v0.64.4
|
||||
|
||||
🚨 **IMPORTANT:** This is an exceptional release on an unsupported version. We recommend you upgrade to one of [the supported versions, listed here](https://github.com/reactwg/react-native-releases#which-versions-are-currently-supported).
|
||||
|
||||
### Fixed
|
||||
|
||||
- Add an afterEvaluate to solve AGP 4.1.x configuration resolution ([667f1bd21a](https://github.com/facebook/react-native/commit/667f1bd21abfdda19e56f8bbf0520fddba3102ed) by [@cortinico](https://github.com/cortinico))
|
||||
- Force dependencies resolution to minor series for 0.64 ([a6a183ad81](https://github.com/facebook/react-native/commit/a6a183ad8106d67e3befce842138e82fb1e136fd) by [@kelset](https://github.com/kelset))
|
||||
|
||||
## v0.64.3
|
||||
|
||||
### Fixed
|
||||
@@ -2289,15 +1621,6 @@ Read the [announcement blogpost here](https://reactnative.dev/blog/2023/01/12/ve
|
||||
- Fix crash inside RCTRedBox when trying to present same UIViewController twice ([46c77dc296](https://github.com/facebook/react-native/commit/46c77dc296dfab754356cd9346a01dae8d4869f4) by [@sammy-SC](https://github.com/sammy-SC))
|
||||
- Fix outdated CocoaPods version requirement in a React.podspec ([8a6ac1fef3](https://github.com/facebook/react-native/commit/8a6ac1fef369071405a3bf14a89924c66f28d192) by [@sunnylqm](https://github.com/sunnylqm))
|
||||
|
||||
## v0.63.5
|
||||
|
||||
🚨 **IMPORTANT:** This is an exceptional release on an unsupported version. We recommend you upgrade to one of [the supported versions, listed here](https://github.com/reactwg/react-native-releases#which-versions-are-currently-supported).
|
||||
|
||||
### Fixed
|
||||
|
||||
- Add an afterEvaluate to solve AGP 3.x configuration resolution ([473a36099c](https://github.com/facebook/react-native/commit/473a36099c80de08591e3cb51687f7d531145ee3) by [@cortinico](https://github.com/cortinico))
|
||||
- Force dependencies resolution to minor series for 0.63 ([28cc286cc4](https://github.com/facebook/react-native/commit/28cc286cc4d43b9fe5153d779ea3eecf4d72c51e) by [@cortinico](https://github.com/cortinico))
|
||||
|
||||
## v0.63.4
|
||||
|
||||
### Changed
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
source 'https://rubygems.org'
|
||||
|
||||
# You may use http://rbenv.org/ or https://rvm.io/ to install and use this version
|
||||
ruby ">= 2.6.10"
|
||||
ruby '>= 2.6.10'
|
||||
|
||||
gem 'cocoapods', '~> 1.12'
|
||||
gem 'activesupport', '>= 6.1.7.1'
|
||||
gem 'cocoapods', '>= 1.11.3'
|
||||
gem 'activesupport', '>= 6.1.7.3', '< 7.1.0'
|
||||
|
||||
+19
-19
@@ -3,24 +3,24 @@ GEM
|
||||
specs:
|
||||
CFPropertyList (3.0.6)
|
||||
rexml
|
||||
activesupport (7.0.6)
|
||||
activesupport (7.0.8)
|
||||
concurrent-ruby (~> 1.0, >= 1.0.2)
|
||||
i18n (>= 1.6, < 2)
|
||||
minitest (>= 5.1)
|
||||
tzinfo (~> 2.0)
|
||||
addressable (2.8.4)
|
||||
addressable (2.8.6)
|
||||
public_suffix (>= 2.0.2, < 6.0)
|
||||
algoliasearch (1.27.5)
|
||||
httpclient (~> 2.8, >= 2.8.3)
|
||||
json (>= 1.5.1)
|
||||
atomos (0.1.3)
|
||||
claide (1.1.0)
|
||||
cocoapods (1.12.1)
|
||||
cocoapods (1.15.0)
|
||||
addressable (~> 2.8)
|
||||
claide (>= 1.0.2, < 2.0)
|
||||
cocoapods-core (= 1.12.1)
|
||||
cocoapods-core (= 1.15.0)
|
||||
cocoapods-deintegrate (>= 1.0.3, < 2.0)
|
||||
cocoapods-downloader (>= 1.6.0, < 2.0)
|
||||
cocoapods-downloader (>= 2.1, < 3.0)
|
||||
cocoapods-plugins (>= 1.0.0, < 2.0)
|
||||
cocoapods-search (>= 1.0.0, < 2.0)
|
||||
cocoapods-trunk (>= 1.6.0, < 2.0)
|
||||
@@ -32,8 +32,8 @@ GEM
|
||||
molinillo (~> 0.8.0)
|
||||
nap (~> 1.0)
|
||||
ruby-macho (>= 2.3.0, < 3.0)
|
||||
xcodeproj (>= 1.21.0, < 2.0)
|
||||
cocoapods-core (1.12.1)
|
||||
xcodeproj (>= 1.23.0, < 2.0)
|
||||
cocoapods-core (1.15.0)
|
||||
activesupport (>= 5.0, < 8)
|
||||
addressable (~> 2.8)
|
||||
algoliasearch (~> 1.0)
|
||||
@@ -44,7 +44,7 @@ GEM
|
||||
public_suffix (~> 4.0)
|
||||
typhoeus (~> 1.0)
|
||||
cocoapods-deintegrate (1.0.5)
|
||||
cocoapods-downloader (1.6.3)
|
||||
cocoapods-downloader (2.1)
|
||||
cocoapods-plugins (1.0.0)
|
||||
nap
|
||||
cocoapods-search (1.0.1)
|
||||
@@ -53,31 +53,31 @@ GEM
|
||||
netrc (~> 0.11)
|
||||
cocoapods-try (1.2.0)
|
||||
colored2 (3.1.2)
|
||||
concurrent-ruby (1.2.2)
|
||||
concurrent-ruby (1.2.3)
|
||||
escape (0.0.4)
|
||||
ethon (0.16.0)
|
||||
ffi (>= 1.15.0)
|
||||
ffi (1.15.5)
|
||||
ffi (1.16.3)
|
||||
fourflusher (2.3.1)
|
||||
fuzzy_match (2.0.4)
|
||||
gh_inspector (1.1.3)
|
||||
httpclient (2.8.3)
|
||||
i18n (1.14.1)
|
||||
concurrent-ruby (~> 1.0)
|
||||
json (2.6.3)
|
||||
minitest (5.18.1)
|
||||
json (2.7.1)
|
||||
minitest (5.21.2)
|
||||
molinillo (0.8.0)
|
||||
nanaimo (0.3.0)
|
||||
nap (1.1.0)
|
||||
netrc (0.11.0)
|
||||
public_suffix (4.0.7)
|
||||
rexml (3.2.5)
|
||||
rexml (3.2.6)
|
||||
ruby-macho (2.5.1)
|
||||
typhoeus (1.4.0)
|
||||
typhoeus (1.4.1)
|
||||
ethon (>= 0.9.0)
|
||||
tzinfo (2.0.6)
|
||||
concurrent-ruby (~> 1.0)
|
||||
xcodeproj (1.22.0)
|
||||
xcodeproj (1.24.0)
|
||||
CFPropertyList (>= 2.3.3, < 4.0)
|
||||
atomos (~> 0.1.3)
|
||||
claide (>= 1.0.2, < 2.0)
|
||||
@@ -89,11 +89,11 @@ PLATFORMS
|
||||
ruby
|
||||
|
||||
DEPENDENCIES
|
||||
activesupport (>= 6.1.7.1)
|
||||
cocoapods (~> 1.12)
|
||||
activesupport (>= 6.1.7.3, < 7.1.0)
|
||||
cocoapods (>= 1.11.3)
|
||||
|
||||
RUBY VERSION
|
||||
ruby 3.0.6p216
|
||||
ruby 2.7.6p219
|
||||
|
||||
BUNDLED WITH
|
||||
2.4.13
|
||||
2.3.22
|
||||
|
||||
@@ -61,7 +61,6 @@ class IntegrationTestHarnessTest extends React.Component<Props, State> {
|
||||
* native_oss) This comment suppresses an error found when Flow v0.54
|
||||
* was deployed. To see the error delete this comment and run Flow.
|
||||
*/
|
||||
// $FlowFixMe[unsafe-addition]
|
||||
this.constructor.displayName + ': '
|
||||
}
|
||||
{this.state.done ? 'Done' : 'Testing...'}
|
||||
|
||||
+1
-1
@@ -13,7 +13,7 @@ import type {ColorValue} from '../StyleSheet/StyleSheet';
|
||||
|
||||
import RCTActionSheetManager from './NativeActionSheetManager';
|
||||
|
||||
const processColor = require('../StyleSheet/processColor').default;
|
||||
const processColor = require('../StyleSheet/processColor');
|
||||
const invariant = require('invariant');
|
||||
|
||||
/**
|
||||
+1
-1
@@ -23,7 +23,7 @@ Pod::Spec.new do |s|
|
||||
s.homepage = "https://reactnative.dev/"
|
||||
s.documentation_url = "https://reactnative.dev/docs/actionsheetios"
|
||||
s.license = package["license"]
|
||||
s.author = "Meta Platforms, Inc. and its affiliates"
|
||||
s.author = "Facebook, Inc. and its affiliates"
|
||||
s.platforms = { :ios => "12.4" }
|
||||
s.source = source
|
||||
s.source_files = "*.{m}"
|
||||
+4
-4
@@ -13,14 +13,14 @@
|
||||
export interface AlertButton {
|
||||
text?: string | undefined;
|
||||
onPress?: ((value?: string) => void) | undefined;
|
||||
isPreferred?: boolean | undefined;
|
||||
isPreferred?: boolean;
|
||||
style?: 'default' | 'cancel' | 'destructive' | undefined;
|
||||
}
|
||||
|
||||
interface AlertOptions {
|
||||
/** @platform android */
|
||||
cancelable?: boolean | undefined;
|
||||
userInterfaceStyle?: 'unspecified' | 'light' | 'dark' | undefined;
|
||||
userInterfaceStyle?: 'unspecified' | 'light' | 'dark';
|
||||
/** @platform android */
|
||||
onDismiss?: (() => void) | undefined;
|
||||
}
|
||||
@@ -33,8 +33,8 @@ interface AlertOptions {
|
||||
* button will be an 'OK' button.
|
||||
*
|
||||
* This is an API that works both on iOS and Android and can show static
|
||||
* alerts. On iOS, you can show an alert that prompts the user to enter
|
||||
* some information.
|
||||
* alerts. To show an alert that prompts the user to enter some information,
|
||||
* see `AlertIOS`; entering text in an alert is common on iOS only.
|
||||
*
|
||||
* ## iOS
|
||||
*
|
||||
+6
-17
@@ -11,12 +11,8 @@ import type * as React from 'react';
|
||||
import {ScrollView} from '../Components/ScrollView/ScrollView';
|
||||
import {View} from '../Components/View/View';
|
||||
import {Image} from '../Image/Image';
|
||||
import {FlatListComponent, FlatListProps} from '../Lists/FlatList';
|
||||
import {
|
||||
DefaultSectionT,
|
||||
SectionListComponent,
|
||||
SectionListProps,
|
||||
} from '../Lists/SectionList';
|
||||
import {FlatListProps} from '../Lists/FlatList';
|
||||
import {DefaultSectionT, SectionListProps} from '../Lists/SectionList';
|
||||
import {ColorValue} from '../StyleSheet/StyleSheet';
|
||||
import {Text} from '../Text/Text';
|
||||
import {NativeSyntheticEvent} from '../Types/CoreEventTypes';
|
||||
@@ -564,9 +560,7 @@ export namespace Animated {
|
||||
type NonAnimatedProps = 'key' | 'ref';
|
||||
|
||||
type TAugmentRef<T> = T extends React.Ref<infer R>
|
||||
? unknown extends R
|
||||
? never
|
||||
: React.Ref<R | LegacyRef<R>>
|
||||
? React.Ref<R | LegacyRef<R>>
|
||||
: never;
|
||||
|
||||
export type AnimatedProps<T> = {
|
||||
@@ -581,7 +575,7 @@ export namespace Animated {
|
||||
extends React.FC<AnimatedProps<React.ComponentPropsWithRef<T>>> {}
|
||||
|
||||
export type AnimatedComponentOptions = {
|
||||
collapsable?: boolean | undefined;
|
||||
collapsable?: boolean;
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -604,18 +598,13 @@ export namespace Animated {
|
||||
/**
|
||||
* FlatList and SectionList infer generic Type defined under their `data` and `section` props.
|
||||
*/
|
||||
|
||||
export class FlatList<ItemT = any> extends FlatListComponent<
|
||||
ItemT,
|
||||
export class FlatList<ItemT = any> extends React.Component<
|
||||
AnimatedProps<FlatListProps<ItemT>>
|
||||
> {}
|
||||
|
||||
export class SectionList<
|
||||
ItemT = any,
|
||||
SectionT = DefaultSectionT,
|
||||
> extends SectionListComponent<
|
||||
AnimatedProps<SectionListProps<ItemT, SectionT>>
|
||||
> {}
|
||||
> extends React.Component<AnimatedProps<SectionListProps<ItemT, SectionT>>> {}
|
||||
}
|
||||
|
||||
// We need to alias these views so we can reference them in the Animated
|
||||
+6
-18
@@ -142,11 +142,7 @@ const API = {
|
||||
}
|
||||
},
|
||||
flushQueue: function (): void {
|
||||
// TODO: (T136971132)
|
||||
invariant(
|
||||
NativeAnimatedModule || process.env.NODE_ENV === 'test',
|
||||
'Native animated module is not available',
|
||||
);
|
||||
invariant(NativeAnimatedModule, 'Native animated module is not available');
|
||||
flushQueueTimeout = null;
|
||||
|
||||
// Early returns before calling any APIs
|
||||
@@ -169,18 +165,16 @@ const API = {
|
||||
// use RCTDeviceEventEmitter. This reduces overhead of sending lots of
|
||||
// JSI functions across to native code; but also, TM infrastructure currently
|
||||
// does not support packing a function into native arrays.
|
||||
NativeAnimatedModule?.queueAndExecuteBatchedOperations?.(singleOpQueue);
|
||||
NativeAnimatedModule.queueAndExecuteBatchedOperations?.(singleOpQueue);
|
||||
singleOpQueue.length = 0;
|
||||
} else {
|
||||
Platform.OS === 'android' &&
|
||||
NativeAnimatedModule?.startOperationBatch?.();
|
||||
|
||||
Platform.OS === 'android' && NativeAnimatedModule.startOperationBatch?.();
|
||||
for (let q = 0, l = queue.length; q < l; q++) {
|
||||
queue[q]();
|
||||
}
|
||||
queue.length = 0;
|
||||
Platform.OS === 'android' &&
|
||||
NativeAnimatedModule?.finishOperationBatch?.();
|
||||
NativeAnimatedModule.finishOperationBatch?.();
|
||||
}
|
||||
},
|
||||
queueOperation: <Args: $ReadOnlyArray<mixed>, Fn: (...Args) => void>(
|
||||
@@ -248,7 +242,6 @@ const API = {
|
||||
}
|
||||
// $FlowFixMe
|
||||
API.queueOperation(
|
||||
// $FlowFixMe[incompatible-call]
|
||||
nativeOps.startAnimatingNode,
|
||||
animationId,
|
||||
nodeTag,
|
||||
@@ -391,15 +384,11 @@ const SUPPORTED_STYLES = {
|
||||
borderBottomLeftRadius: true,
|
||||
borderBottomRightRadius: true,
|
||||
borderBottomStartRadius: true,
|
||||
borderEndEndRadius: true,
|
||||
borderEndStartRadius: true,
|
||||
borderRadius: true,
|
||||
borderTopEndRadius: true,
|
||||
borderTopLeftRadius: true,
|
||||
borderTopRightRadius: true,
|
||||
borderTopStartRadius: true,
|
||||
borderStartEndRadius: true,
|
||||
borderStartStartRadius: true,
|
||||
elevation: true,
|
||||
opacity: true,
|
||||
transform: true,
|
||||
@@ -588,11 +577,10 @@ export default {
|
||||
assertNativeAnimatedModule,
|
||||
shouldUseNativeDriver,
|
||||
transformDataType,
|
||||
// $FlowExpectedError[unsafe-getters-setters] - unsafe getter lint suppression
|
||||
// $FlowExpectedError[missing-type-arg] - unsafe getter lint suppression
|
||||
// $FlowExpectedError[unsafe-getters-setters] - unsafe getter lint suppresion
|
||||
// $FlowExpectedError[missing-type-arg] - unsafe getter lint suppresion
|
||||
get nativeEventEmitter(): NativeEventEmitter {
|
||||
if (!nativeEventEmitter) {
|
||||
// $FlowFixMe[underconstrained-implicit-instantiation]
|
||||
nativeEventEmitter = new NativeEventEmitter(
|
||||
// T88715063: NativeEventEmitter only used this parameter on iOS. Now it uses it on all platforms, so this code was modified automatically to preserve its behavior
|
||||
// If you want to use the native module on other platforms, please remove this condition and test its behavior
|
||||
+10
-41
@@ -9,11 +9,10 @@
|
||||
*/
|
||||
|
||||
import * as React from 'react';
|
||||
import TestRenderer from 'react-test-renderer';
|
||||
|
||||
const {PlatformColor} = require('../../StyleSheet/PlatformColorValueTypes');
|
||||
let Animated = require('../Animated').default;
|
||||
const AnimatedProps = require('../nodes/AnimatedProps').default;
|
||||
const TestRenderer = require('react-test-renderer');
|
||||
let AnimatedProps = require('../nodes/AnimatedProps').default;
|
||||
|
||||
jest.mock('../../BatchedBridge/NativeModules', () => ({
|
||||
NativeAnimatedModule: {},
|
||||
@@ -176,13 +175,11 @@ describe('Animated tests', () => {
|
||||
|
||||
expect(testRenderer.toJSON().props.style.opacity).toEqual(0);
|
||||
|
||||
TestRenderer.act(() => {
|
||||
Animated.timing(opacity, {
|
||||
toValue: 1,
|
||||
duration: 0,
|
||||
useNativeDriver: false,
|
||||
}).start();
|
||||
});
|
||||
Animated.timing(opacity, {
|
||||
toValue: 1,
|
||||
duration: 0,
|
||||
useNativeDriver: false,
|
||||
}).start();
|
||||
|
||||
expect(testRenderer.toJSON().props.style.opacity).toEqual(1);
|
||||
});
|
||||
@@ -1040,10 +1037,10 @@ describe('Animated tests', () => {
|
||||
});
|
||||
|
||||
node.__attach();
|
||||
expect(callback).not.toHaveBeenCalled();
|
||||
expect(callback.mock.calls.length).toBe(0);
|
||||
|
||||
color.setValue({r: 11, g: 22, b: 33, a: 0.5});
|
||||
expect(callback).toHaveBeenCalledTimes(5);
|
||||
expect(callback.mock.calls.length).toBe(4);
|
||||
expect(node.__getValue()).toEqual({
|
||||
style: {
|
||||
backgroundColor: 'rgba(11, 22, 33, 0.5)',
|
||||
@@ -1053,7 +1050,7 @@ describe('Animated tests', () => {
|
||||
|
||||
node.__detach();
|
||||
color.setValue({r: 255, g: 0, b: 0, a: 1.0});
|
||||
expect(callback).toHaveBeenCalledTimes(5);
|
||||
expect(callback.mock.calls.length).toBe(4);
|
||||
});
|
||||
|
||||
it('should track colors', () => {
|
||||
@@ -1089,33 +1086,5 @@ describe('Animated tests', () => {
|
||||
jest.runAllTimers();
|
||||
expect(color2.__getValue()).toEqual('rgba(44, 55, 66, 0)');
|
||||
});
|
||||
|
||||
it('should provide updates for native colors', () => {
|
||||
const color = new Animated.Color('red');
|
||||
|
||||
const listener = jest.fn();
|
||||
color.addListener(listener);
|
||||
|
||||
const callback = jest.fn(() => {
|
||||
console.log('callback', color.__getValue());
|
||||
});
|
||||
const node = new AnimatedProps({style: {color}}, callback);
|
||||
node.__attach();
|
||||
|
||||
color.setValue('blue');
|
||||
expect(callback).toHaveBeenCalledTimes(5);
|
||||
expect(listener).toHaveBeenCalledTimes(1);
|
||||
expect(listener).toHaveBeenCalledWith({value: 'rgba(0, 0, 255, 1)'});
|
||||
expect(color.__getValue()).toEqual('rgba(0, 0, 255, 1)');
|
||||
|
||||
callback.mockClear();
|
||||
listener.mockClear();
|
||||
|
||||
color.setValue(PlatformColor('bar'));
|
||||
expect(callback).toHaveBeenCalledTimes(1);
|
||||
expect(listener).toHaveBeenCalledTimes(1);
|
||||
expect(listener).toHaveBeenCalledWith({value: PlatformColor('bar')});
|
||||
expect(color.__getValue()).toEqual(PlatformColor('bar'));
|
||||
});
|
||||
});
|
||||
});
|
||||
+1
-290
@@ -270,7 +270,7 @@ describe('Native Animated', () => {
|
||||
);
|
||||
});
|
||||
|
||||
it('should map AnimatedValueXY', () => {
|
||||
it('shoud map AnimatedValueXY', () => {
|
||||
const value = new Animated.ValueXY({x: 0, y: 0});
|
||||
value.__makeNative();
|
||||
const event = Animated.event([{nativeEvent: {state: value}}], {
|
||||
@@ -625,7 +625,6 @@ describe('Native Animated', () => {
|
||||
type: 'interpolation',
|
||||
inputRange: [10, 20],
|
||||
outputRange: [0, 1],
|
||||
outputType: null,
|
||||
extrapolateLeft: 'extend',
|
||||
extrapolateRight: 'extend',
|
||||
},
|
||||
@@ -672,294 +671,6 @@ describe('Native Animated', () => {
|
||||
);
|
||||
});
|
||||
|
||||
it('sends create operations before connect operations for multiple animated style props', () => {
|
||||
const opacity = new Animated.Value(0);
|
||||
const borderRadius = new Animated.Value(0);
|
||||
TestRenderer.create(<Animated.View style={{borderRadius, opacity}} />);
|
||||
|
||||
Animated.timing(opacity, {
|
||||
toValue: 10,
|
||||
duration: 1000,
|
||||
useNativeDriver: true,
|
||||
}).start();
|
||||
|
||||
const createCalls = NativeAnimatedModule.createAnimatedNode.mock.calls;
|
||||
const createCallOrder =
|
||||
NativeAnimatedModule.createAnimatedNode.mock.invocationCallOrder;
|
||||
const connectCalls = NativeAnimatedModule.connectAnimatedNodes.mock.calls;
|
||||
const connectCallOrder =
|
||||
NativeAnimatedModule.connectAnimatedNodes.mock.invocationCallOrder;
|
||||
|
||||
// First value node and style node should both be created before they are connected
|
||||
const valueNodeCreateCallIndices = createCalls.reduce(
|
||||
(acc, call, index) => {
|
||||
call[1].type === 'value' && acc.push(index);
|
||||
return acc;
|
||||
},
|
||||
[],
|
||||
);
|
||||
const value1NodeCreateCall = createCalls[valueNodeCreateCallIndices[0]];
|
||||
const value1NodeTag = value1NodeCreateCall[0];
|
||||
const value1NodeCreateInvocationOrder =
|
||||
createCallOrder[valueNodeCreateCallIndices[0]];
|
||||
|
||||
const styleNodeCreateCallIndex = createCalls.findIndex(
|
||||
call => call[1].type === 'style',
|
||||
);
|
||||
const styleNodeCreateCall = createCalls[styleNodeCreateCallIndex];
|
||||
const styleNodeTag = styleNodeCreateCall[0];
|
||||
const styleNodeCreateInvocationOrder =
|
||||
createCallOrder[styleNodeCreateCallIndex];
|
||||
|
||||
const value1StyleConnectCallIndex = connectCalls.findIndex(
|
||||
call => call[0] === value1NodeTag && call[1] === styleNodeTag,
|
||||
);
|
||||
const value1StyleConnectInvocationOrder =
|
||||
connectCallOrder[value1StyleConnectCallIndex];
|
||||
|
||||
expect(value1NodeCreateInvocationOrder).toBeLessThan(
|
||||
value1StyleConnectInvocationOrder,
|
||||
);
|
||||
expect(styleNodeCreateInvocationOrder).toBeLessThan(
|
||||
value1StyleConnectInvocationOrder,
|
||||
);
|
||||
|
||||
// Second value node and style node should both be created before they are connected
|
||||
const value2NodeCreateCall = createCalls[valueNodeCreateCallIndices[1]];
|
||||
const value2NodeTag = value2NodeCreateCall[0];
|
||||
const value2NodeCreateInvocationOrder =
|
||||
createCallOrder[valueNodeCreateCallIndices[1]];
|
||||
|
||||
const value2StyleConnectCallIndex = connectCalls.findIndex(
|
||||
call => call[0] === value2NodeTag && call[1] === styleNodeTag,
|
||||
);
|
||||
const value2StyleConnectInvocationOrder =
|
||||
connectCallOrder[value2StyleConnectCallIndex];
|
||||
|
||||
expect(value2NodeCreateInvocationOrder).toBeLessThan(
|
||||
value2StyleConnectInvocationOrder,
|
||||
);
|
||||
expect(styleNodeCreateInvocationOrder).toBeLessThan(
|
||||
value2StyleConnectInvocationOrder,
|
||||
);
|
||||
|
||||
// Style node and props node should both be created before they are connected
|
||||
const propsNodeCreateCallIndex = createCalls.findIndex(
|
||||
call => call[1].type === 'props',
|
||||
);
|
||||
const propsNodeCreateCall = createCalls[propsNodeCreateCallIndex];
|
||||
const propsNodeTag = propsNodeCreateCall[0];
|
||||
const propsNodeCreateInvocationOrder =
|
||||
createCallOrder[propsNodeCreateCallIndex];
|
||||
|
||||
const stylePropsConnectCallIndex = connectCalls.findIndex(
|
||||
call => call[0] === styleNodeTag && call[1] === propsNodeTag,
|
||||
);
|
||||
const stylePropsConnectInvocationOrder =
|
||||
connectCallOrder[stylePropsConnectCallIndex];
|
||||
|
||||
expect(styleNodeCreateInvocationOrder).toBeLessThan(
|
||||
stylePropsConnectInvocationOrder,
|
||||
);
|
||||
expect(propsNodeCreateInvocationOrder).toBeLessThan(
|
||||
stylePropsConnectInvocationOrder,
|
||||
);
|
||||
});
|
||||
|
||||
it('sends create operations before connect operations for multiple animated transform props', () => {
|
||||
const translateX = new Animated.Value(0);
|
||||
const translateY = new Animated.Value(0);
|
||||
TestRenderer.create(
|
||||
<Animated.View
|
||||
style={{
|
||||
transform: [{translateX: translateX}, {translateY: translateY}],
|
||||
}}
|
||||
/>,
|
||||
);
|
||||
|
||||
Animated.timing(translateX, {
|
||||
toValue: 10,
|
||||
duration: 1000,
|
||||
useNativeDriver: true,
|
||||
}).start();
|
||||
|
||||
const createCalls = NativeAnimatedModule.createAnimatedNode.mock.calls;
|
||||
const createCallOrder =
|
||||
NativeAnimatedModule.createAnimatedNode.mock.invocationCallOrder;
|
||||
const connectCalls = NativeAnimatedModule.connectAnimatedNodes.mock.calls;
|
||||
const connectCallOrder =
|
||||
NativeAnimatedModule.connectAnimatedNodes.mock.invocationCallOrder;
|
||||
|
||||
// First value node and transform node should both be created before they are connected
|
||||
const valueNodeCreateCallIndices = createCalls.reduce(
|
||||
(acc, call, index) => {
|
||||
call[1].type === 'value' && acc.push(index);
|
||||
return acc;
|
||||
},
|
||||
[],
|
||||
);
|
||||
const value1NodeCreateCall = createCalls[valueNodeCreateCallIndices[0]];
|
||||
const value1NodeTag = value1NodeCreateCall[0];
|
||||
const value1NodeCreateInvocationOrder =
|
||||
createCallOrder[valueNodeCreateCallIndices[0]];
|
||||
|
||||
const transformNodeCreateCallIndex = createCalls.findIndex(
|
||||
call => call[1].type === 'transform',
|
||||
);
|
||||
const transformNodeCreateCall = createCalls[transformNodeCreateCallIndex];
|
||||
const transformNodeTag = transformNodeCreateCall[0];
|
||||
const transformNodeCreateInvocationOrder =
|
||||
createCallOrder[transformNodeCreateCallIndex];
|
||||
|
||||
const value1TransformConnectCallIndex = connectCalls.findIndex(
|
||||
call => call[0] === value1NodeTag && call[1] === transformNodeTag,
|
||||
);
|
||||
const value1TransformConnectInvocationOrder =
|
||||
connectCallOrder[value1TransformConnectCallIndex];
|
||||
|
||||
expect(value1NodeCreateInvocationOrder).toBeLessThan(
|
||||
value1TransformConnectInvocationOrder,
|
||||
);
|
||||
expect(transformNodeCreateInvocationOrder).toBeLessThan(
|
||||
value1TransformConnectInvocationOrder,
|
||||
);
|
||||
|
||||
// Second value node and transform node should both be created before they are connected
|
||||
const value2NodeCreateCall = createCalls[valueNodeCreateCallIndices[1]];
|
||||
const value2NodeTag = value2NodeCreateCall[0];
|
||||
const value2NodeCreateInvocationOrder =
|
||||
createCallOrder[valueNodeCreateCallIndices[1]];
|
||||
|
||||
const value2TransformConnectCallIndex = connectCalls.findIndex(
|
||||
call => call[0] === value2NodeTag && call[1] === transformNodeTag,
|
||||
);
|
||||
const value2TransformConnectInvocationOrder =
|
||||
connectCallOrder[value2TransformConnectCallIndex];
|
||||
|
||||
expect(value2NodeCreateInvocationOrder).toBeLessThan(
|
||||
value2TransformConnectInvocationOrder,
|
||||
);
|
||||
expect(transformNodeCreateInvocationOrder).toBeLessThan(
|
||||
value2TransformConnectInvocationOrder,
|
||||
);
|
||||
|
||||
// Transform node and style node should both be created before they are connected
|
||||
const styleNodeCreateCallIndex = createCalls.findIndex(
|
||||
call => call[1].type === 'style',
|
||||
);
|
||||
const styleNodeCreateCall = createCalls[styleNodeCreateCallIndex];
|
||||
const styleNodeTag = styleNodeCreateCall[0];
|
||||
const styleNodeCreateInvocationOrder =
|
||||
createCallOrder[styleNodeCreateCallIndex];
|
||||
|
||||
const transformStyleConnectCallIndex = connectCalls.findIndex(
|
||||
call => call[0] === transformNodeTag && call[1] === styleNodeTag,
|
||||
);
|
||||
const transformStyleConnectInvocationOrder =
|
||||
connectCallOrder[transformStyleConnectCallIndex];
|
||||
|
||||
expect(transformNodeCreateInvocationOrder).toBeLessThan(
|
||||
transformStyleConnectInvocationOrder,
|
||||
);
|
||||
expect(styleNodeCreateInvocationOrder).toBeLessThan(
|
||||
transformStyleConnectInvocationOrder,
|
||||
);
|
||||
|
||||
// Style node and props node should both be created before they are connected
|
||||
const propsNodeCreateCallIndex = createCalls.findIndex(
|
||||
call => call[1].type === 'props',
|
||||
);
|
||||
const propsNodeCreateCall = createCalls[propsNodeCreateCallIndex];
|
||||
const propsNodeTag = propsNodeCreateCall[0];
|
||||
const propsNodeCreateInvocationOrder =
|
||||
createCallOrder[propsNodeCreateCallIndex];
|
||||
|
||||
const stylePropsConnectCallIndex = connectCalls.findIndex(
|
||||
call => call[0] === styleNodeTag && call[1] === propsNodeTag,
|
||||
);
|
||||
const stylePropsConnectInvocationOrder =
|
||||
connectCallOrder[stylePropsConnectCallIndex];
|
||||
|
||||
expect(styleNodeCreateInvocationOrder).toBeLessThan(
|
||||
stylePropsConnectInvocationOrder,
|
||||
);
|
||||
expect(propsNodeCreateInvocationOrder).toBeLessThan(
|
||||
stylePropsConnectInvocationOrder,
|
||||
);
|
||||
});
|
||||
|
||||
it('sends create operations before connect operations for multiple animated props', () => {
|
||||
const propA = new Animated.Value(0);
|
||||
const propB = new Animated.Value(0);
|
||||
TestRenderer.create(<Animated.View propA={propA} propB={propB} />);
|
||||
|
||||
Animated.timing(propA, {
|
||||
toValue: 10,
|
||||
duration: 1000,
|
||||
useNativeDriver: true,
|
||||
}).start();
|
||||
|
||||
const createCalls = NativeAnimatedModule.createAnimatedNode.mock.calls;
|
||||
const createCallOrder =
|
||||
NativeAnimatedModule.createAnimatedNode.mock.invocationCallOrder;
|
||||
const connectCalls = NativeAnimatedModule.connectAnimatedNodes.mock.calls;
|
||||
const connectCallOrder =
|
||||
NativeAnimatedModule.connectAnimatedNodes.mock.invocationCallOrder;
|
||||
|
||||
// First value node and props node should both be created before they are connected
|
||||
const valueNodeCreateCallIndices = createCalls.reduce(
|
||||
(acc, call, index) => {
|
||||
call[1].type === 'value' && acc.push(index);
|
||||
return acc;
|
||||
},
|
||||
[],
|
||||
);
|
||||
const value1NodeCreateCall = createCalls[valueNodeCreateCallIndices[0]];
|
||||
const value1NodeTag = value1NodeCreateCall[0];
|
||||
const value1NodeCreateInvocationOrder =
|
||||
createCallOrder[valueNodeCreateCallIndices[0]];
|
||||
|
||||
const propsNodeCreateCallIndex = createCalls.findIndex(
|
||||
call => call[1].type === 'props',
|
||||
);
|
||||
const propsNodeCreateCall = createCalls[propsNodeCreateCallIndex];
|
||||
const propsNodeTag = propsNodeCreateCall[0];
|
||||
const propsNodeCreateInvocationOrder =
|
||||
createCallOrder[propsNodeCreateCallIndex];
|
||||
|
||||
const value1PropsConnectCallIndex = connectCalls.findIndex(
|
||||
call => call[0] === value1NodeTag && call[1] === propsNodeTag,
|
||||
);
|
||||
const value1PropsConnectInvocationOrder =
|
||||
connectCallOrder[value1PropsConnectCallIndex];
|
||||
|
||||
expect(value1NodeCreateInvocationOrder).toBeLessThan(
|
||||
value1PropsConnectInvocationOrder,
|
||||
);
|
||||
expect(propsNodeCreateInvocationOrder).toBeLessThan(
|
||||
value1PropsConnectInvocationOrder,
|
||||
);
|
||||
|
||||
// Second value node and props node should both be created before they are connected
|
||||
const value2NodeCreateCall = createCalls[valueNodeCreateCallIndices[1]];
|
||||
const value2NodeTag = value2NodeCreateCall[0];
|
||||
const value2NodeCreateInvocationOrder =
|
||||
createCallOrder[valueNodeCreateCallIndices[1]];
|
||||
|
||||
const value2PropsConnectCallIndex = connectCalls.findIndex(
|
||||
call => call[0] === value2NodeTag && call[1] === propsNodeTag,
|
||||
);
|
||||
const value2PropsConnectInvocationOrder =
|
||||
connectCallOrder[value2PropsConnectCallIndex];
|
||||
|
||||
expect(value2NodeCreateInvocationOrder).toBeLessThan(
|
||||
value2PropsConnectInvocationOrder,
|
||||
);
|
||||
expect(propsNodeCreateInvocationOrder).toBeLessThan(
|
||||
value2PropsConnectInvocationOrder,
|
||||
);
|
||||
});
|
||||
|
||||
it('sends a valid graph description for Animated.diffClamp nodes', () => {
|
||||
const value = new Animated.Value(2);
|
||||
value.__makeNative();
|
||||
+42
-78
@@ -13,21 +13,9 @@
|
||||
import Easing from '../Easing';
|
||||
import AnimatedInterpolation from '../nodes/AnimatedInterpolation';
|
||||
|
||||
function createInterpolation(config) {
|
||||
let parentValue = null;
|
||||
const interpolation = new AnimatedInterpolation(
|
||||
{__getValue: () => parentValue},
|
||||
config,
|
||||
);
|
||||
return input => {
|
||||
parentValue = input;
|
||||
return interpolation.__getValue();
|
||||
};
|
||||
}
|
||||
|
||||
describe('Interpolation', () => {
|
||||
it('should work with defaults', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: [0, 1],
|
||||
});
|
||||
@@ -39,7 +27,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should work with output range', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: [100, 200],
|
||||
});
|
||||
@@ -51,7 +39,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should work with input range', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [100, 200],
|
||||
outputRange: [0, 1],
|
||||
});
|
||||
@@ -63,25 +51,23 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should throw for non monotonic input ranges', () => {
|
||||
expect(
|
||||
() =>
|
||||
new AnimatedInterpolation(null, {
|
||||
inputRange: [0, 2, 1],
|
||||
outputRange: [0, 1, 2],
|
||||
}),
|
||||
expect(() =>
|
||||
AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 2, 1],
|
||||
outputRange: [0, 1, 2],
|
||||
}),
|
||||
).toThrow();
|
||||
|
||||
expect(
|
||||
() =>
|
||||
new AnimatedInterpolation(null, {
|
||||
inputRange: [0, 1, 2],
|
||||
outputRange: [0, 3, 1],
|
||||
}),
|
||||
expect(() =>
|
||||
AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1, 2],
|
||||
outputRange: [0, 3, 1],
|
||||
}),
|
||||
).not.toThrow();
|
||||
});
|
||||
|
||||
it('should work with empty input range', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 10, 10],
|
||||
outputRange: [1, 2, 3],
|
||||
extrapolate: 'extend',
|
||||
@@ -95,7 +81,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should work with empty output range', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [1, 2, 3],
|
||||
outputRange: [0, 10, 10],
|
||||
extrapolate: 'extend',
|
||||
@@ -110,7 +96,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should work with easing', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: [0, 1],
|
||||
easing: Easing.quad,
|
||||
@@ -123,7 +109,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should work with extrapolate', () => {
|
||||
let interpolation = createInterpolation({
|
||||
let interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: [0, 1],
|
||||
extrapolate: 'extend',
|
||||
@@ -133,7 +119,7 @@ describe('Interpolation', () => {
|
||||
expect(interpolation(-2)).toBe(4);
|
||||
expect(interpolation(2)).toBe(4);
|
||||
|
||||
interpolation = createInterpolation({
|
||||
interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: [0, 1],
|
||||
extrapolate: 'clamp',
|
||||
@@ -143,7 +129,7 @@ describe('Interpolation', () => {
|
||||
expect(interpolation(-2)).toBe(0);
|
||||
expect(interpolation(2)).toBe(1);
|
||||
|
||||
interpolation = createInterpolation({
|
||||
interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: [0, 1],
|
||||
extrapolate: 'identity',
|
||||
@@ -155,7 +141,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should work with keyframes with extrapolate', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 10, 100, 1000],
|
||||
outputRange: [0, 5, 50, 500],
|
||||
extrapolate: true,
|
||||
@@ -173,7 +159,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should work with keyframes without extrapolate', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1, 2],
|
||||
outputRange: [0.2, 1, 0.2],
|
||||
extrapolate: 'clamp',
|
||||
@@ -183,25 +169,23 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should throw for an infinite input range', () => {
|
||||
expect(
|
||||
() =>
|
||||
new AnimatedInterpolation(null, {
|
||||
inputRange: [-Infinity, Infinity],
|
||||
outputRange: [0, 1],
|
||||
}),
|
||||
expect(() =>
|
||||
AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [-Infinity, Infinity],
|
||||
outputRange: [0, 1],
|
||||
}),
|
||||
).toThrow();
|
||||
|
||||
expect(
|
||||
() =>
|
||||
new AnimatedInterpolation(null, {
|
||||
inputRange: [-Infinity, 0, Infinity],
|
||||
outputRange: [1, 2, 3],
|
||||
}),
|
||||
expect(() =>
|
||||
AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [-Infinity, 0, Infinity],
|
||||
outputRange: [1, 2, 3],
|
||||
}),
|
||||
).not.toThrow();
|
||||
});
|
||||
|
||||
it('should work with negative infinite', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [-Infinity, 0],
|
||||
outputRange: [-Infinity, 0],
|
||||
easing: Easing.quad,
|
||||
@@ -217,7 +201,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should work with positive infinite', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [5, Infinity],
|
||||
outputRange: [5, Infinity],
|
||||
easing: Easing.quad,
|
||||
@@ -235,7 +219,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should work with output ranges as string', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: ['rgba(0, 100, 200, 0)', 'rgba(50, 150, 250, 0.4)'],
|
||||
});
|
||||
@@ -246,7 +230,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should work with output ranges as short hex string', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: ['#024', '#9BF'],
|
||||
});
|
||||
@@ -257,7 +241,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should work with output ranges as long hex string', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: ['#FF9500', '#87FC70'],
|
||||
});
|
||||
@@ -268,7 +252,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should work with output ranges with mixed hex and rgba strings', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: ['rgba(100, 120, 140, .4)', '#87FC70'],
|
||||
});
|
||||
@@ -279,7 +263,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should work with negative and decimal values in string ranges', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: ['-100.5deg', '100deg'],
|
||||
});
|
||||
@@ -290,7 +274,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should crash when chaining an interpolation that returns a string', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: [0, 1],
|
||||
});
|
||||
@@ -300,7 +284,7 @@ describe('Interpolation', () => {
|
||||
});
|
||||
|
||||
it('should support a mix of color patterns', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1, 2],
|
||||
outputRange: ['rgba(0, 100, 200, 0)', 'rgb(50, 150, 250)', 'red'],
|
||||
});
|
||||
@@ -313,35 +297,15 @@ describe('Interpolation', () => {
|
||||
|
||||
it('should crash when defining output range with different pattern', () => {
|
||||
expect(() =>
|
||||
createInterpolation({
|
||||
AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: ['20deg', '30rad'],
|
||||
}),
|
||||
).toThrow();
|
||||
});
|
||||
|
||||
it('should interpolate values with arbitrary suffixes', () => {
|
||||
const interpolation = createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: ['-10foo', '10foo'],
|
||||
});
|
||||
|
||||
expect(interpolation(0)).toBe('-10foo');
|
||||
expect(interpolation(0.5)).toBe('0foo');
|
||||
});
|
||||
|
||||
it('should interpolate numeric values of arbitrary format', () => {
|
||||
const interpolation = createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: ['M20,20L20,80L80,80L80,20Z', 'M40,40L33,60L60,60L65,40Z'],
|
||||
});
|
||||
|
||||
expect(interpolation(0)).toBe('M20,20L20,80L80,80L80,20Z');
|
||||
expect(interpolation(0.5)).toBe('M30,30L26.5,70L70,70L72.5,30Z');
|
||||
});
|
||||
|
||||
it('should round the alpha channel of a color to the nearest thousandth', () => {
|
||||
const interpolation = createInterpolation({
|
||||
const interpolation = AnimatedInterpolation.__createInterpolation({
|
||||
inputRange: [0, 1],
|
||||
outputRange: ['rgba(0, 0, 0, 0)', 'rgba(0, 0, 0, 1)'],
|
||||
});
|
||||
@@ -0,0 +1,68 @@
|
||||
/**
|
||||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @flow strict-local
|
||||
* @format
|
||||
* @oncall react_native
|
||||
*/
|
||||
|
||||
'use strict';
|
||||
|
||||
import * as React from 'react';
|
||||
|
||||
const createAnimatedComponent = require('../createAnimatedComponent').default;
|
||||
const createAnimatedComponentInjection = require('../createAnimatedComponentInjection');
|
||||
|
||||
function injected<TProps: {...}, TInstance>(
|
||||
Component: React.AbstractComponent<TProps, TInstance>,
|
||||
): React.AbstractComponent<TProps, TInstance> {
|
||||
return createAnimatedComponent(Component);
|
||||
}
|
||||
|
||||
beforeEach(() => {
|
||||
jest.resetModules();
|
||||
jest.resetAllMocks();
|
||||
});
|
||||
|
||||
test('does nothing without injection', () => {
|
||||
expect(typeof createAnimatedComponent).toBe('function');
|
||||
expect(createAnimatedComponent).not.toBe(injected);
|
||||
});
|
||||
|
||||
test('injection overrides `createAnimatedComponent`', () => {
|
||||
createAnimatedComponentInjection.inject(injected);
|
||||
|
||||
expect(createAnimatedComponent).toBe(injected);
|
||||
});
|
||||
|
||||
test('injection errors if called too late', () => {
|
||||
jest.spyOn(console, 'error').mockReturnValue(undefined);
|
||||
|
||||
// Causes `createAnimatedComponent` to be initialized.
|
||||
createAnimatedComponent;
|
||||
|
||||
createAnimatedComponentInjection.inject(injected);
|
||||
|
||||
expect(createAnimatedComponent).not.toBe(injected);
|
||||
expect(console.error).toBeCalledWith(
|
||||
'createAnimatedComponentInjection: Must be called before `createAnimatedComponent`.',
|
||||
);
|
||||
});
|
||||
|
||||
test('injection errors if called more than once', () => {
|
||||
jest.spyOn(console, 'error').mockReturnValue(undefined);
|
||||
|
||||
createAnimatedComponentInjection.inject(injected);
|
||||
|
||||
expect(createAnimatedComponent).toBe(injected);
|
||||
expect(console.error).not.toBeCalled();
|
||||
|
||||
createAnimatedComponentInjection.inject(injected);
|
||||
|
||||
expect(console.error).toBeCalledWith(
|
||||
'createAnimatedComponentInjection: Cannot be called more than once.',
|
||||
);
|
||||
});
|
||||
@@ -105,7 +105,7 @@ export default function bezier(
|
||||
// Precompute samples table
|
||||
const sampleValues = float32ArraySupported
|
||||
? new Float32Array(kSplineTableSize)
|
||||
: new Array<number>(kSplineTableSize);
|
||||
: new Array(kSplineTableSize);
|
||||
if (mX1 !== mY1 || mX2 !== mY2) {
|
||||
for (let i = 0; i < kSplineTableSize; ++i) {
|
||||
sampleValues[i] = calcBezier(i * kSampleStepSize, mX1, mX2);
|
||||
+3
-8
@@ -17,14 +17,9 @@ import * as React from 'react';
|
||||
/**
|
||||
* @see https://github.com/facebook/react-native/commit/b8c8562
|
||||
*/
|
||||
const FlatListWithEventThrottle = React.forwardRef(
|
||||
(
|
||||
props: React.ElementConfig<typeof FlatList>,
|
||||
ref:
|
||||
| ((null | FlatList<mixed>) => mixed)
|
||||
| {current: null | FlatList<mixed>, ...},
|
||||
) => <FlatList scrollEventThrottle={0.0001} {...props} ref={ref} />,
|
||||
);
|
||||
const FlatListWithEventThrottle = React.forwardRef((props, ref) => (
|
||||
<FlatList scrollEventThrottle={0.0001} {...props} ref={ref} />
|
||||
));
|
||||
|
||||
export default (createAnimatedComponent(
|
||||
FlatListWithEventThrottle,
|
||||
+1
-4
@@ -67,15 +67,12 @@ const AnimatedScrollViewWithInvertedRefreshControl = React.forwardRef(
|
||||
// $FlowFixMe[unclear-type] Same Flow type as `refreshControl` in ScrollView
|
||||
refreshControl: React.Element<any>,
|
||||
},
|
||||
forwardedRef:
|
||||
| {current: Instance | null, ...}
|
||||
| ((Instance | null) => mixed),
|
||||
forwardedRef,
|
||||
) => {
|
||||
// Split `props` into the animate-able props for the parent (RefreshControl)
|
||||
// and child (ScrollView).
|
||||
const {intermediatePropsForRefreshControl, intermediatePropsForScrollView} =
|
||||
useMemo(() => {
|
||||
// $FlowFixMe[underconstrained-implicit-instantiation]
|
||||
const {outer, inner} = splitLayoutProps(flattenStyle(props.style));
|
||||
return {
|
||||
intermediatePropsForRefreshControl: {style: outer},
|
||||
+3
-12
@@ -8,7 +8,6 @@
|
||||
* @format
|
||||
*/
|
||||
|
||||
import type {SectionBase} from '../../Lists/SectionList';
|
||||
import type {AnimatedComponentType} from '../createAnimatedComponent';
|
||||
|
||||
import SectionList from '../../Lists/SectionList';
|
||||
@@ -18,17 +17,9 @@ import * as React from 'react';
|
||||
/**
|
||||
* @see https://github.com/facebook/react-native/commit/b8c8562
|
||||
*/
|
||||
const SectionListWithEventThrottle = React.forwardRef(
|
||||
(
|
||||
props: React.ElementConfig<typeof SectionList>,
|
||||
ref:
|
||||
| ((null | SectionList<SectionBase<$FlowFixMe>>) => mixed)
|
||||
| {
|
||||
current: null | SectionList<SectionBase<$FlowFixMe>>,
|
||||
...
|
||||
},
|
||||
) => <SectionList scrollEventThrottle={0.0001} {...props} ref={ref} />,
|
||||
);
|
||||
const SectionListWithEventThrottle = React.forwardRef((props, ref) => (
|
||||
<SectionList scrollEventThrottle={0.0001} {...props} ref={ref} />
|
||||
));
|
||||
|
||||
export default (createAnimatedComponent(
|
||||
SectionListWithEventThrottle,
|
||||
@@ -0,0 +1,274 @@
|
||||
/**
|
||||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @flow
|
||||
* @format
|
||||
*/
|
||||
|
||||
'use strict';
|
||||
|
||||
import View from '../Components/View/View';
|
||||
import setAndForwardRef from '../Utilities/setAndForwardRef';
|
||||
import {AnimatedEvent} from './AnimatedEvent';
|
||||
import * as createAnimatedComponentInjection from './createAnimatedComponentInjection';
|
||||
import NativeAnimatedHelper from './NativeAnimatedHelper';
|
||||
import AnimatedProps from './nodes/AnimatedProps';
|
||||
import invariant from 'invariant';
|
||||
import * as React from 'react';
|
||||
|
||||
let animatedComponentNextId = 1;
|
||||
|
||||
export type AnimatedComponentType<
|
||||
-Props: {+[string]: mixed, ...},
|
||||
+Instance = mixed,
|
||||
> = React.AbstractComponent<
|
||||
$ObjMap<
|
||||
Props &
|
||||
$ReadOnly<{
|
||||
passthroughAnimatedPropExplicitValues?: React.ElementConfig<
|
||||
typeof View,
|
||||
>,
|
||||
}>,
|
||||
() => any,
|
||||
>,
|
||||
Instance,
|
||||
>;
|
||||
|
||||
function createAnimatedComponent<Props: {+[string]: mixed, ...}, Instance>(
|
||||
Component: React.AbstractComponent<Props, Instance>,
|
||||
): AnimatedComponentType<Props, Instance> {
|
||||
invariant(
|
||||
typeof Component !== 'function' ||
|
||||
(Component.prototype && Component.prototype.isReactComponent),
|
||||
'`createAnimatedComponent` does not support stateless functional components; ' +
|
||||
'use a class component instead.',
|
||||
);
|
||||
|
||||
class AnimatedComponent extends React.Component<Object> {
|
||||
_component: any; // TODO T53738161: flow type this, and the whole file
|
||||
_invokeAnimatedPropsCallbackOnMount: boolean = false;
|
||||
_prevComponent: any;
|
||||
_propsAnimated: AnimatedProps;
|
||||
_eventDetachers: Array<Function> = [];
|
||||
|
||||
// Only to be used in this file, and only in Fabric.
|
||||
_animatedComponentId: string = `${animatedComponentNextId++}:animatedComponent`;
|
||||
|
||||
_attachNativeEvents() {
|
||||
// Make sure to get the scrollable node for components that implement
|
||||
// `ScrollResponder.Mixin`.
|
||||
const scrollableNode = this._component?.getScrollableNode
|
||||
? this._component.getScrollableNode()
|
||||
: this._component;
|
||||
|
||||
for (const key in this.props) {
|
||||
const prop = this.props[key];
|
||||
if (prop instanceof AnimatedEvent && prop.__isNative) {
|
||||
prop.__attach(scrollableNode, key);
|
||||
this._eventDetachers.push(() => prop.__detach(scrollableNode, key));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
_detachNativeEvents() {
|
||||
this._eventDetachers.forEach(remove => remove());
|
||||
this._eventDetachers = [];
|
||||
}
|
||||
|
||||
_isFabric = (): boolean => {
|
||||
// When called during the first render, `_component` is always null.
|
||||
// Therefore, even if a component is rendered in Fabric, we can't detect
|
||||
// that until ref is set, which happens sometime after the first render.
|
||||
// In cases where this value switching between "false" and "true" on Fabric
|
||||
// causes issues, add an additional check for _component nullity.
|
||||
if (this._component == null) {
|
||||
return false;
|
||||
}
|
||||
return (
|
||||
// eslint-disable-next-line dot-notation
|
||||
this._component['_internalInstanceHandle']?.stateNode?.canonical !=
|
||||
null ||
|
||||
// Some components have a setNativeProps function but aren't a host component
|
||||
// such as lists like FlatList and SectionList. These should also use
|
||||
// forceUpdate in Fabric since setNativeProps doesn't exist on the underlying
|
||||
// host component. This crazy hack is essentially special casing those lists and
|
||||
// ScrollView itself to use forceUpdate in Fabric.
|
||||
// If these components end up using forwardRef then these hacks can go away
|
||||
// as this._component would actually be the underlying host component and the above check
|
||||
// would be sufficient.
|
||||
(this._component.getNativeScrollRef != null &&
|
||||
this._component.getNativeScrollRef() != null &&
|
||||
// eslint-disable-next-line dot-notation
|
||||
this._component.getNativeScrollRef()['_internalInstanceHandle']
|
||||
?.stateNode?.canonical != null) ||
|
||||
(this._component.getScrollResponder != null &&
|
||||
this._component.getScrollResponder() != null &&
|
||||
this._component.getScrollResponder().getNativeScrollRef != null &&
|
||||
this._component.getScrollResponder().getNativeScrollRef() != null &&
|
||||
this._component.getScrollResponder().getNativeScrollRef()[
|
||||
// eslint-disable-next-line dot-notation
|
||||
'_internalInstanceHandle'
|
||||
]?.stateNode?.canonical != null)
|
||||
);
|
||||
};
|
||||
|
||||
_waitForUpdate = (): void => {
|
||||
if (this._isFabric()) {
|
||||
NativeAnimatedHelper.API.setWaitingForIdentifier(
|
||||
this._animatedComponentId,
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
_markUpdateComplete = (): void => {
|
||||
if (this._isFabric()) {
|
||||
NativeAnimatedHelper.API.unsetWaitingForIdentifier(
|
||||
this._animatedComponentId,
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
// The system is best designed when setNativeProps is implemented. It is
|
||||
// able to avoid re-rendering and directly set the attributes that changed.
|
||||
// However, setNativeProps can only be implemented on leaf native
|
||||
// components. If you want to animate a composite component, you need to
|
||||
// re-render it. In this case, we have a fallback that uses forceUpdate.
|
||||
// This fallback is also called in Fabric.
|
||||
_animatedPropsCallback = (): void => {
|
||||
if (this._component == null) {
|
||||
// AnimatedProps is created in will-mount because it's used in render.
|
||||
// But this callback may be invoked before mount in async mode,
|
||||
// In which case we should defer the setNativeProps() call.
|
||||
// React may throw away uncommitted work in async mode,
|
||||
// So a deferred call won't always be invoked.
|
||||
this._invokeAnimatedPropsCallbackOnMount = true;
|
||||
} else if (
|
||||
process.env.NODE_ENV === 'test' ||
|
||||
// For animating properties of non-leaf/non-native components
|
||||
typeof this._component.setNativeProps !== 'function' ||
|
||||
// In Fabric, force animations to go through forceUpdate and skip setNativeProps
|
||||
this._isFabric()
|
||||
) {
|
||||
this.forceUpdate();
|
||||
} else if (!this._propsAnimated.__isNative) {
|
||||
this._component.setNativeProps(
|
||||
this._propsAnimated.__getAnimatedValue(),
|
||||
);
|
||||
} else {
|
||||
throw new Error(
|
||||
'Attempting to run JS driven animation on animated ' +
|
||||
'node that has been moved to "native" earlier by starting an ' +
|
||||
'animation with `useNativeDriver: true`',
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
_attachProps(nextProps: any) {
|
||||
const oldPropsAnimated = this._propsAnimated;
|
||||
|
||||
this._propsAnimated = new AnimatedProps(
|
||||
nextProps,
|
||||
this._animatedPropsCallback,
|
||||
);
|
||||
this._propsAnimated.__attach();
|
||||
|
||||
// When you call detach, it removes the element from the parent list
|
||||
// of children. If it goes to 0, then the parent also detaches itself
|
||||
// and so on.
|
||||
// An optimization is to attach the new elements and THEN detach the old
|
||||
// ones instead of detaching and THEN attaching.
|
||||
// This way the intermediate state isn't to go to 0 and trigger
|
||||
// this expensive recursive detaching to then re-attach everything on
|
||||
// the very next operation.
|
||||
if (oldPropsAnimated) {
|
||||
oldPropsAnimated.__restoreDefaultValues();
|
||||
oldPropsAnimated.__detach();
|
||||
}
|
||||
}
|
||||
|
||||
_setComponentRef: (ref: React.ElementRef<any>) => void = setAndForwardRef({
|
||||
getForwardedRef: () => this.props.forwardedRef,
|
||||
setLocalRef: ref => {
|
||||
this._prevComponent = this._component;
|
||||
this._component = ref;
|
||||
},
|
||||
});
|
||||
|
||||
render(): React.Node {
|
||||
const animatedProps = this._propsAnimated.__getValue() || {};
|
||||
|
||||
const {style = {}, ...props} = animatedProps;
|
||||
const {style: passthruStyle = {}, ...passthruProps} =
|
||||
this.props.passthroughAnimatedPropExplicitValues || {};
|
||||
const mergedStyle = {...style, ...passthruStyle};
|
||||
|
||||
// Force `collapsable` to be false so that native view is not flattened.
|
||||
// Flattened views cannot be accurately referenced by a native driver.
|
||||
return (
|
||||
<Component
|
||||
{...props}
|
||||
{...passthruProps}
|
||||
collapsable={false}
|
||||
style={mergedStyle}
|
||||
ref={this._setComponentRef}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
UNSAFE_componentWillMount() {
|
||||
this._waitForUpdate();
|
||||
this._attachProps(this.props);
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
if (this._invokeAnimatedPropsCallbackOnMount) {
|
||||
this._invokeAnimatedPropsCallbackOnMount = false;
|
||||
this._animatedPropsCallback();
|
||||
}
|
||||
|
||||
this._propsAnimated.setNativeView(this._component);
|
||||
this._attachNativeEvents();
|
||||
this._markUpdateComplete();
|
||||
}
|
||||
|
||||
UNSAFE_componentWillReceiveProps(newProps: any) {
|
||||
this._waitForUpdate();
|
||||
this._attachProps(newProps);
|
||||
}
|
||||
|
||||
componentDidUpdate(prevProps: any) {
|
||||
if (this._component !== this._prevComponent) {
|
||||
this._propsAnimated.setNativeView(this._component);
|
||||
}
|
||||
if (this._component !== this._prevComponent || prevProps !== this.props) {
|
||||
this._detachNativeEvents();
|
||||
this._attachNativeEvents();
|
||||
}
|
||||
this._markUpdateComplete();
|
||||
}
|
||||
|
||||
componentWillUnmount() {
|
||||
this._propsAnimated && this._propsAnimated.__detach();
|
||||
this._detachNativeEvents();
|
||||
this._markUpdateComplete();
|
||||
this._component = null;
|
||||
this._prevComponent = null;
|
||||
}
|
||||
}
|
||||
|
||||
return React.forwardRef(function AnimatedComponentWrapper(props, ref) {
|
||||
return (
|
||||
<AnimatedComponent
|
||||
{...props}
|
||||
{...(ref == null ? null : {forwardedRef: ref})}
|
||||
/>
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
// $FlowIgnore[incompatible-cast] - Will be compatible after refactors.
|
||||
export default (createAnimatedComponentInjection.recordAndRetrieve() ??
|
||||
createAnimatedComponent: typeof createAnimatedComponent);
|
||||
@@ -0,0 +1,48 @@
|
||||
/**
|
||||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @flow strict-local
|
||||
* @format
|
||||
*/
|
||||
|
||||
import * as React from 'react';
|
||||
|
||||
type createAnimatedComponent = <TProps: {...}, TInstance>(
|
||||
Component: React.AbstractComponent<TProps, TInstance>,
|
||||
) => React.AbstractComponent<TProps, TInstance>;
|
||||
|
||||
// This can be undefined, null, or the experimental implementation. If this is
|
||||
// null, that means `createAnimatedComponent` has already been initialized and
|
||||
// it is too late to call `inject`.
|
||||
let injected: ?createAnimatedComponent;
|
||||
|
||||
/**
|
||||
* Call during bundle initialization to opt-in to new `createAnimatedComponent`.
|
||||
*/
|
||||
export function inject(newInjected: createAnimatedComponent): void {
|
||||
if (injected !== undefined) {
|
||||
if (__DEV__) {
|
||||
console.error(
|
||||
'createAnimatedComponentInjection: ' +
|
||||
(injected == null
|
||||
? 'Must be called before `createAnimatedComponent`.'
|
||||
: 'Cannot be called more than once.'),
|
||||
);
|
||||
}
|
||||
return;
|
||||
}
|
||||
injected = newInjected;
|
||||
}
|
||||
|
||||
/**
|
||||
* Only called by `createAnimatedComponent.js`.
|
||||
*/
|
||||
export function recordAndRetrieve(): createAnimatedComponent | null {
|
||||
if (injected === undefined) {
|
||||
injected = null;
|
||||
}
|
||||
return injected;
|
||||
}
|
||||
+8
-21
@@ -4,37 +4,24 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @flow
|
||||
* @flow strict-local
|
||||
* @format
|
||||
*/
|
||||
|
||||
import View from '../Components/View/View';
|
||||
import StyleSheet from '../StyleSheet/StyleSheet';
|
||||
import useMergeRefs from '../Utilities/useMergeRefs';
|
||||
import useAnimatedProps from './useAnimatedProps';
|
||||
import * as React from 'react';
|
||||
|
||||
export type AnimatedComponentType<
|
||||
-Props: {+[string]: mixed, ...},
|
||||
+Instance = mixed,
|
||||
> = React.AbstractComponent<
|
||||
$ObjMap<
|
||||
Props &
|
||||
$ReadOnly<{
|
||||
passthroughAnimatedPropExplicitValues?: React.ElementConfig<
|
||||
typeof View,
|
||||
>,
|
||||
}>,
|
||||
() => any,
|
||||
>,
|
||||
Instance,
|
||||
>;
|
||||
|
||||
/**
|
||||
* Experimental implementation of `createAnimatedComponent` that is intended to
|
||||
* be compatible with concurrent rendering.
|
||||
*/
|
||||
export default function createAnimatedComponent<TProps: {...}, TInstance>(
|
||||
Component: React.AbstractComponent<TProps, TInstance>,
|
||||
): AnimatedComponentType<TProps, TInstance> {
|
||||
): React.AbstractComponent<TProps, TInstance> {
|
||||
return React.forwardRef((props, forwardedRef) => {
|
||||
const [reducedProps, callbackRef] = useAnimatedProps<TProps, TInstance>(
|
||||
// $FlowFixMe[incompatible-call]
|
||||
props,
|
||||
);
|
||||
const ref = useMergeRefs<TInstance | null>(callbackRef, forwardedRef);
|
||||
@@ -47,7 +34,7 @@ export default function createAnimatedComponent<TProps: {...}, TInstance>(
|
||||
const {passthroughAnimatedPropExplicitValues, style} = reducedProps;
|
||||
const {style: passthroughStyle, ...passthroughProps} =
|
||||
passthroughAnimatedPropExplicitValues ?? {};
|
||||
const mergedStyle = {...style, ...passthroughStyle};
|
||||
const mergedStyle = StyleSheet.compose(style, passthroughStyle);
|
||||
|
||||
return (
|
||||
<Component
|
||||
+79
-46
@@ -18,7 +18,7 @@ import type {PlatformConfig} from '../AnimatedPlatformConfig';
|
||||
import normalizeColor from '../../StyleSheet/normalizeColor';
|
||||
import {processColorObject} from '../../StyleSheet/PlatformColorValueTypes';
|
||||
import NativeAnimatedHelper from '../NativeAnimatedHelper';
|
||||
import AnimatedValue, {flushValue} from './AnimatedValue';
|
||||
import AnimatedValue from './AnimatedValue';
|
||||
import AnimatedWithChildren from './AnimatedWithChildren';
|
||||
|
||||
export type AnimatedColorConfig = $ReadOnly<{
|
||||
@@ -43,11 +43,10 @@ type RgbaAnimatedValue = {
|
||||
...
|
||||
};
|
||||
|
||||
export type InputValue = ?(RgbaValue | RgbaAnimatedValue | ColorValue);
|
||||
|
||||
const NativeAnimatedAPI = NativeAnimatedHelper.API;
|
||||
|
||||
const defaultColor: RgbaValue = {r: 0, g: 0, b: 0, a: 1.0};
|
||||
let _uniqueId = 1;
|
||||
|
||||
/* eslint no-bitwise: 0 */
|
||||
function processColor(
|
||||
@@ -114,12 +113,22 @@ export default class AnimatedColor extends AnimatedWithChildren {
|
||||
b: AnimatedValue;
|
||||
a: AnimatedValue;
|
||||
nativeColor: ?NativeColorValue;
|
||||
_listeners: {
|
||||
[key: string]: {
|
||||
r: string,
|
||||
g: string,
|
||||
b: string,
|
||||
a: string,
|
||||
...
|
||||
},
|
||||
...
|
||||
} = {};
|
||||
|
||||
_suspendCallbacks: number = 0;
|
||||
|
||||
constructor(valueIn?: InputValue, config?: ?AnimatedColorConfig) {
|
||||
constructor(
|
||||
valueIn?: ?(RgbaValue | RgbaAnimatedValue | ColorValue),
|
||||
config?: ?AnimatedColorConfig,
|
||||
) {
|
||||
super();
|
||||
|
||||
let value: RgbaValue | RgbaAnimatedValue | ColorValue =
|
||||
valueIn ?? defaultColor;
|
||||
if (isRgbaAnimatedValue(value)) {
|
||||
@@ -147,8 +156,7 @@ export default class AnimatedColor extends AnimatedWithChildren {
|
||||
this.b = new AnimatedValue(initColor.b);
|
||||
this.a = new AnimatedValue(initColor.a);
|
||||
}
|
||||
|
||||
if (config?.useNativeDriver) {
|
||||
if (this.nativeColor || (config && config.useNativeDriver)) {
|
||||
this.__makeNative();
|
||||
}
|
||||
}
|
||||
@@ -166,27 +174,25 @@ export default class AnimatedColor extends AnimatedWithChildren {
|
||||
|
||||
const processedColor: RgbaValue | NativeColorValue =
|
||||
processColor(value) ?? defaultColor;
|
||||
this._withSuspendedCallbacks(() => {
|
||||
if (isRgbaValue(processedColor)) {
|
||||
// $FlowIgnore[incompatible-type] - Type is verified above
|
||||
const rgbaValue: RgbaValue = processedColor;
|
||||
this.r.setValue(rgbaValue.r);
|
||||
this.g.setValue(rgbaValue.g);
|
||||
this.b.setValue(rgbaValue.b);
|
||||
this.a.setValue(rgbaValue.a);
|
||||
if (this.nativeColor != null) {
|
||||
this.nativeColor = null;
|
||||
shouldUpdateNodeConfig = true;
|
||||
}
|
||||
} else {
|
||||
// $FlowIgnore[incompatible-type] - Type is verified above
|
||||
const nativeColor: NativeColorValue = processedColor;
|
||||
if (this.nativeColor !== nativeColor) {
|
||||
this.nativeColor = nativeColor;
|
||||
shouldUpdateNodeConfig = true;
|
||||
}
|
||||
if (isRgbaValue(processedColor)) {
|
||||
// $FlowIgnore[incompatible-type] - Type is verified above
|
||||
const rgbaValue: RgbaValue = processedColor;
|
||||
this.r.setValue(rgbaValue.r);
|
||||
this.g.setValue(rgbaValue.g);
|
||||
this.b.setValue(rgbaValue.b);
|
||||
this.a.setValue(rgbaValue.a);
|
||||
if (this.nativeColor != null) {
|
||||
this.nativeColor = null;
|
||||
shouldUpdateNodeConfig = true;
|
||||
}
|
||||
});
|
||||
} else {
|
||||
// $FlowIgnore[incompatible-type] - Type is verified above
|
||||
const nativeColor: NativeColorValue = processedColor;
|
||||
if (this.nativeColor !== nativeColor) {
|
||||
this.nativeColor = nativeColor;
|
||||
shouldUpdateNodeConfig = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (this.__isNative) {
|
||||
const nativeTag = this.__getNativeTag();
|
||||
@@ -197,12 +203,7 @@ export default class AnimatedColor extends AnimatedWithChildren {
|
||||
);
|
||||
}
|
||||
NativeAnimatedAPI.unsetWaitingForIdentifier(nativeTag.toString());
|
||||
} else {
|
||||
flushValue(this);
|
||||
}
|
||||
|
||||
// $FlowFixMe[incompatible-call]
|
||||
this.__callListeners(this.__getValue());
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -239,6 +240,50 @@ export default class AnimatedColor extends AnimatedWithChildren {
|
||||
this.a.extractOffset();
|
||||
}
|
||||
|
||||
/**
|
||||
* Adds an asynchronous listener to the value so you can observe updates from
|
||||
* animations. This is useful because there is no way to synchronously read
|
||||
* the value because it might be driven natively.
|
||||
*
|
||||
* Returns a string that serves as an identifier for the listener.
|
||||
*/
|
||||
addListener(callback: ColorListenerCallback): string {
|
||||
const id = String(_uniqueId++);
|
||||
const jointCallback = ({value: number}: any) => {
|
||||
callback(this.__getValue());
|
||||
};
|
||||
this._listeners[id] = {
|
||||
r: this.r.addListener(jointCallback),
|
||||
g: this.g.addListener(jointCallback),
|
||||
b: this.b.addListener(jointCallback),
|
||||
a: this.a.addListener(jointCallback),
|
||||
};
|
||||
return id;
|
||||
}
|
||||
|
||||
/**
|
||||
* Unregister a listener. The `id` param shall match the identifier
|
||||
* previously returned by `addListener()`.
|
||||
*/
|
||||
removeListener(id: string): void {
|
||||
this.r.removeListener(this._listeners[id].r);
|
||||
this.g.removeListener(this._listeners[id].g);
|
||||
this.b.removeListener(this._listeners[id].b);
|
||||
this.a.removeListener(this._listeners[id].a);
|
||||
delete this._listeners[id];
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove all registered listeners.
|
||||
*/
|
||||
removeAllListeners(): void {
|
||||
this.r.removeAllListeners();
|
||||
this.g.removeAllListeners();
|
||||
this.b.removeAllListeners();
|
||||
this.a.removeAllListeners();
|
||||
this._listeners = {};
|
||||
}
|
||||
|
||||
/**
|
||||
* Stops any running animation or tracking. `callback` is invoked with the
|
||||
* final value after stopping the animation, which is useful for updating
|
||||
@@ -287,18 +332,6 @@ export default class AnimatedColor extends AnimatedWithChildren {
|
||||
super.__detach();
|
||||
}
|
||||
|
||||
_withSuspendedCallbacks(callback: () => void) {
|
||||
this._suspendCallbacks++;
|
||||
callback();
|
||||
this._suspendCallbacks--;
|
||||
}
|
||||
|
||||
__callListeners(value: number): void {
|
||||
if (this._suspendCallbacks === 0) {
|
||||
super.__callListeners(value);
|
||||
}
|
||||
}
|
||||
|
||||
__makeNative(platformConfig: ?PlatformConfig) {
|
||||
this.r.__makeNative(platformConfig);
|
||||
this.g.__makeNative(platformConfig);
|
||||
+121
-167
@@ -16,8 +16,6 @@ import type {PlatformConfig} from '../AnimatedPlatformConfig';
|
||||
import type AnimatedNode from './AnimatedNode';
|
||||
|
||||
import normalizeColor from '../../StyleSheet/normalizeColor';
|
||||
import processColor from '../../StyleSheet/processColor';
|
||||
import Easing from '../Easing';
|
||||
import NativeAnimatedHelper from '../NativeAnimatedHelper';
|
||||
import AnimatedWithChildren from './AnimatedWithChildren';
|
||||
import invariant from 'invariant';
|
||||
@@ -33,17 +31,39 @@ export type InterpolationConfigType<OutputT: number | string> = $ReadOnly<{
|
||||
extrapolateRight?: ExtrapolateType,
|
||||
}>;
|
||||
|
||||
const linear = (t: number) => t;
|
||||
|
||||
/**
|
||||
* Very handy helper to map input ranges to output ranges with an easing
|
||||
* function and custom behavior outside of the ranges.
|
||||
*/
|
||||
function createNumericInterpolation(
|
||||
config: InterpolationConfigType<number>,
|
||||
): (input: number) => number {
|
||||
function createInterpolation<OutputT: number | string>(
|
||||
config: InterpolationConfigType<OutputT>,
|
||||
): (input: number) => OutputT {
|
||||
if (config.outputRange && typeof config.outputRange[0] === 'string') {
|
||||
return (createInterpolationFromStringOutputRange((config: any)): any);
|
||||
}
|
||||
|
||||
const outputRange: $ReadOnlyArray<number> = (config.outputRange: any);
|
||||
|
||||
const inputRange = config.inputRange;
|
||||
|
||||
const easing = config.easing || Easing.linear;
|
||||
if (__DEV__) {
|
||||
checkInfiniteRange('outputRange', outputRange);
|
||||
checkInfiniteRange('inputRange', inputRange);
|
||||
checkValidInputRange(inputRange);
|
||||
|
||||
invariant(
|
||||
inputRange.length === outputRange.length,
|
||||
'inputRange (' +
|
||||
inputRange.length +
|
||||
') and outputRange (' +
|
||||
outputRange.length +
|
||||
') must have the same length',
|
||||
);
|
||||
}
|
||||
|
||||
const easing = config.easing || linear;
|
||||
|
||||
let extrapolateLeft: ExtrapolateType = 'extend';
|
||||
if (config.extrapolateLeft !== undefined) {
|
||||
@@ -147,49 +167,24 @@ function interpolate(
|
||||
return result;
|
||||
}
|
||||
|
||||
const numericComponentRegex = /[+-]?(?:\d+\.?\d*|\.\d+)(?:[eE][+-]?\d+)?/g;
|
||||
|
||||
// Maps string inputs an RGBA color or an array of numeric components
|
||||
function mapStringToNumericComponents(
|
||||
input: string,
|
||||
):
|
||||
| {isColor: true, components: [number, number, number, number]}
|
||||
| {isColor: false, components: $ReadOnlyArray<number | string>} {
|
||||
function colorToRgba(input: string): string {
|
||||
let normalizedColor = normalizeColor(input);
|
||||
invariant(
|
||||
normalizedColor == null || typeof normalizedColor !== 'object',
|
||||
'PlatformColors are not supported',
|
||||
);
|
||||
|
||||
if (typeof normalizedColor === 'number') {
|
||||
normalizedColor = normalizedColor || 0;
|
||||
const r = (normalizedColor & 0xff000000) >>> 24;
|
||||
const g = (normalizedColor & 0x00ff0000) >>> 16;
|
||||
const b = (normalizedColor & 0x0000ff00) >>> 8;
|
||||
const a = (normalizedColor & 0x000000ff) / 255;
|
||||
return {isColor: true, components: [r, g, b, a]};
|
||||
} else {
|
||||
const components: Array<string | number> = [];
|
||||
let lastMatchEnd = 0;
|
||||
let match: RegExp$matchResult;
|
||||
while ((match = (numericComponentRegex.exec(input): any)) != null) {
|
||||
if (match.index > lastMatchEnd) {
|
||||
components.push(input.substring(lastMatchEnd, match.index));
|
||||
}
|
||||
components.push(parseFloat(match[0]));
|
||||
lastMatchEnd = match.index + match[0].length;
|
||||
}
|
||||
invariant(
|
||||
components.length > 0,
|
||||
'outputRange must contain color or value with numeric component',
|
||||
);
|
||||
if (lastMatchEnd < input.length) {
|
||||
components.push(input.substring(lastMatchEnd, input.length));
|
||||
}
|
||||
return {isColor: false, components};
|
||||
if (normalizedColor === null || typeof normalizedColor !== 'number') {
|
||||
return input;
|
||||
}
|
||||
|
||||
normalizedColor = normalizedColor || 0;
|
||||
|
||||
const r = (normalizedColor & 0xff000000) >>> 24;
|
||||
const g = (normalizedColor & 0x00ff0000) >>> 16;
|
||||
const b = (normalizedColor & 0x0000ff00) >>> 8;
|
||||
const a = (normalizedColor & 0x000000ff) / 255;
|
||||
|
||||
return `rgba(${r}, ${g}, ${b}, ${a})`;
|
||||
}
|
||||
|
||||
const stringShapeRegex = /[+-]?(?:\d+\.?\d*|\.\d+)(?:[eE][+-]?\d+)?/g;
|
||||
|
||||
/**
|
||||
* Supports string shapes by extracting numbers so new values can be computed,
|
||||
* and recombines those values into new strings of the same shape. Supports
|
||||
@@ -198,69 +193,76 @@ function mapStringToNumericComponents(
|
||||
* rgba(123, 42, 99, 0.36) // colors
|
||||
* -45deg // values with units
|
||||
*/
|
||||
function createStringInterpolation(
|
||||
function createInterpolationFromStringOutputRange(
|
||||
config: InterpolationConfigType<string>,
|
||||
): (input: number) => string {
|
||||
invariant(config.outputRange.length >= 2, 'Bad output range');
|
||||
const outputRange = config.outputRange.map(mapStringToNumericComponents);
|
||||
let outputRange: Array<string> = (config.outputRange: any);
|
||||
invariant(outputRange.length >= 2, 'Bad output range');
|
||||
outputRange = outputRange.map(colorToRgba);
|
||||
checkPattern(outputRange);
|
||||
|
||||
const isColor = outputRange[0].isColor;
|
||||
if (__DEV__) {
|
||||
invariant(
|
||||
outputRange.every(output => output.isColor === isColor),
|
||||
'All elements of output range should either be a color or a string with numeric components',
|
||||
);
|
||||
const firstOutput = outputRange[0].components;
|
||||
invariant(
|
||||
outputRange.every(
|
||||
output => output.components.length === firstOutput.length,
|
||||
),
|
||||
'All elements of output range should have the same number of components',
|
||||
);
|
||||
invariant(
|
||||
outputRange.every(output =>
|
||||
output.components.every(
|
||||
(component, i) =>
|
||||
// $FlowIgnoreMe[invalid-compare]
|
||||
typeof component === 'number' || component === firstOutput[i],
|
||||
),
|
||||
),
|
||||
'All elements of output range should have the same non-numeric components',
|
||||
);
|
||||
}
|
||||
// ['rgba(0, 100, 200, 0)', 'rgba(50, 150, 250, 0.5)']
|
||||
// ->
|
||||
// [
|
||||
// [0, 50],
|
||||
// [100, 150],
|
||||
// [200, 250],
|
||||
// [0, 0.5],
|
||||
// ]
|
||||
/* $FlowFixMe[incompatible-use] (>=0.18.0): `outputRange[0].match()` can
|
||||
* return `null`. Need to guard against this possibility. */
|
||||
const outputRanges = outputRange[0].match(stringShapeRegex).map(() => []);
|
||||
outputRange.forEach(value => {
|
||||
/* $FlowFixMe[incompatible-use] (>=0.18.0): `value.match()` can return
|
||||
* `null`. Need to guard against this possibility. */
|
||||
value.match(stringShapeRegex).forEach((number, i) => {
|
||||
outputRanges[i].push(+number);
|
||||
});
|
||||
});
|
||||
|
||||
const numericComponents: $ReadOnlyArray<$ReadOnlyArray<number>> =
|
||||
outputRange.map(output =>
|
||||
isColor
|
||||
? // $FlowIgnoreMe[incompatible-call]
|
||||
output.components
|
||||
: // $FlowIgnoreMe[incompatible-call]
|
||||
output.components.filter(c => typeof c === 'number'),
|
||||
);
|
||||
const interpolations = numericComponents[0].map((_, i) =>
|
||||
createNumericInterpolation({
|
||||
...config,
|
||||
outputRange: numericComponents.map(components => components[i]),
|
||||
}),
|
||||
);
|
||||
if (!isColor) {
|
||||
return input => {
|
||||
const values = interpolations.map(interpolation => interpolation(input));
|
||||
let i = 0;
|
||||
return outputRange[0].components
|
||||
.map(c => (typeof c === 'number' ? values[i++] : c))
|
||||
.join('');
|
||||
};
|
||||
} else {
|
||||
return input => {
|
||||
const result = interpolations.map((interpolation, i) => {
|
||||
const value = interpolation(input);
|
||||
// rgba requires that the r,g,b are integers.... so we want to round them, but we *dont* want to
|
||||
// round the opacity (4th column).
|
||||
return i < 3 ? Math.round(value) : Math.round(value * 1000) / 1000;
|
||||
const interpolations = outputRange[0]
|
||||
.match(stringShapeRegex)
|
||||
/* $FlowFixMe[incompatible-use] (>=0.18.0): `outputRange[0].match()` can
|
||||
* return `null`. Need to guard against this possibility. */
|
||||
/* $FlowFixMe[incompatible-call] (>=0.18.0): `outputRange[0].match()` can
|
||||
* return `null`. Need to guard against this possibility. */
|
||||
.map((value, i) => {
|
||||
return createInterpolation({
|
||||
...config,
|
||||
outputRange: outputRanges[i],
|
||||
});
|
||||
return `rgba(${result[0]}, ${result[1]}, ${result[2]}, ${result[3]})`;
|
||||
};
|
||||
});
|
||||
|
||||
// rgba requires that the r,g,b are integers.... so we want to round them, but we *dont* want to
|
||||
// round the opacity (4th column).
|
||||
const shouldRound = isRgbOrRgba(outputRange[0]);
|
||||
|
||||
return input => {
|
||||
let i = 0;
|
||||
// 'rgba(0, 100, 200, 0)'
|
||||
// ->
|
||||
// 'rgba(${interpolations[0](input)}, ${interpolations[1](input)}, ...'
|
||||
return outputRange[0].replace(stringShapeRegex, () => {
|
||||
let val = +interpolations[i++](input);
|
||||
if (shouldRound) {
|
||||
val = i < 4 ? Math.round(val) : Math.round(val * 1000) / 1000;
|
||||
}
|
||||
return String(val);
|
||||
});
|
||||
};
|
||||
}
|
||||
|
||||
function isRgbOrRgba(range: string) {
|
||||
return typeof range === 'string' && range.startsWith('rgb');
|
||||
}
|
||||
|
||||
function checkPattern(arr: $ReadOnlyArray<string>) {
|
||||
const pattern = arr[0].replace(stringShapeRegex, '');
|
||||
for (let i = 1; i < arr.length; ++i) {
|
||||
invariant(
|
||||
pattern === arr[i].replace(stringShapeRegex, ''),
|
||||
'invalid pattern ' + arr[0] + ' and ' + arr[i],
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -274,24 +276,6 @@ function findRange(input: number, inputRange: $ReadOnlyArray<number>) {
|
||||
return i - 1;
|
||||
}
|
||||
|
||||
function checkValidRanges<OutputT: number | string>(
|
||||
inputRange: $ReadOnlyArray<number>,
|
||||
outputRange: $ReadOnlyArray<OutputT>,
|
||||
) {
|
||||
checkInfiniteRange('outputRange', outputRange);
|
||||
checkInfiniteRange('inputRange', inputRange);
|
||||
checkValidInputRange(inputRange);
|
||||
|
||||
invariant(
|
||||
inputRange.length === outputRange.length,
|
||||
'inputRange (' +
|
||||
inputRange.length +
|
||||
') and outputRange (' +
|
||||
outputRange.length +
|
||||
') must have the same length',
|
||||
);
|
||||
}
|
||||
|
||||
function checkValidInputRange(arr: $ReadOnlyArray<number>) {
|
||||
invariant(arr.length >= 2, 'inputRange must have at least 2 elements');
|
||||
const message =
|
||||
@@ -301,10 +285,7 @@ function checkValidInputRange(arr: $ReadOnlyArray<number>) {
|
||||
}
|
||||
}
|
||||
|
||||
function checkInfiniteRange<OutputT: number | string>(
|
||||
name: string,
|
||||
arr: $ReadOnlyArray<OutputT>,
|
||||
) {
|
||||
function checkInfiniteRange(name: string, arr: $ReadOnlyArray<number>) {
|
||||
invariant(arr.length >= 2, name + ' must have at least 2 elements');
|
||||
invariant(
|
||||
arr.length !== 2 || arr[0] !== -Infinity || arr[1] !== Infinity,
|
||||
@@ -313,7 +294,6 @@ function checkInfiniteRange<OutputT: number | string>(
|
||||
* doesn't cleanly convert to a string, like undefined, null, and object,
|
||||
* etc. If you really mean this implicit string conversion, you can do
|
||||
* something like String(myThing) */
|
||||
// $FlowFixMe[unsafe-addition]
|
||||
name + 'cannot be ]-infinity;+infinity[ ' + arr,
|
||||
);
|
||||
}
|
||||
@@ -321,34 +301,20 @@ function checkInfiniteRange<OutputT: number | string>(
|
||||
export default class AnimatedInterpolation<
|
||||
OutputT: number | string,
|
||||
> extends AnimatedWithChildren {
|
||||
// Export for testing.
|
||||
static __createInterpolation: (
|
||||
config: InterpolationConfigType<OutputT>,
|
||||
) => (input: number) => OutputT = createInterpolation;
|
||||
|
||||
_parent: AnimatedNode;
|
||||
_config: InterpolationConfigType<OutputT>;
|
||||
_interpolation: ?(input: number) => OutputT;
|
||||
_interpolation: (input: number) => OutputT;
|
||||
|
||||
constructor(parent: AnimatedNode, config: InterpolationConfigType<OutputT>) {
|
||||
super();
|
||||
this._parent = parent;
|
||||
this._config = config;
|
||||
|
||||
if (__DEV__) {
|
||||
checkValidRanges(config.inputRange, config.outputRange);
|
||||
|
||||
// Create interpolation eagerly in dev, so we can signal errors faster
|
||||
// even when using the native driver
|
||||
this._getInterpolation();
|
||||
}
|
||||
}
|
||||
|
||||
_getInterpolation(): number => OutputT {
|
||||
if (!this._interpolation) {
|
||||
const config = this._config;
|
||||
if (config.outputRange && typeof config.outputRange[0] === 'string') {
|
||||
this._interpolation = (createStringInterpolation((config: any)): any);
|
||||
} else {
|
||||
this._interpolation = (createNumericInterpolation((config: any)): any);
|
||||
}
|
||||
}
|
||||
return this._interpolation;
|
||||
this._interpolation = createInterpolation(config);
|
||||
}
|
||||
|
||||
__makeNative(platformConfig: ?PlatformConfig) {
|
||||
@@ -356,13 +322,13 @@ export default class AnimatedInterpolation<
|
||||
super.__makeNative(platformConfig);
|
||||
}
|
||||
|
||||
__getValue(): OutputT {
|
||||
__getValue(): number | string {
|
||||
const parentValue: number = this._parent.__getValue();
|
||||
invariant(
|
||||
typeof parentValue === 'number',
|
||||
'Cannot interpolate an input which is not a number.',
|
||||
);
|
||||
return this._getInterpolation()(parentValue);
|
||||
return this._interpolation(parentValue);
|
||||
}
|
||||
|
||||
interpolate<NewOutputT: number | string>(
|
||||
@@ -380,31 +346,19 @@ export default class AnimatedInterpolation<
|
||||
super.__detach();
|
||||
}
|
||||
|
||||
__transformDataType(range: $ReadOnlyArray<OutputT>): Array<any> {
|
||||
return range.map(NativeAnimatedHelper.transformDataType);
|
||||
}
|
||||
|
||||
__getNativeConfig(): any {
|
||||
if (__DEV__) {
|
||||
NativeAnimatedHelper.validateInterpolation(this._config);
|
||||
}
|
||||
|
||||
// Only the `outputRange` can contain strings so we don't need to transform `inputRange` here
|
||||
let outputRange = this._config.outputRange;
|
||||
let outputType = null;
|
||||
if (typeof outputRange[0] === 'string') {
|
||||
// $FlowIgnoreMe[incompatible-cast]
|
||||
outputRange = ((outputRange: $ReadOnlyArray<string>).map(value => {
|
||||
const processedColor = processColor(value);
|
||||
if (typeof processedColor === 'number') {
|
||||
outputType = 'color';
|
||||
return processedColor;
|
||||
} else {
|
||||
return NativeAnimatedHelper.transformDataType(value);
|
||||
}
|
||||
}): any);
|
||||
}
|
||||
|
||||
return {
|
||||
inputRange: this._config.inputRange,
|
||||
outputRange,
|
||||
outputType,
|
||||
// Only the `outputRange` can contain strings so we don't need to transform `inputRange` here
|
||||
outputRange: this.__transformDataType(this._config.outputRange),
|
||||
extrapolateLeft:
|
||||
this._config.extrapolateLeft || this._config.extrapolate || 'extend',
|
||||
extrapolateRight:
|
||||
+5
-3
@@ -12,6 +12,7 @@
|
||||
|
||||
import type {PlatformConfig} from '../AnimatedPlatformConfig';
|
||||
|
||||
import ReactNativeFeatureFlags from '../../ReactNative/ReactNativeFeatureFlags';
|
||||
import NativeAnimatedHelper from '../NativeAnimatedHelper';
|
||||
import invariant from 'invariant';
|
||||
|
||||
@@ -29,7 +30,9 @@ export default class AnimatedNode {
|
||||
__nativeAnimatedValueListener: ?any;
|
||||
__attach(): void {}
|
||||
__detach(): void {
|
||||
this.removeAllListeners();
|
||||
if (ReactNativeFeatureFlags.removeListenersOnDetach()) {
|
||||
this.removeAllListeners();
|
||||
}
|
||||
if (this.__isNative && this.__nativeTag != null) {
|
||||
NativeAnimatedHelper.API.dropAnimatedNode(this.__nativeTag);
|
||||
this.__nativeTag = undefined;
|
||||
@@ -41,7 +44,7 @@ export default class AnimatedNode {
|
||||
}
|
||||
__addChild(child: AnimatedNode) {}
|
||||
__removeChild(child: AnimatedNode) {}
|
||||
__getChildren(): $ReadOnlyArray<AnimatedNode> {
|
||||
__getChildren(): Array<AnimatedNode> {
|
||||
return [];
|
||||
}
|
||||
|
||||
@@ -183,7 +186,6 @@ export default class AnimatedNode {
|
||||
'This JS animated node type cannot be used as native animated node',
|
||||
);
|
||||
}
|
||||
|
||||
toJSON(): any {
|
||||
return this.__getValue();
|
||||
}
|
||||
+6
-7
@@ -90,15 +90,14 @@ export default class AnimatedProps extends AnimatedNode {
|
||||
}
|
||||
|
||||
__makeNative(platformConfig: ?PlatformConfig): void {
|
||||
for (const key in this._props) {
|
||||
const value = this._props[key];
|
||||
if (value instanceof AnimatedNode) {
|
||||
value.__makeNative(platformConfig);
|
||||
}
|
||||
}
|
||||
|
||||
if (!this.__isNative) {
|
||||
this.__isNative = true;
|
||||
for (const key in this._props) {
|
||||
const value = this._props[key];
|
||||
if (value instanceof AnimatedNode) {
|
||||
value.__makeNative(platformConfig);
|
||||
}
|
||||
}
|
||||
|
||||
// Since this does not call the super.__makeNative, we need to store the
|
||||
// supplied platformConfig here, before calling __connectAnimatedView
|
||||
+8
-42
@@ -13,54 +13,24 @@
|
||||
import type {PlatformConfig} from '../AnimatedPlatformConfig';
|
||||
|
||||
import flattenStyle from '../../StyleSheet/flattenStyle';
|
||||
import Platform from '../../Utilities/Platform';
|
||||
import NativeAnimatedHelper from '../NativeAnimatedHelper';
|
||||
import AnimatedNode from './AnimatedNode';
|
||||
import AnimatedTransform from './AnimatedTransform';
|
||||
import AnimatedWithChildren from './AnimatedWithChildren';
|
||||
|
||||
function createAnimatedStyle(inputStyle: any): Object {
|
||||
// $FlowFixMe[underconstrained-implicit-instantiation]
|
||||
const style = flattenStyle(inputStyle);
|
||||
const animatedStyles: any = {};
|
||||
for (const key in style) {
|
||||
const value = style[key];
|
||||
if (key === 'transform') {
|
||||
animatedStyles[key] = new AnimatedTransform(value);
|
||||
} else if (value instanceof AnimatedNode) {
|
||||
animatedStyles[key] = value;
|
||||
} else if (value && !Array.isArray(value) && typeof value === 'object') {
|
||||
animatedStyles[key] = createAnimatedStyle(value);
|
||||
}
|
||||
}
|
||||
return animatedStyles;
|
||||
}
|
||||
|
||||
function createStyleWithAnimatedTransform(inputStyle: any): Object {
|
||||
// $FlowFixMe[underconstrained-implicit-instantiation]
|
||||
let style = flattenStyle(inputStyle) || ({}: {[string]: any});
|
||||
|
||||
if (style.transform) {
|
||||
style = {
|
||||
...style,
|
||||
transform: new AnimatedTransform(style.transform),
|
||||
};
|
||||
}
|
||||
return style;
|
||||
}
|
||||
|
||||
export default class AnimatedStyle extends AnimatedWithChildren {
|
||||
_inputStyle: any;
|
||||
_style: Object;
|
||||
|
||||
constructor(style: any) {
|
||||
super();
|
||||
if (Platform.OS === 'web') {
|
||||
this._inputStyle = style;
|
||||
this._style = createAnimatedStyle(style);
|
||||
} else {
|
||||
this._style = createStyleWithAnimatedTransform(style);
|
||||
style = flattenStyle(style) || ({}: {[string]: any});
|
||||
if (style.transform) {
|
||||
style = {
|
||||
...style,
|
||||
transform: new AnimatedTransform(style.transform),
|
||||
};
|
||||
}
|
||||
this._style = style;
|
||||
}
|
||||
|
||||
// Recursively get values for nested styles (like iOS's shadowOffset)
|
||||
@@ -80,11 +50,7 @@ export default class AnimatedStyle extends AnimatedWithChildren {
|
||||
return updatedStyle;
|
||||
}
|
||||
|
||||
__getValue(): Object | Array<Object> {
|
||||
if (Platform.OS === 'web') {
|
||||
return [this._inputStyle, this._walkStyleAndGetValues(this._style)];
|
||||
}
|
||||
|
||||
__getValue(): Object {
|
||||
return this._walkStyleAndGetValues(this._style);
|
||||
}
|
||||
|
||||
+1
-1
@@ -68,7 +68,7 @@ export default class AnimatedTransform extends AnimatedWithChildren {
|
||||
}
|
||||
|
||||
__getNativeConfig(): any {
|
||||
const transConfigs: Array<any> = [];
|
||||
const transConfigs = [];
|
||||
|
||||
this._transforms.forEach(transform => {
|
||||
for (const key in transform) {
|
||||
+12
-8
@@ -48,18 +48,21 @@ const NativeAnimatedAPI = NativeAnimatedHelper.API;
|
||||
* this two-phases process is to deal with composite props such as
|
||||
* transform which can receive values from multiple parents.
|
||||
*/
|
||||
export function flushValue(rootNode: AnimatedNode): void {
|
||||
const leaves = new Set<{update: () => void, ...}>();
|
||||
function findAnimatedStyles(node: AnimatedNode) {
|
||||
// $FlowFixMe[prop-missing]
|
||||
function _flush(rootNode: AnimatedValue): void {
|
||||
const animatedStyles = new Set<AnimatedValue | AnimatedNode>();
|
||||
function findAnimatedStyles(node: AnimatedValue | AnimatedNode) {
|
||||
/* $FlowFixMe[prop-missing] (>=0.68.0 site=react_native_fb) This comment
|
||||
* suppresses an error found when Flow v0.68 was deployed. To see the error
|
||||
* delete this comment and run Flow. */
|
||||
if (typeof node.update === 'function') {
|
||||
leaves.add((node: any));
|
||||
animatedStyles.add(node);
|
||||
} else {
|
||||
node.__getChildren().forEach(findAnimatedStyles);
|
||||
}
|
||||
}
|
||||
findAnimatedStyles(rootNode);
|
||||
leaves.forEach(leaf => leaf.update());
|
||||
// $FlowFixMe[prop-missing]
|
||||
animatedStyles.forEach(animatedStyle => animatedStyle.update());
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -88,6 +91,7 @@ export default class AnimatedValue extends AnimatedWithChildren {
|
||||
_animation: ?Animation;
|
||||
_tracking: ?AnimatedTracking;
|
||||
|
||||
// $FlowFixMe[missing-local-annot]
|
||||
constructor(value: number, config?: ?AnimatedValueConfig) {
|
||||
super();
|
||||
if (typeof value !== 'number') {
|
||||
@@ -287,9 +291,9 @@ export default class AnimatedValue extends AnimatedWithChildren {
|
||||
|
||||
this._value = value;
|
||||
if (flush) {
|
||||
flushValue(this);
|
||||
_flush(this);
|
||||
}
|
||||
this.__callListeners(this.__getValue());
|
||||
super.__callListeners(this.__getValue());
|
||||
}
|
||||
|
||||
__getNativeConfig(): Object {
|
||||
+1
-1
@@ -70,7 +70,7 @@ export default class AnimatedWithChildren extends AnimatedNode {
|
||||
}
|
||||
}
|
||||
|
||||
__getChildren(): $ReadOnlyArray<AnimatedNode> {
|
||||
__getChildren(): Array<AnimatedNode> {
|
||||
return this._children;
|
||||
}
|
||||
|
||||
+10
-7
@@ -10,7 +10,6 @@
|
||||
|
||||
'use strict';
|
||||
|
||||
import {isPublicInstance as isFabricPublicInstance} from '../Renderer/public/ReactFabricPublicInstanceUtils';
|
||||
import useRefEffect from '../Utilities/useRefEffect';
|
||||
import {AnimatedEvent} from './AnimatedEvent';
|
||||
import NativeAnimatedHelper from './NativeAnimatedHelper';
|
||||
@@ -53,7 +52,7 @@ export default function useAnimatedProps<TProps: {...}, TInstance>(
|
||||
// 2) Update `onUpdateRef`.
|
||||
// 3) Update listeners for `AnimatedEvent` props.
|
||||
//
|
||||
// Ideally, each of these would be separate "effects" so that they are not
|
||||
// Ideally, each of these would be separat "effects" so that they are not
|
||||
// unnecessarily re-run when irrelevant dependencies change. For example, we
|
||||
// should be able to hoist all `AnimatedEvent` props and only do #3 if either
|
||||
// the `AnimatedEvent` props change or `instance` changes.
|
||||
@@ -184,7 +183,7 @@ function getEventTarget<TInstance>(instance: TInstance): TInstance {
|
||||
// $FlowFixMe[unclear-type] - Legacy instance assumptions.
|
||||
function isFabricInstance(instance: any): boolean {
|
||||
return (
|
||||
isFabricPublicInstance(instance) ||
|
||||
hasFabricHandle(instance) ||
|
||||
// Some components have a setNativeProps function but aren't a host component
|
||||
// such as lists like FlatList and SectionList. These should also use
|
||||
// forceUpdate in Fabric since setNativeProps doesn't exist on the underlying
|
||||
@@ -193,9 +192,13 @@ function isFabricInstance(instance: any): boolean {
|
||||
// If these components end up using forwardRef then these hacks can go away
|
||||
// as instance would actually be the underlying host component and the above check
|
||||
// would be sufficient.
|
||||
isFabricPublicInstance(instance?.getNativeScrollRef?.()) ||
|
||||
isFabricPublicInstance(
|
||||
instance?.getScrollResponder?.()?.getNativeScrollRef?.(),
|
||||
)
|
||||
hasFabricHandle(instance?.getNativeScrollRef?.()) ||
|
||||
hasFabricHandle(instance?.getScrollResponder?.()?.getNativeScrollRef?.())
|
||||
);
|
||||
}
|
||||
|
||||
// $FlowFixMe[unclear-type] - Legacy instance assumptions.
|
||||
function hasFabricHandle(instance: any): boolean {
|
||||
// eslint-disable-next-line dot-notation
|
||||
return instance?.['_internalInstanceHandle']?.stateNode?.canonical != null;
|
||||
}
|
||||
+8
-6
@@ -24,7 +24,7 @@
|
||||
* @end
|
||||
* ```
|
||||
*
|
||||
* All the methods implemented by the RCTAppDelegate can be overridden by your AppDelegate if you need to provide a
|
||||
* All the methods implemented by the RCTAppDelegate can be overriden by your AppDelegate if you need to provide a
|
||||
custom implementation.
|
||||
* If you need to customize the default implementation, you can invoke `[super <method_name>]` and use the returned
|
||||
object.
|
||||
@@ -94,17 +94,19 @@
|
||||
*/
|
||||
- (UIViewController *)createRootViewController;
|
||||
|
||||
/// This method controls whether the App will use RuntimeScheduler. Only applicable in the legacy architecture.
|
||||
///
|
||||
/// @return: `YES` to use RuntimeScheduler, `NO` to use JavaScript scheduler. The default value is `YES`.
|
||||
- (BOOL)runtimeSchedulerEnabled;
|
||||
|
||||
#if RCT_NEW_ARCH_ENABLED
|
||||
|
||||
/// The TurboModule manager
|
||||
@property (nonatomic, strong) RCTTurboModuleManager *turboModuleManager;
|
||||
@property (nonatomic, strong) RCTSurfacePresenterBridgeAdapter *bridgeAdapter;
|
||||
|
||||
/// This method controls whether the `concurrentRoot` feature of React18 is turned on or off.
|
||||
///
|
||||
/// @see: https://reactjs.org/blog/2022/03/29/react-v18.html
|
||||
/// @note: This requires to be rendering on Fabric (i.e. on the New Architecture).
|
||||
/// @return: `true` if the `concurrentRoot` feature is enabled. Otherwise, it returns `false`.
|
||||
- (BOOL)concurrentRootEnabled;
|
||||
|
||||
/// This method controls whether the `turboModules` feature of the New Architecture is turned on or off.
|
||||
///
|
||||
/// @note: This is required to be rendering on Fabric (i.e. on the New Architecture).
|
||||
+29
-74
@@ -6,29 +6,21 @@
|
||||
*/
|
||||
|
||||
#import "RCTAppDelegate.h"
|
||||
#import <React/RCTCxxBridgeDelegate.h>
|
||||
#import <React/RCTAppSetupUtils.h>
|
||||
#import <React/RCTRootView.h>
|
||||
#import <React/RCTRuntimeExecutorFromBridge.h>
|
||||
#import <react/renderer/runtimescheduler/RuntimeScheduler.h>
|
||||
|
||||
#import "RCTAppSetupUtils.h"
|
||||
|
||||
#if RCT_NEW_ARCH_ENABLED
|
||||
#import <React/CoreModulesPlugins.h>
|
||||
#import <React/RCTComponentViewFactory.h>
|
||||
#import <React/RCTComponentViewProtocol.h>
|
||||
#import <React/RCTCxxBridgeDelegate.h>
|
||||
#import <React/RCTFabricSurfaceHostingProxyRootView.h>
|
||||
#import <React/RCTLegacyViewManagerInteropComponentView.h>
|
||||
#import <React/RCTSurfacePresenter.h>
|
||||
#import <React/RCTSurfacePresenterBridgeAdapter.h>
|
||||
#import <ReactCommon/RCTTurboModuleManager.h>
|
||||
#import <react/config/ReactNativeConfig.h>
|
||||
#import <react/renderer/runtimescheduler/RuntimeSchedulerCallInvoker.h>
|
||||
#import "RCTLegacyInteropComponents.h"
|
||||
|
||||
static NSString *const kRNConcurrentRoot = @"concurrentRoot";
|
||||
|
||||
@interface RCTAppDelegate () <RCTTurboModuleManagerDelegate> {
|
||||
@interface RCTAppDelegate () <RCTTurboModuleManagerDelegate, RCTCxxBridgeDelegate> {
|
||||
std::shared_ptr<const facebook::react::ReactNativeConfig> _reactNativeConfig;
|
||||
facebook::react::ContextContainer::Shared _contextContainer;
|
||||
}
|
||||
@@ -36,53 +28,43 @@ static NSString *const kRNConcurrentRoot = @"concurrentRoot";
|
||||
|
||||
#endif
|
||||
|
||||
@interface RCTAppDelegate () <RCTCxxBridgeDelegate> {
|
||||
std::shared_ptr<facebook::react::RuntimeScheduler> _runtimeScheduler;
|
||||
}
|
||||
@end
|
||||
|
||||
@implementation RCTAppDelegate
|
||||
|
||||
#if RCT_NEW_ARCH_ENABLED
|
||||
- (instancetype)init
|
||||
{
|
||||
if (self = [super init]) {
|
||||
_contextContainer = std::make_shared<facebook::react::ContextContainer const>();
|
||||
_reactNativeConfig = std::make_shared<facebook::react::EmptyReactNativeConfig const>();
|
||||
_contextContainer->insert("ReactNativeConfig", _reactNativeConfig);
|
||||
}
|
||||
return self;
|
||||
}
|
||||
#endif
|
||||
|
||||
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
|
||||
{
|
||||
BOOL enableTM = NO;
|
||||
#if RCT_NEW_ARCH_ENABLED
|
||||
enableTM = self.turboModuleEnabled;
|
||||
#endif
|
||||
|
||||
RCTAppSetupPrepareApp(application, enableTM);
|
||||
|
||||
if (!self.bridge) {
|
||||
self.bridge = [self createBridgeWithDelegate:self launchOptions:launchOptions];
|
||||
}
|
||||
#if RCT_NEW_ARCH_ENABLED
|
||||
_contextContainer = std::make_shared<facebook::react::ContextContainer const>();
|
||||
_reactNativeConfig = std::make_shared<facebook::react::EmptyReactNativeConfig const>();
|
||||
_contextContainer->insert("ReactNativeConfig", _reactNativeConfig);
|
||||
self.bridgeAdapter = [[RCTSurfacePresenterBridgeAdapter alloc] initWithBridge:self.bridge
|
||||
contextContainer:_contextContainer];
|
||||
self.bridge.surfacePresenter = self.bridgeAdapter.surfacePresenter;
|
||||
|
||||
[self unstable_registerLegacyComponents];
|
||||
#endif
|
||||
|
||||
NSDictionary *initProps = [self prepareInitialProps];
|
||||
UIView *rootView = [self createRootViewWithBridge:self.bridge moduleName:self.moduleName initProps:initProps];
|
||||
|
||||
if (@available(iOS 13.0, *)) {
|
||||
rootView.backgroundColor = [UIColor systemBackgroundColor];
|
||||
} else {
|
||||
rootView.backgroundColor = [UIColor whiteColor];
|
||||
}
|
||||
|
||||
self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
|
||||
UIViewController *rootViewController = [self createRootViewController];
|
||||
rootViewController.view = rootView;
|
||||
self.window.rootViewController = rootViewController;
|
||||
[self.window makeKeyAndVisible];
|
||||
|
||||
return YES;
|
||||
}
|
||||
|
||||
@@ -93,14 +75,19 @@ static NSString *const kRNConcurrentRoot = @"concurrentRoot";
|
||||
return nil;
|
||||
}
|
||||
|
||||
- (BOOL)concurrentRootEnabled
|
||||
{
|
||||
[NSException raise:@"concurrentRootEnabled not implemented"
|
||||
format:@"Subclasses must implement a valid concurrentRootEnabled method"];
|
||||
return true;
|
||||
}
|
||||
|
||||
- (NSDictionary *)prepareInitialProps
|
||||
{
|
||||
NSMutableDictionary *initProps = self.initialProps ? [self.initialProps mutableCopy] : [NSMutableDictionary new];
|
||||
|
||||
#ifdef RCT_NEW_ARCH_ENABLED
|
||||
// Hardcoding the Concurrent Root as it it not recommended to
|
||||
// have the concurrentRoot turned off when Fabric is enabled.
|
||||
initProps[kRNConcurrentRoot] = @([self fabricEnabled]);
|
||||
initProps[kRNConcurrentRoot] = @([self concurrentRootEnabled]);
|
||||
#endif
|
||||
|
||||
return initProps;
|
||||
@@ -119,14 +106,7 @@ static NSString *const kRNConcurrentRoot = @"concurrentRoot";
|
||||
#if RCT_NEW_ARCH_ENABLED
|
||||
enableFabric = self.fabricEnabled;
|
||||
#endif
|
||||
UIView *rootView = RCTAppSetupDefaultRootView(bridge, moduleName, initProps, enableFabric);
|
||||
if (@available(iOS 13.0, *)) {
|
||||
rootView.backgroundColor = [UIColor systemBackgroundColor];
|
||||
} else {
|
||||
rootView.backgroundColor = [UIColor whiteColor];
|
||||
}
|
||||
|
||||
return rootView;
|
||||
return RCTAppSetupDefaultRootView(bridge, moduleName, initProps, enableFabric);
|
||||
}
|
||||
|
||||
- (UIViewController *)createRootViewController
|
||||
@@ -134,34 +114,18 @@ static NSString *const kRNConcurrentRoot = @"concurrentRoot";
|
||||
return [UIViewController new];
|
||||
}
|
||||
|
||||
- (BOOL)runtimeSchedulerEnabled
|
||||
{
|
||||
return YES;
|
||||
}
|
||||
|
||||
#if RCT_NEW_ARCH_ENABLED
|
||||
#pragma mark - RCTCxxBridgeDelegate
|
||||
|
||||
- (std::unique_ptr<facebook::react::JSExecutorFactory>)jsExecutorFactoryForBridge:(RCTBridge *)bridge
|
||||
{
|
||||
#if RCT_NEW_ARCH_ENABLED
|
||||
_runtimeScheduler = std::make_shared<facebook::react::RuntimeScheduler>(RCTRuntimeExecutorFromBridge(bridge));
|
||||
std::shared_ptr<facebook::react::CallInvoker> callInvoker =
|
||||
std::make_shared<facebook::react::RuntimeSchedulerCallInvoker>(_runtimeScheduler);
|
||||
self.turboModuleManager = [[RCTTurboModuleManager alloc] initWithBridge:bridge delegate:self jsInvoker:callInvoker];
|
||||
_contextContainer->erase("RuntimeScheduler");
|
||||
_contextContainer->insert("RuntimeScheduler", _runtimeScheduler);
|
||||
return RCTAppSetupDefaultJsExecutorFactory(bridge, self.turboModuleManager, _runtimeScheduler);
|
||||
#else
|
||||
if (self.runtimeSchedulerEnabled) {
|
||||
_runtimeScheduler = std::make_shared<facebook::react::RuntimeScheduler>(RCTRuntimeExecutorFromBridge(bridge));
|
||||
}
|
||||
return RCTAppSetupJsExecutorFactoryForOldArch(bridge, _runtimeScheduler);
|
||||
#endif
|
||||
self.turboModuleManager = [[RCTTurboModuleManager alloc] initWithBridge:bridge
|
||||
delegate:self
|
||||
jsInvoker:bridge.jsCallInvoker];
|
||||
return RCTAppSetupDefaultJsExecutorFactory(bridge, _turboModuleManager);
|
||||
}
|
||||
|
||||
|
||||
#if RCT_NEW_ARCH_ENABLED
|
||||
|
||||
#pragma mark - RCTTurboModuleManagerDelegate
|
||||
#pragma mark RCTTurboModuleManagerDelegate
|
||||
|
||||
- (Class)getModuleClassFromName:(const char *)name
|
||||
{
|
||||
@@ -198,15 +162,6 @@ static NSString *const kRNConcurrentRoot = @"concurrentRoot";
|
||||
return YES;
|
||||
}
|
||||
|
||||
#pragma mark - New Arch Utilities
|
||||
|
||||
- (void)unstable_registerLegacyComponents
|
||||
{
|
||||
for (NSString *legacyComponent in [RCTLegacyInteropComponents legacyInteropComponents]) {
|
||||
[RCTLegacyViewManagerInteropComponentView supportLegacyViewManagerWithName:legacyComponent];
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@end
|
||||
+5
-43
@@ -16,17 +16,14 @@ else
|
||||
source[:tag] = "v#{version}"
|
||||
end
|
||||
|
||||
folly_flags = ' -DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1'
|
||||
folly_flags = '-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1'
|
||||
folly_compiler_flags = folly_flags + ' ' + '-Wno-comma -Wno-shorten-64-to-32'
|
||||
|
||||
is_new_arch_enabled = ENV["RCT_NEW_ARCH_ENABLED"] == "1"
|
||||
new_arch_enabled_flag = (is_new_arch_enabled ? " -DRCT_NEW_ARCH_ENABLED" : "")
|
||||
is_fabric_enabled = is_new_arch_enabled || ENV["RCT_FABRIC_ENABLED"]
|
||||
fabric_flag = (is_fabric_enabled ? " -DRN_FABRIC_ENABLED" : "")
|
||||
other_cflags = "$(inherited)" + folly_flags + new_arch_enabled_flag + fabric_flag
|
||||
new_arch_enabled_flag="RCT_NEW_ARCH_ENABLED"
|
||||
is_new_arch_enabled = ENV[new_arch_enabled_flag] == "1"
|
||||
other_cflags = "$(inherited) -DRN_FABRIC_ENABLED " + folly_flags + (is_new_arch_enabled ? " -D"+"RCT_NEW_ARCH_ENABLED" : "")
|
||||
|
||||
use_hermes = ENV['USE_HERMES'] == '1'
|
||||
use_frameworks = ENV['USE_FRAMEWORKS'] != nil
|
||||
|
||||
header_search_paths = [
|
||||
"$(PODS_TARGET_SRCROOT)/ReactCommon",
|
||||
@@ -40,16 +37,6 @@ header_search_paths = [
|
||||
].concat(use_hermes ? [
|
||||
"$(PODS_ROOT)/Headers/Public/React-hermes",
|
||||
"$(PODS_ROOT)/Headers/Public/hermes-engine"
|
||||
] : []).concat(use_frameworks ? [
|
||||
"$(PODS_CONFIGURATION_BUILD_DIR)/React-Fabric/React_Fabric.framework/Headers/",
|
||||
"$(PODS_CONFIGURATION_BUILD_DIR)/React-graphics/React_graphics.framework/Headers/",
|
||||
"$(PODS_CONFIGURATION_BUILD_DIR)/React-graphics/React_graphics.framework/Headers/react/renderer/graphics/platform/ios",
|
||||
"$(PODS_CONFIGURATION_BUILD_DIR)/ReactCommon/ReactCommon.framework/Headers/react/nativemodule/core",
|
||||
"$(PODS_CONFIGURATION_BUILD_DIR)/React-NativeModulesApple/React_NativeModulesApple.framework/Headers",
|
||||
"$(PODS_CONFIGURATION_BUILD_DIR)/React-RCTFabric/RCTFabric.framework/Headers/",
|
||||
"$(PODS_CONFIGURATION_BUILD_DIR)/React-utils/React_utils.framework/Headers/",
|
||||
"$(PODS_CONFIGURATION_BUILD_DIR)/React-debug/React_debug.framework/Headers/",
|
||||
"$(PODS_CONFIGURATION_BUILD_DIR)/React-runtimescheduler/React_runtimescheduler.framework/Headers/",
|
||||
] : []).map{|p| "\"#{p}\""}.join(" ")
|
||||
|
||||
Pod::Spec.new do |s|
|
||||
@@ -59,7 +46,7 @@ Pod::Spec.new do |s|
|
||||
s.homepage = "https://reactnative.dev/"
|
||||
s.documentation_url = "https://reactnative.dev/docs/actionsheetios"
|
||||
s.license = package["license"]
|
||||
s.author = "Meta Platforms, Inc. and its affiliates"
|
||||
s.author = "Facebook, Inc. and its affiliates"
|
||||
s.platforms = { :ios => "12.4" }
|
||||
s.source = source
|
||||
s.source_files = "**/*.{c,h,m,mm,S,cpp}"
|
||||
@@ -78,34 +65,9 @@ Pod::Spec.new do |s|
|
||||
s.dependency "RCTRequired"
|
||||
s.dependency "RCTTypeSafety"
|
||||
s.dependency "ReactCommon/turbomodule/core"
|
||||
s.dependency "React-RCTNetwork"
|
||||
s.dependency "React-RCTImage"
|
||||
s.dependency "React-NativeModulesApple"
|
||||
s.dependency "React-CoreModules"
|
||||
s.dependency "React-runtimescheduler"
|
||||
|
||||
if ENV['USE_HERMES'] == nil || ENV['USE_HERMES'] == "1"
|
||||
s.dependency "React-hermes"
|
||||
else
|
||||
s.dependency "React-jsc"
|
||||
end
|
||||
|
||||
if is_new_arch_enabled
|
||||
s.dependency "React-RCTFabric"
|
||||
s.dependency "React-graphics"
|
||||
s.dependency "React-utils"
|
||||
s.dependency "React-debug"
|
||||
|
||||
s.script_phases = {
|
||||
:name => "Generate Legacy Components Interop",
|
||||
:script => "
|
||||
WITH_ENVIRONMENT=\"$REACT_NATIVE_PATH/scripts/xcode/with-environment.sh\"
|
||||
source $WITH_ENVIRONMENT
|
||||
${NODE_BINARY} ${REACT_NATIVE_PATH}/scripts/codegen/generate-legacy-interop-components.js -p #{ENV['APP_PATH']} -o ${REACT_NATIVE_PATH}/Libraries/AppDelegate
|
||||
",
|
||||
:execution_position => :before_compile,
|
||||
:input_files => ["#{ENV['APP_PATH']}/react-native.config.js"],
|
||||
:output_files => ["${REACT_NATIVE_PATH}/Libraries/AppDelegate/RCTLegacyInteropComponents.mm"],
|
||||
}
|
||||
end
|
||||
end
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user