cloudinary-video-player 3.12.1 → 3.12.2-edge.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (86) hide show
  1. package/dist/134.min.js +8 -0
  2. package/dist/309.min.js +6 -0
  3. package/dist/adaptive-streaming.js +9 -9
  4. package/dist/adaptive-streaming.min.js +2 -2
  5. package/dist/chapters.js +4 -4
  6. package/dist/chapters.min.js +3 -3
  7. package/dist/cld-player-core.js +37 -0
  8. package/dist/cld-player-core.min.js +6 -0
  9. package/dist/cld-video-player-lazy.js +494 -0
  10. package/dist/cld-video-player-lazy.min.js +6 -0
  11. package/dist/cld-video-player.css +2 -2
  12. package/dist/cld-video-player.js +366 -332
  13. package/dist/cld-video-player.light.js +366 -332
  14. package/dist/cld-video-player.light.min.js +4 -4
  15. package/dist/cld-video-player.min.css +2 -2
  16. package/dist/cld-video-player.min.js +4 -4
  17. package/dist/colors.js +4 -4
  18. package/dist/colors.min.js +2 -2
  19. package/dist/dash.js +6 -6
  20. package/dist/dash.min.js +2 -2
  21. package/dist/debug.js +8 -8
  22. package/dist/debug.min.js +3 -3
  23. package/dist/ima.js +9 -9
  24. package/dist/ima.min.js +2 -2
  25. package/dist/interaction-areas.js +11 -11
  26. package/dist/interaction-areas.min.js +2 -2
  27. package/dist/node_modules_lodash_throttle_js.js +8 -8
  28. package/dist/playlist.js +31 -31
  29. package/dist/playlist.min.js +3 -3
  30. package/dist/recommendations-overlay.js +10 -10
  31. package/dist/recommendations-overlay.min.js +2 -2
  32. package/dist/schema.json +19 -0
  33. package/dist/share.js +5 -5
  34. package/dist/share.min.js +3 -3
  35. package/dist/shoppable.js +12 -12
  36. package/dist/shoppable.min.js +2 -2
  37. package/dist/utils_fetch-config_js.js +81 -0
  38. package/dist/video-player_js.js +3111 -0
  39. package/dist/visual-search.js +7 -7
  40. package/dist/visual-search.min.js +2 -2
  41. package/lib/_commonjsHelpers.js +7 -0
  42. package/lib/_videojs-proxy.js +30294 -0
  43. package/lib/abr-strategies.js +31 -0
  44. package/lib/adaptive-streaming.js +468 -2
  45. package/lib/all.js +25 -2
  46. package/lib/chapters.js +205 -1
  47. package/lib/cld-video-player.min.css +5 -22
  48. package/lib/colors.js +59 -1
  49. package/lib/{schema.json → config/configSchema.json} +19 -0
  50. package/lib/dash.js +69943 -2
  51. package/lib/debug.js +322 -1
  52. package/lib/document.js +770 -0
  53. package/lib/download-button.js +48 -0
  54. package/lib/fetch-config.js +93 -0
  55. package/lib/ima.js +6851 -1
  56. package/lib/index.js +27 -0
  57. package/lib/interaction-areas.const.js +24 -0
  58. package/lib/interaction-areas.service.js +469 -0
  59. package/lib/lazy.js +20 -0
  60. package/lib/noop.js +33 -0
  61. package/lib/player-api.js +469 -0
  62. package/lib/player.js +7 -2
  63. package/lib/playlist-panel.js +602 -0
  64. package/lib/playlist.js +637 -1
  65. package/lib/querystring.js +81 -0
  66. package/lib/recommendations-overlay.js +320 -1
  67. package/lib/share.js +129 -1
  68. package/lib/shoppable-post-widget.js +572 -0
  69. package/lib/shoppable-widget.js +77 -0
  70. package/lib/throttle.js +318 -0
  71. package/lib/toNumber.js +134 -0
  72. package/lib/validators-functions.js +485 -0
  73. package/lib/video-player.js +16241 -0
  74. package/lib/videoPlayer.js +7 -2
  75. package/lib/videojs-contrib-hlsjs.js +37638 -0
  76. package/lib/visual-search.js +235 -1
  77. package/package.json +31 -15
  78. package/lib/adaptive-streaming.js.LICENSE.txt +0 -3
  79. package/lib/all.js.LICENSE.txt +0 -25
  80. package/lib/cld-video-player.js +0 -2
  81. package/lib/cld-video-player.js.LICENSE.txt +0 -21
  82. package/lib/dash.js.LICENSE.txt +0 -1842
  83. package/lib/interaction-areas.js +0 -1
  84. package/lib/player.js.LICENSE.txt +0 -21
  85. package/lib/shoppable.js +0 -1
  86. package/lib/videoPlayer.js.LICENSE.txt +0 -21
