@mjhls/mjh-framework 1.0.537 → 1.0.540
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 +172 -172
- package/dist/cjs/AD.js +1 -1
- package/dist/cjs/AD300x250.js +3 -3
- package/dist/cjs/AD300x250x600.js +3 -3
- package/dist/cjs/AD728x90.js +5 -5
- package/dist/cjs/ADFloatingFooter.js +5 -5
- package/dist/cjs/ADGutter.js +2 -2
- package/dist/cjs/ADSponsoredResources.js +2 -2
- package/dist/cjs/ADWebcast.js +2 -2
- package/dist/cjs/ADWelcome.js +2 -2
- package/dist/cjs/AccordionPanel.js +2 -2
- package/dist/cjs/AdSlot.js +2 -2
- package/dist/cjs/AdSlotsProvider.js +1 -1
- package/dist/cjs/ArticleQueue.js +10 -10
- package/dist/cjs/Auth.js +507 -256
- package/dist/cjs/{BlockContent-77f81ffc.js → BlockContent-f942392e.js} +1 -1
- package/dist/cjs/CMEDeck.js +5 -5
- package/dist/cjs/Column3.js +4 -4
- package/dist/cjs/ConferenceArticleCard.js +17 -17
- package/dist/cjs/DeckContent.js +15 -15
- package/dist/cjs/DeckQueue.js +6 -6
- package/dist/cjs/{Dfp-fcdeabc4.js → Dfp-fbe32b96.js} +1 -1
- package/dist/cjs/EventsDeck.js +22 -22
- package/dist/cjs/ExternalResources.js +6 -6
- package/dist/cjs/Feature.js +3 -3
- package/dist/cjs/ForbesHero.js +2 -2
- package/dist/cjs/GridContent.js +10 -10
- package/dist/cjs/GridHero.js +2 -2
- package/dist/cjs/GroupDeck.js +5 -5
- package/dist/cjs/HamMagazine.js +218 -39
- package/dist/cjs/Hero.js +1 -1
- package/dist/cjs/HorizontalHero.js +5 -5
- package/dist/cjs/IssueContentDeck.js +2 -2
- package/dist/cjs/IssueDeck.js +2 -2
- package/dist/cjs/IssueLanding.js +36 -36
- package/dist/cjs/KMTracker.js +15 -15
- package/dist/cjs/LeftNav.js +2 -2
- package/dist/cjs/MasterDeck.js +20 -23
- package/dist/cjs/NavDvm.js +214 -14
- package/dist/cjs/NavMagazine.js +212 -25
- package/dist/cjs/NavNative.js +201 -24
- package/dist/cjs/NavNormal.js +229 -10
- package/dist/cjs/OncliveHero.js +4 -4
- package/dist/cjs/OncliveLargeHero.js +2 -2
- package/dist/cjs/PartnerDetailListing.js +14 -1210
- package/dist/cjs/PdfDownload.js +2 -2
- package/dist/cjs/PublicationDeck.js +1 -1
- package/dist/cjs/PublicationLanding.js +41 -34
- package/dist/cjs/QueueDeckExpanded.js +9 -9
- package/dist/cjs/RelatedContent.js +30 -30
- package/dist/cjs/RelatedTopicsDropdown.js +10 -10
- package/dist/cjs/SideFooter.js +2 -2
- package/dist/cjs/TaxonomyCard.js +2 -2
- package/dist/cjs/TemplateNormal.js +9 -9
- package/dist/cjs/ThumbnailCard.js +1 -1
- package/dist/cjs/Ustream.js +7 -7
- package/dist/cjs/VerticalHero.js +2 -2
- package/dist/cjs/VideoSeriesFilter.js +1 -1
- package/dist/cjs/VideoSeriesListing.js +6 -6
- package/dist/cjs/View.js +38 -38
- package/dist/cjs/YahooHero.js +2 -2
- package/dist/cjs/YoutubeGroup.js +5 -5
- package/dist/cjs/getQuery.js +1 -1
- package/dist/cjs/getRelatedArticle.js +6 -355
- package/dist/cjs/getSerializers.js +449 -437
- package/dist/cjs/{getTargeting-3d208b98.js → getTargeting-b15993cb.js} +11 -11
- package/dist/cjs/getTargeting.js +1 -1
- package/dist/cjs/{iconBase-637d3f1e.js → iconBase-68959171.js} +1 -0
- package/dist/cjs/{index-3294d3bc.js → index-5be2866f.js} +1 -1
- package/dist/cjs/{index-be0c82be.js → index-b5eb3ff8.js} +20 -19
- package/dist/cjs/{index-fa3cec70.js → index-f7ee1612.js} +4 -6
- package/dist/cjs/{index.es-9110add6.js → index.es-ab3f2690.js} +3 -1
- package/dist/cjs/index.esm-0e5c6a9e.js +11 -0
- package/dist/cjs/{index.esm-c0d8b44b.js → index.esm-66ffa47a.js} +1 -1
- package/dist/cjs/{index.esm-25423c2f.js → index.esm-89fabc47.js} +1 -1
- package/dist/cjs/{index.esm-fcdbd2c6.js → index.esm-fbd1f7e9.js} +1 -1
- package/dist/cjs/index.js +23 -21
- package/dist/cjs/{main-88348b15.js → main-bc4db521.js} +66 -35
- package/dist/cjs/{moment-575fe24c.js → moment-66a6a284.js} +1 -1
- package/dist/cjs/urlFor.js +2 -2
- package/dist/esm/AD.js +1 -1
- package/dist/esm/AD300x250.js +3 -3
- package/dist/esm/AD300x250x600.js +3 -3
- package/dist/esm/AD728x90.js +5 -5
- package/dist/esm/ADFloatingFooter.js +5 -5
- package/dist/esm/ADGutter.js +2 -2
- package/dist/esm/ADSponsoredResources.js +2 -2
- package/dist/esm/ADWebcast.js +2 -2
- package/dist/esm/ADWelcome.js +2 -2
- package/dist/esm/AccordionPanel.js +2 -2
- package/dist/esm/AdSlot.js +2 -2
- package/dist/esm/AdSlotsProvider.js +1 -1
- package/dist/esm/ArticleQueue.js +10 -10
- package/dist/esm/Auth.js +499 -248
- package/dist/esm/{BlockContent-e9b4ddcf.js → BlockContent-a614acdf.js} +1 -1
- package/dist/esm/CMEDeck.js +5 -5
- package/dist/esm/Column3.js +4 -4
- package/dist/esm/ConferenceArticleCard.js +17 -17
- package/dist/esm/DeckContent.js +15 -15
- package/dist/esm/DeckQueue.js +6 -6
- package/dist/esm/{Dfp-81a052c2.js → Dfp-ae9336e2.js} +1 -1
- package/dist/esm/EventsDeck.js +22 -22
- package/dist/esm/ExternalResources.js +6 -6
- package/dist/esm/Feature.js +3 -3
- package/dist/esm/ForbesHero.js +2 -2
- package/dist/esm/GridContent.js +10 -10
- package/dist/esm/GridHero.js +2 -2
- package/dist/esm/GroupDeck.js +5 -5
- package/dist/esm/HamMagazine.js +218 -39
- package/dist/esm/Hero.js +1 -1
- package/dist/esm/HorizontalHero.js +4 -4
- package/dist/esm/IssueContentDeck.js +2 -2
- package/dist/esm/IssueDeck.js +2 -2
- package/dist/esm/IssueLanding.js +36 -36
- package/dist/esm/KMTracker.js +15 -15
- package/dist/esm/LeftNav.js +2 -2
- package/dist/esm/MasterDeck.js +20 -23
- package/dist/esm/NavDvm.js +215 -15
- package/dist/esm/NavMagazine.js +212 -25
- package/dist/esm/NavNative.js +201 -24
- package/dist/esm/NavNormal.js +230 -11
- package/dist/esm/OncliveHero.js +4 -4
- package/dist/esm/OncliveLargeHero.js +2 -2
- package/dist/esm/PartnerDetailListing.js +12 -1208
- package/dist/esm/PdfDownload.js +2 -2
- package/dist/esm/PublicationDeck.js +1 -1
- package/dist/esm/PublicationLanding.js +41 -34
- package/dist/esm/QueueDeckExpanded.js +9 -9
- package/dist/esm/RelatedContent.js +30 -30
- package/dist/esm/RelatedTopicsDropdown.js +10 -10
- package/dist/esm/SideFooter.js +2 -2
- package/dist/esm/TaxonomyCard.js +2 -2
- package/dist/esm/TemplateNormal.js +9 -9
- package/dist/esm/ThumbnailCard.js +1 -1
- package/dist/esm/Ustream.js +5 -5
- package/dist/esm/VerticalHero.js +2 -2
- package/dist/esm/VideoSeriesFilter.js +1 -1
- package/dist/esm/VideoSeriesListing.js +6 -6
- package/dist/esm/View.js +13 -13
- package/dist/esm/YahooHero.js +2 -2
- package/dist/esm/YoutubeGroup.js +5 -5
- package/dist/esm/getQuery.js +1 -1
- package/dist/esm/getRelatedArticle.js +6 -355
- package/dist/esm/getSerializers.js +449 -437
- package/dist/esm/{getTargeting-1f2c61e3.js → getTargeting-1a0bd08d.js} +9 -9
- package/dist/esm/getTargeting.js +1 -1
- package/dist/esm/{iconBase-6ee2f2fb.js → iconBase-602d52fe.js} +1 -1
- package/dist/esm/{index-73819142.js → index-51a80699.js} +20 -19
- package/dist/esm/{index-3f4dd6f2.js → index-93ec3c59.js} +4 -6
- package/dist/esm/{index-ef6d5dcf.js → index-d2f90501.js} +1 -1
- package/dist/esm/{index.es-29c1cef5.js → index.es-938a3a58.js} +3 -1
- package/dist/esm/index.esm-16536e81.js +9 -0
- package/dist/esm/{index.esm-b97cf389.js → index.esm-4b1d94b7.js} +1 -1
- package/dist/esm/{index.esm-a7ad65ba.js → index.esm-9a4c8813.js} +1 -1
- package/dist/esm/{index.esm-9d6faf80.js → index.esm-b08f4b04.js} +1 -1
- package/dist/esm/index.js +21 -19
- package/dist/esm/{main-d7ee6151.js → main-7255814e.js} +65 -34
- package/dist/esm/{moment-e2f9b20c.js → moment-12415288.js} +1 -1
- package/dist/esm/urlFor.js +2 -2
- package/package.json +107 -107
- package/dist/cjs/index-bd6c9f56.js +0 -211
- package/dist/esm/index-db3bb315.js +0 -207
- /package/dist/cjs/{ADInfeed-d8e47444.js → ADInfeed-3404200f.js} +0 -0
- /package/dist/cjs/{ADlgInfeed-947c3a47.js → ADlgInfeed-2611e1a9.js} +0 -0
- /package/dist/esm/{ADInfeed-2eb234ae.js → ADInfeed-27674dc6.js} +0 -0
- /package/dist/esm/{ADlgInfeed-17c13711.js → ADlgInfeed-43060a77.js} +0 -0
|
@@ -9,22 +9,22 @@ require('./_library-dd23b178.js');
|
|
|
9
9
|
require('./_iter-detect-4d0352f8.js');
|
|
10
10
|
var from = require('./from-ea347372.js');
|
|
11
11
|
require('./_object-pie-68c5bcbc.js');
|
|
12
|
-
var _extends
|
|
12
|
+
var _extends = require('./extends-60837c34.js');
|
|
13
13
|
require('./web.dom.iterable-43c3e277.js');
|
|
14
14
|
require('./typeof-1869832c.js');
|
|
15
15
|
require('./_is-array-754e012d.js');
|
|
16
16
|
var React = require('react');
|
|
17
17
|
var React__default = _interopDefault(React);
|
|
18
|
-
var index = require('./index-
|
|
18
|
+
var index = require('./index-f7ee1612.js');
|
|
19
19
|
var PropTypes = _interopDefault(require('prop-types'));
|
|
20
20
|
var Router = require('next/router');
|
|
21
21
|
var Router__default = _interopDefault(Router);
|
|
22
22
|
require('./isSymbol-488934a7.js');
|
|
23
23
|
require('./debounce-32e57002.js');
|
|
24
24
|
require('react-dom');
|
|
25
|
-
var index$1 = require('./index-
|
|
25
|
+
var index$1 = require('./index-b5eb3ff8.js');
|
|
26
26
|
var index$2 = require('./index-fa0fb52c.js');
|
|
27
|
-
var main = require('./main-
|
|
27
|
+
var main = require('./main-bc4db521.js');
|
|
28
28
|
var entities = require('./entities-310b46ee.js');
|
|
29
29
|
var slicedToArray = require('./slicedToArray-8063ee51.js');
|
|
30
30
|
require('./stringify-7c5aff47.js');
|
|
@@ -32,7 +32,7 @@ require('./asyncToGenerator-8e707718.js');
|
|
|
32
32
|
require('./_set-species-4458e975.js');
|
|
33
33
|
var Segment = require('./beam-d22818d3.js');
|
|
34
34
|
var AdSlot = require('./AdSlot.js');
|
|
35
|
-
var BlockContent = require('./BlockContent-
|
|
35
|
+
var BlockContent = require('./BlockContent-f942392e.js');
|
|
36
36
|
var smoothscroll = require('./smoothscroll-95231a70.js');
|
|
37
37
|
var GroupDeck = require('./GroupDeck.js');
|
|
38
38
|
var reactBootstrap = require('react-bootstrap');
|
|
@@ -104,21 +104,18 @@ var Slideshow = function Slideshow(_ref) {
|
|
|
104
104
|
);
|
|
105
105
|
};
|
|
106
106
|
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
107
|
+
// do not edit .js files directly - edit src/index.jst
|
|
108
|
+
|
|
109
|
+
|
|
110
110
|
|
|
111
111
|
var fastDeepEqual = function equal(a, b) {
|
|
112
112
|
if (a === b) return true;
|
|
113
113
|
|
|
114
114
|
if (a && b && typeof a == 'object' && typeof b == 'object') {
|
|
115
|
-
|
|
116
|
-
, arrB = isArray(b)
|
|
117
|
-
, i
|
|
118
|
-
, length
|
|
119
|
-
, key;
|
|
115
|
+
if (a.constructor !== b.constructor) return false;
|
|
120
116
|
|
|
121
|
-
|
|
117
|
+
var length, i, keys;
|
|
118
|
+
if (Array.isArray(a)) {
|
|
122
119
|
length = a.length;
|
|
123
120
|
if (length != b.length) return false;
|
|
124
121
|
for (i = length; i-- !== 0;)
|
|
@@ -126,35 +123,29 @@ var fastDeepEqual = function equal(a, b) {
|
|
|
126
123
|
return true;
|
|
127
124
|
}
|
|
128
125
|
|
|
129
|
-
if (arrA != arrB) return false;
|
|
130
126
|
|
|
131
|
-
var dateA = a instanceof Date
|
|
132
|
-
, dateB = b instanceof Date;
|
|
133
|
-
if (dateA != dateB) return false;
|
|
134
|
-
if (dateA && dateB) return a.getTime() == b.getTime();
|
|
135
127
|
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
if (
|
|
139
|
-
if (regexpA && regexpB) return a.toString() == b.toString();
|
|
128
|
+
if (a.constructor === RegExp) return a.source === b.source && a.flags === b.flags;
|
|
129
|
+
if (a.valueOf !== Object.prototype.valueOf) return a.valueOf() === b.valueOf();
|
|
130
|
+
if (a.toString !== Object.prototype.toString) return a.toString() === b.toString();
|
|
140
131
|
|
|
141
|
-
|
|
132
|
+
keys = Object.keys(a);
|
|
142
133
|
length = keys.length;
|
|
143
|
-
|
|
144
|
-
if (length !== keyList(b).length)
|
|
145
|
-
return false;
|
|
134
|
+
if (length !== Object.keys(b).length) return false;
|
|
146
135
|
|
|
147
136
|
for (i = length; i-- !== 0;)
|
|
148
|
-
if (!
|
|
137
|
+
if (!Object.prototype.hasOwnProperty.call(b, keys[i])) return false;
|
|
149
138
|
|
|
150
139
|
for (i = length; i-- !== 0;) {
|
|
151
|
-
key = keys[i];
|
|
140
|
+
var key = keys[i];
|
|
141
|
+
|
|
152
142
|
if (!equal(a[key], b[key])) return false;
|
|
153
143
|
}
|
|
154
144
|
|
|
155
145
|
return true;
|
|
156
146
|
}
|
|
157
147
|
|
|
148
|
+
// true if both NaN, false otherwise
|
|
158
149
|
return a!==a && b!==b;
|
|
159
150
|
};
|
|
160
151
|
|
|
@@ -1577,199 +1568,235 @@ module.exports = exports['default'];
|
|
|
1577
1568
|
|
|
1578
1569
|
var youTubePlayer = _commonjsHelpers.unwrapExports(dist);
|
|
1579
1570
|
|
|
1580
|
-
|
|
1581
|
-
|
|
1582
|
-
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; };
|
|
1571
|
+
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); }
|
|
1583
1572
|
|
|
1584
1573
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
1585
1574
|
|
|
1586
|
-
function
|
|
1575
|
+
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); } }
|
|
1576
|
+
|
|
1577
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
1578
|
+
|
|
1579
|
+
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); }; }
|
|
1580
|
+
|
|
1581
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
1582
|
+
|
|
1583
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
1584
|
+
|
|
1585
|
+
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; } }
|
|
1586
|
+
|
|
1587
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
1588
|
+
|
|
1589
|
+
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); }
|
|
1590
|
+
|
|
1591
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
1592
|
+
|
|
1593
|
+
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; }
|
|
1587
1594
|
|
|
1588
|
-
function
|
|
1595
|
+
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; }
|
|
1589
1596
|
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
*
|
|
1593
|
-
*
|
|
1594
|
-
* @param {Object}
|
|
1597
|
+
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; }
|
|
1598
|
+
/**
|
|
1599
|
+
* Check whether a `props` change should result in the video being updated.
|
|
1600
|
+
*
|
|
1601
|
+
* @param {Object} prevProps
|
|
1602
|
+
* @param {Object} props
|
|
1595
1603
|
*/
|
|
1604
|
+
|
|
1596
1605
|
function shouldUpdateVideo(prevProps, props) {
|
|
1597
1606
|
// A changing video should always trigger an update
|
|
1598
1607
|
if (prevProps.videoId !== props.videoId) {
|
|
1599
1608
|
return true;
|
|
1600
|
-
}
|
|
1601
|
-
|
|
1602
|
-
// Otherwise, a change in the start/end time playerVars also requires a player
|
|
1609
|
+
} // Otherwise, a change in the start/end time playerVars also requires a player
|
|
1603
1610
|
// update.
|
|
1611
|
+
|
|
1612
|
+
|
|
1604
1613
|
var prevVars = prevProps.opts.playerVars || {};
|
|
1605
1614
|
var vars = props.opts.playerVars || {};
|
|
1606
|
-
|
|
1607
1615
|
return prevVars.start !== vars.start || prevVars.end !== vars.end;
|
|
1608
1616
|
}
|
|
1609
|
-
|
|
1610
|
-
|
|
1611
|
-
*
|
|
1612
|
-
*
|
|
1613
|
-
*
|
|
1614
|
-
*
|
|
1615
|
-
* @param {Object} opts
|
|
1617
|
+
/**
|
|
1618
|
+
* Neutralize API options that only require a video update, leaving only options
|
|
1619
|
+
* that require a player reset. The results can then be compared to see if a
|
|
1620
|
+
* player reset is necessary.
|
|
1621
|
+
*
|
|
1622
|
+
* @param {Object} opts
|
|
1616
1623
|
*/
|
|
1624
|
+
|
|
1625
|
+
|
|
1617
1626
|
function filterResetOptions(opts) {
|
|
1618
|
-
return
|
|
1619
|
-
playerVars:
|
|
1627
|
+
return _objectSpread({}, opts, {
|
|
1628
|
+
playerVars: _objectSpread({}, opts.playerVars, {
|
|
1620
1629
|
autoplay: 0,
|
|
1621
1630
|
start: 0,
|
|
1622
1631
|
end: 0
|
|
1623
1632
|
})
|
|
1624
1633
|
});
|
|
1625
1634
|
}
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
*
|
|
1629
|
-
*
|
|
1630
|
-
*
|
|
1631
|
-
*
|
|
1632
|
-
*
|
|
1633
|
-
* @param {Object}
|
|
1634
|
-
* @param {Object} props
|
|
1635
|
+
/**
|
|
1636
|
+
* Check whether a `props` change should result in the player being reset.
|
|
1637
|
+
* The player is reset when the `props.opts` change, except if the only change
|
|
1638
|
+
* is in the `start` and `end` playerVars, because a video update can deal with
|
|
1639
|
+
* those.
|
|
1640
|
+
*
|
|
1641
|
+
* @param {Object} prevProps
|
|
1642
|
+
* @param {Object} props
|
|
1635
1643
|
*/
|
|
1644
|
+
|
|
1645
|
+
|
|
1636
1646
|
function shouldResetPlayer(prevProps, props) {
|
|
1637
1647
|
return !fastDeepEqual(filterResetOptions(prevProps.opts), filterResetOptions(props.opts));
|
|
1638
1648
|
}
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
*
|
|
1642
|
-
*
|
|
1643
|
-
* @param {Object}
|
|
1644
|
-
* @param {Object} props
|
|
1649
|
+
/**
|
|
1650
|
+
* Check whether a props change should result in an id or className update.
|
|
1651
|
+
*
|
|
1652
|
+
* @param {Object} prevProps
|
|
1653
|
+
* @param {Object} props
|
|
1645
1654
|
*/
|
|
1655
|
+
|
|
1656
|
+
|
|
1646
1657
|
function shouldUpdatePlayer(prevProps, props) {
|
|
1647
1658
|
return prevProps.id !== props.id || prevProps.className !== props.className;
|
|
1648
1659
|
}
|
|
1649
1660
|
|
|
1650
|
-
var YouTube = function (_React$Component) {
|
|
1661
|
+
var YouTube = /*#__PURE__*/function (_React$Component) {
|
|
1651
1662
|
_inherits(YouTube, _React$Component);
|
|
1652
1663
|
|
|
1664
|
+
var _super = _createSuper(YouTube);
|
|
1665
|
+
|
|
1666
|
+
/**
|
|
1667
|
+
* Expose PlayerState constants for convenience. These constants can also be
|
|
1668
|
+
* accessed through the global YT object after the YouTube IFrame API is instantiated.
|
|
1669
|
+
* https://developers.google.com/youtube/iframe_api_reference#onStateChange
|
|
1670
|
+
*/
|
|
1653
1671
|
function YouTube(props) {
|
|
1672
|
+
var _this;
|
|
1673
|
+
|
|
1654
1674
|
_classCallCheck(this, YouTube);
|
|
1655
1675
|
|
|
1656
|
-
|
|
1676
|
+
_this = _super.call(this, props);
|
|
1657
1677
|
|
|
1658
|
-
_this
|
|
1678
|
+
_defineProperty(_assertThisInitialized(_this), "onPlayerReady", function (event) {
|
|
1659
1679
|
return _this.props.onReady(event);
|
|
1660
|
-
};
|
|
1680
|
+
});
|
|
1661
1681
|
|
|
1662
|
-
_this
|
|
1682
|
+
_defineProperty(_assertThisInitialized(_this), "onPlayerError", function (event) {
|
|
1663
1683
|
return _this.props.onError(event);
|
|
1664
|
-
};
|
|
1684
|
+
});
|
|
1665
1685
|
|
|
1666
|
-
_this
|
|
1686
|
+
_defineProperty(_assertThisInitialized(_this), "onPlayerStateChange", function (event) {
|
|
1667
1687
|
_this.props.onStateChange(event);
|
|
1668
|
-
switch (event.data) {
|
|
1669
1688
|
|
|
1689
|
+
switch (event.data) {
|
|
1670
1690
|
case YouTube.PlayerState.ENDED:
|
|
1671
1691
|
_this.props.onEnd(event);
|
|
1692
|
+
|
|
1672
1693
|
break;
|
|
1673
1694
|
|
|
1674
1695
|
case YouTube.PlayerState.PLAYING:
|
|
1675
1696
|
_this.props.onPlay(event);
|
|
1697
|
+
|
|
1676
1698
|
break;
|
|
1677
1699
|
|
|
1678
1700
|
case YouTube.PlayerState.PAUSED:
|
|
1679
1701
|
_this.props.onPause(event);
|
|
1702
|
+
|
|
1680
1703
|
break;
|
|
1681
1704
|
}
|
|
1682
|
-
};
|
|
1705
|
+
});
|
|
1683
1706
|
|
|
1684
|
-
_this
|
|
1707
|
+
_defineProperty(_assertThisInitialized(_this), "onPlayerPlaybackRateChange", function (event) {
|
|
1685
1708
|
return _this.props.onPlaybackRateChange(event);
|
|
1686
|
-
};
|
|
1709
|
+
});
|
|
1687
1710
|
|
|
1688
|
-
_this
|
|
1711
|
+
_defineProperty(_assertThisInitialized(_this), "onPlayerPlaybackQualityChange", function (event) {
|
|
1689
1712
|
return _this.props.onPlaybackQualityChange(event);
|
|
1690
|
-
};
|
|
1713
|
+
});
|
|
1691
1714
|
|
|
1692
|
-
_this
|
|
1715
|
+
_defineProperty(_assertThisInitialized(_this), "createPlayer", function () {
|
|
1693
1716
|
// do not attempt to create a player server-side, it won't work
|
|
1694
|
-
if (typeof document === 'undefined') return;
|
|
1695
|
-
|
|
1696
|
-
var playerOpts =
|
|
1717
|
+
if (typeof document === 'undefined') return; // create player
|
|
1718
|
+
|
|
1719
|
+
var playerOpts = _objectSpread({}, _this.props.opts, {
|
|
1697
1720
|
// preload the `videoId` video if one is already given
|
|
1698
1721
|
videoId: _this.props.videoId
|
|
1699
1722
|
});
|
|
1700
|
-
|
|
1701
|
-
// attach event handlers
|
|
1723
|
+
|
|
1724
|
+
_this.internalPlayer = youTubePlayer(_this.container, playerOpts); // attach event handlers
|
|
1725
|
+
|
|
1702
1726
|
_this.internalPlayer.on('ready', _this.onPlayerReady);
|
|
1727
|
+
|
|
1703
1728
|
_this.internalPlayer.on('error', _this.onPlayerError);
|
|
1729
|
+
|
|
1704
1730
|
_this.internalPlayer.on('stateChange', _this.onPlayerStateChange);
|
|
1731
|
+
|
|
1705
1732
|
_this.internalPlayer.on('playbackRateChange', _this.onPlayerPlaybackRateChange);
|
|
1733
|
+
|
|
1706
1734
|
_this.internalPlayer.on('playbackQualityChange', _this.onPlayerPlaybackQualityChange);
|
|
1707
|
-
};
|
|
1735
|
+
});
|
|
1708
1736
|
|
|
1709
|
-
_this
|
|
1737
|
+
_defineProperty(_assertThisInitialized(_this), "resetPlayer", function () {
|
|
1710
1738
|
return _this.internalPlayer.destroy().then(_this.createPlayer);
|
|
1711
|
-
};
|
|
1739
|
+
});
|
|
1712
1740
|
|
|
1713
|
-
_this
|
|
1741
|
+
_defineProperty(_assertThisInitialized(_this), "updatePlayer", function () {
|
|
1714
1742
|
_this.internalPlayer.getIframe().then(function (iframe) {
|
|
1715
1743
|
if (_this.props.id) iframe.setAttribute('id', _this.props.id);else iframe.removeAttribute('id');
|
|
1716
1744
|
if (_this.props.className) iframe.setAttribute('class', _this.props.className);else iframe.removeAttribute('class');
|
|
1717
1745
|
});
|
|
1718
|
-
};
|
|
1746
|
+
});
|
|
1719
1747
|
|
|
1720
|
-
_this
|
|
1748
|
+
_defineProperty(_assertThisInitialized(_this), "updateVideo", function () {
|
|
1721
1749
|
if (typeof _this.props.videoId === 'undefined' || _this.props.videoId === null) {
|
|
1722
1750
|
_this.internalPlayer.stopVideo();
|
|
1751
|
+
|
|
1723
1752
|
return;
|
|
1724
|
-
}
|
|
1753
|
+
} // set queueing options
|
|
1754
|
+
|
|
1725
1755
|
|
|
1726
|
-
// set queueing options
|
|
1727
1756
|
var autoplay = false;
|
|
1728
1757
|
var opts = {
|
|
1729
1758
|
videoId: _this.props.videoId
|
|
1730
1759
|
};
|
|
1760
|
+
|
|
1731
1761
|
if ('playerVars' in _this.props.opts) {
|
|
1732
1762
|
autoplay = _this.props.opts.playerVars.autoplay === 1;
|
|
1763
|
+
|
|
1733
1764
|
if ('start' in _this.props.opts.playerVars) {
|
|
1734
1765
|
opts.startSeconds = _this.props.opts.playerVars.start;
|
|
1735
1766
|
}
|
|
1767
|
+
|
|
1736
1768
|
if ('end' in _this.props.opts.playerVars) {
|
|
1737
1769
|
opts.endSeconds = _this.props.opts.playerVars.end;
|
|
1738
1770
|
}
|
|
1739
|
-
}
|
|
1771
|
+
} // if autoplay is enabled loadVideoById
|
|
1772
|
+
|
|
1740
1773
|
|
|
1741
|
-
// if autoplay is enabled loadVideoById
|
|
1742
1774
|
if (autoplay) {
|
|
1743
1775
|
_this.internalPlayer.loadVideoById(opts);
|
|
1776
|
+
|
|
1744
1777
|
return;
|
|
1745
|
-
}
|
|
1746
|
-
|
|
1778
|
+
} // default behaviour just cues the video
|
|
1779
|
+
|
|
1780
|
+
|
|
1747
1781
|
_this.internalPlayer.cueVideoById(opts);
|
|
1748
|
-
};
|
|
1782
|
+
});
|
|
1749
1783
|
|
|
1750
|
-
_this
|
|
1784
|
+
_defineProperty(_assertThisInitialized(_this), "refContainer", function (container) {
|
|
1751
1785
|
_this.container = container;
|
|
1752
|
-
};
|
|
1786
|
+
});
|
|
1753
1787
|
|
|
1754
1788
|
_this.container = null;
|
|
1755
1789
|
_this.internalPlayer = null;
|
|
1756
1790
|
return _this;
|
|
1757
1791
|
}
|
|
1758
1792
|
|
|
1759
|
-
/**
|
|
1760
|
-
* Expose PlayerState constants for convenience. These constants can also be
|
|
1761
|
-
* accessed through the global YT object after the YouTube IFrame API is instantiated.
|
|
1762
|
-
* https://developers.google.com/youtube/iframe_api_reference#onStateChange
|
|
1763
|
-
*/
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
1793
|
_createClass(YouTube, [{
|
|
1767
|
-
key:
|
|
1794
|
+
key: "componentDidMount",
|
|
1768
1795
|
value: function componentDidMount() {
|
|
1769
1796
|
this.createPlayer();
|
|
1770
1797
|
}
|
|
1771
1798
|
}, {
|
|
1772
|
-
key:
|
|
1799
|
+
key: "componentDidUpdate",
|
|
1773
1800
|
value: function componentDidUpdate(prevProps) {
|
|
1774
1801
|
if (shouldUpdatePlayer(prevProps, this.props)) {
|
|
1775
1802
|
this.updatePlayer();
|
|
@@ -1784,112 +1811,58 @@ var YouTube = function (_React$Component) {
|
|
|
1784
1811
|
}
|
|
1785
1812
|
}
|
|
1786
1813
|
}, {
|
|
1787
|
-
key:
|
|
1814
|
+
key: "componentWillUnmount",
|
|
1788
1815
|
value: function componentWillUnmount() {
|
|
1789
|
-
/**
|
|
1790
|
-
* Note: The `youtube-player` package that is used promisifies all
|
|
1791
|
-
* Player API calls, which introduces a delay of a tick before it actually
|
|
1792
|
-
* gets destroyed. Since React attempts to remove the element instantly
|
|
1793
|
-
* this method isn't quick enough to reset the container element.
|
|
1816
|
+
/**
|
|
1817
|
+
* Note: The `youtube-player` package that is used promisifies all YouTube
|
|
1818
|
+
* Player API calls, which introduces a delay of a tick before it actually
|
|
1819
|
+
* gets destroyed. Since React attempts to remove the element instantly
|
|
1820
|
+
* this method isn't quick enough to reset the container element.
|
|
1794
1821
|
*/
|
|
1795
1822
|
this.internalPlayer.destroy();
|
|
1796
1823
|
}
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
*
|
|
1800
|
-
*
|
|
1801
|
-
*
|
|
1802
|
-
* @param {Object} target - player object
|
|
1803
|
-
*/
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
/**
|
|
1807
|
-
* https://developers.google.com/youtube/iframe_api_reference#onError
|
|
1808
|
-
*
|
|
1809
|
-
* @param {Object} event
|
|
1810
|
-
* @param {Integer} data - error type
|
|
1811
|
-
* @param {Object} target - player object
|
|
1812
|
-
*/
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
/**
|
|
1816
|
-
* https://developers.google.com/youtube/iframe_api_reference#onStateChange
|
|
1817
|
-
*
|
|
1818
|
-
* @param {Object} event
|
|
1819
|
-
* @param {Integer} data - status change type
|
|
1820
|
-
* @param {Object} target - actual YT player
|
|
1821
|
-
*/
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
/**
|
|
1825
|
-
* https://developers.google.com/youtube/iframe_api_reference#onPlaybackRateChange
|
|
1826
|
-
*
|
|
1827
|
-
* @param {Object} event
|
|
1828
|
-
* @param {Float} data - playback rate
|
|
1829
|
-
* @param {Object} target - actual YT player
|
|
1830
|
-
*/
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
/**
|
|
1834
|
-
* https://developers.google.com/youtube/iframe_api_reference#onPlaybackQualityChange
|
|
1835
|
-
*
|
|
1836
|
-
* @param {Object} event
|
|
1837
|
-
* @param {String} data - playback quality
|
|
1838
|
-
* @param {Object} target - actual YT player
|
|
1839
|
-
*/
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
/**
|
|
1843
|
-
* Initialize the Youtube Player API on the container and attach event handlers
|
|
1844
|
-
*/
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
/**
|
|
1848
|
-
* Shorthand for destroying and then re-creating the Youtube Player
|
|
1849
|
-
*/
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
/**
|
|
1853
|
-
* Method to update the id and class of the Youtube Player iframe.
|
|
1854
|
-
* React should update this automatically but since the Youtube Player API
|
|
1855
|
-
* replaced the DIV that is mounted by React we need to do this manually.
|
|
1856
|
-
*/
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
/**
|
|
1860
|
-
* Call Youtube Player API methods to update the currently playing video.
|
|
1861
|
-
* Depeding on the `opts.playerVars.autoplay` this function uses one of two
|
|
1862
|
-
* Youtube Player API methods to update the video.
|
|
1824
|
+
/**
|
|
1825
|
+
* https://developers.google.com/youtube/iframe_api_reference#onReady
|
|
1826
|
+
*
|
|
1827
|
+
* @param {Object} event
|
|
1828
|
+
* @param {Object} target - player object
|
|
1863
1829
|
*/
|
|
1864
1830
|
|
|
1865
1831
|
}, {
|
|
1866
|
-
key:
|
|
1832
|
+
key: "render",
|
|
1867
1833
|
value: function render() {
|
|
1868
|
-
return React__default.createElement(
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1834
|
+
return /*#__PURE__*/React__default.createElement("div", {
|
|
1835
|
+
className: this.props.containerClassName
|
|
1836
|
+
}, /*#__PURE__*/React__default.createElement("div", {
|
|
1837
|
+
id: this.props.id,
|
|
1838
|
+
className: this.props.className,
|
|
1839
|
+
ref: this.refContainer
|
|
1840
|
+
}));
|
|
1873
1841
|
}
|
|
1874
1842
|
}]);
|
|
1875
1843
|
|
|
1876
1844
|
return YouTube;
|
|
1877
1845
|
}(React__default.Component);
|
|
1878
1846
|
|
|
1847
|
+
_defineProperty(YouTube, "PlayerState", {
|
|
1848
|
+
UNSTARTED: -1,
|
|
1849
|
+
ENDED: 0,
|
|
1850
|
+
PLAYING: 1,
|
|
1851
|
+
PAUSED: 2,
|
|
1852
|
+
BUFFERING: 3,
|
|
1853
|
+
CUED: 5
|
|
1854
|
+
});
|
|
1855
|
+
|
|
1879
1856
|
YouTube.propTypes = {
|
|
1880
1857
|
videoId: PropTypes.string,
|
|
1881
|
-
|
|
1882
1858
|
// custom ID for player element
|
|
1883
1859
|
id: PropTypes.string,
|
|
1884
|
-
|
|
1885
1860
|
// custom class name for player element
|
|
1886
1861
|
className: PropTypes.string,
|
|
1887
1862
|
// custom class name for player container element
|
|
1888
1863
|
containerClassName: PropTypes.string,
|
|
1889
|
-
|
|
1890
1864
|
// https://developers.google.com/youtube/iframe_api_reference#Loading_a_Video_Player
|
|
1891
1865
|
opts: PropTypes.objectOf(PropTypes.any),
|
|
1892
|
-
|
|
1893
1866
|
// event subscriptions
|
|
1894
1867
|
onReady: PropTypes.func,
|
|
1895
1868
|
onError: PropTypes.func,
|
|
@@ -1901,6 +1874,7 @@ YouTube.propTypes = {
|
|
|
1901
1874
|
onPlaybackQualityChange: PropTypes.func
|
|
1902
1875
|
};
|
|
1903
1876
|
YouTube.defaultProps = {
|
|
1877
|
+
videoId: null,
|
|
1904
1878
|
id: null,
|
|
1905
1879
|
className: null,
|
|
1906
1880
|
opts: {},
|
|
@@ -1914,14 +1888,6 @@ YouTube.defaultProps = {
|
|
|
1914
1888
|
onPlaybackRateChange: function onPlaybackRateChange() {},
|
|
1915
1889
|
onPlaybackQualityChange: function onPlaybackQualityChange() {}
|
|
1916
1890
|
};
|
|
1917
|
-
YouTube.PlayerState = {
|
|
1918
|
-
UNSTARTED: -1,
|
|
1919
|
-
ENDED: 0,
|
|
1920
|
-
PLAYING: 1,
|
|
1921
|
-
PAUSED: 2,
|
|
1922
|
-
BUFFERING: 3,
|
|
1923
|
-
CUED: 5
|
|
1924
|
-
};
|
|
1925
1891
|
|
|
1926
1892
|
var YouTubePlayer = function YouTubePlayer(_ref) {
|
|
1927
1893
|
var url = _ref.url;
|
|
@@ -2182,7 +2148,7 @@ var Media = function Media(_ref) {
|
|
|
2182
2148
|
React__default.createElement(
|
|
2183
2149
|
'a',
|
|
2184
2150
|
{ href: uploadDoc.asset.url, target: blank ? '_blank' : '_self' },
|
|
2185
|
-
React__default.createElement(reactBootstrap.Figure.Image, _extends
|
|
2151
|
+
React__default.createElement(reactBootstrap.Figure.Image, _extends._extends({ className: 'media-image', style: { maxWidth: '100%' }, src: urlFor(poster).url() }, alt && { alt: alt })),
|
|
2186
2152
|
caption && React__default.createElement(
|
|
2187
2153
|
reactBootstrap.Figure.Caption,
|
|
2188
2154
|
{ className: 'media-caption' },
|
|
@@ -2193,7 +2159,7 @@ var Media = function Media(_ref) {
|
|
|
2193
2159
|
} else if (caption && caption !== '') {
|
|
2194
2160
|
return React__default.createElement(
|
|
2195
2161
|
'a',
|
|
2196
|
-
_extends
|
|
2162
|
+
_extends._extends({}, uploadDoc.downloadMedia ? {
|
|
2197
2163
|
href: uploadDoc.asset.url + '?dl='
|
|
2198
2164
|
} : { href: uploadDoc.asset.url, target: blank ? '_blank' : '_self', rel: 'noopener noreferrer' }, {
|
|
2199
2165
|
style: { paddingLeft: '4px', paddingRight: '4px' },
|
|
@@ -2756,11 +2722,17 @@ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "functi
|
|
|
2756
2722
|
|
|
2757
2723
|
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; }
|
|
2758
2724
|
|
|
2759
|
-
function
|
|
2725
|
+
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; } } }; }
|
|
2726
|
+
|
|
2727
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
2760
2728
|
|
|
2761
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); }
|
|
2729
|
+
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."); }
|
|
2762
2730
|
|
|
2763
|
-
function
|
|
2731
|
+
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); }
|
|
2732
|
+
|
|
2733
|
+
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; }
|
|
2734
|
+
|
|
2735
|
+
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; }
|
|
2764
2736
|
|
|
2765
2737
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
2766
2738
|
|
|
@@ -2890,12 +2862,12 @@ function getSDK(url, sdkGlobal) {
|
|
|
2890
2862
|
|
|
2891
2863
|
function getConfig(props$1, defaultProps, showWarning) {
|
|
2892
2864
|
var config = (0, _deepmerge["default"])(defaultProps.config, props$1.config);
|
|
2893
|
-
|
|
2894
|
-
var
|
|
2895
|
-
|
|
2865
|
+
|
|
2866
|
+
var _iterator = _createForOfIteratorHelper(props.DEPRECATED_CONFIG_PROPS),
|
|
2867
|
+
_step;
|
|
2896
2868
|
|
|
2897
2869
|
try {
|
|
2898
|
-
for (
|
|
2870
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
2899
2871
|
var p = _step.value;
|
|
2900
2872
|
|
|
2901
2873
|
if (props$1[p]) {
|
|
@@ -2910,18 +2882,9 @@ function getConfig(props$1, defaultProps, showWarning) {
|
|
|
2910
2882
|
}
|
|
2911
2883
|
}
|
|
2912
2884
|
} catch (err) {
|
|
2913
|
-
|
|
2914
|
-
_iteratorError = err;
|
|
2885
|
+
_iterator.e(err);
|
|
2915
2886
|
} finally {
|
|
2916
|
-
|
|
2917
|
-
if (!_iteratorNormalCompletion && _iterator["return"] != null) {
|
|
2918
|
-
_iterator["return"]();
|
|
2919
|
-
}
|
|
2920
|
-
} finally {
|
|
2921
|
-
if (_didIteratorError) {
|
|
2922
|
-
throw _iteratorError;
|
|
2923
|
-
}
|
|
2924
|
-
}
|
|
2887
|
+
_iterator.f();
|
|
2925
2888
|
}
|
|
2926
2889
|
|
|
2927
2890
|
return config;
|
|
@@ -3068,12 +3031,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
3068
3031
|
|
|
3069
3032
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
3070
3033
|
|
|
3071
|
-
function
|
|
3034
|
+
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); }; }
|
|
3072
3035
|
|
|
3073
|
-
function
|
|
3036
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
3074
3037
|
|
|
3075
3038
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
3076
3039
|
|
|
3040
|
+
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; } }
|
|
3041
|
+
|
|
3042
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
3043
|
+
|
|
3077
3044
|
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); }
|
|
3078
3045
|
|
|
3079
3046
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -3082,14 +3049,12 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
3082
3049
|
|
|
3083
3050
|
var SEEK_ON_PLAY_EXPIRY = 5000;
|
|
3084
3051
|
|
|
3085
|
-
var Player =
|
|
3086
|
-
/*#__PURE__*/
|
|
3087
|
-
function (_Component) {
|
|
3052
|
+
var Player = /*#__PURE__*/function (_Component) {
|
|
3088
3053
|
_inherits(Player, _Component);
|
|
3089
3054
|
|
|
3090
|
-
|
|
3091
|
-
var _getPrototypeOf2;
|
|
3055
|
+
var _super = _createSuper(Player);
|
|
3092
3056
|
|
|
3057
|
+
function Player() {
|
|
3093
3058
|
var _this;
|
|
3094
3059
|
|
|
3095
3060
|
_classCallCheck(this, Player);
|
|
@@ -3098,7 +3063,7 @@ function (_Component) {
|
|
|
3098
3063
|
_args[_key] = arguments[_key];
|
|
3099
3064
|
}
|
|
3100
3065
|
|
|
3101
|
-
_this =
|
|
3066
|
+
_this = _super.call.apply(_super, [this].concat(_args));
|
|
3102
3067
|
|
|
3103
3068
|
_defineProperty(_assertThisInitialized(_this), "mounted", false);
|
|
3104
3069
|
|
|
@@ -3423,7 +3388,7 @@ function (_Component) {
|
|
|
3423
3388
|
return null;
|
|
3424
3389
|
}
|
|
3425
3390
|
|
|
3426
|
-
return _react["default"].createElement(Player, _extends({}, this.props, {
|
|
3391
|
+
return /*#__PURE__*/_react["default"].createElement(Player, _extends({}, this.props, {
|
|
3427
3392
|
ref: this.ref,
|
|
3428
3393
|
onReady: this.handleReady,
|
|
3429
3394
|
onPlay: this.handlePlay,
|
|
@@ -3484,12 +3449,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
3484
3449
|
|
|
3485
3450
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
3486
3451
|
|
|
3487
|
-
function
|
|
3452
|
+
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); }; }
|
|
3488
3453
|
|
|
3489
|
-
function
|
|
3454
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
3490
3455
|
|
|
3491
3456
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
3492
3457
|
|
|
3458
|
+
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; } }
|
|
3459
|
+
|
|
3460
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
3461
|
+
|
|
3493
3462
|
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); }
|
|
3494
3463
|
|
|
3495
3464
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -3501,14 +3470,12 @@ var SUPPORTED_PROPS = Object.keys(props.propTypes);
|
|
|
3501
3470
|
function createSinglePlayer(activePlayer) {
|
|
3502
3471
|
var _class, _temp;
|
|
3503
3472
|
|
|
3504
|
-
return _temp = _class =
|
|
3505
|
-
/*#__PURE__*/
|
|
3506
|
-
function (_Component) {
|
|
3473
|
+
return _temp = _class = /*#__PURE__*/function (_Component) {
|
|
3507
3474
|
_inherits(SinglePlayer, _Component);
|
|
3508
3475
|
|
|
3509
|
-
|
|
3510
|
-
var _getPrototypeOf2;
|
|
3476
|
+
var _super = _createSuper(SinglePlayer);
|
|
3511
3477
|
|
|
3478
|
+
function SinglePlayer() {
|
|
3512
3479
|
var _this;
|
|
3513
3480
|
|
|
3514
3481
|
_classCallCheck(this, SinglePlayer);
|
|
@@ -3517,7 +3484,7 @@ function createSinglePlayer(activePlayer) {
|
|
|
3517
3484
|
args[_key] = arguments[_key];
|
|
3518
3485
|
}
|
|
3519
3486
|
|
|
3520
|
-
_this =
|
|
3487
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
3521
3488
|
|
|
3522
3489
|
_defineProperty(_assertThisInitialized(_this), "config", (0, utils.getConfig)(_this.props, props.defaultProps, true));
|
|
3523
3490
|
|
|
@@ -3585,12 +3552,12 @@ function createSinglePlayer(activePlayer) {
|
|
|
3585
3552
|
height = _this$props.height,
|
|
3586
3553
|
Wrapper = _this$props.wrapper;
|
|
3587
3554
|
var otherProps = (0, utils.omit)(this.props, SUPPORTED_PROPS, props.DEPRECATED_CONFIG_PROPS);
|
|
3588
|
-
return _react["default"].createElement(Wrapper, _extends({
|
|
3555
|
+
return /*#__PURE__*/_react["default"].createElement(Wrapper, _extends({
|
|
3589
3556
|
style: _objectSpread({}, style, {
|
|
3590
3557
|
width: width,
|
|
3591
3558
|
height: height
|
|
3592
3559
|
})
|
|
3593
|
-
}, otherProps), _react["default"].createElement(_Player["default"], _extends({}, this.props, {
|
|
3560
|
+
}, otherProps), /*#__PURE__*/_react["default"].createElement(_Player["default"], _extends({}, this.props, {
|
|
3594
3561
|
ref: this.ref,
|
|
3595
3562
|
activePlayer: activePlayer,
|
|
3596
3563
|
config: this.config
|
|
@@ -3636,23 +3603,31 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
3636
3603
|
|
|
3637
3604
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
3638
3605
|
|
|
3639
|
-
function
|
|
3606
|
+
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); }; }
|
|
3640
3607
|
|
|
3641
|
-
function
|
|
3608
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
3642
3609
|
|
|
3643
3610
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
3644
3611
|
|
|
3612
|
+
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; } }
|
|
3613
|
+
|
|
3614
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
3615
|
+
|
|
3645
3616
|
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); }
|
|
3646
3617
|
|
|
3647
3618
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
3648
3619
|
|
|
3649
3620
|
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; }
|
|
3650
3621
|
|
|
3651
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }
|
|
3622
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
3623
|
+
|
|
3624
|
+
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."); }
|
|
3625
|
+
|
|
3626
|
+
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); }
|
|
3652
3627
|
|
|
3653
|
-
function
|
|
3628
|
+
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; }
|
|
3654
3629
|
|
|
3655
|
-
function _iterableToArrayLimit(arr, i) { if (!(Symbol.iterator in Object(arr)
|
|
3630
|
+
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; }
|
|
3656
3631
|
|
|
3657
3632
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
3658
3633
|
|
|
@@ -3677,14 +3652,12 @@ function parsePlaylist(url) {
|
|
|
3677
3652
|
return {};
|
|
3678
3653
|
}
|
|
3679
3654
|
|
|
3680
|
-
var YouTube =
|
|
3681
|
-
/*#__PURE__*/
|
|
3682
|
-
function (_Component) {
|
|
3655
|
+
var YouTube = /*#__PURE__*/function (_Component) {
|
|
3683
3656
|
_inherits(YouTube, _Component);
|
|
3684
3657
|
|
|
3685
|
-
|
|
3686
|
-
var _getPrototypeOf2;
|
|
3658
|
+
var _super = _createSuper(YouTube);
|
|
3687
3659
|
|
|
3660
|
+
function YouTube() {
|
|
3688
3661
|
var _this;
|
|
3689
3662
|
|
|
3690
3663
|
_classCallCheck(this, YouTube);
|
|
@@ -3693,7 +3666,7 @@ function (_Component) {
|
|
|
3693
3666
|
args[_key] = arguments[_key];
|
|
3694
3667
|
}
|
|
3695
3668
|
|
|
3696
|
-
_this =
|
|
3669
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
3697
3670
|
|
|
3698
3671
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
3699
3672
|
|
|
@@ -3881,9 +3854,9 @@ function (_Component) {
|
|
|
3881
3854
|
height: '100%',
|
|
3882
3855
|
display: display
|
|
3883
3856
|
};
|
|
3884
|
-
return _react["default"].createElement("div", {
|
|
3857
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
3885
3858
|
style: style
|
|
3886
|
-
}, _react["default"].createElement("div", {
|
|
3859
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
3887
3860
|
ref: this.ref
|
|
3888
3861
|
}));
|
|
3889
3862
|
}
|
|
@@ -3939,12 +3912,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
3939
3912
|
|
|
3940
3913
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
3941
3914
|
|
|
3942
|
-
function
|
|
3915
|
+
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); }; }
|
|
3943
3916
|
|
|
3944
|
-
function
|
|
3917
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
3945
3918
|
|
|
3946
3919
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
3947
3920
|
|
|
3921
|
+
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; } }
|
|
3922
|
+
|
|
3923
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
3924
|
+
|
|
3948
3925
|
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); }
|
|
3949
3926
|
|
|
3950
3927
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -3953,16 +3930,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
3953
3930
|
|
|
3954
3931
|
var SDK_URL = 'https://w.soundcloud.com/player/api.js';
|
|
3955
3932
|
var SDK_GLOBAL = 'SC';
|
|
3956
|
-
var MATCH_URL = /(soundcloud\.com|snd\.sc)
|
|
3933
|
+
var MATCH_URL = /(?:soundcloud\.com|snd\.sc)\/[^.]+$/;
|
|
3957
3934
|
|
|
3958
|
-
var SoundCloud =
|
|
3959
|
-
/*#__PURE__*/
|
|
3960
|
-
function (_Component) {
|
|
3935
|
+
var SoundCloud = /*#__PURE__*/function (_Component) {
|
|
3961
3936
|
_inherits(SoundCloud, _Component);
|
|
3962
3937
|
|
|
3963
|
-
|
|
3964
|
-
var _getPrototypeOf2;
|
|
3938
|
+
var _super = _createSuper(SoundCloud);
|
|
3965
3939
|
|
|
3940
|
+
function SoundCloud() {
|
|
3966
3941
|
var _this;
|
|
3967
3942
|
|
|
3968
3943
|
_classCallCheck(this, SoundCloud);
|
|
@@ -3971,7 +3946,7 @@ function (_Component) {
|
|
|
3971
3946
|
args[_key] = arguments[_key];
|
|
3972
3947
|
}
|
|
3973
3948
|
|
|
3974
|
-
_this =
|
|
3949
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
3975
3950
|
|
|
3976
3951
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
3977
3952
|
|
|
@@ -4092,7 +4067,7 @@ function (_Component) {
|
|
|
4092
4067
|
height: '100%',
|
|
4093
4068
|
display: display
|
|
4094
4069
|
};
|
|
4095
|
-
return _react["default"].createElement("iframe", {
|
|
4070
|
+
return /*#__PURE__*/_react["default"].createElement("iframe", {
|
|
4096
4071
|
ref: this.ref,
|
|
4097
4072
|
src: "https://w.soundcloud.com/player/?url=".concat(encodeURIComponent(this.props.url)),
|
|
4098
4073
|
style: style,
|
|
@@ -4154,12 +4129,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
4154
4129
|
|
|
4155
4130
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
4156
4131
|
|
|
4157
|
-
function
|
|
4132
|
+
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); }; }
|
|
4158
4133
|
|
|
4159
|
-
function
|
|
4134
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
4160
4135
|
|
|
4161
4136
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
4162
4137
|
|
|
4138
|
+
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; } }
|
|
4139
|
+
|
|
4140
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
4141
|
+
|
|
4163
4142
|
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); }
|
|
4164
4143
|
|
|
4165
4144
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -4171,14 +4150,12 @@ var SDK_GLOBAL = 'Vimeo';
|
|
|
4171
4150
|
var MATCH_URL = /vimeo\.com\/.+/;
|
|
4172
4151
|
var MATCH_FILE_URL = /vimeo\.com\/external\/[0-9]+\..+/;
|
|
4173
4152
|
|
|
4174
|
-
var Vimeo =
|
|
4175
|
-
/*#__PURE__*/
|
|
4176
|
-
function (_Component) {
|
|
4153
|
+
var Vimeo = /*#__PURE__*/function (_Component) {
|
|
4177
4154
|
_inherits(Vimeo, _Component);
|
|
4178
4155
|
|
|
4179
|
-
|
|
4180
|
-
var _getPrototypeOf2;
|
|
4156
|
+
var _super = _createSuper(Vimeo);
|
|
4181
4157
|
|
|
4158
|
+
function Vimeo() {
|
|
4182
4159
|
var _this;
|
|
4183
4160
|
|
|
4184
4161
|
_classCallCheck(this, Vimeo);
|
|
@@ -4187,7 +4164,7 @@ function (_Component) {
|
|
|
4187
4164
|
args[_key] = arguments[_key];
|
|
4188
4165
|
}
|
|
4189
4166
|
|
|
4190
|
-
_this =
|
|
4167
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
4191
4168
|
|
|
4192
4169
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
4193
4170
|
|
|
@@ -4344,7 +4321,7 @@ function (_Component) {
|
|
|
4344
4321
|
overflow: 'hidden',
|
|
4345
4322
|
display: display
|
|
4346
4323
|
};
|
|
4347
|
-
return _react["default"].createElement("div", {
|
|
4324
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
4348
4325
|
key: this.props.url,
|
|
4349
4326
|
ref: this.ref,
|
|
4350
4327
|
style: style
|
|
@@ -4404,12 +4381,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
4404
4381
|
|
|
4405
4382
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
4406
4383
|
|
|
4407
|
-
function
|
|
4384
|
+
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); }; }
|
|
4408
4385
|
|
|
4409
|
-
function
|
|
4386
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
4410
4387
|
|
|
4411
4388
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
4412
4389
|
|
|
4390
|
+
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; } }
|
|
4391
|
+
|
|
4392
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
4393
|
+
|
|
4413
4394
|
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); }
|
|
4414
4395
|
|
|
4415
4396
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -4422,14 +4403,12 @@ var SDK_GLOBAL_READY = 'fbAsyncInit';
|
|
|
4422
4403
|
var MATCH_URL = /^https?:\/\/(www\.)?facebook\.com.*\/(video(s)?|watch|story)(\.php?|\/).+$/;
|
|
4423
4404
|
var PLAYER_ID_PREFIX = 'facebook-player-';
|
|
4424
4405
|
|
|
4425
|
-
var Facebook =
|
|
4426
|
-
/*#__PURE__*/
|
|
4427
|
-
function (_Component) {
|
|
4406
|
+
var Facebook = /*#__PURE__*/function (_Component) {
|
|
4428
4407
|
_inherits(Facebook, _Component);
|
|
4429
4408
|
|
|
4430
|
-
|
|
4431
|
-
var _getPrototypeOf2;
|
|
4409
|
+
var _super = _createSuper(Facebook);
|
|
4432
4410
|
|
|
4411
|
+
function Facebook() {
|
|
4433
4412
|
var _this;
|
|
4434
4413
|
|
|
4435
4414
|
_classCallCheck(this, Facebook);
|
|
@@ -4438,7 +4417,7 @@ function (_Component) {
|
|
|
4438
4417
|
args[_key] = arguments[_key];
|
|
4439
4418
|
}
|
|
4440
4419
|
|
|
4441
|
-
_this =
|
|
4420
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
4442
4421
|
|
|
4443
4422
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
4444
4423
|
|
|
@@ -4554,7 +4533,7 @@ function (_Component) {
|
|
|
4554
4533
|
width: '100%',
|
|
4555
4534
|
height: '100%'
|
|
4556
4535
|
};
|
|
4557
|
-
return _react["default"].createElement("div", {
|
|
4536
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
4558
4537
|
style: style,
|
|
4559
4538
|
id: this.playerID,
|
|
4560
4539
|
className: "fb-video",
|
|
@@ -4614,12 +4593,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
4614
4593
|
|
|
4615
4594
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
4616
4595
|
|
|
4617
|
-
function
|
|
4596
|
+
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); }; }
|
|
4618
4597
|
|
|
4619
|
-
function
|
|
4598
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
4620
4599
|
|
|
4621
4600
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
4622
4601
|
|
|
4602
|
+
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; } }
|
|
4603
|
+
|
|
4604
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
4605
|
+
|
|
4623
4606
|
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); }
|
|
4624
4607
|
|
|
4625
4608
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -4630,14 +4613,12 @@ var SDK_URL = 'https://cdn.embed.ly/player-0.1.0.min.js';
|
|
|
4630
4613
|
var SDK_GLOBAL = 'playerjs';
|
|
4631
4614
|
var MATCH_URL = /streamable\.com\/([a-z0-9]+)$/;
|
|
4632
4615
|
|
|
4633
|
-
var Streamable =
|
|
4634
|
-
/*#__PURE__*/
|
|
4635
|
-
function (_Component) {
|
|
4616
|
+
var Streamable = /*#__PURE__*/function (_Component) {
|
|
4636
4617
|
_inherits(Streamable, _Component);
|
|
4637
4618
|
|
|
4638
|
-
|
|
4639
|
-
var _getPrototypeOf2;
|
|
4619
|
+
var _super = _createSuper(Streamable);
|
|
4640
4620
|
|
|
4621
|
+
function Streamable() {
|
|
4641
4622
|
var _this;
|
|
4642
4623
|
|
|
4643
4624
|
_classCallCheck(this, Streamable);
|
|
@@ -4646,7 +4627,7 @@ function (_Component) {
|
|
|
4646
4627
|
args[_key] = arguments[_key];
|
|
4647
4628
|
}
|
|
4648
4629
|
|
|
4649
|
-
_this =
|
|
4630
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
4650
4631
|
|
|
4651
4632
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
4652
4633
|
|
|
@@ -4766,7 +4747,7 @@ function (_Component) {
|
|
|
4766
4747
|
width: '100%',
|
|
4767
4748
|
height: '100%'
|
|
4768
4749
|
};
|
|
4769
|
-
return _react["default"].createElement("iframe", {
|
|
4750
|
+
return /*#__PURE__*/_react["default"].createElement("iframe", {
|
|
4770
4751
|
ref: this.ref,
|
|
4771
4752
|
src: "https://streamable.com/o/".concat(id),
|
|
4772
4753
|
frameBorder: "0",
|
|
@@ -4827,12 +4808,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
4827
4808
|
|
|
4828
4809
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
4829
4810
|
|
|
4830
|
-
function
|
|
4811
|
+
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); }; }
|
|
4831
4812
|
|
|
4832
|
-
function
|
|
4813
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
4833
4814
|
|
|
4834
4815
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
4835
4816
|
|
|
4817
|
+
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; } }
|
|
4818
|
+
|
|
4819
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
4820
|
+
|
|
4836
4821
|
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); }
|
|
4837
4822
|
|
|
4838
4823
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -4843,26 +4828,48 @@ var SDK_URL = 'https://fast.wistia.com/assets/external/E-v1.js';
|
|
|
4843
4828
|
var SDK_GLOBAL = 'Wistia';
|
|
4844
4829
|
var MATCH_URL = /(?:wistia\.com|wi\.st)\/(?:medias|embed)\/(.*)$/;
|
|
4845
4830
|
|
|
4846
|
-
var Wistia =
|
|
4847
|
-
/*#__PURE__*/
|
|
4848
|
-
function (_Component) {
|
|
4831
|
+
var Wistia = /*#__PURE__*/function (_Component) {
|
|
4849
4832
|
_inherits(Wistia, _Component);
|
|
4850
4833
|
|
|
4851
|
-
|
|
4852
|
-
var _getPrototypeOf2;
|
|
4834
|
+
var _super = _createSuper(Wistia);
|
|
4853
4835
|
|
|
4836
|
+
function Wistia() {
|
|
4854
4837
|
var _this;
|
|
4855
4838
|
|
|
4856
4839
|
_classCallCheck(this, Wistia);
|
|
4857
4840
|
|
|
4858
|
-
for (var _len = arguments.length,
|
|
4859
|
-
|
|
4841
|
+
for (var _len = arguments.length, _args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
4842
|
+
_args[_key] = arguments[_key];
|
|
4860
4843
|
}
|
|
4861
4844
|
|
|
4862
|
-
_this =
|
|
4845
|
+
_this = _super.call.apply(_super, [this].concat(_args));
|
|
4863
4846
|
|
|
4864
4847
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
4865
4848
|
|
|
4849
|
+
_defineProperty(_assertThisInitialized(_this), "onPlay", function () {
|
|
4850
|
+
var _this$props;
|
|
4851
|
+
|
|
4852
|
+
return (_this$props = _this.props).onPlay.apply(_this$props, arguments);
|
|
4853
|
+
});
|
|
4854
|
+
|
|
4855
|
+
_defineProperty(_assertThisInitialized(_this), "onPause", function () {
|
|
4856
|
+
var _this$props2;
|
|
4857
|
+
|
|
4858
|
+
return (_this$props2 = _this.props).onPause.apply(_this$props2, arguments);
|
|
4859
|
+
});
|
|
4860
|
+
|
|
4861
|
+
_defineProperty(_assertThisInitialized(_this), "onSeek", function () {
|
|
4862
|
+
var _this$props3;
|
|
4863
|
+
|
|
4864
|
+
return (_this$props3 = _this.props).onSeek.apply(_this$props3, arguments);
|
|
4865
|
+
});
|
|
4866
|
+
|
|
4867
|
+
_defineProperty(_assertThisInitialized(_this), "onEnded", function () {
|
|
4868
|
+
var _this$props4;
|
|
4869
|
+
|
|
4870
|
+
return (_this$props4 = _this.props).onEnded.apply(_this$props4, arguments);
|
|
4871
|
+
});
|
|
4872
|
+
|
|
4866
4873
|
_defineProperty(_assertThisInitialized(_this), "mute", function () {
|
|
4867
4874
|
_this.callPlayer('mute');
|
|
4868
4875
|
});
|
|
@@ -4884,17 +4891,13 @@ function (_Component) {
|
|
|
4884
4891
|
value: function load(url) {
|
|
4885
4892
|
var _this2 = this;
|
|
4886
4893
|
|
|
4887
|
-
var _this$
|
|
4888
|
-
playing = _this$
|
|
4889
|
-
muted = _this$
|
|
4890
|
-
controls = _this$
|
|
4891
|
-
_onReady = _this$
|
|
4892
|
-
|
|
4893
|
-
|
|
4894
|
-
onSeek = _this$props.onSeek,
|
|
4895
|
-
onEnded = _this$props.onEnded,
|
|
4896
|
-
config = _this$props.config,
|
|
4897
|
-
onError = _this$props.onError;
|
|
4894
|
+
var _this$props5 = this.props,
|
|
4895
|
+
playing = _this$props5.playing,
|
|
4896
|
+
muted = _this$props5.muted,
|
|
4897
|
+
controls = _this$props5.controls,
|
|
4898
|
+
_onReady = _this$props5.onReady,
|
|
4899
|
+
config = _this$props5.config,
|
|
4900
|
+
onError = _this$props5.onError;
|
|
4898
4901
|
(0, utils.getSDK)(SDK_URL, SDK_GLOBAL).then(function () {
|
|
4899
4902
|
window._wq = window._wq || [];
|
|
4900
4903
|
|
|
@@ -4911,19 +4914,28 @@ function (_Component) {
|
|
|
4911
4914
|
|
|
4912
4915
|
_this2.unbind();
|
|
4913
4916
|
|
|
4914
|
-
_this2.player.bind('play', onPlay);
|
|
4917
|
+
_this2.player.bind('play', _this2.onPlay);
|
|
4915
4918
|
|
|
4916
|
-
_this2.player.bind('pause', onPause);
|
|
4919
|
+
_this2.player.bind('pause', _this2.onPause);
|
|
4917
4920
|
|
|
4918
|
-
_this2.player.bind('seek', onSeek);
|
|
4921
|
+
_this2.player.bind('seek', _this2.onSeek);
|
|
4919
4922
|
|
|
4920
|
-
_this2.player.bind('end', onEnded);
|
|
4923
|
+
_this2.player.bind('end', _this2.onEnded);
|
|
4921
4924
|
|
|
4922
4925
|
_onReady();
|
|
4923
4926
|
}
|
|
4924
4927
|
});
|
|
4925
4928
|
}, onError);
|
|
4926
4929
|
}
|
|
4930
|
+
}, {
|
|
4931
|
+
key: "unbind",
|
|
4932
|
+
value: function unbind() {
|
|
4933
|
+
this.player.unbind('play', this.onPlay);
|
|
4934
|
+
this.player.unbind('pause', this.onPause);
|
|
4935
|
+
this.player.unbind('seek', this.onSeek);
|
|
4936
|
+
this.player.unbind('end', this.onEnded);
|
|
4937
|
+
} // Proxy methods to prevent listener leaks
|
|
4938
|
+
|
|
4927
4939
|
}, {
|
|
4928
4940
|
key: "play",
|
|
4929
4941
|
value: function play() {
|
|
@@ -4934,19 +4946,6 @@ function (_Component) {
|
|
|
4934
4946
|
value: function pause() {
|
|
4935
4947
|
this.callPlayer('pause');
|
|
4936
4948
|
}
|
|
4937
|
-
}, {
|
|
4938
|
-
key: "unbind",
|
|
4939
|
-
value: function unbind() {
|
|
4940
|
-
var _this$props2 = this.props,
|
|
4941
|
-
onPlay = _this$props2.onPlay,
|
|
4942
|
-
onPause = _this$props2.onPause,
|
|
4943
|
-
onSeek = _this$props2.onSeek,
|
|
4944
|
-
onEnded = _this$props2.onEnded;
|
|
4945
|
-
this.player.unbind('play', onPlay);
|
|
4946
|
-
this.player.unbind('pause', onPause);
|
|
4947
|
-
this.player.unbind('seek', onSeek);
|
|
4948
|
-
this.player.unbind('end', onEnded);
|
|
4949
|
-
}
|
|
4950
4949
|
}, {
|
|
4951
4950
|
key: "stop",
|
|
4952
4951
|
value: function stop() {
|
|
@@ -4992,7 +4991,7 @@ function (_Component) {
|
|
|
4992
4991
|
width: '100%',
|
|
4993
4992
|
height: '100%'
|
|
4994
4993
|
};
|
|
4995
|
-
return _react["default"].createElement("div", {
|
|
4994
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
4996
4995
|
key: id,
|
|
4997
4996
|
className: className,
|
|
4998
4997
|
style: style
|
|
@@ -5052,12 +5051,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
5052
5051
|
|
|
5053
5052
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
5054
5053
|
|
|
5055
|
-
function
|
|
5054
|
+
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); }; }
|
|
5056
5055
|
|
|
5057
|
-
function
|
|
5056
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
5058
5057
|
|
|
5059
5058
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
5060
5059
|
|
|
5060
|
+
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; } }
|
|
5061
|
+
|
|
5062
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
5063
|
+
|
|
5061
5064
|
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); }
|
|
5062
5065
|
|
|
5063
5066
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -5070,14 +5073,12 @@ var MATCH_VIDEO_URL = /(?:www\.|go\.)?twitch\.tv\/videos\/(\d+)($|\?)/;
|
|
|
5070
5073
|
var MATCH_CHANNEL_URL = /(?:www\.|go\.)?twitch\.tv\/([a-z0-9_]+)($|\?)/;
|
|
5071
5074
|
var PLAYER_ID_PREFIX = 'twitch-player-';
|
|
5072
5075
|
|
|
5073
|
-
var Twitch =
|
|
5074
|
-
/*#__PURE__*/
|
|
5075
|
-
function (_Component) {
|
|
5076
|
+
var Twitch = /*#__PURE__*/function (_Component) {
|
|
5076
5077
|
_inherits(Twitch, _Component);
|
|
5077
5078
|
|
|
5078
|
-
|
|
5079
|
-
var _getPrototypeOf2;
|
|
5079
|
+
var _super = _createSuper(Twitch);
|
|
5080
5080
|
|
|
5081
|
+
function Twitch() {
|
|
5081
5082
|
var _this;
|
|
5082
5083
|
|
|
5083
5084
|
_classCallCheck(this, Twitch);
|
|
@@ -5086,7 +5087,7 @@ function (_Component) {
|
|
|
5086
5087
|
args[_key] = arguments[_key];
|
|
5087
5088
|
}
|
|
5088
5089
|
|
|
5089
|
-
_this =
|
|
5090
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
5090
5091
|
|
|
5091
5092
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
5092
5093
|
|
|
@@ -5207,7 +5208,7 @@ function (_Component) {
|
|
|
5207
5208
|
width: '100%',
|
|
5208
5209
|
height: '100%'
|
|
5209
5210
|
};
|
|
5210
|
-
return _react["default"].createElement("div", {
|
|
5211
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
5211
5212
|
style: style,
|
|
5212
5213
|
id: this.playerID
|
|
5213
5214
|
});
|
|
@@ -5260,11 +5261,15 @@ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (O
|
|
|
5260
5261
|
|
|
5261
5262
|
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; }
|
|
5262
5263
|
|
|
5263
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }
|
|
5264
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
5265
|
+
|
|
5266
|
+
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."); }
|
|
5267
|
+
|
|
5268
|
+
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); }
|
|
5264
5269
|
|
|
5265
|
-
function
|
|
5270
|
+
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; }
|
|
5266
5271
|
|
|
5267
|
-
function _iterableToArrayLimit(arr, i) { if (!(Symbol.iterator in Object(arr)
|
|
5272
|
+
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; }
|
|
5268
5273
|
|
|
5269
5274
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
5270
5275
|
|
|
@@ -5274,12 +5279,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
5274
5279
|
|
|
5275
5280
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
5276
5281
|
|
|
5277
|
-
function
|
|
5282
|
+
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); }; }
|
|
5278
5283
|
|
|
5279
|
-
function
|
|
5284
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
5280
5285
|
|
|
5281
5286
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
5282
5287
|
|
|
5288
|
+
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; } }
|
|
5289
|
+
|
|
5290
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
5291
|
+
|
|
5283
5292
|
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); }
|
|
5284
5293
|
|
|
5285
5294
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -5291,14 +5300,12 @@ var SDK_GLOBAL = 'DM';
|
|
|
5291
5300
|
var SDK_GLOBAL_READY = 'dmAsyncInit';
|
|
5292
5301
|
var MATCH_URL = /^(?:(?:https?):)?(?:\/\/)?(?:www\.)?(?:(?:dailymotion\.com(?:\/embed)?\/video)|dai\.ly)\/([a-zA-Z0-9]+)(?:_[\w_-]+)?$/;
|
|
5293
5302
|
|
|
5294
|
-
var DailyMotion =
|
|
5295
|
-
/*#__PURE__*/
|
|
5296
|
-
function (_Component) {
|
|
5303
|
+
var DailyMotion = /*#__PURE__*/function (_Component) {
|
|
5297
5304
|
_inherits(DailyMotion, _Component);
|
|
5298
5305
|
|
|
5299
|
-
|
|
5300
|
-
var _getPrototypeOf2;
|
|
5306
|
+
var _super = _createSuper(DailyMotion);
|
|
5301
5307
|
|
|
5308
|
+
function DailyMotion() {
|
|
5302
5309
|
var _this;
|
|
5303
5310
|
|
|
5304
5311
|
_classCallCheck(this, DailyMotion);
|
|
@@ -5307,7 +5314,7 @@ function (_Component) {
|
|
|
5307
5314
|
args[_key] = arguments[_key];
|
|
5308
5315
|
}
|
|
5309
5316
|
|
|
5310
|
-
_this =
|
|
5317
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
5311
5318
|
|
|
5312
5319
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
5313
5320
|
|
|
@@ -5436,9 +5443,9 @@ function (_Component) {
|
|
|
5436
5443
|
height: '100%',
|
|
5437
5444
|
display: display
|
|
5438
5445
|
};
|
|
5439
|
-
return _react["default"].createElement("div", {
|
|
5446
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
5440
5447
|
style: style
|
|
5441
|
-
}, _react["default"].createElement("div", {
|
|
5448
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
5442
5449
|
ref: this.ref
|
|
5443
5450
|
}));
|
|
5444
5451
|
}
|
|
@@ -5496,12 +5503,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
5496
5503
|
|
|
5497
5504
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
5498
5505
|
|
|
5499
|
-
function
|
|
5506
|
+
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); }; }
|
|
5500
5507
|
|
|
5501
|
-
function
|
|
5508
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
5502
5509
|
|
|
5503
5510
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
5504
5511
|
|
|
5512
|
+
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; } }
|
|
5513
|
+
|
|
5514
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
5515
|
+
|
|
5505
5516
|
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); }
|
|
5506
5517
|
|
|
5507
5518
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -5512,14 +5523,12 @@ var SDK_URL = 'https://widget.mixcloud.com/media/js/widgetApi.js';
|
|
|
5512
5523
|
var SDK_GLOBAL = 'Mixcloud';
|
|
5513
5524
|
var MATCH_URL = /mixcloud\.com\/([^/]+\/[^/]+)/;
|
|
5514
5525
|
|
|
5515
|
-
var Mixcloud =
|
|
5516
|
-
/*#__PURE__*/
|
|
5517
|
-
function (_Component) {
|
|
5526
|
+
var Mixcloud = /*#__PURE__*/function (_Component) {
|
|
5518
5527
|
_inherits(Mixcloud, _Component);
|
|
5519
5528
|
|
|
5520
|
-
|
|
5521
|
-
var _getPrototypeOf2;
|
|
5529
|
+
var _super = _createSuper(Mixcloud);
|
|
5522
5530
|
|
|
5531
|
+
function Mixcloud() {
|
|
5523
5532
|
var _this;
|
|
5524
5533
|
|
|
5525
5534
|
_classCallCheck(this, Mixcloud);
|
|
@@ -5528,7 +5537,7 @@ function (_Component) {
|
|
|
5528
5537
|
args[_key] = arguments[_key];
|
|
5529
5538
|
}
|
|
5530
5539
|
|
|
5531
|
-
_this =
|
|
5540
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
5532
5541
|
|
|
5533
5542
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
5534
5543
|
|
|
@@ -5631,7 +5640,7 @@ function (_Component) {
|
|
|
5631
5640
|
})); // We have to give the iframe a key here to prevent a
|
|
5632
5641
|
// weird dialog appearing when loading a new track
|
|
5633
5642
|
|
|
5634
|
-
return _react["default"].createElement("iframe", {
|
|
5643
|
+
return /*#__PURE__*/_react["default"].createElement("iframe", {
|
|
5635
5644
|
key: id,
|
|
5636
5645
|
ref: this.ref,
|
|
5637
5646
|
style: style,
|
|
@@ -5691,23 +5700,33 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
5691
5700
|
|
|
5692
5701
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
5693
5702
|
|
|
5694
|
-
function
|
|
5703
|
+
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); }; }
|
|
5695
5704
|
|
|
5696
|
-
function
|
|
5705
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
5697
5706
|
|
|
5698
5707
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
5699
5708
|
|
|
5709
|
+
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; } }
|
|
5710
|
+
|
|
5711
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
5712
|
+
|
|
5700
5713
|
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); }
|
|
5701
5714
|
|
|
5702
5715
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
5703
5716
|
|
|
5704
5717
|
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; }
|
|
5705
5718
|
|
|
5719
|
+
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; } } }; }
|
|
5720
|
+
|
|
5721
|
+
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); }
|
|
5722
|
+
|
|
5723
|
+
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; }
|
|
5724
|
+
|
|
5706
5725
|
var IOS = typeof navigator !== 'undefined' && /iPad|iPhone|iPod/.test(navigator.userAgent) && !window.MSStream;
|
|
5707
5726
|
var AUDIO_EXTENSIONS = /\.(m4a|mp4a|mpga|mp2|mp2a|mp3|m2a|m3a|wav|weba|aac|oga|spx)($|\?)/i;
|
|
5708
5727
|
var VIDEO_EXTENSIONS = /\.(mp4|og[gv]|webm|mov|m4v)($|\?)/i;
|
|
5709
5728
|
var HLS_EXTENSIONS = /\.(m3u8)($|\?)/i;
|
|
5710
|
-
var HLS_SDK_URL = 'https://cdn.jsdelivr.net/npm/hls.js@VERSION';
|
|
5729
|
+
var HLS_SDK_URL = 'https://cdn.jsdelivr.net/npm/hls.js@VERSION/dist/hls.min.js';
|
|
5711
5730
|
var HLS_GLOBAL = 'Hls';
|
|
5712
5731
|
var DASH_EXTENSIONS = /\.(mpd)($|\?)/i;
|
|
5713
5732
|
var DASH_SDK_URL = 'https://cdnjs.cloudflare.com/ajax/libs/dashjs/VERSION/dash.all.min.js';
|
|
@@ -5716,12 +5735,11 @@ var MATCH_DROPBOX_URL = /www\.dropbox\.com\/.+/;
|
|
|
5716
5735
|
|
|
5717
5736
|
function canPlay(url) {
|
|
5718
5737
|
if (url instanceof Array) {
|
|
5719
|
-
var
|
|
5720
|
-
|
|
5721
|
-
var _iteratorError = undefined;
|
|
5738
|
+
var _iterator = _createForOfIteratorHelper(url),
|
|
5739
|
+
_step;
|
|
5722
5740
|
|
|
5723
5741
|
try {
|
|
5724
|
-
for (
|
|
5742
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
5725
5743
|
var item = _step.value;
|
|
5726
5744
|
|
|
5727
5745
|
if (typeof item === 'string' && canPlay(item)) {
|
|
@@ -5733,18 +5751,9 @@ function canPlay(url) {
|
|
|
5733
5751
|
}
|
|
5734
5752
|
}
|
|
5735
5753
|
} catch (err) {
|
|
5736
|
-
|
|
5737
|
-
_iteratorError = err;
|
|
5754
|
+
_iterator.e(err);
|
|
5738
5755
|
} finally {
|
|
5739
|
-
|
|
5740
|
-
if (!_iteratorNormalCompletion && _iterator["return"] != null) {
|
|
5741
|
-
_iterator["return"]();
|
|
5742
|
-
}
|
|
5743
|
-
} finally {
|
|
5744
|
-
if (_didIteratorError) {
|
|
5745
|
-
throw _iteratorError;
|
|
5746
|
-
}
|
|
5747
|
-
}
|
|
5756
|
+
_iterator.f();
|
|
5748
5757
|
}
|
|
5749
5758
|
|
|
5750
5759
|
return false;
|
|
@@ -5768,14 +5777,12 @@ function canEnablePIP(url) {
|
|
|
5768
5777
|
return canPlay(url) && (!!document.pictureInPictureEnabled || supportsWebKitPresentationMode()) && !AUDIO_EXTENSIONS.test(url);
|
|
5769
5778
|
}
|
|
5770
5779
|
|
|
5771
|
-
var FilePlayer =
|
|
5772
|
-
/*#__PURE__*/
|
|
5773
|
-
function (_Component) {
|
|
5780
|
+
var FilePlayer = /*#__PURE__*/function (_Component) {
|
|
5774
5781
|
_inherits(FilePlayer, _Component);
|
|
5775
5782
|
|
|
5776
|
-
|
|
5777
|
-
var _getPrototypeOf2;
|
|
5783
|
+
var _super = _createSuper(FilePlayer);
|
|
5778
5784
|
|
|
5785
|
+
function FilePlayer() {
|
|
5779
5786
|
var _this;
|
|
5780
5787
|
|
|
5781
5788
|
_classCallCheck(this, FilePlayer);
|
|
@@ -5784,7 +5791,7 @@ function (_Component) {
|
|
|
5784
5791
|
_args[_key] = arguments[_key];
|
|
5785
5792
|
}
|
|
5786
5793
|
|
|
5787
|
-
_this =
|
|
5794
|
+
_this = _super.call.apply(_super, [this].concat(_args));
|
|
5788
5795
|
|
|
5789
5796
|
_defineProperty(_assertThisInitialized(_this), "onReady", function () {
|
|
5790
5797
|
var _this$props;
|
|
@@ -5871,19 +5878,19 @@ function (_Component) {
|
|
|
5871
5878
|
|
|
5872
5879
|
_defineProperty(_assertThisInitialized(_this), "renderSourceElement", function (source, index) {
|
|
5873
5880
|
if (typeof source === 'string') {
|
|
5874
|
-
return _react["default"].createElement("source", {
|
|
5881
|
+
return /*#__PURE__*/_react["default"].createElement("source", {
|
|
5875
5882
|
key: index,
|
|
5876
5883
|
src: source
|
|
5877
5884
|
});
|
|
5878
5885
|
}
|
|
5879
5886
|
|
|
5880
|
-
return _react["default"].createElement("source", _extends({
|
|
5887
|
+
return /*#__PURE__*/_react["default"].createElement("source", _extends({
|
|
5881
5888
|
key: index
|
|
5882
5889
|
}, source));
|
|
5883
5890
|
});
|
|
5884
5891
|
|
|
5885
5892
|
_defineProperty(_assertThisInitialized(_this), "renderTrack", function (track, index) {
|
|
5886
|
-
return _react["default"].createElement("track", _extends({
|
|
5893
|
+
return /*#__PURE__*/_react["default"].createElement("track", _extends({
|
|
5887
5894
|
key: index
|
|
5888
5895
|
}, track));
|
|
5889
5896
|
});
|
|
@@ -5921,6 +5928,10 @@ function (_Component) {
|
|
|
5921
5928
|
key: "componentWillUnmount",
|
|
5922
5929
|
value: function componentWillUnmount() {
|
|
5923
5930
|
this.removeListeners(this.player);
|
|
5931
|
+
|
|
5932
|
+
if (this.hls) {
|
|
5933
|
+
this.hls.destroy();
|
|
5934
|
+
}
|
|
5924
5935
|
}
|
|
5925
5936
|
}, {
|
|
5926
5937
|
key: "addListeners",
|
|
@@ -6051,10 +6062,6 @@ function (_Component) {
|
|
|
6051
6062
|
value: function stop() {
|
|
6052
6063
|
this.player.removeAttribute('src');
|
|
6053
6064
|
|
|
6054
|
-
if (this.hls) {
|
|
6055
|
-
this.hls.destroy();
|
|
6056
|
-
}
|
|
6057
|
-
|
|
6058
6065
|
if (this.dash) {
|
|
6059
6066
|
this.dash.reset();
|
|
6060
6067
|
}
|
|
@@ -6166,7 +6173,7 @@ function (_Component) {
|
|
|
6166
6173
|
width: width === 'auto' ? width : '100%',
|
|
6167
6174
|
height: height === 'auto' ? height : '100%'
|
|
6168
6175
|
};
|
|
6169
|
-
return _react["default"].createElement(Element, _extends({
|
|
6176
|
+
return /*#__PURE__*/_react["default"].createElement(Element, _extends({
|
|
6170
6177
|
ref: this.ref,
|
|
6171
6178
|
src: this.getSource(url),
|
|
6172
6179
|
style: style,
|
|
@@ -6256,12 +6263,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
6256
6263
|
|
|
6257
6264
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
6258
6265
|
|
|
6259
|
-
function
|
|
6266
|
+
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); }; }
|
|
6260
6267
|
|
|
6261
|
-
function
|
|
6268
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
6262
6269
|
|
|
6263
6270
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
6264
6271
|
|
|
6272
|
+
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; } }
|
|
6273
|
+
|
|
6274
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
6275
|
+
|
|
6265
6276
|
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); }
|
|
6266
6277
|
|
|
6267
6278
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -6270,14 +6281,12 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
6270
6281
|
|
|
6271
6282
|
var ICON_SIZE = '64px';
|
|
6272
6283
|
|
|
6273
|
-
var Preview =
|
|
6274
|
-
/*#__PURE__*/
|
|
6275
|
-
function (_Component) {
|
|
6284
|
+
var Preview = /*#__PURE__*/function (_Component) {
|
|
6276
6285
|
_inherits(Preview, _Component);
|
|
6277
6286
|
|
|
6278
|
-
|
|
6279
|
-
var _getPrototypeOf2;
|
|
6287
|
+
var _super = _createSuper(Preview);
|
|
6280
6288
|
|
|
6289
|
+
function Preview() {
|
|
6281
6290
|
var _this;
|
|
6282
6291
|
|
|
6283
6292
|
_classCallCheck(this, Preview);
|
|
@@ -6286,7 +6295,7 @@ function (_Component) {
|
|
|
6286
6295
|
args[_key] = arguments[_key];
|
|
6287
6296
|
}
|
|
6288
6297
|
|
|
6289
|
-
_this =
|
|
6298
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
6290
6299
|
|
|
6291
6300
|
_defineProperty(_assertThisInitialized(_this), "mounted", false);
|
|
6292
6301
|
|
|
@@ -6384,15 +6393,15 @@ function (_Component) {
|
|
|
6384
6393
|
}
|
|
6385
6394
|
};
|
|
6386
6395
|
|
|
6387
|
-
var defaultPlayIcon = _react["default"].createElement("div", {
|
|
6396
|
+
var defaultPlayIcon = /*#__PURE__*/_react["default"].createElement("div", {
|
|
6388
6397
|
style: styles.shadow,
|
|
6389
6398
|
className: "react-player__shadow"
|
|
6390
|
-
}, _react["default"].createElement("div", {
|
|
6399
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
6391
6400
|
style: styles.playIcon,
|
|
6392
6401
|
className: "react-player__play-icon"
|
|
6393
6402
|
}));
|
|
6394
6403
|
|
|
6395
|
-
return _react["default"].createElement("div", {
|
|
6404
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
6396
6405
|
style: styles.preview,
|
|
6397
6406
|
className: "react-player__preview",
|
|
6398
6407
|
onClick: onClick
|
|
@@ -6429,6 +6438,12 @@ var _Player = _interopRequireDefault(Player_1);
|
|
|
6429
6438
|
|
|
6430
6439
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
6431
6440
|
|
|
6441
|
+
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; } } }; }
|
|
6442
|
+
|
|
6443
|
+
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); }
|
|
6444
|
+
|
|
6445
|
+
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; }
|
|
6446
|
+
|
|
6432
6447
|
var PRELOAD_PLAYERS = [{
|
|
6433
6448
|
Player: YouTube_1.YouTube,
|
|
6434
6449
|
configKey: 'youtube',
|
|
@@ -6449,16 +6464,16 @@ var PRELOAD_PLAYERS = [{
|
|
|
6449
6464
|
|
|
6450
6465
|
function renderPreloadPlayers(url, controls, config) {
|
|
6451
6466
|
var players = [];
|
|
6452
|
-
|
|
6453
|
-
var
|
|
6454
|
-
|
|
6467
|
+
|
|
6468
|
+
var _iterator = _createForOfIteratorHelper(PRELOAD_PLAYERS),
|
|
6469
|
+
_step;
|
|
6455
6470
|
|
|
6456
6471
|
try {
|
|
6457
|
-
for (
|
|
6472
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
6458
6473
|
var player = _step.value;
|
|
6459
6474
|
|
|
6460
6475
|
if (!player.Player.canPlay(url) && config[player.configKey].preload) {
|
|
6461
|
-
players.push(_react["default"].createElement(_Player["default"], {
|
|
6476
|
+
players.push( /*#__PURE__*/_react["default"].createElement(_Player["default"], {
|
|
6462
6477
|
key: player.Player.displayName,
|
|
6463
6478
|
activePlayer: player.Player,
|
|
6464
6479
|
url: player.url,
|
|
@@ -6470,18 +6485,9 @@ function renderPreloadPlayers(url, controls, config) {
|
|
|
6470
6485
|
}
|
|
6471
6486
|
}
|
|
6472
6487
|
} catch (err) {
|
|
6473
|
-
|
|
6474
|
-
_iteratorError = err;
|
|
6488
|
+
_iterator.e(err);
|
|
6475
6489
|
} finally {
|
|
6476
|
-
|
|
6477
|
-
if (!_iteratorNormalCompletion && _iterator["return"] != null) {
|
|
6478
|
-
_iterator["return"]();
|
|
6479
|
-
}
|
|
6480
|
-
} finally {
|
|
6481
|
-
if (_didIteratorError) {
|
|
6482
|
-
throw _iteratorError;
|
|
6483
|
-
}
|
|
6484
|
-
}
|
|
6490
|
+
_iterator.f();
|
|
6485
6491
|
}
|
|
6486
6492
|
|
|
6487
6493
|
return players;
|
|
@@ -6605,13 +6611,17 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
|
|
|
6605
6611
|
|
|
6606
6612
|
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); }
|
|
6607
6613
|
|
|
6608
|
-
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _nonIterableSpread(); }
|
|
6614
|
+
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
|
6615
|
+
|
|
6616
|
+
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."); }
|
|
6617
|
+
|
|
6618
|
+
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); }
|
|
6609
6619
|
|
|
6610
|
-
function
|
|
6620
|
+
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && Symbol.iterator in Object(iter)) return Array.from(iter); }
|
|
6611
6621
|
|
|
6612
|
-
function
|
|
6622
|
+
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
6613
6623
|
|
|
6614
|
-
function
|
|
6624
|
+
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; }
|
|
6615
6625
|
|
|
6616
6626
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
6617
6627
|
|
|
@@ -6619,12 +6629,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
6619
6629
|
|
|
6620
6630
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
6621
6631
|
|
|
6622
|
-
function
|
|
6632
|
+
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); }; }
|
|
6623
6633
|
|
|
6624
|
-
function
|
|
6634
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
6625
6635
|
|
|
6626
6636
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
6627
6637
|
|
|
6638
|
+
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; } }
|
|
6639
|
+
|
|
6640
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
6641
|
+
|
|
6628
6642
|
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); }
|
|
6629
6643
|
|
|
6630
6644
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -6634,14 +6648,12 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
6634
6648
|
var SUPPORTED_PROPS = Object.keys(props.propTypes);
|
|
6635
6649
|
var customPlayers = [];
|
|
6636
6650
|
|
|
6637
|
-
var ReactPlayer =
|
|
6638
|
-
/*#__PURE__*/
|
|
6639
|
-
function (_Component) {
|
|
6651
|
+
var ReactPlayer = /*#__PURE__*/function (_Component) {
|
|
6640
6652
|
_inherits(ReactPlayer, _Component);
|
|
6641
6653
|
|
|
6642
|
-
|
|
6643
|
-
var _getPrototypeOf2;
|
|
6654
|
+
var _super = _createSuper(ReactPlayer);
|
|
6644
6655
|
|
|
6656
|
+
function ReactPlayer() {
|
|
6645
6657
|
var _this;
|
|
6646
6658
|
|
|
6647
6659
|
_classCallCheck(this, ReactPlayer);
|
|
@@ -6650,7 +6662,7 @@ function (_Component) {
|
|
|
6650
6662
|
args[_key] = arguments[_key];
|
|
6651
6663
|
}
|
|
6652
6664
|
|
|
6653
|
-
_this =
|
|
6665
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
6654
6666
|
|
|
6655
6667
|
_defineProperty(_assertThisInitialized(_this), "config", (0, utils.getConfig)(_this.props, props.defaultProps, true));
|
|
6656
6668
|
|
|
@@ -6761,7 +6773,7 @@ function (_Component) {
|
|
|
6761
6773
|
key: "renderActivePlayer",
|
|
6762
6774
|
value: function renderActivePlayer(url, activePlayer) {
|
|
6763
6775
|
if (!url) return null;
|
|
6764
|
-
return _react["default"].createElement(_Player4["default"], _extends({}, this.props, {
|
|
6776
|
+
return /*#__PURE__*/_react["default"].createElement(_Player4["default"], _extends({}, this.props, {
|
|
6765
6777
|
key: activePlayer.displayName,
|
|
6766
6778
|
ref: this.activePlayerRef,
|
|
6767
6779
|
config: this.config,
|
|
@@ -6798,14 +6810,14 @@ function (_Component) {
|
|
|
6798
6810
|
var preloadPlayers = (0, _preload["default"])(url, controls, this.config);
|
|
6799
6811
|
var players = [renderedActivePlayer].concat(_toConsumableArray(preloadPlayers)).sort(this.sortPlayers);
|
|
6800
6812
|
|
|
6801
|
-
var preview = _react["default"].createElement(_Preview["default"], {
|
|
6813
|
+
var preview = /*#__PURE__*/_react["default"].createElement(_Preview["default"], {
|
|
6802
6814
|
url: url,
|
|
6803
6815
|
light: light,
|
|
6804
6816
|
playIcon: playIcon,
|
|
6805
6817
|
onClick: this.handleClickPreview
|
|
6806
6818
|
});
|
|
6807
6819
|
|
|
6808
|
-
return _react["default"].createElement(Wrapper, _extends({
|
|
6820
|
+
return /*#__PURE__*/_react["default"].createElement(Wrapper, _extends({
|
|
6809
6821
|
ref: this.wrapperRef,
|
|
6810
6822
|
style: _objectSpread({}, style, {
|
|
6811
6823
|
width: width,
|
|
@@ -7353,7 +7365,7 @@ var YouTubeGallery = function YouTubeGallery(_ref) {
|
|
|
7353
7365
|
{ className: 'mb-3' },
|
|
7354
7366
|
nodes.videos[series - 1].title
|
|
7355
7367
|
),
|
|
7356
|
-
nodes.videos[series - 1] && nodes.videos[series - 1].text && React__default.createElement(BlockContent.BlockContent, _extends
|
|
7368
|
+
nodes.videos[series - 1] && nodes.videos[series - 1].text && React__default.createElement(BlockContent.BlockContent, _extends._extends({ serializers: getSerializers, blocks: nodes.videos[series - 1].text, imageOptions: { w: 320, h: 240, fit: 'max' } }, client.config()))
|
|
7357
7369
|
),
|
|
7358
7370
|
React__default.createElement(
|
|
7359
7371
|
'style',
|
|
@@ -7481,7 +7493,7 @@ var Poll = function Poll(_ref) {
|
|
|
7481
7493
|
);
|
|
7482
7494
|
};
|
|
7483
7495
|
|
|
7484
|
-
var numberOfPaginations = main.
|
|
7496
|
+
var numberOfPaginations = main.main_38 ? 4 : 10;
|
|
7485
7497
|
|
|
7486
7498
|
var Quiz = function Quiz(_ref) {
|
|
7487
7499
|
var quizzes = _ref.quizzes,
|
|
@@ -7594,7 +7606,7 @@ var Quiz = function Quiz(_ref) {
|
|
|
7594
7606
|
var renderPagination = function renderPagination() {
|
|
7595
7607
|
return React__default.createElement(
|
|
7596
7608
|
Pagination,
|
|
7597
|
-
{ className: 'p-0 m-0', size: main.
|
|
7609
|
+
{ className: 'p-0 m-0', size: main.main_38 && 'sm' },
|
|
7598
7610
|
React__default.createElement(Pagination.First, { onClick: function onClick() {
|
|
7599
7611
|
return changePage('first');
|
|
7600
7612
|
}, disabled: currentPage === 1 }),
|
|
@@ -7928,7 +7940,7 @@ var MultiFigure = function MultiFigure(props) {
|
|
|
7928
7940
|
{ xs: 12, md: 12 / images.length, key: index },
|
|
7929
7941
|
React__default.createElement(
|
|
7930
7942
|
'a',
|
|
7931
|
-
_extends
|
|
7943
|
+
_extends._extends({}, image.link && { href: image.link, target: image.blank ? '_blank' : '_self' }, { style: { cursor: image.link ? 'pointer' : 'default' } }),
|
|
7932
7944
|
React__default.createElement(
|
|
7933
7945
|
'div',
|
|
7934
7946
|
{ className: 'multi-figure-image-container' },
|