softbuilders-react-video-player
Advanced tools
Comparing version 1.1.44 to 1.1.45
@@ -47,3 +47,3 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime"; | ||
const VideoPlayerComponent = ({ id, options, notes, chapters, startTime = 0, handleSaveNoteAction, poster, onPlay, onPause, }) => { | ||
var _a, _b, _c; | ||
var _a; | ||
const videoRef = useRef(undefined); | ||
@@ -262,3 +262,2 @@ const playerRef = useRef(undefined); | ||
}, []); | ||
console.log((_a = playerRef === null || playerRef === void 0 ? void 0 : playerRef.current) === null || _a === void 0 ? void 0 : _a.currentTime(), (_b = playerRef === null || playerRef === void 0 ? void 0 : playerRef.current) === null || _b === void 0 ? void 0 : _b.duration(), "player"); | ||
const [timeSeeker, setTimeSeeker] = useState("0"); | ||
@@ -281,7 +280,6 @@ useEffect(() => { | ||
updateTimeSeeker(); | ||
}, [(_c = playerRef === null || playerRef === void 0 ? void 0 : playerRef.current) === null || _c === void 0 ? void 0 : _c.currentTime()]); | ||
document.addEventListener("mousemove", (event) => { | ||
handlePlayerClick(event, true); | ||
}); | ||
return (_jsx("div", { ref: videoRefs, id: `video-container-${id}`, className: "sb-relative sb-rounded-md sb-overflow-hidden sb-w-full sb-h-full ", onMouseEnter: () => setIsHovered(true), onMouseLeave: () => setIsHovered(false), children: _jsxs("div", { className: "hover:sb-cursor-pointer sb-w-full sb-h-full", "data-vjs-player": true, children: [_jsx("div", { className: `sb-h-[3px] sb-transition- sb-duration-500 sb-delay-400 sb-z-10 ease-in-out sb-border-spacing-x-2 sb-absolute sb-bg-[red] -sb-bottom-[1.5px] ${opacity == "100" ? "sb-opacity-0" : "sb-opacity-100"}`, style: { | ||
}, [(_a = playerRef === null || playerRef === void 0 ? void 0 : playerRef.current) === null || _a === void 0 ? void 0 : _a.currentTime()]); | ||
return (_jsx("div", { ref: videoRefs, id: `video-container-${id}`, onMouseMove: () => { | ||
handlePlayerClick(event, true); | ||
}, className: "sb-relative sb-rounded-md sb-overflow-hidden sb-w-full sb-h-full ", onMouseEnter: () => setIsHovered(true), onMouseLeave: () => setIsHovered(false), children: _jsxs("div", { className: "hover:sb-cursor-pointer sb-w-full sb-h-full", "data-vjs-player": true, children: [_jsx("div", { className: `sb-h-[3px] sb-transition- sb-duration-500 sb-delay-400 sb-z-10 ease-in-out sb-border-spacing-x-2 sb-absolute sb-bg-[red] -sb-bottom-[1.5px] ${opacity == "100" ? "sb-opacity-0" : "sb-opacity-100"}`, style: { | ||
width: timeSeeker, | ||
@@ -288,0 +286,0 @@ } }), _jsx("div", { onClick: handlePlayerClick, ref: videoRef, className: "sb-h-full sb-w-full" })] }) })); |
{ | ||
"name": "softbuilders-react-video-player", | ||
"description": "Standalone video player component", | ||
"version": "1.1.44", | ||
"version": "1.1.45", | ||
"main": "dist/index.js", | ||
@@ -6,0 +6,0 @@ "types": "dist/index.d.ts", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
316527
6906