@clappr/player 0.5.0 → 0.7.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.
- package/dist/clappr.js +27046 -25855
- package/dist/clappr.js.map +1 -1
- package/dist/clappr.min.js +280 -187
- package/dist/clappr.min.js.map +1 -1
- package/dist/clappr.plainhtml5.js +756 -685
- package/dist/clappr.plainhtml5.js.map +1 -1
- package/dist/clappr.plainhtml5.min.js +1 -1
- package/dist/clappr.plainhtml5.min.js.map +1 -1
- package/package.json +18 -4
- package/LICENSE +0 -25
|
@@ -4,29 +4,29 @@
|
|
|
4
4
|
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Clappr = factory());
|
|
5
5
|
})(this, (function () { 'use strict';
|
|
6
6
|
|
|
7
|
-
function ownKeys$1(
|
|
8
|
-
var
|
|
7
|
+
function ownKeys$1(e, r) {
|
|
8
|
+
var t = Object.keys(e);
|
|
9
9
|
if (Object.getOwnPropertySymbols) {
|
|
10
|
-
var
|
|
11
|
-
|
|
12
|
-
return Object.getOwnPropertyDescriptor(
|
|
13
|
-
})),
|
|
10
|
+
var o = Object.getOwnPropertySymbols(e);
|
|
11
|
+
r && (o = o.filter(function (r) {
|
|
12
|
+
return Object.getOwnPropertyDescriptor(e, r).enumerable;
|
|
13
|
+
})), t.push.apply(t, o);
|
|
14
14
|
}
|
|
15
|
-
return
|
|
15
|
+
return t;
|
|
16
16
|
}
|
|
17
|
-
function _objectSpread2$1(
|
|
18
|
-
for (var
|
|
19
|
-
var
|
|
20
|
-
|
|
21
|
-
_defineProperty$1(
|
|
22
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(
|
|
23
|
-
Object.defineProperty(
|
|
17
|
+
function _objectSpread2$1(e) {
|
|
18
|
+
for (var r = 1; r < arguments.length; r++) {
|
|
19
|
+
var t = null != arguments[r] ? arguments[r] : {};
|
|
20
|
+
r % 2 ? ownKeys$1(Object(t), !0).forEach(function (r) {
|
|
21
|
+
_defineProperty$1(e, r, t[r]);
|
|
22
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$1(Object(t)).forEach(function (r) {
|
|
23
|
+
Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
|
|
24
24
|
});
|
|
25
25
|
}
|
|
26
|
-
return
|
|
26
|
+
return e;
|
|
27
27
|
}
|
|
28
28
|
function _defineProperty$1(obj, key, value) {
|
|
29
|
-
key = _toPropertyKey$
|
|
29
|
+
key = _toPropertyKey$2(key);
|
|
30
30
|
if (key in obj) {
|
|
31
31
|
Object.defineProperty(obj, key, {
|
|
32
32
|
value: value,
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
}
|
|
40
40
|
return obj;
|
|
41
41
|
}
|
|
42
|
-
function _toPrimitive$
|
|
42
|
+
function _toPrimitive$2(input, hint) {
|
|
43
43
|
if (typeof input !== "object" || input === null) return input;
|
|
44
44
|
var prim = input[Symbol.toPrimitive];
|
|
45
45
|
if (prim !== undefined) {
|
|
@@ -49,40 +49,92 @@
|
|
|
49
49
|
}
|
|
50
50
|
return (hint === "string" ? String : Number)(input);
|
|
51
51
|
}
|
|
52
|
-
function _toPropertyKey$
|
|
53
|
-
var key = _toPrimitive$
|
|
52
|
+
function _toPropertyKey$2(arg) {
|
|
53
|
+
var key = _toPrimitive$2(arg, "string");
|
|
54
54
|
return typeof key === "symbol" ? key : String(key);
|
|
55
55
|
}
|
|
56
56
|
|
|
57
|
-
function
|
|
58
|
-
|
|
57
|
+
function _callSuper$1(t, o, e) {
|
|
58
|
+
return o = _getPrototypeOf$1(o), _possibleConstructorReturn$1(t, _isNativeReflectConstruct$1() ? Reflect.construct(o, e || [], _getPrototypeOf$1(t).constructor) : o.apply(t, e));
|
|
59
|
+
}
|
|
60
|
+
function _isNativeReflectConstruct$1() {
|
|
61
|
+
try {
|
|
62
|
+
var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
|
|
63
|
+
} catch (t) {}
|
|
64
|
+
return (_isNativeReflectConstruct$1 = function () {
|
|
65
|
+
return !!t;
|
|
66
|
+
})();
|
|
67
|
+
}
|
|
68
|
+
function _iterableToArrayLimit(r, l) {
|
|
69
|
+
var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
|
|
70
|
+
if (null != t) {
|
|
71
|
+
var e,
|
|
72
|
+
n,
|
|
73
|
+
i,
|
|
74
|
+
u,
|
|
75
|
+
a = [],
|
|
76
|
+
f = !0,
|
|
77
|
+
o = !1;
|
|
78
|
+
try {
|
|
79
|
+
if (i = (t = t.call(r)).next, 0 === l) {
|
|
80
|
+
if (Object(t) !== t) return;
|
|
81
|
+
f = !1;
|
|
82
|
+
} else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0);
|
|
83
|
+
} catch (r) {
|
|
84
|
+
o = !0, n = r;
|
|
85
|
+
} finally {
|
|
86
|
+
try {
|
|
87
|
+
if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return;
|
|
88
|
+
} finally {
|
|
89
|
+
if (o) throw n;
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
return a;
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
function ownKeys(e, r) {
|
|
96
|
+
var t = Object.keys(e);
|
|
59
97
|
if (Object.getOwnPropertySymbols) {
|
|
60
|
-
var
|
|
61
|
-
|
|
62
|
-
return Object.getOwnPropertyDescriptor(
|
|
63
|
-
})),
|
|
98
|
+
var o = Object.getOwnPropertySymbols(e);
|
|
99
|
+
r && (o = o.filter(function (r) {
|
|
100
|
+
return Object.getOwnPropertyDescriptor(e, r).enumerable;
|
|
101
|
+
})), t.push.apply(t, o);
|
|
64
102
|
}
|
|
65
|
-
return
|
|
103
|
+
return t;
|
|
66
104
|
}
|
|
67
|
-
function _objectSpread2(
|
|
68
|
-
for (var
|
|
69
|
-
var
|
|
70
|
-
|
|
71
|
-
_defineProperty(
|
|
72
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(
|
|
73
|
-
Object.defineProperty(
|
|
105
|
+
function _objectSpread2(e) {
|
|
106
|
+
for (var r = 1; r < arguments.length; r++) {
|
|
107
|
+
var t = null != arguments[r] ? arguments[r] : {};
|
|
108
|
+
r % 2 ? ownKeys(Object(t), !0).forEach(function (r) {
|
|
109
|
+
_defineProperty(e, r, t[r]);
|
|
110
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {
|
|
111
|
+
Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
|
|
74
112
|
});
|
|
75
113
|
}
|
|
76
|
-
return
|
|
114
|
+
return e;
|
|
77
115
|
}
|
|
78
|
-
function
|
|
116
|
+
function _toPrimitive$1(t, r) {
|
|
117
|
+
if ("object" != typeof t || !t) return t;
|
|
118
|
+
var e = t[Symbol.toPrimitive];
|
|
119
|
+
if (void 0 !== e) {
|
|
120
|
+
var i = e.call(t, r);
|
|
121
|
+
if ("object" != typeof i) return i;
|
|
122
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
123
|
+
}
|
|
124
|
+
return String(t);
|
|
125
|
+
}
|
|
126
|
+
function _toPropertyKey$1(t) {
|
|
127
|
+
var i = _toPrimitive$1(t, "string");
|
|
128
|
+
return "symbol" == typeof i ? i : i + "";
|
|
129
|
+
}
|
|
130
|
+
function _typeof(o) {
|
|
79
131
|
"@babel/helpers - typeof";
|
|
80
132
|
|
|
81
|
-
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (
|
|
82
|
-
return typeof
|
|
83
|
-
} : function (
|
|
84
|
-
return
|
|
85
|
-
}, _typeof(
|
|
133
|
+
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
|
|
134
|
+
return typeof o;
|
|
135
|
+
} : function (o) {
|
|
136
|
+
return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
|
|
137
|
+
}, _typeof(o);
|
|
86
138
|
}
|
|
87
139
|
function _classCallCheck$1(instance, Constructor) {
|
|
88
140
|
if (!(instance instanceof Constructor)) {
|
|
@@ -95,7 +147,7 @@
|
|
|
95
147
|
descriptor.enumerable = descriptor.enumerable || false;
|
|
96
148
|
descriptor.configurable = true;
|
|
97
149
|
if ("value" in descriptor) descriptor.writable = true;
|
|
98
|
-
Object.defineProperty(target, descriptor.key, descriptor);
|
|
150
|
+
Object.defineProperty(target, _toPropertyKey$1(descriptor.key), descriptor);
|
|
99
151
|
}
|
|
100
152
|
}
|
|
101
153
|
function _createClass$1(Constructor, protoProps, staticProps) {
|
|
@@ -107,6 +159,7 @@
|
|
|
107
159
|
return Constructor;
|
|
108
160
|
}
|
|
109
161
|
function _defineProperty(obj, key, value) {
|
|
162
|
+
key = _toPropertyKey$1(key);
|
|
110
163
|
if (key in obj) {
|
|
111
164
|
Object.defineProperty(obj, key, {
|
|
112
165
|
value: value,
|
|
@@ -148,17 +201,6 @@
|
|
|
148
201
|
};
|
|
149
202
|
return _setPrototypeOf$1(o, p);
|
|
150
203
|
}
|
|
151
|
-
function _isNativeReflectConstruct$1() {
|
|
152
|
-
if (typeof Reflect === "undefined" || !Reflect.construct) return false;
|
|
153
|
-
if (Reflect.construct.sham) return false;
|
|
154
|
-
if (typeof Proxy === "function") return true;
|
|
155
|
-
try {
|
|
156
|
-
Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
|
|
157
|
-
return true;
|
|
158
|
-
} catch (e) {
|
|
159
|
-
return false;
|
|
160
|
-
}
|
|
161
|
-
}
|
|
162
204
|
function _assertThisInitialized$1(self) {
|
|
163
205
|
if (self === void 0) {
|
|
164
206
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
@@ -173,20 +215,6 @@
|
|
|
173
215
|
}
|
|
174
216
|
return _assertThisInitialized$1(self);
|
|
175
217
|
}
|
|
176
|
-
function _createSuper$1(Derived) {
|
|
177
|
-
var hasNativeReflectConstruct = _isNativeReflectConstruct$1();
|
|
178
|
-
return function _createSuperInternal() {
|
|
179
|
-
var Super = _getPrototypeOf$1(Derived),
|
|
180
|
-
result;
|
|
181
|
-
if (hasNativeReflectConstruct) {
|
|
182
|
-
var NewTarget = _getPrototypeOf$1(this).constructor;
|
|
183
|
-
result = Reflect.construct(Super, arguments, NewTarget);
|
|
184
|
-
} else {
|
|
185
|
-
result = Super.apply(this, arguments);
|
|
186
|
-
}
|
|
187
|
-
return _possibleConstructorReturn$1(this, result);
|
|
188
|
-
};
|
|
189
|
-
}
|
|
190
218
|
function _superPropBase$1(object, property) {
|
|
191
219
|
while (!Object.prototype.hasOwnProperty.call(object, property)) {
|
|
192
220
|
object = _getPrototypeOf$1(object);
|
|
@@ -225,30 +253,6 @@
|
|
|
225
253
|
function _iterableToArray(iter) {
|
|
226
254
|
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
|
|
227
255
|
}
|
|
228
|
-
function _iterableToArrayLimit(arr, i) {
|
|
229
|
-
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
230
|
-
if (_i == null) return;
|
|
231
|
-
var _arr = [];
|
|
232
|
-
var _n = true;
|
|
233
|
-
var _d = false;
|
|
234
|
-
var _s, _e;
|
|
235
|
-
try {
|
|
236
|
-
for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) {
|
|
237
|
-
_arr.push(_s.value);
|
|
238
|
-
if (i && _arr.length === i) break;
|
|
239
|
-
}
|
|
240
|
-
} catch (err) {
|
|
241
|
-
_d = true;
|
|
242
|
-
_e = err;
|
|
243
|
-
} finally {
|
|
244
|
-
try {
|
|
245
|
-
if (!_n && _i["return"] != null) _i["return"]();
|
|
246
|
-
} finally {
|
|
247
|
-
if (_d) throw _e;
|
|
248
|
-
}
|
|
249
|
-
}
|
|
250
|
-
return _arr;
|
|
251
|
-
}
|
|
252
256
|
function _unsupportedIterableToArray(o, minLen) {
|
|
253
257
|
if (!o) return;
|
|
254
258
|
if (typeof o === "string") return _arrayLikeToArray(o, minLen);
|
|
@@ -271,7 +275,7 @@
|
|
|
271
275
|
function _createForOfIteratorHelper(o, allowArrayLike) {
|
|
272
276
|
var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"];
|
|
273
277
|
if (!it) {
|
|
274
|
-
if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike
|
|
278
|
+
if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike) {
|
|
275
279
|
if (it) o = it;
|
|
276
280
|
var i = 0;
|
|
277
281
|
var F = function () {};
|
|
@@ -319,173 +323,10 @@
|
|
|
319
323
|
}
|
|
320
324
|
};
|
|
321
325
|
}
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
// Use of this source code is governed by a BSD-style
|
|
325
|
-
// license that can be found in the LICENSE file.
|
|
326
|
-
|
|
327
|
-
/* istanbul ignore file */
|
|
328
|
-
|
|
329
|
-
/**
|
|
330
|
-
* Array.prototype.find
|
|
331
|
-
*
|
|
332
|
-
* Original source : https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Array/find
|
|
333
|
-
* See also : https://tc39.github.io/ecma262/#sec-array.prototype.find
|
|
334
|
-
*/
|
|
335
|
-
if (!Array.prototype.find) {
|
|
336
|
-
// eslint-disable-next-line
|
|
337
|
-
Object.defineProperty(Array.prototype, 'find', {
|
|
338
|
-
// Note: ES6 arrow function syntax is not used on purpose to avoid this to be undefined
|
|
339
|
-
value: function value(predicate) {
|
|
340
|
-
// 1. Let O be ? ToObject(this value).
|
|
341
|
-
if (this == null) throw new TypeError('"this" is null or not defined');
|
|
342
|
-
var o = Object(this);
|
|
343
|
-
|
|
344
|
-
// 2. Let len be ? ToLength(? Get(O, "length")).
|
|
345
|
-
var len = o.length >>> 0;
|
|
346
|
-
|
|
347
|
-
// 3. If IsCallable(predicate) is false, throw a TypeError exception.
|
|
348
|
-
if (typeof predicate !== 'function') throw new TypeError('predicate must be a function');
|
|
349
|
-
|
|
350
|
-
// 4. If thisArg was supplied, let T be thisArg; else let T be undefined.
|
|
351
|
-
var thisArg = arguments[1];
|
|
352
|
-
|
|
353
|
-
// 5. Let k be 0.
|
|
354
|
-
var k = 0;
|
|
355
|
-
|
|
356
|
-
// 6. Repeat, while k < len
|
|
357
|
-
while (k < len) {
|
|
358
|
-
// a. Let Pk be ! ToString(k).
|
|
359
|
-
// b. Let kValue be ? Get(O, Pk).
|
|
360
|
-
// c. Let testResult be ToBoolean(? Call(predicate, T, « kValue, k, O »)).
|
|
361
|
-
// d. If testResult is true, return kValue.
|
|
362
|
-
var kValue = o[k];
|
|
363
|
-
if (predicate.call(thisArg, kValue, k, o)) return kValue;
|
|
364
|
-
|
|
365
|
-
// e. Increase k by 1.
|
|
366
|
-
k++;
|
|
367
|
-
}
|
|
368
|
-
|
|
369
|
-
// 7. Return undefined.
|
|
370
|
-
return undefined;
|
|
371
|
-
}
|
|
372
|
-
});
|
|
373
|
-
}
|
|
374
|
-
|
|
375
|
-
// polyfills for smart TVs
|
|
376
|
-
|
|
377
|
-
if (!Object.entries) {
|
|
378
|
-
Object.entries = function (obj) {
|
|
379
|
-
var ownProps = Object.keys(obj),
|
|
380
|
-
i = ownProps.length,
|
|
381
|
-
resArray = new Array(i); // preallocate the Array
|
|
382
|
-
while (i--) {
|
|
383
|
-
resArray[i] = [ownProps[i], obj[ownProps[i]]];
|
|
384
|
-
}
|
|
385
|
-
return resArray;
|
|
386
|
-
};
|
|
387
|
-
}
|
|
388
|
-
if (!Object.values) {
|
|
389
|
-
Object.values = function (obj) {
|
|
390
|
-
var ownProps = Object.keys(obj),
|
|
391
|
-
i = ownProps.length,
|
|
392
|
-
resArray = new Array(i); // preallocate the Array
|
|
393
|
-
while (i--) {
|
|
394
|
-
resArray[i] = obj[ownProps[i]];
|
|
395
|
-
}
|
|
396
|
-
return resArray;
|
|
397
|
-
};
|
|
398
|
-
}
|
|
399
|
-
|
|
400
|
-
/**
|
|
401
|
-
* Object.assign
|
|
402
|
-
* This polyfill doesn't support symbol properties, since ES5 doesn't have symbols anyway
|
|
403
|
-
*
|
|
404
|
-
* Original source : https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/assign
|
|
405
|
-
*/
|
|
406
|
-
if (typeof Object.assign != 'function') {
|
|
407
|
-
// Must be writable: true, enumerable: false, configurable: true
|
|
408
|
-
Object.defineProperty(Object, 'assign', {
|
|
409
|
-
// length of function is 2.
|
|
410
|
-
value: function assign(target, varArgs) {
|
|
411
|
-
|
|
412
|
-
if (target == null) {
|
|
413
|
-
// TypeError if undefined or null
|
|
414
|
-
throw new TypeError('Cannot convert undefined or null to object');
|
|
415
|
-
}
|
|
416
|
-
var to = Object(target);
|
|
417
|
-
for (var index = 1; index < arguments.length; index++) {
|
|
418
|
-
var nextSource = arguments[index];
|
|
419
|
-
if (nextSource != null) {
|
|
420
|
-
// Skip over if undefined or null
|
|
421
|
-
for (var nextKey in nextSource) {
|
|
422
|
-
// Avoid bugs when hasOwnProperty is shadowed
|
|
423
|
-
if (Object.prototype.hasOwnProperty.call(nextSource, nextKey)) {
|
|
424
|
-
to[nextKey] = nextSource[nextKey];
|
|
425
|
-
}
|
|
426
|
-
}
|
|
427
|
-
}
|
|
428
|
-
}
|
|
429
|
-
return to;
|
|
430
|
-
},
|
|
431
|
-
writable: true,
|
|
432
|
-
configurable: true
|
|
433
|
-
});
|
|
434
|
-
}
|
|
435
|
-
|
|
436
|
-
// https://tc39.github.io/ecma262/#sec-array.prototype.findindex
|
|
437
|
-
if (!Array.prototype.findIndex) {
|
|
438
|
-
Object.defineProperty(Array.prototype, 'findIndex', {
|
|
439
|
-
value: function value(predicate) {
|
|
440
|
-
// 1. Let O be ? ToObject(this value).
|
|
441
|
-
if (this == null) {
|
|
442
|
-
throw new TypeError('"this" is null or not defined');
|
|
443
|
-
}
|
|
444
|
-
var o = Object(this);
|
|
445
|
-
|
|
446
|
-
// 2. Let len be ? ToLength(? Get(O, "length")).
|
|
447
|
-
var len = o.length >>> 0;
|
|
448
|
-
|
|
449
|
-
// 3. If IsCallable(predicate) is false, throw a TypeError exception.
|
|
450
|
-
if (typeof predicate !== 'function') {
|
|
451
|
-
throw new TypeError('predicate must be a function');
|
|
452
|
-
}
|
|
453
|
-
|
|
454
|
-
// 4. If thisArg was supplied, let T be thisArg; else let T be undefined.
|
|
455
|
-
var thisArg = arguments[1];
|
|
456
|
-
|
|
457
|
-
// 5. Let k be 0.
|
|
458
|
-
var k = 0;
|
|
459
|
-
|
|
460
|
-
// 6. Repeat, while k < len
|
|
461
|
-
while (k < len) {
|
|
462
|
-
// a. Let Pk be ! ToString(k).
|
|
463
|
-
// b. Let kValue be ? Get(O, Pk).
|
|
464
|
-
// c. Let testResult be ToBoolean(? Call(predicate, T, « kValue, k, O »)).
|
|
465
|
-
// d. If testResult is true, return k.
|
|
466
|
-
var kValue = o[k];
|
|
467
|
-
if (predicate.call(thisArg, kValue, k, o)) {
|
|
468
|
-
return k;
|
|
469
|
-
}
|
|
470
|
-
// e. Increase k by 1.
|
|
471
|
-
k++;
|
|
472
|
-
}
|
|
473
|
-
|
|
474
|
-
// 7. Return -1.
|
|
475
|
-
return -1;
|
|
476
|
-
},
|
|
477
|
-
configurable: true,
|
|
478
|
-
writable: true
|
|
479
|
-
});
|
|
326
|
+
function getDefaultExportFromCjs(x) {
|
|
327
|
+
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
|
480
328
|
}
|
|
481
329
|
|
|
482
|
-
/* istanbul ignore file */
|
|
483
|
-
// https://github.com/mathiasbynens/small
|
|
484
|
-
var mp4 = 'data:video/mp4;base64,AAAAHGZ0eXBpc29tAAACAGlzb21pc28ybXA0MQAAAAhmcmVlAAAC721kYXQhEAUgpBv/wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA3pwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcCEQBSCkG//AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADengAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcAAAAsJtb292AAAAbG12aGQAAAAAAAAAAAAAAAAAAAPoAAAALwABAAABAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAAAB7HRyYWsAAABcdGtoZAAAAAMAAAAAAAAAAAAAAAIAAAAAAAAALwAAAAAAAAAAAAAAAQEAAAAAAQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAACRlZHRzAAAAHGVsc3QAAAAAAAAAAQAAAC8AAAAAAAEAAAAAAWRtZGlhAAAAIG1kaGQAAAAAAAAAAAAAAAAAAKxEAAAIAFXEAAAAAAAtaGRscgAAAAAAAAAAc291bgAAAAAAAAAAAAAAAFNvdW5kSGFuZGxlcgAAAAEPbWluZgAAABBzbWhkAAAAAAAAAAAAAAAkZGluZgAAABxkcmVmAAAAAAAAAAEAAAAMdXJsIAAAAAEAAADTc3RibAAAAGdzdHNkAAAAAAAAAAEAAABXbXA0YQAAAAAAAAABAAAAAAAAAAAAAgAQAAAAAKxEAAAAAAAzZXNkcwAAAAADgICAIgACAASAgIAUQBUAAAAAAfQAAAHz+QWAgIACEhAGgICAAQIAAAAYc3R0cwAAAAAAAAABAAAAAgAABAAAAAAcc3RzYwAAAAAAAAABAAAAAQAAAAIAAAABAAAAHHN0c3oAAAAAAAAAAAAAAAIAAAFzAAABdAAAABRzdGNvAAAAAAAAAAEAAAAsAAAAYnVkdGEAAABabWV0YQAAAAAAAAAhaGRscgAAAAAAAAAAbWRpcmFwcGwAAAAAAAAAAAAAAAAtaWxzdAAAACWpdG9vAAAAHWRhdGEAAAABAAAAAExhdmY1Ni40MC4xMDE=';
|
|
485
|
-
var Media = {
|
|
486
|
-
mp4: mp4
|
|
487
|
-
};
|
|
488
|
-
|
|
489
330
|
/* Zepto v1.2.0 - zepto ajax callbacks deferred event ie selector - zeptojs.com/license */
|
|
490
331
|
var Zepto = function () {
|
|
491
332
|
var undefined$1,
|
|
@@ -1317,6 +1158,7 @@
|
|
|
1317
1158
|
|
|
1318
1159
|
// Generate the `width` and `height` functions
|
|
1319
1160
|
;
|
|
1161
|
+
|
|
1320
1162
|
['width', 'height'].forEach(function (dimension) {
|
|
1321
1163
|
var dimensionProperty = dimension.replace(/./, function (m) {
|
|
1322
1164
|
return m[0].toUpperCase();
|
|
@@ -2183,6 +2025,7 @@
|
|
|
2183
2025
|
|
|
2184
2026
|
// shortcut methods for `.bind(event, fn)` for each event type
|
|
2185
2027
|
;
|
|
2028
|
+
|
|
2186
2029
|
('focusin focusout focus blur load resize scroll unload click dblclick ' + 'mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave ' + 'change select keydown keypress keyup error').split(' ').forEach(function (event) {
|
|
2187
2030
|
$.fn[event] = function (callback) {
|
|
2188
2031
|
return 0 in arguments ? this.bind(event, callback) : this.trigger(event);
|
|
@@ -2311,6 +2154,168 @@
|
|
|
2311
2154
|
};
|
|
2312
2155
|
})(Zepto);
|
|
2313
2156
|
var zepto = Zepto;
|
|
2157
|
+
var $ = /*@__PURE__*/getDefaultExportFromCjs(zepto);
|
|
2158
|
+
|
|
2159
|
+
// Copyright 2014 Globo.com Player authors. All rights reserved.
|
|
2160
|
+
// Use of this source code is governed by a BSD-style
|
|
2161
|
+
// license that can be found in the LICENSE file.
|
|
2162
|
+
|
|
2163
|
+
/* istanbul ignore file */
|
|
2164
|
+
|
|
2165
|
+
/**
|
|
2166
|
+
* Array.prototype.find
|
|
2167
|
+
*
|
|
2168
|
+
* Original source : https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Array/find
|
|
2169
|
+
* See also : https://tc39.github.io/ecma262/#sec-array.prototype.find
|
|
2170
|
+
*/
|
|
2171
|
+
if (!Array.prototype.find) {
|
|
2172
|
+
// eslint-disable-next-line
|
|
2173
|
+
Object.defineProperty(Array.prototype, 'find', {
|
|
2174
|
+
// Note: ES6 arrow function syntax is not used on purpose to avoid this to be undefined
|
|
2175
|
+
value: function value(predicate) {
|
|
2176
|
+
// 1. Let O be ? ToObject(this value).
|
|
2177
|
+
if (this == null) throw new TypeError('"this" is null or not defined');
|
|
2178
|
+
var o = Object(this);
|
|
2179
|
+
|
|
2180
|
+
// 2. Let len be ? ToLength(? Get(O, "length")).
|
|
2181
|
+
var len = o.length >>> 0;
|
|
2182
|
+
|
|
2183
|
+
// 3. If IsCallable(predicate) is false, throw a TypeError exception.
|
|
2184
|
+
if (typeof predicate !== 'function') throw new TypeError('predicate must be a function');
|
|
2185
|
+
|
|
2186
|
+
// 4. If thisArg was supplied, let T be thisArg; else let T be undefined.
|
|
2187
|
+
var thisArg = arguments[1];
|
|
2188
|
+
|
|
2189
|
+
// 5. Let k be 0.
|
|
2190
|
+
var k = 0;
|
|
2191
|
+
|
|
2192
|
+
// 6. Repeat, while k < len
|
|
2193
|
+
while (k < len) {
|
|
2194
|
+
// a. Let Pk be ! ToString(k).
|
|
2195
|
+
// b. Let kValue be ? Get(O, Pk).
|
|
2196
|
+
// c. Let testResult be ToBoolean(? Call(predicate, T, « kValue, k, O »)).
|
|
2197
|
+
// d. If testResult is true, return kValue.
|
|
2198
|
+
var kValue = o[k];
|
|
2199
|
+
if (predicate.call(thisArg, kValue, k, o)) return kValue;
|
|
2200
|
+
|
|
2201
|
+
// e. Increase k by 1.
|
|
2202
|
+
k++;
|
|
2203
|
+
}
|
|
2204
|
+
|
|
2205
|
+
// 7. Return undefined.
|
|
2206
|
+
return undefined;
|
|
2207
|
+
}
|
|
2208
|
+
});
|
|
2209
|
+
}
|
|
2210
|
+
|
|
2211
|
+
// polyfills for smart TVs
|
|
2212
|
+
|
|
2213
|
+
if (!Object.entries) {
|
|
2214
|
+
Object.entries = function (obj) {
|
|
2215
|
+
var ownProps = Object.keys(obj),
|
|
2216
|
+
i = ownProps.length,
|
|
2217
|
+
resArray = new Array(i); // preallocate the Array
|
|
2218
|
+
while (i--) resArray[i] = [ownProps[i], obj[ownProps[i]]];
|
|
2219
|
+
return resArray;
|
|
2220
|
+
};
|
|
2221
|
+
}
|
|
2222
|
+
if (!Object.values) {
|
|
2223
|
+
Object.values = function (obj) {
|
|
2224
|
+
var ownProps = Object.keys(obj),
|
|
2225
|
+
i = ownProps.length,
|
|
2226
|
+
resArray = new Array(i); // preallocate the Array
|
|
2227
|
+
while (i--) resArray[i] = obj[ownProps[i]];
|
|
2228
|
+
return resArray;
|
|
2229
|
+
};
|
|
2230
|
+
}
|
|
2231
|
+
|
|
2232
|
+
/**
|
|
2233
|
+
* Object.assign
|
|
2234
|
+
* This polyfill doesn't support symbol properties, since ES5 doesn't have symbols anyway
|
|
2235
|
+
*
|
|
2236
|
+
* Original source : https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/assign
|
|
2237
|
+
*/
|
|
2238
|
+
if (typeof Object.assign != 'function') {
|
|
2239
|
+
// Must be writable: true, enumerable: false, configurable: true
|
|
2240
|
+
Object.defineProperty(Object, 'assign', {
|
|
2241
|
+
// length of function is 2.
|
|
2242
|
+
value: function assign(target, varArgs) {
|
|
2243
|
+
if (target == null) {
|
|
2244
|
+
// TypeError if undefined or null
|
|
2245
|
+
throw new TypeError('Cannot convert undefined or null to object');
|
|
2246
|
+
}
|
|
2247
|
+
var to = Object(target);
|
|
2248
|
+
for (var index = 1; index < arguments.length; index++) {
|
|
2249
|
+
var nextSource = arguments[index];
|
|
2250
|
+
if (nextSource != null) {
|
|
2251
|
+
// Skip over if undefined or null
|
|
2252
|
+
for (var nextKey in nextSource) {
|
|
2253
|
+
// Avoid bugs when hasOwnProperty is shadowed
|
|
2254
|
+
if (Object.prototype.hasOwnProperty.call(nextSource, nextKey)) {
|
|
2255
|
+
to[nextKey] = nextSource[nextKey];
|
|
2256
|
+
}
|
|
2257
|
+
}
|
|
2258
|
+
}
|
|
2259
|
+
}
|
|
2260
|
+
return to;
|
|
2261
|
+
},
|
|
2262
|
+
writable: true,
|
|
2263
|
+
configurable: true
|
|
2264
|
+
});
|
|
2265
|
+
}
|
|
2266
|
+
|
|
2267
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.findindex
|
|
2268
|
+
if (!Array.prototype.findIndex) {
|
|
2269
|
+
Object.defineProperty(Array.prototype, 'findIndex', {
|
|
2270
|
+
value: function value(predicate) {
|
|
2271
|
+
// 1. Let O be ? ToObject(this value).
|
|
2272
|
+
if (this == null) {
|
|
2273
|
+
throw new TypeError('"this" is null or not defined');
|
|
2274
|
+
}
|
|
2275
|
+
var o = Object(this);
|
|
2276
|
+
|
|
2277
|
+
// 2. Let len be ? ToLength(? Get(O, "length")).
|
|
2278
|
+
var len = o.length >>> 0;
|
|
2279
|
+
|
|
2280
|
+
// 3. If IsCallable(predicate) is false, throw a TypeError exception.
|
|
2281
|
+
if (typeof predicate !== 'function') {
|
|
2282
|
+
throw new TypeError('predicate must be a function');
|
|
2283
|
+
}
|
|
2284
|
+
|
|
2285
|
+
// 4. If thisArg was supplied, let T be thisArg; else let T be undefined.
|
|
2286
|
+
var thisArg = arguments[1];
|
|
2287
|
+
|
|
2288
|
+
// 5. Let k be 0.
|
|
2289
|
+
var k = 0;
|
|
2290
|
+
|
|
2291
|
+
// 6. Repeat, while k < len
|
|
2292
|
+
while (k < len) {
|
|
2293
|
+
// a. Let Pk be ! ToString(k).
|
|
2294
|
+
// b. Let kValue be ? Get(O, Pk).
|
|
2295
|
+
// c. Let testResult be ToBoolean(? Call(predicate, T, « kValue, k, O »)).
|
|
2296
|
+
// d. If testResult is true, return k.
|
|
2297
|
+
var kValue = o[k];
|
|
2298
|
+
if (predicate.call(thisArg, kValue, k, o)) {
|
|
2299
|
+
return k;
|
|
2300
|
+
}
|
|
2301
|
+
// e. Increase k by 1.
|
|
2302
|
+
k++;
|
|
2303
|
+
}
|
|
2304
|
+
|
|
2305
|
+
// 7. Return -1.
|
|
2306
|
+
return -1;
|
|
2307
|
+
},
|
|
2308
|
+
configurable: true,
|
|
2309
|
+
writable: true
|
|
2310
|
+
});
|
|
2311
|
+
}
|
|
2312
|
+
|
|
2313
|
+
/* istanbul ignore file */
|
|
2314
|
+
// https://github.com/mathiasbynens/small
|
|
2315
|
+
var mp4 = 'data:video/mp4;base64,AAAAHGZ0eXBpc29tAAACAGlzb21pc28ybXA0MQAAAAhmcmVlAAAC721kYXQhEAUgpBv/wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA3pwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcCEQBSCkG//AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADengAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcAAAAsJtb292AAAAbG12aGQAAAAAAAAAAAAAAAAAAAPoAAAALwABAAABAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAAAB7HRyYWsAAABcdGtoZAAAAAMAAAAAAAAAAAAAAAIAAAAAAAAALwAAAAAAAAAAAAAAAQEAAAAAAQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAACRlZHRzAAAAHGVsc3QAAAAAAAAAAQAAAC8AAAAAAAEAAAAAAWRtZGlhAAAAIG1kaGQAAAAAAAAAAAAAAAAAAKxEAAAIAFXEAAAAAAAtaGRscgAAAAAAAAAAc291bgAAAAAAAAAAAAAAAFNvdW5kSGFuZGxlcgAAAAEPbWluZgAAABBzbWhkAAAAAAAAAAAAAAAkZGluZgAAABxkcmVmAAAAAAAAAAEAAAAMdXJsIAAAAAEAAADTc3RibAAAAGdzdHNkAAAAAAAAAAEAAABXbXA0YQAAAAAAAAABAAAAAAAAAAAAAgAQAAAAAKxEAAAAAAAzZXNkcwAAAAADgICAIgACAASAgIAUQBUAAAAAAfQAAAHz+QWAgIACEhAGgICAAQIAAAAYc3R0cwAAAAAAAAABAAAAAgAABAAAAAAcc3RzYwAAAAAAAAABAAAAAQAAAAIAAAABAAAAHHN0c3oAAAAAAAAAAAAAAAIAAAFzAAABdAAAABRzdGNvAAAAAAAAAAEAAAAsAAAAYnVkdGEAAABabWV0YQAAAAAAAAAhaGRscgAAAAAAAAAAbWRpcmFwcGwAAAAAAAAAAAAAAAAtaWxzdAAAACWpdG9vAAAAHWRhdGEAAAABAAAAAExhdmY1Ni40MC4xMDE=';
|
|
2316
|
+
var Media = {
|
|
2317
|
+
mp4: mp4
|
|
2318
|
+
};
|
|
2314
2319
|
|
|
2315
2320
|
/* eslint-disable no-useless-escape */
|
|
2316
2321
|
// The order of the following arrays is important, be careful if you change it.
|
|
@@ -2551,7 +2556,6 @@
|
|
|
2551
2556
|
group: 'BlackBerry',
|
|
2552
2557
|
identifier: 'BlackBerry'
|
|
2553
2558
|
}];
|
|
2554
|
-
|
|
2555
2559
|
var Browser = {};
|
|
2556
2560
|
var hasLocalstorage = function hasLocalstorage() {
|
|
2557
2561
|
try {
|
|
@@ -2708,8 +2712,8 @@
|
|
|
2708
2712
|
// Set viewport size
|
|
2709
2713
|
var getViewportSize = function getViewportSize() {
|
|
2710
2714
|
var viewportObject = {};
|
|
2711
|
-
viewportObject.width =
|
|
2712
|
-
viewportObject.height =
|
|
2715
|
+
viewportObject.width = $(window).width();
|
|
2716
|
+
viewportObject.height = $(window).height();
|
|
2713
2717
|
return viewportObject;
|
|
2714
2718
|
};
|
|
2715
2719
|
|
|
@@ -2772,7 +2776,6 @@
|
|
|
2772
2776
|
Browser.viewport = getViewportSize();
|
|
2773
2777
|
Browser.device = getDevice(Browser.userAgent);
|
|
2774
2778
|
typeof window.orientation !== 'undefined' && setViewportOrientation();
|
|
2775
|
-
|
|
2776
2779
|
var idsCounter = {};
|
|
2777
2780
|
var videoStack = [];
|
|
2778
2781
|
var requestAnimationFrame = (window.requestAnimationFrame || window.mozRequestAnimationFrame || window.webkitRequestAnimationFrame || function (fn) {
|
|
@@ -2790,23 +2793,29 @@
|
|
|
2790
2793
|
}
|
|
2791
2794
|
function extend$1(parent, properties) {
|
|
2792
2795
|
var Surrogate = /*#__PURE__*/function (_parent) {
|
|
2793
|
-
_inherits$1(Surrogate, _parent);
|
|
2794
|
-
var _super = _createSuper$1(Surrogate);
|
|
2795
2796
|
function Surrogate() {
|
|
2796
2797
|
var _this;
|
|
2797
2798
|
_classCallCheck$1(this, Surrogate);
|
|
2798
2799
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
2799
2800
|
args[_key] = arguments[_key];
|
|
2800
2801
|
}
|
|
2801
|
-
_this =
|
|
2802
|
-
if (properties.initialize) properties.initialize.apply(
|
|
2802
|
+
_this = _callSuper$1(this, Surrogate, [].concat(args));
|
|
2803
|
+
if (properties.initialize) properties.initialize.apply(_this, args);
|
|
2803
2804
|
return _this;
|
|
2804
2805
|
}
|
|
2806
|
+
_inherits$1(Surrogate, _parent);
|
|
2805
2807
|
return _createClass$1(Surrogate);
|
|
2806
2808
|
}(parent);
|
|
2807
2809
|
assign(Surrogate.prototype, properties);
|
|
2808
2810
|
return Surrogate;
|
|
2809
2811
|
}
|
|
2812
|
+
|
|
2813
|
+
/**
|
|
2814
|
+
*
|
|
2815
|
+
* @param {number} time
|
|
2816
|
+
* @param {*=} paddedHours
|
|
2817
|
+
* @returns
|
|
2818
|
+
*/
|
|
2810
2819
|
function formatTime$2(time, paddedHours) {
|
|
2811
2820
|
if (!isFinite(time)) return '--:--';
|
|
2812
2821
|
time = time * 1000;
|
|
@@ -2859,7 +2868,7 @@
|
|
|
2859
2868
|
function Config() {
|
|
2860
2869
|
_classCallCheck$1(this, Config);
|
|
2861
2870
|
}
|
|
2862
|
-
_createClass$1(Config, null, [{
|
|
2871
|
+
return _createClass$1(Config, null, [{
|
|
2863
2872
|
key: "_defaultConfig",
|
|
2864
2873
|
value: function _defaultConfig() {
|
|
2865
2874
|
return {
|
|
@@ -2902,13 +2911,12 @@
|
|
|
2902
2911
|
}
|
|
2903
2912
|
}
|
|
2904
2913
|
}]);
|
|
2905
|
-
return Config;
|
|
2906
2914
|
}();
|
|
2907
2915
|
var QueryString = /*#__PURE__*/function () {
|
|
2908
2916
|
function QueryString() {
|
|
2909
2917
|
_classCallCheck$1(this, QueryString);
|
|
2910
2918
|
}
|
|
2911
|
-
_createClass$1(QueryString, null, [{
|
|
2919
|
+
return _createClass$1(QueryString, null, [{
|
|
2912
2920
|
key: "params",
|
|
2913
2921
|
get: function get() {
|
|
2914
2922
|
var query = window.location.search.substring(1);
|
|
@@ -2946,7 +2954,6 @@
|
|
|
2946
2954
|
return params;
|
|
2947
2955
|
}
|
|
2948
2956
|
}]);
|
|
2949
|
-
return QueryString;
|
|
2950
2957
|
}();
|
|
2951
2958
|
function seekStringToSeconds() {
|
|
2952
2959
|
var paramName = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 't';
|
|
@@ -3045,10 +3052,10 @@
|
|
|
3045
3052
|
function DomRecycler() {
|
|
3046
3053
|
_classCallCheck$1(this, DomRecycler);
|
|
3047
3054
|
}
|
|
3048
|
-
_createClass$1(DomRecycler, null, [{
|
|
3055
|
+
return _createClass$1(DomRecycler, null, [{
|
|
3049
3056
|
key: "configure",
|
|
3050
3057
|
value: function configure(options) {
|
|
3051
|
-
this.options =
|
|
3058
|
+
this.options = $.extend(true, this.options, options);
|
|
3052
3059
|
}
|
|
3053
3060
|
}, {
|
|
3054
3061
|
key: "create",
|
|
@@ -3060,14 +3067,13 @@
|
|
|
3060
3067
|
key: "garbage",
|
|
3061
3068
|
value: function garbage(el) {
|
|
3062
3069
|
if (!this.options.recycleVideo || el.tagName.toUpperCase() !== 'VIDEO') return;
|
|
3063
|
-
|
|
3070
|
+
$(el).children().remove();
|
|
3064
3071
|
Object.values(el.attributes).forEach(function (attr) {
|
|
3065
3072
|
return el.removeAttribute(attr.name);
|
|
3066
3073
|
});
|
|
3067
3074
|
videoStack.push(el);
|
|
3068
3075
|
}
|
|
3069
3076
|
}]);
|
|
3070
|
-
return DomRecycler;
|
|
3071
3077
|
}();
|
|
3072
3078
|
DomRecycler.options = {
|
|
3073
3079
|
recycleVideo: false
|
|
@@ -3079,7 +3085,7 @@
|
|
|
3079
3085
|
this.delay = delay;
|
|
3080
3086
|
this.lastTime = 0;
|
|
3081
3087
|
}
|
|
3082
|
-
_createClass$1(DoubleEventHandler, [{
|
|
3088
|
+
return _createClass$1(DoubleEventHandler, [{
|
|
3083
3089
|
key: "handle",
|
|
3084
3090
|
value: function handle(event, cb) {
|
|
3085
3091
|
var prevented = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
|
|
@@ -3093,7 +3099,6 @@
|
|
|
3093
3099
|
this.lastTime = currentTime;
|
|
3094
3100
|
}
|
|
3095
3101
|
}]);
|
|
3096
|
-
return DoubleEventHandler;
|
|
3097
3102
|
}();
|
|
3098
3103
|
var Utils = {
|
|
3099
3104
|
Config: Config$1,
|
|
@@ -3143,7 +3148,7 @@
|
|
|
3143
3148
|
this.previousLevel = this.level;
|
|
3144
3149
|
this.offLevel = offLevel;
|
|
3145
3150
|
}
|
|
3146
|
-
_createClass$1(Log, [{
|
|
3151
|
+
return _createClass$1(Log, [{
|
|
3147
3152
|
key: "level",
|
|
3148
3153
|
get: function get() {
|
|
3149
3154
|
return this._level;
|
|
@@ -3198,7 +3203,6 @@
|
|
|
3198
3203
|
window.console && window.console.log && window.console.log.apply(console, ['%c[' + DESCRIPTIONS[level] + ']' + klassDescription, color].concat(message));
|
|
3199
3204
|
}
|
|
3200
3205
|
}]);
|
|
3201
|
-
return Log;
|
|
3202
3206
|
}();
|
|
3203
3207
|
Log.LEVEL_DEBUG = LEVEL_DEBUG;
|
|
3204
3208
|
Log.LEVEL_INFO = LEVEL_INFO;
|
|
@@ -3223,7 +3227,6 @@
|
|
|
3223
3227
|
Log.error = function () {
|
|
3224
3228
|
this.getInstance().error.apply(this.getInstance(), arguments);
|
|
3225
3229
|
};
|
|
3226
|
-
|
|
3227
3230
|
var slice = Array.prototype.slice;
|
|
3228
3231
|
var eventSplitter = /\s+/;
|
|
3229
3232
|
var eventsApi = function eventsApi(obj, action, name, rest) {
|
|
@@ -3231,18 +3234,14 @@
|
|
|
3231
3234
|
|
|
3232
3235
|
// Handle event maps.
|
|
3233
3236
|
if (_typeof(name) === 'object') {
|
|
3234
|
-
for (var key in name)
|
|
3235
|
-
obj[action].apply(obj, [key, name[key]].concat(rest));
|
|
3236
|
-
}
|
|
3237
|
+
for (var key in name) obj[action].apply(obj, [key, name[key]].concat(rest));
|
|
3237
3238
|
return false;
|
|
3238
3239
|
}
|
|
3239
3240
|
|
|
3240
3241
|
// Handle space separated event names.
|
|
3241
3242
|
if (eventSplitter.test(name)) {
|
|
3242
3243
|
var names = name.split(eventSplitter);
|
|
3243
|
-
for (var i = 0, l = names.length; i < l; i++)
|
|
3244
|
-
obj[action].apply(obj, [names[i]].concat(rest));
|
|
3245
|
-
}
|
|
3244
|
+
for (var i = 0, l = names.length; i < l; i++) obj[action].apply(obj, [names[i]].concat(rest));
|
|
3246
3245
|
return false;
|
|
3247
3246
|
}
|
|
3248
3247
|
return true;
|
|
@@ -3301,7 +3300,7 @@
|
|
|
3301
3300
|
function Events() {
|
|
3302
3301
|
_classCallCheck$1(this, Events);
|
|
3303
3302
|
}
|
|
3304
|
-
_createClass$1(Events, [{
|
|
3303
|
+
return _createClass$1(Events, [{
|
|
3305
3304
|
key: "on",
|
|
3306
3305
|
value:
|
|
3307
3306
|
/**
|
|
@@ -3343,6 +3342,7 @@
|
|
|
3343
3342
|
off();
|
|
3344
3343
|
callback.apply(this, arguments);
|
|
3345
3344
|
};
|
|
3345
|
+
_once._callback = callback;
|
|
3346
3346
|
return this.on(name, _once, context);
|
|
3347
3347
|
}
|
|
3348
3348
|
|
|
@@ -3443,22 +3443,36 @@
|
|
|
3443
3443
|
});
|
|
3444
3444
|
}
|
|
3445
3445
|
}]);
|
|
3446
|
-
return Events;
|
|
3447
3446
|
}();
|
|
3448
|
-
|
|
3449
|
-
|
|
3450
|
-
|
|
3447
|
+
Events.prototype.listenTo = function (obj, name, callback) {
|
|
3448
|
+
var listeningTo = this._listeningTo || (this._listeningTo = {});
|
|
3449
|
+
var id = obj._listenId || (obj._listenId = uniqueId('l'));
|
|
3450
|
+
listeningTo[id] = obj;
|
|
3451
|
+
if (!callback && _typeof(name) === 'object') callback = this;
|
|
3452
|
+
obj.on(name, callback, this);
|
|
3453
|
+
return this;
|
|
3454
|
+
};
|
|
3455
|
+
|
|
3456
|
+
/**
|
|
3457
|
+
* listen to an event once for a given `obj`
|
|
3458
|
+
* @method listenToOnce
|
|
3459
|
+
* @param {Object} obj
|
|
3460
|
+
* @param {String} name
|
|
3461
|
+
* @param {Function} callback
|
|
3462
|
+
* @param {Object} context
|
|
3463
|
+
* @example
|
|
3464
|
+
* ```javascript
|
|
3465
|
+
* this.listenToOnce(this.core.playback, Events.PLAYBACK_PAUSE, this.callback)
|
|
3466
|
+
* ```
|
|
3467
|
+
*/
|
|
3468
|
+
Events.prototype.listenToOnce = function (obj, name, callback) {
|
|
3469
|
+
var listeningTo = this._listeningTo || (this._listeningTo = {});
|
|
3470
|
+
var id = obj._listenId || (obj._listenId = uniqueId('l'));
|
|
3471
|
+
listeningTo[id] = obj;
|
|
3472
|
+
if (!callback && _typeof(name) === 'object') callback = this;
|
|
3473
|
+
obj.once(name, callback, this);
|
|
3474
|
+
return this;
|
|
3451
3475
|
};
|
|
3452
|
-
Object.keys(listenMethods).forEach(function (method) {
|
|
3453
|
-
Events.prototype[method] = function (obj, name, callback) {
|
|
3454
|
-
var listeningTo = this._listeningTo || (this._listeningTo = {});
|
|
3455
|
-
var id = obj._listenId || (obj._listenId = uniqueId('l'));
|
|
3456
|
-
listeningTo[id] = obj;
|
|
3457
|
-
if (!callback && _typeof(name) === 'object') callback = this;
|
|
3458
|
-
obj[listenMethods[method]](name, callback, this);
|
|
3459
|
-
return this;
|
|
3460
|
-
};
|
|
3461
|
-
});
|
|
3462
3476
|
|
|
3463
3477
|
// PLAYER EVENTS
|
|
3464
3478
|
/**
|
|
@@ -3567,6 +3581,16 @@
|
|
|
3567
3581
|
Events.PLAYER_SUBTITLE_AVAILABLE = 'subtitleavailable';
|
|
3568
3582
|
|
|
3569
3583
|
// Playback Events
|
|
3584
|
+
/** Fired when picture-in-picture mode is entered
|
|
3585
|
+
*
|
|
3586
|
+
* @event PLAYBACK_PIP_ENTER
|
|
3587
|
+
*/
|
|
3588
|
+
Events.PLAYBACK_PIP_ENTER = 'playback:picture-in-picture:enter';
|
|
3589
|
+
/** Fired when picture-in-picture mode is exited
|
|
3590
|
+
*
|
|
3591
|
+
* @event PLAYBACK_PIP_EXIT
|
|
3592
|
+
*/
|
|
3593
|
+
Events.PLAYBACK_PIP_EXIT = 'playback:picture-in-picture:exit';
|
|
3570
3594
|
/**
|
|
3571
3595
|
* Fired when the playback is downloading the media
|
|
3572
3596
|
*
|
|
@@ -3998,6 +4022,17 @@
|
|
|
3998
4022
|
Events.CONTAINER_MOUSE_UP = 'container:mouseup';
|
|
3999
4023
|
Events.CONTAINER_MOUSE_DOWN = 'container:mousedown';
|
|
4000
4024
|
|
|
4025
|
+
/**
|
|
4026
|
+
* Fired when the container enters on Picture-in-Picture mode
|
|
4027
|
+
* @event CONTAINER_PIP_ENTER
|
|
4028
|
+
*/
|
|
4029
|
+
Events.CONTAINER_PIP_ENTER = 'container:picture-in-picture:enter';
|
|
4030
|
+
/**
|
|
4031
|
+
* Fired when the container exits from Picture-in-Picture mode
|
|
4032
|
+
* @event CONTAINER_PIP_EXIT
|
|
4033
|
+
*/
|
|
4034
|
+
Events.CONTAINER_PIP_EXIT = 'container:picture-in-picture:exit';
|
|
4035
|
+
|
|
4001
4036
|
/**
|
|
4002
4037
|
* Fired when the container seeks the video
|
|
4003
4038
|
*
|
|
@@ -4131,8 +4166,6 @@
|
|
|
4131
4166
|
* @module base
|
|
4132
4167
|
*/
|
|
4133
4168
|
var BaseObject = /*#__PURE__*/function (_Events) {
|
|
4134
|
-
_inherits$1(BaseObject, _Events);
|
|
4135
|
-
var _super = _createSuper$1(BaseObject);
|
|
4136
4169
|
/**
|
|
4137
4170
|
* @method constructor
|
|
4138
4171
|
* @param {Object} options
|
|
@@ -4141,7 +4174,7 @@
|
|
|
4141
4174
|
var _this;
|
|
4142
4175
|
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
4143
4176
|
_classCallCheck$1(this, BaseObject);
|
|
4144
|
-
_this =
|
|
4177
|
+
_this = _callSuper$1(this, BaseObject, [options]);
|
|
4145
4178
|
_this._options = options;
|
|
4146
4179
|
_this.uniqueId = uniqueId('o');
|
|
4147
4180
|
return _this;
|
|
@@ -4152,7 +4185,8 @@
|
|
|
4152
4185
|
* @property uniqueId
|
|
4153
4186
|
* @type String
|
|
4154
4187
|
*/
|
|
4155
|
-
|
|
4188
|
+
_inherits$1(BaseObject, _Events);
|
|
4189
|
+
return _createClass$1(BaseObject, [{
|
|
4156
4190
|
key: "options",
|
|
4157
4191
|
get:
|
|
4158
4192
|
/**
|
|
@@ -4164,7 +4198,6 @@
|
|
|
4164
4198
|
return this._options;
|
|
4165
4199
|
}
|
|
4166
4200
|
}]);
|
|
4167
|
-
return BaseObject;
|
|
4168
4201
|
}(Events);
|
|
4169
4202
|
|
|
4170
4203
|
/* eslint-disable no-var */
|
|
@@ -4216,9 +4249,14 @@
|
|
|
4216
4249
|
};
|
|
4217
4250
|
var counter = 0;
|
|
4218
4251
|
|
|
4219
|
-
|
|
4220
|
-
|
|
4221
|
-
|
|
4252
|
+
/**
|
|
4253
|
+
* JavaScript micro-templating, similar to John Resig's implementation.
|
|
4254
|
+
* Underscore templating handles arbitrary delimiters, preserves whitespace,
|
|
4255
|
+
* and correctly escapes quotes within interpolated code.
|
|
4256
|
+
* @param {string} text
|
|
4257
|
+
* @param {*=} data
|
|
4258
|
+
* @returns
|
|
4259
|
+
*/
|
|
4222
4260
|
var tmpl = function tmpl(text, data) {
|
|
4223
4261
|
var render;
|
|
4224
4262
|
|
|
@@ -4263,15 +4301,17 @@
|
|
|
4263
4301
|
tmpl.settings = settings;
|
|
4264
4302
|
|
|
4265
4303
|
// Copyright 2014 Globo.com Player authors. All rights reserved.
|
|
4304
|
+
// Use of this source code is governed by a BSD-style
|
|
4305
|
+
// license that can be found in the LICENSE file.
|
|
4306
|
+
|
|
4266
4307
|
var Styler = {
|
|
4267
4308
|
getStyleFor: function getStyleFor(style) {
|
|
4268
4309
|
var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {
|
|
4269
4310
|
baseUrl: ''
|
|
4270
4311
|
};
|
|
4271
|
-
return
|
|
4312
|
+
return $('<style class="clappr-style"></style>').html(tmpl(style.toString())(options));
|
|
4272
4313
|
}
|
|
4273
4314
|
};
|
|
4274
|
-
|
|
4275
4315
|
var delegateEventSplitter = /^(\S+)\s*(.*)$/;
|
|
4276
4316
|
|
|
4277
4317
|
/**
|
|
@@ -4282,8 +4322,6 @@
|
|
|
4282
4322
|
* @module base
|
|
4283
4323
|
*/
|
|
4284
4324
|
var UIObject = /*#__PURE__*/function (_BaseObject) {
|
|
4285
|
-
_inherits$1(UIObject, _BaseObject);
|
|
4286
|
-
var _super = _createSuper$1(UIObject);
|
|
4287
4325
|
/**
|
|
4288
4326
|
* it builds an ui component by:
|
|
4289
4327
|
* * creating an id for the component `cid`
|
|
@@ -4295,7 +4333,13 @@
|
|
|
4295
4333
|
function UIObject(options) {
|
|
4296
4334
|
var _this;
|
|
4297
4335
|
_classCallCheck$1(this, UIObject);
|
|
4298
|
-
_this =
|
|
4336
|
+
_this = _callSuper$1(this, UIObject, [options]);
|
|
4337
|
+
/**
|
|
4338
|
+
* a unique id prefixed with `'c'`, `c1, c232`
|
|
4339
|
+
*
|
|
4340
|
+
* @property cid
|
|
4341
|
+
* @type String
|
|
4342
|
+
*/
|
|
4299
4343
|
_this.cid = uniqueId('c');
|
|
4300
4344
|
_this._ensureElement();
|
|
4301
4345
|
_this.delegateEvents();
|
|
@@ -4311,29 +4355,11 @@
|
|
|
4311
4355
|
* ```javascript
|
|
4312
4356
|
* fullScreenBarUIComponent.$('.button-full') //will return only `.button-full` within the component
|
|
4313
4357
|
* ```
|
|
4314
|
-
*/
|
|
4315
|
-
|
|
4316
|
-
|
|
4317
|
-
|
|
4318
|
-
|
|
4319
|
-
* a unique id prefixed with `'c'`, `c1, c232`
|
|
4320
|
-
*
|
|
4321
|
-
* @property cid
|
|
4322
|
-
* @type String
|
|
4323
|
-
*/
|
|
4324
|
-
/**
|
|
4325
|
-
* the dom element itself
|
|
4326
|
-
*
|
|
4327
|
-
* @property el
|
|
4328
|
-
* @type HTMLElement
|
|
4329
|
-
*/
|
|
4330
|
-
/**
|
|
4331
|
-
* the dom element wrapped by `$`
|
|
4332
|
-
*
|
|
4333
|
-
* @property $el
|
|
4334
|
-
* @type HTMLElement
|
|
4335
|
-
*/
|
|
4336
|
-
|
|
4358
|
+
*/
|
|
4359
|
+
_inherits$1(UIObject, _BaseObject);
|
|
4360
|
+
return _createClass$1(UIObject, [{
|
|
4361
|
+
key: "tagName",
|
|
4362
|
+
get:
|
|
4337
4363
|
/**
|
|
4338
4364
|
* gets the tag name for the ui component
|
|
4339
4365
|
* @method tagName
|
|
@@ -4432,7 +4458,19 @@
|
|
|
4432
4458
|
key: "setElement",
|
|
4433
4459
|
value: function setElement(element, delegate) {
|
|
4434
4460
|
if (this.$el) this.undelegateEvents();
|
|
4435
|
-
|
|
4461
|
+
/**
|
|
4462
|
+
* the dom element wrapped by `$`
|
|
4463
|
+
*
|
|
4464
|
+
* @property $el
|
|
4465
|
+
* @type import("clappr-zepto").ZeptoCollection
|
|
4466
|
+
*/
|
|
4467
|
+
this.$el = $.zepto.isZ(element) ? element : $(element);
|
|
4468
|
+
/**
|
|
4469
|
+
* the dom element itself
|
|
4470
|
+
*
|
|
4471
|
+
* @property el
|
|
4472
|
+
* @type HTMLElement
|
|
4473
|
+
*/
|
|
4436
4474
|
this.el = this.$el[0];
|
|
4437
4475
|
if (delegate !== false) this.delegateEvents();
|
|
4438
4476
|
return this;
|
|
@@ -4483,17 +4521,16 @@
|
|
|
4483
4521
|
key: "_ensureElement",
|
|
4484
4522
|
value: function _ensureElement() {
|
|
4485
4523
|
if (!this.el) {
|
|
4486
|
-
var attrs =
|
|
4524
|
+
var attrs = $.extend(true, {}, this.attributes);
|
|
4487
4525
|
if (this.id) attrs.id = this.id;
|
|
4488
4526
|
if (this.className) attrs['class'] = this.className;
|
|
4489
|
-
var $el =
|
|
4527
|
+
var $el = $(DomRecycler.create(this.tagName)).attr(attrs);
|
|
4490
4528
|
this.setElement($el, false);
|
|
4491
4529
|
} else {
|
|
4492
4530
|
this.setElement(this.el, false);
|
|
4493
4531
|
}
|
|
4494
4532
|
}
|
|
4495
4533
|
}]);
|
|
4496
|
-
return UIObject;
|
|
4497
4534
|
}(BaseObject);
|
|
4498
4535
|
|
|
4499
4536
|
/**
|
|
@@ -4504,14 +4541,12 @@
|
|
|
4504
4541
|
* @module components
|
|
4505
4542
|
*/
|
|
4506
4543
|
var PlayerError = /*#__PURE__*/function (_BaseObject) {
|
|
4507
|
-
_inherits$1(PlayerError, _BaseObject);
|
|
4508
|
-
var _super = _createSuper$1(PlayerError);
|
|
4509
4544
|
function PlayerError() {
|
|
4510
4545
|
var _this;
|
|
4511
4546
|
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
4512
4547
|
var core = arguments.length > 1 ? arguments[1] : undefined;
|
|
4513
4548
|
_classCallCheck$1(this, PlayerError);
|
|
4514
|
-
_this =
|
|
4549
|
+
_this = _callSuper$1(this, PlayerError, [options]);
|
|
4515
4550
|
_this.core = core;
|
|
4516
4551
|
return _this;
|
|
4517
4552
|
}
|
|
@@ -4521,7 +4556,8 @@
|
|
|
4521
4556
|
* @method createError
|
|
4522
4557
|
* @param {Object} err should be an object with code, description, level, origin, scope and raw error.
|
|
4523
4558
|
*/
|
|
4524
|
-
|
|
4559
|
+
_inherits$1(PlayerError, _BaseObject);
|
|
4560
|
+
return _createClass$1(PlayerError, [{
|
|
4525
4561
|
key: "name",
|
|
4526
4562
|
get: function get() {
|
|
4527
4563
|
return 'error';
|
|
@@ -4550,9 +4586,7 @@
|
|
|
4550
4586
|
};
|
|
4551
4587
|
}
|
|
4552
4588
|
}]);
|
|
4553
|
-
return PlayerError;
|
|
4554
4589
|
}(BaseObject);
|
|
4555
|
-
|
|
4556
4590
|
var ErrorMixin = {
|
|
4557
4591
|
/**
|
|
4558
4592
|
* creates an error.
|
|
@@ -4589,21 +4623,19 @@
|
|
|
4589
4623
|
return errorData;
|
|
4590
4624
|
}
|
|
4591
4625
|
};
|
|
4592
|
-
|
|
4593
4626
|
var UICorePlugin = /*#__PURE__*/function (_UIObject) {
|
|
4594
|
-
_inherits$1(UICorePlugin, _UIObject);
|
|
4595
|
-
var _super = _createSuper$1(UICorePlugin);
|
|
4596
4627
|
function UICorePlugin(core) {
|
|
4597
4628
|
var _this;
|
|
4598
4629
|
_classCallCheck$1(this, UICorePlugin);
|
|
4599
|
-
_this =
|
|
4630
|
+
_this = _callSuper$1(this, UICorePlugin, [core.options]);
|
|
4600
4631
|
_this.core = core;
|
|
4601
4632
|
_this.enabled = true;
|
|
4602
4633
|
_this.bindEvents();
|
|
4603
4634
|
_this.render();
|
|
4604
4635
|
return _this;
|
|
4605
4636
|
}
|
|
4606
|
-
|
|
4637
|
+
_inherits$1(UICorePlugin, _UIObject);
|
|
4638
|
+
return _createClass$1(UICorePlugin, [{
|
|
4607
4639
|
key: "playerError",
|
|
4608
4640
|
get: function get() {
|
|
4609
4641
|
return this.core.playerError;
|
|
@@ -4638,14 +4670,12 @@
|
|
|
4638
4670
|
return this;
|
|
4639
4671
|
}
|
|
4640
4672
|
}]);
|
|
4641
|
-
return UICorePlugin;
|
|
4642
4673
|
}(UIObject);
|
|
4643
4674
|
Object.assign(UICorePlugin.prototype, ErrorMixin);
|
|
4644
4675
|
UICorePlugin.extend = function (properties) {
|
|
4645
4676
|
return extend$1(UICorePlugin, properties);
|
|
4646
4677
|
};
|
|
4647
4678
|
UICorePlugin.type = 'core';
|
|
4648
|
-
|
|
4649
4679
|
var css_248z$5$1 = ".container[data-container] {\n position: absolute;\n background-color: black;\n height: 100%;\n width: 100%;\n max-width: 100%; }\n .container[data-container] .chromeless {\n cursor: default; }\n\n[data-player]:not(.nocursor) .container[data-container]:not(.chromeless).pointer-enabled {\n cursor: pointer; }\n";
|
|
4650
4680
|
|
|
4651
4681
|
/**
|
|
@@ -4657,8 +4687,6 @@
|
|
|
4657
4687
|
* @module base
|
|
4658
4688
|
*/
|
|
4659
4689
|
var Container = /*#__PURE__*/function (_UIObject) {
|
|
4660
|
-
_inherits$1(Container, _UIObject);
|
|
4661
|
-
var _super = _createSuper$1(Container);
|
|
4662
4690
|
/**
|
|
4663
4691
|
* it builds a container
|
|
4664
4692
|
* @method constructor
|
|
@@ -4668,13 +4696,13 @@
|
|
|
4668
4696
|
function Container(options, i18n, playerError) {
|
|
4669
4697
|
var _this;
|
|
4670
4698
|
_classCallCheck$1(this, Container);
|
|
4671
|
-
_this =
|
|
4699
|
+
_this = _callSuper$1(this, Container, [options]);
|
|
4672
4700
|
_this._i18n = i18n;
|
|
4673
4701
|
_this.currentTime = 0;
|
|
4674
4702
|
_this.volume = 100;
|
|
4675
4703
|
_this.playback = options.playback;
|
|
4676
4704
|
_this.playerError = playerError;
|
|
4677
|
-
_this.settings =
|
|
4705
|
+
_this.settings = $.extend(true, {}, _this.playback.settings);
|
|
4678
4706
|
_this.isReady = false;
|
|
4679
4707
|
_this.mediaControlDisabled = false;
|
|
4680
4708
|
_this.plugins = [_this.playback];
|
|
@@ -4709,12 +4737,15 @@
|
|
|
4709
4737
|
* | play |
|
|
4710
4738
|
* | pause |
|
|
4711
4739
|
* | error |
|
|
4740
|
+
* | pip_enter |
|
|
4741
|
+
* | pip_exit |
|
|
4712
4742
|
*
|
|
4713
4743
|
* ps: the events usually translate from PLABACK_x to CONTAINER_x, you can check all the events at `Event` class.
|
|
4714
4744
|
*
|
|
4715
4745
|
* @method bindEvents
|
|
4716
4746
|
*/
|
|
4717
|
-
|
|
4747
|
+
_inherits$1(Container, _UIObject);
|
|
4748
|
+
return _createClass$1(Container, [{
|
|
4718
4749
|
key: "name",
|
|
4719
4750
|
get:
|
|
4720
4751
|
/**
|
|
@@ -4845,6 +4876,16 @@
|
|
|
4845
4876
|
get: function get() {
|
|
4846
4877
|
return this.playback.currentAudioTrack;
|
|
4847
4878
|
}
|
|
4879
|
+
|
|
4880
|
+
/**
|
|
4881
|
+
* returns the picture-in-picture state.
|
|
4882
|
+
* @type {Boolean}
|
|
4883
|
+
*/
|
|
4884
|
+
}, {
|
|
4885
|
+
key: "isPiPActive",
|
|
4886
|
+
get: function get() {
|
|
4887
|
+
return this.playback.isPiPActive;
|
|
4888
|
+
}
|
|
4848
4889
|
}, {
|
|
4849
4890
|
key: "bindEvents",
|
|
4850
4891
|
value: function bindEvents() {
|
|
@@ -4872,6 +4913,8 @@
|
|
|
4872
4913
|
this.listenTo(this.playback, Events.PLAYBACK_SUBTITLE_CHANGED, this.subtitleChanged);
|
|
4873
4914
|
this.listenTo(this.playback, Events.PLAYBACK_AUDIO_AVAILABLE, this.audioAvailable);
|
|
4874
4915
|
this.listenTo(this.playback, Events.PLAYBACK_AUDIO_CHANGED, this.audioChanged);
|
|
4916
|
+
this.listenTo(this.playback, Events.PLAYBACK_PIP_ENTER, this.onEnterPiP);
|
|
4917
|
+
this.listenTo(this.playback, Events.PLAYBACK_PIP_EXIT, this.onExitPiP);
|
|
4875
4918
|
}
|
|
4876
4919
|
}, {
|
|
4877
4920
|
key: "subtitleAvailable",
|
|
@@ -4957,6 +5000,7 @@
|
|
|
4957
5000
|
return plugin.destroy();
|
|
4958
5001
|
});
|
|
4959
5002
|
this.$el.remove();
|
|
5003
|
+
this.undelegateEvents();
|
|
4960
5004
|
}
|
|
4961
5005
|
}, {
|
|
4962
5006
|
key: "setStyle",
|
|
@@ -5176,6 +5220,16 @@
|
|
|
5176
5220
|
value: function bufferfull() {
|
|
5177
5221
|
this.trigger(Events.CONTAINER_STATE_BUFFERFULL, this.name);
|
|
5178
5222
|
}
|
|
5223
|
+
}, {
|
|
5224
|
+
key: "onEnterPiP",
|
|
5225
|
+
value: function onEnterPiP() {
|
|
5226
|
+
this.trigger(Events.CONTAINER_PIP_ENTER, this.name);
|
|
5227
|
+
}
|
|
5228
|
+
}, {
|
|
5229
|
+
key: "onExitPiP",
|
|
5230
|
+
value: function onExitPiP() {
|
|
5231
|
+
this.trigger(Events.CONTAINER_PIP_EXIT, this.name);
|
|
5232
|
+
}
|
|
5179
5233
|
|
|
5180
5234
|
/**
|
|
5181
5235
|
* adds plugin to the container
|
|
@@ -5232,6 +5286,16 @@
|
|
|
5232
5286
|
value: function mouseDown() {
|
|
5233
5287
|
if (!this.options.chromeless || this.options.allowUserInteraction) this.trigger(Events.CONTAINER_MOUSE_DOWN);
|
|
5234
5288
|
}
|
|
5289
|
+
}, {
|
|
5290
|
+
key: "enterPiP",
|
|
5291
|
+
value: function enterPiP() {
|
|
5292
|
+
this.playback.enterPiP();
|
|
5293
|
+
}
|
|
5294
|
+
}, {
|
|
5295
|
+
key: "exitPiP",
|
|
5296
|
+
value: function exitPiP() {
|
|
5297
|
+
this.playback.exitPiP();
|
|
5298
|
+
}
|
|
5235
5299
|
}, {
|
|
5236
5300
|
key: "settingsUpdate",
|
|
5237
5301
|
value: function settingsUpdate() {
|
|
@@ -5308,7 +5372,7 @@
|
|
|
5308
5372
|
}, {
|
|
5309
5373
|
key: "configure",
|
|
5310
5374
|
value: function configure(options) {
|
|
5311
|
-
this._options =
|
|
5375
|
+
this._options = $.extend(true, this._options, options);
|
|
5312
5376
|
this.updateStyle();
|
|
5313
5377
|
this.playback.configure(this.options);
|
|
5314
5378
|
this.trigger(Events.CONTAINER_OPTIONS_CHANGE);
|
|
@@ -5327,7 +5391,6 @@
|
|
|
5327
5391
|
return this;
|
|
5328
5392
|
}
|
|
5329
5393
|
}]);
|
|
5330
|
-
return Container;
|
|
5331
5394
|
}(UIObject);
|
|
5332
5395
|
Object.assign(Container.prototype, ErrorMixin);
|
|
5333
5396
|
|
|
@@ -5349,8 +5412,6 @@
|
|
|
5349
5412
|
* @module base
|
|
5350
5413
|
*/
|
|
5351
5414
|
var Playback = /*#__PURE__*/function (_UIObject) {
|
|
5352
|
-
_inherits$1(Playback, _UIObject);
|
|
5353
|
-
var _super = _createSuper$1(Playback);
|
|
5354
5415
|
/**
|
|
5355
5416
|
* @method constructor
|
|
5356
5417
|
* @param {Object} options the options object
|
|
@@ -5359,7 +5420,7 @@
|
|
|
5359
5420
|
function Playback(options, i18n, playerError) {
|
|
5360
5421
|
var _this;
|
|
5361
5422
|
_classCallCheck$1(this, Playback);
|
|
5362
|
-
_this =
|
|
5423
|
+
_this = _callSuper$1(this, Playback, [options]);
|
|
5363
5424
|
_this.settings = {};
|
|
5364
5425
|
_this._i18n = i18n;
|
|
5365
5426
|
_this.playerError = playerError;
|
|
@@ -5372,7 +5433,8 @@
|
|
|
5372
5433
|
* @method consent
|
|
5373
5434
|
* @param {Function} callback function called when playback is consented
|
|
5374
5435
|
*/
|
|
5375
|
-
|
|
5436
|
+
_inherits$1(Playback, _UIObject);
|
|
5437
|
+
return _createClass$1(Playback, [{
|
|
5376
5438
|
key: "isAudioOnly",
|
|
5377
5439
|
get:
|
|
5378
5440
|
/**
|
|
@@ -5423,6 +5485,41 @@
|
|
|
5423
5485
|
get: function get() {
|
|
5424
5486
|
return false;
|
|
5425
5487
|
}
|
|
5488
|
+
|
|
5489
|
+
/**
|
|
5490
|
+
* The estimated time (in seconds) of a video's live edge plus time sync playlist advanced.
|
|
5491
|
+
* (i.e if first playlist hasn't been loaded, will return 0)
|
|
5492
|
+
* @property latency
|
|
5493
|
+
* @type {Number}
|
|
5494
|
+
*/
|
|
5495
|
+
}, {
|
|
5496
|
+
key: "latency",
|
|
5497
|
+
get: function get() {
|
|
5498
|
+
return null;
|
|
5499
|
+
}
|
|
5500
|
+
|
|
5501
|
+
/**
|
|
5502
|
+
* The datetime value relative for a video's active level Program Date Time, if present.
|
|
5503
|
+
* (i.e if first playlist hasn't been loaded, will return null)
|
|
5504
|
+
* @property currentProgramDateTime
|
|
5505
|
+
* @return {Date}
|
|
5506
|
+
*/
|
|
5507
|
+
}, {
|
|
5508
|
+
key: "currentProgramDateTime",
|
|
5509
|
+
get: function get() {
|
|
5510
|
+
return null;
|
|
5511
|
+
}
|
|
5512
|
+
|
|
5513
|
+
/**
|
|
5514
|
+
* checks if picture in picture mode is active.
|
|
5515
|
+
* @property isPiPActive
|
|
5516
|
+
* @type {Boolean} `true` if the current playback is in picture in picture mode, otherwise `false`
|
|
5517
|
+
*/
|
|
5518
|
+
}, {
|
|
5519
|
+
key: "isPiPActive",
|
|
5520
|
+
get: function get() {
|
|
5521
|
+
return false;
|
|
5522
|
+
}
|
|
5426
5523
|
}, {
|
|
5427
5524
|
key: "consent",
|
|
5428
5525
|
value: function consent(cb) {
|
|
@@ -5453,6 +5550,22 @@
|
|
|
5453
5550
|
key: "stop",
|
|
5454
5551
|
value: function stop() {}
|
|
5455
5552
|
|
|
5553
|
+
/**
|
|
5554
|
+
* enter in picture in picture mode
|
|
5555
|
+
* @method enterPiP
|
|
5556
|
+
*/
|
|
5557
|
+
}, {
|
|
5558
|
+
key: "enterPiP",
|
|
5559
|
+
value: function enterPiP() {}
|
|
5560
|
+
|
|
5561
|
+
/**
|
|
5562
|
+
* exit from picture in picture mode
|
|
5563
|
+
* @method exitPiP
|
|
5564
|
+
*/
|
|
5565
|
+
}, {
|
|
5566
|
+
key: "exitPiP",
|
|
5567
|
+
value: function exitPiP() {}
|
|
5568
|
+
|
|
5456
5569
|
/**
|
|
5457
5570
|
* seeks the playback to a given `time` in seconds
|
|
5458
5571
|
* @method seek
|
|
@@ -5647,7 +5760,7 @@
|
|
|
5647
5760
|
}, {
|
|
5648
5761
|
key: "configure",
|
|
5649
5762
|
value: function configure(options) {
|
|
5650
|
-
this._options =
|
|
5763
|
+
this._options = $.extend(true, this._options, options);
|
|
5651
5764
|
}
|
|
5652
5765
|
|
|
5653
5766
|
/**
|
|
@@ -5675,7 +5788,6 @@
|
|
|
5675
5788
|
cb(true, null); // Assume playback can autoplay by default
|
|
5676
5789
|
}
|
|
5677
5790
|
}]);
|
|
5678
|
-
return Playback;
|
|
5679
5791
|
}(UIObject);
|
|
5680
5792
|
Object.assign(Playback.prototype, ErrorMixin);
|
|
5681
5793
|
Playback.extend = function (properties) {
|
|
@@ -5737,20 +5849,18 @@
|
|
|
5737
5849
|
* @type String
|
|
5738
5850
|
*/
|
|
5739
5851
|
Playback.type = 'playback';
|
|
5740
|
-
|
|
5741
5852
|
var ContainerFactory = /*#__PURE__*/function (_BaseObject) {
|
|
5742
|
-
_inherits$1(ContainerFactory, _BaseObject);
|
|
5743
|
-
var _super = _createSuper$1(ContainerFactory);
|
|
5744
5853
|
function ContainerFactory(options, loader, i18n, playerError) {
|
|
5745
5854
|
var _this;
|
|
5746
5855
|
_classCallCheck$1(this, ContainerFactory);
|
|
5747
|
-
_this =
|
|
5856
|
+
_this = _callSuper$1(this, ContainerFactory, [options]);
|
|
5748
5857
|
_this._i18n = i18n;
|
|
5749
5858
|
_this.loader = loader;
|
|
5750
5859
|
_this.playerError = playerError;
|
|
5751
5860
|
return _this;
|
|
5752
5861
|
}
|
|
5753
|
-
|
|
5862
|
+
_inherits$1(ContainerFactory, _BaseObject);
|
|
5863
|
+
return _createClass$1(ContainerFactory, [{
|
|
5754
5864
|
key: "options",
|
|
5755
5865
|
get: function get() {
|
|
5756
5866
|
return this._options;
|
|
@@ -5762,7 +5872,7 @@
|
|
|
5762
5872
|
key: "createContainers",
|
|
5763
5873
|
value: function createContainers() {
|
|
5764
5874
|
var _this2 = this;
|
|
5765
|
-
return
|
|
5875
|
+
return $.Deferred(function (promise) {
|
|
5766
5876
|
promise.resolve(_this2.options.sources.map(function (source) {
|
|
5767
5877
|
return _this2.createContainer(source);
|
|
5768
5878
|
}));
|
|
@@ -5799,7 +5909,7 @@
|
|
|
5799
5909
|
playback: playback
|
|
5800
5910
|
});
|
|
5801
5911
|
var container = new Container(options, this._i18n, this.playerError);
|
|
5802
|
-
var defer =
|
|
5912
|
+
var defer = $.Deferred();
|
|
5803
5913
|
defer.promise(container);
|
|
5804
5914
|
this.addContainerPlugins(container);
|
|
5805
5915
|
this.listenToOnce(container, Events.CONTAINER_READY, function () {
|
|
@@ -5815,11 +5925,8 @@
|
|
|
5815
5925
|
});
|
|
5816
5926
|
}
|
|
5817
5927
|
}]);
|
|
5818
|
-
return ContainerFactory;
|
|
5819
5928
|
}(BaseObject);
|
|
5820
|
-
|
|
5821
5929
|
var css_248z$4$1 = "[data-player] {\n -webkit-touch-callout: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n -o-user-select: none;\n user-select: none;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n transform: translate3d(0, 0, 0);\n position: relative;\n margin: 0;\n padding: 0;\n border: 0;\n font-style: normal;\n font-weight: normal;\n text-align: center;\n overflow: hidden;\n font-size: 100%;\n font-family: \"Roboto\", \"Open Sans\", Arial, sans-serif;\n text-shadow: 0 0 0;\n box-sizing: border-box; }\n [data-player]:focus {\n outline: 0; }\n [data-player] * {\n box-sizing: inherit; }\n [data-player] > * {\n float: none;\n max-width: none; }\n [data-player] > div {\n display: block; }\n [data-player].fullscreen {\n width: 100% !important;\n height: 100% !important;\n top: 0;\n left: 0; }\n [data-player].nocursor {\n cursor: none; }\n\n.clappr-style {\n display: none !important; }\n";
|
|
5822
|
-
|
|
5823
5930
|
var css_248z$3$1 = "[data-player] div, [data-player] span, [data-player] applet, [data-player] object, [data-player] iframe,\n[data-player] h1, [data-player] h2, [data-player] h3, [data-player] h4, [data-player] h5, [data-player] h6, [data-player] p, [data-player] blockquote, [data-player] pre,\n[data-player] a, [data-player] abbr, [data-player] acronym, [data-player] address, [data-player] big, [data-player] cite, [data-player] code,\n[data-player] del, [data-player] dfn, [data-player] em, [data-player] img, [data-player] ins, [data-player] kbd, [data-player] q, [data-player] s, [data-player] samp,\n[data-player] small, [data-player] strike, [data-player] strong, [data-player] sub, [data-player] sup, [data-player] tt, [data-player] var,\n[data-player] b, [data-player] u, [data-player] i, [data-player] center,\n[data-player] dl, [data-player] dt, [data-player] dd, [data-player] ol, [data-player] ul, [data-player] li,\n[data-player] fieldset, [data-player] form, [data-player] label, [data-player] legend,\n[data-player] table, [data-player] caption, [data-player] tbody, [data-player] tfoot, [data-player] thead, [data-player] tr, [data-player] th, [data-player] td,\n[data-player] article, [data-player] aside, [data-player] canvas, [data-player] details, [data-player] embed,\n[data-player] figure, [data-player] figcaption, [data-player] footer, [data-player] header, [data-player] hgroup,\n[data-player] menu, [data-player] nav, [data-player] output, [data-player] ruby, [data-player] section, [data-player] summary,\n[data-player] time, [data-player] mark, [data-player] audio, [data-player] video {\n margin: 0;\n padding: 0;\n border: 0;\n font: inherit;\n font-size: 100%;\n vertical-align: baseline; }\n\n[data-player] table {\n border-collapse: collapse;\n border-spacing: 0; }\n\n[data-player] caption, [data-player] th, [data-player] td {\n text-align: left;\n font-weight: normal;\n vertical-align: middle; }\n\n[data-player] q, [data-player] blockquote {\n quotes: none; }\n [data-player] q:before, [data-player] q:after, [data-player] blockquote:before, [data-player] blockquote:after {\n content: \"\";\n content: none; }\n\n[data-player] a img {\n border: none; }\n";
|
|
5824
5931
|
|
|
5825
5932
|
/**
|
|
@@ -5830,30 +5937,31 @@
|
|
|
5830
5937
|
* @module components
|
|
5831
5938
|
*/
|
|
5832
5939
|
var Core = /*#__PURE__*/function (_UIObject) {
|
|
5833
|
-
_inherits$1(Core, _UIObject);
|
|
5834
|
-
var _super = _createSuper$1(Core);
|
|
5835
5940
|
function Core(options) {
|
|
5836
5941
|
var _this;
|
|
5837
5942
|
_classCallCheck$1(this, Core);
|
|
5838
|
-
_this =
|
|
5839
|
-
_this.playerError = new PlayerError(options,
|
|
5943
|
+
_this = _callSuper$1(this, Core, [options]);
|
|
5944
|
+
_this.playerError = new PlayerError(options, _this);
|
|
5840
5945
|
_this.configureDomRecycler();
|
|
5841
5946
|
_this.firstResize = true;
|
|
5947
|
+
_this.styleRendered = false;
|
|
5842
5948
|
_this.plugins = [];
|
|
5843
5949
|
_this.containers = [];
|
|
5844
5950
|
//FIXME fullscreen api sucks
|
|
5845
5951
|
_this._boundFullscreenHandler = function () {
|
|
5846
5952
|
return _this.handleFullscreenChange();
|
|
5847
5953
|
};
|
|
5848
|
-
|
|
5849
|
-
|
|
5850
|
-
|
|
5851
|
-
|
|
5852
|
-
|
|
5853
|
-
|
|
5954
|
+
_this._boundHandleWindowResize = function (o) {
|
|
5955
|
+
return _this.handleWindowResize(o);
|
|
5956
|
+
};
|
|
5957
|
+
$(document).bind('fullscreenchange', _this._boundFullscreenHandler);
|
|
5958
|
+
$(document).bind('MSFullscreenChange', _this._boundFullscreenHandler);
|
|
5959
|
+
$(document).bind('mozfullscreenchange', _this._boundFullscreenHandler);
|
|
5960
|
+
Browser.isMobile && $(window).bind('resize', _this._boundHandleWindowResize);
|
|
5854
5961
|
return _this;
|
|
5855
5962
|
}
|
|
5856
|
-
|
|
5963
|
+
_inherits$1(Core, _UIObject);
|
|
5964
|
+
return _createClass$1(Core, [{
|
|
5857
5965
|
key: "events",
|
|
5858
5966
|
get: function get() {
|
|
5859
5967
|
return {
|
|
@@ -5970,7 +6078,7 @@
|
|
|
5970
6078
|
}, {
|
|
5971
6079
|
key: "createContainers",
|
|
5972
6080
|
value: function createContainers(options) {
|
|
5973
|
-
this.defer =
|
|
6081
|
+
this.defer = $.Deferred();
|
|
5974
6082
|
this.defer.promise(this);
|
|
5975
6083
|
this.containerFactory = new ContainerFactory(options, options.loader, this.i18n, this.playerError);
|
|
5976
6084
|
this.prepareContainers();
|
|
@@ -6001,8 +6109,8 @@
|
|
|
6001
6109
|
height: this.options.height
|
|
6002
6110
|
};
|
|
6003
6111
|
this.currentSize = {
|
|
6004
|
-
width:
|
|
6005
|
-
height:
|
|
6112
|
+
width: $(window).width(),
|
|
6113
|
+
height: $(window).height()
|
|
6006
6114
|
};
|
|
6007
6115
|
}
|
|
6008
6116
|
}
|
|
@@ -6012,8 +6120,8 @@
|
|
|
6012
6120
|
this.$el.removeClass('fullscreen');
|
|
6013
6121
|
this.currentSize = this.previousSize;
|
|
6014
6122
|
this.previousSize = {
|
|
6015
|
-
width:
|
|
6016
|
-
height:
|
|
6123
|
+
width: $(window).width(),
|
|
6124
|
+
height: $(window).height()
|
|
6017
6125
|
};
|
|
6018
6126
|
this.resize(this.currentSize);
|
|
6019
6127
|
}
|
|
@@ -6071,7 +6179,7 @@
|
|
|
6071
6179
|
key: "resolveOnContainersReady",
|
|
6072
6180
|
value: function resolveOnContainersReady(containers) {
|
|
6073
6181
|
var _this4 = this;
|
|
6074
|
-
|
|
6182
|
+
$.when.apply($, containers).done(function () {
|
|
6075
6183
|
_this4.defer.resolve(_this4);
|
|
6076
6184
|
_this4.ready = true;
|
|
6077
6185
|
_this4.trigger(Events.CORE_READY);
|
|
@@ -6103,7 +6211,7 @@
|
|
|
6103
6211
|
this.containers.forEach(function (container) {
|
|
6104
6212
|
return container.destroy();
|
|
6105
6213
|
});
|
|
6106
|
-
this.containerFactory.options =
|
|
6214
|
+
this.containerFactory.options = $.extend(true, this.options, {
|
|
6107
6215
|
sources: sources
|
|
6108
6216
|
});
|
|
6109
6217
|
this.prepareContainers();
|
|
@@ -6119,10 +6227,12 @@
|
|
|
6119
6227
|
return plugin.destroy();
|
|
6120
6228
|
});
|
|
6121
6229
|
this.$el.remove();
|
|
6122
|
-
|
|
6123
|
-
|
|
6124
|
-
|
|
6230
|
+
$(document).unbind('fullscreenchange', this._boundFullscreenHandler);
|
|
6231
|
+
$(document).unbind('MSFullscreenChange', this._boundFullscreenHandler);
|
|
6232
|
+
$(document).unbind('mozfullscreenchange', this._boundFullscreenHandler);
|
|
6233
|
+
Browser.isMobile && $(window).unbind('resize', this._boundHandleWindowResize);
|
|
6125
6234
|
this.stopListening();
|
|
6235
|
+
this.undelegateEvents();
|
|
6126
6236
|
}
|
|
6127
6237
|
}, {
|
|
6128
6238
|
key: "handleFullscreenChange",
|
|
@@ -6149,6 +6259,7 @@
|
|
|
6149
6259
|
key: "removeContainer",
|
|
6150
6260
|
value: function removeContainer(container) {
|
|
6151
6261
|
this.stopListening(container);
|
|
6262
|
+
this.containerFactory.stopListening(container);
|
|
6152
6263
|
this.containers = this.containers.filter(function (c) {
|
|
6153
6264
|
return c !== container;
|
|
6154
6265
|
});
|
|
@@ -6262,7 +6373,7 @@
|
|
|
6262
6373
|
key: "configure",
|
|
6263
6374
|
value: function configure(options) {
|
|
6264
6375
|
var _this7 = this;
|
|
6265
|
-
this._options =
|
|
6376
|
+
this._options = $.extend(true, this._options, options);
|
|
6266
6377
|
this.configureDomRecycler();
|
|
6267
6378
|
var sources = options.source || options.sources;
|
|
6268
6379
|
sources && this.load(sources, options.mimeType || this.options.mimeType);
|
|
@@ -6274,20 +6385,29 @@
|
|
|
6274
6385
|
}, {
|
|
6275
6386
|
key: "appendToParent",
|
|
6276
6387
|
value: function appendToParent() {
|
|
6388
|
+
var hasCoreParent = this.$el.parent() && this.$el.parent().length;
|
|
6389
|
+
!hasCoreParent && this.$el.appendTo(this.options.parentElement);
|
|
6390
|
+
}
|
|
6391
|
+
}, {
|
|
6392
|
+
key: "appendStyles",
|
|
6393
|
+
value: function appendStyles() {
|
|
6394
|
+
if (this.styleRendered) return;
|
|
6277
6395
|
var style = Styler.getStyleFor(css_248z$4$1.toString(), {
|
|
6278
6396
|
baseUrl: this.options.baseUrl
|
|
6279
6397
|
});
|
|
6280
|
-
var resetStyle = Styler.getStyleFor(css_248z$3$1.toString(), {
|
|
6281
|
-
baseUrl: this.options.baseUrl
|
|
6282
|
-
});
|
|
6283
6398
|
this.$el.append(style[0]);
|
|
6284
|
-
this.options.includeResetStyle
|
|
6285
|
-
|
|
6286
|
-
|
|
6399
|
+
if (this.options.includeResetStyle) {
|
|
6400
|
+
var resetStyle = Styler.getStyleFor(css_248z$3$1.toString(), {
|
|
6401
|
+
baseUrl: this.options.baseUrl
|
|
6402
|
+
});
|
|
6403
|
+
this.$el.append(resetStyle[0]);
|
|
6404
|
+
}
|
|
6405
|
+
this.styleRendered = true;
|
|
6287
6406
|
}
|
|
6288
6407
|
}, {
|
|
6289
6408
|
key: "render",
|
|
6290
6409
|
value: function render() {
|
|
6410
|
+
this.appendStyles();
|
|
6291
6411
|
this.options.width = this.options.width || this.$el.width();
|
|
6292
6412
|
this.options.height = this.options.height || this.$el.height();
|
|
6293
6413
|
var size = {
|
|
@@ -6300,7 +6420,6 @@
|
|
|
6300
6420
|
return this;
|
|
6301
6421
|
}
|
|
6302
6422
|
}]);
|
|
6303
|
-
return Core;
|
|
6304
6423
|
}(UIObject);
|
|
6305
6424
|
Object.assign(Core.prototype, ErrorMixin);
|
|
6306
6425
|
|
|
@@ -6312,8 +6431,6 @@
|
|
|
6312
6431
|
* @module components
|
|
6313
6432
|
*/
|
|
6314
6433
|
var CoreFactory = /*#__PURE__*/function (_BaseObject) {
|
|
6315
|
-
_inherits$1(CoreFactory, _BaseObject);
|
|
6316
|
-
var _super = _createSuper$1(CoreFactory);
|
|
6317
6434
|
/**
|
|
6318
6435
|
* it builds the core factory
|
|
6319
6436
|
* @method constructor
|
|
@@ -6322,7 +6439,7 @@
|
|
|
6322
6439
|
function CoreFactory(player) {
|
|
6323
6440
|
var _this;
|
|
6324
6441
|
_classCallCheck$1(this, CoreFactory);
|
|
6325
|
-
_this =
|
|
6442
|
+
_this = _callSuper$1(this, CoreFactory, [player.options]);
|
|
6326
6443
|
_this.player = player;
|
|
6327
6444
|
return _this;
|
|
6328
6445
|
}
|
|
@@ -6332,7 +6449,8 @@
|
|
|
6332
6449
|
* @method create
|
|
6333
6450
|
* @return {Core} created core
|
|
6334
6451
|
*/
|
|
6335
|
-
|
|
6452
|
+
_inherits$1(CoreFactory, _BaseObject);
|
|
6453
|
+
return _createClass$1(CoreFactory, [{
|
|
6336
6454
|
key: "loader",
|
|
6337
6455
|
get: function get() {
|
|
6338
6456
|
return this.player.loader;
|
|
@@ -6367,14 +6485,10 @@
|
|
|
6367
6485
|
key: "setupExternalInterface",
|
|
6368
6486
|
value: function setupExternalInterface(plugin) {
|
|
6369
6487
|
var externalFunctions = plugin.getExternalInterface();
|
|
6370
|
-
for (var key in externalFunctions)
|
|
6371
|
-
this.player[key] = externalFunctions[key].bind(plugin);
|
|
6372
|
-
}
|
|
6488
|
+
for (var key in externalFunctions) this.player[key] = externalFunctions[key].bind(plugin);
|
|
6373
6489
|
}
|
|
6374
6490
|
}]);
|
|
6375
|
-
return CoreFactory;
|
|
6376
6491
|
}(BaseObject);
|
|
6377
|
-
|
|
6378
6492
|
var VERSION_REGEX = /(\d+)(?:\.(\d+))?(?:\.(\d+))?/;
|
|
6379
6493
|
var Version = /*#__PURE__*/function () {
|
|
6380
6494
|
function Version(major, minor, patch) {
|
|
@@ -6383,7 +6497,7 @@
|
|
|
6383
6497
|
this.minor = parseInt(minor || 0, 10);
|
|
6384
6498
|
this.patch = parseInt(patch || 0, 10);
|
|
6385
6499
|
}
|
|
6386
|
-
_createClass$1(Version, [{
|
|
6500
|
+
return _createClass$1(Version, [{
|
|
6387
6501
|
key: "compare",
|
|
6388
6502
|
value: function compare(other) {
|
|
6389
6503
|
var diff = this.major - other.major;
|
|
@@ -6421,9 +6535,7 @@
|
|
|
6421
6535
|
return new Version(major, minor, patch);
|
|
6422
6536
|
}
|
|
6423
6537
|
}]);
|
|
6424
|
-
return Version;
|
|
6425
6538
|
}();
|
|
6426
|
-
|
|
6427
6539
|
var filterPluginsByType = function filterPluginsByType(plugins, type) {
|
|
6428
6540
|
if (!plugins || !type) return {};
|
|
6429
6541
|
return Object.entries(plugins).filter(function (_ref) {
|
|
@@ -6445,12 +6557,12 @@
|
|
|
6445
6557
|
* @extends BaseObject
|
|
6446
6558
|
* @module components
|
|
6447
6559
|
*/
|
|
6448
|
-
var Loader =
|
|
6560
|
+
var Loader = function () {
|
|
6449
6561
|
var registry = {
|
|
6450
6562
|
plugins: {},
|
|
6451
6563
|
playbacks: []
|
|
6452
6564
|
};
|
|
6453
|
-
var currentVersion = "0.
|
|
6565
|
+
var currentVersion = "0.8.0";
|
|
6454
6566
|
return /*#__PURE__*/function () {
|
|
6455
6567
|
/**
|
|
6456
6568
|
* builds the loader
|
|
@@ -6480,7 +6592,7 @@
|
|
|
6480
6592
|
* @param {Object} an config object or an array of plugins
|
|
6481
6593
|
* @return {Object} plugins the config object with the plugins separated by type
|
|
6482
6594
|
*/
|
|
6483
|
-
_createClass$1(Loader, [{
|
|
6595
|
+
return _createClass$1(Loader, [{
|
|
6484
6596
|
key: "groupPluginsByType",
|
|
6485
6597
|
value: function groupPluginsByType(plugins) {
|
|
6486
6598
|
if (Array.isArray(plugins)) {
|
|
@@ -6504,9 +6616,7 @@
|
|
|
6504
6616
|
};
|
|
6505
6617
|
var pluginsMap = list.reduceRight(groupUp, Object.create(null));
|
|
6506
6618
|
var plugins = [];
|
|
6507
|
-
for (var key in pluginsMap)
|
|
6508
|
-
plugins.unshift(pluginsMap[key]);
|
|
6509
|
-
}
|
|
6619
|
+
for (var key in pluginsMap) plugins.unshift(pluginsMap[key]);
|
|
6510
6620
|
return plugins;
|
|
6511
6621
|
}
|
|
6512
6622
|
|
|
@@ -6659,10 +6769,8 @@
|
|
|
6659
6769
|
registry.playbacks = [];
|
|
6660
6770
|
}
|
|
6661
6771
|
}]);
|
|
6662
|
-
return Loader;
|
|
6663
6772
|
}();
|
|
6664
|
-
}
|
|
6665
|
-
|
|
6773
|
+
}();
|
|
6666
6774
|
var baseUrl = currentScriptUrl().replace(/\/[^/]+$/, '');
|
|
6667
6775
|
|
|
6668
6776
|
/**
|
|
@@ -6690,8 +6798,6 @@
|
|
|
6690
6798
|
* ```
|
|
6691
6799
|
*/
|
|
6692
6800
|
var Player = /*#__PURE__*/function (_BaseObject) {
|
|
6693
|
-
_inherits$1(Player, _BaseObject);
|
|
6694
|
-
var _super = _createSuper$1(Player);
|
|
6695
6801
|
/**
|
|
6696
6802
|
* @typedef {Object} PlaybackConfig
|
|
6697
6803
|
* @prop {boolean} disableContextMenu
|
|
@@ -6823,7 +6929,7 @@
|
|
|
6823
6929
|
function Player(options) {
|
|
6824
6930
|
var _this;
|
|
6825
6931
|
_classCallCheck$1(this, Player);
|
|
6826
|
-
_this =
|
|
6932
|
+
_this = _callSuper$1(this, Player, [options]);
|
|
6827
6933
|
var playbackDefaultOptions = {
|
|
6828
6934
|
recycleVideo: true
|
|
6829
6935
|
};
|
|
@@ -6837,7 +6943,7 @@
|
|
|
6837
6943
|
includeResetStyle: true,
|
|
6838
6944
|
playback: playbackDefaultOptions
|
|
6839
6945
|
};
|
|
6840
|
-
_this._options =
|
|
6946
|
+
_this._options = $.extend(true, defaultOptions, options);
|
|
6841
6947
|
_this.options.sources = _this._normalizeSources(options);
|
|
6842
6948
|
if (!_this.options.chromeless) {
|
|
6843
6949
|
// "allowUserInteraction" cannot be false if not in chromeless mode.
|
|
@@ -6848,7 +6954,7 @@
|
|
|
6848
6954
|
_this.options.disableKeyboardShortcuts = true;
|
|
6849
6955
|
}
|
|
6850
6956
|
_this._registerOptionEventListeners(_this.options.events);
|
|
6851
|
-
_this._coreFactory = new CoreFactory(
|
|
6957
|
+
_this._coreFactory = new CoreFactory(_this);
|
|
6852
6958
|
var parentElement = _this._getParentElement(_this.options);
|
|
6853
6959
|
parentElement && _this.attachTo(parentElement);
|
|
6854
6960
|
return _this;
|
|
@@ -6860,7 +6966,8 @@
|
|
|
6860
6966
|
* @param {Object} parent
|
|
6861
6967
|
* @returns {Object} the parent element
|
|
6862
6968
|
*/
|
|
6863
|
-
|
|
6969
|
+
_inherits$1(Player, _BaseObject);
|
|
6970
|
+
return _createClass$1(Player, [{
|
|
6864
6971
|
key: "loader",
|
|
6865
6972
|
get: function get() {
|
|
6866
6973
|
if (!this._loader) this._loader = new Loader(this.options.plugins || {}, this.options.playerId);
|
|
@@ -7337,7 +7444,6 @@
|
|
|
7337
7444
|
return this.core.activeContainer.getDuration();
|
|
7338
7445
|
}
|
|
7339
7446
|
}]);
|
|
7340
|
-
return Player;
|
|
7341
7447
|
}(BaseObject);
|
|
7342
7448
|
Object.assign(Player.prototype, ErrorMixin);
|
|
7343
7449
|
|
|
@@ -7349,18 +7455,17 @@
|
|
|
7349
7455
|
* @module base
|
|
7350
7456
|
*/
|
|
7351
7457
|
var ContainerPlugin = /*#__PURE__*/function (_BaseObject) {
|
|
7352
|
-
_inherits$1(ContainerPlugin, _BaseObject);
|
|
7353
|
-
var _super = _createSuper$1(ContainerPlugin);
|
|
7354
7458
|
function ContainerPlugin(container) {
|
|
7355
7459
|
var _this;
|
|
7356
7460
|
_classCallCheck$1(this, ContainerPlugin);
|
|
7357
|
-
_this =
|
|
7461
|
+
_this = _callSuper$1(this, ContainerPlugin, [container.options]);
|
|
7358
7462
|
_this.container = container;
|
|
7359
7463
|
_this.enabled = true;
|
|
7360
7464
|
_this.bindEvents();
|
|
7361
7465
|
return _this;
|
|
7362
7466
|
}
|
|
7363
|
-
|
|
7467
|
+
_inherits$1(ContainerPlugin, _BaseObject);
|
|
7468
|
+
return _createClass$1(ContainerPlugin, [{
|
|
7364
7469
|
key: "playerError",
|
|
7365
7470
|
get: function get() {
|
|
7366
7471
|
return this.container.playerError;
|
|
@@ -7390,27 +7495,24 @@
|
|
|
7390
7495
|
this.stopListening();
|
|
7391
7496
|
}
|
|
7392
7497
|
}]);
|
|
7393
|
-
return ContainerPlugin;
|
|
7394
7498
|
}(BaseObject);
|
|
7395
7499
|
Object.assign(ContainerPlugin.prototype, ErrorMixin);
|
|
7396
7500
|
ContainerPlugin.extend = function (properties) {
|
|
7397
7501
|
return extend$1(ContainerPlugin, properties);
|
|
7398
7502
|
};
|
|
7399
7503
|
ContainerPlugin.type = 'container';
|
|
7400
|
-
|
|
7401
7504
|
var CorePlugin = /*#__PURE__*/function (_BaseObject) {
|
|
7402
|
-
_inherits$1(CorePlugin, _BaseObject);
|
|
7403
|
-
var _super = _createSuper$1(CorePlugin);
|
|
7404
7505
|
function CorePlugin(core) {
|
|
7405
7506
|
var _this;
|
|
7406
7507
|
_classCallCheck$1(this, CorePlugin);
|
|
7407
|
-
_this =
|
|
7508
|
+
_this = _callSuper$1(this, CorePlugin, [core.options]);
|
|
7408
7509
|
_this.core = core;
|
|
7409
7510
|
_this.enabled = true;
|
|
7410
7511
|
_this.bindEvents();
|
|
7411
7512
|
return _this;
|
|
7412
7513
|
}
|
|
7413
|
-
|
|
7514
|
+
_inherits$1(CorePlugin, _BaseObject);
|
|
7515
|
+
return _createClass$1(CorePlugin, [{
|
|
7414
7516
|
key: "playerError",
|
|
7415
7517
|
get: function get() {
|
|
7416
7518
|
return this.core.playerError;
|
|
@@ -7445,7 +7547,6 @@
|
|
|
7445
7547
|
this.stopListening();
|
|
7446
7548
|
}
|
|
7447
7549
|
}]);
|
|
7448
|
-
return CorePlugin;
|
|
7449
7550
|
}(BaseObject);
|
|
7450
7551
|
Object.assign(CorePlugin.prototype, ErrorMixin);
|
|
7451
7552
|
CorePlugin.extend = function (properties) {
|
|
@@ -7461,18 +7562,17 @@
|
|
|
7461
7562
|
* @module base
|
|
7462
7563
|
*/
|
|
7463
7564
|
var UIContainerPlugin = /*#__PURE__*/function (_UIObject) {
|
|
7464
|
-
_inherits$1(UIContainerPlugin, _UIObject);
|
|
7465
|
-
var _super = _createSuper$1(UIContainerPlugin);
|
|
7466
7565
|
function UIContainerPlugin(container) {
|
|
7467
7566
|
var _this;
|
|
7468
7567
|
_classCallCheck$1(this, UIContainerPlugin);
|
|
7469
|
-
_this =
|
|
7568
|
+
_this = _callSuper$1(this, UIContainerPlugin, [container.options]);
|
|
7470
7569
|
_this.container = container;
|
|
7471
7570
|
_this.enabled = true;
|
|
7472
7571
|
_this.bindEvents();
|
|
7473
7572
|
return _this;
|
|
7474
7573
|
}
|
|
7475
|
-
|
|
7574
|
+
_inherits$1(UIContainerPlugin, _UIObject);
|
|
7575
|
+
return _createClass$1(UIContainerPlugin, [{
|
|
7476
7576
|
key: "playerError",
|
|
7477
7577
|
get: function get() {
|
|
7478
7578
|
return this.container.playerError;
|
|
@@ -7497,18 +7597,14 @@
|
|
|
7497
7597
|
key: "bindEvents",
|
|
7498
7598
|
value: function bindEvents() {}
|
|
7499
7599
|
}]);
|
|
7500
|
-
return UIContainerPlugin;
|
|
7501
7600
|
}(UIObject);
|
|
7502
7601
|
Object.assign(UIContainerPlugin.prototype, ErrorMixin);
|
|
7503
7602
|
UIContainerPlugin.extend = function (properties) {
|
|
7504
7603
|
return extend$1(UIContainerPlugin, properties);
|
|
7505
7604
|
};
|
|
7506
7605
|
UIContainerPlugin.type = 'container';
|
|
7507
|
-
|
|
7508
7606
|
var tracksHTML = "<% for (var i = 0; i < tracks.length; i++) { %>\n <track data-html5-video-track=\"<%= i %>\" kind=\"<%= tracks[i].kind %>\" label=\"<%= tracks[i].label %>\" srclang=\"<%= tracks[i].lang %>\" src=\"<%= tracks[i].src %>\">\n<% }; %>\n";
|
|
7509
|
-
|
|
7510
7607
|
var css_248z$2$1 = "[data-html5-video] {\n position: absolute;\n height: 100%;\n width: 100%;\n display: block; }\n";
|
|
7511
|
-
|
|
7512
7608
|
var MIMETYPES = {
|
|
7513
7609
|
'mp4': ['avc1.42E01E', 'avc1.58A01E', 'avc1.4D401E', 'avc1.64001E', 'mp4v.20.8', 'mp4v.20.240', 'mp4a.40.2'].map(function (codec) {
|
|
7514
7610
|
return 'video/mp4; codecs="' + codec + ', mp4a.40.2"';
|
|
@@ -7537,15 +7633,13 @@
|
|
|
7537
7633
|
|
|
7538
7634
|
// TODO: rename this Playback to HTML5Playback (breaking change, only after 0.3.0)
|
|
7539
7635
|
var HTML5Video = /*#__PURE__*/function (_Playback) {
|
|
7540
|
-
_inherits$1(HTML5Video, _Playback);
|
|
7541
|
-
var _super = _createSuper$1(HTML5Video);
|
|
7542
7636
|
function HTML5Video() {
|
|
7543
7637
|
var _this;
|
|
7544
7638
|
_classCallCheck$1(this, HTML5Video);
|
|
7545
7639
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
7546
7640
|
args[_key] = arguments[_key];
|
|
7547
7641
|
}
|
|
7548
|
-
_this =
|
|
7642
|
+
_this = _callSuper$1(this, HTML5Video, [].concat(args));
|
|
7549
7643
|
_this._destroyed = false;
|
|
7550
7644
|
_this._loadStarted = false;
|
|
7551
7645
|
_this._isBuffering = false;
|
|
@@ -7553,7 +7647,9 @@
|
|
|
7553
7647
|
_this._playheadMovingTimer = null;
|
|
7554
7648
|
_this._stopped = false;
|
|
7555
7649
|
_this._ccTrackId = -1;
|
|
7650
|
+
_this._playheadMovingCheckEnabled = !_this.options.disablePlayheadMovingCheck;
|
|
7556
7651
|
_this._setupSrc(_this.options.src);
|
|
7652
|
+
_this._playheadMovingCheckInterval = _this.options.playheadMovingCheckInterval || 500;
|
|
7557
7653
|
// backwards compatibility (TODO: remove on 0.3.0)
|
|
7558
7654
|
_this.options.playback || (_this.options.playback = _this.options || {});
|
|
7559
7655
|
_this.options.playback.disableContextMenu = _this.options.playback.disableContextMenu || _this.options.disableVideoTagContextMenu;
|
|
@@ -7564,7 +7660,7 @@
|
|
|
7564
7660
|
if (_this.options.poster) {
|
|
7565
7661
|
if (typeof _this.options.poster === 'string') posterUrl = _this.options.poster;else if (typeof _this.options.poster.url === 'string') posterUrl = _this.options.poster.url;
|
|
7566
7662
|
}
|
|
7567
|
-
|
|
7663
|
+
$.extend(true, _this.el, {
|
|
7568
7664
|
muted: _this.options.mute,
|
|
7569
7665
|
defaultMuted: _this.options.mute,
|
|
7570
7666
|
loop: _this.options.loop,
|
|
@@ -7591,7 +7687,8 @@
|
|
|
7591
7687
|
_this.options.autoPlay && _this.attemptAutoPlay();
|
|
7592
7688
|
return _this;
|
|
7593
7689
|
}
|
|
7594
|
-
|
|
7690
|
+
_inherits$1(HTML5Video, _Playback);
|
|
7691
|
+
return _createClass$1(HTML5Video, [{
|
|
7595
7692
|
key: "name",
|
|
7596
7693
|
get: function get() {
|
|
7597
7694
|
return 'html5_video';
|
|
@@ -7600,7 +7697,7 @@
|
|
|
7600
7697
|
key: "supportedVersion",
|
|
7601
7698
|
get: function get() {
|
|
7602
7699
|
return {
|
|
7603
|
-
min: "0.
|
|
7700
|
+
min: "0.8.0"
|
|
7604
7701
|
};
|
|
7605
7702
|
}
|
|
7606
7703
|
}, {
|
|
@@ -7640,7 +7737,9 @@
|
|
|
7640
7737
|
'seeked': '_onSeeked',
|
|
7641
7738
|
'stalled': '_handleBufferingEvents',
|
|
7642
7739
|
'timeupdate': '_onTimeUpdate',
|
|
7643
|
-
'waiting': '_onWaiting'
|
|
7740
|
+
'waiting': '_onWaiting',
|
|
7741
|
+
'enterpictureinpicture': '_onEnterPiP',
|
|
7742
|
+
'leavepictureinpicture': '_onExitPiP'
|
|
7644
7743
|
};
|
|
7645
7744
|
}
|
|
7646
7745
|
|
|
@@ -7667,6 +7766,11 @@
|
|
|
7667
7766
|
get: function get() {
|
|
7668
7767
|
return this._isBuffering;
|
|
7669
7768
|
}
|
|
7769
|
+
}, {
|
|
7770
|
+
key: "isPiPActive",
|
|
7771
|
+
get: function get() {
|
|
7772
|
+
return this.el === document.pictureInPictureElement;
|
|
7773
|
+
}
|
|
7670
7774
|
}, {
|
|
7671
7775
|
key: "isLive",
|
|
7672
7776
|
get: function get() {
|
|
@@ -7687,6 +7791,11 @@
|
|
|
7687
7791
|
get: function get() {
|
|
7688
7792
|
return typeof this.minimumDVRSizeConfig !== 'undefined' && typeof this.minimumDVRSizeConfig === 'number';
|
|
7689
7793
|
}
|
|
7794
|
+
}, {
|
|
7795
|
+
key: "sourceMedia",
|
|
7796
|
+
get: function get() {
|
|
7797
|
+
return this._src;
|
|
7798
|
+
}
|
|
7690
7799
|
}, {
|
|
7691
7800
|
key: "configure",
|
|
7692
7801
|
value: function configure(options) {
|
|
@@ -7748,6 +7857,18 @@
|
|
|
7748
7857
|
});
|
|
7749
7858
|
}
|
|
7750
7859
|
|
|
7860
|
+
/**
|
|
7861
|
+
* Sets the source url on the <video> element, and also the 'src' property.
|
|
7862
|
+
* @method load
|
|
7863
|
+
* @public
|
|
7864
|
+
* @param {String} srcUrl The source URL.
|
|
7865
|
+
*/
|
|
7866
|
+
}, {
|
|
7867
|
+
key: "load",
|
|
7868
|
+
value: function load(srcUrl) {
|
|
7869
|
+
this._setupSrc(srcUrl);
|
|
7870
|
+
}
|
|
7871
|
+
|
|
7751
7872
|
/**
|
|
7752
7873
|
* Sets the source url on the <video> element, and also the 'src' property.
|
|
7753
7874
|
* @method setupSrc
|
|
@@ -7831,13 +7952,17 @@
|
|
|
7831
7952
|
}, {
|
|
7832
7953
|
key: "play",
|
|
7833
7954
|
value: function play() {
|
|
7955
|
+
var _this4 = this;
|
|
7834
7956
|
this.trigger(Events.PLAYBACK_PLAY_INTENT);
|
|
7835
7957
|
this._stopped = false;
|
|
7836
7958
|
this._setupSrc(this._src);
|
|
7837
7959
|
this._handleBufferingEvents();
|
|
7838
7960
|
var promise = this.el.play();
|
|
7839
7961
|
// For more details, see https://developers.google.com/web/updates/2016/03/play-returns-promise
|
|
7840
|
-
if (promise && promise["catch"]) promise["catch"](function () {
|
|
7962
|
+
if (promise && promise["catch"]) promise["catch"](function (error) {
|
|
7963
|
+
return Log.warn(_this4.name, 'HTML5 play failed', error);
|
|
7964
|
+
});
|
|
7965
|
+
return promise;
|
|
7841
7966
|
}
|
|
7842
7967
|
}, {
|
|
7843
7968
|
key: "pause",
|
|
@@ -7911,10 +8036,10 @@
|
|
|
7911
8036
|
}, {
|
|
7912
8037
|
key: "_startPlayheadMovingChecks",
|
|
7913
8038
|
value: function _startPlayheadMovingChecks() {
|
|
7914
|
-
if (this._playheadMovingTimer !== null) return;
|
|
8039
|
+
if (this._playheadMovingTimer !== null || !this._playheadMovingCheckEnabled) return;
|
|
7915
8040
|
this._playheadMovingTimeOnCheck = null;
|
|
7916
8041
|
this._determineIfPlayheadMoving();
|
|
7917
|
-
this._playheadMovingTimer = setInterval(this._determineIfPlayheadMoving.bind(this),
|
|
8042
|
+
this._playheadMovingTimer = setInterval(this._determineIfPlayheadMoving.bind(this), this._playheadMovingCheckInterval);
|
|
7918
8043
|
}
|
|
7919
8044
|
}, {
|
|
7920
8045
|
key: "_stopPlayheadMovingChecks",
|
|
@@ -8002,6 +8127,36 @@
|
|
|
8002
8127
|
this._handleBufferingEvents();
|
|
8003
8128
|
this.trigger(Events.PLAYBACK_ENDED, this.name);
|
|
8004
8129
|
}
|
|
8130
|
+
}, {
|
|
8131
|
+
key: "_onEnterPiP",
|
|
8132
|
+
value: function _onEnterPiP() {
|
|
8133
|
+
this.trigger(Events.PLAYBACK_PIP_ENTER, this.name);
|
|
8134
|
+
}
|
|
8135
|
+
}, {
|
|
8136
|
+
key: "_onExitPiP",
|
|
8137
|
+
value: function _onExitPiP() {
|
|
8138
|
+
this.trigger(Events.PLAYBACK_PIP_EXIT, this.name);
|
|
8139
|
+
}
|
|
8140
|
+
}, {
|
|
8141
|
+
key: "enterPiP",
|
|
8142
|
+
value: function enterPiP() {
|
|
8143
|
+
var _this5 = this;
|
|
8144
|
+
this.el.requestPictureInPicture().then(function () {
|
|
8145
|
+
Log.info(_this5.name, 'enter PIP success');
|
|
8146
|
+
})["catch"](function (e) {
|
|
8147
|
+
Log.warn(_this5.name, 'enter PIP failed', e);
|
|
8148
|
+
});
|
|
8149
|
+
}
|
|
8150
|
+
}, {
|
|
8151
|
+
key: "exitPiP",
|
|
8152
|
+
value: function exitPiP() {
|
|
8153
|
+
var _this6 = this;
|
|
8154
|
+
document.exitPictureInPicture().then(function () {
|
|
8155
|
+
Log.info(_this6.name, 'exit PIP success');
|
|
8156
|
+
})["catch"](function (e) {
|
|
8157
|
+
Log.warn(_this6.name, 'exit PIP failed', e);
|
|
8158
|
+
});
|
|
8159
|
+
}
|
|
8005
8160
|
|
|
8006
8161
|
// The playback should be classed as buffering if the following are true:
|
|
8007
8162
|
// - the ready state is less then HAVE_FUTURE_DATA or the playhead isn't moving and it should be
|
|
@@ -8011,8 +8166,11 @@
|
|
|
8011
8166
|
}, {
|
|
8012
8167
|
key: "_handleBufferingEvents",
|
|
8013
8168
|
value: function _handleBufferingEvents() {
|
|
8014
|
-
var
|
|
8015
|
-
var
|
|
8169
|
+
var isLoading = this._loadStarted && !this.el.ended && !this._stopped;
|
|
8170
|
+
var isMissingMediaDataToPlay = this.el.readyState < this.el.HAVE_FUTURE_DATA;
|
|
8171
|
+
var playheadShouldBeMoving = !this.el.ended && !this.el.paused && !this._playheadMoving;
|
|
8172
|
+
var buffering = isLoading && isMissingMediaDataToPlay;
|
|
8173
|
+
if (this._playheadMovingCheckEnabled) buffering = buffering || isLoading && playheadShouldBeMoving;
|
|
8016
8174
|
if (this._isBuffering !== buffering) {
|
|
8017
8175
|
this._isBuffering = buffering;
|
|
8018
8176
|
if (buffering) this.trigger(Events.PLAYBACK_BUFFERING, this.name);else this.trigger(Events.PLAYBACK_BUFFERFULL, this.name);
|
|
@@ -8037,7 +8195,9 @@
|
|
|
8037
8195
|
key: "destroy",
|
|
8038
8196
|
value: function destroy() {
|
|
8039
8197
|
this._destroyed = true;
|
|
8198
|
+
this._stopPlayheadMovingChecks();
|
|
8040
8199
|
this.handleTextTrackChange && this.el.textTracks.removeEventListener('change', this.handleTextTrackChange);
|
|
8200
|
+
this.$el.off('contextmenu');
|
|
8041
8201
|
_get$1(_getPrototypeOf$1(HTML5Video.prototype), "destroy", this).call(this);
|
|
8042
8202
|
this.el.removeAttribute('src');
|
|
8043
8203
|
this.el.load(); // load with no src to stop loading of the previous source and avoid leaks
|
|
@@ -8098,11 +8258,11 @@
|
|
|
8098
8258
|
}, {
|
|
8099
8259
|
key: "_scheduleUpdateSettingsCheck",
|
|
8100
8260
|
value: function _scheduleUpdateSettingsCheck() {
|
|
8101
|
-
var
|
|
8261
|
+
var _this7 = this;
|
|
8102
8262
|
if (this._updateSettingsCheckInFlight) return;
|
|
8103
8263
|
this._updateSettingsCheckInFlight = setTimeout(function () {
|
|
8104
|
-
|
|
8105
|
-
|
|
8264
|
+
_this7._updateSettings();
|
|
8265
|
+
_this7._updateSettingsCheckInFlight = null;
|
|
8106
8266
|
}, 1000);
|
|
8107
8267
|
}
|
|
8108
8268
|
}, {
|
|
@@ -8262,9 +8422,11 @@
|
|
|
8262
8422
|
return this;
|
|
8263
8423
|
}
|
|
8264
8424
|
}]);
|
|
8265
|
-
return HTML5Video;
|
|
8266
8425
|
}(Playback);
|
|
8267
|
-
HTML5Video._mimeTypesForUrl = function (
|
|
8426
|
+
HTML5Video._mimeTypesForUrl = function () {
|
|
8427
|
+
var resourceUrl = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
|
|
8428
|
+
var mimeTypesByExtension = arguments.length > 1 ? arguments[1] : undefined;
|
|
8429
|
+
var mimeType = arguments.length > 2 ? arguments[2] : undefined;
|
|
8268
8430
|
var extension = (resourceUrl.split('?')[0].match(/.*\.(.*)$/) || [])[1];
|
|
8269
8431
|
var mimeTypes = mimeType || extension && mimeTypesByExtension[extension.toLowerCase()] || [];
|
|
8270
8432
|
return mimeTypes.constructor === Array ? mimeTypes : [mimeTypes];
|
|
@@ -8282,13 +8444,12 @@
|
|
|
8282
8444
|
|
|
8283
8445
|
// TODO: remove this playback and change HTML5Video to HTML5Playback (breaking change, only after 0.3.0)
|
|
8284
8446
|
var HTML5Audio = /*#__PURE__*/function (_HTML5Video) {
|
|
8285
|
-
_inherits$1(HTML5Audio, _HTML5Video);
|
|
8286
|
-
var _super = _createSuper$1(HTML5Audio);
|
|
8287
8447
|
function HTML5Audio() {
|
|
8288
8448
|
_classCallCheck$1(this, HTML5Audio);
|
|
8289
|
-
return
|
|
8449
|
+
return _callSuper$1(this, HTML5Audio, arguments);
|
|
8290
8450
|
}
|
|
8291
|
-
|
|
8451
|
+
_inherits$1(HTML5Audio, _HTML5Video);
|
|
8452
|
+
return _createClass$1(HTML5Audio, [{
|
|
8292
8453
|
key: "name",
|
|
8293
8454
|
get: function get() {
|
|
8294
8455
|
return 'html5_audio';
|
|
@@ -8297,7 +8458,7 @@
|
|
|
8297
8458
|
key: "supportedVersion",
|
|
8298
8459
|
get: function get() {
|
|
8299
8460
|
return {
|
|
8300
|
-
min: "0.
|
|
8461
|
+
min: "0.8.0"
|
|
8301
8462
|
};
|
|
8302
8463
|
}
|
|
8303
8464
|
}, {
|
|
@@ -8323,7 +8484,6 @@
|
|
|
8323
8484
|
return Playback.AOD;
|
|
8324
8485
|
}
|
|
8325
8486
|
}]);
|
|
8326
|
-
return HTML5Audio;
|
|
8327
8487
|
}(HTML5Video);
|
|
8328
8488
|
HTML5Audio.canPlay = function (resourceUrl, mimeType) {
|
|
8329
8489
|
var mimetypes = {
|
|
@@ -8334,20 +8494,17 @@
|
|
|
8334
8494
|
};
|
|
8335
8495
|
return HTML5Video._canPlay('audio', mimetypes, resourceUrl, mimeType);
|
|
8336
8496
|
};
|
|
8337
|
-
|
|
8338
8497
|
var css_248z$1$1 = "[data-html-img] {\n max-width: 100%;\n max-height: 100%; }\n";
|
|
8339
|
-
|
|
8340
8498
|
var HTMLImg = /*#__PURE__*/function (_Playback) {
|
|
8341
|
-
_inherits$1(HTMLImg, _Playback);
|
|
8342
|
-
var _super = _createSuper$1(HTMLImg);
|
|
8343
8499
|
function HTMLImg(params) {
|
|
8344
8500
|
var _this;
|
|
8345
8501
|
_classCallCheck$1(this, HTMLImg);
|
|
8346
|
-
_this =
|
|
8502
|
+
_this = _callSuper$1(this, HTMLImg, [params]);
|
|
8347
8503
|
_this.el.src = params.src;
|
|
8348
8504
|
return _this;
|
|
8349
8505
|
}
|
|
8350
|
-
|
|
8506
|
+
_inherits$1(HTMLImg, _Playback);
|
|
8507
|
+
return _createClass$1(HTMLImg, [{
|
|
8351
8508
|
key: "name",
|
|
8352
8509
|
get: function get() {
|
|
8353
8510
|
return 'html_img';
|
|
@@ -8356,7 +8513,7 @@
|
|
|
8356
8513
|
key: "supportedVersion",
|
|
8357
8514
|
get: function get() {
|
|
8358
8515
|
return {
|
|
8359
|
-
min: "0.
|
|
8516
|
+
min: "0.8.0"
|
|
8360
8517
|
};
|
|
8361
8518
|
}
|
|
8362
8519
|
}, {
|
|
@@ -8409,30 +8566,25 @@
|
|
|
8409
8566
|
}, this.name);
|
|
8410
8567
|
}
|
|
8411
8568
|
}]);
|
|
8412
|
-
return HTMLImg;
|
|
8413
8569
|
}(Playback);
|
|
8414
8570
|
HTMLImg.canPlay = function (resource) {
|
|
8415
8571
|
return /\.(png|jpg|jpeg|gif|bmp|tiff|pgm|pnm|webp)(|\?.*)$/i.test(resource);
|
|
8416
8572
|
};
|
|
8417
|
-
|
|
8418
8573
|
var noOpHTML = "<canvas data-no-op-canvas></canvas>\n<p data-no-op-msg><%=message%></p><p>\n</p>";
|
|
8419
|
-
|
|
8420
8574
|
var css_248z$8 = "[data-no-op] {\n position: absolute;\n height: 100%;\n width: 100%;\n text-align: center; }\n\n[data-no-op] p[data-no-op-msg] {\n position: absolute;\n text-align: center;\n font-size: 25px;\n left: 0;\n right: 0;\n color: white;\n padding: 10px;\n /* center vertically */\n top: 50%;\n transform: translateY(-50%);\n max-height: 100%;\n overflow: auto; }\n\n[data-no-op] canvas[data-no-op-canvas] {\n background-color: #777;\n height: 100%;\n width: 100%; }\n";
|
|
8421
|
-
|
|
8422
8575
|
var NoOp = /*#__PURE__*/function (_Playback) {
|
|
8423
|
-
_inherits$1(NoOp, _Playback);
|
|
8424
|
-
var _super = _createSuper$1(NoOp);
|
|
8425
8576
|
function NoOp() {
|
|
8426
8577
|
var _this;
|
|
8427
8578
|
_classCallCheck$1(this, NoOp);
|
|
8428
8579
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
8429
8580
|
args[_key] = arguments[_key];
|
|
8430
8581
|
}
|
|
8431
|
-
_this =
|
|
8582
|
+
_this = _callSuper$1(this, NoOp, [].concat(args));
|
|
8432
8583
|
_this._noiseFrameNum = -1;
|
|
8433
8584
|
return _this;
|
|
8434
8585
|
}
|
|
8435
|
-
|
|
8586
|
+
_inherits$1(NoOp, _Playback);
|
|
8587
|
+
return _createClass$1(NoOp, [{
|
|
8436
8588
|
key: "name",
|
|
8437
8589
|
get: function get() {
|
|
8438
8590
|
return 'no_op';
|
|
@@ -8441,7 +8593,7 @@
|
|
|
8441
8593
|
key: "supportedVersion",
|
|
8442
8594
|
get: function get() {
|
|
8443
8595
|
return {
|
|
8444
|
-
min: "0.
|
|
8596
|
+
min: "0.8.0"
|
|
8445
8597
|
};
|
|
8446
8598
|
}
|
|
8447
8599
|
}, {
|
|
@@ -8487,9 +8639,7 @@
|
|
|
8487
8639
|
} catch (err) {
|
|
8488
8640
|
buffer32 = new Uint32Array(this.context.canvas.width * this.context.canvas.height * 4);
|
|
8489
8641
|
var data = idata.data;
|
|
8490
|
-
for (var i = 0; i < data.length; i++)
|
|
8491
|
-
buffer32[i] = data[i];
|
|
8492
|
-
}
|
|
8642
|
+
for (var i = 0; i < data.length; i++) buffer32[i] = data[i];
|
|
8493
8643
|
}
|
|
8494
8644
|
var len = buffer32.length,
|
|
8495
8645
|
m = Math.random() * 6 + 4;
|
|
@@ -8532,7 +8682,6 @@
|
|
|
8532
8682
|
this._loop();
|
|
8533
8683
|
}
|
|
8534
8684
|
}]);
|
|
8535
|
-
return NoOp;
|
|
8536
8685
|
}(Playback);
|
|
8537
8686
|
NoOp.canPlay = function (source) {
|
|
8538
8687
|
// eslint-disable-line no-unused-vars
|
|
@@ -8547,12 +8696,10 @@
|
|
|
8547
8696
|
* @module plugins
|
|
8548
8697
|
*/
|
|
8549
8698
|
var Strings = /*#__PURE__*/function (_CorePlugin) {
|
|
8550
|
-
_inherits$1(Strings, _CorePlugin);
|
|
8551
|
-
var _super = _createSuper$1(Strings);
|
|
8552
8699
|
function Strings(core) {
|
|
8553
8700
|
var _this;
|
|
8554
8701
|
_classCallCheck$1(this, Strings);
|
|
8555
|
-
_this =
|
|
8702
|
+
_this = _callSuper$1(this, Strings, [core]);
|
|
8556
8703
|
_this._initializeMessages();
|
|
8557
8704
|
return _this;
|
|
8558
8705
|
}
|
|
@@ -8562,7 +8709,8 @@
|
|
|
8562
8709
|
* @param {String} key the key to all messages
|
|
8563
8710
|
* @return {String} translated label
|
|
8564
8711
|
*/
|
|
8565
|
-
|
|
8712
|
+
_inherits$1(Strings, _CorePlugin);
|
|
8713
|
+
return _createClass$1(Strings, [{
|
|
8566
8714
|
key: "name",
|
|
8567
8715
|
get: function get() {
|
|
8568
8716
|
return 'strings';
|
|
@@ -8571,7 +8719,7 @@
|
|
|
8571
8719
|
key: "supportedVersion",
|
|
8572
8720
|
get: function get() {
|
|
8573
8721
|
return {
|
|
8574
|
-
min: "0.
|
|
8722
|
+
min: "0.8.0"
|
|
8575
8723
|
};
|
|
8576
8724
|
}
|
|
8577
8725
|
}, {
|
|
@@ -8611,7 +8759,7 @@
|
|
|
8611
8759
|
'live': 'ao vivo',
|
|
8612
8760
|
'back_to_live': 'voltar para o ao vivo',
|
|
8613
8761
|
'disabled': 'Desativado',
|
|
8614
|
-
'playback_not_supported': 'Seu navegador não
|
|
8762
|
+
'playback_not_supported': 'Seu navegador não suporta a reprodução deste video. Por favor, tente usar um navegador diferente.',
|
|
8615
8763
|
'default_error_title': 'Não foi possível reproduzir o vídeo.',
|
|
8616
8764
|
'default_error_message': 'Ocorreu um problema ao tentar carregar o vídeo.'
|
|
8617
8765
|
},
|
|
@@ -8682,7 +8830,7 @@
|
|
|
8682
8830
|
'default_error_message': '在尝试加载视频时出现了问题。'
|
|
8683
8831
|
}
|
|
8684
8832
|
};
|
|
8685
|
-
this._messages =
|
|
8833
|
+
this._messages = $.extend(true, defaultMessages, this.core.options.strings || {});
|
|
8686
8834
|
this._messages['de-DE'] = this._messages['de'];
|
|
8687
8835
|
this._messages['pt-BR'] = this._messages['pt'];
|
|
8688
8836
|
this._messages['en-US'] = this._messages['en'];
|
|
@@ -8696,17 +8844,14 @@
|
|
|
8696
8844
|
this._messages['zh-CN'] = this._messages['zh'];
|
|
8697
8845
|
}
|
|
8698
8846
|
}]);
|
|
8699
|
-
return Strings;
|
|
8700
8847
|
}(CorePlugin);
|
|
8701
|
-
|
|
8702
8848
|
var SourcesPlugin = /*#__PURE__*/function (_CorePlugin) {
|
|
8703
|
-
_inherits$1(SourcesPlugin, _CorePlugin);
|
|
8704
|
-
var _super = _createSuper$1(SourcesPlugin);
|
|
8705
8849
|
function SourcesPlugin() {
|
|
8706
8850
|
_classCallCheck$1(this, SourcesPlugin);
|
|
8707
|
-
return
|
|
8851
|
+
return _callSuper$1(this, SourcesPlugin, arguments);
|
|
8708
8852
|
}
|
|
8709
|
-
|
|
8853
|
+
_inherits$1(SourcesPlugin, _CorePlugin);
|
|
8854
|
+
return _createClass$1(SourcesPlugin, [{
|
|
8710
8855
|
key: "name",
|
|
8711
8856
|
get: function get() {
|
|
8712
8857
|
return 'sources';
|
|
@@ -8715,7 +8860,7 @@
|
|
|
8715
8860
|
key: "supportedVersion",
|
|
8716
8861
|
get: function get() {
|
|
8717
8862
|
return {
|
|
8718
|
-
min: "0.
|
|
8863
|
+
min: "0.8.0"
|
|
8719
8864
|
};
|
|
8720
8865
|
}
|
|
8721
8866
|
}, {
|
|
@@ -8734,11 +8879,17 @@
|
|
|
8734
8879
|
});
|
|
8735
8880
|
}
|
|
8736
8881
|
}]);
|
|
8737
|
-
return SourcesPlugin;
|
|
8738
8882
|
}(CorePlugin);
|
|
8739
8883
|
|
|
8740
8884
|
// Copyright 2014 Globo.com Player authors. All rights reserved.
|
|
8741
|
-
|
|
8885
|
+
// Use of this source code is governed by a BSD-style
|
|
8886
|
+
// license that can be found in the LICENSE file.
|
|
8887
|
+
|
|
8888
|
+
/** @constant
|
|
8889
|
+
@type {string}
|
|
8890
|
+
@default
|
|
8891
|
+
*/
|
|
8892
|
+
var version$1 = "0.8.0";
|
|
8742
8893
|
|
|
8743
8894
|
// Built-in Plugins/Playbacks
|
|
8744
8895
|
|
|
@@ -8771,9 +8922,34 @@
|
|
|
8771
8922
|
Styler: Styler,
|
|
8772
8923
|
version: version$1,
|
|
8773
8924
|
template: tmpl,
|
|
8774
|
-
$:
|
|
8925
|
+
$: $
|
|
8775
8926
|
};
|
|
8776
8927
|
|
|
8928
|
+
function _callSuper(t, o, e) {
|
|
8929
|
+
return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e));
|
|
8930
|
+
}
|
|
8931
|
+
function _isNativeReflectConstruct() {
|
|
8932
|
+
try {
|
|
8933
|
+
var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
|
|
8934
|
+
} catch (t) {}
|
|
8935
|
+
return (_isNativeReflectConstruct = function () {
|
|
8936
|
+
return !!t;
|
|
8937
|
+
})();
|
|
8938
|
+
}
|
|
8939
|
+
function _toPrimitive(t, r) {
|
|
8940
|
+
if ("object" != typeof t || !t) return t;
|
|
8941
|
+
var e = t[Symbol.toPrimitive];
|
|
8942
|
+
if (void 0 !== e) {
|
|
8943
|
+
var i = e.call(t, r || "default");
|
|
8944
|
+
if ("object" != typeof i) return i;
|
|
8945
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
8946
|
+
}
|
|
8947
|
+
return ("string" === r ? String : Number)(t);
|
|
8948
|
+
}
|
|
8949
|
+
function _toPropertyKey(t) {
|
|
8950
|
+
var i = _toPrimitive(t, "string");
|
|
8951
|
+
return "symbol" == typeof i ? i : i + "";
|
|
8952
|
+
}
|
|
8777
8953
|
function _classCallCheck(instance, Constructor) {
|
|
8778
8954
|
if (!(instance instanceof Constructor)) {
|
|
8779
8955
|
throw new TypeError("Cannot call a class as a function");
|
|
@@ -8825,17 +9001,6 @@
|
|
|
8825
9001
|
};
|
|
8826
9002
|
return _setPrototypeOf(o, p);
|
|
8827
9003
|
}
|
|
8828
|
-
function _isNativeReflectConstruct() {
|
|
8829
|
-
if (typeof Reflect === "undefined" || !Reflect.construct) return false;
|
|
8830
|
-
if (Reflect.construct.sham) return false;
|
|
8831
|
-
if (typeof Proxy === "function") return true;
|
|
8832
|
-
try {
|
|
8833
|
-
Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
|
|
8834
|
-
return true;
|
|
8835
|
-
} catch (e) {
|
|
8836
|
-
return false;
|
|
8837
|
-
}
|
|
8838
|
-
}
|
|
8839
9004
|
function _assertThisInitialized(self) {
|
|
8840
9005
|
if (self === void 0) {
|
|
8841
9006
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
@@ -8850,20 +9015,6 @@
|
|
|
8850
9015
|
}
|
|
8851
9016
|
return _assertThisInitialized(self);
|
|
8852
9017
|
}
|
|
8853
|
-
function _createSuper(Derived) {
|
|
8854
|
-
var hasNativeReflectConstruct = _isNativeReflectConstruct();
|
|
8855
|
-
return function _createSuperInternal() {
|
|
8856
|
-
var Super = _getPrototypeOf(Derived),
|
|
8857
|
-
result;
|
|
8858
|
-
if (hasNativeReflectConstruct) {
|
|
8859
|
-
var NewTarget = _getPrototypeOf(this).constructor;
|
|
8860
|
-
result = Reflect.construct(Super, arguments, NewTarget);
|
|
8861
|
-
} else {
|
|
8862
|
-
result = Super.apply(this, arguments);
|
|
8863
|
-
}
|
|
8864
|
-
return _possibleConstructorReturn(this, result);
|
|
8865
|
-
};
|
|
8866
|
-
}
|
|
8867
9018
|
function _superPropBase(object, property) {
|
|
8868
9019
|
while (!Object.prototype.hasOwnProperty.call(object, property)) {
|
|
8869
9020
|
object = _getPrototypeOf(object);
|
|
@@ -8887,29 +9038,13 @@
|
|
|
8887
9038
|
}
|
|
8888
9039
|
return _get.apply(this, arguments);
|
|
8889
9040
|
}
|
|
8890
|
-
function _toPrimitive(input, hint) {
|
|
8891
|
-
if (typeof input !== "object" || input === null) return input;
|
|
8892
|
-
var prim = input[Symbol.toPrimitive];
|
|
8893
|
-
if (prim !== undefined) {
|
|
8894
|
-
var res = prim.call(input, hint || "default");
|
|
8895
|
-
if (typeof res !== "object") return res;
|
|
8896
|
-
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
8897
|
-
}
|
|
8898
|
-
return (hint === "string" ? String : Number)(input);
|
|
8899
|
-
}
|
|
8900
|
-
function _toPropertyKey(arg) {
|
|
8901
|
-
var key = _toPrimitive(arg, "string");
|
|
8902
|
-
return typeof key === "symbol" ? key : String(key);
|
|
8903
|
-
}
|
|
8904
|
-
|
|
8905
9041
|
var ClickToPausePlugin = /*#__PURE__*/function (_ContainerPlugin) {
|
|
8906
|
-
_inherits(ClickToPausePlugin, _ContainerPlugin);
|
|
8907
|
-
var _super = _createSuper(ClickToPausePlugin);
|
|
8908
9042
|
function ClickToPausePlugin(container) {
|
|
8909
9043
|
_classCallCheck(this, ClickToPausePlugin);
|
|
8910
|
-
return
|
|
9044
|
+
return _callSuper(this, ClickToPausePlugin, [container]);
|
|
8911
9045
|
}
|
|
8912
|
-
|
|
9046
|
+
_inherits(ClickToPausePlugin, _ContainerPlugin);
|
|
9047
|
+
return _createClass(ClickToPausePlugin, [{
|
|
8913
9048
|
key: "name",
|
|
8914
9049
|
get: function get() {
|
|
8915
9050
|
return 'click_to_pause';
|
|
@@ -8918,7 +9053,7 @@
|
|
|
8918
9053
|
key: "supportedVersion",
|
|
8919
9054
|
get: function get() {
|
|
8920
9055
|
return {
|
|
8921
|
-
min: "0.
|
|
9056
|
+
min: "0.8.0"
|
|
8922
9057
|
};
|
|
8923
9058
|
}
|
|
8924
9059
|
}, {
|
|
@@ -8950,22 +9085,15 @@
|
|
|
8950
9085
|
this.pointerEnabled = pointerEnabled;
|
|
8951
9086
|
}
|
|
8952
9087
|
}]);
|
|
8953
|
-
return ClickToPausePlugin;
|
|
8954
9088
|
}(ContainerPlugin);
|
|
8955
|
-
|
|
8956
9089
|
var ccIcon = "<svg version=\"1.1\" id=\"Layer_1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" x=\"0px\" y=\"0px\"\n\t viewBox=\"0 0 49 41.8\" style=\"enable-background:new 0 0 49 41.8;\" xml:space=\"preserve\">\n<path d=\"M47.1,0H3.2C1.6,0,0,1.2,0,2.8v31.5C0,35.9,1.6,37,3.2,37h11.9l3.2,1.9l4.7,2.7c0.9,0.5,2-0.1,2-1.1V37h22.1\n\tc1.6,0,1.9-1.1,1.9-2.7V2.8C49,1.2,48.7,0,47.1,0z M7.2,18.6c0-4.8,3.5-9.3,9.9-9.3c4.8,0,7.1,2.7,7.1,2.7l-2.5,4\n\tc0,0-1.7-1.7-4.2-1.7c-2.8,0-4.3,2.1-4.3,4.3c0,2.1,1.5,4.4,4.5,4.4c2.5,0,4.9-2.1,4.9-2.1l2.2,4.2c0,0-2.7,2.9-7.6,2.9\n\tC10.8,27.9,7.2,23.5,7.2,18.6z M36.9,27.9c-6.4,0-9.9-4.4-9.9-9.3c0-4.8,3.5-9.3,9.9-9.3C41.7,9.3,44,12,44,12l-2.5,4\n\tc0,0-1.7-1.7-4.2-1.7c-2.8,0-4.3,2.1-4.3,4.3c0,2.1,1.5,4.4,4.5,4.4c2.5,0,4.9-2.1,4.9-2.1l2.2,4.2C44.5,25,41.9,27.9,36.9,27.9z\"/>\n</svg>";
|
|
8957
|
-
|
|
8958
9090
|
var ccHTML = "<button type=\"button\" class=\"cc-button media-control-button media-control-icon\" data-cc-button aria-label=\"<%= ariaLabel %>\"></button>\n<ul>\n <% if (title) { %>\n <li data-title><%= title %></li>\n <% }; %>\n <li><a href=\"#\" data-cc-select=\"-1\"><%= disabledLabel %></a></li>\n <% for (var i = 0; i < tracks.length; i++) { %>\n <li><a href=\"#\" data-cc-select=\"<%= tracks[i].id %>\"><%= tracks[i].label %></a></li>\n <% }; %>\n</ul>\n";
|
|
8959
|
-
|
|
8960
9091
|
var css_248z$7 = ".cc-controls[data-cc-controls] {\n float: right;\n position: relative;\n display: none; }\n .cc-controls[data-cc-controls].available {\n display: block; }\n .cc-controls[data-cc-controls] .cc-button {\n padding: 6px !important; }\n .cc-controls[data-cc-controls] .cc-button.enabled {\n display: block;\n opacity: 1.0; }\n .cc-controls[data-cc-controls] .cc-button.enabled:hover {\n opacity: 1.0;\n text-shadow: none; }\n .cc-controls[data-cc-controls] > ul {\n list-style-type: none;\n position: absolute;\n bottom: 25px;\n border: 1px solid black;\n display: none;\n background-color: #e6e6e6; }\n .cc-controls[data-cc-controls] li {\n font-size: 10px; }\n .cc-controls[data-cc-controls] li[data-title] {\n background-color: #c3c2c2;\n padding: 5px; }\n .cc-controls[data-cc-controls] li a {\n color: #444;\n padding: 2px 10px;\n display: block;\n text-decoration: none; }\n .cc-controls[data-cc-controls] li a:hover {\n background-color: #555;\n color: white; }\n .cc-controls[data-cc-controls] li a:hover a {\n color: white;\n text-decoration: none; }\n .cc-controls[data-cc-controls] li.current a {\n color: #f00; }\n";
|
|
8961
|
-
|
|
8962
9092
|
var ClosedCaptions$1 = /*#__PURE__*/function (_UICorePlugin) {
|
|
8963
|
-
_inherits(ClosedCaptions, _UICorePlugin);
|
|
8964
|
-
var _super = _createSuper(ClosedCaptions);
|
|
8965
9093
|
function ClosedCaptions(core) {
|
|
8966
9094
|
var _this;
|
|
8967
9095
|
_classCallCheck(this, ClosedCaptions);
|
|
8968
|
-
_this =
|
|
9096
|
+
_this = _callSuper(this, ClosedCaptions, [core]);
|
|
8969
9097
|
var config = core.options.closedCaptionsConfig;
|
|
8970
9098
|
_this._title = config && config.title ? config.title : null;
|
|
8971
9099
|
_this._ariaLabel = config && config.ariaLabel ? config.ariaLabel : 'cc-button';
|
|
@@ -8974,7 +9102,8 @@
|
|
|
8974
9102
|
};
|
|
8975
9103
|
return _this;
|
|
8976
9104
|
}
|
|
8977
|
-
|
|
9105
|
+
_inherits(ClosedCaptions, _UICorePlugin);
|
|
9106
|
+
return _createClass(ClosedCaptions, [{
|
|
8978
9107
|
key: "name",
|
|
8979
9108
|
get: function get() {
|
|
8980
9109
|
return 'closed_captions';
|
|
@@ -8983,7 +9112,7 @@
|
|
|
8983
9112
|
key: "supportedVersion",
|
|
8984
9113
|
get: function get() {
|
|
8985
9114
|
return {
|
|
8986
|
-
min: "0.
|
|
9115
|
+
min: "0.8.0"
|
|
8987
9116
|
};
|
|
8988
9117
|
}
|
|
8989
9118
|
}, {
|
|
@@ -9116,24 +9245,19 @@
|
|
|
9116
9245
|
return this;
|
|
9117
9246
|
}
|
|
9118
9247
|
}]);
|
|
9119
|
-
return ClosedCaptions;
|
|
9120
9248
|
}(UICorePlugin);
|
|
9121
|
-
|
|
9122
9249
|
var dvrHTML = "<div class=\"live-info\"><%= live %></div>\n<button type=\"button\" class=\"live-button\" aria-label=\"<%= backToLive %>\"><%= backToLive %></button>\n";
|
|
9123
|
-
|
|
9124
9250
|
var css_248z$6 = ".dvr-controls[data-dvr-controls] {\n display: inline-block;\n float: left;\n color: #fff;\n line-height: 32px;\n font-size: 10px;\n font-weight: bold;\n margin-left: 6px; }\n .dvr-controls[data-dvr-controls] .live-info {\n cursor: default;\n font-family: \"Roboto\", \"Open Sans\", Arial, sans-serif;\n text-transform: uppercase; }\n .dvr-controls[data-dvr-controls] .live-info:before {\n content: \"\";\n display: inline-block;\n position: relative;\n width: 7px;\n height: 7px;\n border-radius: 3.5px;\n margin-right: 3.5px;\n background-color: #ff0101; }\n .dvr-controls[data-dvr-controls] .live-info.disabled {\n opacity: 0.3; }\n .dvr-controls[data-dvr-controls] .live-info.disabled:before {\n background-color: #fff; }\n .dvr-controls[data-dvr-controls] .live-button {\n cursor: pointer;\n outline: none;\n display: none;\n border: 0;\n color: #fff;\n background-color: transparent;\n height: 32px;\n padding: 0;\n opacity: 0.7;\n font-family: \"Roboto\", \"Open Sans\", Arial, sans-serif;\n text-transform: uppercase;\n transition: all 0.1s ease; }\n .dvr-controls[data-dvr-controls] .live-button:before {\n content: \"\";\n display: inline-block;\n position: relative;\n width: 7px;\n height: 7px;\n border-radius: 3.5px;\n margin-right: 3.5px;\n background-color: #fff; }\n .dvr-controls[data-dvr-controls] .live-button:hover {\n opacity: 1;\n text-shadow: rgba(255, 255, 255, 0.75) 0 0 5px; }\n\n.dvr .dvr-controls[data-dvr-controls] .live-info {\n display: none; }\n\n.dvr .dvr-controls[data-dvr-controls] .live-button {\n display: block; }\n\n.dvr.media-control.live[data-media-control] .media-control-layer[data-controls] .bar-container[data-seekbar] .bar-background[data-seekbar] .bar-fill-2[data-seekbar] {\n background-color: #005aff; }\n\n.media-control.live[data-media-control] .media-control-layer[data-controls] .bar-container[data-seekbar] .bar-background[data-seekbar] .bar-fill-2[data-seekbar] {\n background-color: #ff0101; }\n";
|
|
9125
|
-
|
|
9126
9251
|
var DVRControls$1 = /*#__PURE__*/function (_UICorePlugin) {
|
|
9127
|
-
_inherits(DVRControls, _UICorePlugin);
|
|
9128
|
-
var _super = _createSuper(DVRControls);
|
|
9129
9252
|
function DVRControls(core) {
|
|
9130
9253
|
var _this;
|
|
9131
9254
|
_classCallCheck(this, DVRControls);
|
|
9132
|
-
_this =
|
|
9255
|
+
_this = _callSuper(this, DVRControls, [core]);
|
|
9133
9256
|
_this.settingsUpdate();
|
|
9134
9257
|
return _this;
|
|
9135
9258
|
}
|
|
9136
|
-
|
|
9259
|
+
_inherits(DVRControls, _UICorePlugin);
|
|
9260
|
+
return _createClass(DVRControls, [{
|
|
9137
9261
|
key: "template",
|
|
9138
9262
|
get: function get() {
|
|
9139
9263
|
return tmpl(dvrHTML);
|
|
@@ -9147,7 +9271,7 @@
|
|
|
9147
9271
|
key: "supportedVersion",
|
|
9148
9272
|
get: function get() {
|
|
9149
9273
|
return {
|
|
9150
|
-
min: "0.
|
|
9274
|
+
min: "0.8.0"
|
|
9151
9275
|
};
|
|
9152
9276
|
}
|
|
9153
9277
|
}, {
|
|
@@ -9258,17 +9382,14 @@
|
|
|
9258
9382
|
return this;
|
|
9259
9383
|
}
|
|
9260
9384
|
}]);
|
|
9261
|
-
return DVRControls;
|
|
9262
9385
|
}(UICorePlugin);
|
|
9263
|
-
|
|
9264
9386
|
var EndVideo$1 = /*#__PURE__*/function (_CorePlugin) {
|
|
9265
|
-
_inherits(EndVideo, _CorePlugin);
|
|
9266
|
-
var _super = _createSuper(EndVideo);
|
|
9267
9387
|
function EndVideo() {
|
|
9268
9388
|
_classCallCheck(this, EndVideo);
|
|
9269
|
-
return
|
|
9389
|
+
return _callSuper(this, EndVideo, arguments);
|
|
9270
9390
|
}
|
|
9271
|
-
|
|
9391
|
+
_inherits(EndVideo, _CorePlugin);
|
|
9392
|
+
return _createClass(EndVideo, [{
|
|
9272
9393
|
key: "name",
|
|
9273
9394
|
get: function get() {
|
|
9274
9395
|
return 'end_video';
|
|
@@ -9277,7 +9398,7 @@
|
|
|
9277
9398
|
key: "supportedVersion",
|
|
9278
9399
|
get: function get() {
|
|
9279
9400
|
return {
|
|
9280
|
-
min: "0.
|
|
9401
|
+
min: "0.8.0"
|
|
9281
9402
|
};
|
|
9282
9403
|
}
|
|
9283
9404
|
}, {
|
|
@@ -9303,26 +9424,20 @@
|
|
|
9303
9424
|
if (exitOnEnd && this.core.isFullscreen()) this.core.toggleFullscreen();
|
|
9304
9425
|
}
|
|
9305
9426
|
}]);
|
|
9306
|
-
return EndVideo;
|
|
9307
9427
|
}(CorePlugin);
|
|
9308
|
-
|
|
9309
9428
|
var reloadIcon = "<svg fill=\"#FFFFFF\" height=\"24\" viewBox=\"0 0 24 24\" width=\"24\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M17.65 6.35C16.2 4.9 14.21 4 12 4c-4.42 0-7.99 3.58-7.99 8s3.57 8 7.99 8c3.73 0 6.84-2.55 7.73-6h-2.08c-.82 2.33-3.04 4-5.65 4-3.31 0-6-2.69-6-6s2.69-6 6-6c1.66 0 3.14.69 4.22 1.78L13 11h7V4l-2.35 2.35z\"/>\n <path d=\"M0 0h24v24H0z\" fill=\"none\"/>\n</svg>";
|
|
9310
|
-
|
|
9311
9429
|
var templateHtml = "<div class=\"player-error-screen__content\" data-error-screen>\n <% if (icon) { %>\n <div class=\"player-error-screen__icon\" data-error-screen><%= icon %></div>\n <% } %>\n <div class=\"player-error-screen__title\" data-error-screen><%= title %></div>\n <div class=\"player-error-screen__message\" data-error-screen><%= message %></div>\n <div class=\"player-error-screen__code\" data-error-screen>Error code: <%= code %></div>\n <div class=\"player-error-screen__reload\" data-error-screen><%= reloadIcon %></div>\n</div>\n";
|
|
9312
|
-
|
|
9313
9430
|
var css_248z$5 = "[data-player] .player-error-screen {\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n color: #CCCACA;\n position: absolute;\n top: 0;\n height: 100%;\n width: 100%;\n background-color: rgba(0, 0, 0, 0.7);\n z-index: 2000;\n display: flex;\n flex-direction: column;\n justify-content: center; }\n [data-player] .player-error-screen__content[data-error-screen] {\n font-size: 14px;\n color: #CCCACA;\n margin-top: 45px; }\n [data-player] .player-error-screen__title[data-error-screen] {\n font-weight: bold;\n line-height: 30px;\n font-size: 18px; }\n [data-player] .player-error-screen__message[data-error-screen] {\n width: 90%;\n margin: 0 auto; }\n [data-player] .player-error-screen__code[data-error-screen] {\n font-size: 13px;\n margin-top: 15px; }\n [data-player] .player-error-screen__reload {\n cursor: pointer;\n width: 30px;\n margin: 15px auto 0 !important; }\n";
|
|
9314
|
-
|
|
9315
9431
|
var ErrorScreen$1 = /*#__PURE__*/function (_UICorePlugin) {
|
|
9316
|
-
_inherits(ErrorScreen, _UICorePlugin);
|
|
9317
|
-
var _super = _createSuper(ErrorScreen);
|
|
9318
9432
|
function ErrorScreen(core) {
|
|
9319
9433
|
var _this;
|
|
9320
9434
|
_classCallCheck(this, ErrorScreen);
|
|
9321
|
-
_this =
|
|
9435
|
+
_this = _callSuper(this, ErrorScreen, [core]);
|
|
9322
9436
|
if (_this.options.disableErrorScreen) return _possibleConstructorReturn(_this, _this.disable());
|
|
9323
9437
|
return _this;
|
|
9324
9438
|
}
|
|
9325
|
-
|
|
9439
|
+
_inherits(ErrorScreen, _UICorePlugin);
|
|
9440
|
+
return _createClass(ErrorScreen, [{
|
|
9326
9441
|
key: "name",
|
|
9327
9442
|
get: function get() {
|
|
9328
9443
|
return 'error_screen';
|
|
@@ -9331,7 +9446,7 @@
|
|
|
9331
9446
|
key: "supportedVersion",
|
|
9332
9447
|
get: function get() {
|
|
9333
9448
|
return {
|
|
9334
|
-
min: "0.
|
|
9449
|
+
min: "0.8.0"
|
|
9335
9450
|
};
|
|
9336
9451
|
}
|
|
9337
9452
|
}, {
|
|
@@ -9428,26 +9543,21 @@
|
|
|
9428
9543
|
return this;
|
|
9429
9544
|
}
|
|
9430
9545
|
}]);
|
|
9431
|
-
return ErrorScreen;
|
|
9432
9546
|
}(UICorePlugin);
|
|
9433
|
-
|
|
9434
9547
|
var playIcon = "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 16 16\">\n <path fill=\"#010101\" d=\"M1.425.35L14.575 8l-13.15 7.65V.35z\"/>\n</svg>";
|
|
9435
|
-
|
|
9436
9548
|
var pauseIcon = "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 16 16\">\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" fill=\"#010101\" d=\"M1.712 14.76H6.43V1.24H1.71v13.52zm7.86-13.52v13.52h4.716V1.24H9.573z\"/>\n</svg>";
|
|
9437
|
-
|
|
9438
|
-
var oldIcon = zepto('link[rel="shortcut icon"]');
|
|
9549
|
+
var oldIcon = $('link[rel="shortcut icon"]');
|
|
9439
9550
|
var Favicon$1 = /*#__PURE__*/function (_CorePlugin) {
|
|
9440
|
-
_inherits(Favicon, _CorePlugin);
|
|
9441
|
-
var _super = _createSuper(Favicon);
|
|
9442
9551
|
function Favicon(core) {
|
|
9443
9552
|
var _this;
|
|
9444
9553
|
_classCallCheck(this, Favicon);
|
|
9445
|
-
_this =
|
|
9554
|
+
_this = _callSuper(this, Favicon, [core]);
|
|
9446
9555
|
_this._container = null;
|
|
9447
9556
|
_this.configure();
|
|
9448
9557
|
return _this;
|
|
9449
9558
|
}
|
|
9450
|
-
|
|
9559
|
+
_inherits(Favicon, _CorePlugin);
|
|
9560
|
+
return _createClass(Favicon, [{
|
|
9451
9561
|
key: "name",
|
|
9452
9562
|
get: function get() {
|
|
9453
9563
|
return 'favicon';
|
|
@@ -9456,7 +9566,7 @@
|
|
|
9456
9566
|
key: "supportedVersion",
|
|
9457
9567
|
get: function get() {
|
|
9458
9568
|
return {
|
|
9459
|
-
min: "0.
|
|
9569
|
+
min: "0.8.0"
|
|
9460
9570
|
};
|
|
9461
9571
|
}
|
|
9462
9572
|
}, {
|
|
@@ -9511,15 +9621,15 @@
|
|
|
9511
9621
|
}, {
|
|
9512
9622
|
key: "createIcon",
|
|
9513
9623
|
value: function createIcon(svg) {
|
|
9514
|
-
var canvas =
|
|
9624
|
+
var canvas = $('<canvas/>');
|
|
9515
9625
|
canvas[0].width = 16;
|
|
9516
9626
|
canvas[0].height = 16;
|
|
9517
9627
|
var ctx = canvas[0].getContext('2d');
|
|
9518
9628
|
ctx.fillStyle = '#000';
|
|
9519
|
-
var d =
|
|
9629
|
+
var d = $(svg).find('path').attr('d');
|
|
9520
9630
|
var path = new Path2D(d);
|
|
9521
9631
|
ctx.fill(path);
|
|
9522
|
-
var icon =
|
|
9632
|
+
var icon = $('<link rel="shortcut icon" type="image/png"/>');
|
|
9523
9633
|
icon.attr('href', canvas[0].toDataURL('image/png'));
|
|
9524
9634
|
return icon;
|
|
9525
9635
|
}
|
|
@@ -9538,28 +9648,24 @@
|
|
|
9538
9648
|
}, {
|
|
9539
9649
|
key: "resetIcon",
|
|
9540
9650
|
value: function resetIcon() {
|
|
9541
|
-
|
|
9542
|
-
|
|
9651
|
+
$('link[rel="shortcut icon"]').remove();
|
|
9652
|
+
$('head').append(this.oldIcon);
|
|
9543
9653
|
}
|
|
9544
9654
|
}, {
|
|
9545
9655
|
key: "changeIcon",
|
|
9546
9656
|
value: function changeIcon(icon) {
|
|
9547
9657
|
if (icon) {
|
|
9548
|
-
|
|
9549
|
-
|
|
9658
|
+
$('link[rel="shortcut icon"]').remove();
|
|
9659
|
+
$('head').append(icon);
|
|
9550
9660
|
}
|
|
9551
9661
|
}
|
|
9552
9662
|
}]);
|
|
9553
|
-
return Favicon;
|
|
9554
9663
|
}(CorePlugin);
|
|
9555
|
-
|
|
9556
9664
|
var GoogleAnalytics$1 = /*#__PURE__*/function (_ContainerPlugin) {
|
|
9557
|
-
_inherits(GoogleAnalytics, _ContainerPlugin);
|
|
9558
|
-
var _super = _createSuper(GoogleAnalytics);
|
|
9559
9665
|
function GoogleAnalytics(container) {
|
|
9560
9666
|
var _this;
|
|
9561
9667
|
_classCallCheck(this, GoogleAnalytics);
|
|
9562
|
-
_this =
|
|
9668
|
+
_this = _callSuper(this, GoogleAnalytics, [container]);
|
|
9563
9669
|
if (_this.container.options.gaAccount) {
|
|
9564
9670
|
_this.account = _this.container.options.gaAccount;
|
|
9565
9671
|
_this.trackerName = _this.container.options.gaTrackerName ? _this.container.options.gaTrackerName + '.' : 'Clappr.';
|
|
@@ -9569,7 +9675,8 @@
|
|
|
9569
9675
|
}
|
|
9570
9676
|
return _this;
|
|
9571
9677
|
}
|
|
9572
|
-
|
|
9678
|
+
_inherits(GoogleAnalytics, _ContainerPlugin);
|
|
9679
|
+
return _createClass(GoogleAnalytics, [{
|
|
9573
9680
|
key: "name",
|
|
9574
9681
|
get: function get() {
|
|
9575
9682
|
return 'google_analytics';
|
|
@@ -9578,7 +9685,7 @@
|
|
|
9578
9685
|
key: "supportedVersion",
|
|
9579
9686
|
get: function get() {
|
|
9580
9687
|
return {
|
|
9581
|
-
min: "0.
|
|
9688
|
+
min: "0.8.0"
|
|
9582
9689
|
};
|
|
9583
9690
|
}
|
|
9584
9691
|
}, {
|
|
@@ -9707,7 +9814,6 @@
|
|
|
9707
9814
|
_gaq.push(res);
|
|
9708
9815
|
}
|
|
9709
9816
|
}]);
|
|
9710
|
-
return GoogleAnalytics;
|
|
9711
9817
|
}(ContainerPlugin);
|
|
9712
9818
|
|
|
9713
9819
|
/* eslint-disable */
|
|
@@ -10008,39 +10114,27 @@
|
|
|
10008
10114
|
}
|
|
10009
10115
|
return result.join(' ');
|
|
10010
10116
|
};
|
|
10011
|
-
|
|
10012
10117
|
var index = {
|
|
10013
10118
|
Kibo: Kibo
|
|
10014
10119
|
};
|
|
10015
|
-
|
|
10016
10120
|
var css_248z$4 = ".media-control-notransition {\n transition: none !important; }\n\n.media-control[data-media-control] {\n position: absolute;\n width: 100%;\n height: 100%;\n z-index: 9999;\n pointer-events: none; }\n .media-control[data-media-control].dragging {\n pointer-events: auto;\n cursor: grabbing !important;\n cursor: url(\"closed-hand.cur\"), move; }\n .media-control[data-media-control].dragging * {\n cursor: grabbing !important;\n cursor: url(\"closed-hand.cur\"), move; }\n .media-control[data-media-control] .media-control-background[data-background] {\n position: absolute;\n height: 40%;\n width: 100%;\n bottom: 0;\n background: linear-gradient(transparent, rgba(0, 0, 0, 0.9));\n will-change: transform, opacity;\n transition: opacity 0.6s ease-out; }\n .media-control[data-media-control] .media-control-icon {\n line-height: 0;\n letter-spacing: 0;\n speak: none;\n color: #fff;\n opacity: 0.5;\n vertical-align: middle;\n text-align: left;\n transition: all 0.1s ease; }\n .media-control[data-media-control] .media-control-icon:hover {\n color: white;\n opacity: 0.75;\n text-shadow: rgba(255, 255, 255, 0.8) 0 0 5px; }\n .media-control[data-media-control].media-control-hide .media-control-background[data-background] {\n opacity: 0; }\n .media-control[data-media-control].media-control-hide .media-control-layer[data-controls] {\n transform: translateY(50px); }\n .media-control[data-media-control].media-control-hide .media-control-layer[data-controls] .bar-container[data-seekbar] .bar-scrubber[data-seekbar] {\n opacity: 0; }\n .media-control[data-media-control] .media-control-layer[data-controls] {\n position: absolute;\n transform: translateY(-7px);\n bottom: 0;\n width: 100%;\n height: 32px;\n font-size: 0;\n vertical-align: middle;\n pointer-events: auto;\n transition: bottom 0.4s ease-out; }\n .media-control[data-media-control] .media-control-layer[data-controls] .media-control-left-panel[data-media-control] {\n position: absolute;\n top: 0;\n left: 4px;\n height: 100%; }\n .media-control[data-media-control] .media-control-layer[data-controls] .media-control-center-panel[data-media-control] {\n height: 100%;\n text-align: center;\n line-height: 32px; }\n .media-control[data-media-control] .media-control-layer[data-controls] .media-control-right-panel[data-media-control] {\n position: absolute;\n top: 0;\n right: 4px;\n height: 100%; }\n .media-control[data-media-control] .media-control-layer[data-controls] button.media-control-button {\n background-color: transparent;\n border: 0;\n margin: 0 6px;\n padding: 0;\n cursor: pointer;\n display: inline-block;\n width: 32px;\n height: 100%; }\n .media-control[data-media-control] .media-control-layer[data-controls] button.media-control-button svg {\n width: 100%;\n height: 22px; }\n .media-control[data-media-control] .media-control-layer[data-controls] button.media-control-button svg path {\n fill: white; }\n .media-control[data-media-control] .media-control-layer[data-controls] button.media-control-button:focus {\n outline: none; }\n .media-control[data-media-control] .media-control-layer[data-controls] button.media-control-button[data-play] {\n float: left;\n height: 100%; }\n .media-control[data-media-control] .media-control-layer[data-controls] button.media-control-button[data-pause] {\n float: left;\n height: 100%; }\n .media-control[data-media-control] .media-control-layer[data-controls] button.media-control-button[data-stop] {\n float: left;\n height: 100%; }\n .media-control[data-media-control] .media-control-layer[data-controls] button.media-control-button[data-fullscreen] {\n float: right;\n background-color: transparent;\n border: 0;\n height: 100%; }\n .media-control[data-media-control] .media-control-layer[data-controls] button.media-control-button[data-hd-indicator] {\n background-color: transparent;\n border: 0;\n cursor: default;\n display: none;\n float: right;\n height: 100%; }\n .media-control[data-media-control] .media-control-layer[data-controls] button.media-control-button[data-hd-indicator].enabled {\n display: block;\n opacity: 1.0; }\n .media-control[data-media-control] .media-control-layer[data-controls] button.media-control-button[data-hd-indicator].enabled:hover {\n opacity: 1.0;\n text-shadow: none; }\n .media-control[data-media-control] .media-control-layer[data-controls] button.media-control-button[data-playpause] {\n float: left; }\n .media-control[data-media-control] .media-control-layer[data-controls] button.media-control-button[data-playstop] {\n float: left; }\n .media-control[data-media-control] .media-control-layer[data-controls] .media-control-indicator[data-position], .media-control[data-media-control] .media-control-layer[data-controls] .media-control-indicator[data-duration] {\n display: inline-block;\n font-size: 10px;\n color: white;\n cursor: default;\n line-height: 32px;\n position: relative; }\n .media-control[data-media-control] .media-control-layer[data-controls] .media-control-indicator[data-position] {\n margin: 0 6px 0 7px; }\n .media-control[data-media-control] .media-control-layer[data-controls] .media-control-indicator[data-duration] {\n color: rgba(255, 255, 255, 0.5);\n margin-right: 6px; }\n .media-control[data-media-control] .media-control-layer[data-controls] .media-control-indicator[data-duration]:before {\n content: \"|\";\n margin-right: 7px; }\n .media-control[data-media-control] .media-control-layer[data-controls] .bar-container[data-seekbar] {\n position: absolute;\n top: -20px;\n left: 0;\n display: inline-block;\n vertical-align: middle;\n width: 100%;\n height: 25px;\n cursor: pointer; }\n .media-control[data-media-control] .media-control-layer[data-controls] .bar-container[data-seekbar] .bar-background[data-seekbar] {\n width: 100%;\n height: 1px;\n position: relative;\n top: 12px;\n background-color: #666666; }\n .media-control[data-media-control] .media-control-layer[data-controls] .bar-container[data-seekbar] .bar-background[data-seekbar] .bar-fill-1[data-seekbar] {\n position: absolute;\n top: 0;\n left: 0;\n width: 0;\n height: 100%;\n background-color: #c2c2c2;\n transition: all 0.1s ease-out; }\n .media-control[data-media-control] .media-control-layer[data-controls] .bar-container[data-seekbar] .bar-background[data-seekbar] .bar-fill-2[data-seekbar] {\n position: absolute;\n top: 0;\n left: 0;\n width: 0;\n height: 100%;\n background-color: #005aff;\n transition: all 0.1s ease-out; }\n .media-control[data-media-control] .media-control-layer[data-controls] .bar-container[data-seekbar] .bar-background[data-seekbar] .bar-hover[data-seekbar] {\n opacity: 0;\n position: absolute;\n top: -3px;\n width: 5px;\n height: 7px;\n background-color: rgba(255, 255, 255, 0.5);\n transition: opacity 0.1s ease; }\n .media-control[data-media-control] .media-control-layer[data-controls] .bar-container[data-seekbar]:hover .bar-background[data-seekbar] .bar-hover[data-seekbar] {\n opacity: 1; }\n .media-control[data-media-control] .media-control-layer[data-controls] .bar-container[data-seekbar].seek-disabled {\n cursor: default; }\n .media-control[data-media-control] .media-control-layer[data-controls] .bar-container[data-seekbar].seek-disabled:hover .bar-background[data-seekbar] .bar-hover[data-seekbar] {\n opacity: 0; }\n .media-control[data-media-control] .media-control-layer[data-controls] .bar-container[data-seekbar] .bar-scrubber[data-seekbar] {\n position: absolute;\n transform: translateX(-50%);\n top: 2px;\n left: 0;\n width: 20px;\n height: 20px;\n opacity: 1;\n transition: all 0.1s ease-out; }\n .media-control[data-media-control] .media-control-layer[data-controls] .bar-container[data-seekbar] .bar-scrubber[data-seekbar] .bar-scrubber-icon[data-seekbar] {\n position: absolute;\n left: 6px;\n top: 6px;\n width: 8px;\n height: 8px;\n border-radius: 10px;\n box-shadow: 0 0 0 6px rgba(255, 255, 255, 0.2);\n background-color: white; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] {\n float: right;\n display: inline-block;\n height: 32px;\n cursor: pointer;\n margin: 0 6px;\n box-sizing: border-box; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .drawer-icon-container[data-volume] {\n float: left;\n bottom: 0; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .drawer-icon-container[data-volume] .drawer-icon[data-volume] {\n background-color: transparent;\n border: 0;\n box-sizing: content-box;\n width: 32px;\n height: 32px;\n opacity: 0.5; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .drawer-icon-container[data-volume] .drawer-icon[data-volume]:hover {\n opacity: 0.75; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .drawer-icon-container[data-volume] .drawer-icon[data-volume] svg {\n height: 24px;\n position: relative;\n top: 3px; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .drawer-icon-container[data-volume] .drawer-icon[data-volume] svg path {\n fill: white; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .drawer-icon-container[data-volume] .drawer-icon[data-volume].muted svg {\n margin-left: 2px; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .bar-container[data-volume] {\n float: left;\n position: relative;\n overflow: hidden;\n top: 6px;\n width: 42px;\n height: 18px;\n padding: 3px 0;\n transition: width .2s ease-out; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .bar-container[data-volume] .bar-background[data-volume] {\n height: 1px;\n position: relative;\n top: 7px;\n margin: 0 3px;\n background-color: #666666; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .bar-container[data-volume] .bar-background[data-volume] .bar-fill-1[data-volume] {\n position: absolute;\n top: 0;\n left: 0;\n width: 0;\n height: 100%;\n background-color: #c2c2c2;\n transition: all 0.1s ease-out; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .bar-container[data-volume] .bar-background[data-volume] .bar-fill-2[data-volume] {\n position: absolute;\n top: 0;\n left: 0;\n width: 0;\n height: 100%;\n background-color: #005aff;\n transition: all 0.1s ease-out; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .bar-container[data-volume] .bar-background[data-volume] .bar-hover[data-volume] {\n opacity: 0;\n position: absolute;\n top: -3px;\n width: 5px;\n height: 7px;\n background-color: rgba(255, 255, 255, 0.5);\n transition: opacity 0.1s ease; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .bar-container[data-volume] .bar-scrubber[data-volume] {\n position: absolute;\n transform: translateX(-50%);\n top: 0px;\n left: 0;\n width: 20px;\n height: 20px;\n opacity: 1;\n transition: all 0.1s ease-out; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .bar-container[data-volume] .bar-scrubber[data-volume] .bar-scrubber-icon[data-volume] {\n position: absolute;\n left: 6px;\n top: 6px;\n width: 8px;\n height: 8px;\n border-radius: 10px;\n box-shadow: 0 0 0 6px rgba(255, 255, 255, 0.2);\n background-color: white; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .bar-container[data-volume] .segmented-bar-element[data-volume] {\n float: left;\n width: 4px;\n padding-left: 2px;\n height: 12px;\n opacity: 0.5;\n box-shadow: inset 2px 0 0 white;\n transition: transform .2s ease-out; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .bar-container[data-volume] .segmented-bar-element[data-volume].fill {\n box-shadow: inset 2px 0 0 #fff;\n opacity: 1; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .bar-container[data-volume] .segmented-bar-element[data-volume]:nth-of-type(1) {\n padding-left: 0; }\n .media-control[data-media-control] .media-control-layer[data-controls] .drawer-container[data-volume] .bar-container[data-volume] .segmented-bar-element[data-volume]:hover {\n transform: scaleY(1.5); }\n .media-control[data-media-control].w320 .media-control-layer[data-controls] .drawer-container[data-volume] .bar-container[data-volume].volume-bar-hide {\n width: 0;\n height: 12px;\n top: 9px;\n padding: 0; }\n";
|
|
10017
|
-
|
|
10018
10121
|
var mediaControlHTML = "<div class=\"media-control-background\" data-background></div>\n<div class=\"media-control-layer\" data-controls>\n <% var renderBar = function(name) { %>\n <div class=\"bar-container\" data-<%= name %>>\n <div class=\"bar-background\" data-<%= name %>>\n <div class=\"bar-fill-1\" data-<%= name %>></div>\n <div class=\"bar-fill-2\" data-<%= name %>></div>\n <div class=\"bar-hover\" data-<%= name %>></div>\n </div>\n <div class=\"bar-scrubber\" data-<%= name %>>\n <div class=\"bar-scrubber-icon\" data-<%= name %>></div>\n </div>\n </div>\n <% }; %>\n <% var renderSegmentedBar = function(name, segments) {\n segments = segments || 10; %>\n <div class=\"bar-container\" data-<%= name %>>\n <% for (var i = 0; i < segments; i++) { %>\n <div class=\"segmented-bar-element\" data-<%= name %>></div>\n <% } %>\n </div>\n <% }; %>\n <% var renderDrawer = function(name, renderContent) { %>\n <div class=\"drawer-container\" data-<%= name %>>\n <div class=\"drawer-icon-container\" data-<%= name %>>\n <div class=\"drawer-icon media-control-icon\" data-<%= name %>></div>\n <span class=\"drawer-text\" data-<%= name %>></span>\n </div>\n <% renderContent(name); %>\n </div>\n <% }; %>\n <% var renderIndicator = function(name) { %>\n <div class=\"media-control-indicator\" data-<%= name %>></div>\n <% }; %>\n <% var renderButton = function(name) { %>\n <button type=\"button\" class=\"media-control-button media-control-icon\" data-<%= name %> aria-label=\"<%= name %>\"></button>\n <% }; %>\n <% var templates = {\n bar: renderBar,\n segmentedBar: renderSegmentedBar,\n };\n var render = function(settingsList) {\n settingsList.forEach(function(setting) {\n if(setting === \"seekbar\") {\n renderBar(setting);\n } else if (setting === \"volume\") {\n renderDrawer(setting, settings.volumeBarTemplate ? templates[settings.volumeBarTemplate] : function(name) { return renderSegmentedBar(name); });\n } else if (setting === \"duration\" || setting === \"position\") {\n renderIndicator(setting);\n } else {\n renderButton(setting);\n }\n });\n }; %>\n <% if (settings.default && settings.default.length) { %>\n <div class=\"media-control-center-panel\" data-media-control>\n <% render(settings.default); %>\n </div>\n <% } %>\n <% if (settings.left && settings.left.length) { %>\n <div class=\"media-control-left-panel\" data-media-control>\n <% render(settings.left); %>\n </div>\n <% } %>\n <% if (settings.right && settings.right.length) { %>\n <div class=\"media-control-right-panel\" data-media-control>\n <% render(settings.right); %>\n </div>\n <% } %>\n</div>\n";
|
|
10019
|
-
|
|
10020
10122
|
var stopIcon = "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 16 16\">\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" fill=\"#010101\" d=\"M1.712 1.24h12.6v13.52h-12.6z\"/>\n</svg>";
|
|
10021
|
-
|
|
10022
10123
|
var volumeIcon = "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 16 16\">\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" fill=\"#010101\" d=\"M11.5 11h-.002v1.502L7.798 10H4.5V6h3.297l3.7-2.502V4.5h.003V11zM11 4.49L7.953 6.5H5v3h2.953L11 11.51V4.49z\"/>\n</svg>";
|
|
10023
|
-
|
|
10024
10124
|
var volumeMuteIcon = "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 16 16\">\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" fill=\"#010101\" d=\"M9.75 11.51L6.7 9.5H3.75v-3H6.7L9.75 4.49v.664l.497.498V3.498L6.547 6H3.248v4h3.296l3.7 2.502v-2.154l-.497.5v.662zm3-5.165L12.404 6l-1.655 1.653L9.093 6l-.346.345L10.402 8 8.747 9.654l.346.347 1.655-1.653L12.403 10l.348-.346L11.097 8l1.655-1.655z\"/>\n</svg>";
|
|
10025
|
-
|
|
10026
10125
|
var fullscreenIcon = "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 16 16\">\n <path fill=\"#010101\" d=\"M7.156 8L4 11.156V8.5H3V13h4.5v-1H4.844L8 8.844 7.156 8zM8.5 3v1h2.657L8 7.157 8.846 8 12 4.844V7.5h1V3H8.5z\"/>\n</svg>";
|
|
10027
|
-
|
|
10028
10126
|
var exitFullscreenIcon = "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 16 16\">\n <path fill=\"#010101\" d=\"M13.5 3.344l-.844-.844L9.5 5.656V3h-1v4.5H13v-1h-2.656L13.5 3.344zM3 9.5h2.656L2.5 12.656l.844.844L6.5 10.344V13h1V8.5H3v1z\"/>\n</svg>";
|
|
10029
|
-
|
|
10030
10127
|
var hdIcon = "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 16 16\">\n <path fill=\"#010101\" d=\"M5.375 7.062H2.637V4.26H.502v7.488h2.135V8.9h2.738v2.848h2.133V4.26H5.375v2.802zm5.97-2.81h-2.84v7.496h2.798c2.65 0 4.195-1.607 4.195-3.77v-.022c0-2.162-1.523-3.704-4.154-3.704zm2.06 3.758c0 1.21-.81 1.896-2.03 1.896h-.83V6.093h.83c1.22 0 2.03.696 2.03 1.896v.02z\"/>\n</svg>";
|
|
10031
|
-
|
|
10032
10128
|
var Config = Utils.Config,
|
|
10033
10129
|
Fullscreen = Utils.Fullscreen,
|
|
10034
10130
|
formatTime$1 = Utils.formatTime,
|
|
10035
10131
|
extend = Utils.extend,
|
|
10036
10132
|
removeArrayItem = Utils.removeArrayItem;
|
|
10037
10133
|
var MediaControl$1 = /*#__PURE__*/function (_UICorePlugin) {
|
|
10038
|
-
_inherits(MediaControl, _UICorePlugin);
|
|
10039
|
-
var _super = _createSuper(MediaControl);
|
|
10040
10134
|
function MediaControl(core) {
|
|
10041
10135
|
var _this;
|
|
10042
10136
|
_classCallCheck(this, MediaControl);
|
|
10043
|
-
_this =
|
|
10137
|
+
_this = _callSuper(this, MediaControl, [core]);
|
|
10044
10138
|
_this.persistConfig = _this.options.persistConfig;
|
|
10045
10139
|
_this.currentPositionValue = null;
|
|
10046
10140
|
_this.currentDurationValue = null;
|
|
@@ -10055,7 +10149,7 @@
|
|
|
10055
10149
|
_this.kibo = new Kibo(_this.options.focusElement);
|
|
10056
10150
|
_this.bindKeyEvents();
|
|
10057
10151
|
if (_this.container) {
|
|
10058
|
-
if (
|
|
10152
|
+
if (!$.isEmptyObject(_this.container.settings)) _this.settings = $.extend({}, _this.container.settings);
|
|
10059
10153
|
} else {
|
|
10060
10154
|
_this.settings = {};
|
|
10061
10155
|
}
|
|
@@ -10067,11 +10161,12 @@
|
|
|
10067
10161
|
_this.updateDragHandler = function (event) {
|
|
10068
10162
|
return _this.updateDrag(event);
|
|
10069
10163
|
};
|
|
10070
|
-
|
|
10071
|
-
|
|
10164
|
+
$(document).bind('mouseup', _this.stopDragHandler);
|
|
10165
|
+
$(document).bind('mousemove', _this.updateDragHandler);
|
|
10072
10166
|
return _this;
|
|
10073
10167
|
}
|
|
10074
|
-
|
|
10168
|
+
_inherits(MediaControl, _UICorePlugin);
|
|
10169
|
+
return _createClass(MediaControl, [{
|
|
10075
10170
|
key: "name",
|
|
10076
10171
|
get: function get() {
|
|
10077
10172
|
return 'media_control';
|
|
@@ -10080,7 +10175,7 @@
|
|
|
10080
10175
|
key: "supportedVersion",
|
|
10081
10176
|
get: function get() {
|
|
10082
10177
|
return {
|
|
10083
|
-
min: "0.
|
|
10178
|
+
min: "0.8.0"
|
|
10084
10179
|
};
|
|
10085
10180
|
}
|
|
10086
10181
|
}, {
|
|
@@ -10625,7 +10720,7 @@
|
|
|
10625
10720
|
}, {
|
|
10626
10721
|
key: "getSettings",
|
|
10627
10722
|
value: function getSettings() {
|
|
10628
|
-
return
|
|
10723
|
+
return $.extend(true, {}, this.container && this.container.settings);
|
|
10629
10724
|
}
|
|
10630
10725
|
}, {
|
|
10631
10726
|
key: "highDefinitionUpdate",
|
|
@@ -10775,13 +10870,13 @@
|
|
|
10775
10870
|
}, {
|
|
10776
10871
|
key: "applyButtonStyle",
|
|
10777
10872
|
value: function applyButtonStyle(element) {
|
|
10778
|
-
this.buttonsColor && element &&
|
|
10873
|
+
this.buttonsColor && element && $(element).find('svg path').css('fill', this.buttonsColor);
|
|
10779
10874
|
}
|
|
10780
10875
|
}, {
|
|
10781
10876
|
key: "destroy",
|
|
10782
10877
|
value: function destroy() {
|
|
10783
|
-
|
|
10784
|
-
|
|
10878
|
+
$(document).unbind('mouseup', this.stopDragHandler);
|
|
10879
|
+
$(document).unbind('mousemove', this.updateDragHandler);
|
|
10785
10880
|
this.unbindKeyEvents();
|
|
10786
10881
|
this.stopListening();
|
|
10787
10882
|
_get(_getPrototypeOf(MediaControl.prototype), "destroy", this).call(this);
|
|
@@ -10851,23 +10946,17 @@
|
|
|
10851
10946
|
return this;
|
|
10852
10947
|
}
|
|
10853
10948
|
}]);
|
|
10854
|
-
return MediaControl;
|
|
10855
10949
|
}(UICorePlugin);
|
|
10856
10950
|
MediaControl$1.extend = function (properties) {
|
|
10857
10951
|
return extend(MediaControl$1, properties);
|
|
10858
10952
|
};
|
|
10859
|
-
|
|
10860
10953
|
var posterHTML = "<div class=\"play-wrapper\" data-poster></div>\n";
|
|
10861
|
-
|
|
10862
10954
|
var css_248z$3 = ".player-poster[data-poster] {\n display: flex;\n justify-content: center;\n align-items: center;\n position: absolute;\n height: 100%;\n width: 100%;\n z-index: 998;\n top: 0;\n left: 0;\n background-color: transparent;\n background-size: cover;\n background-repeat: no-repeat;\n background-position: 50% 50%; }\n .player-poster[data-poster].clickable {\n cursor: pointer; }\n .player-poster[data-poster]:hover .play-wrapper[data-poster] {\n opacity: 1; }\n .player-poster[data-poster] .play-wrapper[data-poster] {\n width: 100%;\n height: 25%;\n margin: 0 auto;\n opacity: 0.75;\n transition: opacity 0.1s ease; }\n .player-poster[data-poster] .play-wrapper[data-poster] svg {\n height: 100%; }\n .player-poster[data-poster] .play-wrapper[data-poster] svg path {\n fill: #fff; }\n";
|
|
10863
|
-
|
|
10864
10955
|
var PosterPlugin = /*#__PURE__*/function (_UIContainerPlugin) {
|
|
10865
|
-
_inherits(PosterPlugin, _UIContainerPlugin);
|
|
10866
|
-
var _super = _createSuper(PosterPlugin);
|
|
10867
10956
|
function PosterPlugin(container) {
|
|
10868
10957
|
var _this;
|
|
10869
10958
|
_classCallCheck(this, PosterPlugin);
|
|
10870
|
-
_this =
|
|
10959
|
+
_this = _callSuper(this, PosterPlugin, [container]);
|
|
10871
10960
|
_this.hasStartedPlaying = false;
|
|
10872
10961
|
_this.playRequested = false;
|
|
10873
10962
|
_this.render();
|
|
@@ -10876,7 +10965,8 @@
|
|
|
10876
10965
|
}, 0);
|
|
10877
10966
|
return _this;
|
|
10878
10967
|
}
|
|
10879
|
-
|
|
10968
|
+
_inherits(PosterPlugin, _UIContainerPlugin);
|
|
10969
|
+
return _createClass(PosterPlugin, [{
|
|
10880
10970
|
key: "name",
|
|
10881
10971
|
get: function get() {
|
|
10882
10972
|
return 'poster';
|
|
@@ -10885,7 +10975,7 @@
|
|
|
10885
10975
|
key: "supportedVersion",
|
|
10886
10976
|
get: function get() {
|
|
10887
10977
|
return {
|
|
10888
|
-
min: "0.
|
|
10978
|
+
min: "0.8.0"
|
|
10889
10979
|
};
|
|
10890
10980
|
}
|
|
10891
10981
|
}, {
|
|
@@ -11059,21 +11149,15 @@
|
|
|
11059
11149
|
this.container.playback && this.container.playback.$el && this.container.playback.$el[0] && this.container.playback.$el[0].removeAttribute && this.container.playback.$el[0].removeAttribute('poster');
|
|
11060
11150
|
}
|
|
11061
11151
|
}]);
|
|
11062
|
-
return PosterPlugin;
|
|
11063
11152
|
}(UIContainerPlugin);
|
|
11064
|
-
|
|
11065
11153
|
var seekTimeHTML = "<span data-seek-time></span>\n<span data-duration></span>\n";
|
|
11066
|
-
|
|
11067
11154
|
var css_248z$2 = ".seek-time[data-seek-time] {\n position: absolute;\n white-space: nowrap;\n height: 20px;\n line-height: 20px;\n font-size: 0;\n left: -100%;\n bottom: 55px;\n background-color: rgba(2, 2, 2, 0.5);\n z-index: 9999;\n transition: opacity 0.1s ease; }\n .seek-time[data-seek-time].hidden[data-seek-time] {\n opacity: 0; }\n .seek-time[data-seek-time] [data-seek-time] {\n display: inline-block;\n color: white;\n font-size: 10px;\n padding-left: 7px;\n padding-right: 7px;\n vertical-align: top; }\n .seek-time[data-seek-time] [data-duration] {\n display: inline-block;\n color: rgba(255, 255, 255, 0.5);\n font-size: 10px;\n padding-right: 7px;\n vertical-align: top; }\n .seek-time[data-seek-time] [data-duration]:before {\n content: \"|\";\n margin-right: 7px; }\n";
|
|
11068
|
-
|
|
11069
11155
|
var formatTime = Utils.formatTime;
|
|
11070
11156
|
var SeekTime$1 = /*#__PURE__*/function (_UICorePlugin) {
|
|
11071
|
-
_inherits(SeekTime, _UICorePlugin);
|
|
11072
|
-
var _super = _createSuper(SeekTime);
|
|
11073
11157
|
function SeekTime(core) {
|
|
11074
11158
|
var _this;
|
|
11075
11159
|
_classCallCheck(this, SeekTime);
|
|
11076
|
-
_this =
|
|
11160
|
+
_this = _callSuper(this, SeekTime, [core]);
|
|
11077
11161
|
_this.hoveringOverSeekBar = false;
|
|
11078
11162
|
_this.hoverPosition = null;
|
|
11079
11163
|
_this.duration = null;
|
|
@@ -11084,7 +11168,8 @@
|
|
|
11084
11168
|
}
|
|
11085
11169
|
return _this;
|
|
11086
11170
|
}
|
|
11087
|
-
|
|
11171
|
+
_inherits(SeekTime, _UICorePlugin);
|
|
11172
|
+
return _createClass(SeekTime, [{
|
|
11088
11173
|
key: "name",
|
|
11089
11174
|
get: function get() {
|
|
11090
11175
|
return 'seek_time';
|
|
@@ -11093,7 +11178,7 @@
|
|
|
11093
11178
|
key: "supportedVersion",
|
|
11094
11179
|
get: function get() {
|
|
11095
11180
|
return {
|
|
11096
|
-
min: "0.
|
|
11181
|
+
min: "0.8.0"
|
|
11097
11182
|
};
|
|
11098
11183
|
}
|
|
11099
11184
|
}, {
|
|
@@ -11267,20 +11352,14 @@
|
|
|
11267
11352
|
this.update();
|
|
11268
11353
|
}
|
|
11269
11354
|
}]);
|
|
11270
|
-
return SeekTime;
|
|
11271
11355
|
}(UICorePlugin);
|
|
11272
|
-
|
|
11273
11356
|
var spinnerHTML = "<div data-bounce1></div><div data-bounce2></div><div data-bounce3></div>\n";
|
|
11274
|
-
|
|
11275
11357
|
var css_248z$1 = ".spinner-three-bounce[data-spinner] {\n position: absolute;\n margin: 0 auto;\n width: 70px;\n text-align: center;\n z-index: 999;\n left: 0;\n right: 0;\n margin-left: auto;\n margin-right: auto;\n /* center vertically */\n top: 50%;\n transform: translateY(-50%); }\n .spinner-three-bounce[data-spinner] > div {\n width: 18px;\n height: 18px;\n background-color: #FFFFFF;\n border-radius: 100%;\n display: inline-block;\n animation: bouncedelay 1.4s infinite ease-in-out;\n /* Prevent first frame from flickering when animation starts */\n animation-fill-mode: both; }\n .spinner-three-bounce[data-spinner] [data-bounce1] {\n animation-delay: -0.32s; }\n .spinner-three-bounce[data-spinner] [data-bounce2] {\n animation-delay: -0.16s; }\n\n@keyframes bouncedelay {\n 0%, 80%, 100% {\n transform: scale(0); }\n 40% {\n transform: scale(1); } }\n";
|
|
11276
|
-
|
|
11277
11358
|
var SpinnerThreeBouncePlugin = /*#__PURE__*/function (_UIContainerPlugin) {
|
|
11278
|
-
_inherits(SpinnerThreeBouncePlugin, _UIContainerPlugin);
|
|
11279
|
-
var _super = _createSuper(SpinnerThreeBouncePlugin);
|
|
11280
11359
|
function SpinnerThreeBouncePlugin(container) {
|
|
11281
11360
|
var _this;
|
|
11282
11361
|
_classCallCheck(this, SpinnerThreeBouncePlugin);
|
|
11283
|
-
_this =
|
|
11362
|
+
_this = _callSuper(this, SpinnerThreeBouncePlugin, [container]);
|
|
11284
11363
|
_this.template = tmpl(spinnerHTML);
|
|
11285
11364
|
_this.showTimeout = null;
|
|
11286
11365
|
_this.listenTo(_this.container, Events.CONTAINER_STATE_BUFFERING, _this.onBuffering);
|
|
@@ -11291,7 +11370,8 @@
|
|
|
11291
11370
|
_this.render();
|
|
11292
11371
|
return _this;
|
|
11293
11372
|
}
|
|
11294
|
-
|
|
11373
|
+
_inherits(SpinnerThreeBouncePlugin, _UIContainerPlugin);
|
|
11374
|
+
return _createClass(SpinnerThreeBouncePlugin, [{
|
|
11295
11375
|
key: "name",
|
|
11296
11376
|
get: function get() {
|
|
11297
11377
|
return 'spinner';
|
|
@@ -11300,7 +11380,7 @@
|
|
|
11300
11380
|
key: "supportedVersion",
|
|
11301
11381
|
get: function get() {
|
|
11302
11382
|
return {
|
|
11303
|
-
min: "0.
|
|
11383
|
+
min: "0.8.0"
|
|
11304
11384
|
};
|
|
11305
11385
|
}
|
|
11306
11386
|
}, {
|
|
@@ -11357,22 +11437,19 @@
|
|
|
11357
11437
|
return this;
|
|
11358
11438
|
}
|
|
11359
11439
|
}]);
|
|
11360
|
-
return SpinnerThreeBouncePlugin;
|
|
11361
11440
|
}(UIContainerPlugin);
|
|
11362
|
-
|
|
11363
11441
|
var StatsPlugin = /*#__PURE__*/function (_ContainerPlugin) {
|
|
11364
|
-
_inherits(StatsPlugin, _ContainerPlugin);
|
|
11365
|
-
var _super = _createSuper(StatsPlugin);
|
|
11366
11442
|
function StatsPlugin(container) {
|
|
11367
11443
|
var _this;
|
|
11368
11444
|
_classCallCheck(this, StatsPlugin);
|
|
11369
|
-
_this =
|
|
11445
|
+
_this = _callSuper(this, StatsPlugin, [container]);
|
|
11370
11446
|
_this.setInitialAttrs();
|
|
11371
11447
|
_this.reportInterval = _this.options.reportInterval || 5000;
|
|
11372
11448
|
_this.state = 'IDLE';
|
|
11373
11449
|
return _this;
|
|
11374
11450
|
}
|
|
11375
|
-
|
|
11451
|
+
_inherits(StatsPlugin, _ContainerPlugin);
|
|
11452
|
+
return _createClass(StatsPlugin, [{
|
|
11376
11453
|
key: "name",
|
|
11377
11454
|
get: function get() {
|
|
11378
11455
|
return 'stats';
|
|
@@ -11381,7 +11458,7 @@
|
|
|
11381
11458
|
key: "supportedVersion",
|
|
11382
11459
|
get: function get() {
|
|
11383
11460
|
return {
|
|
11384
|
-
min: "0.
|
|
11461
|
+
min: "0.8.0"
|
|
11385
11462
|
};
|
|
11386
11463
|
}
|
|
11387
11464
|
}, {
|
|
@@ -11461,7 +11538,7 @@
|
|
|
11461
11538
|
}, {
|
|
11462
11539
|
key: "onStatsAdd",
|
|
11463
11540
|
value: function onStatsAdd(metric) {
|
|
11464
|
-
|
|
11541
|
+
$.extend(this.externalMetrics, metric);
|
|
11465
11542
|
}
|
|
11466
11543
|
}, {
|
|
11467
11544
|
key: "getStats",
|
|
@@ -11472,7 +11549,7 @@
|
|
|
11472
11549
|
rebufferingTime: this.isRebuffering() ? this.rebufferingTime + this.getRebufferingTime() : this.rebufferingTime,
|
|
11473
11550
|
watchingTime: this.isRebuffering() ? this.getWatchingTime() - this.getRebufferingTime() : this.getWatchingTime()
|
|
11474
11551
|
};
|
|
11475
|
-
|
|
11552
|
+
$.extend(metrics, this.externalMetrics);
|
|
11476
11553
|
return metrics;
|
|
11477
11554
|
}
|
|
11478
11555
|
}, {
|
|
@@ -11481,24 +11558,19 @@
|
|
|
11481
11558
|
this.container.statsReport(this.getStats());
|
|
11482
11559
|
}
|
|
11483
11560
|
}]);
|
|
11484
|
-
return StatsPlugin;
|
|
11485
11561
|
}(ContainerPlugin);
|
|
11486
|
-
|
|
11487
11562
|
var watermarkHTML = "<div class=\"clappr-watermark\" data-watermark data-watermark-<%=position %>>\n<% if(typeof imageLink !== 'undefined') { %>\n<a target=\"_blank\" href=\"<%= imageLink %>\">\n<% } %>\n<img src=\"<%= imageUrl %>\">\n<% if(typeof imageLink !== 'undefined') { %>\n</a>\n<% } %>\n</div>\n";
|
|
11488
|
-
|
|
11489
11563
|
var css_248z = ".clappr-watermark[data-watermark] {\n position: absolute;\n min-width: 70px;\n max-width: 200px;\n width: 12%;\n text-align: center;\n z-index: 10; }\n\n.clappr-watermark[data-watermark] a {\n outline: none;\n cursor: pointer; }\n\n.clappr-watermark[data-watermark] img {\n max-width: 100%; }\n\n.clappr-watermark[data-watermark-bottom-left] {\n bottom: 10px;\n left: 10px; }\n\n.clappr-watermark[data-watermark-bottom-right] {\n bottom: 10px;\n right: 42px; }\n\n.clappr-watermark[data-watermark-top-left] {\n top: 10px;\n left: 10px; }\n\n.clappr-watermark[data-watermark-top-right] {\n top: 10px;\n right: 37px; }\n";
|
|
11490
|
-
|
|
11491
11564
|
var WaterMarkPlugin = /*#__PURE__*/function (_UIContainerPlugin) {
|
|
11492
|
-
_inherits(WaterMarkPlugin, _UIContainerPlugin);
|
|
11493
|
-
var _super = _createSuper(WaterMarkPlugin);
|
|
11494
11565
|
function WaterMarkPlugin(container) {
|
|
11495
11566
|
var _this;
|
|
11496
11567
|
_classCallCheck(this, WaterMarkPlugin);
|
|
11497
|
-
_this =
|
|
11568
|
+
_this = _callSuper(this, WaterMarkPlugin, [container]);
|
|
11498
11569
|
_this.configure();
|
|
11499
11570
|
return _this;
|
|
11500
11571
|
}
|
|
11501
|
-
|
|
11572
|
+
_inherits(WaterMarkPlugin, _UIContainerPlugin);
|
|
11573
|
+
return _createClass(WaterMarkPlugin, [{
|
|
11502
11574
|
key: "name",
|
|
11503
11575
|
get: function get() {
|
|
11504
11576
|
return 'watermark';
|
|
@@ -11507,7 +11579,7 @@
|
|
|
11507
11579
|
key: "supportedVersion",
|
|
11508
11580
|
get: function get() {
|
|
11509
11581
|
return {
|
|
11510
|
-
min: "0.
|
|
11582
|
+
min: "0.8.0"
|
|
11511
11583
|
};
|
|
11512
11584
|
}
|
|
11513
11585
|
}, {
|
|
@@ -11562,7 +11634,6 @@
|
|
|
11562
11634
|
return this;
|
|
11563
11635
|
}
|
|
11564
11636
|
}]);
|
|
11565
|
-
return WaterMarkPlugin;
|
|
11566
11637
|
}(UIContainerPlugin);
|
|
11567
11638
|
var Plugins = {
|
|
11568
11639
|
ClickToPause: ClickToPausePlugin,
|
|
@@ -11580,7 +11651,7 @@
|
|
|
11580
11651
|
WaterMark: WaterMarkPlugin
|
|
11581
11652
|
};
|
|
11582
11653
|
|
|
11583
|
-
var version = "0.
|
|
11654
|
+
var version = "0.7.0";
|
|
11584
11655
|
for (var _i = 0, _Object$values = Object.values(Plugins); _i < _Object$values.length; _i++) {
|
|
11585
11656
|
var plugin = _Object$values[_i];
|
|
11586
11657
|
Loader.registerPlugin(plugin);
|