@mjhls/mjh-framework 1.0.269 → 1.0.270
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/README.md +171 -171
- package/dist/cjs/DeckContent.js +9 -9
- package/dist/cjs/DeckQueue.js +1 -1
- package/dist/cjs/{GridContent-524f2ad8.js → GridContent-81563bbb.js} +2 -2
- package/dist/cjs/GridContent.js +2 -2
- package/dist/cjs/IssueContentDeck.js +1 -1
- package/dist/cjs/IssueDeck.js +1 -1
- package/dist/cjs/MasterDeck.js +9 -9
- package/dist/cjs/{Normal-6c0b2764.js → Normal-05dd6f72.js} +31 -31
- package/dist/cjs/PublicationDeck.js +1 -1
- package/dist/cjs/QueueDeckExpanded.js +1 -1
- package/dist/cjs/{TaxonomyCard-b5074d6e.js → TaxonomyCard-e3566492.js} +1 -1
- package/dist/cjs/TaxonomyCard.js +2 -2
- package/dist/cjs/TemplateNormal.js +1 -1
- package/dist/cjs/ThumbnailCard.js +1 -1
- package/dist/cjs/VideoSeriesListing.js +1 -2
- package/dist/cjs/{YoutubeGroup-78e6bcc3.js → YoutubeGroup-94e6efea.js} +437 -5
- package/dist/cjs/YoutubeGroup.js +1 -2
- package/dist/cjs/{index-39beccb3.js → index-be0c82be.js} +1 -2
- package/dist/cjs/index.js +529 -542
- package/dist/esm/DeckContent.js +9 -9
- package/dist/esm/DeckQueue.js +1 -1
- package/dist/esm/{GridContent-f4fd38a7.js → GridContent-b2edf91a.js} +1 -1
- package/dist/esm/GridContent.js +2 -2
- package/dist/esm/IssueContentDeck.js +1 -1
- package/dist/esm/IssueDeck.js +1 -1
- package/dist/esm/MasterDeck.js +9 -9
- package/dist/esm/{Normal-b7aa5dce.js → Normal-ccc2f7f8.js} +31 -31
- package/dist/esm/PublicationDeck.js +1 -1
- package/dist/esm/QueueDeckExpanded.js +1 -1
- package/dist/esm/{TaxonomyCard-ee1a22ae.js → TaxonomyCard-2d0ab635.js} +1 -1
- package/dist/esm/TaxonomyCard.js +2 -2
- package/dist/esm/TemplateNormal.js +1 -1
- package/dist/esm/ThumbnailCard.js +1 -1
- package/dist/esm/VideoSeriesListing.js +1 -2
- package/dist/esm/{YoutubeGroup-a87b8967.js → YoutubeGroup-f59297bb.js} +437 -5
- package/dist/esm/YoutubeGroup.js +1 -2
- package/dist/esm/{index-3849e3fe.js → index-73819142.js} +1 -2
- package/dist/esm/index.js +532 -545
- package/package.json +103 -103
package/dist/cjs/index.js
CHANGED
|
@@ -26,7 +26,7 @@ var Link = _interopDefault(require('next/link'));
|
|
|
26
26
|
var Router = require('next/router');
|
|
27
27
|
var Router__default = _interopDefault(Router);
|
|
28
28
|
require('react-dom');
|
|
29
|
-
var index$1 = require('./index-
|
|
29
|
+
var index$1 = require('./index-be0c82be.js');
|
|
30
30
|
require('./index-fa0fb52c.js');
|
|
31
31
|
var entities = require('./entities-310b46ee.js');
|
|
32
32
|
var slicedToArray = require('./slicedToArray-e38fb29d.js');
|
|
@@ -35,14 +35,13 @@ require('./promise-b96c61f8.js');
|
|
|
35
35
|
require('./ADInfeed-0da6acd4.js');
|
|
36
36
|
var DeckContent = require('./DeckContent.js');
|
|
37
37
|
require('./get-1f91592f.js');
|
|
38
|
-
var GridContent = require('./GridContent-
|
|
38
|
+
var GridContent = require('./GridContent-81563bbb.js');
|
|
39
39
|
var DeckQueue = require('./DeckQueue.js');
|
|
40
40
|
require('react-bootstrap/Media');
|
|
41
41
|
var ThumbnailCard = require('./ThumbnailCard.js');
|
|
42
|
-
var TaxonomyCard = require('./TaxonomyCard-
|
|
42
|
+
var TaxonomyCard = require('./TaxonomyCard-e3566492.js');
|
|
43
43
|
var GroupDeck = require('./GroupDeck.js');
|
|
44
|
-
var YoutubeGroup = require('./YoutubeGroup-
|
|
45
|
-
require('smoothscroll-polyfill');
|
|
44
|
+
var YoutubeGroup = require('./YoutubeGroup-94e6efea.js');
|
|
46
45
|
var reactBootstrap = require('react-bootstrap');
|
|
47
46
|
var QueueDeckExpanded = require('./QueueDeckExpanded.js');
|
|
48
47
|
var index_esm = require('./index.esm-340d3792.js');
|
|
@@ -54,7 +53,7 @@ var IssueDeck = require('./IssueDeck.js');
|
|
|
54
53
|
require('react-bootstrap/Badge');
|
|
55
54
|
var IssueContentDeck = require('./IssueContentDeck.js');
|
|
56
55
|
var Spinner = _interopDefault(require('react-bootstrap/Spinner'));
|
|
57
|
-
var TemplateNormal = require('./Normal-
|
|
56
|
+
var TemplateNormal = require('./Normal-05dd6f72.js');
|
|
58
57
|
require('react-bootstrap/ListGroup');
|
|
59
58
|
var Head = _interopDefault(require('next/head'));
|
|
60
59
|
var Accordion = _interopDefault(require('react-bootstrap/Accordion'));
|
|
@@ -3291,18 +3290,21 @@ var Slideshow = function Slideshow(_ref) {
|
|
|
3291
3290
|
);
|
|
3292
3291
|
};
|
|
3293
3292
|
|
|
3294
|
-
|
|
3295
|
-
|
|
3296
|
-
|
|
3293
|
+
var isArray = Array.isArray;
|
|
3294
|
+
var keyList = Object.keys;
|
|
3295
|
+
var hasProp = Object.prototype.hasOwnProperty;
|
|
3297
3296
|
|
|
3298
3297
|
var fastDeepEqual = function equal(a, b) {
|
|
3299
3298
|
if (a === b) return true;
|
|
3300
3299
|
|
|
3301
3300
|
if (a && b && typeof a == 'object' && typeof b == 'object') {
|
|
3302
|
-
|
|
3301
|
+
var arrA = isArray(a)
|
|
3302
|
+
, arrB = isArray(b)
|
|
3303
|
+
, i
|
|
3304
|
+
, length
|
|
3305
|
+
, key;
|
|
3303
3306
|
|
|
3304
|
-
|
|
3305
|
-
if (Array.isArray(a)) {
|
|
3307
|
+
if (arrA && arrB) {
|
|
3306
3308
|
length = a.length;
|
|
3307
3309
|
if (length != b.length) return false;
|
|
3308
3310
|
for (i = length; i-- !== 0;)
|
|
@@ -3310,29 +3312,35 @@ var fastDeepEqual = function equal(a, b) {
|
|
|
3310
3312
|
return true;
|
|
3311
3313
|
}
|
|
3312
3314
|
|
|
3315
|
+
if (arrA != arrB) return false;
|
|
3313
3316
|
|
|
3317
|
+
var dateA = a instanceof Date
|
|
3318
|
+
, dateB = b instanceof Date;
|
|
3319
|
+
if (dateA != dateB) return false;
|
|
3320
|
+
if (dateA && dateB) return a.getTime() == b.getTime();
|
|
3314
3321
|
|
|
3315
|
-
|
|
3316
|
-
|
|
3317
|
-
if (
|
|
3322
|
+
var regexpA = a instanceof RegExp
|
|
3323
|
+
, regexpB = b instanceof RegExp;
|
|
3324
|
+
if (regexpA != regexpB) return false;
|
|
3325
|
+
if (regexpA && regexpB) return a.toString() == b.toString();
|
|
3318
3326
|
|
|
3319
|
-
keys =
|
|
3327
|
+
var keys = keyList(a);
|
|
3320
3328
|
length = keys.length;
|
|
3321
|
-
|
|
3329
|
+
|
|
3330
|
+
if (length !== keyList(b).length)
|
|
3331
|
+
return false;
|
|
3322
3332
|
|
|
3323
3333
|
for (i = length; i-- !== 0;)
|
|
3324
|
-
if (!
|
|
3334
|
+
if (!hasProp.call(b, keys[i])) return false;
|
|
3325
3335
|
|
|
3326
3336
|
for (i = length; i-- !== 0;) {
|
|
3327
|
-
|
|
3328
|
-
|
|
3337
|
+
key = keys[i];
|
|
3329
3338
|
if (!equal(a[key], b[key])) return false;
|
|
3330
3339
|
}
|
|
3331
3340
|
|
|
3332
3341
|
return true;
|
|
3333
3342
|
}
|
|
3334
3343
|
|
|
3335
|
-
// true if both NaN, false otherwise
|
|
3336
3344
|
return a!==a && b!==b;
|
|
3337
3345
|
};
|
|
3338
3346
|
|
|
@@ -4355,7 +4363,7 @@ function formatValue(ctx, value, recurseTimes) {
|
|
|
4355
4363
|
var base = '', array = false, braces = ['{', '}'];
|
|
4356
4364
|
|
|
4357
4365
|
// Make Array say that they are Array
|
|
4358
|
-
if (isArray(value)) {
|
|
4366
|
+
if (isArray$1(value)) {
|
|
4359
4367
|
array = true;
|
|
4360
4368
|
braces = ['[', ']'];
|
|
4361
4369
|
}
|
|
@@ -4534,7 +4542,7 @@ function reduceToSingleString(output, base, braces) {
|
|
|
4534
4542
|
|
|
4535
4543
|
// NOTE: These type checking functions intentionally don't use `instanceof`
|
|
4536
4544
|
// because it is fragile and can be easily faked with `Object.create()`.
|
|
4537
|
-
function isArray(ar) {
|
|
4545
|
+
function isArray$1(ar) {
|
|
4538
4546
|
return Array.isArray(ar);
|
|
4539
4547
|
}
|
|
4540
4548
|
|
|
@@ -4661,7 +4669,7 @@ var util = {
|
|
|
4661
4669
|
isNullOrUndefined: isNullOrUndefined,
|
|
4662
4670
|
isNull: isNull,
|
|
4663
4671
|
isBoolean: isBoolean,
|
|
4664
|
-
isArray: isArray,
|
|
4672
|
+
isArray: isArray$1,
|
|
4665
4673
|
inspect: inspect,
|
|
4666
4674
|
deprecate: deprecate,
|
|
4667
4675
|
format: format,
|
|
@@ -5328,235 +5336,199 @@ module.exports = exports['default'];
|
|
|
5328
5336
|
|
|
5329
5337
|
var youTubePlayer = _commonjsHelpers.unwrapExports(dist);
|
|
5330
5338
|
|
|
5331
|
-
function
|
|
5339
|
+
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
|
|
5332
5340
|
|
|
5333
|
-
function
|
|
5341
|
+
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
|
5334
5342
|
|
|
5335
|
-
function
|
|
5336
|
-
|
|
5337
|
-
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
5338
|
-
|
|
5339
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
5340
|
-
|
|
5341
|
-
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
5342
|
-
|
|
5343
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
5344
|
-
|
|
5345
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
5346
|
-
|
|
5347
|
-
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
5348
|
-
|
|
5349
|
-
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
5350
|
-
|
|
5351
|
-
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
5343
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
5352
5344
|
|
|
5353
|
-
function
|
|
5345
|
+
function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; }
|
|
5354
5346
|
|
|
5355
|
-
function
|
|
5347
|
+
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
|
|
5356
5348
|
|
|
5357
|
-
|
|
5358
|
-
|
|
5359
|
-
*
|
|
5360
|
-
*
|
|
5361
|
-
* @param {Object}
|
|
5362
|
-
* @param {Object} props
|
|
5349
|
+
/**
|
|
5350
|
+
* Check whether a `props` change should result in the video being updated.
|
|
5351
|
+
*
|
|
5352
|
+
* @param {Object} prevProps
|
|
5353
|
+
* @param {Object} props
|
|
5363
5354
|
*/
|
|
5364
|
-
|
|
5365
5355
|
function shouldUpdateVideo(prevProps, props) {
|
|
5366
5356
|
// A changing video should always trigger an update
|
|
5367
5357
|
if (prevProps.videoId !== props.videoId) {
|
|
5368
5358
|
return true;
|
|
5369
|
-
}
|
|
5370
|
-
// update.
|
|
5371
|
-
|
|
5359
|
+
}
|
|
5372
5360
|
|
|
5361
|
+
// Otherwise, a change in the start/end time playerVars also requires a player
|
|
5362
|
+
// update.
|
|
5373
5363
|
var prevVars = prevProps.opts.playerVars || {};
|
|
5374
5364
|
var vars = props.opts.playerVars || {};
|
|
5365
|
+
|
|
5375
5366
|
return prevVars.start !== vars.start || prevVars.end !== vars.end;
|
|
5376
5367
|
}
|
|
5377
|
-
/**
|
|
5378
|
-
* Neutralize API options that only require a video update, leaving only options
|
|
5379
|
-
* that require a player reset. The results can then be compared to see if a
|
|
5380
|
-
* player reset is necessary.
|
|
5381
|
-
*
|
|
5382
|
-
* @param {Object} opts
|
|
5383
|
-
*/
|
|
5384
|
-
|
|
5385
5368
|
|
|
5369
|
+
/**
|
|
5370
|
+
* Neutralise API options that only require a video update, leaving only options
|
|
5371
|
+
* that require a player reset. The results can then be compared to see if a
|
|
5372
|
+
* player reset is necessary.
|
|
5373
|
+
*
|
|
5374
|
+
* @param {Object} opts
|
|
5375
|
+
*/
|
|
5386
5376
|
function filterResetOptions(opts) {
|
|
5387
|
-
return
|
|
5388
|
-
playerVars:
|
|
5377
|
+
return _extends({}, opts, {
|
|
5378
|
+
playerVars: _extends({}, opts.playerVars, {
|
|
5389
5379
|
autoplay: 0,
|
|
5390
5380
|
start: 0,
|
|
5391
5381
|
end: 0
|
|
5392
5382
|
})
|
|
5393
5383
|
});
|
|
5394
5384
|
}
|
|
5395
|
-
/**
|
|
5396
|
-
* Check whether a `props` change should result in the player being reset.
|
|
5397
|
-
* The player is reset when the `props.opts` change, except if the only change
|
|
5398
|
-
* is in the `start` and `end` playerVars, because a video update can deal with
|
|
5399
|
-
* those.
|
|
5400
|
-
*
|
|
5401
|
-
* @param {Object} prevProps
|
|
5402
|
-
* @param {Object} props
|
|
5403
|
-
*/
|
|
5404
|
-
|
|
5405
5385
|
|
|
5386
|
+
/**
|
|
5387
|
+
* Check whether a `props` change should result in the player being reset.
|
|
5388
|
+
* The player is reset when the `props.opts` change, except if the only change
|
|
5389
|
+
* is in the `start` and `end` playerVars, because a video update can deal with
|
|
5390
|
+
* those.
|
|
5391
|
+
*
|
|
5392
|
+
* @param {Object} prevProps
|
|
5393
|
+
* @param {Object} props
|
|
5394
|
+
*/
|
|
5406
5395
|
function shouldResetPlayer(prevProps, props) {
|
|
5407
5396
|
return !fastDeepEqual(filterResetOptions(prevProps.opts), filterResetOptions(props.opts));
|
|
5408
5397
|
}
|
|
5409
|
-
/**
|
|
5410
|
-
* Check whether a props change should result in an id or className update.
|
|
5411
|
-
*
|
|
5412
|
-
* @param {Object} prevProps
|
|
5413
|
-
* @param {Object} props
|
|
5414
|
-
*/
|
|
5415
|
-
|
|
5416
5398
|
|
|
5399
|
+
/**
|
|
5400
|
+
* Check whether a props change should result in an id or className update.
|
|
5401
|
+
*
|
|
5402
|
+
* @param {Object} prevProps
|
|
5403
|
+
* @param {Object} props
|
|
5404
|
+
*/
|
|
5417
5405
|
function shouldUpdatePlayer(prevProps, props) {
|
|
5418
5406
|
return prevProps.id !== props.id || prevProps.className !== props.className;
|
|
5419
5407
|
}
|
|
5420
5408
|
|
|
5421
|
-
var YouTube =
|
|
5409
|
+
var YouTube = function (_React$Component) {
|
|
5422
5410
|
_inherits(YouTube, _React$Component);
|
|
5423
5411
|
|
|
5424
|
-
var _super = _createSuper(YouTube);
|
|
5425
|
-
|
|
5426
|
-
/**
|
|
5427
|
-
* Expose PlayerState constants for convenience. These constants can also be
|
|
5428
|
-
* accessed through the global YT object after the YouTube IFrame API is instantiated.
|
|
5429
|
-
* https://developers.google.com/youtube/iframe_api_reference#onStateChange
|
|
5430
|
-
*/
|
|
5431
5412
|
function YouTube(props) {
|
|
5432
|
-
var _this;
|
|
5433
|
-
|
|
5434
5413
|
_classCallCheck(this, YouTube);
|
|
5435
5414
|
|
|
5436
|
-
_this =
|
|
5415
|
+
var _this = _possibleConstructorReturn(this, (YouTube.__proto__ || Object.getPrototypeOf(YouTube)).call(this, props));
|
|
5437
5416
|
|
|
5438
|
-
|
|
5417
|
+
_this.onPlayerReady = function (event) {
|
|
5439
5418
|
return _this.props.onReady(event);
|
|
5440
|
-
}
|
|
5419
|
+
};
|
|
5441
5420
|
|
|
5442
|
-
|
|
5421
|
+
_this.onPlayerError = function (event) {
|
|
5443
5422
|
return _this.props.onError(event);
|
|
5444
|
-
}
|
|
5423
|
+
};
|
|
5445
5424
|
|
|
5446
|
-
|
|
5425
|
+
_this.onPlayerStateChange = function (event) {
|
|
5447
5426
|
_this.props.onStateChange(event);
|
|
5448
|
-
|
|
5449
5427
|
switch (event.data) {
|
|
5428
|
+
|
|
5450
5429
|
case YouTube.PlayerState.ENDED:
|
|
5451
5430
|
_this.props.onEnd(event);
|
|
5452
|
-
|
|
5453
5431
|
break;
|
|
5454
5432
|
|
|
5455
5433
|
case YouTube.PlayerState.PLAYING:
|
|
5456
5434
|
_this.props.onPlay(event);
|
|
5457
|
-
|
|
5458
5435
|
break;
|
|
5459
5436
|
|
|
5460
5437
|
case YouTube.PlayerState.PAUSED:
|
|
5461
5438
|
_this.props.onPause(event);
|
|
5462
|
-
|
|
5463
5439
|
break;
|
|
5464
5440
|
}
|
|
5465
|
-
}
|
|
5441
|
+
};
|
|
5466
5442
|
|
|
5467
|
-
|
|
5443
|
+
_this.onPlayerPlaybackRateChange = function (event) {
|
|
5468
5444
|
return _this.props.onPlaybackRateChange(event);
|
|
5469
|
-
}
|
|
5445
|
+
};
|
|
5470
5446
|
|
|
5471
|
-
|
|
5447
|
+
_this.onPlayerPlaybackQualityChange = function (event) {
|
|
5472
5448
|
return _this.props.onPlaybackQualityChange(event);
|
|
5473
|
-
}
|
|
5449
|
+
};
|
|
5474
5450
|
|
|
5475
|
-
|
|
5451
|
+
_this.createPlayer = function () {
|
|
5476
5452
|
// do not attempt to create a player server-side, it won't work
|
|
5477
|
-
if (typeof document === 'undefined') return;
|
|
5478
|
-
|
|
5479
|
-
var playerOpts =
|
|
5453
|
+
if (typeof document === 'undefined') return;
|
|
5454
|
+
// create player
|
|
5455
|
+
var playerOpts = _extends({}, _this.props.opts, {
|
|
5480
5456
|
// preload the `videoId` video if one is already given
|
|
5481
5457
|
videoId: _this.props.videoId
|
|
5482
5458
|
});
|
|
5483
|
-
|
|
5484
|
-
|
|
5485
|
-
|
|
5459
|
+
_this.internalPlayer = youTubePlayer(_this.container, playerOpts);
|
|
5460
|
+
// attach event handlers
|
|
5486
5461
|
_this.internalPlayer.on('ready', _this.onPlayerReady);
|
|
5487
|
-
|
|
5488
5462
|
_this.internalPlayer.on('error', _this.onPlayerError);
|
|
5489
|
-
|
|
5490
5463
|
_this.internalPlayer.on('stateChange', _this.onPlayerStateChange);
|
|
5491
|
-
|
|
5492
5464
|
_this.internalPlayer.on('playbackRateChange', _this.onPlayerPlaybackRateChange);
|
|
5493
|
-
|
|
5494
5465
|
_this.internalPlayer.on('playbackQualityChange', _this.onPlayerPlaybackQualityChange);
|
|
5495
|
-
}
|
|
5466
|
+
};
|
|
5496
5467
|
|
|
5497
|
-
|
|
5468
|
+
_this.resetPlayer = function () {
|
|
5498
5469
|
return _this.internalPlayer.destroy().then(_this.createPlayer);
|
|
5499
|
-
}
|
|
5470
|
+
};
|
|
5500
5471
|
|
|
5501
|
-
|
|
5472
|
+
_this.updatePlayer = function () {
|
|
5502
5473
|
_this.internalPlayer.getIframe().then(function (iframe) {
|
|
5503
5474
|
if (_this.props.id) iframe.setAttribute('id', _this.props.id);else iframe.removeAttribute('id');
|
|
5504
5475
|
if (_this.props.className) iframe.setAttribute('class', _this.props.className);else iframe.removeAttribute('class');
|
|
5505
5476
|
});
|
|
5506
|
-
}
|
|
5477
|
+
};
|
|
5507
5478
|
|
|
5508
|
-
|
|
5479
|
+
_this.updateVideo = function () {
|
|
5509
5480
|
if (typeof _this.props.videoId === 'undefined' || _this.props.videoId === null) {
|
|
5510
5481
|
_this.internalPlayer.stopVideo();
|
|
5511
|
-
|
|
5512
5482
|
return;
|
|
5513
|
-
}
|
|
5514
|
-
|
|
5483
|
+
}
|
|
5515
5484
|
|
|
5485
|
+
// set queueing options
|
|
5516
5486
|
var autoplay = false;
|
|
5517
5487
|
var opts = {
|
|
5518
5488
|
videoId: _this.props.videoId
|
|
5519
5489
|
};
|
|
5520
|
-
|
|
5521
5490
|
if ('playerVars' in _this.props.opts) {
|
|
5522
5491
|
autoplay = _this.props.opts.playerVars.autoplay === 1;
|
|
5523
|
-
|
|
5524
5492
|
if ('start' in _this.props.opts.playerVars) {
|
|
5525
5493
|
opts.startSeconds = _this.props.opts.playerVars.start;
|
|
5526
5494
|
}
|
|
5527
|
-
|
|
5528
5495
|
if ('end' in _this.props.opts.playerVars) {
|
|
5529
5496
|
opts.endSeconds = _this.props.opts.playerVars.end;
|
|
5530
5497
|
}
|
|
5531
|
-
}
|
|
5532
|
-
|
|
5498
|
+
}
|
|
5533
5499
|
|
|
5500
|
+
// if autoplay is enabled loadVideoById
|
|
5534
5501
|
if (autoplay) {
|
|
5535
5502
|
_this.internalPlayer.loadVideoById(opts);
|
|
5536
|
-
|
|
5537
5503
|
return;
|
|
5538
|
-
}
|
|
5539
|
-
|
|
5540
|
-
|
|
5504
|
+
}
|
|
5505
|
+
// default behaviour just cues the video
|
|
5541
5506
|
_this.internalPlayer.cueVideoById(opts);
|
|
5542
|
-
}
|
|
5507
|
+
};
|
|
5543
5508
|
|
|
5544
|
-
|
|
5509
|
+
_this.refContainer = function (container) {
|
|
5545
5510
|
_this.container = container;
|
|
5546
|
-
}
|
|
5511
|
+
};
|
|
5547
5512
|
|
|
5548
5513
|
_this.container = null;
|
|
5549
5514
|
_this.internalPlayer = null;
|
|
5550
5515
|
return _this;
|
|
5551
5516
|
}
|
|
5552
5517
|
|
|
5518
|
+
/**
|
|
5519
|
+
* Expose PlayerState constants for convenience. These constants can also be
|
|
5520
|
+
* accessed through the global YT object after the YouTube IFrame API is instantiated.
|
|
5521
|
+
* https://developers.google.com/youtube/iframe_api_reference#onStateChange
|
|
5522
|
+
*/
|
|
5523
|
+
|
|
5524
|
+
|
|
5553
5525
|
_createClass(YouTube, [{
|
|
5554
|
-
key:
|
|
5526
|
+
key: 'componentDidMount',
|
|
5555
5527
|
value: function componentDidMount() {
|
|
5556
5528
|
this.createPlayer();
|
|
5557
5529
|
}
|
|
5558
5530
|
}, {
|
|
5559
|
-
key:
|
|
5531
|
+
key: 'componentDidUpdate',
|
|
5560
5532
|
value: function componentDidUpdate(prevProps) {
|
|
5561
5533
|
if (shouldUpdatePlayer(prevProps, this.props)) {
|
|
5562
5534
|
this.updatePlayer();
|
|
@@ -5571,58 +5543,112 @@ var YouTube = /*#__PURE__*/function (_React$Component) {
|
|
|
5571
5543
|
}
|
|
5572
5544
|
}
|
|
5573
5545
|
}, {
|
|
5574
|
-
key:
|
|
5546
|
+
key: 'componentWillUnmount',
|
|
5575
5547
|
value: function componentWillUnmount() {
|
|
5576
|
-
/**
|
|
5577
|
-
* Note: The `youtube-player` package that is used promisifies all
|
|
5578
|
-
* Player API calls, which introduces a delay of a tick before it actually
|
|
5579
|
-
* gets destroyed. Since React attempts to remove the element instantly
|
|
5580
|
-
* this method isn't quick enough to reset the container element.
|
|
5548
|
+
/**
|
|
5549
|
+
* Note: The `youtube-player` package that is used promisifies all Youtube
|
|
5550
|
+
* Player API calls, which introduces a delay of a tick before it actually
|
|
5551
|
+
* gets destroyed. Since React attempts to remove the element instantly
|
|
5552
|
+
* this method isn't quick enough to reset the container element.
|
|
5581
5553
|
*/
|
|
5582
5554
|
this.internalPlayer.destroy();
|
|
5583
5555
|
}
|
|
5584
|
-
|
|
5585
|
-
|
|
5586
|
-
*
|
|
5587
|
-
*
|
|
5588
|
-
*
|
|
5556
|
+
|
|
5557
|
+
/**
|
|
5558
|
+
* https://developers.google.com/youtube/iframe_api_reference#onReady
|
|
5559
|
+
*
|
|
5560
|
+
* @param {Object} event
|
|
5561
|
+
* @param {Object} target - player object
|
|
5562
|
+
*/
|
|
5563
|
+
|
|
5564
|
+
|
|
5565
|
+
/**
|
|
5566
|
+
* https://developers.google.com/youtube/iframe_api_reference#onError
|
|
5567
|
+
*
|
|
5568
|
+
* @param {Object} event
|
|
5569
|
+
* @param {Integer} data - error type
|
|
5570
|
+
* @param {Object} target - player object
|
|
5571
|
+
*/
|
|
5572
|
+
|
|
5573
|
+
|
|
5574
|
+
/**
|
|
5575
|
+
* https://developers.google.com/youtube/iframe_api_reference#onStateChange
|
|
5576
|
+
*
|
|
5577
|
+
* @param {Object} event
|
|
5578
|
+
* @param {Integer} data - status change type
|
|
5579
|
+
* @param {Object} target - actual YT player
|
|
5580
|
+
*/
|
|
5581
|
+
|
|
5582
|
+
|
|
5583
|
+
/**
|
|
5584
|
+
* https://developers.google.com/youtube/iframe_api_reference#onPlaybackRateChange
|
|
5585
|
+
*
|
|
5586
|
+
* @param {Object} event
|
|
5587
|
+
* @param {Float} data - playback rate
|
|
5588
|
+
* @param {Object} target - actual YT player
|
|
5589
|
+
*/
|
|
5590
|
+
|
|
5591
|
+
|
|
5592
|
+
/**
|
|
5593
|
+
* https://developers.google.com/youtube/iframe_api_reference#onPlaybackQualityChange
|
|
5594
|
+
*
|
|
5595
|
+
* @param {Object} event
|
|
5596
|
+
* @param {String} data - playback quality
|
|
5597
|
+
* @param {Object} target - actual YT player
|
|
5598
|
+
*/
|
|
5599
|
+
|
|
5600
|
+
|
|
5601
|
+
/**
|
|
5602
|
+
* Initialize the Youtube Player API on the container and attach event handlers
|
|
5603
|
+
*/
|
|
5604
|
+
|
|
5605
|
+
|
|
5606
|
+
/**
|
|
5607
|
+
* Shorthand for destroying and then re-creating the Youtube Player
|
|
5608
|
+
*/
|
|
5609
|
+
|
|
5610
|
+
|
|
5611
|
+
/**
|
|
5612
|
+
* Method to update the id and class of the Youtube Player iframe.
|
|
5613
|
+
* React should update this automatically but since the Youtube Player API
|
|
5614
|
+
* replaced the DIV that is mounted by React we need to do this manually.
|
|
5615
|
+
*/
|
|
5616
|
+
|
|
5617
|
+
|
|
5618
|
+
/**
|
|
5619
|
+
* Call Youtube Player API methods to update the currently playing video.
|
|
5620
|
+
* Depeding on the `opts.playerVars.autoplay` this function uses one of two
|
|
5621
|
+
* Youtube Player API methods to update the video.
|
|
5589
5622
|
*/
|
|
5590
5623
|
|
|
5591
5624
|
}, {
|
|
5592
|
-
key:
|
|
5625
|
+
key: 'render',
|
|
5593
5626
|
value: function render() {
|
|
5594
|
-
return
|
|
5595
|
-
|
|
5596
|
-
|
|
5597
|
-
id: this.props.id,
|
|
5598
|
-
|
|
5599
|
-
ref: this.refContainer
|
|
5600
|
-
}));
|
|
5627
|
+
return React__default.createElement(
|
|
5628
|
+
'div',
|
|
5629
|
+
{ className: this.props.containerClassName },
|
|
5630
|
+
React__default.createElement('div', { id: this.props.id, className: this.props.className, ref: this.refContainer })
|
|
5631
|
+
);
|
|
5601
5632
|
}
|
|
5602
5633
|
}]);
|
|
5603
5634
|
|
|
5604
5635
|
return YouTube;
|
|
5605
5636
|
}(React__default.Component);
|
|
5606
5637
|
|
|
5607
|
-
_defineProperty(YouTube, "PlayerState", {
|
|
5608
|
-
UNSTARTED: -1,
|
|
5609
|
-
ENDED: 0,
|
|
5610
|
-
PLAYING: 1,
|
|
5611
|
-
PAUSED: 2,
|
|
5612
|
-
BUFFERING: 3,
|
|
5613
|
-
CUED: 5
|
|
5614
|
-
});
|
|
5615
|
-
|
|
5616
5638
|
YouTube.propTypes = {
|
|
5617
5639
|
videoId: PropTypes.string,
|
|
5640
|
+
|
|
5618
5641
|
// custom ID for player element
|
|
5619
5642
|
id: PropTypes.string,
|
|
5643
|
+
|
|
5620
5644
|
// custom class name for player element
|
|
5621
5645
|
className: PropTypes.string,
|
|
5622
5646
|
// custom class name for player container element
|
|
5623
5647
|
containerClassName: PropTypes.string,
|
|
5648
|
+
|
|
5624
5649
|
// https://developers.google.com/youtube/iframe_api_reference#Loading_a_Video_Player
|
|
5625
5650
|
opts: PropTypes.objectOf(PropTypes.any),
|
|
5651
|
+
|
|
5626
5652
|
// event subscriptions
|
|
5627
5653
|
onReady: PropTypes.func,
|
|
5628
5654
|
onError: PropTypes.func,
|
|
@@ -5634,7 +5660,6 @@ YouTube.propTypes = {
|
|
|
5634
5660
|
onPlaybackQualityChange: PropTypes.func
|
|
5635
5661
|
};
|
|
5636
5662
|
YouTube.defaultProps = {
|
|
5637
|
-
videoId: null,
|
|
5638
5663
|
id: null,
|
|
5639
5664
|
className: null,
|
|
5640
5665
|
opts: {},
|
|
@@ -5648,6 +5673,14 @@ YouTube.defaultProps = {
|
|
|
5648
5673
|
onPlaybackRateChange: function onPlaybackRateChange() {},
|
|
5649
5674
|
onPlaybackQualityChange: function onPlaybackQualityChange() {}
|
|
5650
5675
|
};
|
|
5676
|
+
YouTube.PlayerState = {
|
|
5677
|
+
UNSTARTED: -1,
|
|
5678
|
+
ENDED: 0,
|
|
5679
|
+
PLAYING: 1,
|
|
5680
|
+
PAUSED: 2,
|
|
5681
|
+
BUFFERING: 3,
|
|
5682
|
+
CUED: 5
|
|
5683
|
+
};
|
|
5651
5684
|
|
|
5652
5685
|
var YouTubePlayer = function YouTubePlayer(_ref) {
|
|
5653
5686
|
var url = _ref.url;
|
|
@@ -6671,8 +6704,8 @@ var window_1 = win;
|
|
|
6671
6704
|
|
|
6672
6705
|
/*! @name @brightcove/react-player-loader @version 1.4.0 @license Apache-2.0 */
|
|
6673
6706
|
|
|
6674
|
-
function _extends() {
|
|
6675
|
-
_extends = Object.assign || function (target) {
|
|
6707
|
+
function _extends$1() {
|
|
6708
|
+
_extends$1 = Object.assign || function (target) {
|
|
6676
6709
|
for (var i = 1; i < arguments.length; i++) {
|
|
6677
6710
|
var source = arguments[i];
|
|
6678
6711
|
|
|
@@ -6686,7 +6719,7 @@ function _extends() {
|
|
|
6686
6719
|
return target;
|
|
6687
6720
|
};
|
|
6688
6721
|
|
|
6689
|
-
return _extends.apply(this, arguments);
|
|
6722
|
+
return _extends$1.apply(this, arguments);
|
|
6690
6723
|
}
|
|
6691
6724
|
|
|
6692
6725
|
function _inheritsLoose(subClass, superClass) {
|
|
@@ -6695,7 +6728,7 @@ function _inheritsLoose(subClass, superClass) {
|
|
|
6695
6728
|
subClass.__proto__ = superClass;
|
|
6696
6729
|
}
|
|
6697
6730
|
|
|
6698
|
-
function _assertThisInitialized
|
|
6731
|
+
function _assertThisInitialized(self) {
|
|
6699
6732
|
if (self === void 0) {
|
|
6700
6733
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
6701
6734
|
}
|
|
@@ -6705,8 +6738,8 @@ function _assertThisInitialized$1(self) {
|
|
|
6705
6738
|
|
|
6706
6739
|
/*! @name @brightcove/player-loader @version 1.7.1 @license Apache-2.0 */
|
|
6707
6740
|
|
|
6708
|
-
function _extends$1() {
|
|
6709
|
-
_extends$1 = Object.assign || function (target) {
|
|
6741
|
+
function _extends$1$1() {
|
|
6742
|
+
_extends$1$1 = Object.assign || function (target) {
|
|
6710
6743
|
for (var i = 1; i < arguments.length; i++) {
|
|
6711
6744
|
var source = arguments[i];
|
|
6712
6745
|
|
|
@@ -6720,7 +6753,7 @@ function _extends$1() {
|
|
|
6720
6753
|
return target;
|
|
6721
6754
|
};
|
|
6722
6755
|
|
|
6723
|
-
return _extends$1.apply(this, arguments);
|
|
6756
|
+
return _extends$1$1.apply(this, arguments);
|
|
6724
6757
|
}
|
|
6725
6758
|
|
|
6726
6759
|
var version$1 = "1.7.1";
|
|
@@ -6728,7 +6761,7 @@ var version$1 = "1.7.1";
|
|
|
6728
6761
|
/*! @name @brightcove/player-url @version 1.2.0 @license Apache-2.0 */
|
|
6729
6762
|
var version$1$1 = "1.2.0";
|
|
6730
6763
|
|
|
6731
|
-
var _typeof
|
|
6764
|
+
var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) {
|
|
6732
6765
|
return typeof obj;
|
|
6733
6766
|
} : function (obj) {
|
|
6734
6767
|
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
@@ -6863,7 +6896,7 @@ var brightcovePlayerUrl = function brightcovePlayerUrl(_ref) {
|
|
|
6863
6896
|
|
|
6864
6897
|
var qs = '';
|
|
6865
6898
|
|
|
6866
|
-
if (iframe && queryParams && (typeof queryParams === 'undefined' ? 'undefined' : _typeof
|
|
6899
|
+
if (iframe && queryParams && (typeof queryParams === 'undefined' ? 'undefined' : _typeof(queryParams)) === 'object') {
|
|
6867
6900
|
qs = getQueryString(queryParams);
|
|
6868
6901
|
}
|
|
6869
6902
|
|
|
@@ -7097,7 +7130,7 @@ var wrapResponsive = function wrapResponsive(embedType, embedOptions, el) {
|
|
|
7097
7130
|
el.style.width = '100%';
|
|
7098
7131
|
el.style.height = '100%';
|
|
7099
7132
|
|
|
7100
|
-
var responsive = _extends$1({
|
|
7133
|
+
var responsive = _extends$1$1({
|
|
7101
7134
|
aspectRatio: DEFAULT_ASPECT_RATIO,
|
|
7102
7135
|
iframeHorizontalPlaylist: DEFAULT_IFRAME_HORIZONTAL_PLAYLIST,
|
|
7103
7136
|
maxWidth: DEFAULT_MAX_WIDTH
|
|
@@ -7782,7 +7815,7 @@ var loadPlayer = function loadPlayer(params, resolve, reject) {
|
|
|
7782
7815
|
|
|
7783
7816
|
|
|
7784
7817
|
var brightcovePlayerLoader = function brightcovePlayerLoader(parameters) {
|
|
7785
|
-
var params = _extends$1({}, DEFAULTS, parameters);
|
|
7818
|
+
var params = _extends$1$1({}, DEFAULTS, parameters);
|
|
7786
7819
|
|
|
7787
7820
|
var Promise = params.Promise,
|
|
7788
7821
|
onSuccess = params.onSuccess,
|
|
@@ -7924,7 +7957,7 @@ function (_React$Component) {
|
|
|
7924
7957
|
_this.refNode = ref;
|
|
7925
7958
|
};
|
|
7926
7959
|
|
|
7927
|
-
_this.loadPlayer = _this.loadPlayer.bind(_assertThisInitialized
|
|
7960
|
+
_this.loadPlayer = _this.loadPlayer.bind(_assertThisInitialized(_this));
|
|
7928
7961
|
return _this;
|
|
7929
7962
|
}
|
|
7930
7963
|
/**
|
|
@@ -7945,7 +7978,7 @@ function (_React$Component) {
|
|
|
7945
7978
|
var userSuccess = this.props.onSuccess;
|
|
7946
7979
|
var userFailure = this.props.onFailure;
|
|
7947
7980
|
|
|
7948
|
-
var options = _extends({}, this.props, {
|
|
7981
|
+
var options = _extends$1({}, this.props, {
|
|
7949
7982
|
refNode: this.refNode,
|
|
7950
7983
|
refNodeInsert: 'append',
|
|
7951
7984
|
onSuccess: function onSuccess(_ref) {
|
|
@@ -8254,7 +8287,7 @@ function (_React$Component) {
|
|
|
8254
8287
|
;
|
|
8255
8288
|
|
|
8256
8289
|
_proto.render = function render() {
|
|
8257
|
-
var props = _extends({
|
|
8290
|
+
var props = _extends$1({
|
|
8258
8291
|
className: 'brightcove-react-player-loader'
|
|
8259
8292
|
}, this.props.attrs, {
|
|
8260
8293
|
ref: this.setRefNode
|
|
@@ -8668,17 +8701,11 @@ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "functi
|
|
|
8668
8701
|
|
|
8669
8702
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
8670
8703
|
|
|
8671
|
-
function
|
|
8672
|
-
|
|
8673
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
8674
|
-
|
|
8675
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
8704
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }
|
|
8676
8705
|
|
|
8677
|
-
function
|
|
8706
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); }
|
|
8678
8707
|
|
|
8679
|
-
function
|
|
8680
|
-
|
|
8681
|
-
function _iterableToArrayLimit(arr, i) { if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return; var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
8708
|
+
function _iterableToArrayLimit(arr, i) { if (!(Symbol.iterator in Object(arr) || Object.prototype.toString.call(arr) === "[object Arguments]")) { return; } var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
8682
8709
|
|
|
8683
8710
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
8684
8711
|
|
|
@@ -8808,12 +8835,12 @@ function getSDK(url, sdkGlobal) {
|
|
|
8808
8835
|
|
|
8809
8836
|
function getConfig(props$1, defaultProps, showWarning) {
|
|
8810
8837
|
var config = (0, _deepmerge["default"])(defaultProps.config, props$1.config);
|
|
8811
|
-
|
|
8812
|
-
var
|
|
8813
|
-
|
|
8838
|
+
var _iteratorNormalCompletion = true;
|
|
8839
|
+
var _didIteratorError = false;
|
|
8840
|
+
var _iteratorError = undefined;
|
|
8814
8841
|
|
|
8815
8842
|
try {
|
|
8816
|
-
for (_iterator.
|
|
8843
|
+
for (var _iterator = props.DEPRECATED_CONFIG_PROPS[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
|
|
8817
8844
|
var p = _step.value;
|
|
8818
8845
|
|
|
8819
8846
|
if (props$1[p]) {
|
|
@@ -8828,9 +8855,18 @@ function getConfig(props$1, defaultProps, showWarning) {
|
|
|
8828
8855
|
}
|
|
8829
8856
|
}
|
|
8830
8857
|
} catch (err) {
|
|
8831
|
-
|
|
8858
|
+
_didIteratorError = true;
|
|
8859
|
+
_iteratorError = err;
|
|
8832
8860
|
} finally {
|
|
8833
|
-
|
|
8861
|
+
try {
|
|
8862
|
+
if (!_iteratorNormalCompletion && _iterator["return"] != null) {
|
|
8863
|
+
_iterator["return"]();
|
|
8864
|
+
}
|
|
8865
|
+
} finally {
|
|
8866
|
+
if (_didIteratorError) {
|
|
8867
|
+
throw _iteratorError;
|
|
8868
|
+
}
|
|
8869
|
+
}
|
|
8834
8870
|
}
|
|
8835
8871
|
|
|
8836
8872
|
return config;
|
|
@@ -8977,16 +9013,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
8977
9013
|
|
|
8978
9014
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
8979
9015
|
|
|
8980
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
8981
|
-
|
|
8982
9016
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
8983
9017
|
|
|
8984
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
8985
|
-
|
|
8986
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
8987
|
-
|
|
8988
9018
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
8989
9019
|
|
|
9020
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9021
|
+
|
|
8990
9022
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
8991
9023
|
|
|
8992
9024
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -8995,12 +9027,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
8995
9027
|
|
|
8996
9028
|
var SEEK_ON_PLAY_EXPIRY = 5000;
|
|
8997
9029
|
|
|
8998
|
-
var Player =
|
|
9030
|
+
var Player =
|
|
9031
|
+
/*#__PURE__*/
|
|
9032
|
+
function (_Component) {
|
|
8999
9033
|
_inherits(Player, _Component);
|
|
9000
9034
|
|
|
9001
|
-
var _super = _createSuper(Player);
|
|
9002
|
-
|
|
9003
9035
|
function Player() {
|
|
9036
|
+
var _getPrototypeOf2;
|
|
9037
|
+
|
|
9004
9038
|
var _this;
|
|
9005
9039
|
|
|
9006
9040
|
_classCallCheck(this, Player);
|
|
@@ -9009,7 +9043,7 @@ var Player = /*#__PURE__*/function (_Component) {
|
|
|
9009
9043
|
_args[_key] = arguments[_key];
|
|
9010
9044
|
}
|
|
9011
9045
|
|
|
9012
|
-
_this =
|
|
9046
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Player)).call.apply(_getPrototypeOf2, [this].concat(_args)));
|
|
9013
9047
|
|
|
9014
9048
|
_defineProperty(_assertThisInitialized(_this), "mounted", false);
|
|
9015
9049
|
|
|
@@ -9334,7 +9368,7 @@ var Player = /*#__PURE__*/function (_Component) {
|
|
|
9334
9368
|
return null;
|
|
9335
9369
|
}
|
|
9336
9370
|
|
|
9337
|
-
return
|
|
9371
|
+
return _react["default"].createElement(Player, _extends({}, this.props, {
|
|
9338
9372
|
ref: this.ref,
|
|
9339
9373
|
onReady: this.handleReady,
|
|
9340
9374
|
onPlay: this.handlePlay,
|
|
@@ -9395,16 +9429,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
9395
9429
|
|
|
9396
9430
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
9397
9431
|
|
|
9398
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
9399
|
-
|
|
9400
9432
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
9401
9433
|
|
|
9402
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9403
|
-
|
|
9404
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
9405
|
-
|
|
9406
9434
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
9407
9435
|
|
|
9436
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9437
|
+
|
|
9408
9438
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
9409
9439
|
|
|
9410
9440
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -9416,12 +9446,14 @@ var SUPPORTED_PROPS = Object.keys(props.propTypes);
|
|
|
9416
9446
|
function createSinglePlayer(activePlayer) {
|
|
9417
9447
|
var _class, _temp;
|
|
9418
9448
|
|
|
9419
|
-
return _temp = _class =
|
|
9449
|
+
return _temp = _class =
|
|
9450
|
+
/*#__PURE__*/
|
|
9451
|
+
function (_Component) {
|
|
9420
9452
|
_inherits(SinglePlayer, _Component);
|
|
9421
9453
|
|
|
9422
|
-
var _super = _createSuper(SinglePlayer);
|
|
9423
|
-
|
|
9424
9454
|
function SinglePlayer() {
|
|
9455
|
+
var _getPrototypeOf2;
|
|
9456
|
+
|
|
9425
9457
|
var _this;
|
|
9426
9458
|
|
|
9427
9459
|
_classCallCheck(this, SinglePlayer);
|
|
@@ -9430,7 +9462,7 @@ function createSinglePlayer(activePlayer) {
|
|
|
9430
9462
|
args[_key] = arguments[_key];
|
|
9431
9463
|
}
|
|
9432
9464
|
|
|
9433
|
-
_this =
|
|
9465
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(SinglePlayer)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
9434
9466
|
|
|
9435
9467
|
_defineProperty(_assertThisInitialized(_this), "config", (0, utils.getConfig)(_this.props, props.defaultProps, true));
|
|
9436
9468
|
|
|
@@ -9498,12 +9530,12 @@ function createSinglePlayer(activePlayer) {
|
|
|
9498
9530
|
height = _this$props.height,
|
|
9499
9531
|
Wrapper = _this$props.wrapper;
|
|
9500
9532
|
var otherProps = (0, utils.omit)(this.props, SUPPORTED_PROPS, props.DEPRECATED_CONFIG_PROPS);
|
|
9501
|
-
return
|
|
9533
|
+
return _react["default"].createElement(Wrapper, _extends({
|
|
9502
9534
|
style: _objectSpread({}, style, {
|
|
9503
9535
|
width: width,
|
|
9504
9536
|
height: height
|
|
9505
9537
|
})
|
|
9506
|
-
}, otherProps),
|
|
9538
|
+
}, otherProps), _react["default"].createElement(_Player["default"], _extends({}, this.props, {
|
|
9507
9539
|
ref: this.ref,
|
|
9508
9540
|
activePlayer: activePlayer,
|
|
9509
9541
|
config: this.config
|
|
@@ -9549,31 +9581,23 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
9549
9581
|
|
|
9550
9582
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
9551
9583
|
|
|
9552
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
9553
|
-
|
|
9554
9584
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
9555
9585
|
|
|
9556
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9557
|
-
|
|
9558
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
9559
|
-
|
|
9560
9586
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
9561
9587
|
|
|
9588
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9589
|
+
|
|
9562
9590
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
9563
9591
|
|
|
9564
9592
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
9565
9593
|
|
|
9566
9594
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
9567
9595
|
|
|
9568
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) ||
|
|
9596
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }
|
|
9569
9597
|
|
|
9570
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance
|
|
9598
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); }
|
|
9571
9599
|
|
|
9572
|
-
function
|
|
9573
|
-
|
|
9574
|
-
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
9575
|
-
|
|
9576
|
-
function _iterableToArrayLimit(arr, i) { if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return; var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
9600
|
+
function _iterableToArrayLimit(arr, i) { if (!(Symbol.iterator in Object(arr) || Object.prototype.toString.call(arr) === "[object Arguments]")) { return; } var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
9577
9601
|
|
|
9578
9602
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
9579
9603
|
|
|
@@ -9598,12 +9622,14 @@ function parsePlaylist(url) {
|
|
|
9598
9622
|
return {};
|
|
9599
9623
|
}
|
|
9600
9624
|
|
|
9601
|
-
var YouTube =
|
|
9625
|
+
var YouTube =
|
|
9626
|
+
/*#__PURE__*/
|
|
9627
|
+
function (_Component) {
|
|
9602
9628
|
_inherits(YouTube, _Component);
|
|
9603
9629
|
|
|
9604
|
-
var _super = _createSuper(YouTube);
|
|
9605
|
-
|
|
9606
9630
|
function YouTube() {
|
|
9631
|
+
var _getPrototypeOf2;
|
|
9632
|
+
|
|
9607
9633
|
var _this;
|
|
9608
9634
|
|
|
9609
9635
|
_classCallCheck(this, YouTube);
|
|
@@ -9612,7 +9638,7 @@ var YouTube = /*#__PURE__*/function (_Component) {
|
|
|
9612
9638
|
args[_key] = arguments[_key];
|
|
9613
9639
|
}
|
|
9614
9640
|
|
|
9615
|
-
_this =
|
|
9641
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(YouTube)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
9616
9642
|
|
|
9617
9643
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
9618
9644
|
|
|
@@ -9800,9 +9826,9 @@ var YouTube = /*#__PURE__*/function (_Component) {
|
|
|
9800
9826
|
height: '100%',
|
|
9801
9827
|
display: display
|
|
9802
9828
|
};
|
|
9803
|
-
return
|
|
9829
|
+
return _react["default"].createElement("div", {
|
|
9804
9830
|
style: style
|
|
9805
|
-
},
|
|
9831
|
+
}, _react["default"].createElement("div", {
|
|
9806
9832
|
ref: this.ref
|
|
9807
9833
|
}));
|
|
9808
9834
|
}
|
|
@@ -9858,16 +9884,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
9858
9884
|
|
|
9859
9885
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
9860
9886
|
|
|
9861
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
9862
|
-
|
|
9863
9887
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
9864
9888
|
|
|
9865
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9866
|
-
|
|
9867
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
9868
|
-
|
|
9869
9889
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
9870
9890
|
|
|
9891
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9892
|
+
|
|
9871
9893
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
9872
9894
|
|
|
9873
9895
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -9876,14 +9898,16 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
9876
9898
|
|
|
9877
9899
|
var SDK_URL = 'https://w.soundcloud.com/player/api.js';
|
|
9878
9900
|
var SDK_GLOBAL = 'SC';
|
|
9879
|
-
var MATCH_URL = /(
|
|
9901
|
+
var MATCH_URL = /(soundcloud\.com|snd\.sc)\/.+$/;
|
|
9880
9902
|
|
|
9881
|
-
var SoundCloud =
|
|
9903
|
+
var SoundCloud =
|
|
9904
|
+
/*#__PURE__*/
|
|
9905
|
+
function (_Component) {
|
|
9882
9906
|
_inherits(SoundCloud, _Component);
|
|
9883
9907
|
|
|
9884
|
-
var _super = _createSuper(SoundCloud);
|
|
9885
|
-
|
|
9886
9908
|
function SoundCloud() {
|
|
9909
|
+
var _getPrototypeOf2;
|
|
9910
|
+
|
|
9887
9911
|
var _this;
|
|
9888
9912
|
|
|
9889
9913
|
_classCallCheck(this, SoundCloud);
|
|
@@ -9892,7 +9916,7 @@ var SoundCloud = /*#__PURE__*/function (_Component) {
|
|
|
9892
9916
|
args[_key] = arguments[_key];
|
|
9893
9917
|
}
|
|
9894
9918
|
|
|
9895
|
-
_this =
|
|
9919
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(SoundCloud)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
9896
9920
|
|
|
9897
9921
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
9898
9922
|
|
|
@@ -10013,7 +10037,7 @@ var SoundCloud = /*#__PURE__*/function (_Component) {
|
|
|
10013
10037
|
height: '100%',
|
|
10014
10038
|
display: display
|
|
10015
10039
|
};
|
|
10016
|
-
return
|
|
10040
|
+
return _react["default"].createElement("iframe", {
|
|
10017
10041
|
ref: this.ref,
|
|
10018
10042
|
src: "https://w.soundcloud.com/player/?url=".concat(encodeURIComponent(this.props.url)),
|
|
10019
10043
|
style: style,
|
|
@@ -10075,16 +10099,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
10075
10099
|
|
|
10076
10100
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
10077
10101
|
|
|
10078
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
10079
|
-
|
|
10080
10102
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
10081
10103
|
|
|
10082
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10083
|
-
|
|
10084
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
10085
|
-
|
|
10086
10104
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
10087
10105
|
|
|
10106
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10107
|
+
|
|
10088
10108
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
10089
10109
|
|
|
10090
10110
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -10096,12 +10116,14 @@ var SDK_GLOBAL = 'Vimeo';
|
|
|
10096
10116
|
var MATCH_URL = /vimeo\.com\/.+/;
|
|
10097
10117
|
var MATCH_FILE_URL = /vimeo\.com\/external\/[0-9]+\..+/;
|
|
10098
10118
|
|
|
10099
|
-
var Vimeo =
|
|
10119
|
+
var Vimeo =
|
|
10120
|
+
/*#__PURE__*/
|
|
10121
|
+
function (_Component) {
|
|
10100
10122
|
_inherits(Vimeo, _Component);
|
|
10101
10123
|
|
|
10102
|
-
var _super = _createSuper(Vimeo);
|
|
10103
|
-
|
|
10104
10124
|
function Vimeo() {
|
|
10125
|
+
var _getPrototypeOf2;
|
|
10126
|
+
|
|
10105
10127
|
var _this;
|
|
10106
10128
|
|
|
10107
10129
|
_classCallCheck(this, Vimeo);
|
|
@@ -10110,7 +10132,7 @@ var Vimeo = /*#__PURE__*/function (_Component) {
|
|
|
10110
10132
|
args[_key] = arguments[_key];
|
|
10111
10133
|
}
|
|
10112
10134
|
|
|
10113
|
-
_this =
|
|
10135
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Vimeo)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
10114
10136
|
|
|
10115
10137
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
10116
10138
|
|
|
@@ -10267,7 +10289,7 @@ var Vimeo = /*#__PURE__*/function (_Component) {
|
|
|
10267
10289
|
overflow: 'hidden',
|
|
10268
10290
|
display: display
|
|
10269
10291
|
};
|
|
10270
|
-
return
|
|
10292
|
+
return _react["default"].createElement("div", {
|
|
10271
10293
|
key: this.props.url,
|
|
10272
10294
|
ref: this.ref,
|
|
10273
10295
|
style: style
|
|
@@ -10327,16 +10349,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
10327
10349
|
|
|
10328
10350
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
10329
10351
|
|
|
10330
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
10331
|
-
|
|
10332
10352
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
10333
10353
|
|
|
10334
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10335
|
-
|
|
10336
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
10337
|
-
|
|
10338
10354
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
10339
10355
|
|
|
10356
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10357
|
+
|
|
10340
10358
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
10341
10359
|
|
|
10342
10360
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -10349,12 +10367,14 @@ var SDK_GLOBAL_READY = 'fbAsyncInit';
|
|
|
10349
10367
|
var MATCH_URL = /^https?:\/\/(www\.)?facebook\.com.*\/(video(s)?|watch|story)(\.php?|\/).+$/;
|
|
10350
10368
|
var PLAYER_ID_PREFIX = 'facebook-player-';
|
|
10351
10369
|
|
|
10352
|
-
var Facebook =
|
|
10370
|
+
var Facebook =
|
|
10371
|
+
/*#__PURE__*/
|
|
10372
|
+
function (_Component) {
|
|
10353
10373
|
_inherits(Facebook, _Component);
|
|
10354
10374
|
|
|
10355
|
-
var _super = _createSuper(Facebook);
|
|
10356
|
-
|
|
10357
10375
|
function Facebook() {
|
|
10376
|
+
var _getPrototypeOf2;
|
|
10377
|
+
|
|
10358
10378
|
var _this;
|
|
10359
10379
|
|
|
10360
10380
|
_classCallCheck(this, Facebook);
|
|
@@ -10363,7 +10383,7 @@ var Facebook = /*#__PURE__*/function (_Component) {
|
|
|
10363
10383
|
args[_key] = arguments[_key];
|
|
10364
10384
|
}
|
|
10365
10385
|
|
|
10366
|
-
_this =
|
|
10386
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Facebook)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
10367
10387
|
|
|
10368
10388
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
10369
10389
|
|
|
@@ -10479,7 +10499,7 @@ var Facebook = /*#__PURE__*/function (_Component) {
|
|
|
10479
10499
|
width: '100%',
|
|
10480
10500
|
height: '100%'
|
|
10481
10501
|
};
|
|
10482
|
-
return
|
|
10502
|
+
return _react["default"].createElement("div", {
|
|
10483
10503
|
style: style,
|
|
10484
10504
|
id: this.playerID,
|
|
10485
10505
|
className: "fb-video",
|
|
@@ -10539,16 +10559,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
10539
10559
|
|
|
10540
10560
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
10541
10561
|
|
|
10542
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
10543
|
-
|
|
10544
10562
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
10545
10563
|
|
|
10546
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10547
|
-
|
|
10548
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
10549
|
-
|
|
10550
10564
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
10551
10565
|
|
|
10566
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10567
|
+
|
|
10552
10568
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
10553
10569
|
|
|
10554
10570
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -10559,12 +10575,14 @@ var SDK_URL = 'https://cdn.embed.ly/player-0.1.0.min.js';
|
|
|
10559
10575
|
var SDK_GLOBAL = 'playerjs';
|
|
10560
10576
|
var MATCH_URL = /streamable\.com\/([a-z0-9]+)$/;
|
|
10561
10577
|
|
|
10562
|
-
var Streamable =
|
|
10578
|
+
var Streamable =
|
|
10579
|
+
/*#__PURE__*/
|
|
10580
|
+
function (_Component) {
|
|
10563
10581
|
_inherits(Streamable, _Component);
|
|
10564
10582
|
|
|
10565
|
-
var _super = _createSuper(Streamable);
|
|
10566
|
-
|
|
10567
10583
|
function Streamable() {
|
|
10584
|
+
var _getPrototypeOf2;
|
|
10585
|
+
|
|
10568
10586
|
var _this;
|
|
10569
10587
|
|
|
10570
10588
|
_classCallCheck(this, Streamable);
|
|
@@ -10573,7 +10591,7 @@ var Streamable = /*#__PURE__*/function (_Component) {
|
|
|
10573
10591
|
args[_key] = arguments[_key];
|
|
10574
10592
|
}
|
|
10575
10593
|
|
|
10576
|
-
_this =
|
|
10594
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Streamable)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
10577
10595
|
|
|
10578
10596
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
10579
10597
|
|
|
@@ -10693,7 +10711,7 @@ var Streamable = /*#__PURE__*/function (_Component) {
|
|
|
10693
10711
|
width: '100%',
|
|
10694
10712
|
height: '100%'
|
|
10695
10713
|
};
|
|
10696
|
-
return
|
|
10714
|
+
return _react["default"].createElement("iframe", {
|
|
10697
10715
|
ref: this.ref,
|
|
10698
10716
|
src: "https://streamable.com/o/".concat(id),
|
|
10699
10717
|
frameBorder: "0",
|
|
@@ -10754,16 +10772,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
10754
10772
|
|
|
10755
10773
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
10756
10774
|
|
|
10757
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
10758
|
-
|
|
10759
10775
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
10760
10776
|
|
|
10761
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10762
|
-
|
|
10763
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
10764
|
-
|
|
10765
10777
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
10766
10778
|
|
|
10779
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10780
|
+
|
|
10767
10781
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
10768
10782
|
|
|
10769
10783
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -10774,48 +10788,26 @@ var SDK_URL = 'https://fast.wistia.com/assets/external/E-v1.js';
|
|
|
10774
10788
|
var SDK_GLOBAL = 'Wistia';
|
|
10775
10789
|
var MATCH_URL = /(?:wistia\.com|wi\.st)\/(?:medias|embed)\/(.*)$/;
|
|
10776
10790
|
|
|
10777
|
-
var Wistia =
|
|
10791
|
+
var Wistia =
|
|
10792
|
+
/*#__PURE__*/
|
|
10793
|
+
function (_Component) {
|
|
10778
10794
|
_inherits(Wistia, _Component);
|
|
10779
10795
|
|
|
10780
|
-
var _super = _createSuper(Wistia);
|
|
10781
|
-
|
|
10782
10796
|
function Wistia() {
|
|
10797
|
+
var _getPrototypeOf2;
|
|
10798
|
+
|
|
10783
10799
|
var _this;
|
|
10784
10800
|
|
|
10785
10801
|
_classCallCheck(this, Wistia);
|
|
10786
10802
|
|
|
10787
|
-
for (var _len = arguments.length,
|
|
10788
|
-
|
|
10803
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
10804
|
+
args[_key] = arguments[_key];
|
|
10789
10805
|
}
|
|
10790
10806
|
|
|
10791
|
-
_this =
|
|
10807
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Wistia)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
10792
10808
|
|
|
10793
10809
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
10794
10810
|
|
|
10795
|
-
_defineProperty(_assertThisInitialized(_this), "onPlay", function () {
|
|
10796
|
-
var _this$props;
|
|
10797
|
-
|
|
10798
|
-
return (_this$props = _this.props).onPlay.apply(_this$props, arguments);
|
|
10799
|
-
});
|
|
10800
|
-
|
|
10801
|
-
_defineProperty(_assertThisInitialized(_this), "onPause", function () {
|
|
10802
|
-
var _this$props2;
|
|
10803
|
-
|
|
10804
|
-
return (_this$props2 = _this.props).onPause.apply(_this$props2, arguments);
|
|
10805
|
-
});
|
|
10806
|
-
|
|
10807
|
-
_defineProperty(_assertThisInitialized(_this), "onSeek", function () {
|
|
10808
|
-
var _this$props3;
|
|
10809
|
-
|
|
10810
|
-
return (_this$props3 = _this.props).onSeek.apply(_this$props3, arguments);
|
|
10811
|
-
});
|
|
10812
|
-
|
|
10813
|
-
_defineProperty(_assertThisInitialized(_this), "onEnded", function () {
|
|
10814
|
-
var _this$props4;
|
|
10815
|
-
|
|
10816
|
-
return (_this$props4 = _this.props).onEnded.apply(_this$props4, arguments);
|
|
10817
|
-
});
|
|
10818
|
-
|
|
10819
10811
|
_defineProperty(_assertThisInitialized(_this), "mute", function () {
|
|
10820
10812
|
_this.callPlayer('mute');
|
|
10821
10813
|
});
|
|
@@ -10837,13 +10829,17 @@ var Wistia = /*#__PURE__*/function (_Component) {
|
|
|
10837
10829
|
value: function load(url) {
|
|
10838
10830
|
var _this2 = this;
|
|
10839
10831
|
|
|
10840
|
-
var _this$
|
|
10841
|
-
playing = _this$
|
|
10842
|
-
muted = _this$
|
|
10843
|
-
controls = _this$
|
|
10844
|
-
_onReady = _this$
|
|
10845
|
-
|
|
10846
|
-
|
|
10832
|
+
var _this$props = this.props,
|
|
10833
|
+
playing = _this$props.playing,
|
|
10834
|
+
muted = _this$props.muted,
|
|
10835
|
+
controls = _this$props.controls,
|
|
10836
|
+
_onReady = _this$props.onReady,
|
|
10837
|
+
onPlay = _this$props.onPlay,
|
|
10838
|
+
onPause = _this$props.onPause,
|
|
10839
|
+
onSeek = _this$props.onSeek,
|
|
10840
|
+
onEnded = _this$props.onEnded,
|
|
10841
|
+
config = _this$props.config,
|
|
10842
|
+
onError = _this$props.onError;
|
|
10847
10843
|
(0, utils.getSDK)(SDK_URL, SDK_GLOBAL).then(function () {
|
|
10848
10844
|
window._wq = window._wq || [];
|
|
10849
10845
|
|
|
@@ -10860,28 +10856,19 @@ var Wistia = /*#__PURE__*/function (_Component) {
|
|
|
10860
10856
|
|
|
10861
10857
|
_this2.unbind();
|
|
10862
10858
|
|
|
10863
|
-
_this2.player.bind('play',
|
|
10859
|
+
_this2.player.bind('play', onPlay);
|
|
10864
10860
|
|
|
10865
|
-
_this2.player.bind('pause',
|
|
10861
|
+
_this2.player.bind('pause', onPause);
|
|
10866
10862
|
|
|
10867
|
-
_this2.player.bind('seek',
|
|
10863
|
+
_this2.player.bind('seek', onSeek);
|
|
10868
10864
|
|
|
10869
|
-
_this2.player.bind('end',
|
|
10865
|
+
_this2.player.bind('end', onEnded);
|
|
10870
10866
|
|
|
10871
10867
|
_onReady();
|
|
10872
10868
|
}
|
|
10873
10869
|
});
|
|
10874
10870
|
}, onError);
|
|
10875
10871
|
}
|
|
10876
|
-
}, {
|
|
10877
|
-
key: "unbind",
|
|
10878
|
-
value: function unbind() {
|
|
10879
|
-
this.player.unbind('play', this.onPlay);
|
|
10880
|
-
this.player.unbind('pause', this.onPause);
|
|
10881
|
-
this.player.unbind('seek', this.onSeek);
|
|
10882
|
-
this.player.unbind('end', this.onEnded);
|
|
10883
|
-
} // Proxy methods to prevent listener leaks
|
|
10884
|
-
|
|
10885
10872
|
}, {
|
|
10886
10873
|
key: "play",
|
|
10887
10874
|
value: function play() {
|
|
@@ -10892,6 +10879,19 @@ var Wistia = /*#__PURE__*/function (_Component) {
|
|
|
10892
10879
|
value: function pause() {
|
|
10893
10880
|
this.callPlayer('pause');
|
|
10894
10881
|
}
|
|
10882
|
+
}, {
|
|
10883
|
+
key: "unbind",
|
|
10884
|
+
value: function unbind() {
|
|
10885
|
+
var _this$props2 = this.props,
|
|
10886
|
+
onPlay = _this$props2.onPlay,
|
|
10887
|
+
onPause = _this$props2.onPause,
|
|
10888
|
+
onSeek = _this$props2.onSeek,
|
|
10889
|
+
onEnded = _this$props2.onEnded;
|
|
10890
|
+
this.player.unbind('play', onPlay);
|
|
10891
|
+
this.player.unbind('pause', onPause);
|
|
10892
|
+
this.player.unbind('seek', onSeek);
|
|
10893
|
+
this.player.unbind('end', onEnded);
|
|
10894
|
+
}
|
|
10895
10895
|
}, {
|
|
10896
10896
|
key: "stop",
|
|
10897
10897
|
value: function stop() {
|
|
@@ -10937,7 +10937,7 @@ var Wistia = /*#__PURE__*/function (_Component) {
|
|
|
10937
10937
|
width: '100%',
|
|
10938
10938
|
height: '100%'
|
|
10939
10939
|
};
|
|
10940
|
-
return
|
|
10940
|
+
return _react["default"].createElement("div", {
|
|
10941
10941
|
key: id,
|
|
10942
10942
|
className: className,
|
|
10943
10943
|
style: style
|
|
@@ -10997,16 +10997,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
10997
10997
|
|
|
10998
10998
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
10999
10999
|
|
|
11000
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
11001
|
-
|
|
11002
11000
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
11003
11001
|
|
|
11004
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
11005
|
-
|
|
11006
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
11007
|
-
|
|
11008
11002
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
11009
11003
|
|
|
11004
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
11005
|
+
|
|
11010
11006
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
11011
11007
|
|
|
11012
11008
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -11019,12 +11015,14 @@ var MATCH_VIDEO_URL = /(?:www\.|go\.)?twitch\.tv\/videos\/(\d+)($|\?)/;
|
|
|
11019
11015
|
var MATCH_CHANNEL_URL = /(?:www\.|go\.)?twitch\.tv\/([a-z0-9_]+)($|\?)/;
|
|
11020
11016
|
var PLAYER_ID_PREFIX = 'twitch-player-';
|
|
11021
11017
|
|
|
11022
|
-
var Twitch =
|
|
11018
|
+
var Twitch =
|
|
11019
|
+
/*#__PURE__*/
|
|
11020
|
+
function (_Component) {
|
|
11023
11021
|
_inherits(Twitch, _Component);
|
|
11024
11022
|
|
|
11025
|
-
var _super = _createSuper(Twitch);
|
|
11026
|
-
|
|
11027
11023
|
function Twitch() {
|
|
11024
|
+
var _getPrototypeOf2;
|
|
11025
|
+
|
|
11028
11026
|
var _this;
|
|
11029
11027
|
|
|
11030
11028
|
_classCallCheck(this, Twitch);
|
|
@@ -11033,7 +11031,7 @@ var Twitch = /*#__PURE__*/function (_Component) {
|
|
|
11033
11031
|
args[_key] = arguments[_key];
|
|
11034
11032
|
}
|
|
11035
11033
|
|
|
11036
|
-
_this =
|
|
11034
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Twitch)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
11037
11035
|
|
|
11038
11036
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
11039
11037
|
|
|
@@ -11154,7 +11152,7 @@ var Twitch = /*#__PURE__*/function (_Component) {
|
|
|
11154
11152
|
width: '100%',
|
|
11155
11153
|
height: '100%'
|
|
11156
11154
|
};
|
|
11157
|
-
return
|
|
11155
|
+
return _react["default"].createElement("div", {
|
|
11158
11156
|
style: style,
|
|
11159
11157
|
id: this.playerID
|
|
11160
11158
|
});
|
|
@@ -11207,15 +11205,11 @@ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (O
|
|
|
11207
11205
|
|
|
11208
11206
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
11209
11207
|
|
|
11210
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) ||
|
|
11211
|
-
|
|
11212
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
11208
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }
|
|
11213
11209
|
|
|
11214
|
-
function
|
|
11210
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); }
|
|
11215
11211
|
|
|
11216
|
-
function
|
|
11217
|
-
|
|
11218
|
-
function _iterableToArrayLimit(arr, i) { if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return; var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
11212
|
+
function _iterableToArrayLimit(arr, i) { if (!(Symbol.iterator in Object(arr) || Object.prototype.toString.call(arr) === "[object Arguments]")) { return; } var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
11219
11213
|
|
|
11220
11214
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
11221
11215
|
|
|
@@ -11225,16 +11219,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
11225
11219
|
|
|
11226
11220
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
11227
11221
|
|
|
11228
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
11229
|
-
|
|
11230
11222
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
11231
11223
|
|
|
11232
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
11233
|
-
|
|
11234
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
11235
|
-
|
|
11236
11224
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
11237
11225
|
|
|
11226
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
11227
|
+
|
|
11238
11228
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
11239
11229
|
|
|
11240
11230
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -11246,12 +11236,14 @@ var SDK_GLOBAL = 'DM';
|
|
|
11246
11236
|
var SDK_GLOBAL_READY = 'dmAsyncInit';
|
|
11247
11237
|
var MATCH_URL = /^(?:(?:https?):)?(?:\/\/)?(?:www\.)?(?:(?:dailymotion\.com(?:\/embed)?\/video)|dai\.ly)\/([a-zA-Z0-9]+)(?:_[\w_-]+)?$/;
|
|
11248
11238
|
|
|
11249
|
-
var DailyMotion =
|
|
11239
|
+
var DailyMotion =
|
|
11240
|
+
/*#__PURE__*/
|
|
11241
|
+
function (_Component) {
|
|
11250
11242
|
_inherits(DailyMotion, _Component);
|
|
11251
11243
|
|
|
11252
|
-
var _super = _createSuper(DailyMotion);
|
|
11253
|
-
|
|
11254
11244
|
function DailyMotion() {
|
|
11245
|
+
var _getPrototypeOf2;
|
|
11246
|
+
|
|
11255
11247
|
var _this;
|
|
11256
11248
|
|
|
11257
11249
|
_classCallCheck(this, DailyMotion);
|
|
@@ -11260,7 +11252,7 @@ var DailyMotion = /*#__PURE__*/function (_Component) {
|
|
|
11260
11252
|
args[_key] = arguments[_key];
|
|
11261
11253
|
}
|
|
11262
11254
|
|
|
11263
|
-
_this =
|
|
11255
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(DailyMotion)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
11264
11256
|
|
|
11265
11257
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
11266
11258
|
|
|
@@ -11389,9 +11381,9 @@ var DailyMotion = /*#__PURE__*/function (_Component) {
|
|
|
11389
11381
|
height: '100%',
|
|
11390
11382
|
display: display
|
|
11391
11383
|
};
|
|
11392
|
-
return
|
|
11384
|
+
return _react["default"].createElement("div", {
|
|
11393
11385
|
style: style
|
|
11394
|
-
},
|
|
11386
|
+
}, _react["default"].createElement("div", {
|
|
11395
11387
|
ref: this.ref
|
|
11396
11388
|
}));
|
|
11397
11389
|
}
|
|
@@ -11449,16 +11441,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
11449
11441
|
|
|
11450
11442
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
11451
11443
|
|
|
11452
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
11453
|
-
|
|
11454
11444
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
11455
11445
|
|
|
11456
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
11457
|
-
|
|
11458
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
11459
|
-
|
|
11460
11446
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
11461
11447
|
|
|
11448
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
11449
|
+
|
|
11462
11450
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
11463
11451
|
|
|
11464
11452
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -11469,12 +11457,14 @@ var SDK_URL = 'https://widget.mixcloud.com/media/js/widgetApi.js';
|
|
|
11469
11457
|
var SDK_GLOBAL = 'Mixcloud';
|
|
11470
11458
|
var MATCH_URL = /mixcloud\.com\/([^/]+\/[^/]+)/;
|
|
11471
11459
|
|
|
11472
|
-
var Mixcloud =
|
|
11460
|
+
var Mixcloud =
|
|
11461
|
+
/*#__PURE__*/
|
|
11462
|
+
function (_Component) {
|
|
11473
11463
|
_inherits(Mixcloud, _Component);
|
|
11474
11464
|
|
|
11475
|
-
var _super = _createSuper(Mixcloud);
|
|
11476
|
-
|
|
11477
11465
|
function Mixcloud() {
|
|
11466
|
+
var _getPrototypeOf2;
|
|
11467
|
+
|
|
11478
11468
|
var _this;
|
|
11479
11469
|
|
|
11480
11470
|
_classCallCheck(this, Mixcloud);
|
|
@@ -11483,7 +11473,7 @@ var Mixcloud = /*#__PURE__*/function (_Component) {
|
|
|
11483
11473
|
args[_key] = arguments[_key];
|
|
11484
11474
|
}
|
|
11485
11475
|
|
|
11486
|
-
_this =
|
|
11476
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Mixcloud)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
11487
11477
|
|
|
11488
11478
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
11489
11479
|
|
|
@@ -11586,7 +11576,7 @@ var Mixcloud = /*#__PURE__*/function (_Component) {
|
|
|
11586
11576
|
})); // We have to give the iframe a key here to prevent a
|
|
11587
11577
|
// weird dialog appearing when loading a new track
|
|
11588
11578
|
|
|
11589
|
-
return
|
|
11579
|
+
return _react["default"].createElement("iframe", {
|
|
11590
11580
|
key: id,
|
|
11591
11581
|
ref: this.ref,
|
|
11592
11582
|
style: style,
|
|
@@ -11646,33 +11636,23 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
11646
11636
|
|
|
11647
11637
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
11648
11638
|
|
|
11649
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
11650
|
-
|
|
11651
11639
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
11652
11640
|
|
|
11653
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
11654
|
-
|
|
11655
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
11656
|
-
|
|
11657
11641
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
11658
11642
|
|
|
11643
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
11644
|
+
|
|
11659
11645
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
11660
11646
|
|
|
11661
11647
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
11662
11648
|
|
|
11663
11649
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
11664
11650
|
|
|
11665
|
-
function _createForOfIteratorHelper(o) { if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) { if (Array.isArray(o) || (o = _unsupportedIterableToArray(o))) { var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var it, normalCompletion = true, didErr = false, err; return { s: function s() { it = o[Symbol.iterator](); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; }
|
|
11666
|
-
|
|
11667
|
-
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(n); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
11668
|
-
|
|
11669
|
-
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
11670
|
-
|
|
11671
11651
|
var IOS = typeof navigator !== 'undefined' && /iPad|iPhone|iPod/.test(navigator.userAgent) && !window.MSStream;
|
|
11672
11652
|
var AUDIO_EXTENSIONS = /\.(m4a|mp4a|mpga|mp2|mp2a|mp3|m2a|m3a|wav|weba|aac|oga|spx)($|\?)/i;
|
|
11673
11653
|
var VIDEO_EXTENSIONS = /\.(mp4|og[gv]|webm|mov|m4v)($|\?)/i;
|
|
11674
11654
|
var HLS_EXTENSIONS = /\.(m3u8)($|\?)/i;
|
|
11675
|
-
var HLS_SDK_URL = 'https://cdn.jsdelivr.net/npm/hls.js@VERSION
|
|
11655
|
+
var HLS_SDK_URL = 'https://cdn.jsdelivr.net/npm/hls.js@VERSION';
|
|
11676
11656
|
var HLS_GLOBAL = 'Hls';
|
|
11677
11657
|
var DASH_EXTENSIONS = /\.(mpd)($|\?)/i;
|
|
11678
11658
|
var DASH_SDK_URL = 'https://cdnjs.cloudflare.com/ajax/libs/dashjs/VERSION/dash.all.min.js';
|
|
@@ -11681,11 +11661,12 @@ var MATCH_DROPBOX_URL = /www\.dropbox\.com\/.+/;
|
|
|
11681
11661
|
|
|
11682
11662
|
function canPlay(url) {
|
|
11683
11663
|
if (url instanceof Array) {
|
|
11684
|
-
var
|
|
11685
|
-
|
|
11664
|
+
var _iteratorNormalCompletion = true;
|
|
11665
|
+
var _didIteratorError = false;
|
|
11666
|
+
var _iteratorError = undefined;
|
|
11686
11667
|
|
|
11687
11668
|
try {
|
|
11688
|
-
for (_iterator.
|
|
11669
|
+
for (var _iterator = url[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
|
|
11689
11670
|
var item = _step.value;
|
|
11690
11671
|
|
|
11691
11672
|
if (typeof item === 'string' && canPlay(item)) {
|
|
@@ -11697,9 +11678,18 @@ function canPlay(url) {
|
|
|
11697
11678
|
}
|
|
11698
11679
|
}
|
|
11699
11680
|
} catch (err) {
|
|
11700
|
-
|
|
11681
|
+
_didIteratorError = true;
|
|
11682
|
+
_iteratorError = err;
|
|
11701
11683
|
} finally {
|
|
11702
|
-
|
|
11684
|
+
try {
|
|
11685
|
+
if (!_iteratorNormalCompletion && _iterator["return"] != null) {
|
|
11686
|
+
_iterator["return"]();
|
|
11687
|
+
}
|
|
11688
|
+
} finally {
|
|
11689
|
+
if (_didIteratorError) {
|
|
11690
|
+
throw _iteratorError;
|
|
11691
|
+
}
|
|
11692
|
+
}
|
|
11703
11693
|
}
|
|
11704
11694
|
|
|
11705
11695
|
return false;
|
|
@@ -11723,12 +11713,14 @@ function canEnablePIP(url) {
|
|
|
11723
11713
|
return canPlay(url) && (!!document.pictureInPictureEnabled || supportsWebKitPresentationMode()) && !AUDIO_EXTENSIONS.test(url);
|
|
11724
11714
|
}
|
|
11725
11715
|
|
|
11726
|
-
var FilePlayer =
|
|
11716
|
+
var FilePlayer =
|
|
11717
|
+
/*#__PURE__*/
|
|
11718
|
+
function (_Component) {
|
|
11727
11719
|
_inherits(FilePlayer, _Component);
|
|
11728
11720
|
|
|
11729
|
-
var _super = _createSuper(FilePlayer);
|
|
11730
|
-
|
|
11731
11721
|
function FilePlayer() {
|
|
11722
|
+
var _getPrototypeOf2;
|
|
11723
|
+
|
|
11732
11724
|
var _this;
|
|
11733
11725
|
|
|
11734
11726
|
_classCallCheck(this, FilePlayer);
|
|
@@ -11737,7 +11729,7 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
|
|
|
11737
11729
|
_args[_key] = arguments[_key];
|
|
11738
11730
|
}
|
|
11739
11731
|
|
|
11740
|
-
_this =
|
|
11732
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(FilePlayer)).call.apply(_getPrototypeOf2, [this].concat(_args)));
|
|
11741
11733
|
|
|
11742
11734
|
_defineProperty(_assertThisInitialized(_this), "onReady", function () {
|
|
11743
11735
|
var _this$props;
|
|
@@ -11824,19 +11816,19 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
|
|
|
11824
11816
|
|
|
11825
11817
|
_defineProperty(_assertThisInitialized(_this), "renderSourceElement", function (source, index) {
|
|
11826
11818
|
if (typeof source === 'string') {
|
|
11827
|
-
return
|
|
11819
|
+
return _react["default"].createElement("source", {
|
|
11828
11820
|
key: index,
|
|
11829
11821
|
src: source
|
|
11830
11822
|
});
|
|
11831
11823
|
}
|
|
11832
11824
|
|
|
11833
|
-
return
|
|
11825
|
+
return _react["default"].createElement("source", _extends({
|
|
11834
11826
|
key: index
|
|
11835
11827
|
}, source));
|
|
11836
11828
|
});
|
|
11837
11829
|
|
|
11838
11830
|
_defineProperty(_assertThisInitialized(_this), "renderTrack", function (track, index) {
|
|
11839
|
-
return
|
|
11831
|
+
return _react["default"].createElement("track", _extends({
|
|
11840
11832
|
key: index
|
|
11841
11833
|
}, track));
|
|
11842
11834
|
});
|
|
@@ -11874,10 +11866,6 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
|
|
|
11874
11866
|
key: "componentWillUnmount",
|
|
11875
11867
|
value: function componentWillUnmount() {
|
|
11876
11868
|
this.removeListeners(this.player);
|
|
11877
|
-
|
|
11878
|
-
if (this.hls) {
|
|
11879
|
-
this.hls.destroy();
|
|
11880
|
-
}
|
|
11881
11869
|
}
|
|
11882
11870
|
}, {
|
|
11883
11871
|
key: "addListeners",
|
|
@@ -12008,6 +11996,10 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
|
|
|
12008
11996
|
value: function stop() {
|
|
12009
11997
|
this.player.removeAttribute('src');
|
|
12010
11998
|
|
|
11999
|
+
if (this.hls) {
|
|
12000
|
+
this.hls.destroy();
|
|
12001
|
+
}
|
|
12002
|
+
|
|
12011
12003
|
if (this.dash) {
|
|
12012
12004
|
this.dash.reset();
|
|
12013
12005
|
}
|
|
@@ -12119,7 +12111,7 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
|
|
|
12119
12111
|
width: width === 'auto' ? width : '100%',
|
|
12120
12112
|
height: height === 'auto' ? height : '100%'
|
|
12121
12113
|
};
|
|
12122
|
-
return
|
|
12114
|
+
return _react["default"].createElement(Element, _extends({
|
|
12123
12115
|
ref: this.ref,
|
|
12124
12116
|
src: this.getSource(url),
|
|
12125
12117
|
style: style,
|
|
@@ -12209,16 +12201,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
12209
12201
|
|
|
12210
12202
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
12211
12203
|
|
|
12212
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
12213
|
-
|
|
12214
12204
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
12215
12205
|
|
|
12216
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
12217
|
-
|
|
12218
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
12219
|
-
|
|
12220
12206
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
12221
12207
|
|
|
12208
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
12209
|
+
|
|
12222
12210
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
12223
12211
|
|
|
12224
12212
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -12227,12 +12215,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
12227
12215
|
|
|
12228
12216
|
var ICON_SIZE = '64px';
|
|
12229
12217
|
|
|
12230
|
-
var Preview =
|
|
12218
|
+
var Preview =
|
|
12219
|
+
/*#__PURE__*/
|
|
12220
|
+
function (_Component) {
|
|
12231
12221
|
_inherits(Preview, _Component);
|
|
12232
12222
|
|
|
12233
|
-
var _super = _createSuper(Preview);
|
|
12234
|
-
|
|
12235
12223
|
function Preview() {
|
|
12224
|
+
var _getPrototypeOf2;
|
|
12225
|
+
|
|
12236
12226
|
var _this;
|
|
12237
12227
|
|
|
12238
12228
|
_classCallCheck(this, Preview);
|
|
@@ -12241,7 +12231,7 @@ var Preview = /*#__PURE__*/function (_Component) {
|
|
|
12241
12231
|
args[_key] = arguments[_key];
|
|
12242
12232
|
}
|
|
12243
12233
|
|
|
12244
|
-
_this =
|
|
12234
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Preview)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
12245
12235
|
|
|
12246
12236
|
_defineProperty(_assertThisInitialized(_this), "mounted", false);
|
|
12247
12237
|
|
|
@@ -12339,15 +12329,15 @@ var Preview = /*#__PURE__*/function (_Component) {
|
|
|
12339
12329
|
}
|
|
12340
12330
|
};
|
|
12341
12331
|
|
|
12342
|
-
var defaultPlayIcon =
|
|
12332
|
+
var defaultPlayIcon = _react["default"].createElement("div", {
|
|
12343
12333
|
style: styles.shadow,
|
|
12344
12334
|
className: "react-player__shadow"
|
|
12345
|
-
},
|
|
12335
|
+
}, _react["default"].createElement("div", {
|
|
12346
12336
|
style: styles.playIcon,
|
|
12347
12337
|
className: "react-player__play-icon"
|
|
12348
12338
|
}));
|
|
12349
12339
|
|
|
12350
|
-
return
|
|
12340
|
+
return _react["default"].createElement("div", {
|
|
12351
12341
|
style: styles.preview,
|
|
12352
12342
|
className: "react-player__preview",
|
|
12353
12343
|
onClick: onClick
|
|
@@ -12384,12 +12374,6 @@ var _Player = _interopRequireDefault(Player_1);
|
|
|
12384
12374
|
|
|
12385
12375
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
12386
12376
|
|
|
12387
|
-
function _createForOfIteratorHelper(o) { if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) { if (Array.isArray(o) || (o = _unsupportedIterableToArray(o))) { var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var it, normalCompletion = true, didErr = false, err; return { s: function s() { it = o[Symbol.iterator](); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; }
|
|
12388
|
-
|
|
12389
|
-
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(n); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
12390
|
-
|
|
12391
|
-
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
12392
|
-
|
|
12393
12377
|
var PRELOAD_PLAYERS = [{
|
|
12394
12378
|
Player: YouTube_1.YouTube,
|
|
12395
12379
|
configKey: 'youtube',
|
|
@@ -12410,16 +12394,16 @@ var PRELOAD_PLAYERS = [{
|
|
|
12410
12394
|
|
|
12411
12395
|
function renderPreloadPlayers(url, controls, config) {
|
|
12412
12396
|
var players = [];
|
|
12413
|
-
|
|
12414
|
-
var
|
|
12415
|
-
|
|
12397
|
+
var _iteratorNormalCompletion = true;
|
|
12398
|
+
var _didIteratorError = false;
|
|
12399
|
+
var _iteratorError = undefined;
|
|
12416
12400
|
|
|
12417
12401
|
try {
|
|
12418
|
-
for (_iterator.
|
|
12402
|
+
for (var _iterator = PRELOAD_PLAYERS[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
|
|
12419
12403
|
var player = _step.value;
|
|
12420
12404
|
|
|
12421
12405
|
if (!player.Player.canPlay(url) && config[player.configKey].preload) {
|
|
12422
|
-
players.push(
|
|
12406
|
+
players.push(_react["default"].createElement(_Player["default"], {
|
|
12423
12407
|
key: player.Player.displayName,
|
|
12424
12408
|
activePlayer: player.Player,
|
|
12425
12409
|
url: player.url,
|
|
@@ -12431,9 +12415,18 @@ function renderPreloadPlayers(url, controls, config) {
|
|
|
12431
12415
|
}
|
|
12432
12416
|
}
|
|
12433
12417
|
} catch (err) {
|
|
12434
|
-
|
|
12418
|
+
_didIteratorError = true;
|
|
12419
|
+
_iteratorError = err;
|
|
12435
12420
|
} finally {
|
|
12436
|
-
|
|
12421
|
+
try {
|
|
12422
|
+
if (!_iteratorNormalCompletion && _iterator["return"] != null) {
|
|
12423
|
+
_iterator["return"]();
|
|
12424
|
+
}
|
|
12425
|
+
} finally {
|
|
12426
|
+
if (_didIteratorError) {
|
|
12427
|
+
throw _iteratorError;
|
|
12428
|
+
}
|
|
12429
|
+
}
|
|
12437
12430
|
}
|
|
12438
12431
|
|
|
12439
12432
|
return players;
|
|
@@ -12557,17 +12550,13 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
|
|
|
12557
12550
|
|
|
12558
12551
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
12559
12552
|
|
|
12560
|
-
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) ||
|
|
12561
|
-
|
|
12562
|
-
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
12563
|
-
|
|
12564
|
-
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(n); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
12553
|
+
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _nonIterableSpread(); }
|
|
12565
12554
|
|
|
12566
|
-
function
|
|
12555
|
+
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance"); }
|
|
12567
12556
|
|
|
12568
|
-
function
|
|
12557
|
+
function _iterableToArray(iter) { if (Symbol.iterator in Object(iter) || Object.prototype.toString.call(iter) === "[object Arguments]") return Array.from(iter); }
|
|
12569
12558
|
|
|
12570
|
-
function
|
|
12559
|
+
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = new Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } }
|
|
12571
12560
|
|
|
12572
12561
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
12573
12562
|
|
|
@@ -12575,16 +12564,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
12575
12564
|
|
|
12576
12565
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
12577
12566
|
|
|
12578
|
-
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
12579
|
-
|
|
12580
12567
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
12581
12568
|
|
|
12582
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
12583
|
-
|
|
12584
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
12585
|
-
|
|
12586
12569
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
12587
12570
|
|
|
12571
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
12572
|
+
|
|
12588
12573
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
12589
12574
|
|
|
12590
12575
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -12594,12 +12579,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
12594
12579
|
var SUPPORTED_PROPS = Object.keys(props.propTypes);
|
|
12595
12580
|
var customPlayers = [];
|
|
12596
12581
|
|
|
12597
|
-
var ReactPlayer =
|
|
12582
|
+
var ReactPlayer =
|
|
12583
|
+
/*#__PURE__*/
|
|
12584
|
+
function (_Component) {
|
|
12598
12585
|
_inherits(ReactPlayer, _Component);
|
|
12599
12586
|
|
|
12600
|
-
var _super = _createSuper(ReactPlayer);
|
|
12601
|
-
|
|
12602
12587
|
function ReactPlayer() {
|
|
12588
|
+
var _getPrototypeOf2;
|
|
12589
|
+
|
|
12603
12590
|
var _this;
|
|
12604
12591
|
|
|
12605
12592
|
_classCallCheck(this, ReactPlayer);
|
|
@@ -12608,7 +12595,7 @@ var ReactPlayer = /*#__PURE__*/function (_Component) {
|
|
|
12608
12595
|
args[_key] = arguments[_key];
|
|
12609
12596
|
}
|
|
12610
12597
|
|
|
12611
|
-
_this =
|
|
12598
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(ReactPlayer)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
12612
12599
|
|
|
12613
12600
|
_defineProperty(_assertThisInitialized(_this), "config", (0, utils.getConfig)(_this.props, props.defaultProps, true));
|
|
12614
12601
|
|
|
@@ -12719,7 +12706,7 @@ var ReactPlayer = /*#__PURE__*/function (_Component) {
|
|
|
12719
12706
|
key: "renderActivePlayer",
|
|
12720
12707
|
value: function renderActivePlayer(url, activePlayer) {
|
|
12721
12708
|
if (!url) return null;
|
|
12722
|
-
return
|
|
12709
|
+
return _react["default"].createElement(_Player4["default"], _extends({}, this.props, {
|
|
12723
12710
|
key: activePlayer.displayName,
|
|
12724
12711
|
ref: this.activePlayerRef,
|
|
12725
12712
|
config: this.config,
|
|
@@ -12756,14 +12743,14 @@ var ReactPlayer = /*#__PURE__*/function (_Component) {
|
|
|
12756
12743
|
var preloadPlayers = (0, _preload["default"])(url, controls, this.config);
|
|
12757
12744
|
var players = [renderedActivePlayer].concat(_toConsumableArray(preloadPlayers)).sort(this.sortPlayers);
|
|
12758
12745
|
|
|
12759
|
-
var preview =
|
|
12746
|
+
var preview = _react["default"].createElement(_Preview["default"], {
|
|
12760
12747
|
url: url,
|
|
12761
12748
|
light: light,
|
|
12762
12749
|
playIcon: playIcon,
|
|
12763
12750
|
onClick: this.handleClickPreview
|
|
12764
12751
|
});
|
|
12765
12752
|
|
|
12766
|
-
return
|
|
12753
|
+
return _react["default"].createElement(Wrapper, _extends({
|
|
12767
12754
|
ref: this.wrapperRef,
|
|
12768
12755
|
style: _objectSpread({}, style, {
|
|
12769
12756
|
width: width,
|
|
@@ -14192,16 +14179,16 @@ var RelatedTopicsDropdown = function RelatedTopicsDropdown(_ref) {
|
|
|
14192
14179
|
_ref$className = _ref.className,
|
|
14193
14180
|
className = _ref$className === undefined ? '' : _ref$className;
|
|
14194
14181
|
|
|
14195
|
-
/*
|
|
14196
|
-
Props accepted - parentTaxonomy(required, object), subTaxonomy(required, array), page(optional), exclude(optional), variant(optional), className(optional)
|
|
14197
|
-
example:
|
|
14198
|
-
<RelatedTopicDropdown
|
|
14199
|
-
page='/clinical'
|
|
14200
|
-
exclude="clinical"
|
|
14201
|
-
className='mb-3'
|
|
14202
|
-
parentTaxonomy={props.parentTaxonomy}
|
|
14203
|
-
subTaxonomies={props.subTaxonomies}
|
|
14204
|
-
/>
|
|
14182
|
+
/*
|
|
14183
|
+
Props accepted - parentTaxonomy(required, object), subTaxonomy(required, array), page(optional), exclude(optional), variant(optional), className(optional)
|
|
14184
|
+
example:
|
|
14185
|
+
<RelatedTopicDropdown
|
|
14186
|
+
page='/clinical'
|
|
14187
|
+
exclude="clinical"
|
|
14188
|
+
className='mb-3'
|
|
14189
|
+
parentTaxonomy={props.parentTaxonomy}
|
|
14190
|
+
subTaxonomies={props.subTaxonomies}
|
|
14191
|
+
/>
|
|
14205
14192
|
*/
|
|
14206
14193
|
if (subTaxonomies.length === 0 && parentTaxonomy) {
|
|
14207
14194
|
if (parentTaxonomy.identifier == exclude) {
|
|
@@ -14239,19 +14226,19 @@ var RelatedTopicsDropdown = function RelatedTopicsDropdown(_ref) {
|
|
|
14239
14226
|
}
|
|
14240
14227
|
};
|
|
14241
14228
|
|
|
14242
|
-
/*
|
|
14243
|
-
This dropdown is used inside Article body to display related content placement pages
|
|
14244
|
-
sample usage: <ArticleDetailDropdown contentPlacement={content_placement} exclude={['News',]} />
|
|
14245
|
-
|
|
14246
|
-
in article query, need to add '...' to content_placement to retreive additional info needed
|
|
14247
|
-
|
|
14248
|
-
'content_placement': taxonomyMapping[]-> {
|
|
14249
|
-
...,
|
|
14250
|
-
'ancestor': parent->parent->identifier,
|
|
14251
|
-
'parent': parent->identifier,
|
|
14252
|
-
'path': identifier
|
|
14253
|
-
}
|
|
14254
|
-
|
|
14229
|
+
/*
|
|
14230
|
+
This dropdown is used inside Article body to display related content placement pages
|
|
14231
|
+
sample usage: <ArticleDetailDropdown contentPlacement={content_placement} exclude={['News',]} />
|
|
14232
|
+
|
|
14233
|
+
in article query, need to add '...' to content_placement to retreive additional info needed
|
|
14234
|
+
|
|
14235
|
+
'content_placement': taxonomyMapping[]-> {
|
|
14236
|
+
...,
|
|
14237
|
+
'ancestor': parent->parent->identifier,
|
|
14238
|
+
'parent': parent->identifier,
|
|
14239
|
+
'path': identifier
|
|
14240
|
+
}
|
|
14241
|
+
|
|
14255
14242
|
*/
|
|
14256
14243
|
|
|
14257
14244
|
var ArticleDetailDropdown = function ArticleDetailDropdown(props) {
|
|
@@ -15090,34 +15077,34 @@ var GridHero = function GridHero(props) {
|
|
|
15090
15077
|
);
|
|
15091
15078
|
};
|
|
15092
15079
|
|
|
15093
|
-
/*
|
|
15094
|
-
Sample query
|
|
15095
|
-
let references = ''
|
|
15096
|
-
if(article.taxonomyMapping.length > 0){
|
|
15097
|
-
article.taxonomyMapping.forEach((ref, index) => {
|
|
15098
|
-
references = references + `references('${ref._ref}') `
|
|
15099
|
-
if(index+1 !== article.taxonomyMapping.length){
|
|
15100
|
-
references = references + ` && `
|
|
15101
|
-
}
|
|
15102
|
-
})
|
|
15103
|
-
}
|
|
15104
|
-
|
|
15105
|
-
const relatedArticlesQuery = `*[!(_id in path("drafts.**")) && _type == "article" && title !='${article.title}' && defined(title) && is_visible == true && ( references('article.documentGroup._id') || ${references} ) && published <= '${today}'] | order(published desc) [0...4] {
|
|
15106
|
-
...,
|
|
15107
|
-
title,
|
|
15108
|
-
summary,
|
|
15109
|
-
thumbnail,
|
|
15110
|
-
url,
|
|
15111
|
-
published,
|
|
15112
|
-
authorMapping[]->,
|
|
15113
|
-
contentCategory->
|
|
15114
|
-
}`
|
|
15115
|
-
const relatedArticles = await client.fetch(relatedArticlesQuery)
|
|
15116
|
-
|
|
15117
|
-
Sample usage
|
|
15118
|
-
<RelatedContent dataRecord={props.relatedArticles} client={client} showAuthor showPublished reverse/>
|
|
15119
|
-
|
|
15120
|
-
|
|
15080
|
+
/*
|
|
15081
|
+
Sample query
|
|
15082
|
+
let references = ''
|
|
15083
|
+
if(article.taxonomyMapping.length > 0){
|
|
15084
|
+
article.taxonomyMapping.forEach((ref, index) => {
|
|
15085
|
+
references = references + `references('${ref._ref}') `
|
|
15086
|
+
if(index+1 !== article.taxonomyMapping.length){
|
|
15087
|
+
references = references + ` && `
|
|
15088
|
+
}
|
|
15089
|
+
})
|
|
15090
|
+
}
|
|
15091
|
+
|
|
15092
|
+
const relatedArticlesQuery = `*[!(_id in path("drafts.**")) && _type == "article" && title !='${article.title}' && defined(title) && is_visible == true && ( references('article.documentGroup._id') || ${references} ) && published <= '${today}'] | order(published desc) [0...4] {
|
|
15093
|
+
...,
|
|
15094
|
+
title,
|
|
15095
|
+
summary,
|
|
15096
|
+
thumbnail,
|
|
15097
|
+
url,
|
|
15098
|
+
published,
|
|
15099
|
+
authorMapping[]->,
|
|
15100
|
+
contentCategory->
|
|
15101
|
+
}`
|
|
15102
|
+
const relatedArticles = await client.fetch(relatedArticlesQuery)
|
|
15103
|
+
|
|
15104
|
+
Sample usage
|
|
15105
|
+
<RelatedContent dataRecord={props.relatedArticles} client={client} showAuthor showPublished reverse/>
|
|
15106
|
+
|
|
15107
|
+
|
|
15121
15108
|
*/
|
|
15122
15109
|
var RelatedContent = function RelatedContent(props) {
|
|
15123
15110
|
var client = props.client,
|
|
@@ -15184,21 +15171,21 @@ var RelatedContent = function RelatedContent(props) {
|
|
|
15184
15171
|
);
|
|
15185
15172
|
};
|
|
15186
15173
|
|
|
15187
|
-
/*
|
|
15188
|
-
Example usage - targetedonc.com/latest-conference
|
|
15189
|
-
const query = `*[!(_id in path("drafts.**")) && _type == "article" && defined(title) && is_visible == true && published <= '${today}' && references('b49d36b8-aa56-4183-a2bc-1568c229fb72') ] | order(published desc) [$from...$to] {
|
|
15190
|
-
...,
|
|
15191
|
-
title,
|
|
15192
|
-
summary,
|
|
15193
|
-
thumbnail,
|
|
15194
|
-
url,
|
|
15195
|
-
published,
|
|
15196
|
-
documentGroup->,
|
|
15197
|
-
contentCategory->,
|
|
15198
|
-
'pageNumber': ${currentPage}
|
|
15199
|
-
}`
|
|
15200
|
-
|
|
15201
|
-
const posts = await client.fetch(query, params)
|
|
15174
|
+
/*
|
|
15175
|
+
Example usage - targetedonc.com/latest-conference
|
|
15176
|
+
const query = `*[!(_id in path("drafts.**")) && _type == "article" && defined(title) && is_visible == true && published <= '${today}' && references('b49d36b8-aa56-4183-a2bc-1568c229fb72') ] | order(published desc) [$from...$to] {
|
|
15177
|
+
...,
|
|
15178
|
+
title,
|
|
15179
|
+
summary,
|
|
15180
|
+
thumbnail,
|
|
15181
|
+
url,
|
|
15182
|
+
published,
|
|
15183
|
+
documentGroup->,
|
|
15184
|
+
contentCategory->,
|
|
15185
|
+
'pageNumber': ${currentPage}
|
|
15186
|
+
}`
|
|
15187
|
+
|
|
15188
|
+
const posts = await client.fetch(query, params)
|
|
15202
15189
|
*/
|
|
15203
15190
|
|
|
15204
15191
|
var ConferenceArticleCard = function ConferenceArticleCard(props) {
|
|
@@ -15825,27 +15812,27 @@ var _initialiseProps = function _initialiseProps() {
|
|
|
15825
15812
|
};
|
|
15826
15813
|
|
|
15827
15814
|
var KMTracker = function KMTracker(props) {
|
|
15828
|
-
|
|
15815
|
+
var id = props.id;
|
|
15829
15816
|
|
|
15830
|
-
|
|
15817
|
+
if (document && id) {
|
|
15831
15818
|
(function () {
|
|
15832
|
-
|
|
15819
|
+
var ecnJquery = document.createElement('script');
|
|
15833
15820
|
|
|
15834
|
-
|
|
15835
|
-
|
|
15836
|
-
|
|
15821
|
+
ecnJquery.type = 'text/javascript';
|
|
15822
|
+
ecnJquery.async = true;
|
|
15823
|
+
ecnJquery.src = 'https://apidt.ecn5.com/ECN_jQuery.min.js';
|
|
15837
15824
|
|
|
15838
|
-
|
|
15825
|
+
var ecnScript = document.createElement('script');
|
|
15839
15826
|
|
|
15840
|
-
|
|
15841
|
-
|
|
15842
|
-
|
|
15843
|
-
|
|
15827
|
+
ecnScript.type = 'text/javascript';
|
|
15828
|
+
ecnScript.async = true;
|
|
15829
|
+
ecnScript.id = 'km-tracker';
|
|
15830
|
+
ecnScript.src = 'https://apidt.ecn5.com/ECN_tracker_Secure.js?TrackerKey=' + id;
|
|
15844
15831
|
|
|
15845
|
-
|
|
15846
|
-
|
|
15847
|
-
|
|
15848
|
-
|
|
15832
|
+
document.head.appendChild(ecnJquery);
|
|
15833
|
+
document.head.appendChild(ecnScript);
|
|
15834
|
+
})();
|
|
15835
|
+
}
|
|
15849
15836
|
};
|
|
15850
15837
|
|
|
15851
15838
|
exports.AdSlot = AdSlot.DFPAdSlot;
|