@mjhls/mjh-framework 1.0.533 → 1.0.535
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 +4 -4
- 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/AdSlot.js +2 -2
- package/dist/cjs/AdSlotsProvider.js +1 -1
- package/dist/cjs/ArticleQueue.js +10 -11
- package/dist/cjs/Auth.js +301 -250
- 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 -7
- 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 +11 -11
- package/dist/cjs/Hero.js +1 -1
- package/dist/cjs/HorizontalHero.js +2 -2
- 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 +16 -16
- package/dist/cjs/NavMagazine.js +12 -12
- package/dist/cjs/NavNative.js +11 -11
- package/dist/cjs/OncliveHero.js +2 -2
- package/dist/cjs/OncliveLargeHero.js +2 -2
- package/dist/cjs/PartnerDetailListing.js +20 -1217
- package/dist/cjs/PublicationDeck.js +1 -1
- package/dist/cjs/PublicationLanding.js +33 -33
- 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 +2 -2
- package/dist/cjs/ThumbnailCard.js +1 -1
- package/dist/cjs/Ustream.js +2 -2
- package/dist/cjs/VerticalHero.js +2 -2
- package/dist/cjs/VideoSeriesFilter.js +1 -1
- package/dist/cjs/VideoSeriesListing.js +4 -4
- package/dist/cjs/View.js +38 -39
- 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 +1 -1
- package/dist/cjs/getSerializers.js +589 -443
- package/dist/cjs/{getTargeting-3d208b98.js → getTargeting-b15993cb.js} +11 -11
- package/dist/cjs/getTargeting.js +1 -1
- 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.js +11 -11
- 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 +4 -4
- 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/AdSlot.js +2 -2
- package/dist/esm/AdSlotsProvider.js +1 -1
- package/dist/esm/ArticleQueue.js +10 -11
- package/dist/esm/Auth.js +298 -247
- 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 -7
- 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 +11 -11
- package/dist/esm/Hero.js +1 -1
- package/dist/esm/HorizontalHero.js +2 -2
- 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 +16 -16
- package/dist/esm/NavMagazine.js +12 -12
- package/dist/esm/NavNative.js +11 -11
- package/dist/esm/OncliveHero.js +2 -2
- package/dist/esm/OncliveLargeHero.js +2 -2
- package/dist/esm/PartnerDetailListing.js +18 -1215
- package/dist/esm/PublicationDeck.js +1 -1
- package/dist/esm/PublicationLanding.js +33 -33
- 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 +2 -2
- package/dist/esm/ThumbnailCard.js +1 -1
- package/dist/esm/Ustream.js +2 -2
- package/dist/esm/VerticalHero.js +2 -2
- package/dist/esm/VideoSeriesFilter.js +1 -1
- package/dist/esm/VideoSeriesListing.js +4 -4
- package/dist/esm/View.js +13 -14
- 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 +1 -1
- package/dist/esm/getSerializers.js +589 -443
- package/dist/esm/{getTargeting-1f2c61e3.js → getTargeting-1a0bd08d.js} +9 -9
- package/dist/esm/getTargeting.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.js +11 -11
- 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/Figure-eeac313a.js +0 -154
- package/dist/esm/Figure-bc2b95d7.js +0 -149
- /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');
|
|
@@ -40,7 +40,6 @@ var Button = _interopDefault(require('react-bootstrap/Button'));
|
|
|
40
40
|
var util = require('./util-f2c1b65b.js');
|
|
41
41
|
var brightcoveReactPlayerLoader_es = require('./brightcove-react-player-loader.es-156bd4d6.js');
|
|
42
42
|
var Pagination = _interopDefault(require('react-bootstrap/Pagination'));
|
|
43
|
-
var dynamic = _interopDefault(require('next/dynamic'));
|
|
44
43
|
|
|
45
44
|
var urlFor = function urlFor(source, builder) {
|
|
46
45
|
return builder.image(source).auto('format');
|
|
@@ -105,21 +104,18 @@ var Slideshow = function Slideshow(_ref) {
|
|
|
105
104
|
);
|
|
106
105
|
};
|
|
107
106
|
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
107
|
+
// do not edit .js files directly - edit src/index.jst
|
|
108
|
+
|
|
109
|
+
|
|
111
110
|
|
|
112
111
|
var fastDeepEqual = function equal(a, b) {
|
|
113
112
|
if (a === b) return true;
|
|
114
113
|
|
|
115
114
|
if (a && b && typeof a == 'object' && typeof b == 'object') {
|
|
116
|
-
|
|
117
|
-
, arrB = isArray(b)
|
|
118
|
-
, i
|
|
119
|
-
, length
|
|
120
|
-
, key;
|
|
115
|
+
if (a.constructor !== b.constructor) return false;
|
|
121
116
|
|
|
122
|
-
|
|
117
|
+
var length, i, keys;
|
|
118
|
+
if (Array.isArray(a)) {
|
|
123
119
|
length = a.length;
|
|
124
120
|
if (length != b.length) return false;
|
|
125
121
|
for (i = length; i-- !== 0;)
|
|
@@ -127,35 +123,29 @@ var fastDeepEqual = function equal(a, b) {
|
|
|
127
123
|
return true;
|
|
128
124
|
}
|
|
129
125
|
|
|
130
|
-
if (arrA != arrB) return false;
|
|
131
126
|
|
|
132
|
-
var dateA = a instanceof Date
|
|
133
|
-
, dateB = b instanceof Date;
|
|
134
|
-
if (dateA != dateB) return false;
|
|
135
|
-
if (dateA && dateB) return a.getTime() == b.getTime();
|
|
136
127
|
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
if (
|
|
140
|
-
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();
|
|
141
131
|
|
|
142
|
-
|
|
132
|
+
keys = Object.keys(a);
|
|
143
133
|
length = keys.length;
|
|
144
|
-
|
|
145
|
-
if (length !== keyList(b).length)
|
|
146
|
-
return false;
|
|
134
|
+
if (length !== Object.keys(b).length) return false;
|
|
147
135
|
|
|
148
136
|
for (i = length; i-- !== 0;)
|
|
149
|
-
if (!
|
|
137
|
+
if (!Object.prototype.hasOwnProperty.call(b, keys[i])) return false;
|
|
150
138
|
|
|
151
139
|
for (i = length; i-- !== 0;) {
|
|
152
|
-
key = keys[i];
|
|
140
|
+
var key = keys[i];
|
|
141
|
+
|
|
153
142
|
if (!equal(a[key], b[key])) return false;
|
|
154
143
|
}
|
|
155
144
|
|
|
156
145
|
return true;
|
|
157
146
|
}
|
|
158
147
|
|
|
148
|
+
// true if both NaN, false otherwise
|
|
159
149
|
return a!==a && b!==b;
|
|
160
150
|
};
|
|
161
151
|
|
|
@@ -1578,199 +1568,235 @@ module.exports = exports['default'];
|
|
|
1578
1568
|
|
|
1579
1569
|
var youTubePlayer = _commonjsHelpers.unwrapExports(dist);
|
|
1580
1570
|
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
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); }
|
|
1584
1572
|
|
|
1585
1573
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
1586
1574
|
|
|
1587
|
-
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); }; }
|
|
1588
1580
|
|
|
1589
|
-
function
|
|
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; }
|
|
1590
1584
|
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
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; }
|
|
1594
|
+
|
|
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; }
|
|
1596
|
+
|
|
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
|
|
1596
1603
|
*/
|
|
1604
|
+
|
|
1597
1605
|
function shouldUpdateVideo(prevProps, props) {
|
|
1598
1606
|
// A changing video should always trigger an update
|
|
1599
1607
|
if (prevProps.videoId !== props.videoId) {
|
|
1600
1608
|
return true;
|
|
1601
|
-
}
|
|
1602
|
-
|
|
1603
|
-
// 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
|
|
1604
1610
|
// update.
|
|
1611
|
+
|
|
1612
|
+
|
|
1605
1613
|
var prevVars = prevProps.opts.playerVars || {};
|
|
1606
1614
|
var vars = props.opts.playerVars || {};
|
|
1607
|
-
|
|
1608
1615
|
return prevVars.start !== vars.start || prevVars.end !== vars.end;
|
|
1609
1616
|
}
|
|
1610
|
-
|
|
1611
|
-
|
|
1612
|
-
*
|
|
1613
|
-
*
|
|
1614
|
-
*
|
|
1615
|
-
*
|
|
1616
|
-
* @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
|
|
1617
1623
|
*/
|
|
1624
|
+
|
|
1625
|
+
|
|
1618
1626
|
function filterResetOptions(opts) {
|
|
1619
|
-
return
|
|
1620
|
-
playerVars:
|
|
1627
|
+
return _objectSpread({}, opts, {
|
|
1628
|
+
playerVars: _objectSpread({}, opts.playerVars, {
|
|
1621
1629
|
autoplay: 0,
|
|
1622
1630
|
start: 0,
|
|
1623
1631
|
end: 0
|
|
1624
1632
|
})
|
|
1625
1633
|
});
|
|
1626
1634
|
}
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
*
|
|
1630
|
-
*
|
|
1631
|
-
*
|
|
1632
|
-
*
|
|
1633
|
-
*
|
|
1634
|
-
* @param {Object}
|
|
1635
|
-
* @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
|
|
1636
1643
|
*/
|
|
1644
|
+
|
|
1645
|
+
|
|
1637
1646
|
function shouldResetPlayer(prevProps, props) {
|
|
1638
1647
|
return !fastDeepEqual(filterResetOptions(prevProps.opts), filterResetOptions(props.opts));
|
|
1639
1648
|
}
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
*
|
|
1643
|
-
*
|
|
1644
|
-
* @param {Object}
|
|
1645
|
-
* @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
|
|
1646
1654
|
*/
|
|
1655
|
+
|
|
1656
|
+
|
|
1647
1657
|
function shouldUpdatePlayer(prevProps, props) {
|
|
1648
1658
|
return prevProps.id !== props.id || prevProps.className !== props.className;
|
|
1649
1659
|
}
|
|
1650
1660
|
|
|
1651
|
-
var YouTube = function (_React$Component) {
|
|
1661
|
+
var YouTube = /*#__PURE__*/function (_React$Component) {
|
|
1652
1662
|
_inherits(YouTube, _React$Component);
|
|
1653
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
|
+
*/
|
|
1654
1671
|
function YouTube(props) {
|
|
1672
|
+
var _this;
|
|
1673
|
+
|
|
1655
1674
|
_classCallCheck(this, YouTube);
|
|
1656
1675
|
|
|
1657
|
-
|
|
1676
|
+
_this = _super.call(this, props);
|
|
1658
1677
|
|
|
1659
|
-
_this
|
|
1678
|
+
_defineProperty(_assertThisInitialized(_this), "onPlayerReady", function (event) {
|
|
1660
1679
|
return _this.props.onReady(event);
|
|
1661
|
-
};
|
|
1680
|
+
});
|
|
1662
1681
|
|
|
1663
|
-
_this
|
|
1682
|
+
_defineProperty(_assertThisInitialized(_this), "onPlayerError", function (event) {
|
|
1664
1683
|
return _this.props.onError(event);
|
|
1665
|
-
};
|
|
1684
|
+
});
|
|
1666
1685
|
|
|
1667
|
-
_this
|
|
1686
|
+
_defineProperty(_assertThisInitialized(_this), "onPlayerStateChange", function (event) {
|
|
1668
1687
|
_this.props.onStateChange(event);
|
|
1669
|
-
switch (event.data) {
|
|
1670
1688
|
|
|
1689
|
+
switch (event.data) {
|
|
1671
1690
|
case YouTube.PlayerState.ENDED:
|
|
1672
1691
|
_this.props.onEnd(event);
|
|
1692
|
+
|
|
1673
1693
|
break;
|
|
1674
1694
|
|
|
1675
1695
|
case YouTube.PlayerState.PLAYING:
|
|
1676
1696
|
_this.props.onPlay(event);
|
|
1697
|
+
|
|
1677
1698
|
break;
|
|
1678
1699
|
|
|
1679
1700
|
case YouTube.PlayerState.PAUSED:
|
|
1680
1701
|
_this.props.onPause(event);
|
|
1702
|
+
|
|
1681
1703
|
break;
|
|
1682
1704
|
}
|
|
1683
|
-
};
|
|
1705
|
+
});
|
|
1684
1706
|
|
|
1685
|
-
_this
|
|
1707
|
+
_defineProperty(_assertThisInitialized(_this), "onPlayerPlaybackRateChange", function (event) {
|
|
1686
1708
|
return _this.props.onPlaybackRateChange(event);
|
|
1687
|
-
};
|
|
1709
|
+
});
|
|
1688
1710
|
|
|
1689
|
-
_this
|
|
1711
|
+
_defineProperty(_assertThisInitialized(_this), "onPlayerPlaybackQualityChange", function (event) {
|
|
1690
1712
|
return _this.props.onPlaybackQualityChange(event);
|
|
1691
|
-
};
|
|
1713
|
+
});
|
|
1692
1714
|
|
|
1693
|
-
_this
|
|
1715
|
+
_defineProperty(_assertThisInitialized(_this), "createPlayer", function () {
|
|
1694
1716
|
// do not attempt to create a player server-side, it won't work
|
|
1695
|
-
if (typeof document === 'undefined') return;
|
|
1696
|
-
|
|
1697
|
-
var playerOpts =
|
|
1717
|
+
if (typeof document === 'undefined') return; // create player
|
|
1718
|
+
|
|
1719
|
+
var playerOpts = _objectSpread({}, _this.props.opts, {
|
|
1698
1720
|
// preload the `videoId` video if one is already given
|
|
1699
1721
|
videoId: _this.props.videoId
|
|
1700
1722
|
});
|
|
1701
|
-
|
|
1702
|
-
// attach event handlers
|
|
1723
|
+
|
|
1724
|
+
_this.internalPlayer = youTubePlayer(_this.container, playerOpts); // attach event handlers
|
|
1725
|
+
|
|
1703
1726
|
_this.internalPlayer.on('ready', _this.onPlayerReady);
|
|
1727
|
+
|
|
1704
1728
|
_this.internalPlayer.on('error', _this.onPlayerError);
|
|
1729
|
+
|
|
1705
1730
|
_this.internalPlayer.on('stateChange', _this.onPlayerStateChange);
|
|
1731
|
+
|
|
1706
1732
|
_this.internalPlayer.on('playbackRateChange', _this.onPlayerPlaybackRateChange);
|
|
1733
|
+
|
|
1707
1734
|
_this.internalPlayer.on('playbackQualityChange', _this.onPlayerPlaybackQualityChange);
|
|
1708
|
-
};
|
|
1735
|
+
});
|
|
1709
1736
|
|
|
1710
|
-
_this
|
|
1737
|
+
_defineProperty(_assertThisInitialized(_this), "resetPlayer", function () {
|
|
1711
1738
|
return _this.internalPlayer.destroy().then(_this.createPlayer);
|
|
1712
|
-
};
|
|
1739
|
+
});
|
|
1713
1740
|
|
|
1714
|
-
_this
|
|
1741
|
+
_defineProperty(_assertThisInitialized(_this), "updatePlayer", function () {
|
|
1715
1742
|
_this.internalPlayer.getIframe().then(function (iframe) {
|
|
1716
1743
|
if (_this.props.id) iframe.setAttribute('id', _this.props.id);else iframe.removeAttribute('id');
|
|
1717
1744
|
if (_this.props.className) iframe.setAttribute('class', _this.props.className);else iframe.removeAttribute('class');
|
|
1718
1745
|
});
|
|
1719
|
-
};
|
|
1746
|
+
});
|
|
1720
1747
|
|
|
1721
|
-
_this
|
|
1748
|
+
_defineProperty(_assertThisInitialized(_this), "updateVideo", function () {
|
|
1722
1749
|
if (typeof _this.props.videoId === 'undefined' || _this.props.videoId === null) {
|
|
1723
1750
|
_this.internalPlayer.stopVideo();
|
|
1751
|
+
|
|
1724
1752
|
return;
|
|
1725
|
-
}
|
|
1753
|
+
} // set queueing options
|
|
1754
|
+
|
|
1726
1755
|
|
|
1727
|
-
// set queueing options
|
|
1728
1756
|
var autoplay = false;
|
|
1729
1757
|
var opts = {
|
|
1730
1758
|
videoId: _this.props.videoId
|
|
1731
1759
|
};
|
|
1760
|
+
|
|
1732
1761
|
if ('playerVars' in _this.props.opts) {
|
|
1733
1762
|
autoplay = _this.props.opts.playerVars.autoplay === 1;
|
|
1763
|
+
|
|
1734
1764
|
if ('start' in _this.props.opts.playerVars) {
|
|
1735
1765
|
opts.startSeconds = _this.props.opts.playerVars.start;
|
|
1736
1766
|
}
|
|
1767
|
+
|
|
1737
1768
|
if ('end' in _this.props.opts.playerVars) {
|
|
1738
1769
|
opts.endSeconds = _this.props.opts.playerVars.end;
|
|
1739
1770
|
}
|
|
1740
|
-
}
|
|
1771
|
+
} // if autoplay is enabled loadVideoById
|
|
1772
|
+
|
|
1741
1773
|
|
|
1742
|
-
// if autoplay is enabled loadVideoById
|
|
1743
1774
|
if (autoplay) {
|
|
1744
1775
|
_this.internalPlayer.loadVideoById(opts);
|
|
1776
|
+
|
|
1745
1777
|
return;
|
|
1746
|
-
}
|
|
1747
|
-
|
|
1778
|
+
} // default behaviour just cues the video
|
|
1779
|
+
|
|
1780
|
+
|
|
1748
1781
|
_this.internalPlayer.cueVideoById(opts);
|
|
1749
|
-
};
|
|
1782
|
+
});
|
|
1750
1783
|
|
|
1751
|
-
_this
|
|
1784
|
+
_defineProperty(_assertThisInitialized(_this), "refContainer", function (container) {
|
|
1752
1785
|
_this.container = container;
|
|
1753
|
-
};
|
|
1786
|
+
});
|
|
1754
1787
|
|
|
1755
1788
|
_this.container = null;
|
|
1756
1789
|
_this.internalPlayer = null;
|
|
1757
1790
|
return _this;
|
|
1758
1791
|
}
|
|
1759
1792
|
|
|
1760
|
-
/**
|
|
1761
|
-
* Expose PlayerState constants for convenience. These constants can also be
|
|
1762
|
-
* accessed through the global YT object after the YouTube IFrame API is instantiated.
|
|
1763
|
-
* https://developers.google.com/youtube/iframe_api_reference#onStateChange
|
|
1764
|
-
*/
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
1793
|
_createClass(YouTube, [{
|
|
1768
|
-
key:
|
|
1794
|
+
key: "componentDidMount",
|
|
1769
1795
|
value: function componentDidMount() {
|
|
1770
1796
|
this.createPlayer();
|
|
1771
1797
|
}
|
|
1772
1798
|
}, {
|
|
1773
|
-
key:
|
|
1799
|
+
key: "componentDidUpdate",
|
|
1774
1800
|
value: function componentDidUpdate(prevProps) {
|
|
1775
1801
|
if (shouldUpdatePlayer(prevProps, this.props)) {
|
|
1776
1802
|
this.updatePlayer();
|
|
@@ -1785,112 +1811,58 @@ var YouTube = function (_React$Component) {
|
|
|
1785
1811
|
}
|
|
1786
1812
|
}
|
|
1787
1813
|
}, {
|
|
1788
|
-
key:
|
|
1814
|
+
key: "componentWillUnmount",
|
|
1789
1815
|
value: function componentWillUnmount() {
|
|
1790
|
-
/**
|
|
1791
|
-
* Note: The `youtube-player` package that is used promisifies all
|
|
1792
|
-
* Player API calls, which introduces a delay of a tick before it actually
|
|
1793
|
-
* gets destroyed. Since React attempts to remove the element instantly
|
|
1794
|
-
* 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.
|
|
1795
1821
|
*/
|
|
1796
1822
|
this.internalPlayer.destroy();
|
|
1797
1823
|
}
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
*
|
|
1801
|
-
*
|
|
1802
|
-
*
|
|
1803
|
-
* @param {Object} target - player object
|
|
1804
|
-
*/
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
/**
|
|
1808
|
-
* https://developers.google.com/youtube/iframe_api_reference#onError
|
|
1809
|
-
*
|
|
1810
|
-
* @param {Object} event
|
|
1811
|
-
* @param {Integer} data - error type
|
|
1812
|
-
* @param {Object} target - player object
|
|
1813
|
-
*/
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
/**
|
|
1817
|
-
* https://developers.google.com/youtube/iframe_api_reference#onStateChange
|
|
1818
|
-
*
|
|
1819
|
-
* @param {Object} event
|
|
1820
|
-
* @param {Integer} data - status change type
|
|
1821
|
-
* @param {Object} target - actual YT player
|
|
1822
|
-
*/
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
/**
|
|
1826
|
-
* https://developers.google.com/youtube/iframe_api_reference#onPlaybackRateChange
|
|
1827
|
-
*
|
|
1828
|
-
* @param {Object} event
|
|
1829
|
-
* @param {Float} data - playback rate
|
|
1830
|
-
* @param {Object} target - actual YT player
|
|
1831
|
-
*/
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
/**
|
|
1835
|
-
* https://developers.google.com/youtube/iframe_api_reference#onPlaybackQualityChange
|
|
1836
|
-
*
|
|
1837
|
-
* @param {Object} event
|
|
1838
|
-
* @param {String} data - playback quality
|
|
1839
|
-
* @param {Object} target - actual YT player
|
|
1840
|
-
*/
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
/**
|
|
1844
|
-
* Initialize the Youtube Player API on the container and attach event handlers
|
|
1845
|
-
*/
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
/**
|
|
1849
|
-
* Shorthand for destroying and then re-creating the Youtube Player
|
|
1850
|
-
*/
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
/**
|
|
1854
|
-
* Method to update the id and class of the Youtube Player iframe.
|
|
1855
|
-
* React should update this automatically but since the Youtube Player API
|
|
1856
|
-
* replaced the DIV that is mounted by React we need to do this manually.
|
|
1857
|
-
*/
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
/**
|
|
1861
|
-
* Call Youtube Player API methods to update the currently playing video.
|
|
1862
|
-
* Depeding on the `opts.playerVars.autoplay` this function uses one of two
|
|
1863
|
-
* 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
|
|
1864
1829
|
*/
|
|
1865
1830
|
|
|
1866
1831
|
}, {
|
|
1867
|
-
key:
|
|
1832
|
+
key: "render",
|
|
1868
1833
|
value: function render() {
|
|
1869
|
-
return React__default.createElement(
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
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
|
+
}));
|
|
1874
1841
|
}
|
|
1875
1842
|
}]);
|
|
1876
1843
|
|
|
1877
1844
|
return YouTube;
|
|
1878
1845
|
}(React__default.Component);
|
|
1879
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
|
+
|
|
1880
1856
|
YouTube.propTypes = {
|
|
1881
1857
|
videoId: PropTypes.string,
|
|
1882
|
-
|
|
1883
1858
|
// custom ID for player element
|
|
1884
1859
|
id: PropTypes.string,
|
|
1885
|
-
|
|
1886
1860
|
// custom class name for player element
|
|
1887
1861
|
className: PropTypes.string,
|
|
1888
1862
|
// custom class name for player container element
|
|
1889
1863
|
containerClassName: PropTypes.string,
|
|
1890
|
-
|
|
1891
1864
|
// https://developers.google.com/youtube/iframe_api_reference#Loading_a_Video_Player
|
|
1892
1865
|
opts: PropTypes.objectOf(PropTypes.any),
|
|
1893
|
-
|
|
1894
1866
|
// event subscriptions
|
|
1895
1867
|
onReady: PropTypes.func,
|
|
1896
1868
|
onError: PropTypes.func,
|
|
@@ -1902,6 +1874,7 @@ YouTube.propTypes = {
|
|
|
1902
1874
|
onPlaybackQualityChange: PropTypes.func
|
|
1903
1875
|
};
|
|
1904
1876
|
YouTube.defaultProps = {
|
|
1877
|
+
videoId: null,
|
|
1905
1878
|
id: null,
|
|
1906
1879
|
className: null,
|
|
1907
1880
|
opts: {},
|
|
@@ -1915,14 +1888,6 @@ YouTube.defaultProps = {
|
|
|
1915
1888
|
onPlaybackRateChange: function onPlaybackRateChange() {},
|
|
1916
1889
|
onPlaybackQualityChange: function onPlaybackQualityChange() {}
|
|
1917
1890
|
};
|
|
1918
|
-
YouTube.PlayerState = {
|
|
1919
|
-
UNSTARTED: -1,
|
|
1920
|
-
ENDED: 0,
|
|
1921
|
-
PLAYING: 1,
|
|
1922
|
-
PAUSED: 2,
|
|
1923
|
-
BUFFERING: 3,
|
|
1924
|
-
CUED: 5
|
|
1925
|
-
};
|
|
1926
1891
|
|
|
1927
1892
|
var YouTubePlayer = function YouTubePlayer(_ref) {
|
|
1928
1893
|
var url = _ref.url;
|
|
@@ -2183,7 +2148,7 @@ var Media = function Media(_ref) {
|
|
|
2183
2148
|
React__default.createElement(
|
|
2184
2149
|
'a',
|
|
2185
2150
|
{ href: uploadDoc.asset.url, target: blank ? '_blank' : '_self' },
|
|
2186
|
-
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 })),
|
|
2187
2152
|
caption && React__default.createElement(
|
|
2188
2153
|
reactBootstrap.Figure.Caption,
|
|
2189
2154
|
{ className: 'media-caption' },
|
|
@@ -2194,7 +2159,7 @@ var Media = function Media(_ref) {
|
|
|
2194
2159
|
} else if (caption && caption !== '') {
|
|
2195
2160
|
return React__default.createElement(
|
|
2196
2161
|
'a',
|
|
2197
|
-
_extends
|
|
2162
|
+
_extends._extends({}, uploadDoc.downloadMedia ? {
|
|
2198
2163
|
href: uploadDoc.asset.url + '?dl='
|
|
2199
2164
|
} : { href: uploadDoc.asset.url, target: blank ? '_blank' : '_self', rel: 'noopener noreferrer' }, {
|
|
2200
2165
|
style: { paddingLeft: '4px', paddingRight: '4px' },
|
|
@@ -2757,11 +2722,17 @@ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "functi
|
|
|
2757
2722
|
|
|
2758
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; }
|
|
2759
2724
|
|
|
2760
|
-
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(); }
|
|
2728
|
+
|
|
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."); }
|
|
2730
|
+
|
|
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); }
|
|
2761
2732
|
|
|
2762
|
-
function
|
|
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; }
|
|
2763
2734
|
|
|
2764
|
-
function _iterableToArrayLimit(arr, i) { if (!(Symbol.iterator in Object(arr)
|
|
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; }
|
|
2765
2736
|
|
|
2766
2737
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
2767
2738
|
|
|
@@ -2891,12 +2862,12 @@ function getSDK(url, sdkGlobal) {
|
|
|
2891
2862
|
|
|
2892
2863
|
function getConfig(props$1, defaultProps, showWarning) {
|
|
2893
2864
|
var config = (0, _deepmerge["default"])(defaultProps.config, props$1.config);
|
|
2894
|
-
|
|
2895
|
-
var
|
|
2896
|
-
|
|
2865
|
+
|
|
2866
|
+
var _iterator = _createForOfIteratorHelper(props.DEPRECATED_CONFIG_PROPS),
|
|
2867
|
+
_step;
|
|
2897
2868
|
|
|
2898
2869
|
try {
|
|
2899
|
-
for (
|
|
2870
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
2900
2871
|
var p = _step.value;
|
|
2901
2872
|
|
|
2902
2873
|
if (props$1[p]) {
|
|
@@ -2911,18 +2882,9 @@ function getConfig(props$1, defaultProps, showWarning) {
|
|
|
2911
2882
|
}
|
|
2912
2883
|
}
|
|
2913
2884
|
} catch (err) {
|
|
2914
|
-
|
|
2915
|
-
_iteratorError = err;
|
|
2885
|
+
_iterator.e(err);
|
|
2916
2886
|
} finally {
|
|
2917
|
-
|
|
2918
|
-
if (!_iteratorNormalCompletion && _iterator["return"] != null) {
|
|
2919
|
-
_iterator["return"]();
|
|
2920
|
-
}
|
|
2921
|
-
} finally {
|
|
2922
|
-
if (_didIteratorError) {
|
|
2923
|
-
throw _iteratorError;
|
|
2924
|
-
}
|
|
2925
|
-
}
|
|
2887
|
+
_iterator.f();
|
|
2926
2888
|
}
|
|
2927
2889
|
|
|
2928
2890
|
return config;
|
|
@@ -3069,12 +3031,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
3069
3031
|
|
|
3070
3032
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
3071
3033
|
|
|
3072
|
-
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); }; }
|
|
3073
3035
|
|
|
3074
|
-
function
|
|
3036
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
3075
3037
|
|
|
3076
3038
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
3077
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
|
+
|
|
3078
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); }
|
|
3079
3045
|
|
|
3080
3046
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -3083,14 +3049,12 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
3083
3049
|
|
|
3084
3050
|
var SEEK_ON_PLAY_EXPIRY = 5000;
|
|
3085
3051
|
|
|
3086
|
-
var Player =
|
|
3087
|
-
/*#__PURE__*/
|
|
3088
|
-
function (_Component) {
|
|
3052
|
+
var Player = /*#__PURE__*/function (_Component) {
|
|
3089
3053
|
_inherits(Player, _Component);
|
|
3090
3054
|
|
|
3091
|
-
|
|
3092
|
-
var _getPrototypeOf2;
|
|
3055
|
+
var _super = _createSuper(Player);
|
|
3093
3056
|
|
|
3057
|
+
function Player() {
|
|
3094
3058
|
var _this;
|
|
3095
3059
|
|
|
3096
3060
|
_classCallCheck(this, Player);
|
|
@@ -3099,7 +3063,7 @@ function (_Component) {
|
|
|
3099
3063
|
_args[_key] = arguments[_key];
|
|
3100
3064
|
}
|
|
3101
3065
|
|
|
3102
|
-
_this =
|
|
3066
|
+
_this = _super.call.apply(_super, [this].concat(_args));
|
|
3103
3067
|
|
|
3104
3068
|
_defineProperty(_assertThisInitialized(_this), "mounted", false);
|
|
3105
3069
|
|
|
@@ -3424,7 +3388,7 @@ function (_Component) {
|
|
|
3424
3388
|
return null;
|
|
3425
3389
|
}
|
|
3426
3390
|
|
|
3427
|
-
return _react["default"].createElement(Player, _extends({}, this.props, {
|
|
3391
|
+
return /*#__PURE__*/_react["default"].createElement(Player, _extends({}, this.props, {
|
|
3428
3392
|
ref: this.ref,
|
|
3429
3393
|
onReady: this.handleReady,
|
|
3430
3394
|
onPlay: this.handlePlay,
|
|
@@ -3485,12 +3449,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
3485
3449
|
|
|
3486
3450
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
3487
3451
|
|
|
3488
|
-
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); }; }
|
|
3489
3453
|
|
|
3490
|
-
function
|
|
3454
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
3491
3455
|
|
|
3492
3456
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
3493
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
|
+
|
|
3494
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); }
|
|
3495
3463
|
|
|
3496
3464
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -3502,14 +3470,12 @@ var SUPPORTED_PROPS = Object.keys(props.propTypes);
|
|
|
3502
3470
|
function createSinglePlayer(activePlayer) {
|
|
3503
3471
|
var _class, _temp;
|
|
3504
3472
|
|
|
3505
|
-
return _temp = _class =
|
|
3506
|
-
/*#__PURE__*/
|
|
3507
|
-
function (_Component) {
|
|
3473
|
+
return _temp = _class = /*#__PURE__*/function (_Component) {
|
|
3508
3474
|
_inherits(SinglePlayer, _Component);
|
|
3509
3475
|
|
|
3510
|
-
|
|
3511
|
-
var _getPrototypeOf2;
|
|
3476
|
+
var _super = _createSuper(SinglePlayer);
|
|
3512
3477
|
|
|
3478
|
+
function SinglePlayer() {
|
|
3513
3479
|
var _this;
|
|
3514
3480
|
|
|
3515
3481
|
_classCallCheck(this, SinglePlayer);
|
|
@@ -3518,7 +3484,7 @@ function createSinglePlayer(activePlayer) {
|
|
|
3518
3484
|
args[_key] = arguments[_key];
|
|
3519
3485
|
}
|
|
3520
3486
|
|
|
3521
|
-
_this =
|
|
3487
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
3522
3488
|
|
|
3523
3489
|
_defineProperty(_assertThisInitialized(_this), "config", (0, utils.getConfig)(_this.props, props.defaultProps, true));
|
|
3524
3490
|
|
|
@@ -3586,12 +3552,12 @@ function createSinglePlayer(activePlayer) {
|
|
|
3586
3552
|
height = _this$props.height,
|
|
3587
3553
|
Wrapper = _this$props.wrapper;
|
|
3588
3554
|
var otherProps = (0, utils.omit)(this.props, SUPPORTED_PROPS, props.DEPRECATED_CONFIG_PROPS);
|
|
3589
|
-
return _react["default"].createElement(Wrapper, _extends({
|
|
3555
|
+
return /*#__PURE__*/_react["default"].createElement(Wrapper, _extends({
|
|
3590
3556
|
style: _objectSpread({}, style, {
|
|
3591
3557
|
width: width,
|
|
3592
3558
|
height: height
|
|
3593
3559
|
})
|
|
3594
|
-
}, otherProps), _react["default"].createElement(_Player["default"], _extends({}, this.props, {
|
|
3560
|
+
}, otherProps), /*#__PURE__*/_react["default"].createElement(_Player["default"], _extends({}, this.props, {
|
|
3595
3561
|
ref: this.ref,
|
|
3596
3562
|
activePlayer: activePlayer,
|
|
3597
3563
|
config: this.config
|
|
@@ -3637,23 +3603,31 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
3637
3603
|
|
|
3638
3604
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
3639
3605
|
|
|
3640
|
-
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); }; }
|
|
3641
3607
|
|
|
3642
|
-
function
|
|
3608
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
3643
3609
|
|
|
3644
3610
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
3645
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
|
+
|
|
3646
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); }
|
|
3647
3617
|
|
|
3648
3618
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
3649
3619
|
|
|
3650
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; }
|
|
3651
3621
|
|
|
3652
|
-
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); }
|
|
3653
3627
|
|
|
3654
|
-
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; }
|
|
3655
3629
|
|
|
3656
|
-
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; }
|
|
3657
3631
|
|
|
3658
3632
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
3659
3633
|
|
|
@@ -3678,14 +3652,12 @@ function parsePlaylist(url) {
|
|
|
3678
3652
|
return {};
|
|
3679
3653
|
}
|
|
3680
3654
|
|
|
3681
|
-
var YouTube =
|
|
3682
|
-
/*#__PURE__*/
|
|
3683
|
-
function (_Component) {
|
|
3655
|
+
var YouTube = /*#__PURE__*/function (_Component) {
|
|
3684
3656
|
_inherits(YouTube, _Component);
|
|
3685
3657
|
|
|
3686
|
-
|
|
3687
|
-
var _getPrototypeOf2;
|
|
3658
|
+
var _super = _createSuper(YouTube);
|
|
3688
3659
|
|
|
3660
|
+
function YouTube() {
|
|
3689
3661
|
var _this;
|
|
3690
3662
|
|
|
3691
3663
|
_classCallCheck(this, YouTube);
|
|
@@ -3694,7 +3666,7 @@ function (_Component) {
|
|
|
3694
3666
|
args[_key] = arguments[_key];
|
|
3695
3667
|
}
|
|
3696
3668
|
|
|
3697
|
-
_this =
|
|
3669
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
3698
3670
|
|
|
3699
3671
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
3700
3672
|
|
|
@@ -3882,9 +3854,9 @@ function (_Component) {
|
|
|
3882
3854
|
height: '100%',
|
|
3883
3855
|
display: display
|
|
3884
3856
|
};
|
|
3885
|
-
return _react["default"].createElement("div", {
|
|
3857
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
3886
3858
|
style: style
|
|
3887
|
-
}, _react["default"].createElement("div", {
|
|
3859
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
3888
3860
|
ref: this.ref
|
|
3889
3861
|
}));
|
|
3890
3862
|
}
|
|
@@ -3940,12 +3912,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
3940
3912
|
|
|
3941
3913
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
3942
3914
|
|
|
3943
|
-
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); }; }
|
|
3944
3916
|
|
|
3945
|
-
function
|
|
3917
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
3946
3918
|
|
|
3947
3919
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
3948
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
|
+
|
|
3949
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); }
|
|
3950
3926
|
|
|
3951
3927
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -3954,16 +3930,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
3954
3930
|
|
|
3955
3931
|
var SDK_URL = 'https://w.soundcloud.com/player/api.js';
|
|
3956
3932
|
var SDK_GLOBAL = 'SC';
|
|
3957
|
-
var MATCH_URL = /(soundcloud\.com|snd\.sc)
|
|
3933
|
+
var MATCH_URL = /(?:soundcloud\.com|snd\.sc)\/[^.]+$/;
|
|
3958
3934
|
|
|
3959
|
-
var SoundCloud =
|
|
3960
|
-
/*#__PURE__*/
|
|
3961
|
-
function (_Component) {
|
|
3935
|
+
var SoundCloud = /*#__PURE__*/function (_Component) {
|
|
3962
3936
|
_inherits(SoundCloud, _Component);
|
|
3963
3937
|
|
|
3964
|
-
|
|
3965
|
-
var _getPrototypeOf2;
|
|
3938
|
+
var _super = _createSuper(SoundCloud);
|
|
3966
3939
|
|
|
3940
|
+
function SoundCloud() {
|
|
3967
3941
|
var _this;
|
|
3968
3942
|
|
|
3969
3943
|
_classCallCheck(this, SoundCloud);
|
|
@@ -3972,7 +3946,7 @@ function (_Component) {
|
|
|
3972
3946
|
args[_key] = arguments[_key];
|
|
3973
3947
|
}
|
|
3974
3948
|
|
|
3975
|
-
_this =
|
|
3949
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
3976
3950
|
|
|
3977
3951
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
3978
3952
|
|
|
@@ -4093,7 +4067,7 @@ function (_Component) {
|
|
|
4093
4067
|
height: '100%',
|
|
4094
4068
|
display: display
|
|
4095
4069
|
};
|
|
4096
|
-
return _react["default"].createElement("iframe", {
|
|
4070
|
+
return /*#__PURE__*/_react["default"].createElement("iframe", {
|
|
4097
4071
|
ref: this.ref,
|
|
4098
4072
|
src: "https://w.soundcloud.com/player/?url=".concat(encodeURIComponent(this.props.url)),
|
|
4099
4073
|
style: style,
|
|
@@ -4155,12 +4129,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
4155
4129
|
|
|
4156
4130
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
4157
4131
|
|
|
4158
|
-
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); }; }
|
|
4159
4133
|
|
|
4160
|
-
function
|
|
4134
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
4161
4135
|
|
|
4162
4136
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
4163
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
|
+
|
|
4164
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); }
|
|
4165
4143
|
|
|
4166
4144
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -4172,14 +4150,12 @@ var SDK_GLOBAL = 'Vimeo';
|
|
|
4172
4150
|
var MATCH_URL = /vimeo\.com\/.+/;
|
|
4173
4151
|
var MATCH_FILE_URL = /vimeo\.com\/external\/[0-9]+\..+/;
|
|
4174
4152
|
|
|
4175
|
-
var Vimeo =
|
|
4176
|
-
/*#__PURE__*/
|
|
4177
|
-
function (_Component) {
|
|
4153
|
+
var Vimeo = /*#__PURE__*/function (_Component) {
|
|
4178
4154
|
_inherits(Vimeo, _Component);
|
|
4179
4155
|
|
|
4180
|
-
|
|
4181
|
-
var _getPrototypeOf2;
|
|
4156
|
+
var _super = _createSuper(Vimeo);
|
|
4182
4157
|
|
|
4158
|
+
function Vimeo() {
|
|
4183
4159
|
var _this;
|
|
4184
4160
|
|
|
4185
4161
|
_classCallCheck(this, Vimeo);
|
|
@@ -4188,7 +4164,7 @@ function (_Component) {
|
|
|
4188
4164
|
args[_key] = arguments[_key];
|
|
4189
4165
|
}
|
|
4190
4166
|
|
|
4191
|
-
_this =
|
|
4167
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
4192
4168
|
|
|
4193
4169
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
4194
4170
|
|
|
@@ -4345,7 +4321,7 @@ function (_Component) {
|
|
|
4345
4321
|
overflow: 'hidden',
|
|
4346
4322
|
display: display
|
|
4347
4323
|
};
|
|
4348
|
-
return _react["default"].createElement("div", {
|
|
4324
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
4349
4325
|
key: this.props.url,
|
|
4350
4326
|
ref: this.ref,
|
|
4351
4327
|
style: style
|
|
@@ -4405,12 +4381,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
4405
4381
|
|
|
4406
4382
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
4407
4383
|
|
|
4408
|
-
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); }; }
|
|
4409
4385
|
|
|
4410
|
-
function
|
|
4386
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
4411
4387
|
|
|
4412
4388
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
4413
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
|
+
|
|
4414
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); }
|
|
4415
4395
|
|
|
4416
4396
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -4423,14 +4403,12 @@ var SDK_GLOBAL_READY = 'fbAsyncInit';
|
|
|
4423
4403
|
var MATCH_URL = /^https?:\/\/(www\.)?facebook\.com.*\/(video(s)?|watch|story)(\.php?|\/).+$/;
|
|
4424
4404
|
var PLAYER_ID_PREFIX = 'facebook-player-';
|
|
4425
4405
|
|
|
4426
|
-
var Facebook =
|
|
4427
|
-
/*#__PURE__*/
|
|
4428
|
-
function (_Component) {
|
|
4406
|
+
var Facebook = /*#__PURE__*/function (_Component) {
|
|
4429
4407
|
_inherits(Facebook, _Component);
|
|
4430
4408
|
|
|
4431
|
-
|
|
4432
|
-
var _getPrototypeOf2;
|
|
4409
|
+
var _super = _createSuper(Facebook);
|
|
4433
4410
|
|
|
4411
|
+
function Facebook() {
|
|
4434
4412
|
var _this;
|
|
4435
4413
|
|
|
4436
4414
|
_classCallCheck(this, Facebook);
|
|
@@ -4439,7 +4417,7 @@ function (_Component) {
|
|
|
4439
4417
|
args[_key] = arguments[_key];
|
|
4440
4418
|
}
|
|
4441
4419
|
|
|
4442
|
-
_this =
|
|
4420
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
4443
4421
|
|
|
4444
4422
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
4445
4423
|
|
|
@@ -4555,7 +4533,7 @@ function (_Component) {
|
|
|
4555
4533
|
width: '100%',
|
|
4556
4534
|
height: '100%'
|
|
4557
4535
|
};
|
|
4558
|
-
return _react["default"].createElement("div", {
|
|
4536
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
4559
4537
|
style: style,
|
|
4560
4538
|
id: this.playerID,
|
|
4561
4539
|
className: "fb-video",
|
|
@@ -4615,12 +4593,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
4615
4593
|
|
|
4616
4594
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
4617
4595
|
|
|
4618
|
-
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); }; }
|
|
4619
4597
|
|
|
4620
|
-
function
|
|
4598
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
4621
4599
|
|
|
4622
4600
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
4623
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
|
+
|
|
4624
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); }
|
|
4625
4607
|
|
|
4626
4608
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -4631,14 +4613,12 @@ var SDK_URL = 'https://cdn.embed.ly/player-0.1.0.min.js';
|
|
|
4631
4613
|
var SDK_GLOBAL = 'playerjs';
|
|
4632
4614
|
var MATCH_URL = /streamable\.com\/([a-z0-9]+)$/;
|
|
4633
4615
|
|
|
4634
|
-
var Streamable =
|
|
4635
|
-
/*#__PURE__*/
|
|
4636
|
-
function (_Component) {
|
|
4616
|
+
var Streamable = /*#__PURE__*/function (_Component) {
|
|
4637
4617
|
_inherits(Streamable, _Component);
|
|
4638
4618
|
|
|
4639
|
-
|
|
4640
|
-
var _getPrototypeOf2;
|
|
4619
|
+
var _super = _createSuper(Streamable);
|
|
4641
4620
|
|
|
4621
|
+
function Streamable() {
|
|
4642
4622
|
var _this;
|
|
4643
4623
|
|
|
4644
4624
|
_classCallCheck(this, Streamable);
|
|
@@ -4647,7 +4627,7 @@ function (_Component) {
|
|
|
4647
4627
|
args[_key] = arguments[_key];
|
|
4648
4628
|
}
|
|
4649
4629
|
|
|
4650
|
-
_this =
|
|
4630
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
4651
4631
|
|
|
4652
4632
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
4653
4633
|
|
|
@@ -4767,7 +4747,7 @@ function (_Component) {
|
|
|
4767
4747
|
width: '100%',
|
|
4768
4748
|
height: '100%'
|
|
4769
4749
|
};
|
|
4770
|
-
return _react["default"].createElement("iframe", {
|
|
4750
|
+
return /*#__PURE__*/_react["default"].createElement("iframe", {
|
|
4771
4751
|
ref: this.ref,
|
|
4772
4752
|
src: "https://streamable.com/o/".concat(id),
|
|
4773
4753
|
frameBorder: "0",
|
|
@@ -4828,12 +4808,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
4828
4808
|
|
|
4829
4809
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
4830
4810
|
|
|
4831
|
-
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); }; }
|
|
4832
4812
|
|
|
4833
|
-
function
|
|
4813
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
4834
4814
|
|
|
4835
4815
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
4836
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
|
+
|
|
4837
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); }
|
|
4838
4822
|
|
|
4839
4823
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -4844,26 +4828,48 @@ var SDK_URL = 'https://fast.wistia.com/assets/external/E-v1.js';
|
|
|
4844
4828
|
var SDK_GLOBAL = 'Wistia';
|
|
4845
4829
|
var MATCH_URL = /(?:wistia\.com|wi\.st)\/(?:medias|embed)\/(.*)$/;
|
|
4846
4830
|
|
|
4847
|
-
var Wistia =
|
|
4848
|
-
/*#__PURE__*/
|
|
4849
|
-
function (_Component) {
|
|
4831
|
+
var Wistia = /*#__PURE__*/function (_Component) {
|
|
4850
4832
|
_inherits(Wistia, _Component);
|
|
4851
4833
|
|
|
4852
|
-
|
|
4853
|
-
var _getPrototypeOf2;
|
|
4834
|
+
var _super = _createSuper(Wistia);
|
|
4854
4835
|
|
|
4836
|
+
function Wistia() {
|
|
4855
4837
|
var _this;
|
|
4856
4838
|
|
|
4857
4839
|
_classCallCheck(this, Wistia);
|
|
4858
4840
|
|
|
4859
|
-
for (var _len = arguments.length,
|
|
4860
|
-
|
|
4841
|
+
for (var _len = arguments.length, _args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
4842
|
+
_args[_key] = arguments[_key];
|
|
4861
4843
|
}
|
|
4862
4844
|
|
|
4863
|
-
_this =
|
|
4845
|
+
_this = _super.call.apply(_super, [this].concat(_args));
|
|
4864
4846
|
|
|
4865
4847
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
4866
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
|
+
|
|
4867
4873
|
_defineProperty(_assertThisInitialized(_this), "mute", function () {
|
|
4868
4874
|
_this.callPlayer('mute');
|
|
4869
4875
|
});
|
|
@@ -4885,17 +4891,13 @@ function (_Component) {
|
|
|
4885
4891
|
value: function load(url) {
|
|
4886
4892
|
var _this2 = this;
|
|
4887
4893
|
|
|
4888
|
-
var _this$
|
|
4889
|
-
playing = _this$
|
|
4890
|
-
muted = _this$
|
|
4891
|
-
controls = _this$
|
|
4892
|
-
_onReady = _this$
|
|
4893
|
-
|
|
4894
|
-
|
|
4895
|
-
onSeek = _this$props.onSeek,
|
|
4896
|
-
onEnded = _this$props.onEnded,
|
|
4897
|
-
config = _this$props.config,
|
|
4898
|
-
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;
|
|
4899
4901
|
(0, utils.getSDK)(SDK_URL, SDK_GLOBAL).then(function () {
|
|
4900
4902
|
window._wq = window._wq || [];
|
|
4901
4903
|
|
|
@@ -4912,19 +4914,28 @@ function (_Component) {
|
|
|
4912
4914
|
|
|
4913
4915
|
_this2.unbind();
|
|
4914
4916
|
|
|
4915
|
-
_this2.player.bind('play', onPlay);
|
|
4917
|
+
_this2.player.bind('play', _this2.onPlay);
|
|
4916
4918
|
|
|
4917
|
-
_this2.player.bind('pause', onPause);
|
|
4919
|
+
_this2.player.bind('pause', _this2.onPause);
|
|
4918
4920
|
|
|
4919
|
-
_this2.player.bind('seek', onSeek);
|
|
4921
|
+
_this2.player.bind('seek', _this2.onSeek);
|
|
4920
4922
|
|
|
4921
|
-
_this2.player.bind('end', onEnded);
|
|
4923
|
+
_this2.player.bind('end', _this2.onEnded);
|
|
4922
4924
|
|
|
4923
4925
|
_onReady();
|
|
4924
4926
|
}
|
|
4925
4927
|
});
|
|
4926
4928
|
}, onError);
|
|
4927
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
|
+
|
|
4928
4939
|
}, {
|
|
4929
4940
|
key: "play",
|
|
4930
4941
|
value: function play() {
|
|
@@ -4935,19 +4946,6 @@ function (_Component) {
|
|
|
4935
4946
|
value: function pause() {
|
|
4936
4947
|
this.callPlayer('pause');
|
|
4937
4948
|
}
|
|
4938
|
-
}, {
|
|
4939
|
-
key: "unbind",
|
|
4940
|
-
value: function unbind() {
|
|
4941
|
-
var _this$props2 = this.props,
|
|
4942
|
-
onPlay = _this$props2.onPlay,
|
|
4943
|
-
onPause = _this$props2.onPause,
|
|
4944
|
-
onSeek = _this$props2.onSeek,
|
|
4945
|
-
onEnded = _this$props2.onEnded;
|
|
4946
|
-
this.player.unbind('play', onPlay);
|
|
4947
|
-
this.player.unbind('pause', onPause);
|
|
4948
|
-
this.player.unbind('seek', onSeek);
|
|
4949
|
-
this.player.unbind('end', onEnded);
|
|
4950
|
-
}
|
|
4951
4949
|
}, {
|
|
4952
4950
|
key: "stop",
|
|
4953
4951
|
value: function stop() {
|
|
@@ -4993,7 +4991,7 @@ function (_Component) {
|
|
|
4993
4991
|
width: '100%',
|
|
4994
4992
|
height: '100%'
|
|
4995
4993
|
};
|
|
4996
|
-
return _react["default"].createElement("div", {
|
|
4994
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
4997
4995
|
key: id,
|
|
4998
4996
|
className: className,
|
|
4999
4997
|
style: style
|
|
@@ -5053,12 +5051,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
5053
5051
|
|
|
5054
5052
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
5055
5053
|
|
|
5056
|
-
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); }; }
|
|
5057
5055
|
|
|
5058
|
-
function
|
|
5056
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
5059
5057
|
|
|
5060
5058
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
5061
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
|
+
|
|
5062
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); }
|
|
5063
5065
|
|
|
5064
5066
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -5071,14 +5073,12 @@ var MATCH_VIDEO_URL = /(?:www\.|go\.)?twitch\.tv\/videos\/(\d+)($|\?)/;
|
|
|
5071
5073
|
var MATCH_CHANNEL_URL = /(?:www\.|go\.)?twitch\.tv\/([a-z0-9_]+)($|\?)/;
|
|
5072
5074
|
var PLAYER_ID_PREFIX = 'twitch-player-';
|
|
5073
5075
|
|
|
5074
|
-
var Twitch =
|
|
5075
|
-
/*#__PURE__*/
|
|
5076
|
-
function (_Component) {
|
|
5076
|
+
var Twitch = /*#__PURE__*/function (_Component) {
|
|
5077
5077
|
_inherits(Twitch, _Component);
|
|
5078
5078
|
|
|
5079
|
-
|
|
5080
|
-
var _getPrototypeOf2;
|
|
5079
|
+
var _super = _createSuper(Twitch);
|
|
5081
5080
|
|
|
5081
|
+
function Twitch() {
|
|
5082
5082
|
var _this;
|
|
5083
5083
|
|
|
5084
5084
|
_classCallCheck(this, Twitch);
|
|
@@ -5087,7 +5087,7 @@ function (_Component) {
|
|
|
5087
5087
|
args[_key] = arguments[_key];
|
|
5088
5088
|
}
|
|
5089
5089
|
|
|
5090
|
-
_this =
|
|
5090
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
5091
5091
|
|
|
5092
5092
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
5093
5093
|
|
|
@@ -5208,7 +5208,7 @@ function (_Component) {
|
|
|
5208
5208
|
width: '100%',
|
|
5209
5209
|
height: '100%'
|
|
5210
5210
|
};
|
|
5211
|
-
return _react["default"].createElement("div", {
|
|
5211
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
5212
5212
|
style: style,
|
|
5213
5213
|
id: this.playerID
|
|
5214
5214
|
});
|
|
@@ -5261,11 +5261,15 @@ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (O
|
|
|
5261
5261
|
|
|
5262
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; }
|
|
5263
5263
|
|
|
5264
|
-
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
5265
|
|
|
5266
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); }
|
|
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
5267
|
|
|
5268
|
-
function
|
|
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); }
|
|
5269
|
+
|
|
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; }
|
|
5271
|
+
|
|
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; }
|
|
5269
5273
|
|
|
5270
5274
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
5271
5275
|
|
|
@@ -5275,12 +5279,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
5275
5279
|
|
|
5276
5280
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
5277
5281
|
|
|
5278
|
-
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); }; }
|
|
5279
5283
|
|
|
5280
|
-
function
|
|
5284
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
5281
5285
|
|
|
5282
5286
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
5283
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
|
+
|
|
5284
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); }
|
|
5285
5293
|
|
|
5286
5294
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -5292,14 +5300,12 @@ var SDK_GLOBAL = 'DM';
|
|
|
5292
5300
|
var SDK_GLOBAL_READY = 'dmAsyncInit';
|
|
5293
5301
|
var MATCH_URL = /^(?:(?:https?):)?(?:\/\/)?(?:www\.)?(?:(?:dailymotion\.com(?:\/embed)?\/video)|dai\.ly)\/([a-zA-Z0-9]+)(?:_[\w_-]+)?$/;
|
|
5294
5302
|
|
|
5295
|
-
var DailyMotion =
|
|
5296
|
-
/*#__PURE__*/
|
|
5297
|
-
function (_Component) {
|
|
5303
|
+
var DailyMotion = /*#__PURE__*/function (_Component) {
|
|
5298
5304
|
_inherits(DailyMotion, _Component);
|
|
5299
5305
|
|
|
5300
|
-
|
|
5301
|
-
var _getPrototypeOf2;
|
|
5306
|
+
var _super = _createSuper(DailyMotion);
|
|
5302
5307
|
|
|
5308
|
+
function DailyMotion() {
|
|
5303
5309
|
var _this;
|
|
5304
5310
|
|
|
5305
5311
|
_classCallCheck(this, DailyMotion);
|
|
@@ -5308,7 +5314,7 @@ function (_Component) {
|
|
|
5308
5314
|
args[_key] = arguments[_key];
|
|
5309
5315
|
}
|
|
5310
5316
|
|
|
5311
|
-
_this =
|
|
5317
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
5312
5318
|
|
|
5313
5319
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
5314
5320
|
|
|
@@ -5437,9 +5443,9 @@ function (_Component) {
|
|
|
5437
5443
|
height: '100%',
|
|
5438
5444
|
display: display
|
|
5439
5445
|
};
|
|
5440
|
-
return _react["default"].createElement("div", {
|
|
5446
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
5441
5447
|
style: style
|
|
5442
|
-
}, _react["default"].createElement("div", {
|
|
5448
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
5443
5449
|
ref: this.ref
|
|
5444
5450
|
}));
|
|
5445
5451
|
}
|
|
@@ -5497,12 +5503,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
5497
5503
|
|
|
5498
5504
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
5499
5505
|
|
|
5500
|
-
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); }; }
|
|
5501
5507
|
|
|
5502
|
-
function
|
|
5508
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
5503
5509
|
|
|
5504
5510
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
5505
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
|
+
|
|
5506
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); }
|
|
5507
5517
|
|
|
5508
5518
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -5513,14 +5523,12 @@ var SDK_URL = 'https://widget.mixcloud.com/media/js/widgetApi.js';
|
|
|
5513
5523
|
var SDK_GLOBAL = 'Mixcloud';
|
|
5514
5524
|
var MATCH_URL = /mixcloud\.com\/([^/]+\/[^/]+)/;
|
|
5515
5525
|
|
|
5516
|
-
var Mixcloud =
|
|
5517
|
-
/*#__PURE__*/
|
|
5518
|
-
function (_Component) {
|
|
5526
|
+
var Mixcloud = /*#__PURE__*/function (_Component) {
|
|
5519
5527
|
_inherits(Mixcloud, _Component);
|
|
5520
5528
|
|
|
5521
|
-
|
|
5522
|
-
var _getPrototypeOf2;
|
|
5529
|
+
var _super = _createSuper(Mixcloud);
|
|
5523
5530
|
|
|
5531
|
+
function Mixcloud() {
|
|
5524
5532
|
var _this;
|
|
5525
5533
|
|
|
5526
5534
|
_classCallCheck(this, Mixcloud);
|
|
@@ -5529,7 +5537,7 @@ function (_Component) {
|
|
|
5529
5537
|
args[_key] = arguments[_key];
|
|
5530
5538
|
}
|
|
5531
5539
|
|
|
5532
|
-
_this =
|
|
5540
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
5533
5541
|
|
|
5534
5542
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
5535
5543
|
|
|
@@ -5632,7 +5640,7 @@ function (_Component) {
|
|
|
5632
5640
|
})); // We have to give the iframe a key here to prevent a
|
|
5633
5641
|
// weird dialog appearing when loading a new track
|
|
5634
5642
|
|
|
5635
|
-
return _react["default"].createElement("iframe", {
|
|
5643
|
+
return /*#__PURE__*/_react["default"].createElement("iframe", {
|
|
5636
5644
|
key: id,
|
|
5637
5645
|
ref: this.ref,
|
|
5638
5646
|
style: style,
|
|
@@ -5692,23 +5700,33 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
5692
5700
|
|
|
5693
5701
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
5694
5702
|
|
|
5695
|
-
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); }; }
|
|
5696
5704
|
|
|
5697
|
-
function
|
|
5705
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
5698
5706
|
|
|
5699
5707
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
5700
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
|
+
|
|
5701
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); }
|
|
5702
5714
|
|
|
5703
5715
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
5704
5716
|
|
|
5705
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; }
|
|
5706
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
|
+
|
|
5707
5725
|
var IOS = typeof navigator !== 'undefined' && /iPad|iPhone|iPod/.test(navigator.userAgent) && !window.MSStream;
|
|
5708
5726
|
var AUDIO_EXTENSIONS = /\.(m4a|mp4a|mpga|mp2|mp2a|mp3|m2a|m3a|wav|weba|aac|oga|spx)($|\?)/i;
|
|
5709
5727
|
var VIDEO_EXTENSIONS = /\.(mp4|og[gv]|webm|mov|m4v)($|\?)/i;
|
|
5710
5728
|
var HLS_EXTENSIONS = /\.(m3u8)($|\?)/i;
|
|
5711
|
-
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';
|
|
5712
5730
|
var HLS_GLOBAL = 'Hls';
|
|
5713
5731
|
var DASH_EXTENSIONS = /\.(mpd)($|\?)/i;
|
|
5714
5732
|
var DASH_SDK_URL = 'https://cdnjs.cloudflare.com/ajax/libs/dashjs/VERSION/dash.all.min.js';
|
|
@@ -5717,12 +5735,11 @@ var MATCH_DROPBOX_URL = /www\.dropbox\.com\/.+/;
|
|
|
5717
5735
|
|
|
5718
5736
|
function canPlay(url) {
|
|
5719
5737
|
if (url instanceof Array) {
|
|
5720
|
-
var
|
|
5721
|
-
|
|
5722
|
-
var _iteratorError = undefined;
|
|
5738
|
+
var _iterator = _createForOfIteratorHelper(url),
|
|
5739
|
+
_step;
|
|
5723
5740
|
|
|
5724
5741
|
try {
|
|
5725
|
-
for (
|
|
5742
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
5726
5743
|
var item = _step.value;
|
|
5727
5744
|
|
|
5728
5745
|
if (typeof item === 'string' && canPlay(item)) {
|
|
@@ -5734,18 +5751,9 @@ function canPlay(url) {
|
|
|
5734
5751
|
}
|
|
5735
5752
|
}
|
|
5736
5753
|
} catch (err) {
|
|
5737
|
-
|
|
5738
|
-
_iteratorError = err;
|
|
5754
|
+
_iterator.e(err);
|
|
5739
5755
|
} finally {
|
|
5740
|
-
|
|
5741
|
-
if (!_iteratorNormalCompletion && _iterator["return"] != null) {
|
|
5742
|
-
_iterator["return"]();
|
|
5743
|
-
}
|
|
5744
|
-
} finally {
|
|
5745
|
-
if (_didIteratorError) {
|
|
5746
|
-
throw _iteratorError;
|
|
5747
|
-
}
|
|
5748
|
-
}
|
|
5756
|
+
_iterator.f();
|
|
5749
5757
|
}
|
|
5750
5758
|
|
|
5751
5759
|
return false;
|
|
@@ -5769,14 +5777,12 @@ function canEnablePIP(url) {
|
|
|
5769
5777
|
return canPlay(url) && (!!document.pictureInPictureEnabled || supportsWebKitPresentationMode()) && !AUDIO_EXTENSIONS.test(url);
|
|
5770
5778
|
}
|
|
5771
5779
|
|
|
5772
|
-
var FilePlayer =
|
|
5773
|
-
/*#__PURE__*/
|
|
5774
|
-
function (_Component) {
|
|
5780
|
+
var FilePlayer = /*#__PURE__*/function (_Component) {
|
|
5775
5781
|
_inherits(FilePlayer, _Component);
|
|
5776
5782
|
|
|
5777
|
-
|
|
5778
|
-
var _getPrototypeOf2;
|
|
5783
|
+
var _super = _createSuper(FilePlayer);
|
|
5779
5784
|
|
|
5785
|
+
function FilePlayer() {
|
|
5780
5786
|
var _this;
|
|
5781
5787
|
|
|
5782
5788
|
_classCallCheck(this, FilePlayer);
|
|
@@ -5785,7 +5791,7 @@ function (_Component) {
|
|
|
5785
5791
|
_args[_key] = arguments[_key];
|
|
5786
5792
|
}
|
|
5787
5793
|
|
|
5788
|
-
_this =
|
|
5794
|
+
_this = _super.call.apply(_super, [this].concat(_args));
|
|
5789
5795
|
|
|
5790
5796
|
_defineProperty(_assertThisInitialized(_this), "onReady", function () {
|
|
5791
5797
|
var _this$props;
|
|
@@ -5872,19 +5878,19 @@ function (_Component) {
|
|
|
5872
5878
|
|
|
5873
5879
|
_defineProperty(_assertThisInitialized(_this), "renderSourceElement", function (source, index) {
|
|
5874
5880
|
if (typeof source === 'string') {
|
|
5875
|
-
return _react["default"].createElement("source", {
|
|
5881
|
+
return /*#__PURE__*/_react["default"].createElement("source", {
|
|
5876
5882
|
key: index,
|
|
5877
5883
|
src: source
|
|
5878
5884
|
});
|
|
5879
5885
|
}
|
|
5880
5886
|
|
|
5881
|
-
return _react["default"].createElement("source", _extends({
|
|
5887
|
+
return /*#__PURE__*/_react["default"].createElement("source", _extends({
|
|
5882
5888
|
key: index
|
|
5883
5889
|
}, source));
|
|
5884
5890
|
});
|
|
5885
5891
|
|
|
5886
5892
|
_defineProperty(_assertThisInitialized(_this), "renderTrack", function (track, index) {
|
|
5887
|
-
return _react["default"].createElement("track", _extends({
|
|
5893
|
+
return /*#__PURE__*/_react["default"].createElement("track", _extends({
|
|
5888
5894
|
key: index
|
|
5889
5895
|
}, track));
|
|
5890
5896
|
});
|
|
@@ -5922,6 +5928,10 @@ function (_Component) {
|
|
|
5922
5928
|
key: "componentWillUnmount",
|
|
5923
5929
|
value: function componentWillUnmount() {
|
|
5924
5930
|
this.removeListeners(this.player);
|
|
5931
|
+
|
|
5932
|
+
if (this.hls) {
|
|
5933
|
+
this.hls.destroy();
|
|
5934
|
+
}
|
|
5925
5935
|
}
|
|
5926
5936
|
}, {
|
|
5927
5937
|
key: "addListeners",
|
|
@@ -6052,10 +6062,6 @@ function (_Component) {
|
|
|
6052
6062
|
value: function stop() {
|
|
6053
6063
|
this.player.removeAttribute('src');
|
|
6054
6064
|
|
|
6055
|
-
if (this.hls) {
|
|
6056
|
-
this.hls.destroy();
|
|
6057
|
-
}
|
|
6058
|
-
|
|
6059
6065
|
if (this.dash) {
|
|
6060
6066
|
this.dash.reset();
|
|
6061
6067
|
}
|
|
@@ -6167,7 +6173,7 @@ function (_Component) {
|
|
|
6167
6173
|
width: width === 'auto' ? width : '100%',
|
|
6168
6174
|
height: height === 'auto' ? height : '100%'
|
|
6169
6175
|
};
|
|
6170
|
-
return _react["default"].createElement(Element, _extends({
|
|
6176
|
+
return /*#__PURE__*/_react["default"].createElement(Element, _extends({
|
|
6171
6177
|
ref: this.ref,
|
|
6172
6178
|
src: this.getSource(url),
|
|
6173
6179
|
style: style,
|
|
@@ -6257,12 +6263,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
6257
6263
|
|
|
6258
6264
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
6259
6265
|
|
|
6260
|
-
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); }; }
|
|
6261
6267
|
|
|
6262
|
-
function
|
|
6268
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
6263
6269
|
|
|
6264
6270
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
6265
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
|
+
|
|
6266
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); }
|
|
6267
6277
|
|
|
6268
6278
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -6271,14 +6281,12 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
6271
6281
|
|
|
6272
6282
|
var ICON_SIZE = '64px';
|
|
6273
6283
|
|
|
6274
|
-
var Preview =
|
|
6275
|
-
/*#__PURE__*/
|
|
6276
|
-
function (_Component) {
|
|
6284
|
+
var Preview = /*#__PURE__*/function (_Component) {
|
|
6277
6285
|
_inherits(Preview, _Component);
|
|
6278
6286
|
|
|
6279
|
-
|
|
6280
|
-
var _getPrototypeOf2;
|
|
6287
|
+
var _super = _createSuper(Preview);
|
|
6281
6288
|
|
|
6289
|
+
function Preview() {
|
|
6282
6290
|
var _this;
|
|
6283
6291
|
|
|
6284
6292
|
_classCallCheck(this, Preview);
|
|
@@ -6287,7 +6295,7 @@ function (_Component) {
|
|
|
6287
6295
|
args[_key] = arguments[_key];
|
|
6288
6296
|
}
|
|
6289
6297
|
|
|
6290
|
-
_this =
|
|
6298
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
6291
6299
|
|
|
6292
6300
|
_defineProperty(_assertThisInitialized(_this), "mounted", false);
|
|
6293
6301
|
|
|
@@ -6385,15 +6393,15 @@ function (_Component) {
|
|
|
6385
6393
|
}
|
|
6386
6394
|
};
|
|
6387
6395
|
|
|
6388
|
-
var defaultPlayIcon = _react["default"].createElement("div", {
|
|
6396
|
+
var defaultPlayIcon = /*#__PURE__*/_react["default"].createElement("div", {
|
|
6389
6397
|
style: styles.shadow,
|
|
6390
6398
|
className: "react-player__shadow"
|
|
6391
|
-
}, _react["default"].createElement("div", {
|
|
6399
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
6392
6400
|
style: styles.playIcon,
|
|
6393
6401
|
className: "react-player__play-icon"
|
|
6394
6402
|
}));
|
|
6395
6403
|
|
|
6396
|
-
return _react["default"].createElement("div", {
|
|
6404
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
6397
6405
|
style: styles.preview,
|
|
6398
6406
|
className: "react-player__preview",
|
|
6399
6407
|
onClick: onClick
|
|
@@ -6430,6 +6438,12 @@ var _Player = _interopRequireDefault(Player_1);
|
|
|
6430
6438
|
|
|
6431
6439
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
6432
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
|
+
|
|
6433
6447
|
var PRELOAD_PLAYERS = [{
|
|
6434
6448
|
Player: YouTube_1.YouTube,
|
|
6435
6449
|
configKey: 'youtube',
|
|
@@ -6450,16 +6464,16 @@ var PRELOAD_PLAYERS = [{
|
|
|
6450
6464
|
|
|
6451
6465
|
function renderPreloadPlayers(url, controls, config) {
|
|
6452
6466
|
var players = [];
|
|
6453
|
-
|
|
6454
|
-
var
|
|
6455
|
-
|
|
6467
|
+
|
|
6468
|
+
var _iterator = _createForOfIteratorHelper(PRELOAD_PLAYERS),
|
|
6469
|
+
_step;
|
|
6456
6470
|
|
|
6457
6471
|
try {
|
|
6458
|
-
for (
|
|
6472
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
6459
6473
|
var player = _step.value;
|
|
6460
6474
|
|
|
6461
6475
|
if (!player.Player.canPlay(url) && config[player.configKey].preload) {
|
|
6462
|
-
players.push(_react["default"].createElement(_Player["default"], {
|
|
6476
|
+
players.push( /*#__PURE__*/_react["default"].createElement(_Player["default"], {
|
|
6463
6477
|
key: player.Player.displayName,
|
|
6464
6478
|
activePlayer: player.Player,
|
|
6465
6479
|
url: player.url,
|
|
@@ -6471,18 +6485,9 @@ function renderPreloadPlayers(url, controls, config) {
|
|
|
6471
6485
|
}
|
|
6472
6486
|
}
|
|
6473
6487
|
} catch (err) {
|
|
6474
|
-
|
|
6475
|
-
_iteratorError = err;
|
|
6488
|
+
_iterator.e(err);
|
|
6476
6489
|
} finally {
|
|
6477
|
-
|
|
6478
|
-
if (!_iteratorNormalCompletion && _iterator["return"] != null) {
|
|
6479
|
-
_iterator["return"]();
|
|
6480
|
-
}
|
|
6481
|
-
} finally {
|
|
6482
|
-
if (_didIteratorError) {
|
|
6483
|
-
throw _iteratorError;
|
|
6484
|
-
}
|
|
6485
|
-
}
|
|
6490
|
+
_iterator.f();
|
|
6486
6491
|
}
|
|
6487
6492
|
|
|
6488
6493
|
return players;
|
|
@@ -6606,13 +6611,17 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
|
|
|
6606
6611
|
|
|
6607
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); }
|
|
6608
6613
|
|
|
6609
|
-
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); }
|
|
6610
6619
|
|
|
6611
|
-
function
|
|
6620
|
+
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && Symbol.iterator in Object(iter)) return Array.from(iter); }
|
|
6612
6621
|
|
|
6613
|
-
function
|
|
6622
|
+
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
6614
6623
|
|
|
6615
|
-
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; }
|
|
6616
6625
|
|
|
6617
6626
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
6618
6627
|
|
|
@@ -6620,12 +6629,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
6620
6629
|
|
|
6621
6630
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
6622
6631
|
|
|
6623
|
-
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); }; }
|
|
6624
6633
|
|
|
6625
|
-
function
|
|
6634
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
6626
6635
|
|
|
6627
6636
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
6628
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
|
+
|
|
6629
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); }
|
|
6630
6643
|
|
|
6631
6644
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -6635,14 +6648,12 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
6635
6648
|
var SUPPORTED_PROPS = Object.keys(props.propTypes);
|
|
6636
6649
|
var customPlayers = [];
|
|
6637
6650
|
|
|
6638
|
-
var ReactPlayer =
|
|
6639
|
-
/*#__PURE__*/
|
|
6640
|
-
function (_Component) {
|
|
6651
|
+
var ReactPlayer = /*#__PURE__*/function (_Component) {
|
|
6641
6652
|
_inherits(ReactPlayer, _Component);
|
|
6642
6653
|
|
|
6643
|
-
|
|
6644
|
-
var _getPrototypeOf2;
|
|
6654
|
+
var _super = _createSuper(ReactPlayer);
|
|
6645
6655
|
|
|
6656
|
+
function ReactPlayer() {
|
|
6646
6657
|
var _this;
|
|
6647
6658
|
|
|
6648
6659
|
_classCallCheck(this, ReactPlayer);
|
|
@@ -6651,7 +6662,7 @@ function (_Component) {
|
|
|
6651
6662
|
args[_key] = arguments[_key];
|
|
6652
6663
|
}
|
|
6653
6664
|
|
|
6654
|
-
_this =
|
|
6665
|
+
_this = _super.call.apply(_super, [this].concat(args));
|
|
6655
6666
|
|
|
6656
6667
|
_defineProperty(_assertThisInitialized(_this), "config", (0, utils.getConfig)(_this.props, props.defaultProps, true));
|
|
6657
6668
|
|
|
@@ -6762,7 +6773,7 @@ function (_Component) {
|
|
|
6762
6773
|
key: "renderActivePlayer",
|
|
6763
6774
|
value: function renderActivePlayer(url, activePlayer) {
|
|
6764
6775
|
if (!url) return null;
|
|
6765
|
-
return _react["default"].createElement(_Player4["default"], _extends({}, this.props, {
|
|
6776
|
+
return /*#__PURE__*/_react["default"].createElement(_Player4["default"], _extends({}, this.props, {
|
|
6766
6777
|
key: activePlayer.displayName,
|
|
6767
6778
|
ref: this.activePlayerRef,
|
|
6768
6779
|
config: this.config,
|
|
@@ -6799,14 +6810,14 @@ function (_Component) {
|
|
|
6799
6810
|
var preloadPlayers = (0, _preload["default"])(url, controls, this.config);
|
|
6800
6811
|
var players = [renderedActivePlayer].concat(_toConsumableArray(preloadPlayers)).sort(this.sortPlayers);
|
|
6801
6812
|
|
|
6802
|
-
var preview = _react["default"].createElement(_Preview["default"], {
|
|
6813
|
+
var preview = /*#__PURE__*/_react["default"].createElement(_Preview["default"], {
|
|
6803
6814
|
url: url,
|
|
6804
6815
|
light: light,
|
|
6805
6816
|
playIcon: playIcon,
|
|
6806
6817
|
onClick: this.handleClickPreview
|
|
6807
6818
|
});
|
|
6808
6819
|
|
|
6809
|
-
return _react["default"].createElement(Wrapper, _extends({
|
|
6820
|
+
return /*#__PURE__*/_react["default"].createElement(Wrapper, _extends({
|
|
6810
6821
|
ref: this.wrapperRef,
|
|
6811
6822
|
style: _objectSpread({}, style, {
|
|
6812
6823
|
width: width,
|
|
@@ -7354,7 +7365,7 @@ var YouTubeGallery = function YouTubeGallery(_ref) {
|
|
|
7354
7365
|
{ className: 'mb-3' },
|
|
7355
7366
|
nodes.videos[series - 1].title
|
|
7356
7367
|
),
|
|
7357
|
-
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()))
|
|
7358
7369
|
),
|
|
7359
7370
|
React__default.createElement(
|
|
7360
7371
|
'style',
|
|
@@ -7482,7 +7493,7 @@ var Poll = function Poll(_ref) {
|
|
|
7482
7493
|
);
|
|
7483
7494
|
};
|
|
7484
7495
|
|
|
7485
|
-
var numberOfPaginations = main.
|
|
7496
|
+
var numberOfPaginations = main.main_38 ? 4 : 10;
|
|
7486
7497
|
|
|
7487
7498
|
var Quiz = function Quiz(_ref) {
|
|
7488
7499
|
var quizzes = _ref.quizzes,
|
|
@@ -7595,7 +7606,7 @@ var Quiz = function Quiz(_ref) {
|
|
|
7595
7606
|
var renderPagination = function renderPagination() {
|
|
7596
7607
|
return React__default.createElement(
|
|
7597
7608
|
Pagination,
|
|
7598
|
-
{ className: 'p-0 m-0', size: main.
|
|
7609
|
+
{ className: 'p-0 m-0', size: main.main_38 && 'sm' },
|
|
7599
7610
|
React__default.createElement(Pagination.First, { onClick: function onClick() {
|
|
7600
7611
|
return changePage('first');
|
|
7601
7612
|
}, disabled: currentPage === 1 }),
|
|
@@ -7772,6 +7783,145 @@ var urlFor$2 = function urlFor(source, client) {
|
|
|
7772
7783
|
return builder.image(source).auto('format');
|
|
7773
7784
|
};
|
|
7774
7785
|
|
|
7786
|
+
var compareProps = function compareProps(prevProps, nextProps) {
|
|
7787
|
+
if (nextProps.node.asset && nextProps.node.asset._ref) {
|
|
7788
|
+
return prevProps.node.asset._ref === nextProps.node.asset._ref;
|
|
7789
|
+
}
|
|
7790
|
+
};
|
|
7791
|
+
|
|
7792
|
+
var FigureComponent = function FigureComponent(props) {
|
|
7793
|
+
var _useState = React.useState(false),
|
|
7794
|
+
_useState2 = slicedToArray._slicedToArray(_useState, 2),
|
|
7795
|
+
openImg = _useState2[0],
|
|
7796
|
+
setOpenImg = _useState2[1];
|
|
7797
|
+
|
|
7798
|
+
var _useState3 = React.useState(''),
|
|
7799
|
+
_useState4 = slicedToArray._slicedToArray(_useState3, 2),
|
|
7800
|
+
openImgSrc = _useState4[0],
|
|
7801
|
+
setOpenImgSrc = _useState4[1];
|
|
7802
|
+
|
|
7803
|
+
if (typeof window === 'undefined') return null;
|
|
7804
|
+
|
|
7805
|
+
var node = props.node,
|
|
7806
|
+
client = props.client;
|
|
7807
|
+
|
|
7808
|
+
|
|
7809
|
+
if (!node.asset) return null;
|
|
7810
|
+
|
|
7811
|
+
var caption = node.caption,
|
|
7812
|
+
alt = node.alt,
|
|
7813
|
+
blank = node.blank,
|
|
7814
|
+
link = node.link,
|
|
7815
|
+
_node$alignment = node.alignment,
|
|
7816
|
+
alignment = _node$alignment === undefined ? 'center' : _node$alignment,
|
|
7817
|
+
_node$class_name = node.class_name,
|
|
7818
|
+
class_name = _node$class_name === undefined ? 'd-block' : _node$class_name,
|
|
7819
|
+
_node$disableTextWrap = node.disableTextWrap,
|
|
7820
|
+
disableTextWrap = _node$disableTextWrap === undefined ? false : _node$disableTextWrap;
|
|
7821
|
+
var _node$widthP = node.widthP,
|
|
7822
|
+
widthP = _node$widthP === undefined ? 'auto' : _node$widthP;
|
|
7823
|
+
|
|
7824
|
+
|
|
7825
|
+
var screenWidth = window.innerWidth;
|
|
7826
|
+
|
|
7827
|
+
if (client.clientConfig && client.clientConfig.defaultImageSize && widthP === 'auto') {
|
|
7828
|
+
widthP = client.clientConfig.defaultImageSize;
|
|
7829
|
+
}
|
|
7830
|
+
|
|
7831
|
+
var imageFloat = 'none';
|
|
7832
|
+
if (screenWidth > 1000) {
|
|
7833
|
+
var align = ['center', 'top'].includes(alignment.toLowerCase()) ? 'none' : alignment.toLowerCase();
|
|
7834
|
+
imageFloat = align;
|
|
7835
|
+
}
|
|
7836
|
+
|
|
7837
|
+
var figureMargin = null;
|
|
7838
|
+
if (imageFloat === 'none') {
|
|
7839
|
+
figureMargin = '0 auto 1rem';
|
|
7840
|
+
}
|
|
7841
|
+
if (imageFloat === 'left') {
|
|
7842
|
+
figureMargin = '0 1.5rem 1.5rem 0';
|
|
7843
|
+
}
|
|
7844
|
+
if (imageFloat === 'right') {
|
|
7845
|
+
figureMargin = '0 0 1.5rem 1.5rem';
|
|
7846
|
+
}
|
|
7847
|
+
|
|
7848
|
+
var imageWidth = null;
|
|
7849
|
+
if (screenWidth > 1000) {
|
|
7850
|
+
if (widthP === 'auto') {
|
|
7851
|
+
if (imageFloat === 'none') {
|
|
7852
|
+
imageWidth = 'auto';
|
|
7853
|
+
} else {
|
|
7854
|
+
imageWidth = '30%';
|
|
7855
|
+
}
|
|
7856
|
+
} else {
|
|
7857
|
+
imageWidth = widthP + '%';
|
|
7858
|
+
}
|
|
7859
|
+
} else {
|
|
7860
|
+
imageWidth = '100%';
|
|
7861
|
+
}
|
|
7862
|
+
|
|
7863
|
+
var figureStyle = disableTextWrap ? { maxWidth: '100%', width: imageWidth, margin: imageFloat !== 'none' ? imageFloat === 'left' ? '' : '0 0 0 auto' : '' } : {
|
|
7864
|
+
width: imageWidth,
|
|
7865
|
+
maxWidth: '100%',
|
|
7866
|
+
clear: 'both',
|
|
7867
|
+
float: imageFloat,
|
|
7868
|
+
margin: figureMargin
|
|
7869
|
+
};
|
|
7870
|
+
|
|
7871
|
+
return React__default.createElement(
|
|
7872
|
+
React__default.Fragment,
|
|
7873
|
+
null,
|
|
7874
|
+
React__default.createElement(
|
|
7875
|
+
reactBootstrap.Figure,
|
|
7876
|
+
{ className: '' + class_name, style: figureStyle },
|
|
7877
|
+
link ? React__default.createElement(
|
|
7878
|
+
'a',
|
|
7879
|
+
{ target: blank ? '_blank' : '_self', href: link },
|
|
7880
|
+
React__default.createElement(reactBootstrap.Figure.Image, { style: { maxWidth: '100%' }, className: 'figure-image', src: urlFor$2(node, client).url(), alt: alt && alt }),
|
|
7881
|
+
caption && React__default.createElement('div', { dangerouslySetInnerHTML: { __html: '<span class=\'figure-caption\'>' + caption + '</span>' } })
|
|
7882
|
+
) : React__default.createElement(
|
|
7883
|
+
React__default.Fragment,
|
|
7884
|
+
null,
|
|
7885
|
+
React__default.createElement(reactBootstrap.Figure.Image, {
|
|
7886
|
+
style: { maxWidth: '100%', cursor: 'pointer', width: 'auto' },
|
|
7887
|
+
className: 'figure-image',
|
|
7888
|
+
src: urlFor$2(node, client).url(),
|
|
7889
|
+
alt: alt && alt,
|
|
7890
|
+
onClick: function onClick() {
|
|
7891
|
+
setOpenImgSrc(urlFor$2(node, client).url());
|
|
7892
|
+
setOpenImg(true);
|
|
7893
|
+
}
|
|
7894
|
+
}),
|
|
7895
|
+
caption && React__default.createElement('div', { dangerouslySetInnerHTML: { __html: '<span class=\'figure-caption\'>' + caption + '</span>' } })
|
|
7896
|
+
)
|
|
7897
|
+
),
|
|
7898
|
+
React__default.createElement(
|
|
7899
|
+
'div',
|
|
7900
|
+
{ className: 'lightbox-target ' + (openImg ? 'open' : 'close') },
|
|
7901
|
+
React__default.createElement('img', { src: openImgSrc }),
|
|
7902
|
+
React__default.createElement('a', {
|
|
7903
|
+
className: 'lightbox-close',
|
|
7904
|
+
onClick: function onClick() {
|
|
7905
|
+
setOpenImgSrc('');
|
|
7906
|
+
setOpenImg(false);
|
|
7907
|
+
}
|
|
7908
|
+
})
|
|
7909
|
+
),
|
|
7910
|
+
React__default.createElement(
|
|
7911
|
+
'style',
|
|
7912
|
+
{ jsx: 'true' },
|
|
7913
|
+
'\n figure-caption {\n font-size: 90%;\n color: #6c757d;\n }\n /*Eliminates padding, centers the thumbnail */\n\n /* Styles the lightbox, removes it from sight and adds the fade-in transition */\n\n .lightbox-target {\n position: fixed;\n top: -100%;\n width: 100%;\n background: rgba(0, 0, 0, 0.7);\n width: 100%;\n opacity: 0;\n -webkit-transition: opacity 0.5s ease-in-out;\n -moz-transition: opacity 0.5s ease-in-out;\n -o-transition: opacity 0.5s ease-in-out;\n transition: opacity 0.5s ease-in-out;\n overflow: hidden;\n }\n\n .lightbox-target.close {\n opacity: 0;\n }\n\n /* Styles the lightbox image, centers it vertically and horizontally, adds the zoom-in transition and makes it responsive using a combination of margin and absolute positioning */\n\n .lightbox-target img {\n margin: auto;\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n max-height: 0%;\n max-width: 0%;\n border: 3px solid white;\n box-shadow: 0px 0px 8px rgba(0, 0, 0, 0.3);\n box-sizing: border-box;\n -webkit-transition: 0.5s ease-in-out;\n -moz-transition: 0.5s ease-in-out;\n -o-transition: 0.5s ease-in-out;\n transition: 0.5s ease-in-out;\n }\n\n /* Styles the close link, adds the slide down transition */\n\n a.lightbox-close {\n display: block;\n width: 50px;\n height: 50px;\n box-sizing: border-box;\n background: white;\n color: black;\n text-decoration: none;\n position: absolute;\n top: -80px;\n right: 0;\n -webkit-transition: 0.5s ease-in-out;\n -moz-transition: 0.5s ease-in-out;\n -o-transition: 0.5s ease-in-out;\n transition: 0.5s ease-in-out;\n }\n\n /* Provides part of the "X" to eliminate an image from the close link */\n\n a.lightbox-close:before {\n content: \'\';\n display: block;\n height: 30px;\n width: 1px;\n background: black;\n position: absolute;\n left: 26px;\n top: 10px;\n -webkit-transform: rotate(45deg);\n -moz-transform: rotate(45deg);\n -o-transform: rotate(45deg);\n transform: rotate(45deg);\n }\n\n /* Provides part of the "X" to eliminate an image from the close link */\n\n a.lightbox-close:after {\n content: \'\';\n display: block;\n height: 30px;\n width: 1px;\n background: black;\n position: absolute;\n left: 26px;\n top: 10px;\n -webkit-transform: rotate(-45deg);\n -moz-transform: rotate(-45deg);\n -o-transform: rotate(-45deg);\n transform: rotate(-45deg);\n }\n\n /* Uses the :target pseudo-class to perform the animations upon clicking the .lightbox-target anchor */\n\n .lightbox-target.open {\n opacity: 1;\n top: 0;\n bottom: 0;\n right: 0;\n z-index: 99999;\n }\n\n .lightbox-target.open img {\n max-height: 100%;\n max-width: 100%;\n }\n\n .lightbox-target.open a.lightbox-close {\n top: 0px;\n }\n '
|
|
7914
|
+
)
|
|
7915
|
+
);
|
|
7916
|
+
};
|
|
7917
|
+
|
|
7918
|
+
var Figure = React__default.memo(FigureComponent, compareProps);
|
|
7919
|
+
|
|
7920
|
+
var urlFor$3 = function urlFor(source, client) {
|
|
7921
|
+
var builder = index$1.imageUrlBuilder(client);
|
|
7922
|
+
return builder.image(source).auto('format');
|
|
7923
|
+
};
|
|
7924
|
+
|
|
7775
7925
|
var MultiFigure = function MultiFigure(props) {
|
|
7776
7926
|
var images = props.node.images,
|
|
7777
7927
|
client = props.client;
|
|
@@ -7790,11 +7940,11 @@ var MultiFigure = function MultiFigure(props) {
|
|
|
7790
7940
|
{ xs: 12, md: 12 / images.length, key: index },
|
|
7791
7941
|
React__default.createElement(
|
|
7792
7942
|
'a',
|
|
7793
|
-
_extends
|
|
7943
|
+
_extends._extends({}, image.link && { href: image.link, target: image.blank ? '_blank' : '_self' }, { style: { cursor: image.link ? 'pointer' : 'default' } }),
|
|
7794
7944
|
React__default.createElement(
|
|
7795
7945
|
'div',
|
|
7796
7946
|
{ className: 'multi-figure-image-container' },
|
|
7797
|
-
React__default.createElement('img', { 'images-count': images.length, className: 'multi-figure-image', src: urlFor$
|
|
7947
|
+
React__default.createElement('img', { 'images-count': images.length, className: 'multi-figure-image', src: urlFor$3(image.asset, client).url(), alt: image.alt }),
|
|
7798
7948
|
image.caption && React__default.createElement(
|
|
7799
7949
|
'span',
|
|
7800
7950
|
{ className: 'multi-figure-caption' },
|
|
@@ -7834,10 +7984,6 @@ var AnchorLinkElement = function AnchorLinkElement(props) {
|
|
|
7834
7984
|
);
|
|
7835
7985
|
};
|
|
7836
7986
|
|
|
7837
|
-
var Figure = dynamic(function () {
|
|
7838
|
-
return Promise.resolve().then(function () { return require('./Figure-eeac313a.js'); });
|
|
7839
|
-
}, { ssr: false });
|
|
7840
|
-
|
|
7841
7987
|
var ScrollToElement = function ScrollToElement(elementId) {
|
|
7842
7988
|
var element = document.getElementById(elementId);
|
|
7843
7989
|
if (element) {
|