@streamplace/components 0.7.13 → 0.7.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/mobile-player/fullscreen.native.js +1 -15
- package/node-compile-cache/v22.15.0-x64-efe9a9df-0/37be0eec +0 -0
- package/node-compile-cache/v22.15.0-x64-efe9a9df-0/56540125 +0 -0
- package/node-compile-cache/v22.15.0-x64-efe9a9df-0/67b1eb60 +0 -0
- package/node-compile-cache/v22.15.0-x64-efe9a9df-0/7c275f90 +0 -0
- package/package.json +2 -3
- package/src/components/mobile-player/fullscreen.native.tsx +1 -17
- package/tsconfig.tsbuildinfo +1 -1
|
@@ -3,7 +3,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.Fullscreen = Fullscreen;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
6
|
-
const native_1 = require("@react-navigation/native");
|
|
7
6
|
const react_1 = require("react");
|
|
8
7
|
const react_native_1 = require("react-native");
|
|
9
8
|
const react_native_edge_to_edge_1 = require("react-native-edge-to-edge");
|
|
@@ -15,7 +14,6 @@ const VIDEO_ASPECT_RATIO = 16 / 9;
|
|
|
15
14
|
function Fullscreen(props) {
|
|
16
15
|
const ref = (0, react_1.useRef)(null);
|
|
17
16
|
const insets = (0, react_native_safe_area_context_1.useSafeAreaInsets)();
|
|
18
|
-
const navigation = (0, native_1.useNavigation)();
|
|
19
17
|
const [dimensions, setDimensions] = (0, react_1.useState)(react_native_1.Dimensions.get("window"));
|
|
20
18
|
// Get state from player store
|
|
21
19
|
const protocol = (0, __1.usePlayerStore)((x) => x.protocol);
|
|
@@ -41,10 +39,6 @@ function Fullscreen(props) {
|
|
|
41
39
|
if (fullscreen) {
|
|
42
40
|
react_native_edge_to_edge_1.SystemBars.setHidden(true);
|
|
43
41
|
console.log("setting sidebar hidden");
|
|
44
|
-
// Hide the navigation header
|
|
45
|
-
navigation.setOptions({
|
|
46
|
-
headerShown: false,
|
|
47
|
-
});
|
|
48
42
|
// Handle hardware back button
|
|
49
43
|
const backHandler = react_native_1.BackHandler.addEventListener("hardwareBackPress", () => {
|
|
50
44
|
setFullscreen(false);
|
|
@@ -56,19 +50,11 @@ function Fullscreen(props) {
|
|
|
56
50
|
}
|
|
57
51
|
else {
|
|
58
52
|
react_native_edge_to_edge_1.SystemBars.setHidden(false);
|
|
59
|
-
// Restore the navigation header
|
|
60
|
-
navigation.setOptions({
|
|
61
|
-
headerShown: true,
|
|
62
|
-
});
|
|
63
53
|
}
|
|
64
54
|
return () => {
|
|
65
55
|
react_native_edge_to_edge_1.SystemBars.setHidden(false);
|
|
66
|
-
// Ensure header is restored if component unmounts
|
|
67
|
-
navigation.setOptions({
|
|
68
|
-
headerShown: true,
|
|
69
|
-
});
|
|
70
56
|
};
|
|
71
|
-
}, [fullscreen,
|
|
57
|
+
}, [fullscreen, setFullscreen]);
|
|
72
58
|
// Handle fullscreen state changes for native video players
|
|
73
59
|
(0, react_1.useEffect)(() => {
|
|
74
60
|
// For WebRTC, we handle fullscreen manually via the custom implementation
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@streamplace/components",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.14",
|
|
4
4
|
"description": "Streamplace React (Native) Components",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "src/index.tsx",
|
|
@@ -30,7 +30,6 @@
|
|
|
30
30
|
"@atproto/crypto": "^0.4.4",
|
|
31
31
|
"@emoji-mart/react": "^1.1.1",
|
|
32
32
|
"@gorhom/bottom-sheet": "^5.1.6",
|
|
33
|
-
"@react-navigation/native": "^6.1.18",
|
|
34
33
|
"@rn-primitives/dropdown-menu": "^1.2.0",
|
|
35
34
|
"@rn-primitives/portal": "^1.3.0",
|
|
36
35
|
"@rn-primitives/slider": "^1.2.0",
|
|
@@ -54,5 +53,5 @@
|
|
|
54
53
|
"peerDependencies": {
|
|
55
54
|
"react": "*"
|
|
56
55
|
},
|
|
57
|
-
"gitHead": "
|
|
56
|
+
"gitHead": "c113e9adb79a8a0fe0009dcec815b4c93cd4198a"
|
|
58
57
|
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { useNavigation } from "@react-navigation/native";
|
|
2
1
|
import { VideoView } from "expo-video";
|
|
3
2
|
import { useEffect, useRef, useState } from "react";
|
|
4
3
|
import { BackHandler, Dimensions, StyleSheet, View } from "react-native";
|
|
@@ -18,7 +17,6 @@ const VIDEO_ASPECT_RATIO = 16 / 9;
|
|
|
18
17
|
export function Fullscreen(props: { src: string; children?: React.ReactNode }) {
|
|
19
18
|
const ref = useRef<VideoView>(null);
|
|
20
19
|
const insets = useSafeAreaInsets();
|
|
21
|
-
const navigation = useNavigation();
|
|
22
20
|
const [dimensions, setDimensions] = useState(Dimensions.get("window"));
|
|
23
21
|
|
|
24
22
|
// Get state from player store
|
|
@@ -55,11 +53,6 @@ export function Fullscreen(props: { src: string; children?: React.ReactNode }) {
|
|
|
55
53
|
SystemBars.setHidden(true);
|
|
56
54
|
console.log("setting sidebar hidden");
|
|
57
55
|
|
|
58
|
-
// Hide the navigation header
|
|
59
|
-
navigation.setOptions({
|
|
60
|
-
headerShown: false,
|
|
61
|
-
});
|
|
62
|
-
|
|
63
56
|
// Handle hardware back button
|
|
64
57
|
const backHandler = BackHandler.addEventListener(
|
|
65
58
|
"hardwareBackPress",
|
|
@@ -74,21 +67,12 @@ export function Fullscreen(props: { src: string; children?: React.ReactNode }) {
|
|
|
74
67
|
};
|
|
75
68
|
} else {
|
|
76
69
|
SystemBars.setHidden(false);
|
|
77
|
-
|
|
78
|
-
// Restore the navigation header
|
|
79
|
-
navigation.setOptions({
|
|
80
|
-
headerShown: true,
|
|
81
|
-
});
|
|
82
70
|
}
|
|
83
71
|
|
|
84
72
|
return () => {
|
|
85
73
|
SystemBars.setHidden(false);
|
|
86
|
-
// Ensure header is restored if component unmounts
|
|
87
|
-
navigation.setOptions({
|
|
88
|
-
headerShown: true,
|
|
89
|
-
});
|
|
90
74
|
};
|
|
91
|
-
}, [fullscreen,
|
|
75
|
+
}, [fullscreen, setFullscreen]);
|
|
92
76
|
|
|
93
77
|
// Handle fullscreen state changes for native video players
|
|
94
78
|
useEffect(() => {
|