@mjhls/mjh-framework 1.0.249 → 1.0.251

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.
Files changed (42) hide show
  1. package/README.md +171 -171
  2. package/dist/cjs/{AdSlot-a79ba074.js → AdSlot-9f3af35d.js} +30 -21
  3. package/dist/cjs/DeckContent.js +10 -10
  4. package/dist/cjs/DeckQueue.js +1 -1
  5. package/dist/cjs/{GridContent-e6c8fb75.js → GridContent-007573a0.js} +3 -3
  6. package/dist/cjs/GridContent.js +3 -3
  7. package/dist/cjs/IssueContentDeck.js +1 -1
  8. package/dist/cjs/IssueDeck.js +1 -1
  9. package/dist/cjs/MasterDeck.js +9 -9
  10. package/dist/cjs/{Normal-2ee1925d.js → Normal-503df349.js} +30 -30
  11. package/dist/cjs/PublicationDeck.js +1 -1
  12. package/dist/cjs/QueueDeckExpanded.js +1 -1
  13. package/dist/cjs/{TaxonomyCard-b5074d6e.js → TaxonomyCard-e3566492.js} +1 -1
  14. package/dist/cjs/TaxonomyCard.js +2 -2
  15. package/dist/cjs/TemplateNormal.js +2 -2
  16. package/dist/cjs/ThumbnailCard.js +1 -1
  17. package/dist/cjs/VideoSeriesListing.js +1 -1
  18. package/dist/cjs/{YoutubeGroup-fd44f8a0.js → YoutubeGroup-5f480446.js} +4 -4
  19. package/dist/cjs/YoutubeGroup.js +1 -1
  20. package/dist/cjs/{index-39beccb3.js → index-be0c82be.js} +1 -2
  21. package/dist/cjs/index.js +787 -613
  22. package/dist/esm/{AdSlot-fb853576.js → AdSlot-0f82b407.js} +30 -21
  23. package/dist/esm/DeckContent.js +10 -10
  24. package/dist/esm/DeckQueue.js +1 -1
  25. package/dist/esm/{GridContent-3711b837.js → GridContent-9e96754b.js} +2 -2
  26. package/dist/esm/GridContent.js +3 -3
  27. package/dist/esm/IssueContentDeck.js +1 -1
  28. package/dist/esm/IssueDeck.js +1 -1
  29. package/dist/esm/MasterDeck.js +9 -9
  30. package/dist/esm/{Normal-b0b212a3.js → Normal-dfda02dc.js} +30 -30
  31. package/dist/esm/PublicationDeck.js +1 -1
  32. package/dist/esm/QueueDeckExpanded.js +1 -1
  33. package/dist/esm/{TaxonomyCard-ee1a22ae.js → TaxonomyCard-2d0ab635.js} +1 -1
  34. package/dist/esm/TaxonomyCard.js +2 -2
  35. package/dist/esm/TemplateNormal.js +2 -2
  36. package/dist/esm/ThumbnailCard.js +1 -1
  37. package/dist/esm/VideoSeriesListing.js +1 -1
  38. package/dist/esm/{YoutubeGroup-1b3eca73.js → YoutubeGroup-78d93d44.js} +4 -4
  39. package/dist/esm/YoutubeGroup.js +1 -1
  40. package/dist/esm/{index-3849e3fe.js → index-73819142.js} +1 -2
  41. package/dist/esm/index.js +789 -618
  42. package/package.json +102 -102
package/dist/cjs/index.js CHANGED
@@ -26,21 +26,21 @@ var Link = _interopDefault(require('next/link'));
26
26
  var Router = require('next/router');
27
27
  var Router__default = _interopDefault(Router);
28
28
  require('react-dom');
29
- var index$1 = require('./index-39beccb3.js');
29
+ var index$1 = require('./index-be0c82be.js');
30
30
  require('./index-fa0fb52c.js');
31
31
  var entities = require('./entities-310b46ee.js');
32
32
  var slicedToArray = require('./slicedToArray-e38fb29d.js');
33
- var AdSlot = require('./AdSlot-a79ba074.js');
33
+ var AdSlot = require('./AdSlot-9f3af35d.js');
34
34
  require('./promise-b96c61f8.js');
35
35
  var DeckContent = require('./DeckContent.js');
36
36
  require('./get-1f91592f.js');
37
- var GridContent = require('./GridContent-e6c8fb75.js');
37
+ var GridContent = require('./GridContent-007573a0.js');
38
38
  var DeckQueue = require('./DeckQueue.js');
39
39
  require('react-bootstrap/Media');
40
40
  var ThumbnailCard = require('./ThumbnailCard.js');
41
- var TaxonomyCard = require('./TaxonomyCard-b5074d6e.js');
41
+ var TaxonomyCard = require('./TaxonomyCard-e3566492.js');
42
42
  var GroupDeck = require('./GroupDeck.js');
43
- var YoutubeGroup = require('./YoutubeGroup-fd44f8a0.js');
43
+ var YoutubeGroup = require('./YoutubeGroup-5f480446.js');
44
44
  var reactBootstrap = require('react-bootstrap');
45
45
  var QueueDeckExpanded = require('./QueueDeckExpanded.js');
46
46
  var index_esm = require('./index.esm-340d3792.js');
@@ -52,7 +52,7 @@ var IssueDeck = require('./IssueDeck.js');
52
52
  require('react-bootstrap/Badge');
53
53
  var IssueContentDeck = require('./IssueContentDeck.js');
54
54
  var Spinner = _interopDefault(require('react-bootstrap/Spinner'));
55
- var TemplateNormal = require('./Normal-2ee1925d.js');
55
+ var TemplateNormal = require('./Normal-503df349.js');
56
56
  require('react-bootstrap/ListGroup');
57
57
  var Head = _interopDefault(require('next/head'));
58
58
  var Accordion = _interopDefault(require('react-bootstrap/Accordion'));
@@ -63,6 +63,7 @@ require('react-bootstrap/Navbar');
63
63
  require('react-bootstrap/NavDropdown');
64
64
  require('react-bootstrap/Form');
65
65
  require('react-bootstrap/FormControl');
66
+ var Modal = _interopDefault(require('react-bootstrap/Modal'));
66
67
  var Pagination = _interopDefault(require('react-bootstrap/Pagination'));
67
68
  var Carousel = _interopDefault(require('react-bootstrap/Carousel'));
68
69
  var Breadcrumb = _interopDefault(require('react-bootstrap/Breadcrumb'));
@@ -2839,6 +2840,210 @@ var AdSlotsProvider = function AdSlotsProvider(_ref) {
2839
2840
  );
2840
2841
  };
2841
2842
 
2843
+ var ADFloatingFooter = function ADFloatingFooter(_ref) {
2844
+ var title = _ref.title,
2845
+ floatingAd = _ref.floatingAd,
2846
+ minScreenWidth = _ref.minScreenWidth;
2847
+ var className = floatingAd.className,
2848
+ slotId = floatingAd.slotId,
2849
+ adUnit = floatingAd.adUnit,
2850
+ _floatingAd$targeting = floatingAd.targeting,
2851
+ targeting = _floatingAd$targeting === undefined ? {} : _floatingAd$targeting,
2852
+ position = floatingAd.position,
2853
+ networkID = floatingAd.networkID,
2854
+ sizes = floatingAd.sizes;
2855
+
2856
+ var _useState = React.useState(false),
2857
+ _useState2 = slicedToArray._slicedToArray(_useState, 2),
2858
+ showAd = _useState2[0],
2859
+ setShowAd = _useState2[1];
2860
+
2861
+ var adTargeting = void 0;
2862
+ if (position && position.length > 0) {
2863
+ adTargeting = {
2864
+ content_placement: targeting.content_placement,
2865
+ document_url: targeting.document_url,
2866
+ pos: [position]
2867
+ };
2868
+ }
2869
+
2870
+ React.useEffect(function () {
2871
+ if (window && window.innerWidth >= minScreenWidth) {
2872
+ setShowAd(true);
2873
+ }
2874
+ }, [minScreenWidth]);
2875
+
2876
+ return React__default.createElement(
2877
+ React__default.Fragment,
2878
+ null,
2879
+ showAd && React__default.createElement(
2880
+ 'div',
2881
+ { className: 'floating-ad-wrapper ' + title },
2882
+ React__default.createElement(AdSlot.DFPAdSlot, { className: className, slotId: slotId, networkID: networkID, sizes: sizes, adUnit: adUnit, targeting: adTargeting, refreshFlag: false }),
2883
+ React__default.createElement(
2884
+ 'div',
2885
+ { className: 'closeButton', onClick: function onClick() {
2886
+ return setShowAd(false);
2887
+ } },
2888
+ 'x'
2889
+ )
2890
+ ),
2891
+ React__default.createElement(
2892
+ 'style',
2893
+ { jsx: 'true' },
2894
+ '\n .floating-ad-wrapper {\n width: auto;\n margin: 0;\n background-color: #f5f5f5;\n position: fixed;\n bottom: 0;\n left: 50%;\n transform: translateX(-50%);\n z-index: 9000;\n }\n .closeButton {\n position: absolute;\n top: -10px;\n right: -10px;\n background: grey;\n color: white;\n font-weight: 500;\n border: 2px solid white;\n border-radius: 50%;\n width: 30px;\n height: 30px;\n text-align: center;\n font-size: 17px;\n cursor: pointer;\n }\n '
2895
+ )
2896
+ );
2897
+ };
2898
+
2899
+ var ADGutter = function ADGutter(_ref) {
2900
+ var title = _ref.title,
2901
+ gutterAd = _ref.gutterAd,
2902
+ minScreenWidth = _ref.minScreenWidth;
2903
+ var className = gutterAd.className,
2904
+ slotId = gutterAd.slotId,
2905
+ adUnit = gutterAd.adUnit,
2906
+ _gutterAd$targeting = gutterAd.targeting,
2907
+ targeting = _gutterAd$targeting === undefined ? {} : _gutterAd$targeting,
2908
+ position = gutterAd.position,
2909
+ networkID = gutterAd.networkID,
2910
+ sizes = gutterAd.sizes;
2911
+
2912
+ var _useState = React.useState(false),
2913
+ _useState2 = slicedToArray._slicedToArray(_useState, 2),
2914
+ showAd = _useState2[0],
2915
+ setShowAd = _useState2[1];
2916
+
2917
+ var adTargeting = void 0;
2918
+ if (position && position.length > 0) {
2919
+ adTargeting = {
2920
+ content_placement: targeting.content_placement,
2921
+ document_url: targeting.document_url,
2922
+ pos: [position]
2923
+ };
2924
+ }
2925
+
2926
+ React.useEffect(function () {
2927
+ if (window && window.innerWidth >= minScreenWidth) {
2928
+ setShowAd(true);
2929
+ }
2930
+ }, [minScreenWidth]);
2931
+
2932
+ if (showAd) {
2933
+ return React__default.createElement(
2934
+ React__default.Fragment,
2935
+ null,
2936
+ showAd && React__default.createElement(
2937
+ 'div',
2938
+ { className: 'gutter-ad-wrapper ' + title },
2939
+ React__default.createElement(
2940
+ 'div',
2941
+ { className: 'gutter-ad' },
2942
+ React__default.createElement(AdSlot.DFPAdSlot, { className: className, slotId: slotId, networkID: networkID, sizes: sizes, adUnit: adUnit, targeting: adTargeting, refreshFlag: false })
2943
+ )
2944
+ ),
2945
+ React__default.createElement(
2946
+ 'style',
2947
+ { jsx: 'true' },
2948
+ '\n .gutter-ad-wrapper {\n position: fixed;\n width: 100%;\n height: 100%;\n z-index: 999;\n }\n .gutter-ad {\n width: 150px;\n position: relative;\n top: 50;\n }\n '
2949
+ )
2950
+ );
2951
+ } else return null;
2952
+ };
2953
+
2954
+ var ADWelcome = function ADWelcome(_ref) {
2955
+ var title = _ref.title,
2956
+ welcomeAd = _ref.welcomeAd,
2957
+ setFlag = _ref.setFlag,
2958
+ Website = _ref.Website,
2959
+ counter = _ref.counter;
2960
+ var className = welcomeAd.className,
2961
+ slotId = welcomeAd.slotId,
2962
+ adUnit = welcomeAd.adUnit,
2963
+ _welcomeAd$targeting = welcomeAd.targeting,
2964
+ targeting = _welcomeAd$targeting === undefined ? {} : _welcomeAd$targeting,
2965
+ position = welcomeAd.position,
2966
+ networkID = welcomeAd.networkID,
2967
+ sizes = welcomeAd.sizes;
2968
+
2969
+
2970
+ var adTargeting = void 0;
2971
+ if (position && position.length > 0) {
2972
+ adTargeting = {
2973
+ content_placement: targeting.content_placement,
2974
+ document_url: targeting.document_url,
2975
+ pos: [position]
2976
+ };
2977
+ }
2978
+
2979
+ var calculateTimeLeft = function calculateTimeLeft(timeLeft) {
2980
+ return --timeLeft;
2981
+ };
2982
+
2983
+ var _useState = React.useState(calculateTimeLeft(counter)),
2984
+ _useState2 = slicedToArray._slicedToArray(_useState, 2),
2985
+ timeLeft = _useState2[0],
2986
+ setTimeLeft = _useState2[1];
2987
+
2988
+ React.useEffect(function () {
2989
+ if (timeLeft > 0) {
2990
+ setTimeout(function () {
2991
+ setTimeLeft(calculateTimeLeft(timeLeft));
2992
+ }, 1000);
2993
+ } else {
2994
+ setFlag(true);
2995
+ }
2996
+ });
2997
+
2998
+ return React__default.createElement(
2999
+ Modal,
3000
+ { show: true, 'aria-labelledby': 'contained-modal-title-vcenter', backdrop: 'static', style: { outline: 'none' }, dialogClassName: 'welcome-modal' },
3001
+ React__default.createElement(
3002
+ 'div',
3003
+ { className: 'right-top', style: { position: 'absolute', top: 0, right: 0, textAlign: 'center', margin: '2rem' } },
3004
+ React__default.createElement(
3005
+ 'span',
3006
+ {
3007
+ className: 'continue-site',
3008
+ style: {
3009
+ fontSize: '1.2rem',
3010
+ fontWeight: 'bold',
3011
+ fontFamily: "'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'"
3012
+ },
3013
+ onClick: function onClick() {
3014
+ setFlag(true);
3015
+ } },
3016
+ 'CONTINUE TO SITE >'
3017
+ ),
3018
+ React__default.createElement(
3019
+ 'p',
3020
+ {
3021
+ style: {
3022
+ fontSize: '0.8rem',
3023
+ fontFamily: "'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'"
3024
+ },
3025
+ className: 'timer-block' },
3026
+ 'OR WAIT ' + timeLeft + ' SECS'
3027
+ )
3028
+ ),
3029
+ React__default.createElement(
3030
+ 'div',
3031
+ { className: 'left-top', style: { position: 'absolute', top: 0, left: 0, maxWidth: '200px', margin: '2rem' } },
3032
+ React__default.createElement('img', { style: { width: '100%' }, src: Website.logo, alt: Website.title })
3033
+ ),
3034
+ React__default.createElement(
3035
+ Modal.Body,
3036
+ { className: title, style: { position: 'relative', width: '300px', height: '250px', margin: 'auto', top: '10rem' } },
3037
+ React__default.createElement(AdSlot.DFPAdSlot, { className: className, slotId: slotId, networkID: networkID, sizes: sizes, adUnit: adUnit, targeting: adTargeting, refreshFlag: false })
3038
+ ),
3039
+ React__default.createElement(
3040
+ 'style',
3041
+ { jsx: 'true' },
3042
+ '\n .continue-site:hover {\n cursor: pointer;\n }\n\n @media (min-width: 1200px) {\n .modal-backdrop {\n display: block;\n }\n .modal-content {\n display: block;\n }\n }\n '
3043
+ )
3044
+ );
3045
+ };
3046
+
2842
3047
  var urlFor$1 = function urlFor(source, client) {
2843
3048
  var builder = index$1.imageUrlBuilder(client);
2844
3049
  return builder.image(source).auto('format');
@@ -3048,18 +3253,21 @@ var Slideshow = function Slideshow(_ref) {
3048
3253
  );
3049
3254
  };