package/lib/colors.js CHANGED
@@ -1 +1,59 @@
1
- (self.cloudinaryVideoPlayerChunkLoading=self.cloudinaryVideoPlayerChunkLoading||[]).push([[691],{9454:(o,t,e)=>{e.d(t,{default:()=>l,w:()=>r});var s=e(7764);const c={colorsDark:{base:"#000000",accent:"#0D9AFF",text:"#FFFFFF"},colorsLight:{base:"#FFFFFF",accent:"#0D9AFF",text:"#000000"}},r=o=>(0,s.T4)(o)?c.colorsLight:c.colorsDark,l=function(o){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const e=r(o.options_);t.colors=Object.assign({},e,t.colors);const s=o.el();return t.colors.base&&s.style.setProperty("--color-base",t.colors.base),t.colors.accent&&s.style.setProperty("--color-accent",t.colors.accent),t.colors.text&&s.style.setProperty("--color-text",t.colors.text),{updateColors:o=>{const e=Object.assign({},t.colors,o);e.base&&s.style.setProperty("--color-base",e.base),e.accent&&s.style.setProperty("--color-accent",e.accent),e.text&&s.style.setProperty("--color-text",e.text),t.colors=e},getColors:()=>t.colors}}}}]);
1
+ import { i as isLight } from './video-player.js';
2
+ import './_videojs-proxy.js';
3
+ import './_commonjsHelpers.js';
4
+ import './validators-functions.js';
5
+ import './querystring.js';
6
+ import './player-api.js';
7
+
8
+ const defaults = {
9
+ colorsDark: {
10
+ 'base': '#000000',
11
+ 'accent': '#0D9AFF',
12
+ 'text': '#FFFFFF'
13
+ },
14
+ colorsLight: {
15
+ 'base': '#FFFFFF',
16
+ 'accent': '#0D9AFF',
17
+ 'text': '#000000'
18
+ }
19
+ };
20
+ const getDefaultPlayerColor = options => {
21
+ return isLight(options) ? defaults.colorsLight : defaults.colorsDark;
22
+ };
23
+ const colorsPlugin = function (player) {
24
+ let opts = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
25
+ const skinDefaults = getDefaultPlayerColor(player.options_);
26
+ opts.colors = Object.assign({}, skinDefaults, opts.colors);
27
+
28
+ // Set CSS custom properties on the player element
29
+ const playerEl = player.el();
30
+ if (opts.colors.base) {
31
+ playerEl.style.setProperty('--color-base', opts.colors.base);
32
+ }
33
+ if (opts.colors.accent) {
34
+ playerEl.style.setProperty('--color-accent', opts.colors.accent);
35
+ }
36
+ if (opts.colors.text) {
37
+ playerEl.style.setProperty('--color-text', opts.colors.text);
38
+ }
39
+
40
+ // Return an object with methods to update colors if needed
41
+ return {
42
+ updateColors: newColors => {
43
+ const updatedColors = Object.assign({}, opts.colors, newColors);
44
+ if (updatedColors.base) {
45
+ playerEl.style.setProperty('--color-base', updatedColors.base);
46
+ }
47
+ if (updatedColors.accent) {
48
+ playerEl.style.setProperty('--color-accent', updatedColors.accent);
49
+ }
50
+ if (updatedColors.text) {
51
+ playerEl.style.setProperty('--color-text', updatedColors.text);
52
+ }
53
+ opts.colors = updatedColors;
54
+ },
55
+ getColors: () => opts.colors
56
+ };
57
+ };
58
+
59
+ export { colorsPlugin as default, getDefaultPlayerColor };
@@ -559,6 +559,25 @@
559
559
  "type": "boolean",
560
560
  "default": true
561
561
  },
562
+ "schedule": {
563
+ "type": "object",
564
+ "properties": {
565
+ "weekly": {
566
+ "type": "array",
567
+ "items": {
568
+ "type": "object",
569
+ "properties": {
570
+ "day": { "type": "string" },
571
+ "start": { "type": "string" },
572
+ "duration": { "type": "number" }
573
+ },
574
+ "required": ["day", "start", "duration"]
575
+ },
576
+ "default": []
577
+ }
578
+ },
579
+ "default": {}
580
+ },
562
581
  "videoSources": {
563
582
  "type": "array",
564
583
  "items": {