@livo-tv/blocks 1.33.0 → 1.34.0
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/video.cjs +10 -5
- package/dist/video.cjs.map +1 -1
- package/dist/video.js +10 -5
- package/dist/video.js.map +1 -1
- package/package.json +1 -1
package/dist/video.js
CHANGED
|
@@ -4112,16 +4112,21 @@ function VideoPlayer({
|
|
|
4112
4112
|
if (video.paused) void video.play();
|
|
4113
4113
|
else video.pause();
|
|
4114
4114
|
}
|
|
4115
|
-
function
|
|
4115
|
+
function applyMuted(next) {
|
|
4116
4116
|
const video = videoRef.current;
|
|
4117
|
-
|
|
4118
|
-
|
|
4117
|
+
isMutedRef.current = next;
|
|
4118
|
+
setIsMuted(next);
|
|
4119
|
+
if (video) video.muted = next;
|
|
4120
|
+
}
|
|
4121
|
+
function toggleMute() {
|
|
4122
|
+
applyMuted(!isMutedRef.current);
|
|
4119
4123
|
}
|
|
4120
4124
|
function changeVolume(next) {
|
|
4121
4125
|
const video = videoRef.current;
|
|
4122
4126
|
if (!video) return;
|
|
4123
4127
|
video.volume = next;
|
|
4124
|
-
|
|
4128
|
+
setVolume(next);
|
|
4129
|
+
applyMuted(next === 0);
|
|
4125
4130
|
}
|
|
4126
4131
|
function seekTo(next) {
|
|
4127
4132
|
const video = videoRef.current;
|
|
@@ -4383,7 +4388,7 @@ function VideoPlayer({
|
|
|
4383
4388
|
children: /* @__PURE__ */ jsx(Play, { className: "size-8 translate-x-0.5", fill: "currentColor" })
|
|
4384
4389
|
}
|
|
4385
4390
|
) }),
|
|
4386
|
-
state === "ready" && autoplayState === "muted" && /* @__PURE__ */ jsxs(
|
|
4391
|
+
state === "ready" && autoplayState === "muted" && isMuted && /* @__PURE__ */ jsxs(
|
|
4387
4392
|
"button",
|
|
4388
4393
|
{
|
|
4389
4394
|
type: "button",
|