3050
3255
 
3051
- // do not edit .js files directly - edit src/index.jst
3052
-
3053
-
3256
+ var isArray = Array.isArray;
3257
+ var keyList = Object.keys;
3258
+ var hasProp = Object.prototype.hasOwnProperty;
3054
3259
 
3055
3260
  var fastDeepEqual = function equal(a, b) {
3056
3261
  if (a === b) return true;
3057
3262
 
3058
3263
  if (a && b && typeof a == 'object' && typeof b == 'object') {
3059
- if (a.constructor !== b.constructor) return false;
3264
+ var arrA = isArray(a)
3265
+ , arrB = isArray(b)
3266
+ , i
3267
+ , length
3268
+ , key;
3060
3269
 
3061
- var length, i, keys;
3062
- if (Array.isArray(a)) {
3270
+ if (arrA && arrB) {
3063
3271
  length = a.length;
3064
3272
  if (length != b.length) return false;
3065
3273
  for (i = length; i-- !== 0;)
@@ -3067,29 +3275,35 @@ var fastDeepEqual = function equal(a, b) {
3067
3275
  return true;
3068
3276
  }
3069
3277
 
3278
+ if (arrA != arrB) return false;
3070
3279
 
3280
+ var dateA = a instanceof Date
3281
+ , dateB = b instanceof Date;
3282
+ if (dateA != dateB) return false;
3283
+ if (dateA && dateB) return a.getTime() == b.getTime();
3071
3284
 
3072
- if (a.constructor === RegExp) return a.source === b.source && a.flags === b.flags;
3073
- if (a.valueOf !== Object.prototype.valueOf) return a.valueOf() === b.valueOf();
3074
- if (a.toString !== Object.prototype.toString) return a.toString() === b.toString();
3285
+ var regexpA = a instanceof RegExp
3286
+ , regexpB = b instanceof RegExp;
3287
+ if (regexpA != regexpB) return false;
3288
+ if (regexpA && regexpB) return a.toString() == b.toString();
3075
3289
 
3076
- keys = Object.keys(a);
3290
+ var keys = keyList(a);
3077
3291
  length = keys.length;
3078
- if (length !== Object.keys(b).length) return false;
3292
+
3293
+ if (length !== keyList(b).length)
3294
+ return false;
3079
3295
 
3080
3296
  for (i = length; i-- !== 0;)
3081
- if (!Object.prototype.hasOwnProperty.call(b, keys[i])) return false;
3297
+ if (!hasProp.call(b, keys[i])) return false;
3082
3298
 
3083
3299
  for (i = length; i-- !== 0;) {
3084
- var key = keys[i];
3085
-
3300
+ key = keys[i];
3086
3301
  if (!equal(a[key], b[key])) return false;
3087
3302
  }
3088
3303
 
3089
3304
  return true;
3090
3305
  }
3091
3306
 
3092
- // true if both NaN, false otherwise
3093
3307
  return a!==a && b!==b;
3094
3308
  };
3095
3309
 
@@ -4112,7 +4326,7 @@ function formatValue(ctx, value, recurseTimes) {
4112
4326
  var base = '', array = false, braces = ['{', '}'];
4113
4327
 
4114
4328
  // Make Array say that they are Array
4115
- if (isArray(value)) {
4329
+ if (isArray$1(value)) {
4116
4330
  array = true;
4117
4331
  braces = ['[', ']'];
4118
4332
  }
@@ -4291,7 +4505,7 @@ function reduceToSingleString(output, base, braces) {
4291
4505
 
4292
4506
  // NOTE: These type checking functions intentionally don't use `instanceof`
4293
4507
  // because it is fragile and can be easily faked with `Object.create()`.
4294
- function isArray(ar) {
4508
+ function isArray$1(ar) {
4295
4509
  return Array.isArray(ar);
4296
4510
  }
4297
4511
 
@@ -4418,7 +4632,7 @@ var util = {
4418
4632
  isNullOrUndefined: isNullOrUndefined,
4419
4633
  isNull: isNull,
4420
4634
  isBoolean: isBoolean,
4421
- isArray: isArray,
4635
+ isArray: isArray$1,
4422
4636
  inspect: inspect,
4423
4637
  deprecate: deprecate,
4424
4638
  format: format,
@@ -5085,235 +5299,199 @@ module.exports = exports['default'];
5085
5299
 
5086
5300
  var youTubePlayer = _commonjsHelpers.unwrapExports(dist);
5087
5301
 
5088
- 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); }
5089
-
5090
- function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
5091
-
5092
- 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); } }
5093
-
5094
- function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
5095
-
5096
- 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); }; }
5097
-
5098
- function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
5099
-
5100
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
5101
-
5102
- 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; } }
5103
-
5104
- function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
5302
+ var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
5105
5303
 
5106
- 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); }
5304
+ 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; };
5107
5305
 
5108
- function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
5306
+ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
5109
5307
 
5110
- 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; }
5308
+ function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; }
5111
5309
 
5112
- 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; }
5310
+ function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
5113
5311
 
5114
- 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; }
5115
- /**
5116
- * Check whether a `props` change should result in the video being updated.
5117
- *
5118
- * @param {Object} prevProps
5119
- * @param {Object} props
5312
+ /**
5313
+ * Check whether a `props` change should result in the video being updated.
5314
+ *
5315
+ * @param {Object} prevProps
5316
+ * @param {Object} props
5120
5317
  */
5121
-
5122
5318
  function shouldUpdateVideo(prevProps, props) {
5123
5319
  // A changing video should always trigger an update
5124
5320
  if (prevProps.videoId !== props.videoId) {
5125
5321
  return true;
5126
- } // Otherwise, a change in the start/end time playerVars also requires a player
5127
- // update.
5128
-
5322
+ }
5129
5323
 
5324
+ // Otherwise, a change in the start/end time playerVars also requires a player
5325
+ // update.
5130
5326
  var prevVars = prevProps.opts.playerVars || {};
5131
5327
  var vars = props.opts.playerVars || {};
5328
+
5132
5329
  return prevVars.start !== vars.start || prevVars.end !== vars.end;
5133
5330
  }
5134
- /**
5135
- * Neutralize API options that only require a video update, leaving only options
5136
- * that require a player reset. The results can then be compared to see if a
5137
- * player reset is necessary.
5138
- *
5139
- * @param {Object} opts
5140
- */
5141
-
5142
5331
 
