@dialtribe/react-sdk 0.1.4 → 0.1.7
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/dialtribe-player.js +20 -11
- package/dist/dialtribe-player.js.map +1 -1
- package/dist/dialtribe-player.mjs +20 -11
- package/dist/dialtribe-player.mjs.map +1 -1
- package/dist/dialtribe-streamer.js +20 -11
- package/dist/dialtribe-streamer.js.map +1 -1
- package/dist/dialtribe-streamer.mjs +20 -11
- package/dist/dialtribe-streamer.mjs.map +1 -1
- package/dist/index.js +20 -11
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +20 -11
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1067,18 +1067,27 @@ function DialtribePlayer({
|
|
|
1067
1067
|
const wasLiveStream = initialPlaybackTypeRef.current === "hls";
|
|
1068
1068
|
const playerConfig = React2.useMemo(
|
|
1069
1069
|
() => ({
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1070
|
+
hls: isLiveStream ? {
|
|
1071
|
+
// Performance
|
|
1072
|
+
enableWorker: true,
|
|
1073
|
+
lowLatencyMode: true,
|
|
1074
|
+
// Live edge synchronization - start close to live, not at beginning
|
|
1075
|
+
liveSyncDurationCount: 3,
|
|
1076
|
+
// Start 3 segments behind live edge
|
|
1077
|
+
liveMaxLatencyDurationCount: 10,
|
|
1078
|
+
// Seek to live if >10 segments behind
|
|
1079
|
+
maxLiveSyncPlaybackRate: 1.5,
|
|
1080
|
+
// Speed up to catch up to live edge
|
|
1081
|
+
// Buffer settings
|
|
1082
|
+
maxLoadingDelay: 4,
|
|
1083
|
+
maxBufferLength: 30,
|
|
1084
|
+
maxBufferSize: 60 * 1e3 * 1e3,
|
|
1085
|
+
// 60MB
|
|
1086
|
+
// Bandwidth estimation
|
|
1087
|
+
minAutoBitrate: 0
|
|
1088
|
+
} : void 0
|
|
1080
1089
|
}),
|
|
1081
|
-
[
|
|
1090
|
+
[isLiveStream]
|
|
1082
1091
|
);
|
|
1083
1092
|
const formatTimestamp = (seconds) => {
|
|
1084
1093
|
if (!seconds || isNaN(seconds) || !isFinite(seconds)) return "00:00:00";
|