From 628fcf2a509f55e2f69685dfe4c38dc537138797 Mon Sep 17 00:00:00 2001 From: David Chavez Date: Mon, 24 Jul 2023 14:54:49 +0200 Subject: [PATCH 01/10] chore(example): update RN to 0.71.12 --- example/ios/.ruby-version | 2 +- example/ios/Podfile | 1 + example/package.json | 3 +- example/yarn.lock | 367 ++++++++++++++++++++++---------------- 4 files changed, 219 insertions(+), 154 deletions(-) diff --git a/example/ios/.ruby-version b/example/ios/.ruby-version index fd2a01863..944880fa1 100644 --- a/example/ios/.ruby-version +++ b/example/ios/.ruby-version @@ -1 +1 @@ -3.1.0 +3.2.0 diff --git a/example/ios/Podfile b/example/ios/Podfile index 39b7c26bd..a2522b84d 100644 --- a/example/ios/Podfile +++ b/example/ios/Podfile @@ -60,3 +60,4 @@ target 'example' do __apply_Xcode_12_5_M1_post_install_workaround(installer) end end + diff --git a/example/package.json b/example/package.json index f1a97e6e7..aa600127e 100644 --- a/example/package.json +++ b/example/package.json @@ -11,6 +11,7 @@ "android:install-release": "RD=android/app/build/outputs/bundle/release && (rm $RD/app.apks || true) && bundletool build-apks --bundle=$RD/app-release.aab --output=$RD/app.apks && (adb uninstall com.example || true) && bundletool install-apks --apks=$RD/app.apks", "android:logs": "android/scripts/logs", "ios": "react-native run-ios", + "ios:sim": "react-native run-ios --simulator=\"iPhone\"", "ios:ide": "open ios/*.xcworkspace/", "windows": "react-native run-windows", "start": "react-native start", @@ -24,7 +25,7 @@ "dependencies": { "@react-native-community/slider": "^4.4.2", "react": "18.2.0", - "react-native": "0.71.8", + "react-native": "0.71.12", "react-native-windows": "^0.65.0-0" }, "devDependencies": { diff --git a/example/yarn.lock b/example/yarn.lock index c4997c48f..0e72a6067 100644 --- a/example/yarn.lock +++ b/example/yarn.lock @@ -1762,13 +1762,13 @@ dependencies: serve-static "^1.13.1" -"@react-native-community/cli-doctor@^10.2.2": - version "10.2.2" - resolved "https://registry.yarnpkg.com/@react-native-community/cli-doctor/-/cli-doctor-10.2.2.tgz#b1893604fa9fc8971064e7c00042350f96868bfe" - integrity sha512-49Ep2aQOF0PkbAR/TcyMjOm9XwBa8VQr+/Zzf4SJeYwiYLCT1NZRAVAVjYRXl0xqvq5S5mAGZZShS4AQl4WsZw== +"@react-native-community/cli-doctor@^10.2.4": + version "10.2.5" + resolved "https://registry.yarnpkg.com/@react-native-community/cli-doctor/-/cli-doctor-10.2.5.tgz#e5e28c66c2373f05a94b296a8ec637f8df736707" + integrity sha512-1YbzXvsldBmSw1MmBsXB74bKiHXKNCjlb2ByLgkfTiarpSvETYam3g5vex0N+qc0Cdkzkq+8NznE744LFhnUpw== dependencies: "@react-native-community/cli-config" "^10.1.1" - "@react-native-community/cli-platform-ios" "^10.2.1" + "@react-native-community/cli-platform-ios" "^10.2.5" "@react-native-community/cli-tools" "^10.1.1" chalk "^4.1.2" command-exists "^1.2.8" @@ -1833,10 +1833,22 @@ slash "^3.0.0" xmldoc "^1.1.2" -"@react-native-community/cli-platform-ios@10.2.1", "@react-native-community/cli-platform-ios@^10.2.1": - version "10.2.1" - resolved "https://registry.yarnpkg.com/@react-native-community/cli-platform-ios/-/cli-platform-ios-10.2.1.tgz#2e6bd2cb6d48cbb8720d7b7265bb1bab80745f72" - integrity sha512-hz4zu4Y6eyj7D0lnZx8Mf2c2si8y+zh/zUTgCTaPPLzQD8jSZNNBtUUiA1cARm2razpe8marCZ1QbTMAGbf3mg== +"@react-native-community/cli-platform-ios@10.2.4": + version "10.2.4" + resolved "https://registry.yarnpkg.com/@react-native-community/cli-platform-ios/-/cli-platform-ios-10.2.4.tgz#6af05cd4258438422a3a50d1c0cc757acd6be375" + integrity sha512-/6K+jeRhcGojFIJMWMXV2eY5n/In+YUzBr/DKWQOeHBOHkESRNheG310xSAIjgB46YniSSUKhSyeuhalTbm9OQ== + dependencies: + "@react-native-community/cli-tools" "^10.1.1" + chalk "^4.1.2" + execa "^1.0.0" + fast-xml-parser "^4.0.12" + glob "^7.1.3" + ora "^5.4.1" + +"@react-native-community/cli-platform-ios@^10.2.5": + version "10.2.5" + resolved "https://registry.yarnpkg.com/@react-native-community/cli-platform-ios/-/cli-platform-ios-10.2.5.tgz#7888c74b83099885bf9e6d52170c6e663ad971ee" + integrity sha512-hq+FZZuSBK9z82GLQfzdNDl8vbFx5UlwCLFCuTtNCROgBoapFtVZQKRP2QBftYNrQZ0dLAb01gkwxagHsQCFyg== dependencies: "@react-native-community/cli-tools" "^10.1.1" chalk "^4.1.2" @@ -1859,21 +1871,21 @@ plist "^3.0.2" xcode "^2.0.0" -"@react-native-community/cli-plugin-metro@^10.2.2": - version "10.2.2" - resolved "https://registry.yarnpkg.com/@react-native-community/cli-plugin-metro/-/cli-plugin-metro-10.2.2.tgz#766914e3c8007dfe52b253544c4f6cd8549919ac" - integrity sha512-sTGjZlD3OGqbF9v1ajwUIXhGmjw9NyJ/14Lo0sg7xH8Pv4qUd5ZvQ6+DWYrQn3IKFUMfGFWYyL81ovLuPylrpw== +"@react-native-community/cli-plugin-metro@^10.2.3": + version "10.2.3" + resolved "https://registry.yarnpkg.com/@react-native-community/cli-plugin-metro/-/cli-plugin-metro-10.2.3.tgz#419e0155a50951c3329818fba51cb5021a7294f1" + integrity sha512-jHi2oDuTePmW4NEyVT8JEGNlIYcnFXCSV2ZMp4rnDrUk4TzzyvS3IMvDlESEmG8Kry8rvP0KSUx/hTpy37Sbkw== dependencies: "@react-native-community/cli-server-api" "^10.1.1" "@react-native-community/cli-tools" "^10.1.1" chalk "^4.1.2" execa "^1.0.0" - metro "0.73.9" - metro-config "0.73.9" - metro-core "0.73.9" - metro-react-native-babel-transformer "0.73.9" - metro-resolver "0.73.9" - metro-runtime "0.73.9" + metro "0.73.10" + metro-config "0.73.10" + metro-core "0.73.10" + metro-react-native-babel-transformer "0.73.10" + metro-resolver "0.73.10" + metro-runtime "0.73.10" readline "^1.3.0" "@react-native-community/cli-plugin-metro@^6.4.0": @@ -1965,17 +1977,17 @@ dependencies: ora "^3.4.0" -"@react-native-community/cli@10.2.2": - version "10.2.2" - resolved "https://registry.yarnpkg.com/@react-native-community/cli/-/cli-10.2.2.tgz#3fa438ba7f19f83e07bc337765fc1cabdcf2cac2" - integrity sha512-aZVcVIqj+OG6CrliR/Yn8wHxrvyzbFBY9cj7n0MvRw/P54QUru2nNqUTSSbqv0Qaa297yHJbe6kFDojDMSTM8Q== +"@react-native-community/cli@10.2.4": + version "10.2.4" + resolved "https://registry.yarnpkg.com/@react-native-community/cli/-/cli-10.2.4.tgz#c6afe723055d430061a32bd31644fc56eb9ba330" + integrity sha512-E9BUDHfLEsnjkjeJqECuCjl4E/1Ox9Nl6hkQBhEqjZm4AaQxgU7M6AyFfOgaXn5v3am16/R4ZOUTrJnGJWS3GA== dependencies: "@react-native-community/cli-clean" "^10.1.1" "@react-native-community/cli-config" "^10.1.1" "@react-native-community/cli-debugger-ui" "^10.0.0" - "@react-native-community/cli-doctor" "^10.2.2" + "@react-native-community/cli-doctor" "^10.2.4" "@react-native-community/cli-hermes" "^10.2.0" - "@react-native-community/cli-plugin-metro" "^10.2.2" + "@react-native-community/cli-plugin-metro" "^10.2.3" "@react-native-community/cli-server-api" "^10.1.1" "@react-native-community/cli-tools" "^10.1.1" "@react-native-community/cli-types" "^10.0.0" @@ -5602,6 +5614,11 @@ jsc-android@^250231.0.0: resolved "https://registry.yarnpkg.com/jsc-android/-/jsc-android-250231.0.0.tgz#91720f8df382a108872fa4b3f558f33ba5e95262" integrity sha512-rS46PvsjYmdmuz1OAWXY/1kCYG7pnf1TBqeTiOJr1iDz7s5DLxxC9n/ZMknLDxzYzNVfI7R95MH10emSSG1Wuw== +jsc-safe-url@^0.2.2: + version "0.2.4" + resolved "https://registry.yarnpkg.com/jsc-safe-url/-/jsc-safe-url-0.2.4.tgz#141c14fbb43791e88d5dc64e85a374575a83477a" + integrity sha512-0wM3YBWtYePOjfyXQH5MWQ8H7sdk5EXSwZvmSLKk2RboVQ2Bu239jycHDz5J/8Blf3K0Qnoy2b6xD+z10MFB+Q== + jscodeshift@^0.13.1: version "0.13.1" resolved "https://registry.yarnpkg.com/jscodeshift/-/jscodeshift-0.13.1.tgz#69bfe51e54c831296380585c6d9e733512aecdef" @@ -5939,14 +5956,14 @@ metro-babel-transformer@0.66.2: metro-source-map "0.66.2" nullthrows "^1.1.1" -metro-babel-transformer@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-babel-transformer/-/metro-babel-transformer-0.73.9.tgz#bec8aaaf1bbdc2e469fde586fde455f8b2a83073" - integrity sha512-DlYwg9wwYIZTHtic7dyD4BP0SDftoltZ3clma76nHu43blMWsCnrImHeHsAVne3XsQ+RJaSRxhN5nkG2VyVHwA== +metro-babel-transformer@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-babel-transformer/-/metro-babel-transformer-0.73.10.tgz#b27732fa3869f397246ee8ecf03b64622ab738c1" + integrity sha512-Yv2myTSnpzt/lTyurLvqYbBkytvUJcLHN8XD3t7W6rGiLTQPzmf1zypHQLphvcAXtCWBOXFtH7KLOSi2/qMg+A== dependencies: "@babel/core" "^7.20.0" hermes-parser "0.8.0" - metro-source-map "0.73.9" + metro-source-map "0.73.10" nullthrows "^1.1.1" metro-cache-key@0.66.2: @@ -5954,10 +5971,10 @@ metro-cache-key@0.66.2: resolved "https://registry.yarnpkg.com/metro-cache-key/-/metro-cache-key-0.66.2.tgz#d6463d2a53e887a38419d523962cc24ea0e780b4" integrity sha512-WtkNmRt41qOpHh1MkNA4nLiQ/m7iGL90ysSKD+fcLqlUnOBKJptPQm0ZUv8Kfqk18ddWX2KmsSbq+Sf3I6XohQ== -metro-cache-key@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-cache-key/-/metro-cache-key-0.73.9.tgz#7d8c441a3b7150f7b201273087ef3cf7d3435d9f" - integrity sha512-uJg+6Al7UoGIuGfoxqPBy6y1Ewq7Y8/YapGYIDh6sohInwt/kYKnPZgLDYHIPvY2deORnQ/2CYo4tOeBTnhCXQ== +metro-cache-key@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-cache-key/-/metro-cache-key-0.73.10.tgz#8d63591187d295b62a80aed64a87864b1e9d67a2" + integrity sha512-JMVDl/EREDiUW//cIcUzRjKSwE2AFxVWk47cFBer+KA4ohXIG2CQPEquT56hOw1Y1s6gKNxxs1OlAOEsubrFjw== metro-cache@0.66.2: version "0.66.2" @@ -5968,12 +5985,12 @@ metro-cache@0.66.2: mkdirp "^0.5.1" rimraf "^2.5.4" -metro-cache@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-cache/-/metro-cache-0.73.9.tgz#773c2df6ba53434e58ccbe421b0c54e6da8d2890" - integrity sha512-upiRxY8rrQkUWj7ieACD6tna7xXuXdu2ZqrheksT79ePI0aN/t0memf6WcyUtJUMHZetke3j+ppELNvlmp3tOw== +metro-cache@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-cache/-/metro-cache-0.73.10.tgz#02e9cb7c1e42aab5268d2ecce35ad8f2c08891de" + integrity sha512-wPGlQZpdVlM404m7MxJqJ+hTReDr5epvfPbt2LerUAHY9RN99w61FeeAe25BMZBwgUgDtAsfGlJ51MBHg8MAqw== dependencies: - metro-core "0.73.9" + metro-core "0.73.10" rimraf "^3.0.2" metro-config@0.66.2, metro-config@^0.66.1: @@ -5988,17 +6005,17 @@ metro-config@0.66.2, metro-config@^0.66.1: metro-core "0.66.2" metro-runtime "0.66.2" -metro-config@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-config/-/metro-config-0.73.9.tgz#6b43c70681bdd6b00f44400fc76dddbe53374500" - integrity sha512-NiWl1nkYtjqecDmw77tbRbXnzIAwdO6DXGZTuKSkH+H/c1NKq1eizO8Fe+NQyFtwR9YLqn8Q0WN1nmkwM1j8CA== +metro-config@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-config/-/metro-config-0.73.10.tgz#a9ec3d0a1290369e3f46c467a4c4f6dd43acc223" + integrity sha512-wIlybd1Z9I8K2KcStTiJxTB7OK529dxFgogNpKCTU/3DxkgAASqSkgXnZP6kVyqjh5EOWAKFe5U6IPic7kXDdQ== dependencies: cosmiconfig "^5.0.5" jest-validate "^26.5.2" - metro "0.73.9" - metro-cache "0.73.9" - metro-core "0.73.9" - metro-runtime "0.73.9" + metro "0.73.10" + metro-cache "0.73.10" + metro-core "0.73.10" + metro-runtime "0.73.10" metro-core@0.66.2, metro-core@^0.66.1: version "0.66.2" @@ -6009,18 +6026,18 @@ metro-core@0.66.2, metro-core@^0.66.1: lodash.throttle "^4.1.1" metro-resolver "0.66.2" -metro-core@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-core/-/metro-core-0.73.9.tgz#410c5c0aeae840536c10039f68098fdab3da568e" - integrity sha512-1NTs0IErlKcFTfYyRT3ljdgrISWpl1nys+gaHkXapzTSpvtX9F1NQNn5cgAuE+XIuTJhbsCdfIJiM2JXbrJQaQ== +metro-core@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-core/-/metro-core-0.73.10.tgz#feb3c228aa8c0dde71d8e4cef614cc3a1dc3bbd7" + integrity sha512-5uYkajIxKyL6W45iz/ftNnYPe1l92CvF2QJeon1CHsMXkEiOJxEjo41l+iSnO/YodBGrmMCyupSO4wOQGUc0lw== dependencies: lodash.throttle "^4.1.1" - metro-resolver "0.73.9" + metro-resolver "0.73.10" -metro-file-map@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-file-map/-/metro-file-map-0.73.9.tgz#09c04a8e8ef1eaa6ecb2b9cb8cb53bb0fa0167ec" - integrity sha512-R/Wg3HYeQhYY3ehWtfedw8V0ne4lpufG7a21L3GWer8tafnC9pmjoCKEbJz9XZkVj9i1FtxE7UTbrtZNeIILxQ== +metro-file-map@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-file-map/-/metro-file-map-0.73.10.tgz#55bd906fb7c1bef8e1a31df4b29a3ef4b49f0b5a" + integrity sha512-XOMWAybeaXyD6zmVZPnoCCL2oO3rp4ta76oUlqWP0skBzhFxVtkE/UtDwApEMUY361JeBBago647gnKiARs+1g== dependencies: abort-controller "^3.0.0" anymatch "^3.0.3" @@ -6043,10 +6060,10 @@ metro-hermes-compiler@0.66.2: resolved "https://registry.yarnpkg.com/metro-hermes-compiler/-/metro-hermes-compiler-0.66.2.tgz#30290748f83805faa601aa487632444915795823" integrity sha512-nCVL1g9uR6vrw5+X1wjwZruRyMkndnzGRMqjqoljf+nGEqBTD607CR7elXw4fMWn/EM+1y0Vdq5altUu9LdgCA== -metro-hermes-compiler@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-hermes-compiler/-/metro-hermes-compiler-0.73.9.tgz#6f473e67e8f76066066f00e2e0ecce865f7d445d" - integrity sha512-5B3vXIwQkZMSh3DQQY23XpTCpX9kPLqZbA3rDuAcbGW0tzC3f8dCenkyBb0GcCzyTDncJeot/A7oVCVK6zapwg== +metro-hermes-compiler@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-hermes-compiler/-/metro-hermes-compiler-0.73.10.tgz#4525a7835c803a5d0b3b05c6619202e2273d630f" + integrity sha512-rTRWEzkVrwtQLiYkOXhSdsKkIObnL+Jqo+IXHI7VEK2aSLWRAbtGNqECBs44kbOUypDYTFFE+WLtoqvUWqYkWg== metro-inspector-proxy@0.66.2: version "0.66.2" @@ -6058,20 +6075,20 @@ metro-inspector-proxy@0.66.2: ws "^1.1.5" yargs "^15.3.1" -metro-inspector-proxy@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-inspector-proxy/-/metro-inspector-proxy-0.73.9.tgz#8e11cd300adf3f904f1f5afe28b198312cdcd8c2" - integrity sha512-B3WrWZnlYhtTrv0IaX3aUAhi2qVILPAZQzb5paO1e+xrz4YZHk9c7dXv7qe7B/IQ132e3w46y3AL7rFo90qVjA== +metro-inspector-proxy@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-inspector-proxy/-/metro-inspector-proxy-0.73.10.tgz#752fed2ab88199c9dcc3369c3d59da6c5b954a51" + integrity sha512-CEEvocYc5xCCZBtGSIggMCiRiXTrnBbh8pmjKQqm9TtJZALeOGyt5pXUaEkKGnhrXETrexsg6yIbsQHhEvVfvQ== dependencies: connect "^3.6.5" debug "^2.2.0" ws "^7.5.1" yargs "^17.5.1" -metro-minify-terser@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-minify-terser/-/metro-minify-terser-0.73.9.tgz#301aef2e106b0802f7a14ef0f2b4883b20c80018" - integrity sha512-MTGPu2qV5qtzPJ2SqH6s58awHDtZ4jd7lmmLR+7TXDwtZDjIBA0YVfI0Zak2Haby2SqoNKrhhUns/b4dPAQAVg== +metro-minify-terser@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-minify-terser/-/metro-minify-terser-0.73.10.tgz#557eab3a512b90b7779350ff5d25a215c4dbe61f" + integrity sha512-uG7TSKQ/i0p9kM1qXrwbmY3v+6BrMItsOcEXcSP8Z+68bb+t9HeVK0T/hIfUu1v1PEnonhkhfzVsaP8QyTd5lQ== dependencies: terser "^5.15.0" @@ -6082,10 +6099,10 @@ metro-minify-uglify@0.66.2: dependencies: uglify-es "^3.1.9" -metro-minify-uglify@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-minify-uglify/-/metro-minify-uglify-0.73.9.tgz#cf4f8c19b688deea103905689ec736c2f2acd733" - integrity sha512-gzxD/7WjYcnCNGiFJaA26z34rjOp+c/Ft++194Wg91lYep3TeWQ0CnH8t2HRS7AYDHU81SGWgvD3U7WV0g4LGA== +metro-minify-uglify@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-minify-uglify/-/metro-minify-uglify-0.73.10.tgz#4de79056d502479733854c90f2075374353ea154" + integrity sha512-eocnSeJKnLz/UoYntVFhCJffED7SLSgbCHgNvI6ju6hFb6EFHGJT9OLbkJWeXaWBWD3Zw5mYLS8GGqGn/CHZPA== dependencies: uglify-es "^3.1.9" @@ -6135,6 +6152,50 @@ metro-react-native-babel-preset@0.66.2: "@babel/template" "^7.0.0" react-refresh "^0.4.0" +metro-react-native-babel-preset@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-react-native-babel-preset/-/metro-react-native-babel-preset-0.73.10.tgz#304b24bb391537d2c987732cc0a9774be227d3f6" + integrity sha512-1/dnH4EHwFb2RKEKx34vVDpUS3urt2WEeR8FYim+ogqALg4sTpG7yeQPxWpbgKATezt4rNfqAANpIyH19MS4BQ== + dependencies: + "@babel/core" "^7.20.0" + "@babel/plugin-proposal-async-generator-functions" "^7.0.0" + "@babel/plugin-proposal-class-properties" "^7.0.0" + "@babel/plugin-proposal-export-default-from" "^7.0.0" + "@babel/plugin-proposal-nullish-coalescing-operator" "^7.0.0" + "@babel/plugin-proposal-object-rest-spread" "^7.0.0" + "@babel/plugin-proposal-optional-catch-binding" "^7.0.0" + "@babel/plugin-proposal-optional-chaining" "^7.0.0" + "@babel/plugin-syntax-dynamic-import" "^7.0.0" + "@babel/plugin-syntax-export-default-from" "^7.0.0" + "@babel/plugin-syntax-flow" "^7.18.0" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.0.0" + "@babel/plugin-syntax-optional-chaining" "^7.0.0" + "@babel/plugin-transform-arrow-functions" "^7.0.0" + "@babel/plugin-transform-async-to-generator" "^7.0.0" + "@babel/plugin-transform-block-scoping" "^7.0.0" + "@babel/plugin-transform-classes" "^7.0.0" + "@babel/plugin-transform-computed-properties" "^7.0.0" + "@babel/plugin-transform-destructuring" "^7.0.0" + "@babel/plugin-transform-flow-strip-types" "^7.0.0" + "@babel/plugin-transform-function-name" "^7.0.0" + "@babel/plugin-transform-literals" "^7.0.0" + "@babel/plugin-transform-modules-commonjs" "^7.0.0" + "@babel/plugin-transform-named-capturing-groups-regex" "^7.0.0" + "@babel/plugin-transform-parameters" "^7.0.0" + "@babel/plugin-transform-react-display-name" "^7.0.0" + "@babel/plugin-transform-react-jsx" "^7.0.0" + "@babel/plugin-transform-react-jsx-self" "^7.0.0" + "@babel/plugin-transform-react-jsx-source" "^7.0.0" + "@babel/plugin-transform-runtime" "^7.0.0" + "@babel/plugin-transform-shorthand-properties" "^7.0.0" + "@babel/plugin-transform-spread" "^7.0.0" + "@babel/plugin-transform-sticky-regex" "^7.0.0" + "@babel/plugin-transform-template-literals" "^7.0.0" + "@babel/plugin-transform-typescript" "^7.5.0" + "@babel/plugin-transform-unicode-regex" "^7.0.0" + "@babel/template" "^7.0.0" + react-refresh "^0.4.0" + metro-react-native-babel-preset@0.73.9: version "0.73.9" resolved "https://registry.yarnpkg.com/metro-react-native-babel-preset/-/metro-react-native-babel-preset-0.73.9.tgz#ef54637dd20f025197beb49e71309a9c539e73e2" @@ -6192,17 +6253,17 @@ metro-react-native-babel-transformer@0.66.2, metro-react-native-babel-transforme metro-source-map "0.66.2" nullthrows "^1.1.1" -metro-react-native-babel-transformer@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-react-native-babel-transformer/-/metro-react-native-babel-transformer-0.73.9.tgz#4f4f0cfa5119bab8b53e722fabaf90687d0cbff0" - integrity sha512-DSdrEHuQ22ixY7DyipyKkIcqhOJrt5s6h6X7BYJCP9AMUfXOwLe2biY3BcgJz5GOXv8/Akry4vTCvQscVS1otQ== +metro-react-native-babel-transformer@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-react-native-babel-transformer/-/metro-react-native-babel-transformer-0.73.10.tgz#4e20a9ce131b873cda0b5a44d3eb4002134a64b8" + integrity sha512-4G/upwqKdmKEjmsNa92/NEgsOxUWOygBVs+FXWfXWKgybrmcjh3NoqdRYrROo9ZRA/sB9Y/ZXKVkWOGKHtGzgg== dependencies: "@babel/core" "^7.20.0" babel-preset-fbjs "^3.4.0" hermes-parser "0.8.0" - metro-babel-transformer "0.73.9" - metro-react-native-babel-preset "0.73.9" - metro-source-map "0.73.9" + metro-babel-transformer "0.73.10" + metro-react-native-babel-preset "0.73.10" + metro-source-map "0.73.10" nullthrows "^1.1.1" metro-resolver@0.66.2, metro-resolver@^0.66.1: @@ -6212,10 +6273,10 @@ metro-resolver@0.66.2, metro-resolver@^0.66.1: dependencies: absolute-path "^0.0.0" -metro-resolver@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-resolver/-/metro-resolver-0.73.9.tgz#f3cf77e6c7606a34aa81bad40edb856aad671cf3" - integrity sha512-Ej3wAPOeNRPDnJmkK0zk7vJ33iU07n+oPhpcf5L0NFkWneMmSM2bflMPibI86UjzZGmRfn0AhGhs8yGeBwQ/Xg== +metro-resolver@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-resolver/-/metro-resolver-0.73.10.tgz#c39a3bd8d33e5d78cb256110d29707d8d49ed0be" + integrity sha512-HeXbs+0wjakaaVQ5BI7eT7uqxlZTc9rnyw6cdBWWMgUWB++KpoI0Ge7Hi6eQAOoVAzXC3m26mPFYLejpzTWjng== dependencies: absolute-path "^0.0.0" @@ -6224,10 +6285,10 @@ metro-runtime@0.66.2, metro-runtime@^0.66.1: resolved "https://registry.yarnpkg.com/metro-runtime/-/metro-runtime-0.66.2.tgz#3409ee957b949b6c7b72ef6ed2b9af9a4f4a910e" integrity sha512-vFhKBk2ot9FS4b+2v0OTa/guCF/QDAOJubY0CNg7PzCS5+w4y3IvZIcPX4SSS1t8pYEZBLvtdtTDarlDl81xmg== -metro-runtime@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-runtime/-/metro-runtime-0.73.9.tgz#0b24c0b066b8629ee855a6e5035b65061fef60d5" - integrity sha512-d5Hs83FpKB9r8q8Vb95+fa6ESpwysmPr4lL1I2rM2qXAFiO7OAPT9Bc23WmXgidkBtD0uUFdB2lG+H1ATz8rZg== +metro-runtime@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-runtime/-/metro-runtime-0.73.10.tgz#c3de19d17e75ffe1a145778d99422e7ffc208768" + integrity sha512-EpVKm4eN0Fgx2PEWpJ5NiMArV8zVoOin866jIIvzFLpmkZz1UEqgjf2JAfUJnjgv3fjSV3JqeGG2vZCaGQBTow== dependencies: "@babel/runtime" "^7.0.0" react-refresh "^0.4.0" @@ -6246,17 +6307,17 @@ metro-source-map@0.66.2: source-map "^0.5.6" vlq "^1.0.0" -metro-source-map@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-source-map/-/metro-source-map-0.73.9.tgz#89ca41f6346aeb12f7f23496fa363e520adafebe" - integrity sha512-l4VZKzdqafipriETYR6lsrwtavCF1+CMhCOY9XbyWeTrpGSNgJQgdeJpttzEZTHQQTLR0csQo0nD1ef3zEP6IQ== +metro-source-map@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-source-map/-/metro-source-map-0.73.10.tgz#28e09a28f1a2f7a4f8d0845b845cbed74e2f48f9" + integrity sha512-NAGv14701p/YaFZ76KzyPkacBw/QlEJF1f8elfs23N1tC33YyKLDKvPAzFJiYqjdcFvuuuDCA8JCXd2TgLxNPw== dependencies: "@babel/traverse" "^7.20.0" "@babel/types" "^7.20.0" invariant "^2.2.4" - metro-symbolicate "0.73.9" + metro-symbolicate "0.73.10" nullthrows "^1.1.1" - ob1 "0.73.9" + ob1 "0.73.10" source-map "^0.5.6" vlq "^1.0.0" @@ -6272,13 +6333,13 @@ metro-symbolicate@0.66.2: through2 "^2.0.1" vlq "^1.0.0" -metro-symbolicate@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-symbolicate/-/metro-symbolicate-0.73.9.tgz#cb452299a36e5b86b2826e7426d51221635c48bf" - integrity sha512-4TUOwxRHHqbEHxRqRJ3wZY5TA8xq7AHMtXrXcjegMH9FscgYztsrIG9aNBUBS+VLB6g1qc6BYbfIgoAnLjCDyw== +metro-symbolicate@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-symbolicate/-/metro-symbolicate-0.73.10.tgz#7853a9a8fbfd615a5c9db698fffc685441ac880f" + integrity sha512-PmCe3TOe1c/NVwMlB+B17me951kfkB3Wve5RqJn+ErPAj93od1nxicp6OJe7JT4QBRnpUP8p9tw2sHKqceIzkA== dependencies: invariant "^2.2.4" - metro-source-map "0.73.9" + metro-source-map "0.73.10" nullthrows "^1.1.1" source-map "^0.5.6" through2 "^2.0.1" @@ -6295,10 +6356,10 @@ metro-transform-plugins@0.66.2: "@babel/traverse" "^7.14.0" nullthrows "^1.1.1" -metro-transform-plugins@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-transform-plugins/-/metro-transform-plugins-0.73.9.tgz#9fffbe1b24269e3d114286fa681abc570072d9b8" - integrity sha512-r9NeiqMngmooX2VOKLJVQrMuV7PAydbqst5bFhdVBPcFpZkxxqyzjzo+kzrszGy2UpSQBZr2P1L6OMjLHwQwfQ== +metro-transform-plugins@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-transform-plugins/-/metro-transform-plugins-0.73.10.tgz#1b762330cbbedb6c18438edc3d76b063c88882af" + integrity sha512-D4AgD3Vsrac+4YksaPmxs/0ocT67bvwTkFSIgWWeDvWwIG0U1iHzTS9f8Bvb4PITnXryDoFtjI6OWF7uOpGxpA== dependencies: "@babel/core" "^7.20.0" "@babel/generator" "^7.20.0" @@ -6325,23 +6386,23 @@ metro-transform-worker@0.66.2: metro-transform-plugins "0.66.2" nullthrows "^1.1.1" -metro-transform-worker@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro-transform-worker/-/metro-transform-worker-0.73.9.tgz#30384cef2d5e35a4abe91b15bf1a8344f5720441" - integrity sha512-Rq4b489sIaTUENA+WCvtu9yvlT/C6zFMWhU4sq+97W29Zj0mPBjdk+qGT5n1ZBgtBIJzZWt1KxeYuc17f4aYtQ== +metro-transform-worker@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro-transform-worker/-/metro-transform-worker-0.73.10.tgz#bb401dbd7b10a6fe443a5f7970cba38425efece0" + integrity sha512-IySvVubudFxahxOljWtP0QIMMpgUrCP0bW16cz2Enof0PdumwmR7uU3dTbNq6S+XTzuMHR+076aIe4VhPAWsIQ== dependencies: "@babel/core" "^7.20.0" "@babel/generator" "^7.20.0" "@babel/parser" "^7.20.0" "@babel/types" "^7.20.0" babel-preset-fbjs "^3.4.0" - metro "0.73.9" - metro-babel-transformer "0.73.9" - metro-cache "0.73.9" - metro-cache-key "0.73.9" - metro-hermes-compiler "0.73.9" - metro-source-map "0.73.9" - metro-transform-plugins "0.73.9" + metro "0.73.10" + metro-babel-transformer "0.73.10" + metro-cache "0.73.10" + metro-cache-key "0.73.10" + metro-hermes-compiler "0.73.10" + metro-source-map "0.73.10" + metro-transform-plugins "0.73.10" nullthrows "^1.1.1" metro@0.66.2, metro@^0.66.1: @@ -6402,10 +6463,10 @@ metro@0.66.2, metro@^0.66.1: ws "^1.1.5" yargs "^15.3.1" -metro@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/metro/-/metro-0.73.9.tgz#150e69a6735fab0bcb4f6ee97fd1efc65b3ec36f" - integrity sha512-BlYbPmTF60hpetyNdKhdvi57dSqutb+/oK0u3ni4emIh78PiI0axGo7RfdsZ/mn3saASXc94tDbpC5yn7+NpEg== +metro@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/metro/-/metro-0.73.10.tgz#d9a0efb1e403e3aee5cf5140e0a96a7220c23901" + integrity sha512-J2gBhNHFtc/Z48ysF0B/bfTwUwaRDLjNv7egfhQCc+934dpXcjJG2KZFeuybF+CvA9vo4QUi56G2U+RSAJ5tsA== dependencies: "@babel/code-frame" "^7.0.0" "@babel/core" "^7.20.0" @@ -6428,24 +6489,25 @@ metro@0.73.9: image-size "^0.6.0" invariant "^2.2.4" jest-worker "^27.2.0" + jsc-safe-url "^0.2.2" lodash.throttle "^4.1.1" - metro-babel-transformer "0.73.9" - metro-cache "0.73.9" - metro-cache-key "0.73.9" - metro-config "0.73.9" - metro-core "0.73.9" - metro-file-map "0.73.9" - metro-hermes-compiler "0.73.9" - metro-inspector-proxy "0.73.9" - metro-minify-terser "0.73.9" - metro-minify-uglify "0.73.9" - metro-react-native-babel-preset "0.73.9" - metro-resolver "0.73.9" - metro-runtime "0.73.9" - metro-source-map "0.73.9" - metro-symbolicate "0.73.9" - metro-transform-plugins "0.73.9" - metro-transform-worker "0.73.9" + metro-babel-transformer "0.73.10" + metro-cache "0.73.10" + metro-cache-key "0.73.10" + metro-config "0.73.10" + metro-core "0.73.10" + metro-file-map "0.73.10" + metro-hermes-compiler "0.73.10" + metro-inspector-proxy "0.73.10" + metro-minify-terser "0.73.10" + metro-minify-uglify "0.73.10" + metro-react-native-babel-preset "0.73.10" + metro-resolver "0.73.10" + metro-runtime "0.73.10" + metro-source-map "0.73.10" + metro-symbolicate "0.73.10" + metro-transform-plugins "0.73.10" + metro-transform-worker "0.73.10" mime-types "^2.1.27" node-fetch "^2.2.0" nullthrows "^1.1.1" @@ -6705,10 +6767,10 @@ ob1@0.66.2: resolved "https://registry.yarnpkg.com/ob1/-/ob1-0.66.2.tgz#8caf548202cf2688944bae47db405a08bca17a61" integrity sha512-RFewnL/RjE0qQBOuM+2bbY96zmJPIge/aDtsiDbLSb+MOiK8CReAhBHDgL+zrA3F1hQk00lMWpUwYcep750plA== -ob1@0.73.9: - version "0.73.9" - resolved "https://registry.yarnpkg.com/ob1/-/ob1-0.73.9.tgz#d5677a0dd3e2f16ad84231278d79424436c38c59" - integrity sha512-kHOzCOFXmAM26fy7V/YuXNKne2TyRiXbFAvPBIbuedJCZZWQZHLdPzMeXJI4Egt6IcfDttRzN3jQ90wOwq1iNw== +ob1@0.73.10: + version "0.73.10" + resolved "https://registry.yarnpkg.com/ob1/-/ob1-0.73.10.tgz#bf0a2e8922bb8687ddca82327c5cf209414a1bd4" + integrity sha512-aO6EYC+QRRCkZxVJhCWhLKgVjhNuD6Gu1riGjxrIm89CqLsmKgxzYDDEsktmKsoDeRdWGQM5EdMzXDl5xcVfsw== object-assign@^4.1.1: version "4.1.1" @@ -7251,10 +7313,10 @@ react-native-codegen@^0.71.5: jscodeshift "^0.13.1" nullthrows "^1.1.1" -react-native-gradle-plugin@^0.71.18: - version "0.71.18" - resolved "https://registry.yarnpkg.com/react-native-gradle-plugin/-/react-native-gradle-plugin-0.71.18.tgz#20ef199bc85be32e45bb6cc069ec2e7dcb1a74a6" - integrity sha512-7F6bD7B8Xsn3JllxcwHhFcsl9aHIig47+3eN4IHFNqfLhZr++3ElDrcqfMzugM+niWbaMi7bJ0kAkAL8eCpdWg== +react-native-gradle-plugin@^0.71.19: + version "0.71.19" + resolved "https://registry.yarnpkg.com/react-native-gradle-plugin/-/react-native-gradle-plugin-0.71.19.tgz#3379e28341fcd189bc1f4691cefc84c1a4d7d232" + integrity sha512-1dVk9NwhoyKHCSxcrM6vY6cxmojeATsBobDicX0ZKr7DgUF2cBQRTKsimQFvzH8XhOVXyH8p4HyDSZNIFI8OlQ== react-native-windows@^0.65.0-0: version "0.65.14" @@ -7295,20 +7357,21 @@ react-native-windows@^0.65.0-0: whatwg-fetch "^3.0.0" ws "^6.1.4" -react-native@0.71.8: - version "0.71.8" - resolved "https://registry.yarnpkg.com/react-native/-/react-native-0.71.8.tgz#4314145341c49448cf7465b93ced52a433a5e191" - integrity sha512-ftMAuhpgTkbHU9brrqsEyxcNrpYvXKeATY+if22Nfhhg1zW+6wn95w9otwTnA3xHkljPCbng8mUhmmERjGEl7g== +react-native@0.71.12: + version "0.71.12" + resolved "https://registry.yarnpkg.com/react-native/-/react-native-0.71.12.tgz#a4a37de71931b5f483a15b8ab9114b9c01e1317d" + integrity sha512-1zDOTdalLepcVB8ZRIZpWlIGyyJISzAF4MIYSDdW7VDJtIRC7ybXsj/kSARF1zpGSg+LgAV8NMCZzGg598M7Iw== dependencies: "@jest/create-cache-key-function" "^29.2.1" - "@react-native-community/cli" "10.2.2" + "@react-native-community/cli" "10.2.4" "@react-native-community/cli-platform-android" "10.2.0" - "@react-native-community/cli-platform-ios" "10.2.1" + "@react-native-community/cli-platform-ios" "10.2.4" "@react-native/assets" "1.0.0" "@react-native/normalize-color" "2.1.0" "@react-native/polyfills" "2.0.0" abort-controller "^3.0.0" anser "^1.4.9" + ansi-regex "^5.0.0" base64-js "^1.1.2" deprecated-react-native-prop-types "^3.0.1" event-target-shim "^5.0.1" @@ -7316,16 +7379,16 @@ react-native@0.71.8: jest-environment-node "^29.2.1" jsc-android "^250231.0.0" memoize-one "^5.0.0" - metro-react-native-babel-transformer "0.73.9" - metro-runtime "0.73.9" - metro-source-map "0.73.9" + metro-react-native-babel-transformer "0.73.10" + metro-runtime "0.73.10" + metro-source-map "0.73.10" mkdirp "^0.5.1" nullthrows "^1.1.1" pretty-format "^26.5.2" promise "^8.3.0" react-devtools-core "^4.26.1" react-native-codegen "^0.71.5" - react-native-gradle-plugin "^0.71.18" + react-native-gradle-plugin "^0.71.19" react-refresh "^0.4.0" react-shallow-renderer "^16.15.0" regenerator-runtime "^0.13.2" From 52780a8b18ec14c6a469316e354d3bd101295f7b Mon Sep 17 00:00:00 2001 From: Jonathan Puckey Date: Mon, 24 Jul 2023 14:57:37 +0200 Subject: [PATCH 02/10] chore(example): kill logcat on sigint (#2052) --- example/android/scripts/logs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/example/android/scripts/logs b/example/android/scripts/logs index 071ababf9..58575333a 100755 --- a/example/android/scripts/logs +++ b/example/android/scripts/logs @@ -7,6 +7,8 @@ function monitor_logs { adb logcat --pid="$1" & LOGCAT_PID=$! + trap 'echo "Received SIGINT, cleaning up..."; kill $LOGCAT_PID; exit 1' SIGINT + while adb shell "pidof -s $PACKAGE_NAME >/dev/null"; do sleep 1 done From dcfa19187a61c17cba1ea91be95a27faaee1a0ff Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Jul 2023 15:07:35 +0200 Subject: [PATCH 03/10] chore(deps): bump semver from 5.7.1 to 5.7.2 (#2057) Bumps [semver](https://github.com/npm/node-semver) from 5.7.1 to 5.7.2. - [Release notes](https://github.com/npm/node-semver/releases) - [Changelog](https://github.com/npm/node-semver/blob/v5.7.2/CHANGELOG.md) - [Commits](https://github.com/npm/node-semver/compare/v5.7.1...v5.7.2) --- updated-dependencies: - dependency-name: semver dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- yarn.lock | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/yarn.lock b/yarn.lock index 8731e1452..ebc257f7d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6027,19 +6027,19 @@ scheduler@^0.20.1, scheduler@^0.20.2: object-assign "^4.1.1" "semver@2 || 3 || 4 || 5", semver@^5.3.0, semver@^5.4.1, semver@^5.5.0, semver@^5.6.0: - version "5.7.1" - resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" - integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== + version "5.7.2" + resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8" + integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g== semver@^6.0.0, semver@^6.1.1, semver@^6.1.2, semver@^6.3.0: - version "6.3.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" - integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== + version "6.3.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" + integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== semver@^7.3.2, semver@^7.3.4, semver@^7.3.7: - version "7.3.8" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.8.tgz#07a78feafb3f7b32347d725e33de7e2a2df67798" - integrity sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A== + version "7.5.4" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" + integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== dependencies: lru-cache "^6.0.0" From 3c6ba31850c9ec9c7703c77f46a239fca44ed691 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Jul 2023 15:07:46 +0200 Subject: [PATCH 04/10] chore(deps): bump semver from 5.7.1 to 5.7.2 in /example (#2055) Bumps [semver](https://github.com/npm/node-semver) from 5.7.1 to 5.7.2. - [Release notes](https://github.com/npm/node-semver/releases) - [Changelog](https://github.com/npm/node-semver/blob/v5.7.2/CHANGELOG.md) - [Commits](https://github.com/npm/node-semver/compare/v5.7.1...v5.7.2) --- updated-dependencies: - dependency-name: semver dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- example/yarn.lock | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/example/yarn.lock b/example/yarn.lock index 0e72a6067..7e9c5c435 100644 --- a/example/yarn.lock +++ b/example/yarn.lock @@ -7780,19 +7780,19 @@ scheduler@^0.23.0: loose-envify "^1.1.0" semver@^5.3.0, semver@^5.4.1, semver@^5.5.0, semver@^5.6.0: - version "5.7.1" - resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" - integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== + version "5.7.2" + resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8" + integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g== semver@^6.0.0, semver@^6.1.1, semver@^6.1.2, semver@^6.3.0: - version "6.3.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" - integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== + version "6.3.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" + integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== semver@^7.3.2, semver@^7.3.5, semver@^7.3.7: - version "7.3.8" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.8.tgz#07a78feafb3f7b32347d725e33de7e2a2df67798" - integrity sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A== + version "7.5.4" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" + integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== dependencies: lru-cache "^6.0.0" From b29135ff8b72946ab817994d22bb36e2d6014b0e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Jul 2023 15:07:57 +0200 Subject: [PATCH 05/10] chore(deps): bump semver from 5.7.1 to 5.7.2 in /docs (#2054) Bumps [semver](https://github.com/npm/node-semver) from 5.7.1 to 5.7.2. - [Release notes](https://github.com/npm/node-semver/releases) - [Changelog](https://github.com/npm/node-semver/blob/v5.7.2/CHANGELOG.md) - [Commits](https://github.com/npm/node-semver/compare/v5.7.1...v5.7.2) --- updated-dependencies: - dependency-name: semver dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- docs/yarn.lock | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/docs/yarn.lock b/docs/yarn.lock index f089800f0..4cc76bb0a 100644 --- a/docs/yarn.lock +++ b/docs/yarn.lock @@ -6548,19 +6548,19 @@ semver@7.0.0: integrity sha512-+GB6zVA9LWh6zovYQLALHwv5rb2PHGlJi3lfiqIHxR0uuwCgefcOJc59v9fv1w8GbStwxuuqqAjI9NMAOOgq1A== semver@^5.4.1: - version "5.7.1" - resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" - integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== + version "5.7.2" + resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8" + integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g== semver@^6.0.0, semver@^6.1.1, semver@^6.1.2, semver@^6.2.0, semver@^6.3.0: - version "6.3.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" - integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== + version "6.3.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" + integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== semver@^7.3.2, semver@^7.3.4, semver@^7.3.5: - version "7.3.7" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.7.tgz#12c5b649afdbf9049707796e22a4028814ce523f" - integrity sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g== + version "7.5.4" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" + integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== dependencies: lru-cache "^6.0.0" From 65fb2dbae23f7b6ae1d2ef584fa8548beaea059e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Jul 2023 15:08:11 +0200 Subject: [PATCH 06/10] chore(deps): bump word-wrap from 1.2.3 to 1.2.4 (#2063) Bumps [word-wrap](https://github.com/jonschlinkert/word-wrap) from 1.2.3 to 1.2.4. - [Release notes](https://github.com/jonschlinkert/word-wrap/releases) - [Commits](https://github.com/jonschlinkert/word-wrap/compare/1.2.3...1.2.4) --- updated-dependencies: - dependency-name: word-wrap dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index ebc257f7d..5b07ce09b 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6867,9 +6867,9 @@ which@^2.0.1: isexe "^2.0.0" word-wrap@^1.0.3, word-wrap@^1.2.3: - version "1.2.3" - resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c" - integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ== + version "1.2.4" + resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.4.tgz#cb4b50ec9aca570abd1f52f33cd45b6c61739a9f" + integrity sha512-2V81OA4ugVo5pRo46hAoD2ivUJx8jXmWXfUkY4KFNw0hEptvN0QfH3K4nHiwzGeKl5rFKedV48QVoqYavy4YpA== wordwrap@^1.0.0: version "1.0.0" From 82aa61387b6d20e34fecb7b5c0005640c681ebe6 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Jul 2023 15:08:20 +0200 Subject: [PATCH 07/10] chore(deps): bump word-wrap from 1.2.3 to 1.2.4 in /example (#2064) Bumps [word-wrap](https://github.com/jonschlinkert/word-wrap) from 1.2.3 to 1.2.4. - [Release notes](https://github.com/jonschlinkert/word-wrap/releases) - [Commits](https://github.com/jonschlinkert/word-wrap/compare/1.2.3...1.2.4) --- updated-dependencies: - dependency-name: word-wrap dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- example/yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/example/yarn.lock b/example/yarn.lock index 7e9c5c435..af9d24bea 100644 --- a/example/yarn.lock +++ b/example/yarn.lock @@ -8602,9 +8602,9 @@ which@^2.0.1: isexe "^2.0.0" word-wrap@^1.2.3: - version "1.2.3" - resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c" - integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ== + version "1.2.4" + resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.4.tgz#cb4b50ec9aca570abd1f52f33cd45b6c61739a9f" + integrity sha512-2V81OA4ugVo5pRo46hAoD2ivUJx8jXmWXfUkY4KFNw0hEptvN0QfH3K4nHiwzGeKl5rFKedV48QVoqYavy4YpA== wrap-ansi@^6.2.0: version "6.2.0" From f39de9fea951db6485e5abb5716471d0e8f0ca48 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Jul 2023 15:08:36 +0200 Subject: [PATCH 08/10] chore(deps): bump fast-xml-parser from 4.1.3 to 4.2.4 in /example (#2026) Bumps [fast-xml-parser](https://github.com/NaturalIntelligence/fast-xml-parser) from 4.1.3 to 4.2.4. - [Release notes](https://github.com/NaturalIntelligence/fast-xml-parser/releases) - [Changelog](https://github.com/NaturalIntelligence/fast-xml-parser/blob/master/CHANGELOG.md) - [Commits](https://github.com/NaturalIntelligence/fast-xml-parser/commits) --- updated-dependencies: - dependency-name: fast-xml-parser dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- example/yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/example/yarn.lock b/example/yarn.lock index af9d24bea..0985b08a7 100644 --- a/example/yarn.lock +++ b/example/yarn.lock @@ -4142,9 +4142,9 @@ fast-levenshtein@^2.0.6: integrity sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw== fast-xml-parser@^4.0.12: - version "4.1.3" - resolved "https://registry.yarnpkg.com/fast-xml-parser/-/fast-xml-parser-4.1.3.tgz#0254ad0d4d27f07e6b48254b068c0c137488dd97" - integrity sha512-LsNDahCiCcJPe8NO7HijcnukHB24tKbfDDA5IILx9dmW3Frb52lhbeX6MPNUSvyGNfav2VTYpJ/OqkRoVLrh2Q== + version "4.2.4" + resolved "https://registry.yarnpkg.com/fast-xml-parser/-/fast-xml-parser-4.2.4.tgz#6e846ede1e56ad9e5ef07d8720809edf0ed07e9b" + integrity sha512-fbfMDvgBNIdDJLdLOwacjFAPYt67tr31H9ZhWSm45CDAxvd0I6WTlSOUo7K2P/K5sA5JgMKG64PI3DMcaFdWpQ== dependencies: strnum "^1.0.5" From efecf3e0a1c5bf56dbae85aa1553c1c6f94109af Mon Sep 17 00:00:00 2001 From: Jonathan Puckey Date: Mon, 24 Jul 2023 15:16:08 +0200 Subject: [PATCH 09/10] fix: resolving imported local assets (#2033) --- example/src/components/TrackInfo.tsx | 2 +- src/interfaces/Track.ts | 11 ++- src/interfaces/TrackMetadataBase.ts | 3 +- src/trackPlayer.ts | 110 +++++++++++++-------------- 4 files changed, 61 insertions(+), 65 deletions(-) diff --git a/example/src/components/TrackInfo.tsx b/example/src/components/TrackInfo.tsx index 71a2e7adb..ce60ef29c 100644 --- a/example/src/components/TrackInfo.tsx +++ b/example/src/components/TrackInfo.tsx @@ -7,7 +7,7 @@ export const TrackInfo: React.FC<{ }> = ({ track }) => { return ( - + {track?.title} {track?.artist} diff --git a/src/interfaces/Track.ts b/src/interfaces/Track.ts index e68184098..6e3ca6787 100644 --- a/src/interfaces/Track.ts +++ b/src/interfaces/Track.ts @@ -1,9 +1,9 @@ +import type { PitchAlgorithm, TrackType } from '../constants'; +import { ResourceObject } from './ResourceObject'; import type { TrackMetadataBase } from './TrackMetadataBase'; -import type { ResourceObject } from './ResourceObject'; -import type { TrackType, PitchAlgorithm } from '../constants'; export interface Track extends TrackMetadataBase { - url: string | ResourceObject; + url: string; type?: TrackType; /** The user agent HTTP header */ userAgent?: string; @@ -16,3 +16,8 @@ export interface Track extends TrackMetadataBase { // eslint-disable-next-line @typescript-eslint/no-explicit-any [key: string]: any; } + +export type AddTrack = Track & { + url: string | ResourceObject; + artwork?: string | ResourceObject; +}; diff --git a/src/interfaces/TrackMetadataBase.ts b/src/interfaces/TrackMetadataBase.ts index 9e689a8d5..ef638d03c 100644 --- a/src/interfaces/TrackMetadataBase.ts +++ b/src/interfaces/TrackMetadataBase.ts @@ -1,4 +1,3 @@ -import type { ResourceObject } from './ResourceObject'; import type { RatingType } from '../constants'; export interface TrackMetadataBase { @@ -11,7 +10,7 @@ export interface TrackMetadataBase { /** The track duration in seconds */ duration?: number; /** The track artwork */ - artwork?: string | ResourceObject; + artwork?: string; /** track description */ description?: string; /** The track genre */ diff --git a/src/trackPlayer.ts b/src/trackPlayer.ts index be4b509e0..3d093c559 100644 --- a/src/trackPlayer.ts +++ b/src/trackPlayer.ts @@ -10,6 +10,7 @@ import { default as resolveAssetSource } from 'react-native/Libraries/Image/reso import { Event, RepeatMode, State } from './constants'; import type { + AddTrack, EventPayloadByEvent, NowPlayingMetadata, PlaybackState, @@ -29,9 +30,18 @@ const emitter = // MARK: - Helpers -function resolveImportedPath(path?: number | string) { - if (!path) return undefined; - return resolveAssetSource(path) || path; +function resolveImportedAssetOrPath(pathOrAsset: string | number | undefined) { + return pathOrAsset === undefined + ? undefined + : typeof pathOrAsset === 'string' + ? pathOrAsset + : resolveImportedAsset(pathOrAsset)?.uri; +} + +function resolveImportedAsset(id?: number) { + return id + ? (resolveAssetSource(id) as { uri: string } | null) ?? undefined + : undefined; } // MARK: - General API @@ -90,7 +100,7 @@ export function isServiceRunning(): Promise { * By default the tracks will be added to the end of the queue. */ export async function add( - tracks: Track[], + tracks: AddTrack[], insertBeforeIndex?: number ): Promise; /** @@ -101,32 +111,23 @@ export async function add( * By default the track will be added to the end of the queue. */ export async function add( - track: Track, + track: AddTrack, insertBeforeIndex?: number ): Promise; export async function add( - tracks: Track | Track[], + tracks: AddTrack | AddTrack[], insertBeforeIndex = -1 ): Promise { - // Clone the array before modifying it - if (Array.isArray(tracks)) { - tracks = [...tracks]; - } else { - tracks = [tracks]; - } - - if (tracks.length < 1) return; - - for (let i = 0; i < tracks.length; i++) { - // Clone the object before modifying it - tracks[i] = { ...tracks[i] }; - - // Resolve the URLs - tracks[i].url = resolveImportedPath(tracks[i].url); - tracks[i].artwork = resolveImportedPath(tracks[i].artwork); - } - - return TrackPlayer.add(tracks, insertBeforeIndex); + const resolvedTracks = (Array.isArray(tracks) ? tracks : [tracks]).map( + (track) => ({ + ...track, + url: resolveImportedAssetOrPath(track.url), + artwork: resolveImportedAssetOrPath(track.artwork), + }) + ); + return resolvedTracks.length < 1 + ? undefined + : TrackPlayer.add(resolvedTracks, insertBeforeIndex); } /** @@ -222,26 +223,23 @@ export async function updateOptions({ alwaysPauseOnInterruption, ...options }: UpdateOptions = {}): Promise { - // Handle deprecated alwaysPauseOnInterruption option: - if ( - alwaysPauseOnInterruption !== undefined && - !(options.android && 'alwaysPauseOnInterruption' in options.android) - ) { - if (!options.android) options.android = {}; - options.android.alwaysPauseOnInterruption = alwaysPauseOnInterruption; - } - - // Resolve the asset for each icon - options.icon = resolveImportedPath(options.icon); - options.playIcon = resolveImportedPath(options.playIcon); - options.pauseIcon = resolveImportedPath(options.pauseIcon); - options.stopIcon = resolveImportedPath(options.stopIcon); - options.previousIcon = resolveImportedPath(options.previousIcon); - options.nextIcon = resolveImportedPath(options.nextIcon); - options.rewindIcon = resolveImportedPath(options.rewindIcon); - options.forwardIcon = resolveImportedPath(options.forwardIcon); - - return TrackPlayer.updateOptions(options); + return TrackPlayer.updateOptions({ + android: { + // Handle deprecated alwaysPauseOnInterruption option: + alwaysPauseOnInterruption: + options.android?.alwaysPauseOnInterruption ?? alwaysPauseOnInterruption, + ...options.android, + }, + icon: resolveImportedAsset(options.icon), + playIcon: resolveImportedAsset(options.playIcon), + pauseIcon: resolveImportedAsset(options.pauseIcon), + stopIcon: resolveImportedAsset(options.stopIcon), + previousIcon: resolveImportedAsset(options.previousIcon), + nextIcon: resolveImportedAsset(options.nextIcon), + rewindIcon: resolveImportedAsset(options.rewindIcon), + forwardIcon: resolveImportedAsset(options.forwardIcon), + ...options, + }); } /** @@ -255,13 +253,10 @@ export async function updateMetadataForTrack( trackIndex: number, metadata: TrackMetadataBase ): Promise { - // Clone the object before modifying it - metadata = Object.assign({}, metadata); - - // Resolve the artwork URL - metadata.artwork = resolveImportedPath(metadata.artwork); - - return TrackPlayer.updateMetadataForTrack(trackIndex, metadata); + return TrackPlayer.updateMetadataForTrack(trackIndex, { + ...metadata, + artwork: resolveImportedAssetOrPath(metadata.artwork), + }); } /** @@ -276,13 +271,10 @@ export function clearNowPlayingMetadata(): Promise { export function updateNowPlayingMetadata( metadata: NowPlayingMetadata ): Promise { - // Clone the object before modifying it - metadata = Object.assign({}, metadata); - - // Resolve the artwork URL - metadata.artwork = resolveImportedPath(metadata.artwork); - - return TrackPlayer.updateNowPlayingMetadata(metadata); + return TrackPlayer.updateNowPlayingMetadata({ + ...metadata, + artwork: resolveImportedAssetOrPath(metadata.artwork), + }); } // MARK: - Player API From ddf41254e48bb4a071b97c75ba126a5154a873a5 Mon Sep 17 00:00:00 2001 From: Kirill Zyusko Date: Mon, 24 Jul 2023 17:49:13 +0400 Subject: [PATCH 10/10] chore(optimisation): reuse initial state for progress (#2062) --- src/hooks/useProgress.ts | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/src/hooks/useProgress.ts b/src/hooks/useProgress.ts index 2316d6d3f..c5404b39d 100644 --- a/src/hooks/useProgress.ts +++ b/src/hooks/useProgress.ts @@ -5,20 +5,21 @@ import { Event } from '../constants'; import type { Progress } from '../interfaces'; import { useTrackPlayerEvents } from './useTrackPlayerEvents'; +const INITIAL_STATE = { + position: 0, + duration: 0, + buffered: 0, +}; + /** * Poll for track progress for the given interval (in miliseconds) * @param updateInterval - ms interval */ export function useProgress(updateInterval = 1000) { - const INITIAL = { - position: 0, - duration: 0, - buffered: 0, - }; - const [state, setState] = useState(INITIAL); + const [state, setState] = useState(INITIAL_STATE); useTrackPlayerEvents([Event.PlaybackActiveTrackChanged], () => { - setState(INITIAL); + setState(INITIAL_STATE); }); useEffect(() => {