-
Notifications
You must be signed in to change notification settings - Fork 1.4k
chore: upgrade to react native 81 and expo 54 #6875
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Changes from all commits
f58a536
23ec327
abab68f
1514c7e
5f28192
c0a4d25
f27e9f5
14ecf41
58b5141
a624049
00af6b8
d181c65
d3f516b
b2c221d
5e48723
261b939
b64c1eb
e1eaf31
1998f31
7e7f3d0
64a72f6
998504c
691fb63
caedf9e
cbfe560
8f89ea2
65be6cf
08056fb
b4a596f
76cc834
e13c5a4
4fe2c97
64f4dd9
1dba726
caf9d5a
b0d5d9f
e3ccc64
2f535e3
3776737
7f04181
40d9fb9
f868d6d
504d378
54698cb
9ed2a82
baca611
fd97518
deb038d
6afa789
3937eec
acd8675
854b508
9feee82
b5aaff9
6413650
d0f3d39
a8cdebd
ebe4419
b054ed4
bcbc7fe
8a0d12c
02cd74f
e50f3ad
af3098d
b7c2b2f
22ff512
cc271ef
eb37e68
b5a87b7
a0a6854
ebd8f88
f4defa6
d66c812
7662c7f
88e8b42
c19cadf
7946eb4
d6a3237
6fc21de
7d1f242
301b0c3
8daab95
d23a7e0
7c02045
38cd2c9
930c88a
d0d218b
3bab462
cd35041
35b55df
50e1ffc
ec14b28
28d9062
fb40b8b
ae5df9f
fdaf544
05c7b5a
5064359
650104e
7144138
8db5f90
d3f23e7
c03938c
4e7cc2b
0e45349
dbffe97
d33a796
719c192
1e6da08
e8abcf1
8b410dc
b81a3ae
4a7a9fb
709d7d8
9e60c47
449360a
9b1713c
3dc77ca
9c25b88
9ff7576
28d8d4e
1ddf1c6
54c2e9d
a367e02
2b3e51a
5756896
45d1292
ac20a76
cdda960
cf08b03
cff02b6
c48a040
175bd53
1d7d89d
bf5c915
5042da6
912278c
2f1ba4a
59cae3a
1529a23
4ed67ee
0232059
01552c7
a603042
e9590e3
063ce88
f80ab8e
53d9751
cdf85b0
4ff6637
c2a6ca4
31d5e63
cfc5f2e
2116a2d
c8a5cce
291143b
bdf46e7
21f08c8
fd24f10
8048a08
fbe735c
05cacf5
be81a47
f3c0d50
6929797
d327896
09d63d8
951558d
b4cd9b5
ee7133d
7f5e04d
88be3cd
6bb597e
03e0ae0
a130cd1
a541660
6e35a0b
49eb0d8
6d0ef3a
4688922
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,11 +1,11 @@ | ||
| buildscript { | ||
| ext { | ||
| buildToolsVersion = "35.0.0" | ||
| buildToolsVersion = "36.0.0" | ||
| minSdkVersion = 24 | ||
| compileSdkVersion = 35 | ||
| targetSdkVersion = 35 | ||
| compileSdkVersion = 36 | ||
| targetSdkVersion = 36 | ||
| ndkVersion = "27.1.12297006" | ||
| kotlinVersion = "2.0.21" | ||
| kotlinVersion = "2.1.20" | ||
|
Comment on lines
+3
to
+8
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🏁 Script executed: #!/bin/bash
# Check React Native version in package.json
echo "=== React Native Version ==="
if [ -f "package.json" ]; then
rg '"react-native":\s*"[^"]*"' package.json -o
else
echo "package.json not found"
fi
# Check for Android-related configuration
echo -e "\n=== Android Configuration Files ==="
fd -e gradle . --max-depth 3 | head -20Repository: RocketChat/Rocket.Chat.ReactNative Length of output: 238 🌐 Web query:
💡 Result: Short answer: As of January 4, 2026, Android SDK 36 (Android 16 / "Baklava") is a stable, production SDK (Platform Stability reached; SDK Platform Revision 1 released). Google continues to ship quarterly minor updates (QPRs) and beta builds (QPR1–QPR3 betas/QPR images) but API 36 is stable for targeting and production use; developers should test against the latest QPR/beta images for device-specific fixes and large‑screen behavior changes. [1][2][3] Sources
🌐 Web query:
💡 Result: Short answer
Sources
🌐 Web query:
💡 Result: Short answer
Practical checklist
Sources
Verify Kotlin 2.1.20 compatibility with third-party native modules before merging. Android SDK 36 with 🤖 Prompt for AI Agents |
||
| kotlin_version = kotlinVersion | ||
| glideVersion = "4.11.0" | ||
| supportLibVersion = "28.0.0" | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,6 @@ | ||
| distributionBase=GRADLE_USER_HOME | ||
| distributionPath=wrapper/dists | ||
| distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-bin.zip | ||
| distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🌐 Web query:
💡 Result: Short answer: Yes — Gradle 8.14.3 can be used with Android API/SDK 36, provided you use a compatible Android Gradle Plugin (AGP) release (AGP 8.13.x is the AGP line that documents support for API level 36). Update the Gradle wrapper to 8.14.3 and use AGP 8.13.x (or a later AGP that lists API 36 support). [1][2] References:
🌐 Web query:
💡 Result: Short answer: Kotlin 2.1.20 is not officially supported on Gradle 8.14.3. Kotlin 2.1.20’s documented “fully supported” Gradle range ends at ~8.12.1, so Gradle 8.14.3 is newer than the officially supported maximum — it may work, but you can encounter deprecation warnings or breakage. [1][2] Recommendation: upgrade the Kotlin Gradle plugin to a 2.2.x (or later) KGP that lists Gradle 8.14 as supported (e.g., 2.2.20+ / 2.3.0 for fuller support), or use a Gradle version ≤ 8.12.1 if you must stay on Kotlin 2.1.20. [2][3] Sources:
Gradle 8.14.3 requires Kotlin 2.2.x or later — current Kotlin 2.1.20 is not officially supported. Gradle 8.14.3 is compatible with Android SDK 36 when using AGP 8.13.x or later. However, Kotlin 2.1.20 is only officially supported up to Gradle 8.12.1; using it with Gradle 8.14.3 may produce deprecation warnings or build failures. Either upgrade Kotlin to 2.2.x+ (which supports Gradle 8.14) or downgrade Gradle to 8.12.1 if staying on Kotlin 2.1.20. 🤖 Prompt for AI Agents |
||
| networkTimeout=10000 | ||
| validateDistributionUrl=true | ||
| zipStoreBase=GRADLE_USER_HOME | ||
|
|
||
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +1,4 @@ | ||
| { | ||
| "name": "RocketChatRN" | ||
| "name": "RocketChatRN", | ||
| "plugins": ["@react-native-community/datetimepicker", "expo-web-browser"] | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,21 +1,20 @@ | ||
| import React from 'react'; | ||
| import { type LayoutChangeEvent, View, TextInput, type TextInputProps, TouchableNativeFeedback } from 'react-native'; | ||
| import { PanGestureHandler, type PanGestureHandlerGestureEvent } from 'react-native-gesture-handler'; | ||
| import { Gesture, GestureDetector } from 'react-native-gesture-handler'; | ||
| import Animated, { | ||
| type SharedValue, | ||
| runOnJS, | ||
| useAnimatedGestureHandler, | ||
| useAnimatedProps, | ||
| useAnimatedStyle, | ||
| useDerivedValue, | ||
| useSharedValue | ||
| useSharedValue, | ||
| withTiming | ||
| } from 'react-native-reanimated'; | ||
| import { scheduleOnRN } from 'react-native-worklets'; | ||
|
|
||
| import styles from './styles'; | ||
| import { useTheme } from '../../theme'; | ||
| import { SEEK_HIT_SLOP, THUMB_SEEK_SIZE, ACTIVE_OFFSET_X, DEFAULT_TIME_LABEL } from './constants'; | ||
|
|
||
| Animated.addWhitelistedNativeProps({ text: true }); | ||
| const AnimatedTextInput = Animated.createAnimatedComponent(TextInput); | ||
|
|
||
| interface ISeek { | ||
|
|
@@ -50,6 +49,7 @@ const Seek = ({ currentTime, duration, loaded = false, onChangeTime }: ISeek) => | |
| const timeLabel = useSharedValue(DEFAULT_TIME_LABEL); | ||
| const scale = useSharedValue(1); | ||
| const isPanning = useSharedValue(false); | ||
| const contextX = useSharedValue(0); | ||
|
|
||
| const styleLine = useAnimatedStyle(() => ({ | ||
| width: translateX.value | ||
|
|
@@ -64,21 +64,25 @@ const Seek = ({ currentTime, duration, loaded = false, onChangeTime }: ISeek) => | |
| maxWidth.value = width; | ||
| }; | ||
|
|
||
| const onGestureEvent = useAnimatedGestureHandler<PanGestureHandlerGestureEvent, { offsetX: number }>({ | ||
| onStart: (_event, ctx) => { | ||
| const panGesture = Gesture.Pan() | ||
| .enabled(loaded) | ||
| .activeOffsetX([-ACTIVE_OFFSET_X, ACTIVE_OFFSET_X]) | ||
| .onStart(() => { | ||
| isPanning.value = true; | ||
| ctx.offsetX = translateX.value; | ||
| }, | ||
| onActive: ({ translationX }, ctx) => { | ||
| translateX.value = clamp(ctx.offsetX + translationX, 0, maxWidth.value); | ||
| scale.value = 1.3; | ||
| }, | ||
| onFinish() { | ||
| scale.value = 1; | ||
| contextX.value = translateX.value; | ||
| scale.value = withTiming(1.3, { duration: 150 }); | ||
| }) | ||
| .onUpdate(event => { | ||
| const newX = contextX.value + event.translationX; | ||
| translateX.value = clamp(newX, 0, maxWidth.value); | ||
| }) | ||
|
Comment on lines
+75
to
+78
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Scale animation triggers repeatedly on every pan update. The Move the scale-up animation to 🔧 Proposed fix .onStart(() => {
contextX.value = translateX.value;
+ scale.value = withTiming(1.3, { duration: 150 });
})
.onUpdate(event => {
const newX = contextX.value + event.translationX;
translateX.value = clamp(newX, 0, maxWidth.value);
- scale.value = withTiming(1.3, { duration: 150 });
})🤖 Prompt for AI Agents |
||
| .onEnd(() => { | ||
| scheduleOnRN(onChangeTime, Math.round(currentTime.value * 1000)); | ||
| }) | ||
| .onFinalize(() => { | ||
| isPanning.value = false; | ||
| runOnJS(onChangeTime)(Math.round(currentTime.value * 1000)); | ||
| } | ||
| }); | ||
| scale.value = withTiming(1, { duration: 150 }); | ||
| }); | ||
|
|
||
| useDerivedValue(() => { | ||
| if (isPanning.value) { | ||
|
|
@@ -118,9 +122,9 @@ const Seek = ({ currentTime, duration, loaded = false, onChangeTime }: ISeek) => | |
| <View style={[styles.line, { backgroundColor: colors.strokeLight }]}> | ||
| <Animated.View style={[styles.line, styleLine, { backgroundColor: colors.buttonBackgroundPrimaryDefault }]} /> | ||
| </View> | ||
| <PanGestureHandler enabled={loaded} onGestureEvent={onGestureEvent} activeOffsetX={[-ACTIVE_OFFSET_X, ACTIVE_OFFSET_X]}> | ||
| <GestureDetector gesture={panGesture}> | ||
| <Animated.View hitSlop={SEEK_HIT_SLOP} style={[styles.thumbSeek, { backgroundColor: thumbColor }, styleThumb]} /> | ||
| </PanGestureHandler> | ||
| </GestureDetector> | ||
| </View> | ||
| </View> | ||
| </TouchableNativeFeedback> | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
Repository: RocketChat/Rocket.Chat.ReactNative
Length of output: 596
🏁 Script executed:
Repository: RocketChat/Rocket.Chat.ReactNative
Length of output: 1441
Add
usesCleartextTraffictomanifestPlaceholdersinandroid/app/build.gradle.The placeholder
${usesCleartextTraffic}is used inAndroidManifest.xmlbut is not defined in themanifestPlaceholdersmap. Updateandroid/app/build.gradleline 95 to include this variable:Without this definition, the build will fail or the placeholder will remain unexpanded in the manifest.
🤖 Prompt for AI Agents