5332
+ /**
5333
+ * Neutralise API options that only require a video update, leaving only options
5334
+ * that require a player reset. The results can then be compared to see if a
5335
+ * player reset is necessary.
5336
+ *
5337
+ * @param {Object} opts
5338
+ */
5143
5339
  function filterResetOptions(opts) {
5144
- return _objectSpread({}, opts, {
5145
- playerVars: _objectSpread({}, opts.playerVars, {
5340
+ return _extends({}, opts, {
5341
+ playerVars: _extends({}, opts.playerVars, {
5146
5342
  autoplay: 0,
5147
5343
  start: 0,
5148
5344
  end: 0
5149
5345
  })
5150
5346
  });
5151
5347
  }
5152
- /**
5153
- * Check whether a `props` change should result in the player being reset.
5154
- * The player is reset when the `props.opts` change, except if the only change
5155
- * is in the `start` and `end` playerVars, because a video update can deal with
5156
- * those.
5157
- *
5158
- * @param {Object} prevProps
5159
- * @param {Object} props
5160
- */
5161
-
5162
5348
 
5349
+ /**
5350
+ * Check whether a `props` change should result in the player being reset.
5351
+ * The player is reset when the `props.opts` change, except if the only change
5352
+ * is in the `start` and `end` playerVars, because a video update can deal with
5353
+ * those.
5354
+ *
5355
+ * @param {Object} prevProps
5356
+ * @param {Object} props
5357
+ */
5163
5358
  function shouldResetPlayer(prevProps, props) {
5164
5359
  return !fastDeepEqual(filterResetOptions(prevProps.opts), filterResetOptions(props.opts));
5165
5360
  }
5166
- /**
5167
- * Check whether a props change should result in an id or className update.
5168
- *
5169
- * @param {Object} prevProps
5170
- * @param {Object} props
5171
- */
5172
-
5173
5361
 
5362
+ /**
5363
+ * Check whether a props change should result in an id or className update.
5364
+ *
5365
+ * @param {Object} prevProps
5366
+ * @param {Object} props
5367
+ */
5174
5368
  function shouldUpdatePlayer(prevProps, props) {
5175
5369
  return prevProps.id !== props.id || prevProps.className !== props.className;
5176
5370
  }
5177
5371
 
5178
- var YouTube = /*#__PURE__*/function (_React$Component) {
5372
+ var YouTube = function (_React$Component) {
5179
5373
  _inherits(YouTube, _React$Component);
5180
5374
 
5181
- var _super = _createSuper(YouTube);
5182
-
5183
- /**
5184
- * Expose PlayerState constants for convenience. These constants can also be
5185
- * accessed through the global YT object after the YouTube IFrame API is instantiated.
5186
- * https://developers.google.com/youtube/iframe_api_reference#onStateChange
5187
- */
5188
5375
  function YouTube(props) {
5189
- var _this;
5190
-
5191
5376
  _classCallCheck(this, YouTube);
5192
5377
 
5193
- _this = _super.call(this, props);
5378
+ var _this = _possibleConstructorReturn(this, (YouTube.__proto__ || Object.getPrototypeOf(YouTube)).call(this, props));
5194
5379
 
5195
- _defineProperty(_assertThisInitialized(_this), "onPlayerReady", function (event) {
5380
+ _this.onPlayerReady = function (event) {
5196
5381
  return _this.props.onReady(event);
5197
- });
5382
+ };
5198
5383
 
5199
- _defineProperty(_assertThisInitialized(_this), "onPlayerError", function (event) {
5384
+ _this.onPlayerError = function (event) {
5200
5385
  return _this.props.onError(event);
5201
- });
5386
+ };
5202
5387
 
5203
- _defineProperty(_assertThisInitialized(_this), "onPlayerStateChange", function (event) {
5388
+ _this.onPlayerStateChange = function (event) {
5204
5389
  _this.props.onStateChange(event);
5205
-
5206
5390
  switch (event.data) {
5391
+
5207
5392
  case YouTube.PlayerState.ENDED:
5208
5393
  _this.props.onEnd(event);
5209
-
5210
5394
  break;
5211
5395
 
5212
5396
  case YouTube.PlayerState.PLAYING:
5213
5397
  _this.props.onPlay(event);
5214
-
5215
5398
  break;
5216
5399
 
5217
5400
  case YouTube.PlayerState.PAUSED:
5218
5401
  _this.props.onPause(event);
5219
-
5220
5402
  break;
5221
5403
  }
5222
- });
5404
+ };
5223
5405
 
5224
- _defineProperty(_assertThisInitialized(_this), "onPlayerPlaybackRateChange", function (event) {
5406
+ _this.onPlayerPlaybackRateChange = function (event) {
5225
5407
  return _this.props.onPlaybackRateChange(event);
5226
- });
5408
+ };
5227
5409
 
5228
- _defineProperty(_assertThisInitialized(_this), "onPlayerPlaybackQualityChange", function (event) {
5410
+ _this.onPlayerPlaybackQualityChange = function (event) {
5229
5411
  return _this.props.onPlaybackQualityChange(event);
5230
- });
5412
+ };
5231
5413
 
5232
- _defineProperty(_assertThisInitialized(_this), "createPlayer", function () {
5414
+ _this.createPlayer = function () {
5233
5415
  // do not attempt to create a player server-side, it won't work
5234
- if (typeof document === 'undefined') return; // create player
5235
-
5236
- var playerOpts = _objectSpread({}, _this.props.opts, {
5416
+ if (typeof document === 'undefined') return;
5417
+ // create player
5418
+ var playerOpts = _extends({}, _this.props.opts, {
5237
5419
  // preload the `videoId` video if one is already given
5238
5420
  videoId: _this.props.videoId
5239
5421
  });
5240
-
5241
- _this.internalPlayer = youTubePlayer(_this.container, playerOpts); // attach event handlers
5242
-
5422
+ _this.internalPlayer = youTubePlayer(_this.container, playerOpts);
5423
+ // attach event handlers
5243
5424
  _this.internalPlayer.on('ready', _this.onPlayerReady);
5244
-
5245
5425
  _this.internalPlayer.on('error', _this.onPlayerError);
5246
-
5247
5426
  _this.internalPlayer.on('stateChange', _this.onPlayerStateChange);
5248
-
5249
5427
  _this.internalPlayer.on('playbackRateChange', _this.onPlayerPlaybackRateChange);
5250
-
5251
5428
  _this.internalPlayer.on('playbackQualityChange', _this.onPlayerPlaybackQualityChange);
5252
- });
5429
+ };
5253
5430
 
5254
- _defineProperty(_assertThisInitialized(_this), "resetPlayer", function () {
5431
+ _this.resetPlayer = function () {
5255
5432
  return _this.internalPlayer.destroy().then(_this.createPlayer);
5256
- });
5433
+ };
5257
5434
 
5258
- _defineProperty(_assertThisInitialized(_this), "updatePlayer", function () {
5435
+ _this.updatePlayer = function () {
5259
5436
  _this.internalPlayer.getIframe().then(function (iframe) {
5260
5437
  if (_this.props.id) iframe.setAttribute('id', _this.props.id);else iframe.removeAttribute('id');
5261
5438
  if (_this.props.className) iframe.setAttribute('class', _this.props.className);else iframe.removeAttribute('class');
5262
5439
  });
5263
- });
5440
+ };
5264
5441
 
5265
- _defineProperty(_assertThisInitialized(_this), "updateVideo", function () {
5442
+ _this.updateVideo = function () {
5266
5443
  if (typeof _this.props.videoId === 'undefined' || _this.props.videoId === null) {
5267
5444
  _this.internalPlayer.stopVideo();
5268
-
5269
5445
  return;
5270
- } // set queueing options
5271
-
5446
+ }
5272
5447
 
5448
+ // set queueing options
5273
5449
  var autoplay = false;
5274
5450
  var opts = {
5275
5451
  videoId: _this.props.videoId
5276
5452
  };
5277
-
5278
5453
  if ('playerVars' in _this.props.opts) {
5279
5454
  autoplay = _this.props.opts.playerVars.autoplay === 1;
5280
-
5281
5455
  if ('start' in _this.props.opts.playerVars) {
5282
5456
  opts.startSeconds = _this.props.opts.playerVars.start;
5283
5457
  }
5284
-
5285
5458
  if ('end' in _this.props.opts.playerVars) {
5286
5459
  opts.endSeconds = _this.props.opts.playerVars.end;
5287
5460
  }
5288
- } // if autoplay is enabled loadVideoById
5289
-
5461
+ }
5290
5462
 
5463
+ // if autoplay is enabled loadVideoById
5291
5464
  if (autoplay) {
5292
5465
  _this.internalPlayer.loadVideoById(opts);
5293
-
5294
5466
  return;
5295
- } // default behaviour just cues the video
5296
-
5297
-
5467
+ }
5468
+ // default behaviour just cues the video
5298
5469
  _this.internalPlayer.cueVideoById(opts);
5299
- });
5470
+ };
5300
5471
 
5301
- _defineProperty(_assertThisInitialized(_this), "refContainer", function (container) {
5472
+ _this.refContainer = function (container) {
5302
5473
  _this.container = container;
5303
- });
5474
+ };
5304
5475
 
5305
5476
  _this.container = null;
5306
5477
  _this.internalPlayer = null;
5307
5478
  return _this;
5308
5479
  }
5309
5480
 
5481
+ /**
5482
+ * Expose PlayerState constants for convenience. These constants can also be
5483
+ * accessed through the global YT object after the YouTube IFrame API is instantiated.
5484
+ * https://developers.google.com/youtube/iframe_api_reference#onStateChange
5485
+ */
5486
+
5487
+
5310
5488
  _createClass(YouTube, [{
5311
- key: "componentDidMount",
5489
+ key: 'componentDidMount',
5312
5490
  value: function componentDidMount() {
5313
5491
  this.createPlayer();
5314
5492
  }
5315
5493
  }, {
5316
- key: "componentDidUpdate",
5494
+ key: 'componentDidUpdate',
5317
5495
  value: function componentDidUpdate(prevProps) {
5318
5496
  if (shouldUpdatePlayer(prevProps, this.props)) {
5319
5497
  this.updatePlayer();
@@ -5328,58 +5506,112 @@ var YouTube = /*#__PURE__*/function (_React$Component) {
5328
5506
  }
5329
5507
  }
5330
5508
  }, {
5331
- key: "componentWillUnmount",
5509
+ key: 'componentWillUnmount',
5332
5510
  value: function componentWillUnmount() {
5333
- /**
5334
- * Note: The `youtube-player` package that is used promisifies all YouTube
5335
- * Player API calls, which introduces a delay of a tick before it actually
5336
- * gets destroyed. Since React attempts to remove the element instantly
5337
- * this method isn't quick enough to reset the container element.
5511
+ /**
5512
+ * Note: The `youtube-player` package that is used promisifies all Youtube
5513
+ * Player API calls, which introduces a delay of a tick before it actually
5514
+ * gets destroyed. Since React attempts to remove the element instantly
5515
+ * this method isn't quick enough to reset the container element.
5338
5516
  */
5339
5517
  this.internalPlayer.destroy();
5340
5518
  }
5341
- /**
5342
- * https://developers.google.com/youtube/iframe_api_reference#onReady
5343
- *
5344
- * @param {Object} event
5345
- * @param {Object} target - player object
5519
+
5520
+ /**
5521
+ * https://developers.google.com/youtube/iframe_api_reference#onReady
5522
+ *
5523
+ * @param {Object} event
5524
+ * @param {Object} target - player object
5525
+ */
5526
+
5527
+
5528
+ /**
5529
+ * https://developers.google.com/youtube/iframe_api_reference#onError
5530
+ *
5531
+ * @param {Object} event
5532
+ * @param {Integer} data - error type
5533
+ * @param {Object} target - player object
5534
+ */
5535
+
5536
+
5537
+ /**
5538
+ * https://developers.google.com/youtube/iframe_api_reference#onStateChange
5539
+ *
5540
+ * @param {Object} event
5541
+ * @param {Integer} data - status change type
5542
+ * @param {Object} target - actual YT player
5543
+ */
5544
+
5545
+
5546
+ /**
5547
+ * https://developers.google.com/youtube/iframe_api_reference#onPlaybackRateChange
5548
+ *
5549
+ * @param {Object} event
5550
+ * @param {Float} data - playback rate
5551
+ * @param {Object} target - actual YT player
5552
+ */
5553
+
5554
+
5555
+ /**
5556
+ * https://developers.google.com/youtube/iframe_api_reference#onPlaybackQualityChange
5557
+ *
5558
+ * @param {Object} event
5559
+ * @param {String} data - playback quality
5560
+ * @param {Object} target - actual YT player
5561
+ */
5562
+
5563
+
5564
+ /**
5565
+ * Initialize the Youtube Player API on the container and attach event handlers
5566
+ */
5567
+
5568
+
5569
+ /**
5570
+ * Shorthand for destroying and then re-creating the Youtube Player
5571
+ */
5572
+
5573
+
5574
+ /**
5575
+ * Method to update the id and class of the Youtube Player iframe.
5576
+ * React should update this automatically but since the Youtube Player API
5577
+ * replaced the DIV that is mounted by React we need to do this manually.
5578
+ */
5579
+
5580
+
5581
+ /**
5582
+ * Call Youtube Player API methods to update the currently playing video.
5583
+ * Depeding on the `opts.playerVars.autoplay` this function uses one of two
5584
+ * Youtube Player API methods to update the video.
5346
5585
  */
5347
5586
 
5348
5587
  }, {
5349
- key: "render",
5588
+ key: 'render',
5350
5589
  value: function render() {
5351
- return /*#__PURE__*/React__default.createElement("div", {
5352
- className: this.props.containerClassName
5353
- }, /*#__PURE__*/React__default.createElement("div", {
5354
- id: this.props.id,
5355
- className: this.props.className,
5356
- ref: this.refContainer
5357
- }));
5590
+ return React__default.createElement(
5591
+ 'div',
5592
+ { className: this.props.containerClassName },
5593
+ React__default.createElement('div', { id: this.props.id, className: this.props.className, ref: this.refContainer })
5594
+ );
5358
5595
  }
5359
5596
  }]);
5360
5597
 
5361
5598
  return YouTube;
5362
5599
  }(React__default.Component);
5363
5600
 
5364
- _defineProperty(YouTube, "PlayerState", {
5365
- UNSTARTED: -1,
5366
- ENDED: 0,
5367
- PLAYING: 1,
5368
- PAUSED: 2,
5369
- BUFFERING: 3,
5370
- CUED: 5
5371
- });
5372
-
5373
5601
  YouTube.propTypes = {
5374
5602
  videoId: PropTypes.string,
5603
+
5375
5604
  // custom ID for player element
5376
5605
  id: PropTypes.string,
5606
+
5377
5607
  // custom class name for player element
5378
5608
  className: PropTypes.string,
5379
5609
  // custom class name for player container element
5380
5610
  containerClassName: PropTypes.string,
5611
+
5381
5612
  // https://developers.google.com/youtube/iframe_api_reference#Loading_a_Video_Player
5382
5613
  opts: PropTypes.objectOf(PropTypes.any),
5614
+
5383
5615
  // event subscriptions
5384
5616
  onReady: PropTypes.func,
5385
5617
  onError: PropTypes.func,
@@ -5391,7 +5623,6 @@ YouTube.propTypes = {
5391
5623
  onPlaybackQualityChange: PropTypes.func
5392
5624
  };
5393
5625
  YouTube.defaultProps = {
5394
- videoId: null,
5395
5626
  id: null,
5396
5627
  className: null,
5397
5628
  opts: {},
@@ -5405,6 +5636,14 @@ YouTube.defaultProps = {
5405
5636
  onPlaybackRateChange: function onPlaybackRateChange() {},
5406
5637
  onPlaybackQualityChange: function onPlaybackQualityChange() {}
5407
5638
  };
5639
+ YouTube.PlayerState = {
5640
+ UNSTARTED: -1,
5641
+ ENDED: 0,
5642
+ PLAYING: 1,
5643
+ PAUSED: 2,
5644
+ BUFFERING: 3,
5645
+ CUED: 5
5646
+ };
5408
5647
 
5409
5648
  var YouTubePlayer = function YouTubePlayer(_ref) {
5410
5649
  var url = _ref.url;
@@ -5426,11 +5665,6 @@ var YouTubePlayer = function YouTubePlayer(_ref) {
5426
5665
  intervalID = _useState6[0],
5427
5666
  setIntervalID = _useState6[1];
5428
5667
 
5429
- var _useState7 = React.useState(null),
5430
- _useState8 = slicedToArray._slicedToArray(_useState7, 2),
5431
- segmentData = _useState8[0],
5432
- setSegemntData = _useState8[1];
5433
-
5434
5668
  var queueProgress = [];
5435
5669
 
5436
5670
  var opts = {
@@ -5440,12 +5674,14 @@ var YouTubePlayer = function YouTubePlayer(_ref) {
5440
5674
  }
5441
5675
  };
5442
5676
 
5443
- React.useEffect(function () {
5444
- if (segmentData) {
5445
- console.log('Video Segment', segmentData);
5446
- AdSlot.Beam.report_beam_video('Segment', main.main_16, segmentData.duration, segmentData.current, segmentData.segment);
5447
- }
5448
- }, [segmentData]);
5677
+ var handleOnReady = function handleOnReady(event) {
5678
+ var player = event.target;
5679
+ var current = player.getCurrentTime();
5680
+ var duration = player.getDuration();
5681
+ var queue = Math.floor(duration / 10);
5682
+ var segment = Math.floor(current / queue);
5683
+ AdSlot.Beam.report_beam_video('Ready', main.main_16, duration, current, segment);
5684
+ };
5449
5685
 
5450
5686
  var handlePlayPercent = function handlePlayPercent(player) {
5451
5687
  var current = player.getCurrentTime();
@@ -5454,28 +5690,22 @@ var YouTubePlayer = function YouTubePlayer(_ref) {
5454
5690
  var segment = Math.floor(current / queue);
5455
5691
 
5456
5692
  if (!queueProgress.includes(segment)) {
5457
- setSegemntData({
5458
- current: current,
5459
- duration: duration,
5460
- queue: queue,
5461
- segment: segment
5462
- });
5693
+ AdSlot.Beam.report_beam_video('Segment', main.main_16, duration, current, segment);
5463
5694
  queueProgress.push(segment);
5464
5695
  }
5465
5696
  };
5466
5697
 
5467
5698
  var handleOnPlay = function handleOnPlay(event) {
5468
5699
  // report play
5469
- if (!playReported) {
5470
- console.log('Video Play', event);
5700
+ var player = event.target;
5701
+ var current = player.getCurrentTime();
5702
+ var duration = player.getDuration();
5703
+ var queue = Math.floor(duration / 10);
5704
+ var segment = Math.floor(current / queue);
5471
5705
 
5472
- var player = event.target;
5473
- var current = player.getCurrentTime();
5474
- var duration = player.getDuration();
5475
- var queue = Math.floor(duration / 10);
5476
- var segment = Math.floor(current / queue);
5706
+ AdSlot.Beam.report_beam_video('Play', main.main_16, duration, current, segment);
5477
5707
 
5478
- AdSlot.Beam.report_beam_video('Play', main.main_16, duration, current, segment);
5708
+ if (!playReported) {
5479
5709
  setPlayReported(true);
5480
5710
  var _intervalID = setInterval(function () {
5481
5711
  handlePlayPercent(event.target);
@@ -5486,7 +5716,6 @@ var YouTubePlayer = function YouTubePlayer(_ref) {
5486
5716
 
5487
5717
  var handleOnEnd = function handleOnEnd(event) {
5488
5718
  if (!endReported) {
5489
- console.log('Video End', event);
5490
5719
  var player = event.target;
5491
5720
  var current = player.getCurrentTime();
5492
5721
  var duration = player.getDuration();
@@ -5500,7 +5729,6 @@ var YouTubePlayer = function YouTubePlayer(_ref) {
5500
5729
  };
5501
5730
 
5502
5731
  var handleOnPause = function handleOnPause(event) {
5503
- console.log('Video Pause');
5504
5732
  var player = event.target;
5505
5733
  var current = player.getCurrentTime();
5506
5734
  var duration = player.getDuration();
@@ -5510,7 +5738,7 @@ var YouTubePlayer = function YouTubePlayer(_ref) {
5510
5738
  AdSlot.Beam.report_beam_video('Pause', main.main_16, duration, current, segment);
5511
5739
  };
5512
5740
 
5513
- return React__default.createElement(YouTube, { videoId: id, opts: opts, onPlay: handleOnPlay, onPause: handleOnPause, onEnd: handleOnEnd });
5741
+ return React__default.createElement(YouTube, { videoId: id, opts: opts, onReady: handleOnReady, onPlay: handleOnPlay, onPause: handleOnPause, onEnd: handleOnEnd });
5514
5742
  };
5515
5743
 
5516
5744
  var Sidebar = function Sidebar(_ref) {
@@ -6439,8 +6667,8 @@ var window_1 = win;
6439
6667
 
6440
6668
  /*! @name @brightcove/react-player-loader @version 1.4.0 @license Apache-2.0 */
6441
6669
 
6442
- function _extends() {
6443
- _extends = Object.assign || function (target) {
6670
+ function _extends$1() {
6671
+ _extends$1 = Object.assign || function (target) {
6444
6672
  for (var i = 1; i < arguments.length; i++) {
6445
6673
  var source = arguments[i];
6446
6674
 
@@ -6454,7 +6682,7 @@ function _extends() {
6454
6682
  return target;
6455
6683
  };
6456
6684
 
6457
- return _extends.apply(this, arguments);
6685
+ return _extends$1.apply(this, arguments);
6458
6686
  }
6459
6687
 
6460
6688
  function _inheritsLoose(subClass, superClass) {
@@ -6463,7 +6691,7 @@ function _inheritsLoose(subClass, superClass) {
6463
6691
  subClass.__proto__ = superClass;
6464
6692
  }
6465
6693
 
6466
- function _assertThisInitialized$1(self) {
6694
+ function _assertThisInitialized(self) {
6467
6695
  if (self === void 0) {
6468
6696
  throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
6469
6697
  }
@@ -6473,8 +6701,8 @@ function _assertThisInitialized$1(self) {
6473
6701
 
6474
6702
  /*! @name @brightcove/player-loader @version 1.7.1 @license Apache-2.0 */
6475
6703
 
6476
- function _extends$1() {
6477
- _extends$1 = Object.assign || function (target) {
6704
+ function _extends$1$1() {
6705
+ _extends$1$1 = Object.assign || function (target) {
6478
6706
  for (var i = 1; i < arguments.length; i++) {
6479
6707
  var source = arguments[i];
6480
6708
 
@@ -6488,7 +6716,7 @@ function _extends$1() {
6488
6716
  return target;
6489
6717
  };
6490
6718
 
6491
- return _extends$1.apply(this, arguments);
6719
+ return _extends$1$1.apply(this, arguments);
6492
6720
  }
6493
6721
 
6494
6722
  var version$1 = "1.7.1";
@@ -6496,7 +6724,7 @@ var version$1 = "1.7.1";
6496
6724
  /*! @name @brightcove/player-url @version 1.2.0 @license Apache-2.0 */
6497
6725
  var version$1$1 = "1.2.0";
6498
6726
 
6499
- var _typeof$1 = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) {
6727
+ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) {
6500
6728
  return typeof obj;
6501
6729
  } : function (obj) {
6502
6730
  return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
@@ -6631,7 +6859,7 @@ var brightcovePlayerUrl = function brightcovePlayerUrl(_ref) {
6631
6859
 
6632
6860
  var qs = '';
6633
6861
 
6634
- if (iframe && queryParams && (typeof queryParams === 'undefined' ? 'undefined' : _typeof$1(queryParams)) === 'object') {
6862
+ if (iframe && queryParams && (typeof queryParams === 'undefined' ? 'undefined' : _typeof(queryParams)) === 'object') {
6635
6863
  qs = getQueryString(queryParams);
6636
6864
  }
6637
6865
 
@@ -6865,7 +7093,7 @@ var wrapResponsive = function wrapResponsive(embedType, embedOptions, el) {
6865
7093
  el.style.width = '100%';
6866
7094
  el.style.height = '100%';
6867
7095
 
6868
- var responsive = _extends$1({
7096
+ var responsive = _extends$1$1({
6869
7097
  aspectRatio: DEFAULT_ASPECT_RATIO,
6870
7098
  iframeHorizontalPlaylist: DEFAULT_IFRAME_HORIZONTAL_PLAYLIST,
6871
7099
  maxWidth: DEFAULT_MAX_WIDTH
@@ -7550,7 +7778,7 @@ var loadPlayer = function loadPlayer(params, resolve, reject) {
7550
7778
 
7551
7779
 
7552
7780
  var brightcovePlayerLoader = function brightcovePlayerLoader(parameters) {
7553
- var params = _extends$1({}, DEFAULTS, parameters);
7781
+ var params = _extends$1$1({}, DEFAULTS, parameters);
7554
7782
 
7555
7783
  var Promise = params.Promise,
7556
7784
  onSuccess = params.onSuccess,
@@ -7692,7 +7920,7 @@ function (_React$Component) {
7692
7920
  _this.refNode = ref;
7693
7921
  };
7694
7922
 
7695
- _this.loadPlayer = _this.loadPlayer.bind(_assertThisInitialized$1(_this));
7923
+ _this.loadPlayer = _this.loadPlayer.bind(_assertThisInitialized(_this));
7696
7924
  return _this;
7697
7925
  }
7698
7926
  /**
@@ -7713,7 +7941,7 @@ function (_React$Component) {
7713
7941
  var userSuccess = this.props.onSuccess;
7714
7942
  var userFailure = this.props.onFailure;
7715
7943
 
7716
- var options = _extends({}, this.props, {
7944
+ var options = _extends$1({}, this.props, {
7717
7945
  refNode: this.refNode,
7718
7946
  refNodeInsert: 'append',
7719
7947
  onSuccess: function onSuccess(_ref) {
@@ -8022,7 +8250,7 @@ function (_React$Component) {
8022
8250
  ;
8023
8251
 
8024
8252
  _proto.render = function render() {
8025
- var props = _extends({
8253
+ var props = _extends$1({
8026
8254
  className: 'brightcove-react-player-loader'
8027
8255
  }, this.props.attrs, {
8028
8256
  ref: this.setRefNode
@@ -8436,17 +8664,11 @@ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "functi
8436
8664
 
8437
8665
  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; }
8438
8666
 
8439
- 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; } } }; }
8440
-
8441
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
8667
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }
8442
8668
 
8443
- 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."); }
8669
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); }
8444
8670
 
8445
- 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); }
8446
-
8447
- 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; }
8448
-
8449
- 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; }
8671
+ function _iterableToArrayLimit(arr, i) { if (!(Symbol.iterator in Object(arr) || Object.prototype.toString.call(arr) === "[object Arguments]")) { return; } var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
8450
8672
 
8451
8673
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
8452
8674
 
@@ -8576,12 +8798,12 @@ function getSDK(url, sdkGlobal) {
8576
8798
 
8577
8799
  function getConfig(props$1, defaultProps, showWarning) {
8578
8800
  var config = (0, _deepmerge["default"])(defaultProps.config, props$1.config);
8579
-
8580
- var _iterator = _createForOfIteratorHelper(props.DEPRECATED_CONFIG_PROPS),
8581
- _step;
8801
+ var _iteratorNormalCompletion = true;
8802
+ var _didIteratorError = false;
8803
+ var _iteratorError = undefined;
8582
8804
 
8583
8805
  try {
8584
- for (_iterator.s(); !(_step = _iterator.n()).done;) {
8806
+ for (var _iterator = props.DEPRECATED_CONFIG_PROPS[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
8585
8807
  var p = _step.value;
8586
8808
 
8587
8809
  if (props$1[p]) {
@@ -8596,9 +8818,18 @@ function getConfig(props$1, defaultProps, showWarning) {
8596
8818
  }
8597
8819
  }
8598
8820
  } catch (err) {
8599
- _iterator.e(err);
8821
+ _didIteratorError = true;
8822
+ _iteratorError = err;
8600
8823
  } finally {
8601
- _iterator.f();
8824
+ try {
8825
+ if (!_iteratorNormalCompletion && _iterator["return"] != null) {
8826
+ _iterator["return"]();
8827
+ }
8828
+ } finally {
8829
+ if (_didIteratorError) {
8830
+ throw _iteratorError;
8831
+ }
8832
+ }
8602
8833
  }
8603
8834
 
8604
8835
  return config;
@@ -8745,16 +8976,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
8745
8976
 
8746
8977
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
8747
8978
 
8748
- 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); }; }
8749
-
8750
8979
  function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
8751
8980
 
8752
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
8753
-
8754
- 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; } }
8755
-
8756
8981
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
8757
8982
 
8983
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
8984
+
8758
8985
  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); }
8759
8986
 
8760
8987
  function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
@@ -8763,12 +8990,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
8763
8990
 
8764
8991
  var SEEK_ON_PLAY_EXPIRY = 5000;
8765
8992
 
8766
- var Player = /*#__PURE__*/function (_Component) {
8993
+ var Player =
8994
+ /*#__PURE__*/
8995
+ function (_Component) {
8767
8996
  _inherits(Player, _Component);
8768
8997
 
8769
- var _super = _createSuper(Player);
8770
-
8771
8998
  function Player() {
8999
+ var _getPrototypeOf2;
9000
+
8772
9001
  var _this;
8773
9002
 
8774
9003
  _classCallCheck(this, Player);
@@ -8777,7 +9006,7 @@ var Player = /*#__PURE__*/function (_Component) {
8777
9006
  _args[_key] = arguments[_key];
8778
9007
  }
8779
9008
 
8780
- _this = _super.call.apply(_super, [this].concat(_args));
9009
+ _this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Player)).call.apply(_getPrototypeOf2, [this].concat(_args)));
8781
9010
 
8782
9011
  _defineProperty(_assertThisInitialized(_this), "mounted", false);
8783
9012
 
@@ -9102,7 +9331,7 @@ var Player = /*#__PURE__*/function (_Component) {
9102
9331
  return null;
9103
9332
  }
9104
9333
 
9105
- return /*#__PURE__*/_react["default"].createElement(Player, _extends({}, this.props, {
9334
+ return _react["default"].createElement(Player, _extends({}, this.props, {
9106
9335
  ref: this.ref,
9107
9336
  onReady: this.handleReady,
9108
9337
  onPlay: this.handlePlay,
@@ -9163,16 +9392,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
9163
9392
 
9164
9393
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
9165
9394
 
9166
- 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); }; }
9167
-
9168
9395
  function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
9169
9396
 
9170
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
9171
-
9172
- 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; } }
9173
-
9174
9397
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
9175
9398
 
9399
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
9400
+
9176
9401
  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); }
9177
9402
 
9178
9403
  function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
@@ -9184,12 +9409,14 @@ var SUPPORTED_PROPS = Object.keys(props.propTypes);
9184
9409
  function createSinglePlayer(activePlayer) {
9185
9410
  var _class, _temp;
9186
9411
 
9187
- return _temp = _class = /*#__PURE__*/function (_Component) {
9412
+ return _temp = _class =
9413
+ /*#__PURE__*/
9414
+ function (_Component) {
9188
9415
  _inherits(SinglePlayer, _Component);
9189
9416
 
9190
- var _super = _createSuper(SinglePlayer);
9191
-
9192
9417
  function SinglePlayer() {
9418
+ var _getPrototypeOf2;
9419
+
9193
9420
  var _this;
9194
9421
 
9195
9422
  _classCallCheck(this, SinglePlayer);
@@ -9198,7 +9425,7 @@ function createSinglePlayer(activePlayer) {
9198
9425
  args[_key] = arguments[_key];
9199
9426
  }
9200
9427
 
9201
- _this = _super.call.apply(_super, [this].concat(args));
9428
+ _this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(SinglePlayer)).call.apply(_getPrototypeOf2, [this].concat(args)));
9202
9429
 
9203
9430
  _defineProperty(_assertThisInitialized(_this), "config", (0, utils.getConfig)(_this.props, props.defaultProps, true));
9204
9431
 
@@ -9266,12 +9493,12 @@ function createSinglePlayer(activePlayer) {
9266
9493
  height = _this$props.height,
9267
9494
  Wrapper = _this$props.wrapper;
9268
9495
  var otherProps = (0, utils.omit)(this.props, SUPPORTED_PROPS, props.DEPRECATED_CONFIG_PROPS);
9269
- return /*#__PURE__*/_react["default"].createElement(Wrapper, _extends({
9496
+ return _react["default"].createElement(Wrapper, _extends({
9270
9497
  style: _objectSpread({}, style, {
9271
9498
  width: width,
9272
9499
  height: height
9273
9500
  })
9274
- }, otherProps), /*#__PURE__*/_react["default"].createElement(_Player["default"], _extends({}, this.props, {
9501
+ }, otherProps), _react["default"].createElement(_Player["default"], _extends({}, this.props, {
9275
9502
  ref: this.ref,
9276
9503
  activePlayer: activePlayer,
9277
9504
  config: this.config
@@ -9317,31 +9544,23 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
9317
9544
 
9318
9545
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
9319
9546
 
9320
- 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); }; }
9321
-
9322
9547
  function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
9323
9548
 
9324
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
9325
-
9326
- 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; } }
9327
-
9328
9549
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
9329
9550
 
9551
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
9552
+
9330
9553
  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); }
9331
9554
 
9332
9555
  function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
9333
9556
 
9334
9557
  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; }
9335
9558
 
9336
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
9337
-
9338
- 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."); }
9339
-
9340
- 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); }
9559
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }
9341
9560
 
9342
- 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; }
9561
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); }
9343
9562
 
9344
- 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; }
9563
+ function _iterableToArrayLimit(arr, i) { if (!(Symbol.iterator in Object(arr) || Object.prototype.toString.call(arr) === "[object Arguments]")) { return; } var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
9345
9564
 
9346
9565
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
9347
9566
 
@@ -9366,12 +9585,14 @@ function parsePlaylist(url) {
9366
9585
  return {};
9367
9586
  }
9368
9587
 
9369
- var YouTube = /*#__PURE__*/function (_Component) {
9588
+ var YouTube =
9589
+ /*#__PURE__*/
9590
+ function (_Component) {
9370
9591
  _inherits(YouTube, _Component);
9371
9592
 
9372
- var _super = _createSuper(YouTube);
9373
-
9374
9593
  function YouTube() {
9594
+ var _getPrototypeOf2;
9595
+
9375
9596
  var _this;
9376
9597
 
9377
9598
  _classCallCheck(this, YouTube);
@@ -9380,7 +9601,7 @@ var YouTube = /*#__PURE__*/function (_Component) {
9380
9601
  args[_key] = arguments[_key];
9381
9602
  }
9382
9603
 
9383
- _this = _super.call.apply(_super, [this].concat(args));
9604
+ _this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(YouTube)).call.apply(_getPrototypeOf2, [this].concat(args)));
9384
9605
 
9385
9606
  _defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
9386
9607
 
@@ -9568,9 +9789,9 @@ var YouTube = /*#__PURE__*/function (_Component) {
9568
9789
  height: '100%',
9569
9790
  display: display
9570
9791
  };
9571
- return /*#__PURE__*/_react["default"].createElement("div", {
9792
+ return _react["default"].createElement("div", {
9572
9793
  style: style
9573
- }, /*#__PURE__*/_react["default"].createElement("div", {
9794
+ }, _react["default"].createElement("div", {
9574
9795
  ref: this.ref
9575
9796
  }));
9576
9797
  }
@@ -9626,16 +9847,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
9626
9847
 
9627
9848
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
9628
9849
 
9629
- 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); }; }
9630
-
9631
9850
  function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
9632
9851
 
9633
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
9634
-
9635
- 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; } }
9636
-
9637
9852
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
9638
9853
 
9854
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
9855
+
9639
9856
  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); }
9640
9857
 
9641
9858
  function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
@@ -9644,14 +9861,16 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
9644
9861
 
9645
9862
  var SDK_URL = 'https://w.soundcloud.com/player/api.js';
9646
9863
  var SDK_GLOBAL = 'SC';
9647
- var MATCH_URL = /(?:soundcloud\.com|snd\.sc)\/[^.]+$/;
9864
+ var MATCH_URL = /(soundcloud\.com|snd\.sc)\/.+$/;
9648
9865
 
9649
- var SoundCloud = /*#__PURE__*/function (_Component) {
9866
+ var SoundCloud =
9867
+ /*#__PURE__*/
9868
+ function (_Component) {
9650
9869
  _inherits(SoundCloud, _Component);
9651
9870
 
9652
- var _super = _createSuper(SoundCloud);
9653
-
9654
9871
  function SoundCloud() {
9872
+ var _getPrototypeOf2;
9873
+
9655
9874
  var _this;
9656
9875
 
9657
9876
  _classCallCheck(this, SoundCloud);
@@ -9660,7 +9879,7 @@ var SoundCloud = /*#__PURE__*/function (_Component) {
9660
9879
  args[_key] = arguments[_key];
9661
9880
  }
9662
9881
 
9663
- _this = _super.call.apply(_super, [this].concat(args));
9882
+ _this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(SoundCloud)).call.apply(_getPrototypeOf2, [this].concat(args)));
9664
9883
 
9665
9884
  _defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
9666
9885
 
@@ -9781,7 +10000,7 @@ var SoundCloud = /*#__PURE__*/function (_Component) {
9781
10000
  height: '100%',
9782
10001
  display: display
9783
10002
  };
9784
- return /*#__PURE__*/_react["default"].createElement("iframe", {
10003
+ return _react["default"].createElement("iframe", {
9785
10004
  ref: this.ref,
9786
10005
  src: "https://w.soundcloud.com/player/?url=".concat(encodeURIComponent(this.props.url)),
9787
10006
  style: style,
@@ -9843,16 +10062,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
9843
10062
 
9844
10063
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
9845
10064
 
9846
- 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); }; }
9847
-
9848
10065
  function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
9849
10066
 
9850
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
9851
-
9852
- 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; } }
9853
-
9854
10067
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
9855
10068
 
10069
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
10070
+
9856
10071
  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); }
9857
10072
 
9858
10073
  function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
@@ -9864,12 +10079,14 @@ var SDK_GLOBAL = 'Vimeo';
9864
10079
  var MATCH_URL = /vimeo\.com\/.+/;
9865
10080
  var MATCH_FILE_URL = /vimeo\.com\/external\/[0-9]+\..+/;
9866
10081
 
9867
- var Vimeo = /*#__PURE__*/function (_Component) {
10082
+ var Vimeo =
10083
+ /*#__PURE__*/
10084
+ function (_Component) {
9868
10085
  _inherits(Vimeo, _Component);
9869
10086
 
9870
- var _super = _createSuper(Vimeo);
9871
-
9872
10087
  function Vimeo() {
10088
+ var _getPrototypeOf2;
10089
+
9873
10090
  var _this;
9874
10091
 
9875
10092
  _classCallCheck(this, Vimeo);
@@ -9878,7 +10095,7 @@ var Vimeo = /*#__PURE__*/function (_Component) {
9878
10095
  args[_key] = arguments[_key];
9879
10096
  }
9880
10097
 
9881
- _this = _super.call.apply(_super, [this].concat(args));
10098
+ _this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Vimeo)).call.apply(_getPrototypeOf2, [this].concat(args)));
9882
10099
 
9883
10100
  _defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
9884
10101
 
@@ -10035,7 +10252,7 @@ var Vimeo = /*#__PURE__*/function (_Component) {
10035
10252
  overflow: 'hidden',
10036
10253
  display: display
10037
10254
  };
10038
- return /*#__PURE__*/_react["default"].createElement("div", {
10255
+ return _react["default"].createElement("div", {
10039
10256
  key: this.props.url,
10040
10257
  ref: this.ref,
10041
10258
  style: style
@@ -10095,16 +10312,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
10095
10312
 
10096
10313
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
10097
10314
 
10098
- 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); }; }
10099
-
10100
10315
  function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
10101
10316
 
10102
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
10103
-
10104
- 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; } }
10105
-
10106
10317
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
10107
10318
 
10319
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
10320
+
10108
10321
  function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
10109
10322
 
10110
10323
  function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
@@ -10117,12 +10330,14 @@ var SDK_GLOBAL_READY = 'fbAsyncInit';
10117
10330
  var MATCH_URL = /^https?:\/\/(www\.)?facebook\.com.*\/(video(s)?|watch|story)(\.php?|\/).+$/;
10118
10331
  var PLAYER_ID_PREFIX = 'facebook-player-';
10119
10332
 
10120
- var Facebook = /*#__PURE__*/function (_Component) {
10333
+ var Facebook =
10334
+ /*#__PURE__*/
10335
+ function (_Component) {
10121
10336
  _inherits(Facebook, _Component);
10122
10337
 
10123
- var _super = _createSuper(Facebook);
10124
-
10125
10338
  function Facebook() {
10339
+ var _getPrototypeOf2;
10340
+
10126
10341
  var _this;
10127
10342
 
10128
10343
  _classCallCheck(this, Facebook);
@@ -10131,7 +10346,7 @@ var Facebook = /*#__PURE__*/function (_Component) {
10131
10346
  args[_key] = arguments[_key];
10132
10347
  }
10133
10348
 
10134
- _this = _super.call.apply(_super, [this].concat(args));
10349
+ _this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Facebook)).call.apply(_getPrototypeOf2, [this].concat(args)));
10135
10350
 
10136
10351
  _defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
10137
10352
 
@@ -10247,7 +10462,7 @@ var Facebook = /*#__PURE__*/function (_Component) {
10247
10462
  width: '100%',
10248
10463
  height: '100%'
10249
10464
  };
10250
- return /*#__PURE__*/_react["default"].createElement("div", {
10465
+ return _react["default"].createElement("div", {
10251
10466
  style: style,
10252
10467
  id: this.playerID,
10253
10468
  className: "fb-video",
@@ -10307,16 +10522,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
10307
10522
 
10308
10523
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
10309
10524
 
10310
- 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); }; }
10311
-
10312
10525
  function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
10313
10526
 
10314
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
10315
-
10316
- 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; } }
10317
-
10318
10527
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
10319
10528
 
10529
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
10530
+
10320
10531
  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); }
10321
10532
 
10322
10533
  function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
@@ -10327,12 +10538,14 @@ var SDK_URL = 'https://cdn.embed.ly/player-0.1.0.min.js';
10327
10538
  var SDK_GLOBAL = 'playerjs';
10328
10539
  var MATCH_URL = /streamable\.com\/([a-z0-9]+)$/;
10329
10540
 
10330
- var Streamable = /*#__PURE__*/function (_Component) {
10541
+ var Streamable =
10542
+ /*#__PURE__*/
10543
+ function (_Component) {
10331
10544
  _inherits(Streamable, _Component);
10332
10545
 
10333
- var _super = _createSuper(Streamable);
10334
-
10335
10546
  function Streamable() {
10547
+ var _getPrototypeOf2;
10548
+
10336
10549
  var _this;
10337
10550
 
10338
10551
  _classCallCheck(this, Streamable);
@@ -10341,7 +10554,7 @@ var Streamable = /*#__PURE__*/function (_Component) {
10341
10554
  args[_key] = arguments[_key];
10342
10555
  }
10343
10556
 
10344
- _this = _super.call.apply(_super, [this].concat(args));
10557
+ _this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Streamable)).call.apply(_getPrototypeOf2, [this].concat(args)));
10345
10558
 
10346
10559
  _defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
10347
10560
 
@@ -10461,7 +10674,7 @@ var Streamable = /*#__PURE__*/function (_Component) {
10461
10674
  width: '100%',
10462
10675
  height: '100%'
10463
10676
  };
10464
- return /*#__PURE__*/_react["default"].createElement("iframe", {
10677
+ return _react["default"].createElement("iframe", {
10465
10678
  ref: this.ref,
10466
10679
  src: "https://streamable.com/o/".concat(id),
10467
10680
  frameBorder: "0",
@@ -10522,16 +10735,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
10522
10735
 
10523
10736
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
10524
10737
 
10525
- 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); }; }
10526
-
10527
10738
  function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
10528
10739
 
10529
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
10530
-
10531
- 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; } }
10532
-
10533
10740
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
10534
10741
 
10742
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
10743
+
10535
10744
  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); }
10536
10745
 
10537
10746
  function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
@@ -10542,48 +10751,26 @@ var SDK_URL = 'https://fast.wistia.com/assets/external/E-v1.js';
10542
10751
  var SDK_GLOBAL = 'Wistia';
10543
10752
  var MATCH_URL = /(?:wistia\.com|wi\.st)\/(?:medias|embed)\/(.*)$/;
10544
10753
 
10545
- var Wistia = /*#__PURE__*/function (_Component) {
10754
+ var Wistia =
10755
+ /*#__PURE__*/
10756
+ function (_Component) {
10546
10757
  _inherits(Wistia, _Component);
10547
10758
 
10548
- var _super = _createSuper(Wistia);
10549
-
10550
10759
  function Wistia() {
10760
+ var _getPrototypeOf2;
10761
+
10551
10762
  var _this;
10552
10763
 
10553
10764
  _classCallCheck(this, Wistia);
10554
10765
 
10555
- for (var _len = arguments.length, _args = new Array(_len), _key = 0; _key < _len; _key++) {
10556
- _args[_key] = arguments[_key];
10766
+ for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
10767
+ args[_key] = arguments[_key];
10557
10768
  }
10558
10769
 
10559
- _this = _super.call.apply(_super, [this].concat(_args));
10770
+ _this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Wistia)).call.apply(_getPrototypeOf2, [this].concat(args)));
10560
10771
 
10561
10772
  _defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
10562
10773
 
10563
- _defineProperty(_assertThisInitialized(_this), "onPlay", function () {
10564
- var _this$props;
10565
-
10566
- return (_this$props = _this.props).onPlay.apply(_this$props, arguments);
10567
- });
10568
-
10569
- _defineProperty(_assertThisInitialized(_this), "onPause", function () {
10570
- var _this$props2;
10571
-
10572
- return (_this$props2 = _this.props).onPause.apply(_this$props2, arguments);
10573
- });
10574
-
10575
- _defineProperty(_assertThisInitialized(_this), "onSeek", function () {
10576
- var _this$props3;
10577
-
10578
- return (_this$props3 = _this.props).onSeek.apply(_this$props3, arguments);
10579
- });
10580
-
10581
- _defineProperty(_assertThisInitialized(_this), "onEnded", function () {
10582
- var _this$props4;
10583
-
10584
- return (_this$props4 = _this.props).onEnded.apply(_this$props4, arguments);
10585
- });
10586
-
10587
10774
  _defineProperty(_assertThisInitialized(_this), "mute", function () {
10588
10775
  _this.callPlayer('mute');
10589
10776
  });
@@ -10605,13 +10792,17 @@ var Wistia = /*#__PURE__*/function (_Component) {
10605
10792
  value: function load(url) {
10606
10793
  var _this2 = this;
10607
10794
 
10608
- var _this$props5 = this.props,
10609
- playing = _this$props5.playing,
10610
- muted = _this$props5.muted,
10611
- controls = _this$props5.controls,
10612
- _onReady = _this$props5.onReady,
10613
- config = _this$props5.config,
10614
- onError = _this$props5.onError;
10795
+ var _this$props = this.props,
10796
+ playing = _this$props.playing,
10797
+ muted = _this$props.muted,
10798
+ controls = _this$props.controls,
10799
+ _onReady = _this$props.onReady,
10800
+ onPlay = _this$props.onPlay,
10801
+ onPause = _this$props.onPause,
10802
+ onSeek = _this$props.onSeek,
10803
+ onEnded = _this$props.onEnded,
10804
+ config = _this$props.config,
10805
+ onError = _this$props.onError;
10615
10806
  (0, utils.getSDK)(SDK_URL, SDK_GLOBAL).then(function () {
10616
10807
  window._wq = window._wq || [];
10617
10808
 
@@ -10628,28 +10819,19 @@ var Wistia = /*#__PURE__*/function (_Component) {
10628
10819
 
10629
10820
  _this2.unbind();
10630
10821
 
10631
- _this2.player.bind('play', _this2.onPlay);
10822
+ _this2.player.bind('play', onPlay);
10632
10823
 
10633
- _this2.player.bind('pause', _this2.onPause);
10824
+ _this2.player.bind('pause', onPause);
10634
10825
 
10635
- _this2.player.bind('seek', _this2.onSeek);
10826
+ _this2.player.bind('seek', onSeek);
10636
10827
 
10637
- _this2.player.bind('end', _this2.onEnded);
10828
+ _this2.player.bind('end', onEnded);
10638
10829
 
10639
10830
  _onReady();
10640
10831
  }
10641
10832
  });
10642
10833
  }, onError);
10643
10834
  }
10644
- }, {
10645
- key: "unbind",
10646
- value: function unbind() {
10647
- this.player.unbind('play', this.onPlay);
10648
- this.player.unbind('pause', this.onPause);
10649
- this.player.unbind('seek', this.onSeek);
10650
- this.player.unbind('end', this.onEnded);
10651
- } // Proxy methods to prevent listener leaks
10652
-
10653
10835
  }, {
10654
10836
  key: "play",
10655
10837
  value: function play() {
@@ -10660,6 +10842,19 @@ var Wistia = /*#__PURE__*/function (_Component) {
10660
10842
  value: function pause() {
10661
10843
  this.callPlayer('pause');
10662
10844
  }
10845
+ }, {
10846
+ key: "unbind",
10847
+ value: function unbind() {
10848
+ var _this$props2 = this.props,
10849
+ onPlay = _this$props2.onPlay,
10850
+ onPause = _this$props2.onPause,
10851
+ onSeek = _this$props2.onSeek,
10852
+ onEnded = _this$props2.onEnded;
10853
+ this.player.unbind('play', onPlay);
10854
+ this.player.unbind('pause', onPause);
10855
+ this.player.unbind('seek', onSeek);
10856
+ this.player.unbind('end', onEnded);
10857
+ }
10663
10858
  }, {
10664
10859
  key: "stop",
10665
10860
  value: function stop() {
@@ -10705,7 +10900,7 @@ var Wistia = /*#__PURE__*/function (_Component) {
10705
10900
  width: '100%',
10706
10901
  height: '100%'
10707
10902
  };
10708
- return /*#__PURE__*/_react["default"].createElement("div", {
10903
+ return _react["default"].createElement("div", {
10709
10904
  key: id,
10710
10905
  className: className,
10711
10906
  style: style
@@ -10765,16 +10960,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
10765
10960
 
10766
10961
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
10767
10962
 
10768
- 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); }; }
10769
-
10770
10963
  function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
10771
10964
 
10772
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
10773
-
10774
- 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; } }
10775
-
10776
10965
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
10777
10966
 
10967
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
10968
+
10778
10969
  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); }
10779
10970
 
10780
10971
  function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
@@ -10787,12 +10978,14 @@ var MATCH_VIDEO_URL = /(?:www\.|go\.)?twitch\.tv\/videos\/(\d+)($|\?)/;
10787
10978
  var MATCH_CHANNEL_URL = /(?:www\.|go\.)?twitch\.tv\/([a-z0-9_]+)($|\?)/;
10788
10979
  var PLAYER_ID_PREFIX = 'twitch-player-';
10789
10980
 
10790
- var Twitch = /*#__PURE__*/function (_Component) {
10981
+ var Twitch =
10982
+ /*#__PURE__*/
10983
+ function (_Component) {
10791
10984
  _inherits(Twitch, _Component);
10792
10985
 
10793
- var _super = _createSuper(Twitch);
10794
-
10795
10986
  function Twitch() {
10987
+ var _getPrototypeOf2;
10988
+
10796
10989
  var _this;
10797
10990
 
10798
10991
  _classCallCheck(this, Twitch);
@@ -10801,7 +10994,7 @@ var Twitch = /*#__PURE__*/function (_Component) {
10801
10994
  args[_key] = arguments[_key];
10802
10995
  }
10803
10996
 
10804
- _this = _super.call.apply(_super, [this].concat(args));
10997
+ _this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Twitch)).call.apply(_getPrototypeOf2, [this].concat(args)));
10805
10998
 
10806
10999
  _defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
10807
11000
 
@@ -10922,7 +11115,7 @@ var Twitch = /*#__PURE__*/function (_Component) {
10922
11115
  width: '100%',
10923
11116
  height: '100%'
10924
11117
  };
10925
- return /*#__PURE__*/_react["default"].createElement("div", {
11118
+ return _react["default"].createElement("div", {
10926
11119
  style: style,
10927
11120
  id: this.playerID
10928
11121
  });
@@ -10975,15 +11168,11 @@ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (O
10975
11168
 
10976
11169
  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; }
10977
11170
 
10978
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
10979
-
10980
- 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."); }
11171
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }
10981
11172
 
10982
- 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); }
11173
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); }
10983
11174
 
10984
- 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; }
10985
-
10986
- 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; }
11175
+ function _iterableToArrayLimit(arr, i) { if (!(Symbol.iterator in Object(arr) || Object.prototype.toString.call(arr) === "[object Arguments]")) { return; } var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
10987
11176
 
10988
11177
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
10989
11178
 
@@ -10993,16 +11182,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
10993
11182
 
10994
11183
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
10995
11184
 
10996
- 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); }; }
10997
-
10998
11185
  function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
10999
11186
 
11000
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
11001
-
11002
- 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; } }
11003
-
11004
11187
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
11005
11188
 
11189
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
11190
+
11006
11191
  function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
11007
11192
 
11008
11193
  function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
@@ -11014,12 +11199,14 @@ var SDK_GLOBAL = 'DM';
11014
11199
  var SDK_GLOBAL_READY = 'dmAsyncInit';
11015
11200
  var MATCH_URL = /^(?:(?:https?):)?(?:\/\/)?(?:www\.)?(?:(?:dailymotion\.com(?:\/embed)?\/video)|dai\.ly)\/([a-zA-Z0-9]+)(?:_[\w_-]+)?$/;
11016
11201
 
11017
- var DailyMotion = /*#__PURE__*/function (_Component) {
11202
+ var DailyMotion =
11203
+ /*#__PURE__*/
11204
+ function (_Component) {
11018
11205
  _inherits(DailyMotion, _Component);
11019
11206
 
11020
- var _super = _createSuper(DailyMotion);
11021
-
11022
11207
  function DailyMotion() {
11208
+ var _getPrototypeOf2;
11209
+
11023
11210
  var _this;
11024
11211
 
11025
11212
  _classCallCheck(this, DailyMotion);
@@ -11028,7 +11215,7 @@ var DailyMotion = /*#__PURE__*/function (_Component) {
11028
11215
  args[_key] = arguments[_key];
11029
11216
  }
11030
11217
 
11031
- _this = _super.call.apply(_super, [this].concat(args));
11218
+ _this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(DailyMotion)).call.apply(_getPrototypeOf2, [this].concat(args)));
11032
11219
 
11033
11220
  _defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
11034
11221
 
@@ -11157,9 +11344,9 @@ var DailyMotion = /*#__PURE__*/function (_Component) {
11157
11344
  height: '100%',
11158
11345
  display: display
11159
11346
  };
11160
- return /*#__PURE__*/_react["default"].createElement("div", {
11347
+ return _react["default"].createElement("div", {
11161
11348
  style: style
11162
- }, /*#__PURE__*/_react["default"].createElement("div", {
11349
+ }, _react["default"].createElement("div", {
11163
11350
  ref: this.ref
11164
11351
  }));
11165
11352
  }
@@ -11217,16 +11404,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
11217
11404
 
11218
11405
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
11219
11406
 
11220
- 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); }; }
11221
-
11222
11407
  function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
11223
11408
 
11224
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
11225
-
11226
- 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; } }
11227
-
11228
11409
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
11229
11410
 
11411
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
11412
+
11230
11413
  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); }
11231
11414
 
11232
11415
  function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
@@ -11237,12 +11420,14 @@ var SDK_URL = 'https://widget.mixcloud.com/media/js/widgetApi.js';
11237
11420
  var SDK_GLOBAL = 'Mixcloud';
11238
11421
  var MATCH_URL = /mixcloud\.com\/([^/]+\/[^/]+)/;
11239
11422
 
11240
- var Mixcloud = /*#__PURE__*/function (_Component) {
11423
+ var Mixcloud =
11424
+ /*#__PURE__*/
11425
+ function (_Component) {
11241
11426
  _inherits(Mixcloud, _Component);
11242
11427
 
11243
- var _super = _createSuper(Mixcloud);
11244
-
11245
11428
  function Mixcloud() {
11429
+ var _getPrototypeOf2;
11430
+
11246
11431
  var _this;
11247
11432
 
11248
11433
  _classCallCheck(this, Mixcloud);
@@ -11251,7 +11436,7 @@ var Mixcloud = /*#__PURE__*/function (_Component) {
11251
11436
  args[_key] = arguments[_key];
11252
11437
  }
11253
11438
 
11254
- _this = _super.call.apply(_super, [this].concat(args));
11439
+ _this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Mixcloud)).call.apply(_getPrototypeOf2, [this].concat(args)));
11255
11440
 
11256
11441
  _defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
11257
11442
 
@@ -11354,7 +11539,7 @@ var Mixcloud = /*#__PURE__*/function (_Component) {
11354
11539
  })); // We have to give the iframe a key here to prevent a
11355
11540
  // weird dialog appearing when loading a new track
11356
11541
 
11357
- return /*#__PURE__*/_react["default"].createElement("iframe", {
11542
+ return _react["default"].createElement("iframe", {
11358
11543
  key: id,
11359
11544
  ref: this.ref,
11360
11545
  style: style,
@@ -11414,33 +11599,23 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
11414
11599
 
11415
11600
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
11416
11601
 
11417
- 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); }; }
11418
-
11419
11602
  function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
11420
11603
 
11421
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
11422
-
11423
- 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; } }
11424
-
11425
11604
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
11426
11605
 
11606
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
11607
+
11427
11608
  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); }
11428
11609
 
11429
11610
  function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
11430
11611
 
11431
11612
  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; }
11432
11613
 
11433
- 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; } } }; }
11434
-
11435
- 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); }
11436
-
11437
- 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; }
11438
-
11439
11614
  var IOS = typeof navigator !== 'undefined' && /iPad|iPhone|iPod/.test(navigator.userAgent) && !window.MSStream;
