From ae7ff4fa07ce9234575664a541bbd2f557ff051c Mon Sep 17 00:00:00 2001 From: Joar Karlsson Date: Tue, 28 Apr 2026 14:23:41 +0200 Subject: [PATCH] fix: replace `absoluteFillObject` with `absoluteFill` (#4880) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Update for 0.85 * fix formatting * Delete bun.lock * chore: update deps * chore: update `absoluteFillObject` in tv example --------- Co-authored-by: Joar Karlsson Co-authored-by: Kamil Moskała <91079590+moskalakamil@users.noreply.github.com> Co-authored-by: Kamil Moskała --- examples/bare/package.json | 4 ++-- examples/expo/App.tv.tsx | 2 +- package.json | 11 ++++++----- src/Video.tsx | 12 +++++------- 4 files changed, 14 insertions(+), 15 deletions(-) diff --git a/examples/bare/package.json b/examples/bare/package.json index 47328782..71aa0a3d 100644 --- a/examples/bare/package.json +++ b/examples/bare/package.json @@ -35,8 +35,8 @@ "@react-native/metro-config": "^0.78.0", "@react-native/typescript-config": "0.73.1", "@rnx-kit/metro-config": "^2.0.0", - "@types/react": "^18.2.6", - "@types/react-test-renderer": "^18.0.0", + "@types/react": "^19.0.0", + "@types/react-test-renderer": "^19.0.0", "babel-jest": "^29.6.3", "eslint": "^8.19.0", "jest": "^29.2.1", diff --git a/examples/expo/App.tv.tsx b/examples/expo/App.tv.tsx index 3dd62581..2ffbf1b1 100644 --- a/examples/expo/App.tv.tsx +++ b/examples/expo/App.tv.tsx @@ -21,7 +21,7 @@ export default function App() { 'https://pbs.twimg.com/profile_images/1498641868397191170/6qW2XkuI_400x400.png', }, }} - style={[styles.fullScreen, StyleSheet.absoluteFillObject]} + style={[styles.fullScreen, StyleSheet.absoluteFill]} controls fullscreen resizeMode={'contain'} diff --git a/package.json b/package.json index e88e32e7..d1849fbf 100644 --- a/package.json +++ b/package.json @@ -18,7 +18,7 @@ "@react-native/eslint-config": "^0.72.2", "@release-it/conventional-changelog": "^7.0.2", "@types/jest": "^28.1.2", - "@types/react": "~19.0.0", + "@types/react": "^19.0.0", "@types/react-native-web": "^0.19.1", "@typescript-eslint/eslint-plugin": "^6.7.4", "eslint": "^8.19.0", @@ -26,12 +26,13 @@ "husky": "^9.1.7", "jest": "^29.7.0", "prettier": "^2.4.1", - "react": "18.2.0", - "react-native": "0.78.2", + "react": "19.0.0", + "react-dom": "19.0.0", + "react-native": "^0.78.0", "react-native-web": "0.20.0", - "react-native-windows": "^0.61.0-0", + "react-native-windows": "^0.78.0", "release-it": "^16.2.1", - "typescript": "5.1.6" + "typescript": "5.0.4" }, "peerDependencies": { "react": "*", diff --git a/src/Video.tsx b/src/Video.tsx index 82b73abd..789d9155 100644 --- a/src/Video.tsx +++ b/src/Video.tsx @@ -813,10 +813,10 @@ const Video = forwardRef( } // poster style - const baseStyle: StyleProp = { - ...StyleSheet.absoluteFillObject, - resizeMode: _posterResizeMode, - }; + const baseStyle: StyleProp = [ + StyleSheet.absoluteFill, + {resizeMode: _posterResizeMode}, + ]; let posterStyle: StyleProp = baseStyle; @@ -866,9 +866,7 @@ const Video = forwardRef( ]); const _style: StyleProp = useMemo( - () => ({ - ...StyleSheet.absoluteFillObject, - }), + () => [StyleSheet.absoluteFill], [], );