@faintlines/video-player
Advanced tools
Comparing version 1.1.5 to 1.1.10
@@ -129,3 +129,6 @@ import React, { forwardRef, useState, useRef, useEffect, useContext } from 'react'; | ||
var VideoPlayer = /*#__PURE__*/forwardRef(function (_ref, ref) { | ||
var hlsUrl = _ref.hlsUrl, | ||
var _url, _url2, _url3; | ||
var url = _ref.url, | ||
hlsUrl = _ref.hlsUrl, | ||
dashUrl = _ref.dashUrl, | ||
@@ -139,3 +142,3 @@ fileUrl = _ref.fileUrl, | ||
onProgress = _ref.onProgress, | ||
props = _objectWithoutProperties(_ref, ["hlsUrl", "dashUrl", "fileUrl", "className", "progressInterval", "playsInline", "autoPlay", "preload", "onProgress"]); | ||
props = _objectWithoutProperties(_ref, ["url", "hlsUrl", "dashUrl", "fileUrl", "className", "progressInterval", "playsInline", "autoPlay", "preload", "onProgress"]); | ||
@@ -148,2 +151,9 @@ var _useState = useState(autoPlay), | ||
var playerRef = useRef(); | ||
if (typeof url === "string") { | ||
url = { | ||
file: url | ||
}; | ||
} | ||
useEffect(function () { | ||
@@ -184,5 +194,5 @@ if (ref) { | ||
url: selectVideoUrl({ | ||
hlsUrl: hlsUrl, | ||
dashUrl: dashUrl, | ||
fileUrl: fileUrl | ||
hlsUrl: ((_url = url) === null || _url === void 0 ? void 0 : _url.hls) || hlsUrl, | ||
dashUrl: ((_url2 = url) === null || _url2 === void 0 ? void 0 : _url2.dash) || dashUrl, | ||
fileUrl: ((_url3 = url) === null || _url3 === void 0 ? void 0 : _url3.file) || fileUrl | ||
}), | ||
@@ -189,0 +199,0 @@ wrapper: Wrapper, |
{ | ||
"name": "@faintlines/video-player", | ||
"version": "1.1.5", | ||
"version": "1.1.10", | ||
"description": "", | ||
@@ -36,3 +36,3 @@ "license": "UNLICENSED", | ||
}, | ||
"gitHead": "2c1f1b8c75b5bca89274be8e3c7b8b4868837da5" | ||
"gitHead": "31e8d915d850d839574008e90cbef6ef94356296" | ||
} |
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
15038
201