cloudinary-video-player 3.6.3-edge.6 → 3.6.3-edge.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/adaptive-streaming.js +50 -50
- package/dist/adaptive-streaming.min.js +5 -5
- package/dist/chapters.js +10 -10
- package/dist/chapters.min.js +3 -3
- package/dist/cld-video-player.css +2 -2
- package/dist/cld-video-player.js +1861 -1856
- package/dist/cld-video-player.light.js +1861 -1856
- package/dist/cld-video-player.light.min.js +4 -4
- package/dist/cld-video-player.min.css +3 -3
- package/dist/cld-video-player.min.js +4 -4
- package/dist/colors.js +10 -10
- package/dist/colors.min.js +3 -3
- package/dist/dash.js +18 -18
- package/dist/dash.min.js +4 -4
- package/dist/debug.js +38 -38
- package/dist/debug.min.js +3 -3
- package/dist/ima.js +44 -44
- package/dist/ima.min.js +3 -3
- package/dist/interaction-areas.js +58 -58
- package/dist/interaction-areas.min.js +3 -3
- package/dist/node_modules_lodash_throttle_js.js +26 -26
- package/dist/playlist.js +182 -182
- package/dist/playlist.min.js +3 -3
- package/dist/recommendations-overlay.js +34 -34
- package/dist/recommendations-overlay.min.js +3 -3
- package/dist/share.js +14 -14
- package/dist/share.min.js +3 -3
- package/dist/shoppable.js +48 -48
- package/dist/shoppable.min.js +3 -3
- package/dist/visual-search.js +22 -22
- package/dist/visual-search.min.js +3 -3
- package/lib/adaptive-streaming.js +1 -1
- package/lib/all.js +1 -1
- package/lib/chapters.js +1 -1
- package/lib/cld-video-player.js +1 -1
- package/lib/colors.js +1 -1
- package/lib/dash.js +1 -1
- package/lib/debug.js +1 -1
- package/lib/ima.js +1 -1
- package/lib/interaction-areas.js +1 -1
- package/lib/player.js +1 -1
- package/lib/playlist.js +1 -1
- package/lib/recommendations-overlay.js +1 -1
- package/lib/share.js +1 -1
- package/lib/shoppable.js +1 -1
- package/lib/videoPlayer.js +1 -1
- package/lib/visual-search.js +1 -1
- package/package.json +1 -1
package/dist/chapters.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* Cloudinary Video Player v3.6.3-edge.
|
|
3
|
-
* Built on 2025-12-
|
|
2
|
+
* Cloudinary Video Player v3.6.3-edge.8
|
|
3
|
+
* Built on 2025-12-18T17:10:29.081Z
|
|
4
4
|
* https://github.com/cloudinary/cloudinary-video-player
|
|
5
5
|
*/
|
|
6
6
|
"use strict";
|
|
@@ -14,24 +14,24 @@
|
|
|
14
14
|
*/
|
|
15
15
|
(self["cloudinaryVideoPlayerChunkLoading"] = self["cloudinaryVideoPlayerChunkLoading"] || []).push([["chapters"],{
|
|
16
16
|
|
|
17
|
-
/***/ "./plugins/chapters/chapters.js"
|
|
17
|
+
/***/ "./plugins/chapters/chapters.js"
|
|
18
18
|
/*!**************************************!*\
|
|
19
19
|
!*** ./plugins/chapters/chapters.js ***!
|
|
20
20
|
\**************************************/
|
|
21
|
-
|
|
21
|
+
(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
22
22
|
|
|
23
|
-
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (__WEBPACK_DEFAULT_EXPORT__)\n/* harmony export */ });\n/* harmony import */ var video_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! video.js */ \"../node_modules/video.js/dist/alt/video.core-exposed.js\");\n/* harmony import */ var video_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(video_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _chapters_scss__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./chapters.scss */ \"./plugins/chapters/chapters.scss\");\n/* harmony import */ var _cloudinary_common__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../cloudinary/common */ \"./plugins/cloudinary/common.js\");\n/* harmony import */ var _utils_utf8Base64__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../utils/utf8Base64 */ \"./utils/utf8Base64.js\");\n\n\n\n\n\n/**\n * Chapters plugin.\n *\n * @function chapters\n * @param {Object} [options={}]\n * An object of options left to the plugin author to define.\n * @param {Player} player\n * A Video.js player object.\n */\nconst chapters = function chapters(options, player) {\n player.addClass('vjs-chapters');\n player.chapters = new ChaptersPlugin(player, options);\n};\n\n/**\n * Chapters\n */\nconst ChaptersPlugin = function () {\n /**\n * Plugin class constructor, called by videojs on\n * ready event.\n *\n * @function constructor\n * @param {Player} player\n * A Video.js player object.\n *\n * @param {Object} [options={}]\n * A plain object containing options for the plugin.\n */\n function ChaptersPlugin(player, options) {\n this.player = player;\n this.options = options;\n this.player.one('loadedmetadata', this.initializeChapters.bind(this));\n return this;\n }\n ChaptersPlugin.prototype.src = function src(options) {\n this.resetPlugin();\n this.options = options;\n this.player.one('loadedmetadata', this.initializeChapters.bind(this));\n };\n ChaptersPlugin.prototype.detach = function detach() {\n this.resetPlugin();\n };\n ChaptersPlugin.prototype.resetPlugin = function resetPlugin() {\n if (this.chaptersTrack) {\n this.player.$('.vjs-control-bar-chapter-display').remove();\n this.player.$('.vjs-chapter-display').remove();\n this.player.$$('.vjs-chapter-marker').forEach(el => el.remove());\n this.player.removeRemoteTextTrack(this.chaptersTrack);\n delete this.chaptersTrack;\n }\n };\n ChaptersPlugin.prototype.getChaptersFileUrlByName = function getChaptersFileUrlByName() {\n const currentPublicId = this.player.cloudinary.currentPublicId();\n if (!currentPublicId) {\n return null;\n }\n const {\n type: deliveryType\n } = this.player.cloudinary.source().resourceConfig();\n const urlPrefix = (0,_cloudinary_common__WEBPACK_IMPORTED_MODULE_2__.getCloudinaryUrlPrefix)(this.player.cloudinary.cloudinaryConfig());\n const fullUrl =
|
|
23
|
+
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (__WEBPACK_DEFAULT_EXPORT__)\n/* harmony export */ });\n/* harmony import */ var video_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! video.js */ \"../node_modules/video.js/dist/alt/video.core-exposed.js\");\n/* harmony import */ var video_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(video_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _chapters_scss__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./chapters.scss */ \"./plugins/chapters/chapters.scss\");\n/* harmony import */ var _cloudinary_common__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../cloudinary/common */ \"./plugins/cloudinary/common.js\");\n/* harmony import */ var _utils_utf8Base64__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../utils/utf8Base64 */ \"./utils/utf8Base64.js\");\n\n\n\n\n\n/**\n * Chapters plugin.\n *\n * @function chapters\n * @param {Object} [options={}]\n * An object of options left to the plugin author to define.\n * @param {Player} player\n * A Video.js player object.\n */\nconst chapters = function chapters(options, player) {\n player.addClass('vjs-chapters');\n player.chapters = new ChaptersPlugin(player, options);\n};\n\n/**\n * Chapters\n */\nconst ChaptersPlugin = function () {\n /**\n * Plugin class constructor, called by videojs on\n * ready event.\n *\n * @function constructor\n * @param {Player} player\n * A Video.js player object.\n *\n * @param {Object} [options={}]\n * A plain object containing options for the plugin.\n */\n function ChaptersPlugin(player, options) {\n this.player = player;\n this.options = options;\n this.player.one('loadedmetadata', this.initializeChapters.bind(this));\n return this;\n }\n ChaptersPlugin.prototype.src = function src(options) {\n this.resetPlugin();\n this.options = options;\n this.player.one('loadedmetadata', this.initializeChapters.bind(this));\n };\n ChaptersPlugin.prototype.detach = function detach() {\n this.resetPlugin();\n };\n ChaptersPlugin.prototype.resetPlugin = function resetPlugin() {\n if (this.chaptersTrack) {\n this.player.$('.vjs-control-bar-chapter-display').remove();\n this.player.$('.vjs-chapter-display').remove();\n this.player.$$('.vjs-chapter-marker').forEach(el => el.remove());\n this.player.removeRemoteTextTrack(this.chaptersTrack);\n delete this.chaptersTrack;\n }\n };\n ChaptersPlugin.prototype.getChaptersFileUrlByName = function getChaptersFileUrlByName() {\n const currentPublicId = this.player.cloudinary.currentPublicId();\n if (!currentPublicId) {\n return null;\n }\n const {\n type: deliveryType\n } = this.player.cloudinary.source().resourceConfig();\n const urlPrefix = (0,_cloudinary_common__WEBPACK_IMPORTED_MODULE_2__.getCloudinaryUrlPrefix)(this.player.cloudinary.cloudinaryConfig());\n const fullUrl = `${urlPrefix}/_applet_/video_service/chapters/${deliveryType}/${(0,_utils_utf8Base64__WEBPACK_IMPORTED_MODULE_3__.utf8ToBase64)(currentPublicId)}.vtt`;\n return `${fullUrl}?t=${Date.now()}`;\n };\n\n /**\n * Bootstrap the plugin.\n */\n ChaptersPlugin.prototype.initializeChapters = async function initializeChapters() {\n const chaptersUrl = this.options === true ? this.getChaptersFileUrlByName() : this.options.url;\n if (chaptersUrl) {\n // Fetch chapters VTT from URL\n const chaptersTrack = {\n kind: 'chapters',\n src: chaptersUrl,\n default: true\n };\n const textTrack = this.player.addRemoteTextTrack(chaptersTrack);\n textTrack.addEventListener('load', () => {\n this.chaptersTrack = textTrack.track;\n this.setupChaptersDisplays();\n });\n } else if (Object.entries(this.options).length) {\n // Setup chapters from options\n const textTrack = this.player.addRemoteTextTrack({\n kind: 'chapters',\n default: true\n });\n const end = this.player.duration();\n Object.entries(this.options).forEach((entry, index, arr) => {\n const cue = new VTTCue(parseFloat(entry[0]), parseFloat(arr[index + 1] ? arr[index + 1][0] : end), entry[1]);\n textTrack.track.addCue(cue);\n });\n this.chaptersTrack = textTrack.track;\n this.setupChaptersDisplays();\n if (this.player.controlBar.chaptersButton) {\n this.player.controlBar.chaptersButton.update();\n }\n }\n };\n\n /**\n * Setup chapter displays.\n */\n ChaptersPlugin.prototype.setupChaptersDisplays = function initializeChapters() {\n this.setupProgressBarMarkers();\n this.setupProgressBarChapter();\n this.setupControlBarChapter();\n };\n\n /**\n * Setup the controlbar chapter display.\n */\n ChaptersPlugin.prototype.setupControlBarChapter = function setupControlBarChapter() {\n const controlBarChapterHolder = this.player.$('.vjs-control-bar-chapter-display') || document.createElement('div');\n controlBarChapterHolder.setAttribute('class', 'vjs-control-bar-chapter-display');\n const wrapper = this.player.$('.vjs-control-bar .vjs-spacer');\n wrapper.innerHTML = '';\n wrapper.classList.add('vjs-control-bar-chapter-wrapper');\n wrapper.appendChild(controlBarChapterHolder);\n this.chaptersTrack.addEventListener('cuechange', () => {\n const activeCues = Array.from(this.chaptersTrack.activeCues); // Safari needs Array.from()\n controlBarChapterHolder.innerText = activeCues.length > 0 ? activeCues[0].text : '';\n });\n };\n\n /**\n * Setup the progress bar markers.\n */\n ChaptersPlugin.prototype.setupProgressBarMarkers = function setupProgressBarMarkers() {\n const total = this.player.duration();\n const {\n seekBar\n } = this.player.controlBar.progressControl;\n Array.from(this.chaptersTrack.cues).forEach(marker => {\n // Safari needs Array.from()\n if (marker.startTime !== 0) {\n const markerTime = marker.startTime;\n const left = markerTime / total * 100 + '%';\n const markerEl = video_js__WEBPACK_IMPORTED_MODULE_0___default().dom.createEl('div', undefined, {\n class: 'vjs-chapter-marker',\n style: `left: ${left}`\n });\n seekBar.el().append(markerEl);\n }\n });\n };\n\n /**\n * Setup the progrees bar on-hover chapter display.\n */\n ChaptersPlugin.prototype.setupProgressBarChapter = function setupProgressBarChapter() {\n const chapterEl = video_js__WEBPACK_IMPORTED_MODULE_0___default().dom.createEl('div', undefined, {\n class: 'vjs-chapter-display',\n style: `max-width: ${this.player.$('.vjs-vtt-thumbnail-display') ? this.player.$('.vjs-vtt-thumbnail-display').style.width : '160px'}`\n });\n const mouseTimeDisplay = this.player.getDescendant(['controlBar', 'progressControl', 'seekBar', 'mouseTimeDisplay']);\n const timeTooltip = mouseTimeDisplay.getDescendant(['timeTooltip']);\n timeTooltip.el().parentElement.prepend(chapterEl);\n const getChapterFromPoint = point => {\n const total = this.player.duration();\n const seekBarTime = point * total;\n const chapter = Array.from(this.chaptersTrack?.cues || []).find(marker => {\n return seekBarTime >= marker.startTime && seekBarTime <= marker.endTime;\n });\n return chapter ? chapter.text : '';\n };\n timeTooltip.update = function (seekBarRect, seekBarPoint, content) {\n const originalUpdateFn = Object.getPrototypeOf(this).update;\n originalUpdateFn.call(this, seekBarRect, seekBarPoint, content);\n chapterEl.innerText = getChapterFromPoint(seekBarPoint);\n };\n\n // Handle case of no seek-thumbnails\n if (typeof this.player.vttThumbnails !== 'object') {\n mouseTimeDisplay.update = function (seekBarRect, seekBarPoint) {\n const time = seekBarPoint * this.player_.duration();\n const width = seekBarRect.width;\n const size = chapterEl.clientWidth / 2;\n timeTooltip.updateTime(seekBarRect, seekBarPoint, time, () => {\n // Make sure it doesn't exit the player\n if (seekBarRect.width * seekBarPoint < size) {\n this.el_.style.left = `${size}px`;\n } else if (seekBarRect.width * seekBarPoint + size > width) {\n this.el_.style.left = `${seekBarRect.width - size}px`;\n } else {\n this.el_.style.left = `${seekBarRect.width * seekBarPoint}px`;\n }\n });\n timeTooltip.write(video_js__WEBPACK_IMPORTED_MODULE_0___default().time.formatTime(time));\n };\n }\n };\n return ChaptersPlugin;\n}();\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (chapters);\n\n//# sourceURL=webpack://cloudinary-video-player/./plugins/chapters/chapters.js?\n}");
|
|
24
24
|
|
|
25
|
-
/***/ }
|
|
25
|
+
/***/ },
|
|
26
26
|
|
|
27
|
-
/***/ "./plugins/chapters/chapters.scss"
|
|
27
|
+
/***/ "./plugins/chapters/chapters.scss"
|
|
28
28
|
/*!****************************************!*\
|
|
29
29
|
!*** ./plugins/chapters/chapters.scss ***!
|
|
30
30
|
\****************************************/
|
|
31
|
-
|
|
31
|
+
(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
32
32
|
|
|
33
|
-
eval("__webpack_require__.r(__webpack_exports__);\n// extracted by mini-css-extract-plugin\n\n\n//# sourceURL=webpack://cloudinary-video-player/./plugins/chapters/chapters.scss
|
|
33
|
+
eval("{__webpack_require__.r(__webpack_exports__);\n// extracted by mini-css-extract-plugin\n\n\n//# sourceURL=webpack://cloudinary-video-player/./plugins/chapters/chapters.scss?\n}");
|
|
34
34
|
|
|
35
|
-
/***/ }
|
|
35
|
+
/***/ }
|
|
36
36
|
|
|
37
37
|
}]);
|
package/dist/chapters.min.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* Cloudinary Video Player v3.6.3-edge.
|
|
3
|
-
* Built on 2025-12-
|
|
2
|
+
* Cloudinary Video Player v3.6.3-edge.8
|
|
3
|
+
* Built on 2025-12-18T17:10:14.274Z
|
|
4
4
|
* https://github.com/cloudinary/cloudinary-video-player
|
|
5
5
|
*/
|
|
6
|
-
"use strict";(self.cloudinaryVideoPlayerChunkLoading=self.cloudinaryVideoPlayerChunkLoading||[]).push([[625],{9234
|
|
6
|
+
"use strict";(self.cloudinaryVideoPlayerChunkLoading=self.cloudinaryVideoPlayerChunkLoading||[]).push([[625],{9234(t,e,r){r.d(e,{default:()=>p});var s=r(6673),a=r.n(s),i=r(1865),o=r(2415);const n=function(){function t(t,e){return this.player=t,this.options=e,this.player.one("loadedmetadata",this.initializeChapters.bind(this)),this}return t.prototype.src=function(t){this.resetPlugin(),this.options=t,this.player.one("loadedmetadata",this.initializeChapters.bind(this))},t.prototype.detach=function(){this.resetPlugin()},t.prototype.resetPlugin=function(){this.chaptersTrack&&(this.player.$(".vjs-control-bar-chapter-display").remove(),this.player.$(".vjs-chapter-display").remove(),this.player.$$(".vjs-chapter-marker").forEach(t=>t.remove()),this.player.removeRemoteTextTrack(this.chaptersTrack),delete this.chaptersTrack)},t.prototype.getChaptersFileUrlByName=function(){const t=this.player.cloudinary.currentPublicId();if(!t)return null;const{type:e}=this.player.cloudinary.source().resourceConfig();return`${`${(0,i.k$)(this.player.cloudinary.cloudinaryConfig())}/_applet_/video_service/chapters/${e}/${(0,o.G)(t)}.vtt`}?t=${Date.now()}`},t.prototype.initializeChapters=async function(){const t=!0===this.options?this.getChaptersFileUrlByName():this.options.url;if(t){const e={kind:"chapters",src:t,default:!0},r=this.player.addRemoteTextTrack(e);r.addEventListener("load",()=>{this.chaptersTrack=r.track,this.setupChaptersDisplays()})}else if(Object.entries(this.options).length){const t=this.player.addRemoteTextTrack({kind:"chapters",default:!0}),e=this.player.duration();Object.entries(this.options).forEach((r,s,a)=>{const i=new VTTCue(parseFloat(r[0]),parseFloat(a[s+1]?a[s+1][0]:e),r[1]);t.track.addCue(i)}),this.chaptersTrack=t.track,this.setupChaptersDisplays(),this.player.controlBar.chaptersButton&&this.player.controlBar.chaptersButton.update()}},t.prototype.setupChaptersDisplays=function(){this.setupProgressBarMarkers(),this.setupProgressBarChapter(),this.setupControlBarChapter()},t.prototype.setupControlBarChapter=function(){const t=this.player.$(".vjs-control-bar-chapter-display")||document.createElement("div");t.setAttribute("class","vjs-control-bar-chapter-display");const e=this.player.$(".vjs-control-bar .vjs-spacer");e.innerHTML="",e.classList.add("vjs-control-bar-chapter-wrapper"),e.appendChild(t),this.chaptersTrack.addEventListener("cuechange",()=>{const e=Array.from(this.chaptersTrack.activeCues);t.innerText=e.length>0?e[0].text:""})},t.prototype.setupProgressBarMarkers=function(){const t=this.player.duration(),{seekBar:e}=this.player.controlBar.progressControl;Array.from(this.chaptersTrack.cues).forEach(r=>{if(0!==r.startTime){const s=r.startTime/t*100+"%",i=a().dom.createEl("div",void 0,{class:"vjs-chapter-marker",style:`left: ${s}`});e.el().append(i)}})},t.prototype.setupProgressBarChapter=function(){const t=a().dom.createEl("div",void 0,{class:"vjs-chapter-display",style:`max-width: ${this.player.$(".vjs-vtt-thumbnail-display")?this.player.$(".vjs-vtt-thumbnail-display").style.width:"160px"}`}),e=this.player.getDescendant(["controlBar","progressControl","seekBar","mouseTimeDisplay"]),r=e.getDescendant(["timeTooltip"]);r.el().parentElement.prepend(t);const s=t=>{const e=t*this.player.duration(),r=Array.from(this.chaptersTrack?.cues||[]).find(t=>e>=t.startTime&&e<=t.endTime);return r?r.text:""};r.update=function(e,r,a){Object.getPrototypeOf(this).update.call(this,e,r,a),t.innerText=s(r)},"object"!=typeof this.player.vttThumbnails&&(e.update=function(e,s){const i=s*this.player_.duration(),o=e.width,n=t.clientWidth/2;r.updateTime(e,s,i,()=>{e.width*s<n?this.el_.style.left=`${n}px`:e.width*s+n>o?this.el_.style.left=e.width-n+"px":this.el_.style.left=e.width*s+"px"}),r.write(a().time.formatTime(i))})},t}(),p=function(t,e){e.addClass("vjs-chapters"),e.chapters=new n(e,t)}}}]);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* Cloudinary Video Player v3.6.3-edge.
|
|
3
|
-
* Built on 2025-12-
|
|
2
|
+
* Cloudinary Video Player v3.6.3-edge.8
|
|
3
|
+
* Built on 2025-12-18T17:10:29.081Z
|
|
4
4
|
* https://github.com/cloudinary/cloudinary-video-player
|
|
5
5
|
*/
|
|
6
6
|
/*!*************************************************************************************************!*\
|