@livo-tv/blocks 1.31.0 → 1.32.1
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/index.cjs +27 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +27 -6
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -2865,7 +2865,10 @@ function ShaderCurtain({
|
|
|
2865
2865
|
return;
|
|
2866
2866
|
}
|
|
2867
2867
|
let cancelled = false;
|
|
2868
|
-
void import(
|
|
2868
|
+
void import(
|
|
2869
|
+
/* turbopackOptional: true */
|
|
2870
|
+
'@shadergradient/react'
|
|
2871
|
+
).then((loaded) => {
|
|
2869
2872
|
if (cancelled) return;
|
|
2870
2873
|
if (!loaded.ShaderGradientCanvas || !loaded.ShaderGradient) {
|
|
2871
2874
|
setFailed(true);
|
|
@@ -5538,7 +5541,10 @@ function useHlsPlayback({
|
|
|
5538
5541
|
async function setup() {
|
|
5539
5542
|
let Hls = null;
|
|
5540
5543
|
try {
|
|
5541
|
-
Hls = (await import(
|
|
5544
|
+
Hls = (await import(
|
|
5545
|
+
/* turbopackOptional: true */
|
|
5546
|
+
'hls.js'
|
|
5547
|
+
)).default;
|
|
5542
5548
|
} catch {
|
|
5543
5549
|
Hls = null;
|
|
5544
5550
|
}
|
|
@@ -5884,6 +5890,7 @@ function VideoPlayer({
|
|
|
5884
5890
|
const [cssFullscreen, setCssFullscreen] = React11.useState(false);
|
|
5885
5891
|
const [webkitNativeFs, setWebkitNativeFs] = React11.useState(false);
|
|
5886
5892
|
const hideTimerRef = React11.useRef(null);
|
|
5893
|
+
const lastPointerTypeRef = React11.useRef("mouse");
|
|
5887
5894
|
const liveCaptionCuesRef = React11.useRef(liveCaptionCues);
|
|
5888
5895
|
const liveLagMsRef = React11.useRef(liveLagMs);
|
|
5889
5896
|
const compactChromeRef = React11.useRef(compactChrome);
|
|
@@ -6294,6 +6301,20 @@ function VideoPlayer({
|
|
|
6294
6301
|
return next;
|
|
6295
6302
|
});
|
|
6296
6303
|
}
|
|
6304
|
+
function recordPointerType(e) {
|
|
6305
|
+
lastPointerTypeRef.current = e.pointerType;
|
|
6306
|
+
}
|
|
6307
|
+
function handlePointerMove(e) {
|
|
6308
|
+
if (e.pointerType === "mouse") lastPointerTypeRef.current = "mouse";
|
|
6309
|
+
}
|
|
6310
|
+
function handleMouseMove() {
|
|
6311
|
+
if (lastPointerTypeRef.current === "touch") return;
|
|
6312
|
+
revealControls();
|
|
6313
|
+
}
|
|
6314
|
+
function handleMouseLeave() {
|
|
6315
|
+
if (lastPointerTypeRef.current === "touch") return;
|
|
6316
|
+
if (isPlaying) setControlsVisible(false);
|
|
6317
|
+
}
|
|
6297
6318
|
function handleKeyDown(e) {
|
|
6298
6319
|
if (!active) return;
|
|
6299
6320
|
switch (e.key) {
|
|
@@ -6377,10 +6398,10 @@ function VideoPlayer({
|
|
|
6377
6398
|
cssFullscreen && "fixed inset-0 z-50 h-dvh w-dvw rounded-none",
|
|
6378
6399
|
className
|
|
6379
6400
|
),
|
|
6380
|
-
|
|
6381
|
-
|
|
6382
|
-
|
|
6383
|
-
|
|
6401
|
+
onPointerDown: recordPointerType,
|
|
6402
|
+
onPointerMove: handlePointerMove,
|
|
6403
|
+
onMouseMove: handleMouseMove,
|
|
6404
|
+
onMouseLeave: handleMouseLeave,
|
|
6384
6405
|
onKeyDown: handleKeyDown,
|
|
6385
6406
|
tabIndex: 0,
|
|
6386
6407
|
role: "region",
|