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