From 8c03232b021b4b088af2a5796015a4540c14da9e Mon Sep 17 00:00:00 2001 From: Huong Nguyen Date: Wed, 10 May 2023 14:33:07 +0700 Subject: [PATCH] MDL-77654 Libraries: Upgrade ogv.js tech plugin for VideoJS to 0.2.1 --- .../amd/build/videojs-ogvjs-lazy.min.js | 8 +- .../amd/build/videojs-ogvjs-lazy.min.js.map | 2 +- .../videojs/amd/src/videojs-ogvjs-lazy.js | 1104 ++++++++--------- media/player/videojs/thirdpartylibs.xml | 2 +- 4 files changed, 557 insertions(+), 559 deletions(-) diff --git a/media/player/videojs/amd/build/videojs-ogvjs-lazy.min.js b/media/player/videojs/amd/build/videojs-ogvjs-lazy.min.js index 6c9112e8465..05e6c0e20c6 100644 --- a/media/player/videojs/amd/build/videojs-ogvjs-lazy.min.js +++ b/media/player/videojs/amd/build/videojs-ogvjs-lazy.min.js @@ -1,10 +1,10 @@ /** * videojs-ogvjs - * @version 0.1.2 - * @copyright 2021 Huong Nguyen + * @version 0.2.1 + * @copyright 2023 Huong Nguyen * @license MIT */ -/*! @name videojs-ogvjs @version 0.1.2 @license MIT */ -var global,factory;global=window,factory=function(videojs,ogvBase){function _interopDefaultLegacy(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var videojs__default=_interopDefaultLegacy(videojs),OGVCompat__default=_interopDefaultLegacy(ogvBase.OGVCompat),OGVLoader__default=_interopDefaultLegacy(ogvBase.OGVLoader),OGVPlayer__default=_interopDefaultLegacy(ogvBase.OGVPlayer);function createCommonjsModule(fn,basedir,module){return fn(module={path:basedir,exports:{},require:function(path,base){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==base&&module.path)}},module.exports),module.exports}var setPrototypeOf=createCommonjsModule((function(module){function _setPrototypeOf(o,p){return module.exports=_setPrototypeOf=Object.setPrototypeOf||function(o,p){return o.__proto__=p,o},module.exports.default=module.exports,module.exports.__esModule=!0,_setPrototypeOf(o,p)}module.exports=_setPrototypeOf,module.exports.default=module.exports,module.exports.__esModule=!0})),inheritsLoose=createCommonjsModule((function(module){module.exports=function(subClass,superClass){subClass.prototype=Object.create(superClass.prototype),subClass.prototype.constructor=subClass,setPrototypeOf(subClass,superClass)},module.exports.default=module.exports,module.exports.__esModule=!0})),Tech=videojs__default.default.getComponent("Tech"),getDeviceOS=function(){var ua=navigator.userAgent;return/android/i.test(ua)?"Android":/iPad|iPhone|iPod/.test(ua)?"iPhoneOS":"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1?"iPadOS":"Other"},OgvJS=function(_Tech){function OgvJS(options,ready){var _this;return(_this=_Tech.call(this,options,ready)||this).el_.src=options.source.src,OgvJS.setIfAvailable(_this.el_,"autoplay",options.autoplay),OgvJS.setIfAvailable(_this.el_,"loop",options.loop),OgvJS.setIfAvailable(_this.el_,"poster",options.poster),OgvJS.setIfAvailable(_this.el_,"preload",options.preload),_this.on("loadedmetadata",(function(){if("iPhoneOS"===getDeviceOS()){var canvas=this.el_.getElementsByTagName("canvas")[0];canvas.style.removeProperty("width"),canvas.style.removeProperty("margin")}this.triggerReady()})),_this}inheritsLoose(OgvJS,_Tech);var _proto=OgvJS.prototype;return _proto.createEl=function(){var options=this.options_;if(!options.base)throw new Error("Please specify the base for the ogv.js library");OGVLoader__default.default.base=options.base;var el=new OGVPlayer__default.default(options);return el.className+=" vjs-tech",options.tag=el,el},_proto.play=function(){this.el_.play()},_proto.playbackRate=function(){return this.el_.playbackRate||1},_proto.setPlaybackRate=function(val){this.el_.hasOwnProperty("playbackRate")&&(this.el_.playbackRate=val)},_proto.played=function(){return this.el_.played},_proto.pause=function(){this.el_.pause()},_proto.paused=function(){return this.el_.paused},_proto.currentTime=function(){return this.el_.currentTime},_proto.setCurrentTime=function(seconds){try{this.el_.currentTime=seconds}catch(e){videojs__default.default.log(e,"Media is not ready. (Video.JS)")}},_proto.duration=function(){return this.el_.duration&&this.el_.duration!==1/0?this.el_.duration:0},_proto.buffered=function(){return this.el_.buffered},_proto.volume=function(){return this.el_.hasOwnProperty("volume")?this.el_.volume:1},_proto.setVolume=function(percentAsDecimal){"iPhoneOS"!==getDeviceOS()&&this.el_.hasOwnProperty("volume")&&(this.el_.volume=percentAsDecimal)},_proto.muted=function(){return this.el_.muted},_proto.setMuted=function(muted){this.el_.muted=!!muted},_proto.defaultMuted=function(){return this.el_.defaultMuted||!1},_proto.width=function(){return this.el_.offsetWidth},_proto.height=function(){return this.el_.offsetHeight},_proto.videoWidth=function(){return this.el_.videoWidth},_proto.videoHeight=function(){return this.el_.videoHeight},_proto.src=function(_src){if(void 0===_src)return this.el_.src;this.el_.src=_src},_proto.load=function(){this.el_.load()},_proto.currentSrc=function(){return this.currentSource_?this.currentSource_.src:this.el_.currentSrc},_proto.poster=function(){return this.el_.poster},_proto.setPoster=function(url){this.el_.poster=url},_proto.preload=function(){return this.el_.preload||"none"},_proto.setPreload=function(val){this.el_.hasOwnProperty("preload")&&(this.el_.preload=val)},_proto.autoplay=function(){return this.el_.autoplay||!1},_proto.setAutoplay=function(val){this.el_.hasOwnProperty("autoplay")&&(this.el_.autoplay=!!val)},_proto.controls=function(){return this.el_.controls||!1},_proto.setControls=function(val){this.el_.hasOwnProperty("controls")&&(this.el_.controls=!!val)},_proto.loop=function(){return this.el_.loop||!1},_proto.setLoop=function(val){this.el_.hasOwnProperty("loop")&&(this.el_.loop=!!val)},_proto.seekable=function(){return this.el_.seekable},_proto.seeking=function(){return this.el_.seeking},_proto.ended=function(){return this.el_.ended},_proto.networkState=function(){return this.el_.networkState},_proto.readyState=function(){return this.el_.readyState},_proto.supportsFullScreen=function(){return!1},_proto.error=function(){return this.el_.error},OgvJS}(Tech);return OgvJS.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","resize","volumechange"],OgvJS.setIfAvailable=function(el,name,value){el.hasOwnProperty(name)&&(el[name]=value)},OgvJS.isSupported=function(){return OGVCompat__default.default.supported("OGVPlayer")},OgvJS.canPlayType=function(type){return-1!==type.indexOf("/ogg")||type.indexOf("/webm")?"maybe":""},OgvJS.canPlaySource=function(srcObj){return OgvJS.canPlayType(srcObj.type)},OgvJS.canControlVolume=function(){return"iPhoneOS"!==getDeviceOS()&&(new OGVPlayer__default.default).hasOwnProperty("volume")},OgvJS.canMuteVolume=function(){return!0},OgvJS.canControlPlaybackRate=function(){return!0},OgvJS.supportsNativeTextTracks=function(){return!1},OgvJS.supportsFullscreenResize=function(){return!0},OgvJS.supportsProgressEvents=function(){return!0},OgvJS.supportsTimeupdateEvents=function(){return!0},[["featuresVolumeControl","canControlVolume"],["featuresMuteControl","canMuteVolume"],["featuresPlaybackRate","canControlPlaybackRate"],["featuresNativeTextTracks","supportsNativeTextTracks"],["featuresFullscreenResize","supportsFullscreenResize"],["featuresProgressEvents","supportsProgressEvents"],["featuresTimeupdateEvents","supportsTimeupdateEvents"]].forEach((function(_ref){var key=_ref[0],fn=_ref[1];!function(obj,key,getValue,setter){void 0===setter&&(setter=!0);var set=function(value){Object.defineProperty(obj,key,{value:value,enumerable:!0,writable:!0})},options={configurable:!0,enumerable:!0,get:function(){var value=getValue();return set(value),value}};setter&&(options.set=set),Object.defineProperty(obj,key,options)}(OgvJS.prototype,key,(function(){OgvJS[fn]()}),!0)})),Tech.registerTech("OgvJS",OgvJS),OgvJS},"object"==typeof exports&&"undefined"!=typeof module?module.exports=factory(require("video.js"),require("OGVCompat"),require("OGVLoader"),require("OGVPlayer")):"function"==typeof define&&define.amd?define("media_videojs/videojs-ogvjs-lazy",["media_videojs/video-lazy","./local/ogv/ogv"],factory):(global="undefined"!=typeof globalThis?globalThis:global||self).videojsOgvjs=factory(global.videojs,global.OGVCompat,global.OGVLoader,global.OGVPlayer); +/*! @name videojs-ogvjs @version 0.2.1 @license MIT */ +var global,factory;global=window,factory=function(videojs,ogvBase){function _interopDefaultLegacy(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var videojs__default=_interopDefaultLegacy(videojs),OGVCompat__default=_interopDefaultLegacy(ogvBase.OGVCompat),OGVLoader__default=_interopDefaultLegacy(ogvBase.OGVLoader),OGVPlayer__default=_interopDefaultLegacy(ogvBase.OGVPlayer);function createCommonjsModule(fn,basedir,module){return fn(module={path:basedir,exports:{},require:function(path,base){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==base&&module.path)}},module.exports),module.exports}var setPrototypeOf=createCommonjsModule((function(module){function _setPrototypeOf(o,p){return module.exports=_setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(o,p){return o.__proto__=p,o},module.exports.__esModule=!0,module.exports.default=module.exports,_setPrototypeOf(o,p)}module.exports=_setPrototypeOf,module.exports.__esModule=!0,module.exports.default=module.exports})),inheritsLoose=createCommonjsModule((function(module){module.exports=function(subClass,superClass){subClass.prototype=Object.create(superClass.prototype),subClass.prototype.constructor=subClass,setPrototypeOf(subClass,superClass)},module.exports.__esModule=!0,module.exports.default=module.exports})),Tech=videojs__default.default.getComponent("Tech"),getDeviceOS=function(){var ua=navigator.userAgent;return/android/i.test(ua)?"Android":/iPad|iPhone|iPod/.test(ua)?"iPhoneOS":"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1?"iPadOS":"Other"},OgvJS=function(_Tech){function OgvJS(options,ready){var _this;return(_this=_Tech.call(this,options,ready)||this).el_.src=options.source.src,OgvJS.setIfAvailable(_this.el_,"autoplay",options.autoplay),OgvJS.setIfAvailable(_this.el_,"loop",options.loop),OgvJS.setIfAvailable(_this.el_,"poster",options.poster),OgvJS.setIfAvailable(_this.el_,"preload",options.preload),_this.on("loadedmetadata",(function(){if("iPhoneOS"===getDeviceOS()){var canvas=_this.el_.getElementsByTagName("canvas")[0];canvas.style.removeProperty("width"),canvas.style.removeProperty("margin")}})),_this.triggerReady(),_this}inheritsLoose(OgvJS,_Tech);var _proto=OgvJS.prototype;return _proto.createEl=function(){var options=this.options_;if(!options.base)throw new Error("Please specify the base for the ogv.js library");OGVLoader__default.default.base=options.base;var el=new OGVPlayer__default.default(options);return el.className+=" vjs-tech",options.tag=el,el},_proto.play=function(){this.el_.play()},_proto.playbackRate=function(){return this.el_.playbackRate||1},_proto.setPlaybackRate=function(val){this.el_.hasOwnProperty("playbackRate")&&(this.el_.playbackRate=val)},_proto.played=function(){return this.el_.played},_proto.pause=function(){this.el_.pause()},_proto.paused=function(){return this.el_.paused},_proto.currentTime=function(){return this.el_.currentTime},_proto.setCurrentTime=function(seconds){try{this.el_.currentTime=seconds}catch(e){videojs__default.default.log(e,"Media is not ready. (Video.JS)")}},_proto.duration=function(){return this.el_.duration&&this.el_.duration!==1/0?this.el_.duration:0},_proto.buffered=function(){return this.el_.buffered},_proto.volume=function(){return this.el_.hasOwnProperty("volume")?this.el_.volume:1},_proto.setVolume=function(percentAsDecimal){"iPhoneOS"!==getDeviceOS()&&"iPadOS"!==getDeviceOS()&&this.el_.hasOwnProperty("volume")&&(this.el_.volume=percentAsDecimal)},_proto.muted=function(){return this.el_.muted},_proto.setMuted=function(muted){this.el_.muted=!!muted},_proto.defaultMuted=function(){return this.el_.defaultMuted||!1},_proto.width=function(){return this.el_.offsetWidth},_proto.height=function(){return this.el_.offsetHeight},_proto.videoWidth=function(){return this.el_.videoWidth},_proto.videoHeight=function(){return this.el_.videoHeight},_proto.src=function(_src){if(void 0===_src)return this.el_.src;this.el_.src=_src},_proto.load=function(){this.el_.load()},_proto.currentSrc=function(){return this.currentSource_?this.currentSource_.src:this.el_.currentSrc},_proto.poster=function(){return this.el_.poster},_proto.setPoster=function(url){this.el_.poster=url},_proto.preload=function(){return this.el_.preload||"none"},_proto.setPreload=function(val){this.el_.hasOwnProperty("preload")&&(this.el_.preload=val)},_proto.autoplay=function(){return this.el_.autoplay||!1},_proto.setAutoplay=function(val){this.el_.hasOwnProperty("autoplay")&&(this.el_.autoplay=!!val)},_proto.controls=function(){return this.el_.controls||!1},_proto.setControls=function(val){this.el_.hasOwnProperty("controls")&&(this.el_.controls=!!val)},_proto.loop=function(){return this.el_.loop||!1},_proto.setLoop=function(val){this.el_.hasOwnProperty("loop")&&(this.el_.loop=!!val)},_proto.seekable=function(){return this.el_.seekable},_proto.seeking=function(){return this.el_.seeking},_proto.ended=function(){return this.el_.ended},_proto.networkState=function(){return this.el_.networkState},_proto.readyState=function(){return this.el_.readyState},_proto.supportsFullScreen=function(){return!1},_proto.error=function(){return this.el_.error},OgvJS}(Tech);return OgvJS.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","resize","volumechange"],OgvJS.setIfAvailable=function(el,name,value){el.hasOwnProperty(name)&&(el[name]=value)},OgvJS.isSupported=function(){return OGVCompat__default.default.supported("OGVPlayer")},OgvJS.canPlayType=function(type){return-1!==type.indexOf("/ogg")||type.indexOf("/webm")?"maybe":""},OgvJS.canPlaySource=function(srcObj){return OgvJS.canPlayType(srcObj.type)},OgvJS.canControlVolume=function(){return"iPhoneOS"!==getDeviceOS()&&"iPadOS"!==getDeviceOS()&&(new OGVPlayer__default.default).hasOwnProperty("volume")},OgvJS.canMuteVolume=function(){return!0},OgvJS.canControlPlaybackRate=function(){return!0},OgvJS.supportsNativeTextTracks=function(){return!1},OgvJS.supportsFullscreenResize=function(){return!0},OgvJS.supportsProgressEvents=function(){return!0},OgvJS.supportsTimeupdateEvents=function(){return!0},[["featuresVolumeControl","canControlVolume"],["featuresMuteControl","canMuteVolume"],["featuresPlaybackRate","canControlPlaybackRate"],["featuresNativeTextTracks","supportsNativeTextTracks"],["featuresFullscreenResize","supportsFullscreenResize"],["featuresProgressEvents","supportsProgressEvents"],["featuresTimeupdateEvents","supportsTimeupdateEvents"]].forEach((function(_ref){var key=_ref[0],fn=_ref[1];!function(obj,key,getValue,setter){void 0===setter&&(setter=!0);var set=function(value){Object.defineProperty(obj,key,{value:value,enumerable:!0,writable:!0})},options={configurable:!0,enumerable:!0,get:function(){var value=getValue();return set(value),value}};setter&&(options.set=set),Object.defineProperty(obj,key,options)}(OgvJS.prototype,key,(function(){return OgvJS[fn]()}),!0)})),Tech.registerTech("OgvJS",OgvJS),OgvJS},"object"==typeof exports&&"undefined"!=typeof module?module.exports=factory(require("video.js"),require("OGVCompat"),require("OGVLoader"),require("OGVPlayer")):"function"==typeof define&&define.amd?define("media_videojs/videojs-ogvjs-lazy",["media_videojs/video-lazy","./local/ogv/ogv"],factory):(global="undefined"!=typeof globalThis?globalThis:global||self).videojsOgvjs=factory(global.videojs,global.OGVCompat,global.OGVLoader,global.OGVPlayer); //# sourceMappingURL=videojs-ogvjs-lazy.min.js.map \ No newline at end of file diff --git a/media/player/videojs/amd/build/videojs-ogvjs-lazy.min.js.map b/media/player/videojs/amd/build/videojs-ogvjs-lazy.min.js.map index 6e2cd4c708d..925ad9049e0 100644 --- a/media/player/videojs/amd/build/videojs-ogvjs-lazy.min.js.map +++ b/media/player/videojs/amd/build/videojs-ogvjs-lazy.min.js.map @@ -1 +1 @@ -{"version":3,"file":"videojs-ogvjs-lazy.min.js","sources":["../src/videojs-ogvjs-lazy.js"],"sourcesContent":["/**\n * videojs-ogvjs\n * @version 0.1.2\n * @copyright 2021 Huong Nguyen \n * @license MIT\n */\n/*! @name videojs-ogvjs @version 0.1.2 @license MIT */\n(function (global, factory) {\n\ttypeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('video.js'), require('OGVCompat'), require('OGVLoader'), require('OGVPlayer')) :\n\ttypeof define === 'function' && define.amd ? define(['media_videojs/video-lazy', './local/ogv/ogv'], factory) :\n\t(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.videojsOgvjs = factory(global.videojs, global.OGVCompat, global.OGVLoader, global.OGVPlayer));\n}(this, (function (videojs, ogvBase) { 'use strict';\n\n\tfunction _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }\n\n\tvar videojs__default = /*#__PURE__*/_interopDefaultLegacy(videojs);\n\tvar OGVCompat__default = /*#__PURE__*/_interopDefaultLegacy(ogvBase.OGVCompat);\n\tvar OGVLoader__default = /*#__PURE__*/_interopDefaultLegacy(ogvBase.OGVLoader);\n\tvar OGVPlayer__default = /*#__PURE__*/_interopDefaultLegacy(ogvBase.OGVPlayer);\n\n\tfunction createCommonjsModule(fn, basedir, module) {\n\t\treturn module = {\n\t\t path: basedir,\n\t\t exports: {},\n\t\t require: function (path, base) {\n\t return commonjsRequire(path, (base === undefined || base === null) ? module.path : base);\n\t }\n\t\t}, fn(module, module.exports), module.exports;\n\t}\n\n\tfunction commonjsRequire () {\n\t\tthrow new Error('Dynamic requires are not currently supported by @rollup/plugin-commonjs');\n\t}\n\n\tvar setPrototypeOf = createCommonjsModule(function (module) {\n\t function _setPrototypeOf(o, p) {\n\t module.exports = _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {\n\t o.__proto__ = p;\n\t return o;\n\t };\n\n\t module.exports[\"default\"] = module.exports, module.exports.__esModule = true;\n\t return _setPrototypeOf(o, p);\n\t }\n\n\t module.exports = _setPrototypeOf;\n\t module.exports[\"default\"] = module.exports, module.exports.__esModule = true;\n\t});\n\n\tvar inheritsLoose = createCommonjsModule(function (module) {\n\t function _inheritsLoose(subClass, superClass) {\n\t subClass.prototype = Object.create(superClass.prototype);\n\t subClass.prototype.constructor = subClass;\n\t setPrototypeOf(subClass, superClass);\n\t }\n\n\t module.exports = _inheritsLoose;\n\t module.exports[\"default\"] = module.exports, module.exports.__esModule = true;\n\t});\n\n\tvar Tech = videojs__default['default'].getComponent('Tech');\n\tvar androidOS = 'Android';\n\tvar iPhoneOS = 'iPhoneOS';\n\tvar iPadOS = 'iPadOS';\n\tvar otherOS = 'Other';\n\t/**\n\t * Object.defineProperty but \"lazy\", which means that the value is only set after\n\t * it retrieved the first time, rather than being set right away.\n\t *\n\t * @param {Object} obj the object to set the property on.\n\t * @param {string} key the key for the property to set.\n\t * @param {Function} getValue the function used to get the value when it is needed.\n\t * @param {boolean} setter whether a setter should be allowed or not.\n\t */\n\n\tvar defineLazyProperty = function defineLazyProperty(obj, key, getValue, setter) {\n\t if (setter === void 0) {\n\t setter = true;\n\t }\n\n\t var set = function set(value) {\n\t Object.defineProperty(obj, key, {\n\t value: value,\n\t enumerable: true,\n\t writable: true\n\t });\n\t };\n\n\t var options = {\n\t configurable: true,\n\t enumerable: true,\n\t get: function get() {\n\t var value = getValue();\n\t set(value);\n\t return value;\n\t }\n\t };\n\n\t if (setter) {\n\t options.set = set;\n\t }\n\n\t return Object.defineProperty(obj, key, options);\n\t};\n\t/**\n\t * Get the device's OS.\n\t *\n\t * @return {string} Device's OS.\n\t */\n\n\n\tvar getDeviceOS = function getDeviceOS() {\n\t /* global navigator */\n\t var ua = navigator.userAgent;\n\n\t if (/android/i.test(ua)) {\n\t return androidOS;\n\t } else if (/iPad|iPhone|iPod/.test(ua)) {\n\t return iPhoneOS;\n\t } else if (navigator.platform === 'MacIntel' && navigator.maxTouchPoints > 1) {\n\t return iPadOS;\n\t }\n\n\t return otherOS;\n\t};\n\t/**\n\t * OgvJS Media Controller - Wrapper for ogv.js Media API\n\t *\n\t * @mixes Tech~SourceHandlerAdditions\n\t * @extends Tech\n\t */\n\n\n\tvar OgvJS = /*#__PURE__*/function (_Tech) {\n\t inheritsLoose(OgvJS, _Tech);\n\n\t /**\n\t * Create an instance of this Tech.\n\t *\n\t * @param {Object} [options] The key/value store of player options.\n\t * @param {Component~ReadyCallback} ready Callback function to call when the `OgvJS` Tech is ready.\n\t */\n\t function OgvJS(options, ready) {\n\t var _this;\n\n\t _this = _Tech.call(this, options, ready) || this;\n\t _this.el_.src = options.source.src;\n\t OgvJS.setIfAvailable(_this.el_, 'autoplay', options.autoplay);\n\t OgvJS.setIfAvailable(_this.el_, 'loop', options.loop);\n\t OgvJS.setIfAvailable(_this.el_, 'poster', options.poster);\n\t OgvJS.setIfAvailable(_this.el_, 'preload', options.preload);\n\n\t _this.on('loadedmetadata', function () {\n\t if (getDeviceOS() === iPhoneOS) {\n\t // iPhoneOS add some inline styles to the canvas, we need to remove it.\n\t var canvas = this.el_.getElementsByTagName('canvas')[0];\n\t canvas.style.removeProperty('width');\n\t canvas.style.removeProperty('margin');\n\t }\n\n\t this.triggerReady();\n\t });\n\n\t return _this;\n\t }\n\t /**\n\t * Create the 'OgvJS' Tech's DOM element.\n\t *\n\t * @return {Element} The element that gets created.\n\t */\n\n\n\t var _proto = OgvJS.prototype;\n\n\t _proto.createEl = function createEl() {\n\t var options = this.options_;\n\n\t if (options.base) {\n\t OGVLoader__default['default'].base = options.base;\n\t } else {\n\t throw new Error('Please specify the base for the ogv.js library');\n\t }\n\n\t var el = new OGVPlayer__default['default'](options);\n\t el.className += ' vjs-tech';\n\t options.tag = el;\n\t return el;\n\t }\n\t /**\n\t * Start playback\n\t *\n\t * @method play\n\t */\n\t ;\n\n\t _proto.play = function play() {\n\t this.el_.play();\n\t }\n\t /**\n\t * Get the current playback speed.\n\t *\n\t * @return {number}\n\t * @method playbackRate\n\t */\n\t ;\n\n\t _proto.playbackRate = function playbackRate() {\n\t return this.el_.playbackRate || 1;\n\t }\n\t /**\n\t * Set the playback speed.\n\t *\n\t * @param {number} val Speed for the player to play.\n\t * @method setPlaybackRate\n\t */\n\t ;\n\n\t _proto.setPlaybackRate = function setPlaybackRate(val) {\n\t if (this.el_.hasOwnProperty('playbackRate')) {\n\t this.el_.playbackRate = val;\n\t }\n\t }\n\t /**\n\t * Returns a TimeRanges object that represents the ranges of the media resource that the user agent has played.\n\t *\n\t * @return {TimeRangeObject} the range of points on the media timeline that has been reached through normal playback\n\t */\n\t ;\n\n\t _proto.played = function played() {\n\t return this.el_.played;\n\t }\n\t /**\n\t * Pause playback\n\t *\n\t * @method pause\n\t */\n\t ;\n\n\t _proto.pause = function pause() {\n\t this.el_.pause();\n\t }\n\t /**\n\t * Is the player paused or not.\n\t *\n\t * @return {boolean}\n\t * @method paused\n\t */\n\t ;\n\n\t _proto.paused = function paused() {\n\t return this.el_.paused;\n\t }\n\t /**\n\t * Get current playing time.\n\t *\n\t * @return {number}\n\t * @method currentTime\n\t */\n\t ;\n\n\t _proto.currentTime = function currentTime() {\n\t return this.el_.currentTime;\n\t }\n\t /**\n\t * Set current playing time.\n\t *\n\t * @param {number} seconds Current time of audio/video.\n\t * @method setCurrentTime\n\t */\n\t ;\n\n\t _proto.setCurrentTime = function setCurrentTime(seconds) {\n\t try {\n\t this.el_.currentTime = seconds;\n\t } catch (e) {\n\t videojs__default['default'].log(e, 'Media is not ready. (Video.JS)');\n\t }\n\t }\n\t /**\n\t * Get media's duration.\n\t *\n\t * @return {number}\n\t * @method duration\n\t */\n\t ;\n\n\t _proto.duration = function duration() {\n\t if (this.el_.duration && this.el_.duration !== Infinity) {\n\t return this.el_.duration;\n\t }\n\n\t return 0;\n\t }\n\t /**\n\t * Get a TimeRange object that represents the intersection\n\t * of the time ranges for which the user agent has all\n\t * relevant media.\n\t *\n\t * @return {TimeRangeObject}\n\t * @method buffered\n\t */\n\t ;\n\n\t _proto.buffered = function buffered() {\n\t return this.el_.buffered;\n\t }\n\t /**\n\t * Get current volume level.\n\t *\n\t * @return {number}\n\t * @method volume\n\t */\n\t ;\n\n\t _proto.volume = function volume() {\n\t return this.el_.hasOwnProperty('volume') ? this.el_.volume : 1;\n\t }\n\t /**\n\t * Set current playing volume level.\n\t *\n\t * @param {number} percentAsDecimal Volume percent as a decimal.\n\t * @method setVolume\n\t */\n\t ;\n\n\t _proto.setVolume = function setVolume(percentAsDecimal) {\n\t if (getDeviceOS() !== iPhoneOS && this.el_.hasOwnProperty('volume')) {\n\t this.el_.volume = percentAsDecimal;\n\t }\n\t }\n\t /**\n\t * Is the player muted or not.\n\t *\n\t * @return {boolean}\n\t * @method muted\n\t */\n\t ;\n\n\t _proto.muted = function muted() {\n\t return this.el_.muted;\n\t }\n\t /**\n\t * Mute the player.\n\t *\n\t * @param {boolean} muted True to mute the player.\n\t */\n\t ;\n\n\t _proto.setMuted = function setMuted(muted) {\n\t this.el_.muted = !!muted;\n\t }\n\t /**\n\t * Is the player muted by default or not.\n\t *\n\t * @return {boolean}\n\t * @method defaultMuted\n\t */\n\t ;\n\n\t _proto.defaultMuted = function defaultMuted() {\n\t return this.el_.defaultMuted || false;\n\t }\n\t /**\n\t * Get the player width.\n\t *\n\t * @return {number}\n\t * @method width\n\t */\n\t ;\n\n\t _proto.width = function width() {\n\t return this.el_.offsetWidth;\n\t }\n\t /**\n\t * Get the player height.\n\t *\n\t * @return {number}\n\t * @method height\n\t */\n\t ;\n\n\t _proto.height = function height() {\n\t return this.el_.offsetHeight;\n\t }\n\t /**\n\t * Get the video width.\n\t *\n\t * @return {number}\n\t * @method videoWidth\n\t */\n\t ;\n\n\t _proto.videoWidth = function videoWidth() {\n\t return this.el_.videoWidth;\n\t }\n\t /**\n\t * Get the video height.\n\t *\n\t * @return {number}\n\t * @method videoHeight\n\t */\n\t ;\n\n\t _proto.videoHeight = function videoHeight() {\n\t return this.el_.videoHeight;\n\t }\n\t /**\n\t * Get/set media source.\n\t *\n\t * @param {Object=} src Source object\n\t * @return {Object}\n\t * @method src\n\t */\n\t ;\n\n\t _proto.src = function src(_src) {\n\t if (typeof _src === 'undefined') {\n\t return this.el_.src;\n\t }\n\n\t this.el_.src = _src;\n\t }\n\t /**\n\t * Load the media into the player.\n\t *\n\t * @method load\n\t */\n\t ;\n\n\t _proto.load = function load() {\n\t this.el_.load();\n\t }\n\t /**\n\t * Get current media source.\n\t *\n\t * @return {Object}\n\t * @method currentSrc\n\t */\n\t ;\n\n\t _proto.currentSrc = function currentSrc() {\n\t if (this.currentSource_) {\n\t return this.currentSource_.src;\n\t }\n\n\t return this.el_.currentSrc;\n\t }\n\t /**\n\t * Get media poster URL.\n\t *\n\t * @return {string}\n\t * @method poster\n\t */\n\t ;\n\n\t _proto.poster = function poster() {\n\t return this.el_.poster;\n\t }\n\t /**\n\t * Set media poster URL.\n\t *\n\t * @param {string} url the poster image's url.\n\t * @method\n\t */\n\t ;\n\n\t _proto.setPoster = function setPoster(url) {\n\t this.el_.poster = url;\n\t }\n\t /**\n\t * Is the media preloaded or not.\n\t *\n\t * @return {string}\n\t * @method preload\n\t */\n\t ;\n\n\t _proto.preload = function preload() {\n\t return this.el_.preload || 'none';\n\t }\n\t /**\n\t * Set the media preload method.\n\t *\n\t * @param {string} val Value for preload attribute.\n\t * @method setPreload\n\t */\n\t ;\n\n\t _proto.setPreload = function setPreload(val) {\n\t if (this.el_.hasOwnProperty('preload')) {\n\t this.el_.preload = val;\n\t }\n\t }\n\t /**\n\t * Is the media auto-played or not.\n\t *\n\t * @return {boolean}\n\t * @method autoplay\n\t */\n\t ;\n\n\t _proto.autoplay = function autoplay() {\n\t return this.el_.autoplay || false;\n\t }\n\t /**\n\t * Set media autoplay method.\n\t *\n\t * @param {boolean} val Value for autoplay attribute.\n\t * @method setAutoplay\n\t */\n\t ;\n\n\t _proto.setAutoplay = function setAutoplay(val) {\n\t if (this.el_.hasOwnProperty('autoplay')) {\n\t this.el_.autoplay = !!val;\n\t }\n\t }\n\t /**\n\t * Does the media has controls or not.\n\t *\n\t * @return {boolean}\n\t * @method controls\n\t */\n\t ;\n\n\t _proto.controls = function controls() {\n\t return this.el_.controls || false;\n\t }\n\t /**\n\t * Set the media controls method.\n\t *\n\t * @param {boolean} val Value for controls attribute.\n\t * @method setControls\n\t */\n\t ;\n\n\t _proto.setControls = function setControls(val) {\n\t if (this.el_.hasOwnProperty('controls')) {\n\t this.el_.controls = !!val;\n\t }\n\t }\n\t /**\n\t * Is the media looped or not.\n\t *\n\t * @return {boolean}\n\t * @method loop\n\t */\n\t ;\n\n\t _proto.loop = function loop() {\n\t return this.el_.loop || false;\n\t }\n\t /**\n\t * Set the media loop method.\n\t *\n\t * @param {boolean} val Value for loop attribute.\n\t * @method setLoop\n\t */\n\t ;\n\n\t _proto.setLoop = function setLoop(val) {\n\t if (this.el_.hasOwnProperty('loop')) {\n\t this.el_.loop = !!val;\n\t }\n\t }\n\t /**\n\t * Get a TimeRanges object that represents the\n\t * ranges of the media resource to which it is possible\n\t * for the user agent to seek.\n\t *\n\t * @return {TimeRangeObject}\n\t * @method seekable\n\t */\n\t ;\n\n\t _proto.seekable = function seekable() {\n\t return this.el_.seekable;\n\t }\n\t /**\n\t * Is player in the \"seeking\" state or not.\n\t *\n\t * @return {boolean}\n\t * @method seeking\n\t */\n\t ;\n\n\t _proto.seeking = function seeking() {\n\t return this.el_.seeking;\n\t }\n\t /**\n\t * Is the media ended or not.\n\t *\n\t * @return {boolean}\n\t * @method ended\n\t */\n\t ;\n\n\t _proto.ended = function ended() {\n\t return this.el_.ended;\n\t }\n\t /**\n\t * Get the current state of network activity\n\t * NETWORK_EMPTY (numeric value 0)\n\t * NETWORK_IDLE (numeric value 1)\n\t * NETWORK_LOADING (numeric value 2)\n\t * NETWORK_NO_SOURCE (numeric value 3)\n\t *\n\t * @return {number}\n\t * @method networkState\n\t */\n\t ;\n\n\t _proto.networkState = function networkState() {\n\t return this.el_.networkState;\n\t }\n\t /**\n\t * Get the current state of the player.\n\t * HAVE_NOTHING (numeric value 0)\n\t * HAVE_METADATA (numeric value 1)\n\t * HAVE_CURRENT_DATA (numeric value 2)\n\t * HAVE_FUTURE_DATA (numeric value 3)\n\t * HAVE_ENOUGH_DATA (numeric value 4)\n\t *\n\t * @return {number}\n\t * @method readyState\n\t */\n\t ;\n\n\t _proto.readyState = function readyState() {\n\t return this.el_.readyState;\n\t }\n\t /**\n\t * Does the player support native fullscreen mode or not. (Mobile devices)\n\t *\n\t * @return {boolean}\n\t */\n\t ;\n\n\t _proto.supportsFullScreen = function supportsFullScreen() {\n\t // iOS devices have some problem with HTML5 fullscreen api so we need to fallback to fullWindow mode.\n\t return false;\n\t }\n\t /**\n\t * Get media player error.\n\t *\n\t * @return {string}\n\t * @method error\n\t */\n\t ;\n\n\t _proto.error = function error() {\n\t return this.el_.error;\n\t };\n\n\t return OgvJS;\n\t}(Tech);\n\t/**\n\t * List of available events of the media player.\n\t *\n\t * @private\n\t * @type {Array}\n\t */\n\n\n\tOgvJS.Events = ['loadstart', 'suspend', 'abort', 'error', 'emptied', 'stalled', 'loadedmetadata', 'loadeddata', 'canplay', 'canplaythrough', 'playing', 'waiting', 'seeking', 'seeked', 'ended', 'durationchange', 'timeupdate', 'progress', 'play', 'pause', 'ratechange', 'resize', 'volumechange'];\n\t/**\n\t * Set the value for the player is it has that property.\n\t *\n\t * @param {Element} el\n\t * @param {string} name\n\t * @param value\n\t */\n\n\tOgvJS.setIfAvailable = function (el, name, value) {\n\t if (el.hasOwnProperty(name)) {\n\t el[name] = value;\n\t }\n\t};\n\t/**\n\t * Check if browser/device is supported by Ogv.JS.\n\t *\n\t * @return {boolean}\n\t */\n\n\n\tOgvJS.isSupported = function () {\n\t return OGVCompat__default['default'].supported('OGVPlayer');\n\t};\n\t/**\n\t * Check if the tech can support the given type.\n\t *\n\t * @param {string} type The mimetype to check\n\t * @return {string} 'probably', 'maybe', or '' (empty string)\n\t */\n\n\n\tOgvJS.canPlayType = function (type) {\n\t return type.indexOf('/ogg') !== -1 || type.indexOf('/webm') ? 'maybe' : '';\n\t};\n\t/**\n\t * Check if the tech can support the given source\n\t *\n\t * @param srcObj The source object\n\t * @return {string} The options passed to the tech\n\t */\n\n\n\tOgvJS.canPlaySource = function (srcObj) {\n\t return OgvJS.canPlayType(srcObj.type);\n\t};\n\t/**\n\t * Check if the volume can be changed in this browser/device.\n\t * Volume cannot be changed in a lot of mobile devices.\n\t * Specifically, it can't be changed from 1 on iOS.\n\t *\n\t * @return {boolean} True if volume can be controlled.\n\t */\n\n\n\tOgvJS.canControlVolume = function () {\n\t if (getDeviceOS() === iPhoneOS) {\n\t return false;\n\t }\n\n\t var p = new OGVPlayer__default['default']();\n\t return p.hasOwnProperty('volume');\n\t};\n\t/**\n\t * Check if the volume can be muted in this browser/device.\n\t *\n\t * @return {boolean} True if volume can be muted.\n\t */\n\n\n\tOgvJS.canMuteVolume = function () {\n\t return true;\n\t};\n\t/**\n\t * Check if the playback rate can be changed in this browser/device.\n\t *\n\t * @return {boolean} True if playback rate can be controlled.\n\t */\n\n\n\tOgvJS.canControlPlaybackRate = function () {\n\t return true;\n\t};\n\t/**\n\t * Check to see if native 'TextTracks' are supported by this browser/device.\n\t *\n\t * @return {boolean} True if native 'TextTracks' are supported.\n\t */\n\n\n\tOgvJS.supportsNativeTextTracks = function () {\n\t return false;\n\t};\n\t/**\n\t * Check if the fullscreen resize is supported by this browser/device.\n\t *\n\t * @return {boolean} True if the fullscreen resize is supported.\n\t */\n\n\n\tOgvJS.supportsFullscreenResize = function () {\n\t return true;\n\t};\n\t/**\n\t * Check if the progress events is supported by this browser/device.\n\t *\n\t * @return {boolean} True if the progress events is supported.\n\t */\n\n\n\tOgvJS.supportsProgressEvents = function () {\n\t return true;\n\t};\n\t/**\n\t * Check if the time update events is supported by this browser/device.\n\t *\n\t * @return {boolean} True if the time update events is supported.\n\t */\n\n\n\tOgvJS.supportsTimeupdateEvents = function () {\n\t return true;\n\t};\n\t/**\n\t * Boolean indicating whether the 'OgvJS' tech supports volume control.\n\t *\n\t * @type {boolean}\n\t * @default {@link OgvJS.canControlVolume}\n\t */\n\n\t/**\n\t * Boolean indicating whether the 'OgvJS' tech supports muting volume.\n\t *\n\t * @type {boolean}\n\t * @default {@link OgvJS.canMuteVolume}\n\t */\n\n\t/**\n\t * Boolean indicating whether the 'OgvJS' tech supports changing the speed at which the media plays.\n\t * Examples:\n\t * - Set player to play 2x (twice) as fast.\n\t * - Set player to play 0.5x (half) as fast.\n\t *\n\t * @type {boolean}\n\t * @default {@link OgvJS.canControlPlaybackRate}\n\t */\n\n\t/**\n\t * Boolean indicating whether the 'OgvJS' tech currently supports native 'TextTracks'.\n\t *\n\t * @type {boolean}\n\t * @default {@link OgvJS.supportsNativeTextTracks}\n\t */\n\n\t/**\n\t * Boolean indicating whether the 'OgvJS' tech currently supports fullscreen resize.\n\t *\n\t * @type {boolean}\n\t * @default {@link OgvJS.supportsFullscreenResize}\n\t */\n\n\t/**\n\t * Boolean indicating whether the 'OgvJS' tech currently supports progress events.\n\t *\n\t * @type {boolean}\n\t * @default {@link OgvJS.supportsProgressEvents}\n\t */\n\n\t/**\n\t * Boolean indicating whether the 'OgvJS' tech currently supports time update events.\n\t *\n\t * @type {boolean}\n\t * @default {@link OgvJS.supportsTimeupdateEvents}\n\t */\n\n\n\t[['featuresVolumeControl', 'canControlVolume'], ['featuresMuteControl', 'canMuteVolume'], ['featuresPlaybackRate', 'canControlPlaybackRate'], ['featuresNativeTextTracks', 'supportsNativeTextTracks'], ['featuresFullscreenResize', 'supportsFullscreenResize'], ['featuresProgressEvents', 'supportsProgressEvents'], ['featuresTimeupdateEvents', 'supportsTimeupdateEvents']].forEach(function (_ref) {\n\t var key = _ref[0],\n\t fn = _ref[1];\n\t defineLazyProperty(OgvJS.prototype, key, function () {\n\t OgvJS[fn]();\n\t }, true);\n\t});\n\tTech.registerTech('OgvJS', OgvJS);\n\n\treturn OgvJS;\n\n})));\n"],"names":["global","factory","this","videojs","ogvBase","_interopDefaultLegacy","e","videojs__default","OGVCompat__default","OGVCompat","OGVLoader__default","OGVLoader","OGVPlayer__default","OGVPlayer","createCommonjsModule","fn","basedir","module","path","exports","require","base","Error","commonjsRequire","setPrototypeOf","_setPrototypeOf","o","p","Object","__proto__","__esModule","inheritsLoose","subClass","superClass","prototype","create","constructor","Tech","getComponent","getDeviceOS","ua","navigator","userAgent","test","platform","maxTouchPoints","OgvJS","_Tech","options","ready","_this","call","el_","src","source","setIfAvailable","autoplay","loop","poster","preload","on","canvas","getElementsByTagName","style","removeProperty","triggerReady","_proto","createEl","options_","el","className","tag","play","playbackRate","setPlaybackRate","val","hasOwnProperty","played","pause","paused","currentTime","setCurrentTime","seconds","log","duration","Infinity","buffered","volume","setVolume","percentAsDecimal","muted","setMuted","defaultMuted","width","offsetWidth","height","offsetHeight","videoWidth","videoHeight","_src","load","currentSrc","currentSource_","setPoster","url","setPreload","setAutoplay","controls","setControls","setLoop","seekable","seeking","ended","networkState","readyState","supportsFullScreen","error","Events","name","value","isSupported","supported","canPlayType","type","indexOf","canPlaySource","srcObj","canControlVolume","canMuteVolume","canControlPlaybackRate","supportsNativeTextTracks","supportsFullscreenResize","supportsProgressEvents","supportsTimeupdateEvents","forEach","_ref","key","obj","getValue","setter","set","defineProperty","enumerable","writable","configurable","get","defineLazyProperty","registerTech","define","amd","globalThis","self","videojsOgvjs"],"mappings":";;;;;;;AAOC,IAAUA,OAAQC,QAARD,OAITE,OAJiBD,QAIV,SAAUE,QAASC,kBAElBC,sBAAuBC,UAAYA,GAAkB,iBAANA,GAAkB,YAAaA,EAAIA,EAAI,SAAaA,OAExGC,iBAAgCF,sBAAsBF,SACtDK,mBAAkCH,sBAAsBD,QAAQK,WAChEC,mBAAkCL,sBAAsBD,QAAQO,WAChEC,mBAAkCP,sBAAsBD,QAAQS,oBAE3DC,qBAAqBC,GAAIC,QAASC,eAOvCF,GANIE,OAAS,CACdC,KAAMF,QACNG,QAAS,GACTC,QAAS,SAAUF,KAAMG,8BAOrB,IAAIC,MAAM,2EANJC,CAAuBF,MAAAA,MAAuCJ,OAAOC,QAEnED,OAAOE,SAAUF,OAAOE,YAOnCK,eAAiBV,sBAAqB,SAAUG,iBACzCQ,gBAAgBC,EAAGC,UAC1BV,OAAOE,QAAUM,gBAAkBG,OAAOJ,gBAAkB,SAAyBE,EAAGC,UACtFD,EAAEG,UAAYF,EACPD,GAGTT,OAAOE,QAAP,QAA4BF,OAAOE,QAASF,OAAOE,QAAQW,YAAa,EACjEL,gBAAgBC,EAAGC,GAG5BV,OAAOE,QAAUM,gBACjBR,OAAOE,QAAP,QAA4BF,OAAOE,QAASF,OAAOE,QAAQW,YAAa,KAGtEC,cAAgBjB,sBAAqB,SAAUG,QAOjDA,OAAOE,iBANiBa,SAAUC,YAChCD,SAASE,UAAYN,OAAOO,OAAOF,WAAWC,WAC9CF,SAASE,UAAUE,YAAcJ,SACjCR,eAAeQ,SAAUC,aAI3BhB,OAAOE,QAAP,QAA4BF,OAAOE,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YAAaA,QAAQ,aAAcA,QAAQ,aAAcA,QAAQ,cAC/I,mBAAXgI,QAAyBA,OAAOC,IAAMD,0CAAO,CAAC,2BAA4B,mBAAoBnJ,UACpGD,OAA+B,oBAAfsJ,WAA6BA,WAAatJ,QAAUuJ,MAAaC,aAAevJ,QAAQD,OAAOG,QAASH,OAAOS,UAAWT,OAAOW,UAAWX,OAAOa"} \ No newline at end of file +{"version":3,"file":"videojs-ogvjs-lazy.min.js","sources":["../src/videojs-ogvjs-lazy.js"],"sourcesContent":["/**\n * videojs-ogvjs\n * @version 0.2.1\n * @copyright 2023 Huong Nguyen \n * @license MIT\n */\n/*! @name videojs-ogvjs @version 0.2.1 @license MIT */\n(function (global, factory) {\n\ttypeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('video.js'), require('OGVCompat'), require('OGVLoader'), require('OGVPlayer')) :\n\t\ttypeof define === 'function' && define.amd ? define(['media_videojs/video-lazy', './local/ogv/ogv'], factory) :\n\t\t\t(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.videojsOgvjs = factory(global.videojs, global.OGVCompat, global.OGVLoader, global.OGVPlayer));\n}(this, (function (videojs, ogvBase) { 'use strict';\n\n\tfunction _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }\n\n\tvar videojs__default = /*#__PURE__*/_interopDefaultLegacy(videojs);\n\tvar OGVCompat__default = /*#__PURE__*/_interopDefaultLegacy(ogvBase.OGVCompat);\n\tvar OGVLoader__default = /*#__PURE__*/_interopDefaultLegacy(ogvBase.OGVLoader);\n\tvar OGVPlayer__default = /*#__PURE__*/_interopDefaultLegacy(ogvBase.OGVPlayer);\n\n\tfunction createCommonjsModule(fn, basedir, module) {\n\t\treturn module = {\n\t\t\tpath: basedir,\n\t\t\texports: {},\n\t\t\trequire: function (path, base) {\n\t\t\t\treturn commonjsRequire(path, (base === undefined || base === null) ? module.path : base);\n\t\t\t}\n\t\t}, fn(module, module.exports), module.exports;\n\t}\n\n\tfunction commonjsRequire () {\n\t\tthrow new Error('Dynamic requires are not currently supported by @rollup/plugin-commonjs');\n\t}\n\n\tvar setPrototypeOf = createCommonjsModule(function (module) {\n\t\tfunction _setPrototypeOf(o, p) {\n\t\t\tmodule.exports = _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n\t\t\t\to.__proto__ = p;\n\t\t\t\treturn o;\n\t\t\t}, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;\n\t\t\treturn _setPrototypeOf(o, p);\n\t\t}\n\n\t\tmodule.exports = _setPrototypeOf, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;\n\t});\n\n\tvar inheritsLoose = createCommonjsModule(function (module) {\n\t\tfunction _inheritsLoose(subClass, superClass) {\n\t\t\tsubClass.prototype = Object.create(superClass.prototype);\n\t\t\tsubClass.prototype.constructor = subClass;\n\t\t\tsetPrototypeOf(subClass, superClass);\n\t\t}\n\n\t\tmodule.exports = _inheritsLoose, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;\n\t});\n\n\tvar Tech = videojs__default['default'].getComponent('Tech');\n\tvar androidOS = 'Android';\n\tvar iPhoneOS = 'iPhoneOS';\n\tvar iPadOS = 'iPadOS';\n\tvar otherOS = 'Other';\n\t/**\n\t * Object.defineProperty but \"lazy\", which means that the value is only set after\n\t * it retrieved the first time, rather than being set right away.\n\t *\n\t * @param {Object} obj the object to set the property on.\n\t * @param {string} key the key for the property to set.\n\t * @param {Function} getValue the function used to get the value when it is needed.\n\t * @param {boolean} setter whether a setter should be allowed or not.\n\t */\n\n\tvar defineLazyProperty = function defineLazyProperty(obj, key, getValue, setter) {\n\t\tif (setter === void 0) {\n\t\t\tsetter = true;\n\t\t}\n\n\t\tvar set = function set(value) {\n\t\t\tObject.defineProperty(obj, key, {\n\t\t\t\tvalue: value,\n\t\t\t\tenumerable: true,\n\t\t\t\twritable: true\n\t\t\t});\n\t\t};\n\n\t\tvar options = {\n\t\t\tconfigurable: true,\n\t\t\tenumerable: true,\n\t\t\tget: function get() {\n\t\t\t\tvar value = getValue();\n\t\t\t\tset(value);\n\t\t\t\treturn value;\n\t\t\t}\n\t\t};\n\n\t\tif (setter) {\n\t\t\toptions.set = set;\n\t\t}\n\n\t\treturn Object.defineProperty(obj, key, options);\n\t};\n\t/**\n\t * Get the device's OS.\n\t *\n\t * @return {string} Device's OS.\n\t */\n\n\n\tvar getDeviceOS = function getDeviceOS() {\n\t\t/* global navigator */\n\t\tvar ua = navigator.userAgent;\n\n\t\tif (/android/i.test(ua)) {\n\t\t\treturn androidOS;\n\t\t} else if (/iPad|iPhone|iPod/.test(ua)) {\n\t\t\treturn iPhoneOS;\n\t\t} else if (navigator.platform === 'MacIntel' && navigator.maxTouchPoints > 1) {\n\t\t\treturn iPadOS;\n\t\t}\n\n\t\treturn otherOS;\n\t};\n\t/**\n\t * OgvJS Media Controller - Wrapper for ogv.js Media API\n\t *\n\t * @mixes Tech~SourceHandlerAdditions\n\t * @extends Tech\n\t */\n\n\n\tvar OgvJS = /*#__PURE__*/function (_Tech) {\n\t\tinheritsLoose(OgvJS, _Tech);\n\n\t\t/**\n\t\t * Create an instance of this Tech.\n\t\t *\n\t\t * @param {Object} [options] The key/value store of player options.\n\t\t * @param {Component~ReadyCallback} ready Callback function to call when the `OgvJS` Tech is ready.\n\t\t */\n\t\tfunction OgvJS(options, ready) {\n\t\t\tvar _this;\n\n\t\t\t_this = _Tech.call(this, options, ready) || this;\n\t\t\t_this.el_.src = options.source.src;\n\t\t\tOgvJS.setIfAvailable(_this.el_, 'autoplay', options.autoplay);\n\t\t\tOgvJS.setIfAvailable(_this.el_, 'loop', options.loop);\n\t\t\tOgvJS.setIfAvailable(_this.el_, 'poster', options.poster);\n\t\t\tOgvJS.setIfAvailable(_this.el_, 'preload', options.preload);\n\n\t\t\t_this.on('loadedmetadata', function () {\n\t\t\t\tif (getDeviceOS() === iPhoneOS) {\n\t\t\t\t\t// iPhoneOS add some inline styles to the canvas, we need to remove it.\n\t\t\t\t\tvar canvas = _this.el_.getElementsByTagName('canvas')[0];\n\n\t\t\t\t\tcanvas.style.removeProperty('width');\n\t\t\t\t\tcanvas.style.removeProperty('margin');\n\t\t\t\t}\n\t\t\t});\n\n\t\t\t_this.triggerReady();\n\n\t\t\treturn _this;\n\t\t}\n\t\t/**\n\t\t * Create the 'OgvJS' Tech's DOM element.\n\t\t *\n\t\t * @return {Element} The element that gets created.\n\t\t */\n\n\n\t\tvar _proto = OgvJS.prototype;\n\n\t\t_proto.createEl = function createEl() {\n\t\t\tvar options = this.options_;\n\n\t\t\tif (options.base) {\n\t\t\t\tOGVLoader__default['default'].base = options.base;\n\t\t\t} else {\n\t\t\t\tthrow new Error('Please specify the base for the ogv.js library');\n\t\t\t}\n\n\t\t\tvar el = new OGVPlayer__default['default'](options);\n\t\t\tel.className += ' vjs-tech';\n\t\t\toptions.tag = el;\n\t\t\treturn el;\n\t\t}\n\t\t/**\n\t\t * Start playback\n\t\t *\n\t\t * @method play\n\t\t */\n\t\t;\n\n\t\t_proto.play = function play() {\n\t\t\tthis.el_.play();\n\t\t}\n\t\t/**\n\t\t * Get the current playback speed.\n\t\t *\n\t\t * @return {number}\n\t\t * @method playbackRate\n\t\t */\n\t\t;\n\n\t\t_proto.playbackRate = function playbackRate() {\n\t\t\treturn this.el_.playbackRate || 1;\n\t\t}\n\t\t/**\n\t\t * Set the playback speed.\n\t\t *\n\t\t * @param {number} val Speed for the player to play.\n\t\t * @method setPlaybackRate\n\t\t */\n\t\t;\n\n\t\t_proto.setPlaybackRate = function setPlaybackRate(val) {\n\t\t\tif (this.el_.hasOwnProperty('playbackRate')) {\n\t\t\t\tthis.el_.playbackRate = val;\n\t\t\t}\n\t\t}\n\t\t/**\n\t\t * Returns a TimeRanges object that represents the ranges of the media resource that the user agent has played.\n\t\t *\n\t\t * @return {TimeRangeObject} the range of points on the media timeline that has been reached through normal playback\n\t\t */\n\t\t;\n\n\t\t_proto.played = function played() {\n\t\t\treturn this.el_.played;\n\t\t}\n\t\t/**\n\t\t * Pause playback\n\t\t *\n\t\t * @method pause\n\t\t */\n\t\t;\n\n\t\t_proto.pause = function pause() {\n\t\t\tthis.el_.pause();\n\t\t}\n\t\t/**\n\t\t * Is the player paused or not.\n\t\t *\n\t\t * @return {boolean}\n\t\t * @method paused\n\t\t */\n\t\t;\n\n\t\t_proto.paused = function paused() {\n\t\t\treturn this.el_.paused;\n\t\t}\n\t\t/**\n\t\t * Get current playing time.\n\t\t *\n\t\t * @return {number}\n\t\t * @method currentTime\n\t\t */\n\t\t;\n\n\t\t_proto.currentTime = function currentTime() {\n\t\t\treturn this.el_.currentTime;\n\t\t}\n\t\t/**\n\t\t * Set current playing time.\n\t\t *\n\t\t * @param {number} seconds Current time of audio/video.\n\t\t * @method setCurrentTime\n\t\t */\n\t\t;\n\n\t\t_proto.setCurrentTime = function setCurrentTime(seconds) {\n\t\t\ttry {\n\t\t\t\tthis.el_.currentTime = seconds;\n\t\t\t} catch (e) {\n\t\t\t\tvideojs__default['default'].log(e, 'Media is not ready. (Video.JS)');\n\t\t\t}\n\t\t}\n\t\t/**\n\t\t * Get media's duration.\n\t\t *\n\t\t * @return {number}\n\t\t * @method duration\n\t\t */\n\t\t;\n\n\t\t_proto.duration = function duration() {\n\t\t\tif (this.el_.duration && this.el_.duration !== Infinity) {\n\t\t\t\treturn this.el_.duration;\n\t\t\t}\n\n\t\t\treturn 0;\n\t\t}\n\t\t/**\n\t\t * Get a TimeRange object that represents the intersection\n\t\t * of the time ranges for which the user agent has all\n\t\t * relevant media.\n\t\t *\n\t\t * @return {TimeRangeObject}\n\t\t * @method buffered\n\t\t */\n\t\t;\n\n\t\t_proto.buffered = function buffered() {\n\t\t\treturn this.el_.buffered;\n\t\t}\n\t\t/**\n\t\t * Get current volume level.\n\t\t *\n\t\t * @return {number}\n\t\t * @method volume\n\t\t */\n\t\t;\n\n\t\t_proto.volume = function volume() {\n\t\t\treturn this.el_.hasOwnProperty('volume') ? this.el_.volume : 1;\n\t\t}\n\t\t/**\n\t\t * Set current playing volume level.\n\t\t *\n\t\t * @param {number} percentAsDecimal Volume percent as a decimal.\n\t\t * @method setVolume\n\t\t */\n\t\t;\n\n\t\t_proto.setVolume = function setVolume(percentAsDecimal) {\n\t\t\t// Apple does not allow iOS and iPadOS devices to set the volume on UI.\n\t\t\tif (getDeviceOS() !== iPhoneOS && getDeviceOS() !== iPadOS && this.el_.hasOwnProperty('volume')) {\n\t\t\t\tthis.el_.volume = percentAsDecimal;\n\t\t\t}\n\t\t}\n\t\t/**\n\t\t * Is the player muted or not.\n\t\t *\n\t\t * @return {boolean}\n\t\t * @method muted\n\t\t */\n\t\t;\n\n\t\t_proto.muted = function muted() {\n\t\t\treturn this.el_.muted;\n\t\t}\n\t\t/**\n\t\t * Mute the player.\n\t\t *\n\t\t * @param {boolean} muted True to mute the player.\n\t\t */\n\t\t;\n\n\t\t_proto.setMuted = function setMuted(muted) {\n\t\t\tthis.el_.muted = !!muted;\n\t\t}\n\t\t/**\n\t\t * Is the player muted by default or not.\n\t\t *\n\t\t * @return {boolean}\n\t\t * @method defaultMuted\n\t\t */\n\t\t;\n\n\t\t_proto.defaultMuted = function defaultMuted() {\n\t\t\treturn this.el_.defaultMuted || false;\n\t\t}\n\t\t/**\n\t\t * Get the player width.\n\t\t *\n\t\t * @return {number}\n\t\t * @method width\n\t\t */\n\t\t;\n\n\t\t_proto.width = function width() {\n\t\t\treturn this.el_.offsetWidth;\n\t\t}\n\t\t/**\n\t\t * Get the player height.\n\t\t *\n\t\t * @return {number}\n\t\t * @method height\n\t\t */\n\t\t;\n\n\t\t_proto.height = function height() {\n\t\t\treturn this.el_.offsetHeight;\n\t\t}\n\t\t/**\n\t\t * Get the video width.\n\t\t *\n\t\t * @return {number}\n\t\t * @method videoWidth\n\t\t */\n\t\t;\n\n\t\t_proto.videoWidth = function videoWidth() {\n\t\t\treturn this.el_.videoWidth;\n\t\t}\n\t\t/**\n\t\t * Get the video height.\n\t\t *\n\t\t * @return {number}\n\t\t * @method videoHeight\n\t\t */\n\t\t;\n\n\t\t_proto.videoHeight = function videoHeight() {\n\t\t\treturn this.el_.videoHeight;\n\t\t}\n\t\t/**\n\t\t * Get/set media source.\n\t\t *\n\t\t * @param {Object=} src Source object\n\t\t * @return {Object}\n\t\t * @method src\n\t\t */\n\t\t;\n\n\t\t_proto.src = function src(_src) {\n\t\t\tif (typeof _src === 'undefined') {\n\t\t\t\treturn this.el_.src;\n\t\t\t}\n\n\t\t\tthis.el_.src = _src;\n\t\t}\n\t\t/**\n\t\t * Load the media into the player.\n\t\t *\n\t\t * @method load\n\t\t */\n\t\t;\n\n\t\t_proto.load = function load() {\n\t\t\tthis.el_.load();\n\t\t}\n\t\t/**\n\t\t * Get current media source.\n\t\t *\n\t\t * @return {Object}\n\t\t * @method currentSrc\n\t\t */\n\t\t;\n\n\t\t_proto.currentSrc = function currentSrc() {\n\t\t\tif (this.currentSource_) {\n\t\t\t\treturn this.currentSource_.src;\n\t\t\t}\n\n\t\t\treturn this.el_.currentSrc;\n\t\t}\n\t\t/**\n\t\t * Get media poster URL.\n\t\t *\n\t\t * @return {string}\n\t\t * @method poster\n\t\t */\n\t\t;\n\n\t\t_proto.poster = function poster() {\n\t\t\treturn this.el_.poster;\n\t\t}\n\t\t/**\n\t\t * Set media poster URL.\n\t\t *\n\t\t * @param {string} url the poster image's url.\n\t\t * @method\n\t\t */\n\t\t;\n\n\t\t_proto.setPoster = function setPoster(url) {\n\t\t\tthis.el_.poster = url;\n\t\t}\n\t\t/**\n\t\t * Is the media preloaded or not.\n\t\t *\n\t\t * @return {string}\n\t\t * @method preload\n\t\t */\n\t\t;\n\n\t\t_proto.preload = function preload() {\n\t\t\treturn this.el_.preload || 'none';\n\t\t}\n\t\t/**\n\t\t * Set the media preload method.\n\t\t *\n\t\t * @param {string} val Value for preload attribute.\n\t\t * @method setPreload\n\t\t */\n\t\t;\n\n\t\t_proto.setPreload = function setPreload(val) {\n\t\t\tif (this.el_.hasOwnProperty('preload')) {\n\t\t\t\tthis.el_.preload = val;\n\t\t\t}\n\t\t}\n\t\t/**\n\t\t * Is the media auto-played or not.\n\t\t *\n\t\t * @return {boolean}\n\t\t * @method autoplay\n\t\t */\n\t\t;\n\n\t\t_proto.autoplay = function autoplay() {\n\t\t\treturn this.el_.autoplay || false;\n\t\t}\n\t\t/**\n\t\t * Set media autoplay method.\n\t\t *\n\t\t * @param {boolean} val Value for autoplay attribute.\n\t\t * @method setAutoplay\n\t\t */\n\t\t;\n\n\t\t_proto.setAutoplay = function setAutoplay(val) {\n\t\t\tif (this.el_.hasOwnProperty('autoplay')) {\n\t\t\t\tthis.el_.autoplay = !!val;\n\t\t\t}\n\t\t}\n\t\t/**\n\t\t * Does the media has controls or not.\n\t\t *\n\t\t * @return {boolean}\n\t\t * @method controls\n\t\t */\n\t\t;\n\n\t\t_proto.controls = function controls() {\n\t\t\treturn this.el_.controls || false;\n\t\t}\n\t\t/**\n\t\t * Set the media controls method.\n\t\t *\n\t\t * @param {boolean} val Value for controls attribute.\n\t\t * @method setControls\n\t\t */\n\t\t;\n\n\t\t_proto.setControls = function setControls(val) {\n\t\t\tif (this.el_.hasOwnProperty('controls')) {\n\t\t\t\tthis.el_.controls = !!val;\n\t\t\t}\n\t\t}\n\t\t/**\n\t\t * Is the media looped or not.\n\t\t *\n\t\t * @return {boolean}\n\t\t * @method loop\n\t\t */\n\t\t;\n\n\t\t_proto.loop = function loop() {\n\t\t\treturn this.el_.loop || false;\n\t\t}\n\t\t/**\n\t\t * Set the media loop method.\n\t\t *\n\t\t * @param {boolean} val Value for loop attribute.\n\t\t * @method setLoop\n\t\t */\n\t\t;\n\n\t\t_proto.setLoop = function setLoop(val) {\n\t\t\tif (this.el_.hasOwnProperty('loop')) {\n\t\t\t\tthis.el_.loop = !!val;\n\t\t\t}\n\t\t}\n\t\t/**\n\t\t * Get a TimeRanges object that represents the\n\t\t * ranges of the media resource to which it is possible\n\t\t * for the user agent to seek.\n\t\t *\n\t\t * @return {TimeRangeObject}\n\t\t * @method seekable\n\t\t */\n\t\t;\n\n\t\t_proto.seekable = function seekable() {\n\t\t\treturn this.el_.seekable;\n\t\t}\n\t\t/**\n\t\t * Is player in the \"seeking\" state or not.\n\t\t *\n\t\t * @return {boolean}\n\t\t * @method seeking\n\t\t */\n\t\t;\n\n\t\t_proto.seeking = function seeking() {\n\t\t\treturn this.el_.seeking;\n\t\t}\n\t\t/**\n\t\t * Is the media ended or not.\n\t\t *\n\t\t * @return {boolean}\n\t\t * @method ended\n\t\t */\n\t\t;\n\n\t\t_proto.ended = function ended() {\n\t\t\treturn this.el_.ended;\n\t\t}\n\t\t/**\n\t\t * Get the current state of network activity\n\t\t * NETWORK_EMPTY (numeric value 0)\n\t\t * NETWORK_IDLE (numeric value 1)\n\t\t * NETWORK_LOADING (numeric value 2)\n\t\t * NETWORK_NO_SOURCE (numeric value 3)\n\t\t *\n\t\t * @return {number}\n\t\t * @method networkState\n\t\t */\n\t\t;\n\n\t\t_proto.networkState = function networkState() {\n\t\t\treturn this.el_.networkState;\n\t\t}\n\t\t/**\n\t\t * Get the current state of the player.\n\t\t * HAVE_NOTHING (numeric value 0)\n\t\t * HAVE_METADATA (numeric value 1)\n\t\t * HAVE_CURRENT_DATA (numeric value 2)\n\t\t * HAVE_FUTURE_DATA (numeric value 3)\n\t\t * HAVE_ENOUGH_DATA (numeric value 4)\n\t\t *\n\t\t * @return {number}\n\t\t * @method readyState\n\t\t */\n\t\t;\n\n\t\t_proto.readyState = function readyState() {\n\t\t\treturn this.el_.readyState;\n\t\t}\n\t\t/**\n\t\t * Does the player support native fullscreen mode or not. (Mobile devices)\n\t\t *\n\t\t * @return {boolean}\n\t\t */\n\t\t;\n\n\t\t_proto.supportsFullScreen = function supportsFullScreen() {\n\t\t\t// iOS devices have some problem with HTML5 fullscreen api so we need to fallback to fullWindow mode.\n\t\t\treturn false;\n\t\t}\n\t\t/**\n\t\t * Get media player error.\n\t\t *\n\t\t * @return {string}\n\t\t * @method error\n\t\t */\n\t\t;\n\n\t\t_proto.error = function error() {\n\t\t\treturn this.el_.error;\n\t\t};\n\n\t\treturn OgvJS;\n\t}(Tech);\n\t/**\n\t * List of available events of the media player.\n\t *\n\t * @private\n\t * @type {Array}\n\t */\n\n\n\tOgvJS.Events = ['loadstart', 'suspend', 'abort', 'error', 'emptied', 'stalled', 'loadedmetadata', 'loadeddata', 'canplay', 'canplaythrough', 'playing', 'waiting', 'seeking', 'seeked', 'ended', 'durationchange', 'timeupdate', 'progress', 'play', 'pause', 'ratechange', 'resize', 'volumechange'];\n\t/**\n\t * Set the value for the player is it has that property.\n\t *\n\t * @param {Element} el\n\t * @param {string} name\n\t * @param value\n\t */\n\n\tOgvJS.setIfAvailable = function (el, name, value) {\n\t\tif (el.hasOwnProperty(name)) {\n\t\t\tel[name] = value;\n\t\t}\n\t};\n\t/**\n\t * Check if browser/device is supported by Ogv.JS.\n\t *\n\t * @return {boolean}\n\t */\n\n\n\tOgvJS.isSupported = function () {\n\t\treturn OGVCompat__default['default'].supported('OGVPlayer');\n\t};\n\t/**\n\t * Check if the tech can support the given type.\n\t *\n\t * @param {string} type The mimetype to check\n\t * @return {string} 'probably', 'maybe', or '' (empty string)\n\t */\n\n\n\tOgvJS.canPlayType = function (type) {\n\t\treturn type.indexOf('/ogg') !== -1 || type.indexOf('/webm') ? 'maybe' : '';\n\t};\n\t/**\n\t * Check if the tech can support the given source\n\t *\n\t * @param srcObj The source object\n\t * @return {string} The options passed to the tech\n\t */\n\n\n\tOgvJS.canPlaySource = function (srcObj) {\n\t\treturn OgvJS.canPlayType(srcObj.type);\n\t};\n\t/**\n\t * Check if the volume can be changed in this browser/device.\n\t * Volume cannot be changed in a lot of mobile devices.\n\t * Specifically, it can't be changed on iOS and iPadOS.\n\t *\n\t * @return {boolean} True if volume can be controlled.\n\t */\n\n\n\tOgvJS.canControlVolume = function () {\n\t\tif (getDeviceOS() === iPhoneOS || getDeviceOS() === iPadOS) {\n\t\t\treturn false;\n\t\t}\n\n\t\tvar p = new OGVPlayer__default['default']();\n\t\treturn p.hasOwnProperty('volume');\n\t};\n\t/**\n\t * Check if the volume can be muted in this browser/device.\n\t *\n\t * @return {boolean} True if volume can be muted.\n\t */\n\n\n\tOgvJS.canMuteVolume = function () {\n\t\treturn true;\n\t};\n\t/**\n\t * Check if the playback rate can be changed in this browser/device.\n\t *\n\t * @return {boolean} True if playback rate can be controlled.\n\t */\n\n\n\tOgvJS.canControlPlaybackRate = function () {\n\t\treturn true;\n\t};\n\t/**\n\t * Check to see if native 'TextTracks' are supported by this browser/device.\n\t *\n\t * @return {boolean} True if native 'TextTracks' are supported.\n\t */\n\n\n\tOgvJS.supportsNativeTextTracks = function () {\n\t\treturn false;\n\t};\n\t/**\n\t * Check if the fullscreen resize is supported by this browser/device.\n\t *\n\t * @return {boolean} True if the fullscreen resize is supported.\n\t */\n\n\n\tOgvJS.supportsFullscreenResize = function () {\n\t\treturn true;\n\t};\n\t/**\n\t * Check if the progress events is supported by this browser/device.\n\t *\n\t * @return {boolean} True if the progress events is supported.\n\t */\n\n\n\tOgvJS.supportsProgressEvents = function () {\n\t\treturn true;\n\t};\n\t/**\n\t * Check if the time update events is supported by this browser/device.\n\t *\n\t * @return {boolean} True if the time update events is supported.\n\t */\n\n\n\tOgvJS.supportsTimeupdateEvents = function () {\n\t\treturn true;\n\t};\n\t/**\n\t * Boolean indicating whether the 'OgvJS' tech supports volume control.\n\t *\n\t * @type {boolean}\n\t * @default {@link OgvJS.canControlVolume}\n\t */\n\n\t/**\n\t * Boolean indicating whether the 'OgvJS' tech supports muting volume.\n\t *\n\t * @type {boolean}\n\t * @default {@link OgvJS.canMuteVolume}\n\t */\n\n\t/**\n\t * Boolean indicating whether the 'OgvJS' tech supports changing the speed at which the media plays.\n\t * Examples:\n\t * - Set player to play 2x (twice) as fast.\n\t * - Set player to play 0.5x (half) as fast.\n\t *\n\t * @type {boolean}\n\t * @default {@link OgvJS.canControlPlaybackRate}\n\t */\n\n\t/**\n\t * Boolean indicating whether the 'OgvJS' tech currently supports native 'TextTracks'.\n\t *\n\t * @type {boolean}\n\t * @default {@link OgvJS.supportsNativeTextTracks}\n\t */\n\n\t/**\n\t * Boolean indicating whether the 'OgvJS' tech currently supports fullscreen resize.\n\t *\n\t * @type {boolean}\n\t * @default {@link OgvJS.supportsFullscreenResize}\n\t */\n\n\t/**\n\t * Boolean indicating whether the 'OgvJS' tech currently supports progress events.\n\t *\n\t * @type {boolean}\n\t * @default {@link OgvJS.supportsProgressEvents}\n\t */\n\n\t/**\n\t * Boolean indicating whether the 'OgvJS' tech currently supports time update events.\n\t *\n\t * @type {boolean}\n\t * @default {@link OgvJS.supportsTimeupdateEvents}\n\t */\n\n\n\t[['featuresVolumeControl', 'canControlVolume'], ['featuresMuteControl', 'canMuteVolume'], ['featuresPlaybackRate', 'canControlPlaybackRate'], ['featuresNativeTextTracks', 'supportsNativeTextTracks'], ['featuresFullscreenResize', 'supportsFullscreenResize'], ['featuresProgressEvents', 'supportsProgressEvents'], ['featuresTimeupdateEvents', 'supportsTimeupdateEvents']].forEach(function (_ref) {\n\t\tvar key = _ref[0],\n\t\t\tfn = _ref[1];\n\t\tdefineLazyProperty(OgvJS.prototype, key, function () {\n\t\t\treturn OgvJS[fn]();\n\t\t}, true);\n\t});\n\tTech.registerTech('OgvJS', OgvJS);\n\n\treturn OgvJS;\n\n})));\n"],"names":["global","factory","this","videojs","ogvBase","_interopDefaultLegacy","e","videojs__default","OGVCompat__default","OGVCompat","OGVLoader__default","OGVLoader","OGVPlayer__default","OGVPlayer","createCommonjsModule","fn","basedir","module","path","exports","require","base","Error","commonjsRequire","setPrototypeOf","_setPrototypeOf","o","p","Object","bind","__proto__","__esModule","inheritsLoose","subClass","superClass","prototype","create","constructor","Tech","getComponent","getDeviceOS","ua","navigator","userAgent","test","platform","maxTouchPoints","OgvJS","_Tech","options","ready","_this","call","el_","src","source","setIfAvailable","autoplay","loop","poster","preload","on","canvas","getElementsByTagName","style","removeProperty","triggerReady","_proto","createEl","options_","el","className","tag","play","playbackRate","setPlaybackRate","val","hasOwnProperty","played","pause","paused","currentTime","setCurrentTime","seconds","log","duration","Infinity","buffered","volume","setVolume","percentAsDecimal","muted","setMuted","defaultMuted","width","offsetWidth","height","offsetHeight","videoWidth","videoHeight","_src","load","currentSrc","currentSource_","setPoster","url","setPreload","setAutoplay","controls","setControls","setLoop","seekable","seeking","ended","networkState","readyState","supportsFullScreen","error","Events","name","value","isSupported","supported","canPlayType","type","indexOf","canPlaySource","srcObj","canControlVolume","canMuteVolume","canControlPlaybackRate","supportsNativeTextTracks","supportsFullscreenResize","supportsProgressEvents","supportsTimeupdateEvents","forEach","_ref","key","obj","getValue","setter","set","defineProperty","enumerable","writable","configurable","get","defineLazyProperty","registerTech","define","amd","globalThis","self","videojsOgvjs"],"mappings":";;;;;;;AAOC,IAAUA,OAAQC,QAARD,OAITE,OAJiBD,QAIV,SAAUE,QAASC,kBAElBC,sBAAuBC,UAAYA,GAAkB,iBAANA,GAAkB,YAAaA,EAAIA,EAAI,SAAaA,OAExGC,iBAAgCF,sBAAsBF,SACtDK,mBAAkCH,sBAAsBD,QAAQK,WAChEC,mBAAkCL,sBAAsBD,QAAQO,WAChEC,mBAAkCP,sBAAsBD,QAAQS,oBAE3DC,qBAAqBC,GAAIC,QAASC,eAOvCF,GANIE,OAAS,CACfC,KAAMF,QACNG,QAAS,GACTC,QAAS,SAAUF,KAAMG,8BAOpB,IAAIC,MAAM,2EANPC,CAAuBF,MAAAA,MAAuCJ,OAAOC,QAEhED,OAAOE,SAAUF,OAAOE,YAOnCK,eAAiBV,sBAAqB,SAAUG,iBAC1CQ,gBAAgBC,EAAGC,UAC3BV,OAAOE,QAAUM,gBAAkBG,OAAOJ,eAAiBI,OAAOJ,eAAeK,OAAS,SAAyBH,EAAGC,UACrHD,EAAEI,UAAYH,EACPD,GACLT,OAAOE,QAAQY,YAAa,EAAMd,OAAOE,QAAP,QAA4BF,OAAOE,QACjEM,gBAAgBC,EAAGC,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CACbgG,cAAc,EACdF,YAAY,EACZG,IAAK,eACA1B,MAAQmB,kBACZE,IAAIrB,OACGA,QAILoB,SACH3F,QAAQ4F,IAAMA,KAGRjH,OAAOkH,eAAeJ,IAAKD,IAAKxF,SAwuBvCkG,CAAmBpG,MAAMZ,UAAWsG,KAAK,kBACjC1F,MAAMhC,SACX,MAEJuB,KAAK8G,aAAa,QAASrG,OAEpBA,OAx0BY,iBAAZ5B,SAA0C,oBAAXF,OAAyBA,OAAOE,QAAUlB,QAAQmB,QAAQ,YAAaA,QAAQ,aAAcA,QAAQ,aAAcA,QAAQ,cAC9I,mBAAXiI,QAAyBA,OAAOC,IAAMD,0CAAO,CAAC,2BAA4B,mBAAoBpJ,UACnGD,OAA+B,oBAAfuJ,WAA6BA,WAAavJ,QAAUwJ,MAAaC,aAAexJ,QAAQD,OAAOG,QAASH,OAAOS,UAAWT,OAAOW,UAAWX,OAAOa"} \ No newline at end of file diff --git a/media/player/videojs/amd/src/videojs-ogvjs-lazy.js b/media/player/videojs/amd/src/videojs-ogvjs-lazy.js index 1dc9eaeaa28..ebb7d7d186a 100644 --- a/media/player/videojs/amd/src/videojs-ogvjs-lazy.js +++ b/media/player/videojs/amd/src/videojs-ogvjs-lazy.js @@ -1,14 +1,14 @@ /** * videojs-ogvjs - * @version 0.1.2 - * @copyright 2021 Huong Nguyen + * @version 0.2.1 + * @copyright 2023 Huong Nguyen * @license MIT */ -/*! @name videojs-ogvjs @version 0.1.2 @license MIT */ +/*! @name videojs-ogvjs @version 0.2.1 @license MIT */ (function (global, factory) { typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('video.js'), require('OGVCompat'), require('OGVLoader'), require('OGVPlayer')) : - typeof define === 'function' && define.amd ? define(['media_videojs/video-lazy', './local/ogv/ogv'], factory) : - (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.videojsOgvjs = factory(global.videojs, global.OGVCompat, global.OGVLoader, global.OGVPlayer)); + typeof define === 'function' && define.amd ? define(['media_videojs/video-lazy', './local/ogv/ogv'], factory) : + (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.videojsOgvjs = factory(global.videojs, global.OGVCompat, global.OGVLoader, global.OGVPlayer)); }(this, (function (videojs, ogvBase) { 'use strict'; function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; } @@ -20,11 +20,11 @@ function createCommonjsModule(fn, basedir, module) { return module = { - path: basedir, - exports: {}, - require: function (path, base) { - return commonjsRequire(path, (base === undefined || base === null) ? module.path : base); - } + path: basedir, + exports: {}, + require: function (path, base) { + return commonjsRequire(path, (base === undefined || base === null) ? module.path : base); + } }, fn(module, module.exports), module.exports; } @@ -33,29 +33,25 @@ } var setPrototypeOf = createCommonjsModule(function (module) { - function _setPrototypeOf(o, p) { - module.exports = _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { - o.__proto__ = p; - return o; - }; + function _setPrototypeOf(o, p) { + module.exports = _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { + o.__proto__ = p; + return o; + }, module.exports.__esModule = true, module.exports["default"] = module.exports; + return _setPrototypeOf(o, p); + } - module.exports["default"] = module.exports, module.exports.__esModule = true; - return _setPrototypeOf(o, p); - } - - module.exports = _setPrototypeOf; - module.exports["default"] = module.exports, module.exports.__esModule = true; + module.exports = _setPrototypeOf, module.exports.__esModule = true, module.exports["default"] = module.exports; }); var inheritsLoose = createCommonjsModule(function (module) { - function _inheritsLoose(subClass, superClass) { - subClass.prototype = Object.create(superClass.prototype); - subClass.prototype.constructor = subClass; - setPrototypeOf(subClass, superClass); - } + function _inheritsLoose(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + setPrototypeOf(subClass, superClass); + } - module.exports = _inheritsLoose; - module.exports["default"] = module.exports, module.exports.__esModule = true; + module.exports = _inheritsLoose, module.exports.__esModule = true, module.exports["default"] = module.exports; }); var Tech = videojs__default['default'].getComponent('Tech'); @@ -74,33 +70,33 @@ */ var defineLazyProperty = function defineLazyProperty(obj, key, getValue, setter) { - if (setter === void 0) { - setter = true; - } + if (setter === void 0) { + setter = true; + } - var set = function set(value) { - Object.defineProperty(obj, key, { - value: value, - enumerable: true, - writable: true - }); - }; + var set = function set(value) { + Object.defineProperty(obj, key, { + value: value, + enumerable: true, + writable: true + }); + }; - var options = { - configurable: true, - enumerable: true, - get: function get() { - var value = getValue(); - set(value); - return value; - } - }; + var options = { + configurable: true, + enumerable: true, + get: function get() { + var value = getValue(); + set(value); + return value; + } + }; - if (setter) { - options.set = set; - } + if (setter) { + options.set = set; + } - return Object.defineProperty(obj, key, options); + return Object.defineProperty(obj, key, options); }; /** * Get the device's OS. @@ -110,18 +106,18 @@ var getDeviceOS = function getDeviceOS() { - /* global navigator */ - var ua = navigator.userAgent; + /* global navigator */ + var ua = navigator.userAgent; - if (/android/i.test(ua)) { - return androidOS; - } else if (/iPad|iPhone|iPod/.test(ua)) { - return iPhoneOS; - } else if (navigator.platform === 'MacIntel' && navigator.maxTouchPoints > 1) { - return iPadOS; - } + if (/android/i.test(ua)) { + return androidOS; + } else if (/iPad|iPhone|iPod/.test(ua)) { + return iPhoneOS; + } else if (navigator.platform === 'MacIntel' && navigator.maxTouchPoints > 1) { + return iPadOS; + } - return otherOS; + return otherOS; }; /** * OgvJS Media Controller - Wrapper for ogv.js Media API @@ -132,528 +128,530 @@ var OgvJS = /*#__PURE__*/function (_Tech) { - inheritsLoose(OgvJS, _Tech); + inheritsLoose(OgvJS, _Tech); - /** - * Create an instance of this Tech. - * - * @param {Object} [options] The key/value store of player options. - * @param {Component~ReadyCallback} ready Callback function to call when the `OgvJS` Tech is ready. - */ - function OgvJS(options, ready) { - var _this; + /** + * Create an instance of this Tech. + * + * @param {Object} [options] The key/value store of player options. + * @param {Component~ReadyCallback} ready Callback function to call when the `OgvJS` Tech is ready. + */ + function OgvJS(options, ready) { + var _this; - _this = _Tech.call(this, options, ready) || this; - _this.el_.src = options.source.src; - OgvJS.setIfAvailable(_this.el_, 'autoplay', options.autoplay); - OgvJS.setIfAvailable(_this.el_, 'loop', options.loop); - OgvJS.setIfAvailable(_this.el_, 'poster', options.poster); - OgvJS.setIfAvailable(_this.el_, 'preload', options.preload); + _this = _Tech.call(this, options, ready) || this; + _this.el_.src = options.source.src; + OgvJS.setIfAvailable(_this.el_, 'autoplay', options.autoplay); + OgvJS.setIfAvailable(_this.el_, 'loop', options.loop); + OgvJS.setIfAvailable(_this.el_, 'poster', options.poster); + OgvJS.setIfAvailable(_this.el_, 'preload', options.preload); - _this.on('loadedmetadata', function () { - if (getDeviceOS() === iPhoneOS) { - // iPhoneOS add some inline styles to the canvas, we need to remove it. - var canvas = this.el_.getElementsByTagName('canvas')[0]; - canvas.style.removeProperty('width'); - canvas.style.removeProperty('margin'); - } + _this.on('loadedmetadata', function () { + if (getDeviceOS() === iPhoneOS) { + // iPhoneOS add some inline styles to the canvas, we need to remove it. + var canvas = _this.el_.getElementsByTagName('canvas')[0]; - this.triggerReady(); - }); + canvas.style.removeProperty('width'); + canvas.style.removeProperty('margin'); + } + }); - return _this; - } - /** - * Create the 'OgvJS' Tech's DOM element. - * - * @return {Element} The element that gets created. - */ + _this.triggerReady(); + + return _this; + } + /** + * Create the 'OgvJS' Tech's DOM element. + * + * @return {Element} The element that gets created. + */ - var _proto = OgvJS.prototype; + var _proto = OgvJS.prototype; - _proto.createEl = function createEl() { - var options = this.options_; + _proto.createEl = function createEl() { + var options = this.options_; - if (options.base) { - OGVLoader__default['default'].base = options.base; - } else { - throw new Error('Please specify the base for the ogv.js library'); - } + if (options.base) { + OGVLoader__default['default'].base = options.base; + } else { + throw new Error('Please specify the base for the ogv.js library'); + } - var el = new OGVPlayer__default['default'](options); - el.className += ' vjs-tech'; - options.tag = el; - return el; - } - /** - * Start playback - * - * @method play - */ - ; + var el = new OGVPlayer__default['default'](options); + el.className += ' vjs-tech'; + options.tag = el; + return el; + } + /** + * Start playback + * + * @method play + */ + ; - _proto.play = function play() { - this.el_.play(); - } - /** - * Get the current playback speed. - * - * @return {number} - * @method playbackRate - */ - ; + _proto.play = function play() { + this.el_.play(); + } + /** + * Get the current playback speed. + * + * @return {number} + * @method playbackRate + */ + ; - _proto.playbackRate = function playbackRate() { - return this.el_.playbackRate || 1; - } - /** - * Set the playback speed. - * - * @param {number} val Speed for the player to play. - * @method setPlaybackRate - */ - ; + _proto.playbackRate = function playbackRate() { + return this.el_.playbackRate || 1; + } + /** + * Set the playback speed. + * + * @param {number} val Speed for the player to play. + * @method setPlaybackRate + */ + ; - _proto.setPlaybackRate = function setPlaybackRate(val) { - if (this.el_.hasOwnProperty('playbackRate')) { - this.el_.playbackRate = val; - } - } - /** - * Returns a TimeRanges object that represents the ranges of the media resource that the user agent has played. - * - * @return {TimeRangeObject} the range of points on the media timeline that has been reached through normal playback - */ - ; + _proto.setPlaybackRate = function setPlaybackRate(val) { + if (this.el_.hasOwnProperty('playbackRate')) { + this.el_.playbackRate = val; + } + } + /** + * Returns a TimeRanges object that represents the ranges of the media resource that the user agent has played. + * + * @return {TimeRangeObject} the range of points on the media timeline that has been reached through normal playback + */ + ; - _proto.played = function played() { - return this.el_.played; - } - /** - * Pause playback - * - * @method pause - */ - ; + _proto.played = function played() { + return this.el_.played; + } + /** + * Pause playback + * + * @method pause + */ + ; - _proto.pause = function pause() { - this.el_.pause(); - } - /** - * Is the player paused or not. - * - * @return {boolean} - * @method paused - */ - ; + _proto.pause = function pause() { + this.el_.pause(); + } + /** + * Is the player paused or not. + * + * @return {boolean} + * @method paused + */ + ; - _proto.paused = function paused() { - return this.el_.paused; - } - /** - * Get current playing time. - * - * @return {number} - * @method currentTime - */ - ; + _proto.paused = function paused() { + return this.el_.paused; + } + /** + * Get current playing time. + * + * @return {number} + * @method currentTime + */ + ; - _proto.currentTime = function currentTime() { - return this.el_.currentTime; - } - /** - * Set current playing time. - * - * @param {number} seconds Current time of audio/video. - * @method setCurrentTime - */ - ; + _proto.currentTime = function currentTime() { + return this.el_.currentTime; + } + /** + * Set current playing time. + * + * @param {number} seconds Current time of audio/video. + * @method setCurrentTime + */ + ; - _proto.setCurrentTime = function setCurrentTime(seconds) { - try { - this.el_.currentTime = seconds; - } catch (e) { - videojs__default['default'].log(e, 'Media is not ready. (Video.JS)'); - } - } - /** - * Get media's duration. - * - * @return {number} - * @method duration - */ - ; + _proto.setCurrentTime = function setCurrentTime(seconds) { + try { + this.el_.currentTime = seconds; + } catch (e) { + videojs__default['default'].log(e, 'Media is not ready. (Video.JS)'); + } + } + /** + * Get media's duration. + * + * @return {number} + * @method duration + */ + ; - _proto.duration = function duration() { - if (this.el_.duration && this.el_.duration !== Infinity) { - return this.el_.duration; - } + _proto.duration = function duration() { + if (this.el_.duration && this.el_.duration !== Infinity) { + return this.el_.duration; + } - return 0; - } - /** - * Get a TimeRange object that represents the intersection - * of the time ranges for which the user agent has all - * relevant media. - * - * @return {TimeRangeObject} - * @method buffered - */ - ; + return 0; + } + /** + * Get a TimeRange object that represents the intersection + * of the time ranges for which the user agent has all + * relevant media. + * + * @return {TimeRangeObject} + * @method buffered + */ + ; - _proto.buffered = function buffered() { - return this.el_.buffered; - } - /** - * Get current volume level. - * - * @return {number} - * @method volume - */ - ; + _proto.buffered = function buffered() { + return this.el_.buffered; + } + /** + * Get current volume level. + * + * @return {number} + * @method volume + */ + ; - _proto.volume = function volume() { - return this.el_.hasOwnProperty('volume') ? this.el_.volume : 1; - } - /** - * Set current playing volume level. - * - * @param {number} percentAsDecimal Volume percent as a decimal. - * @method setVolume - */ - ; + _proto.volume = function volume() { + return this.el_.hasOwnProperty('volume') ? this.el_.volume : 1; + } + /** + * Set current playing volume level. + * + * @param {number} percentAsDecimal Volume percent as a decimal. + * @method setVolume + */ + ; - _proto.setVolume = function setVolume(percentAsDecimal) { - if (getDeviceOS() !== iPhoneOS && this.el_.hasOwnProperty('volume')) { - this.el_.volume = percentAsDecimal; - } - } - /** - * Is the player muted or not. - * - * @return {boolean} - * @method muted - */ - ; + _proto.setVolume = function setVolume(percentAsDecimal) { + // Apple does not allow iOS and iPadOS devices to set the volume on UI. + if (getDeviceOS() !== iPhoneOS && getDeviceOS() !== iPadOS && this.el_.hasOwnProperty('volume')) { + this.el_.volume = percentAsDecimal; + } + } + /** + * Is the player muted or not. + * + * @return {boolean} + * @method muted + */ + ; - _proto.muted = function muted() { - return this.el_.muted; - } - /** - * Mute the player. - * - * @param {boolean} muted True to mute the player. - */ - ; + _proto.muted = function muted() { + return this.el_.muted; + } + /** + * Mute the player. + * + * @param {boolean} muted True to mute the player. + */ + ; - _proto.setMuted = function setMuted(muted) { - this.el_.muted = !!muted; - } - /** - * Is the player muted by default or not. - * - * @return {boolean} - * @method defaultMuted - */ - ; + _proto.setMuted = function setMuted(muted) { + this.el_.muted = !!muted; + } + /** + * Is the player muted by default or not. + * + * @return {boolean} + * @method defaultMuted + */ + ; - _proto.defaultMuted = function defaultMuted() { - return this.el_.defaultMuted || false; - } - /** - * Get the player width. - * - * @return {number} - * @method width - */ - ; + _proto.defaultMuted = function defaultMuted() { + return this.el_.defaultMuted || false; + } + /** + * Get the player width. + * + * @return {number} + * @method width + */ + ; - _proto.width = function width() { - return this.el_.offsetWidth; - } - /** - * Get the player height. - * - * @return {number} - * @method height - */ - ; + _proto.width = function width() { + return this.el_.offsetWidth; + } + /** + * Get the player height. + * + * @return {number} + * @method height + */ + ; - _proto.height = function height() { - return this.el_.offsetHeight; - } - /** - * Get the video width. - * - * @return {number} - * @method videoWidth - */ - ; + _proto.height = function height() { + return this.el_.offsetHeight; + } + /** + * Get the video width. + * + * @return {number} + * @method videoWidth + */ + ; - _proto.videoWidth = function videoWidth() { - return this.el_.videoWidth; - } - /** - * Get the video height. - * - * @return {number} - * @method videoHeight - */ - ; + _proto.videoWidth = function videoWidth() { + return this.el_.videoWidth; + } + /** + * Get the video height. + * + * @return {number} + * @method videoHeight + */ + ; - _proto.videoHeight = function videoHeight() { - return this.el_.videoHeight; - } - /** - * Get/set media source. - * - * @param {Object=} src Source object - * @return {Object} - * @method src - */ - ; + _proto.videoHeight = function videoHeight() { + return this.el_.videoHeight; + } + /** + * Get/set media source. + * + * @param {Object=} src Source object + * @return {Object} + * @method src + */ + ; - _proto.src = function src(_src) { - if (typeof _src === 'undefined') { - return this.el_.src; - } + _proto.src = function src(_src) { + if (typeof _src === 'undefined') { + return this.el_.src; + } - this.el_.src = _src; - } - /** - * Load the media into the player. - * - * @method load - */ - ; + this.el_.src = _src; + } + /** + * Load the media into the player. + * + * @method load + */ + ; - _proto.load = function load() { - this.el_.load(); - } - /** - * Get current media source. - * - * @return {Object} - * @method currentSrc - */ - ; + _proto.load = function load() { + this.el_.load(); + } + /** + * Get current media source. + * + * @return {Object} + * @method currentSrc + */ + ; - _proto.currentSrc = function currentSrc() { - if (this.currentSource_) { - return this.currentSource_.src; - } + _proto.currentSrc = function currentSrc() { + if (this.currentSource_) { + return this.currentSource_.src; + } - return this.el_.currentSrc; - } - /** - * Get media poster URL. - * - * @return {string} - * @method poster - */ - ; + return this.el_.currentSrc; + } + /** + * Get media poster URL. + * + * @return {string} + * @method poster + */ + ; - _proto.poster = function poster() { - return this.el_.poster; - } - /** - * Set media poster URL. - * - * @param {string} url the poster image's url. - * @method - */ - ; + _proto.poster = function poster() { + return this.el_.poster; + } + /** + * Set media poster URL. + * + * @param {string} url the poster image's url. + * @method + */ + ; - _proto.setPoster = function setPoster(url) { - this.el_.poster = url; - } - /** - * Is the media preloaded or not. - * - * @return {string} - * @method preload - */ - ; + _proto.setPoster = function setPoster(url) { + this.el_.poster = url; + } + /** + * Is the media preloaded or not. + * + * @return {string} + * @method preload + */ + ; - _proto.preload = function preload() { - return this.el_.preload || 'none'; - } - /** - * Set the media preload method. - * - * @param {string} val Value for preload attribute. - * @method setPreload - */ - ; + _proto.preload = function preload() { + return this.el_.preload || 'none'; + } + /** + * Set the media preload method. + * + * @param {string} val Value for preload attribute. + * @method setPreload + */ + ; - _proto.setPreload = function setPreload(val) { - if (this.el_.hasOwnProperty('preload')) { - this.el_.preload = val; - } - } - /** - * Is the media auto-played or not. - * - * @return {boolean} - * @method autoplay - */ - ; + _proto.setPreload = function setPreload(val) { + if (this.el_.hasOwnProperty('preload')) { + this.el_.preload = val; + } + } + /** + * Is the media auto-played or not. + * + * @return {boolean} + * @method autoplay + */ + ; - _proto.autoplay = function autoplay() { - return this.el_.autoplay || false; - } - /** - * Set media autoplay method. - * - * @param {boolean} val Value for autoplay attribute. - * @method setAutoplay - */ - ; + _proto.autoplay = function autoplay() { + return this.el_.autoplay || false; + } + /** + * Set media autoplay method. + * + * @param {boolean} val Value for autoplay attribute. + * @method setAutoplay + */ + ; - _proto.setAutoplay = function setAutoplay(val) { - if (this.el_.hasOwnProperty('autoplay')) { - this.el_.autoplay = !!val; - } - } - /** - * Does the media has controls or not. - * - * @return {boolean} - * @method controls - */ - ; + _proto.setAutoplay = function setAutoplay(val) { + if (this.el_.hasOwnProperty('autoplay')) { + this.el_.autoplay = !!val; + } + } + /** + * Does the media has controls or not. + * + * @return {boolean} + * @method controls + */ + ; - _proto.controls = function controls() { - return this.el_.controls || false; - } - /** - * Set the media controls method. - * - * @param {boolean} val Value for controls attribute. - * @method setControls - */ - ; + _proto.controls = function controls() { + return this.el_.controls || false; + } + /** + * Set the media controls method. + * + * @param {boolean} val Value for controls attribute. + * @method setControls + */ + ; - _proto.setControls = function setControls(val) { - if (this.el_.hasOwnProperty('controls')) { - this.el_.controls = !!val; - } - } - /** - * Is the media looped or not. - * - * @return {boolean} - * @method loop - */ - ; + _proto.setControls = function setControls(val) { + if (this.el_.hasOwnProperty('controls')) { + this.el_.controls = !!val; + } + } + /** + * Is the media looped or not. + * + * @return {boolean} + * @method loop + */ + ; - _proto.loop = function loop() { - return this.el_.loop || false; - } - /** - * Set the media loop method. - * - * @param {boolean} val Value for loop attribute. - * @method setLoop - */ - ; + _proto.loop = function loop() { + return this.el_.loop || false; + } + /** + * Set the media loop method. + * + * @param {boolean} val Value for loop attribute. + * @method setLoop + */ + ; - _proto.setLoop = function setLoop(val) { - if (this.el_.hasOwnProperty('loop')) { - this.el_.loop = !!val; - } - } - /** - * Get a TimeRanges object that represents the - * ranges of the media resource to which it is possible - * for the user agent to seek. - * - * @return {TimeRangeObject} - * @method seekable - */ - ; + _proto.setLoop = function setLoop(val) { + if (this.el_.hasOwnProperty('loop')) { + this.el_.loop = !!val; + } + } + /** + * Get a TimeRanges object that represents the + * ranges of the media resource to which it is possible + * for the user agent to seek. + * + * @return {TimeRangeObject} + * @method seekable + */ + ; - _proto.seekable = function seekable() { - return this.el_.seekable; - } - /** - * Is player in the "seeking" state or not. - * - * @return {boolean} - * @method seeking - */ - ; + _proto.seekable = function seekable() { + return this.el_.seekable; + } + /** + * Is player in the "seeking" state or not. + * + * @return {boolean} + * @method seeking + */ + ; - _proto.seeking = function seeking() { - return this.el_.seeking; - } - /** - * Is the media ended or not. - * - * @return {boolean} - * @method ended - */ - ; + _proto.seeking = function seeking() { + return this.el_.seeking; + } + /** + * Is the media ended or not. + * + * @return {boolean} + * @method ended + */ + ; - _proto.ended = function ended() { - return this.el_.ended; - } - /** - * Get the current state of network activity - * NETWORK_EMPTY (numeric value 0) - * NETWORK_IDLE (numeric value 1) - * NETWORK_LOADING (numeric value 2) - * NETWORK_NO_SOURCE (numeric value 3) - * - * @return {number} - * @method networkState - */ - ; + _proto.ended = function ended() { + return this.el_.ended; + } + /** + * Get the current state of network activity + * NETWORK_EMPTY (numeric value 0) + * NETWORK_IDLE (numeric value 1) + * NETWORK_LOADING (numeric value 2) + * NETWORK_NO_SOURCE (numeric value 3) + * + * @return {number} + * @method networkState + */ + ; - _proto.networkState = function networkState() { - return this.el_.networkState; - } - /** - * Get the current state of the player. - * HAVE_NOTHING (numeric value 0) - * HAVE_METADATA (numeric value 1) - * HAVE_CURRENT_DATA (numeric value 2) - * HAVE_FUTURE_DATA (numeric value 3) - * HAVE_ENOUGH_DATA (numeric value 4) - * - * @return {number} - * @method readyState - */ - ; + _proto.networkState = function networkState() { + return this.el_.networkState; + } + /** + * Get the current state of the player. + * HAVE_NOTHING (numeric value 0) + * HAVE_METADATA (numeric value 1) + * HAVE_CURRENT_DATA (numeric value 2) + * HAVE_FUTURE_DATA (numeric value 3) + * HAVE_ENOUGH_DATA (numeric value 4) + * + * @return {number} + * @method readyState + */ + ; - _proto.readyState = function readyState() { - return this.el_.readyState; - } - /** - * Does the player support native fullscreen mode or not. (Mobile devices) - * - * @return {boolean} - */ - ; + _proto.readyState = function readyState() { + return this.el_.readyState; + } + /** + * Does the player support native fullscreen mode or not. (Mobile devices) + * + * @return {boolean} + */ + ; - _proto.supportsFullScreen = function supportsFullScreen() { - // iOS devices have some problem with HTML5 fullscreen api so we need to fallback to fullWindow mode. - return false; - } - /** - * Get media player error. - * - * @return {string} - * @method error - */ - ; + _proto.supportsFullScreen = function supportsFullScreen() { + // iOS devices have some problem with HTML5 fullscreen api so we need to fallback to fullWindow mode. + return false; + } + /** + * Get media player error. + * + * @return {string} + * @method error + */ + ; - _proto.error = function error() { - return this.el_.error; - }; + _proto.error = function error() { + return this.el_.error; + }; - return OgvJS; + return OgvJS; }(Tech); /** * List of available events of the media player. @@ -673,9 +671,9 @@ */ OgvJS.setIfAvailable = function (el, name, value) { - if (el.hasOwnProperty(name)) { - el[name] = value; - } + if (el.hasOwnProperty(name)) { + el[name] = value; + } }; /** * Check if browser/device is supported by Ogv.JS. @@ -685,7 +683,7 @@ OgvJS.isSupported = function () { - return OGVCompat__default['default'].supported('OGVPlayer'); + return OGVCompat__default['default'].supported('OGVPlayer'); }; /** * Check if the tech can support the given type. @@ -696,7 +694,7 @@ OgvJS.canPlayType = function (type) { - return type.indexOf('/ogg') !== -1 || type.indexOf('/webm') ? 'maybe' : ''; + return type.indexOf('/ogg') !== -1 || type.indexOf('/webm') ? 'maybe' : ''; }; /** * Check if the tech can support the given source @@ -707,24 +705,24 @@ OgvJS.canPlaySource = function (srcObj) { - return OgvJS.canPlayType(srcObj.type); + return OgvJS.canPlayType(srcObj.type); }; /** * Check if the volume can be changed in this browser/device. * Volume cannot be changed in a lot of mobile devices. - * Specifically, it can't be changed from 1 on iOS. + * Specifically, it can't be changed on iOS and iPadOS. * * @return {boolean} True if volume can be controlled. */ OgvJS.canControlVolume = function () { - if (getDeviceOS() === iPhoneOS) { - return false; - } + if (getDeviceOS() === iPhoneOS || getDeviceOS() === iPadOS) { + return false; + } - var p = new OGVPlayer__default['default'](); - return p.hasOwnProperty('volume'); + var p = new OGVPlayer__default['default'](); + return p.hasOwnProperty('volume'); }; /** * Check if the volume can be muted in this browser/device. @@ -734,7 +732,7 @@ OgvJS.canMuteVolume = function () { - return true; + return true; }; /** * Check if the playback rate can be changed in this browser/device. @@ -744,7 +742,7 @@ OgvJS.canControlPlaybackRate = function () { - return true; + return true; }; /** * Check to see if native 'TextTracks' are supported by this browser/device. @@ -754,7 +752,7 @@ OgvJS.supportsNativeTextTracks = function () { - return false; + return false; }; /** * Check if the fullscreen resize is supported by this browser/device. @@ -764,7 +762,7 @@ OgvJS.supportsFullscreenResize = function () { - return true; + return true; }; /** * Check if the progress events is supported by this browser/device. @@ -774,7 +772,7 @@ OgvJS.supportsProgressEvents = function () { - return true; + return true; }; /** * Check if the time update events is supported by this browser/device. @@ -784,7 +782,7 @@ OgvJS.supportsTimeupdateEvents = function () { - return true; + return true; }; /** * Boolean indicating whether the 'OgvJS' tech supports volume control. @@ -840,11 +838,11 @@ [['featuresVolumeControl', 'canControlVolume'], ['featuresMuteControl', 'canMuteVolume'], ['featuresPlaybackRate', 'canControlPlaybackRate'], ['featuresNativeTextTracks', 'supportsNativeTextTracks'], ['featuresFullscreenResize', 'supportsFullscreenResize'], ['featuresProgressEvents', 'supportsProgressEvents'], ['featuresTimeupdateEvents', 'supportsTimeupdateEvents']].forEach(function (_ref) { - var key = _ref[0], - fn = _ref[1]; - defineLazyProperty(OgvJS.prototype, key, function () { - OgvJS[fn](); - }, true); + var key = _ref[0], + fn = _ref[1]; + defineLazyProperty(OgvJS.prototype, key, function () { + return OgvJS[fn](); + }, true); }); Tech.registerTech('OgvJS', OgvJS); diff --git a/media/player/videojs/thirdpartylibs.xml b/media/player/videojs/thirdpartylibs.xml index 792cd1d3097..0ae1f40c27e 100644 --- a/media/player/videojs/thirdpartylibs.xml +++ b/media/player/videojs/thirdpartylibs.xml @@ -63,7 +63,7 @@ amd/src/videojs-ogvjs-lazy.js ogv.js Tech plugin for Video.JS The ogv.js tech plugin for VideoJS - 0.1.2 + 0.2.1 MIT https://github.com/HuongNV13/videojs-ogvjs