11440
11615
  var AUDIO_EXTENSIONS = /\.(m4a|mp4a|mpga|mp2|mp2a|mp3|m2a|m3a|wav|weba|aac|oga|spx)($|\?)/i;
11441
11616
  var VIDEO_EXTENSIONS = /\.(mp4|og[gv]|webm|mov|m4v)($|\?)/i;
11442
11617
  var HLS_EXTENSIONS = /\.(m3u8)($|\?)/i;
11443
- var HLS_SDK_URL = 'https://cdn.jsdelivr.net/npm/hls.js@VERSION/dist/hls.min.js';
11618
+ var HLS_SDK_URL = 'https://cdn.jsdelivr.net/npm/hls.js@VERSION';
11444
11619
  var HLS_GLOBAL = 'Hls';
11445
11620
  var DASH_EXTENSIONS = /\.(mpd)($|\?)/i;
11446
11621
  var DASH_SDK_URL = 'https://cdnjs.cloudflare.com/ajax/libs/dashjs/VERSION/dash.all.min.js';
@@ -11449,11 +11624,12 @@ var MATCH_DROPBOX_URL = /www\.dropbox\.com\/.+/;
11449
11624
 
11450
11625
  function canPlay(url) {
11451
11626
  if (url instanceof Array) {
11452
- var _iterator = _createForOfIteratorHelper(url),
11453
- _step;
11627
+ var _iteratorNormalCompletion = true;
11628
+ var _didIteratorError = false;
11629
+ var _iteratorError = undefined;
11454
11630
 
11455
11631
  try {
11456
- for (_iterator.s(); !(_step = _iterator.n()).done;) {
11632
+ for (var _iterator = url[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
11457
11633
  var item = _step.value;
11458
11634
 
11459
11635
  if (typeof item === 'string' && canPlay(item)) {
@@ -11465,9 +11641,18 @@ function canPlay(url) {
11465
11641
  }
11466
11642
  }
11467
11643
  } catch (err) {
11468
- _iterator.e(err);
11644
+ _didIteratorError = true;
11645
+ _iteratorError = err;
11469
11646
  } finally {
11470
- _iterator.f();
11647
+ try {
11648
+ if (!_iteratorNormalCompletion && _iterator["return"] != null) {
11649
+ _iterator["return"]();
11650
+ }
11651
+ } finally {
11652
+ if (_didIteratorError) {
11653
+ throw _iteratorError;
11654
+ }
11655
+ }
11471
11656
  }
11472
11657
 
11473
11658
  return false;
@@ -11491,12 +11676,14 @@ function canEnablePIP(url) {
11491
11676
  return canPlay(url) && (!!document.pictureInPictureEnabled || supportsWebKitPresentationMode()) && !AUDIO_EXTENSIONS.test(url);
11492
11677
  }
11493
11678
 
11494
- var FilePlayer = /*#__PURE__*/function (_Component) {
11679
+ var FilePlayer =
11680
+ /*#__PURE__*/
11681
+ function (_Component) {
11495
11682
  _inherits(FilePlayer, _Component);
11496
11683
 
11497
- var _super = _createSuper(FilePlayer);
11498
-
11499
11684
  function FilePlayer() {
11685
+ var _getPrototypeOf2;
11686
+
11500
11687
  var _this;
11501
11688
 
11502
11689
  _classCallCheck(this, FilePlayer);
@@ -11505,7 +11692,7 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
11505
11692
  _args[_key] = arguments[_key];
11506
11693
  }
11507
11694
 
11508
- _this = _super.call.apply(_super, [this].concat(_args));
11695
+ _this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(FilePlayer)).call.apply(_getPrototypeOf2, [this].concat(_args)));
11509
11696
 
11510
11697
  _defineProperty(_assertThisInitialized(_this), "onReady", function () {
11511
11698
  var _this$props;
@@ -11592,19 +11779,19 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
11592
11779
 
11593
11780
  _defineProperty(_assertThisInitialized(_this), "renderSourceElement", function (source, index) {
11594
11781
  if (typeof source === 'string') {
11595
- return /*#__PURE__*/_react["default"].createElement("source", {
11782
+ return _react["default"].createElement("source", {
11596
11783
  key: index,
11597
11784
  src: source
11598
11785
  });
11599
11786
  }
11600
11787
 
11601
- return /*#__PURE__*/_react["default"].createElement("source", _extends({
11788
+ return _react["default"].createElement("source", _extends({
11602
11789
  key: index
11603
11790
  }, source));
11604
11791
  });
11605
11792
 
11606
11793
  _defineProperty(_assertThisInitialized(_this), "renderTrack", function (track, index) {
11607
- return /*#__PURE__*/_react["default"].createElement("track", _extends({
11794
+ return _react["default"].createElement("track", _extends({
11608
11795
  key: index
11609
11796
  }, track));
11610
11797
  });
@@ -11642,10 +11829,6 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
11642
11829
  key: "componentWillUnmount",
11643
11830
  value: function componentWillUnmount() {
11644
11831
  this.removeListeners(this.player);
11645
-
11646
- if (this.hls) {
11647
- this.hls.destroy();
11648
- }
11649
11832
  }
11650
11833
  }, {
11651
11834
  key: "addListeners",
@@ -11776,6 +11959,10 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
11776
11959
  value: function stop() {
11777
11960
  this.player.removeAttribute('src');
11778
11961
 
11962
+ if (this.hls) {
11963
+ this.hls.destroy();
11964
+ }
11965
+
11779
11966
  if (this.dash) {
11780
11967
  this.dash.reset();
11781
11968
  }
@@ -11887,7 +12074,7 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
11887
12074
  width: width === 'auto' ? width : '100%',
11888
12075
  height: height === 'auto' ? height : '100%'
11889
12076
  };
11890
- return /*#__PURE__*/_react["default"].createElement(Element, _extends({
12077
+ return _react["default"].createElement(Element, _extends({
11891
12078
  ref: this.ref,
11892
12079
  src: this.getSource(url),
11893
12080
  style: style,
@@ -11977,16 +12164,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
11977
12164
 
11978
12165
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
11979
12166
 
11980
- 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); }; }
11981
-
11982
12167
  function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
11983
12168
 
11984
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
11985
-
11986
- 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; } }
11987
-
11988
12169
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
11989
12170
 
12171
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
12172
+
11990
12173
  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); }
11991
12174
 
11992
12175
  function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
@@ -11995,12 +12178,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
11995
12178
 
11996
12179
  var ICON_SIZE = '64px';
11997
12180
 
11998
- var Preview = /*#__PURE__*/function (_Component) {
12181
+ var Preview =
12182
+ /*#__PURE__*/
12183
+ function (_Component) {
11999
12184
  _inherits(Preview, _Component);
12000
12185
 
12001
- var _super = _createSuper(Preview);
12002
-
12003
12186
  function Preview() {
12187
+ var _getPrototypeOf2;
12188
+
12004
12189
  var _this;
12005
12190
 
12006
12191
  _classCallCheck(this, Preview);
@@ -12009,7 +12194,7 @@ var Preview = /*#__PURE__*/function (_Component) {
12009
12194
  args[_key] = arguments[_key];
12010
12195
  }
12011
12196
 
12012
- _this = _super.call.apply(_super, [this].concat(args));
12197
+ _this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Preview)).call.apply(_getPrototypeOf2, [this].concat(args)));
12013
12198
 
12014
12199
  _defineProperty(_assertThisInitialized(_this), "mounted", false);
12015
12200
 
@@ -12107,15 +12292,15 @@ var Preview = /*#__PURE__*/function (_Component) {
12107
12292
  }
12108
12293
  };
12109
12294
 
12110
- var defaultPlayIcon = /*#__PURE__*/_react["default"].createElement("div", {
12295
+ var defaultPlayIcon = _react["default"].createElement("div", {
12111
12296
  style: styles.shadow,
12112
12297
  className: "react-player__shadow"
12113
- }, /*#__PURE__*/_react["default"].createElement("div", {
12298
+ }, _react["default"].createElement("div", {
12114
12299
  style: styles.playIcon,
12115
12300
  className: "react-player__play-icon"
12116
12301
  }));
12117
12302
 
12118
- return /*#__PURE__*/_react["default"].createElement("div", {
12303
+ return _react["default"].createElement("div", {
12119
12304
  style: styles.preview,
12120
12305
  className: "react-player__preview",
12121
12306
  onClick: onClick
@@ -12152,12 +12337,6 @@ var _Player = _interopRequireDefault(Player_1);
12152
12337
 
12153
12338
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
12154
12339
 
12155
- 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; } } }; }
12156
-
12157
- 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); }
12158
-
12159
- 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; }
12160
-
12161
12340
  var PRELOAD_PLAYERS = [{
12162
12341
  Player: YouTube_1.YouTube,
12163
12342
  configKey: 'youtube',
@@ -12178,16 +12357,16 @@ var PRELOAD_PLAYERS = [{
12178
12357
 
12179
12358
  function renderPreloadPlayers(url, controls, config) {
12180
12359
  var players = [];
12181
-
12182
- var _iterator = _createForOfIteratorHelper(PRELOAD_PLAYERS),
12183
- _step;
12360
+ var _iteratorNormalCompletion = true;
12361
+ var _didIteratorError = false;
12362
+ var _iteratorError = undefined;
12184
12363
 
12185
12364
  try {
12186
- for (_iterator.s(); !(_step = _iterator.n()).done;) {
12365
+ for (var _iterator = PRELOAD_PLAYERS[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
12187
12366
  var player = _step.value;
12188
12367
 
12189
12368
  if (!player.Player.canPlay(url) && config[player.configKey].preload) {
12190
- players.push( /*#__PURE__*/_react["default"].createElement(_Player["default"], {
12369
+ players.push(_react["default"].createElement(_Player["default"], {
12191
12370
  key: player.Player.displayName,
12192
12371
  activePlayer: player.Player,
12193
12372
  url: player.url,
@@ -12199,9 +12378,18 @@ function renderPreloadPlayers(url, controls, config) {
12199
12378
  }
12200
12379
  }
12201
12380
  } catch (err) {
12202
- _iterator.e(err);
12381
+ _didIteratorError = true;
12382
+ _iteratorError = err;
12203
12383
  } finally {
12204
- _iterator.f();
12384
+ try {
12385
+ if (!_iteratorNormalCompletion && _iterator["return"] != null) {
12386
+ _iterator["return"]();
12387
+ }
12388
+ } finally {
12389
+ if (_didIteratorError) {
12390
+ throw _iteratorError;
12391
+ }
12392
+ }
12205
12393
  }
12206
12394
 
12207
12395
  return players;
@@ -12325,17 +12513,13 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
12325
12513
 
12326
12514
  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); }
12327
12515
 
12328
- function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
12329
-
12330
- 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."); }
12331
-
12332
- 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); }
12516
+ function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _nonIterableSpread(); }
12333
12517
 
12334
- function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && Symbol.iterator in Object(iter)) return Array.from(iter); }
12518
+ function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance"); }
12335
12519
 
12336
- function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
12520
+ function _iterableToArray(iter) { if (Symbol.iterator in Object(iter) || Object.prototype.toString.call(iter) === "[object Arguments]") return Array.from(iter); }
12337
12521
 
12338
- 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; }
12522
+ function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = new Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } }
12339
12523
 
12340
12524
  function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
12341
12525
 
@@ -12343,16 +12527,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
12343
12527
 
12344
12528
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
12345
12529
 
12346
- 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); }; }
12347
-
12348
12530
  function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
12349
12531
 
12350
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
12351
-
12352
- 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; } }
12353
-
12354
12532
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
12355
12533
 
12534
+ function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
12535
+
12356
12536
  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); }
12357
12537
 
12358
12538
  function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
@@ -12362,12 +12542,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
12362
12542
  var SUPPORTED_PROPS = Object.keys(props.propTypes);
12363
12543
  var customPlayers = [];
12364
12544
 
12365
- var ReactPlayer = /*#__PURE__*/function (_Component) {
12545
+ var ReactPlayer =
12546
+ /*#__PURE__*/
12547
+ function (_Component) {
12366
12548
  _inherits(ReactPlayer, _Component);
12367
12549
 
12368
- var _super = _createSuper(ReactPlayer);
12369
-
12370
12550
  function ReactPlayer() {
12551
+ var _getPrototypeOf2;
12552
+
12371
12553
  var _this;
12372
12554
 
12373
12555
  _classCallCheck(this, ReactPlayer);
@@ -12376,7 +12558,7 @@ var ReactPlayer = /*#__PURE__*/function (_Component) {
12376
12558
  args[_key] = arguments[_key];
12377
12559
  }
12378
12560
 
12379
- _this = _super.call.apply(_super, [this].concat(args));
12561
+ _this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(ReactPlayer)).call.apply(_getPrototypeOf2, [this].concat(args)));
12380
12562
 
12381
12563
  _defineProperty(_assertThisInitialized(_this), "config", (0, utils.getConfig)(_this.props, props.defaultProps, true));
12382
12564
 
@@ -12487,7 +12669,7 @@ var ReactPlayer = /*#__PURE__*/function (_Component) {
12487
12669
  key: "renderActivePlayer",
12488
12670
  value: function renderActivePlayer(url, activePlayer) {
12489
12671
  if (!url) return null;
12490
- return /*#__PURE__*/_react["default"].createElement(_Player4["default"], _extends({}, this.props, {
12672
+ return _react["default"].createElement(_Player4["default"], _extends({}, this.props, {
12491
12673
  key: activePlayer.displayName,
12492
12674
  ref: this.activePlayerRef,
12493
12675
  config: this.config,
@@ -12524,14 +12706,14 @@ var ReactPlayer = /*#__PURE__*/function (_Component) {
12524
12706
  var preloadPlayers = (0, _preload["default"])(url, controls, this.config);
12525
12707
  var players = [renderedActivePlayer].concat(_toConsumableArray(preloadPlayers)).sort(this.sortPlayers);
12526
12708
 
12527
- var preview = /*#__PURE__*/_react["default"].createElement(_Preview["default"], {
12709
+ var preview = _react["default"].createElement(_Preview["default"], {
12528
12710
  url: url,
12529
12711
  light: light,
12530
12712
  playIcon: playIcon,
12531
12713
  onClick: this.handleClickPreview
12532
12714
  });
12533
12715
 
12534
- return /*#__PURE__*/_react["default"].createElement(Wrapper, _extends({
12716
+ return _react["default"].createElement(Wrapper, _extends({
12535
12717
  ref: this.wrapperRef,
12536
12718
  style: _objectSpread({}, style, {
12537
12719
  width: width,
@@ -12644,34 +12826,29 @@ var YouTubeGallery = function YouTubeGallery(_ref) {
12644
12826
  intervalID = _useState6[0],
12645
12827
  setIntervalID = _useState6[1];
12646
12828
 
12647
- var _useState7 = React.useState(null),
12648
- _useState8 = slicedToArray._slicedToArray(_useState7, 2),
12649
- segmentData = _useState8[0],
12650
- setSegemntData = _useState8[1];
12651
-
12652
12829
  var queueProgress = [];
12653
12830
 
12654
12831
  //state
12655
12832
 
12656
- var _useState9 = React.useState(''),
12833
+ var _useState7 = React.useState(''),
12834
+ _useState8 = slicedToArray._slicedToArray(_useState7, 2),
12835
+ vidUrl = _useState8[0],
12836
+ setVidUrl = _useState8[1];
12837
+
12838
+ var _useState9 = React.useState('youtube'),
12657
12839
  _useState10 = slicedToArray._slicedToArray(_useState9, 2),
12658
- vidUrl = _useState10[0],
12659
- setVidUrl = _useState10[1];
12840
+ vidType = _useState10[0],
12841
+ setVidType = _useState10[1];
12660
12842
 
12661
- var _useState11 = React.useState('youtube'),
12843
+ var _useState11 = React.useState(''),
12662
12844
  _useState12 = slicedToArray._slicedToArray(_useState11, 2),
12663
- vidType = _useState12[0],
12664
- setVidType = _useState12[1];
12845
+ series = _useState12[0],
12846
+ setSeries = _useState12[1];
12665
12847
 
12666
- var _useState13 = React.useState(''),
12848
+ var _useState13 = React.useState([]),
12667
12849
  _useState14 = slicedToArray._slicedToArray(_useState13, 2),
12668
- series = _useState14[0],
12669
- setSeries = _useState14[1];
12670
-
12671
- var _useState15 = React.useState([]),
12672
- _useState16 = slicedToArray._slicedToArray(_useState15, 2),
12673
- seriesData = _useState16[0],
12674
- setData = _useState16[1];
12850
+ seriesData = _useState14[0],
12851
+ setData = _useState14[1];
12675
12852
  //variables
12676
12853
 
12677
12854
 
@@ -12716,13 +12893,6 @@ var YouTubeGallery = function YouTubeGallery(_ref) {
12716
12893
  setData(data);
12717
12894
  }, []);
12718
12895
 
12719
- React.useEffect(function () {
12720
- if (segmentData) {
12721
- console.log('Video Segment', segmentData);
12722
- AdSlot.Beam.report_beam_video('Segment', main.main_16, segmentData.duration, segmentData.current, segmentData.segment);
12723
- }
12724
- }, [segmentData]);
12725
-
12726
12896
  function toggleSeries() {
12727
12897
  var series = document.querySelector('.vid-series');
12728
12898
  if (series.classList.contains('active')) {
@@ -12744,10 +12914,18 @@ var YouTubeGallery = function YouTubeGallery(_ref) {
12744
12914
  setSeries(vidIndex);
12745
12915
  }
12746
12916
 
12917
+ var handleOnReady = function handleOnReady(event) {
12918
+ var player = event.target;
12919
+ var current = player.getCurrentTime();
12920
+ var duration = player.getDuration();
12921
+ var queue = Math.floor(duration / 10);
12922
+ var segment = Math.floor(current / queue);
12923
+ AdSlot.Beam.report_beam_video('Ready', main.main_16, duration, current, segment);
12924
+ };
12925
+
12747
12926
  // Handle video end
12748
12927
  function handleOnEnd(e) {
12749
12928
  if (!endReported) {
12750
- console.log('Video End', e);
12751
12929
  var player = e.target;
12752
12930
  var current = player.getCurrentTime();
12753
12931
  var duration = player.getDuration();
@@ -12796,28 +12974,22 @@ var YouTubeGallery = function YouTubeGallery(_ref) {
12796
12974
  var segment = Math.floor(current / queue);
12797
12975
 
12798
12976
  if (!queueProgress.includes(segment)) {
12799
- setSegemntData({
12800
- current: current,
12801
- duration: duration,
12802
- queue: queue,
12803
- segment: segment
12804
- });
12977
+ AdSlot.Beam.report_beam_video('Segment', main.main_16, duration, current, segment);
12805
12978
  queueProgress.push(segment);
12806
12979
  }
12807
12980
  };
12808
12981
 
12809
12982
  var handleOnPlay = function handleOnPlay(event) {
12810
12983
  // report play
12811
- if (!playReported) {
12812
- console.log('Video Play', event);
12984
+ var player = event.target;
12985
+ var current = player.getCurrentTime();
12986
+ var duration = player.getDuration();
12987
+ var queue = Math.floor(duration / 10);
12988
+ var segment = Math.floor(current / queue);
12813
12989
 
12814
- var player = event.target;
12815
- var current = player.getCurrentTime();
12816
- var duration = player.getDuration();
12817
- var queue = Math.floor(duration / 10);
12818
- var segment = Math.floor(current / queue);
12990
+ AdSlot.Beam.report_beam_video('Play', main.main_16, duration, current, segment);
12819
12991
 
12820
- AdSlot.Beam.report_beam_video('Play', main.main_16, duration, current, segment);
12992
+ if (!playReported) {
12821
12993
  setPlayReported(true);
12822
12994
  var _intervalID = setInterval(function () {
12823
12995
  handlePlayPercent(event.target);
@@ -12827,7 +12999,6 @@ var YouTubeGallery = function YouTubeGallery(_ref) {
12827
12999
  };
12828
13000
 
12829
13001
  var handleOnPause = function handleOnPause(event) {
12830
- console.log('Video Pause');
12831
13002
  var player = event.target;
12832
13003
  var current = player.getCurrentTime();
12833
13004
  var duration = player.getDuration();
@@ -12851,7 +13022,7 @@ var YouTubeGallery = function YouTubeGallery(_ref) {
12851
13022
  React__default.createElement(
12852
13023
  'div',
12853
13024
  { className: 'video-block', style: { position: 'relative', overflow: 'hidden' } },
12854
- vidUrl && vidType == 'youtube' ? React__default.createElement(YouTube, { videoId: YoutubeGroup.getYoutubeId(vidUrl), opts: opts, onPlay: handleOnPlay, onPause: handleOnPause, onEnd: function onEnd(e) {
13025
+ vidUrl && vidType == 'youtube' ? React__default.createElement(YouTube, { videoId: YoutubeGroup.getYoutubeId(vidUrl), opts: opts, onReady: handleOnReady, onPlay: handleOnPlay, onPause: handleOnPause, onEnd: function onEnd(e) {
12855
13026
  return handleOnEnd(e);
12856
13027
  } }) : React__default.createElement(
12857
13028
  'video',
@@ -13849,16 +14020,16 @@ var RelatedTopicsDropdown = function RelatedTopicsDropdown(_ref) {
13849
14020
  _ref$className = _ref.className,
13850
14021
  className = _ref$className === undefined ? '' : _ref$className;
13851
14022
 
13852
- /*
13853
- Props accepted - parentTaxonomy(required, object), subTaxonomy(required, array), page(optional), exclude(optional), variant(optional), className(optional)
13854
- example:
13855
- <RelatedTopicDropdown
13856
- page='/clinical'
13857
- exclude="clinical"
13858
- className='mb-3'
13859
- parentTaxonomy={props.parentTaxonomy}
13860
- subTaxonomies={props.subTaxonomies}
13861
- />
14023
+ /*
14024
+ Props accepted - parentTaxonomy(required, object), subTaxonomy(required, array), page(optional), exclude(optional), variant(optional), className(optional)
14025
+ example:
14026
+ <RelatedTopicDropdown
14027
+ page='/clinical'
14028
+ exclude="clinical"
14029
+ className='mb-3'
14030
+ parentTaxonomy={props.parentTaxonomy}
14031
+ subTaxonomies={props.subTaxonomies}
14032
+ />
13862
14033
  */
13863
14034
  if (subTaxonomies.length === 0 && parentTaxonomy) {
13864
14035
  if (parentTaxonomy.identifier == exclude) {
@@ -13896,19 +14067,19 @@ var RelatedTopicsDropdown = function RelatedTopicsDropdown(_ref) {
13896
14067
  }
13897
14068
  };
13898
14069
 
13899
- /*
13900
- This dropdown is used inside Article body to display related content placement pages
13901
- sample usage: <ArticleDetailDropdown contentPlacement={content_placement} exclude={['News',]} />
13902
-
13903
- in article query, need to add '...' to content_placement to retreive additional info needed
13904
-
13905
- 'content_placement': taxonomyMapping[]-> {
13906
- ...,
13907
- 'ancestor': parent->parent->identifier,
13908
- 'parent': parent->identifier,
13909
- 'path': identifier
13910
- }
13911
-
14070
+ /*
14071
+ This dropdown is used inside Article body to display related content placement pages
14072
+ sample usage: <ArticleDetailDropdown contentPlacement={content_placement} exclude={['News',]} />
14073
+
14074
+ in article query, need to add '...' to content_placement to retreive additional info needed
14075
+
14076
+ 'content_placement': taxonomyMapping[]-> {
14077
+ ...,
14078
+ 'ancestor': parent->parent->identifier,
14079
+ 'parent': parent->identifier,
14080
+ 'path': identifier
14081
+ }
14082
+
13912
14083
  */
13913
14084
 
13914
14085
  var ArticleDetailDropdown = function ArticleDetailDropdown(props) {
@@ -14741,34 +14912,34 @@ var GridHero = function GridHero(props) {
14741
14912
  );
14742
14913
  };
14743
14914
 
14744
- /*
14745
- Sample query
14746
- let references = ''
14747
- if(article.taxonomyMapping.length > 0){
14748
- article.taxonomyMapping.forEach((ref, index) => {
14749
- references = references + `references('${ref._ref}') `
14750
- if(index+1 !== article.taxonomyMapping.length){
14751
- references = references + ` && `
14752
- }
14753
- })
14754
- }
14755
-
14756
- const relatedArticlesQuery = `*[!(_id in path("drafts.**")) && _type == "article" && title !='${article.title}' && defined(title) && is_visible == true && ( references('article.documentGroup._id') || ${references} ) && published <= '${today}'] | order(published desc) [0...4] {
14757
- ...,
14758
- title,
14759
- summary,
14760
- thumbnail,
14761
- url,
14762
- published,
14763
- authorMapping[]->,
14764
- contentCategory->
14765
- }`
14766
- const relatedArticles = await client.fetch(relatedArticlesQuery)
14767
-
14768
- Sample usage
14769
- <RelatedContent dataRecord={props.relatedArticles} client={client} showAuthor showPublished reverse/>
14770
-
14771
-
14915
+ /*
14916
+ Sample query
14917
+ let references = ''
14918
+ if(article.taxonomyMapping.length > 0){
14919
+ article.taxonomyMapping.forEach((ref, index) => {
14920
+ references = references + `references('${ref._ref}') `
14921
+ if(index+1 !== article.taxonomyMapping.length){
14922
+ references = references + ` && `
14923
+ }
14924
+ })
14925
+ }
14926
+
14927
+ const relatedArticlesQuery = `*[!(_id in path("drafts.**")) && _type == "article" && title !='${article.title}' && defined(title) && is_visible == true && ( references('article.documentGroup._id') || ${references} ) && published <= '${today}'] | order(published desc) [0...4] {
14928
+ ...,
14929
+ title,
14930
+ summary,
14931
+ thumbnail,
14932
+ url,
14933
+ published,
14934
+ authorMapping[]->,
14935
+ contentCategory->
14936
+ }`
14937
+ const relatedArticles = await client.fetch(relatedArticlesQuery)
14938
+
14939
+ Sample usage
14940
+ <RelatedContent dataRecord={props.relatedArticles} client={client} showAuthor showPublished reverse/>
14941
+
14942
+
14772
14943
  */
14773
14944
  var RelatedContent = function RelatedContent(props) {
14774
14945
  var client = props.client,
@@ -14835,21 +15006,21 @@ var RelatedContent = function RelatedContent(props) {
14835
15006
  );
14836
15007
  };
14837
15008
 
14838
- /*
14839
- Example usage - targetedonc.com/latest-conference
14840
- const query = `*[!(_id in path("drafts.**")) && _type == "article" && defined(title) && is_visible == true && published <= '${today}' && references('b49d36b8-aa56-4183-a2bc-1568c229fb72') ] | order(published desc) [$from...$to] {
14841
- ...,
14842
- title,
14843
- summary,
14844
- thumbnail,
14845
- url,
14846
- published,
14847
- documentGroup->,
14848
- contentCategory->,
14849
- 'pageNumber': ${currentPage}
14850
- }`
14851
-
14852
- const posts = await client.fetch(query, params)
15009
+ /*
15010
+ Example usage - targetedonc.com/latest-conference
15011
+ const query = `*[!(_id in path("drafts.**")) && _type == "article" && defined(title) && is_visible == true && published <= '${today}' && references('b49d36b8-aa56-4183-a2bc-1568c229fb72') ] | order(published desc) [$from...$to] {
15012
+ ...,
15013
+ title,
15014
+ summary,
15015
+ thumbnail,
15016
+ url,
15017
+ published,
15018
+ documentGroup->,
15019
+ contentCategory->,
15020
+ 'pageNumber': ${currentPage}
15021
+ }`
15022
+
15023
+ const posts = await client.fetch(query, params)
14853
15024
  */
14854
15025
 
14855
15026
  var ConferenceArticleCard = function ConferenceArticleCard(props) {
@@ -15476,27 +15647,27 @@ var _initialiseProps = function _initialiseProps() {
15476
15647
  };
15477
15648
 
15478
15649
  var KMTracker = function KMTracker(props) {
15479
- var id = props.id;
15650
+ var id = props.id;
15480
15651
 
15481
- if (document) {
15652
+ if (document && id) {
15482
15653
  (function () {
15483
- var ecnJquery = document.createElement('script');
15654
+ var ecnJquery = document.createElement('script');
15484
15655
 
15485
- ecnJquery.type = 'text/javascript';
15486
- ecnJquery.async = true;
15487
- ecnJquery.src = 'https://apidt.ecn5.com/ECN_jQuery.min.js';
15656
+ ecnJquery.type = 'text/javascript';
15657
+ ecnJquery.async = true;
15658
+ ecnJquery.src = 'https://apidt.ecn5.com/ECN_jQuery.min.js';
15488
15659
 
15489
- var ecnScript = document.createElement('script');
15660
+ var ecnScript = document.createElement('script');
15490
15661
 
15491
- ecnScript.type = 'text/javascript';
15492
- ecnScript.async = true;
15493
- ecnScript.id = 'km-tracker';
15494
- ecnScript.src = 'https://apidt.ecn5.com/ECN_tracker_Secure.js?TrackerKey=' + id;
15662
+ ecnScript.type = 'text/javascript';
15663
+ ecnScript.async = true;
15664
+ ecnScript.id = 'km-tracker';
15665
+ ecnScript.src = 'https://apidt.ecn5.com/ECN_tracker_Secure.js?TrackerKey=' + id;
15495
15666
 
15496
- document.head.appendChild(ecnJquery);
15497
- document.head.appendChild(ecnScript);
15498
- })();
15499
- }
15667
+ document.head.appendChild(ecnJquery);
15668
+ document.head.appendChild(ecnScript);
15669
+ })();
15670
+ }
15500
15671
  };
15501
15672
 
15502
15673
  exports.AdSlot = AdSlot.DFPAdSlot;
@@ -15533,7 +15704,10 @@ exports.TemplateNormal = TemplateNormal.TemplateNormal;
15533
15704
  exports.Ustream = Ustream.Ustream;
15534
15705
  exports.AD300x250 = AD300x250;
15535
15706
  exports.AD300x250x600 = AD300x250x600;
15707
+ exports.ADFloatingFooter = ADFloatingFooter;
15536
15708
  exports.ADFooter = ADFooter;
15709
+ exports.ADGutter = ADGutter;
15710
+ exports.ADWelcome = ADWelcome;
15537
15711
  exports.AccordionPanel = AccordionPanel;
15538
15712
  exports.AdSlotsProvider = AdSlotsProvider;
15539
15713
  exports.AlphabeticList = AlphabeticList;