Skip to content

Commit a59ad5f

Browse files
committed
chore: sync with upstream
1 parent ef3bcfe commit a59ad5f

File tree

11 files changed

+189
-242
lines changed

11 files changed

+189
-242
lines changed

packages/helloworld/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
"test": "jest"
1313
},
1414
"dependencies": {
15-
"react": "18.3.1",
16-
"@callstack/react-native-visionos": "1000.0.0"
15+
"react": "19.0.0",
16+
"@callstack/react-native-visionos": "0.77.0-main"
1717
},
1818
"devDependencies": {
1919
"@babel/core": "^7.25.2",

packages/out-of-tree-platforms/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
"dist"
2020
],
2121
"devDependencies": {
22-
"metro-resolver": "^0.81.0-alpha.0"
22+
"metro-resolver": "^0.81.0"
2323
},
2424
"engines": {
2525
"node": ">=18"

packages/react-native/Libraries/AppDelegate/RCTAppDelegate.mm

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,8 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(
4949
return YES;
5050
}
5151

52+
53+
#if !TARGET_OS_VISION
5254
- (void)loadReactNativeWindow:(NSDictionary *)launchOptions
5355
{
5456
UIView *rootView = [self.rootViewFactory viewWithModuleName:self.moduleName
@@ -62,6 +64,7 @@ - (void)loadReactNativeWindow:(NSDictionary *)launchOptions
6264
_window.rootViewController = rootViewController;
6365
[_window makeKeyAndVisible];
6466
}
67+
#endif
6568

6669
#pragma mark - UISceneDelegate
6770

packages/react-native/Libraries/AppDelegate/RCTRootViewFactory.mm

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,7 @@ - (UIView *)viewWithModuleName:(NSString *)moduleName
157157
surfaceHostingProxyRootView.backgroundColor = [UIColor clearColor];
158158
#else
159159
surfaceHostingProxyRootView.backgroundColor = [UIColor systemBackgroundColor];
160+
#endif
160161
if (_configuration.customizeRootView != nil) {
161162
_configuration.customizeRootView(surfaceHostingProxyRootView);
162163
}

packages/react-native/Libraries/Text/TextInput/Multiline/RCTUITextView.mm

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,7 @@ - (void)textDidChange
138138

139139
- (void)setDisableKeyboardShortcuts:(BOOL)disableKeyboardShortcuts
140140
{
141+
#if TARGET_OS_IOS
141142
// Initialize the initial values only once
142143
if (_initialValueLeadingBarButtonGroups == nil) {
143144
// Capture initial values of leading and trailing button groups
@@ -153,6 +154,7 @@ - (void)setDisableKeyboardShortcuts:(BOOL)disableKeyboardShortcuts
153154
self.inputAssistantItem.leadingBarButtonGroups = _initialValueLeadingBarButtonGroups;
154155
self.inputAssistantItem.trailingBarButtonGroups = _initialValueTrailingBarButtonGroups;
155156
}
157+
#endif
156158
_disableKeyboardShortcuts = disableKeyboardShortcuts;
157159
}
158160

packages/react-native/Libraries/Text/TextInput/RCTBaseTextInputView.mm

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -400,6 +400,7 @@ - (void)setInputAccessoryViewButtonLabel:(NSString *)inputAccessoryViewButtonLab
400400

401401
- (void)setDisableKeyboardShortcuts:(BOOL)disableKeyboardShortcuts
402402
{
403+
#if TARGET_OS_IOS
403404
// Initialize the initial values only once
404405
if (_initialValueLeadingBarButtonGroups == nil) {
405406
// Capture initial values of leading and trailing button groups
@@ -415,6 +416,7 @@ - (void)setDisableKeyboardShortcuts:(BOOL)disableKeyboardShortcuts
415416
self.backedTextInputView.inputAssistantItem.leadingBarButtonGroups = _initialValueLeadingBarButtonGroups;
416417
self.backedTextInputView.inputAssistantItem.trailingBarButtonGroups = _initialValueTrailingBarButtonGroups;
417418
}
419+
#endif
418420
}
419421

420422
#pragma mark - RCTBackedTextInputDelegate

packages/react-native/Libraries/Text/TextInput/Singleline/RCTUITextField.mm

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,7 @@ - (void)setSecureTextEntry:(BOOL)secureTextEntry
121121

122122
- (void)setDisableKeyboardShortcuts:(BOOL)disableKeyboardShortcuts
123123
{
124+
#if TARGET_OS_IOS
124125
// Initialize the initial values only once
125126
if (_initialValueLeadingBarButtonGroups == nil) {
126127
// Capture initial values of leading and trailing button groups
@@ -136,6 +137,7 @@ - (void)setDisableKeyboardShortcuts:(BOOL)disableKeyboardShortcuts
136137
self.inputAssistantItem.leadingBarButtonGroups = _initialValueLeadingBarButtonGroups;
137138
self.inputAssistantItem.trailingBarButtonGroups = _initialValueTrailingBarButtonGroups;
138139
}
140+
#endif
139141
_disableKeyboardShortcuts = disableKeyboardShortcuts;
140142
}
141143

packages/react-native/React/Base/RCTUtils.m

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -610,6 +610,7 @@ BOOL RCTRunningInAppExtension(void)
610610
}
611611

612612
UIScene *sceneToUse = foregroundActiveScene ? foregroundActiveScene : foregroundInactiveScene;
613+
UIWindowScene *windowScene = (UIWindowScene *)sceneToUse;
613614

614615
#if TARGET_OS_VISION
615616
// Ornaments are supported only on visionOS.

packages/react-native/React/Views/ScrollView/RCTScrollView.m

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -321,11 +321,13 @@ - (void)_keyboardWillChangeFrame:(NSNotification *)notification
321321
// Text field active region is below visible area with keyboard - update diff to bring into view
322322
contentDiff = endFrame.origin.y - focusEnd;
323323
} else {
324+
#if !TARGET_OS_VISION
324325
UIView *inputAccessoryView = _firstResponderViewOutsideScrollView.inputAccessoryView;
325326
if (inputAccessoryView) {
326327
// Text input view is within the inputAccessoryView.
327328
contentDiff = endFrame.origin.y - beginFrame.origin.y;
328329
}
330+
#endif
329331
}
330332
} else if (endFrame.origin.y <= beginFrame.origin.y) {
331333
// Keyboard opened for other reason

0 commit comments

Comments
 (0)