@mjhls/mjh-framework 1.0.245 → 1.0.246
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +171 -171
- package/dist/cjs/DeckContent.js +9 -9
- package/dist/cjs/DeckQueue.js +1 -1
- package/dist/cjs/{GridContent-f9e3fff5.js → GridContent-463c504f.js} +2 -2
- package/dist/cjs/GridContent.js +2 -2
- package/dist/cjs/IssueContentDeck.js +1 -1
- package/dist/cjs/IssueDeck.js +1 -1
- package/dist/cjs/MasterDeck.js +9 -9
- package/dist/cjs/{Normal-0497eb61.js → Normal-18cef899.js} +31 -31
- package/dist/cjs/PublicationDeck.js +1 -1
- package/dist/cjs/QueueDeckExpanded.js +1 -1
- package/dist/cjs/{TaxonomyCard-b5074d6e.js → TaxonomyCard-e3566492.js} +1 -1
- package/dist/cjs/TaxonomyCard.js +2 -2
- package/dist/cjs/TemplateNormal.js +1 -1
- package/dist/cjs/ThumbnailCard.js +1 -1
- package/dist/cjs/VideoSeriesListing.js +1 -1
- package/dist/cjs/{YoutubeGroup-fd44f8a0.js → YoutubeGroup-5f480446.js} +4 -4
- package/dist/cjs/YoutubeGroup.js +1 -1
- package/dist/cjs/{index-39beccb3.js → index-be0c82be.js} +1 -2
- package/dist/cjs/index.js +514 -526
- package/dist/esm/DeckContent.js +9 -9
- package/dist/esm/DeckQueue.js +1 -1
- package/dist/esm/{GridContent-d4f5457e.js → GridContent-2a48fb19.js} +1 -1
- package/dist/esm/GridContent.js +2 -2
- package/dist/esm/IssueContentDeck.js +1 -1
- package/dist/esm/IssueDeck.js +1 -1
- package/dist/esm/MasterDeck.js +9 -9
- package/dist/esm/{Normal-e1855047.js → Normal-4c82c9c2.js} +31 -31
- package/dist/esm/PublicationDeck.js +1 -1
- package/dist/esm/QueueDeckExpanded.js +1 -1
- package/dist/esm/{TaxonomyCard-ee1a22ae.js → TaxonomyCard-2d0ab635.js} +1 -1
- package/dist/esm/TaxonomyCard.js +2 -2
- package/dist/esm/TemplateNormal.js +1 -1
- package/dist/esm/ThumbnailCard.js +1 -1
- package/dist/esm/VideoSeriesListing.js +1 -1
- package/dist/esm/{YoutubeGroup-1b3eca73.js → YoutubeGroup-78d93d44.js} +4 -4
- package/dist/esm/YoutubeGroup.js +1 -1
- package/dist/esm/{index-3849e3fe.js → index-73819142.js} +1 -2
- package/dist/esm/index.js +517 -529
- package/package.json +103 -103
package/dist/cjs/index.js
CHANGED
|
@@ -26,7 +26,7 @@ var Link = _interopDefault(require('next/link'));
|
|
|
26
26
|
var Router = require('next/router');
|
|
27
27
|
var Router__default = _interopDefault(Router);
|
|
28
28
|
require('react-dom');
|
|
29
|
-
var index$1 = require('./index-
|
|
29
|
+
var index$1 = require('./index-be0c82be.js');
|
|
30
30
|
require('./index-fa0fb52c.js');
|
|
31
31
|
var entities = require('./entities-310b46ee.js');
|
|
32
32
|
var slicedToArray = require('./slicedToArray-e38fb29d.js');
|
|
@@ -34,13 +34,13 @@ var AdSlot = require('./AdSlot-c472fff6.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-
|
|
37
|
+
var GridContent = require('./GridContent-463c504f.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-
|
|
41
|
+
var TaxonomyCard = require('./TaxonomyCard-e3566492.js');
|
|
42
42
|
var GroupDeck = require('./GroupDeck.js');
|
|
43
|
-
var YoutubeGroup = require('./YoutubeGroup-
|
|
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-
|
|
55
|
+
var TemplateNormal = require('./Normal-18cef899.js');
|
|
56
56
|
require('react-bootstrap/ListGroup');
|
|
57
57
|
var Head = _interopDefault(require('next/head'));
|
|
58
58
|
var Accordion = _interopDefault(require('react-bootstrap/Accordion'));
|
|
@@ -3046,18 +3046,21 @@ var Slideshow = function Slideshow(_ref) {
|
|
|
3046
3046
|
);
|
|
3047
3047
|
};
|
|
3048
3048
|
|
|
3049
|
-
|
|
3050
|
-
|
|
3051
|
-
|
|
3049
|
+
var isArray = Array.isArray;
|
|
3050
|
+
var keyList = Object.keys;
|
|
3051
|
+
var hasProp = Object.prototype.hasOwnProperty;
|
|
3052
3052
|
|
|
3053
3053
|
var fastDeepEqual = function equal(a, b) {
|
|
3054
3054
|
if (a === b) return true;
|
|
3055
3055
|
|
|
3056
3056
|
if (a && b && typeof a == 'object' && typeof b == 'object') {
|
|
3057
|
-
|
|
3057
|
+
var arrA = isArray(a)
|
|
3058
|
+
, arrB = isArray(b)
|
|
3059
|
+
, i
|
|
3060
|
+
, length
|
|
3061
|
+
, key;
|
|
3058
3062
|
|
|
3059
|
-
|
|
3060
|
-
if (Array.isArray(a)) {
|
|
3063
|
+
if (arrA && arrB) {
|
|
3061
3064
|
length = a.length;
|
|
3062
3065
|
if (length != b.length) return false;
|
|
3063
3066
|
for (i = length; i-- !== 0;)
|
|
@@ -3065,29 +3068,35 @@ var fastDeepEqual = function equal(a, b) {
|
|
|
3065
3068
|
return true;
|
|
3066
3069
|
}
|
|
3067
3070
|
|
|
3071
|
+
if (arrA != arrB) return false;
|
|
3068
3072
|
|
|
3073
|
+
var dateA = a instanceof Date
|
|
3074
|
+
, dateB = b instanceof Date;
|
|
3075
|
+
if (dateA != dateB) return false;
|
|
3076
|
+
if (dateA && dateB) return a.getTime() == b.getTime();
|
|
3069
3077
|
|
|
3070
|
-
|
|
3071
|
-
|
|
3072
|
-
if (
|
|
3078
|
+
var regexpA = a instanceof RegExp
|
|
3079
|
+
, regexpB = b instanceof RegExp;
|
|
3080
|
+
if (regexpA != regexpB) return false;
|
|
3081
|
+
if (regexpA && regexpB) return a.toString() == b.toString();
|
|
3073
3082
|
|
|
3074
|
-
keys =
|
|
3083
|
+
var keys = keyList(a);
|
|
3075
3084
|
length = keys.length;
|
|
3076
|
-
|
|
3085
|
+
|
|
3086
|
+
if (length !== keyList(b).length)
|
|
3087
|
+
return false;
|
|
3077
3088
|
|
|
3078
3089
|
for (i = length; i-- !== 0;)
|
|
3079
|
-
if (!
|
|
3090
|
+
if (!hasProp.call(b, keys[i])) return false;
|
|
3080
3091
|
|
|
3081
3092
|
for (i = length; i-- !== 0;) {
|
|
3082
|
-
|
|
3083
|
-
|
|
3093
|
+
key = keys[i];
|
|
3084
3094
|
if (!equal(a[key], b[key])) return false;
|
|
3085
3095
|
}
|
|
3086
3096
|
|
|
3087
3097
|
return true;
|
|
3088
3098
|
}
|
|
3089
3099
|
|
|
3090
|
-
// true if both NaN, false otherwise
|
|
3091
3100
|
return a!==a && b!==b;
|
|
3092
3101
|
};
|
|
3093
3102
|
|
|
@@ -4110,7 +4119,7 @@ function formatValue(ctx, value, recurseTimes) {
|
|
|
4110
4119
|
var base = '', array = false, braces = ['{', '}'];
|
|
4111
4120
|
|
|
4112
4121
|
// Make Array say that they are Array
|
|
4113
|
-
if (isArray(value)) {
|
|
4122
|
+
if (isArray$1(value)) {
|
|
4114
4123
|
array = true;
|
|
4115
4124
|
braces = ['[', ']'];
|
|
4116
4125
|
}
|
|
@@ -4289,7 +4298,7 @@ function reduceToSingleString(output, base, braces) {
|
|
|
4289
4298
|
|
|
4290
4299
|
// NOTE: These type checking functions intentionally don't use `instanceof`
|
|
4291
4300
|
// because it is fragile and can be easily faked with `Object.create()`.
|
|
4292
|
-
function isArray(ar) {
|
|
4301
|
+
function isArray$1(ar) {
|
|
4293
4302
|
return Array.isArray(ar);
|
|
4294
4303
|
}
|
|
4295
4304
|
|
|
@@ -4416,7 +4425,7 @@ var util = {
|
|
|
4416
4425
|
isNullOrUndefined: isNullOrUndefined,
|
|
4417
4426
|
isNull: isNull,
|
|
4418
4427
|
isBoolean: isBoolean,
|
|
4419
|
-
isArray: isArray,
|
|
4428
|
+
isArray: isArray$1,
|
|
4420
4429
|
inspect: inspect,
|
|
4421
4430
|
deprecate: deprecate,
|
|
4422
4431
|
format: format,
|
|
@@ -5083,235 +5092,199 @@ module.exports = exports['default'];
|
|
|
5083
5092
|
|
|
5084
5093
|
var youTubePlayer = _commonjsHelpers.unwrapExports(dist);
|
|
5085
5094
|
|
|
5086
|
-
function
|
|
5095
|
+
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; }; }();
|
|
5087
5096
|
|
|
5088
|
-
function
|
|
5097
|
+
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; };
|
|
5089
5098
|
|
|
5090
|
-
function
|
|
5091
|
-
|
|
5092
|
-
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
5093
|
-
|
|
5094
|
-
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); }; }
|
|
5095
|
-
|
|
5096
|
-
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
5097
|
-
|
|
5098
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
5099
|
-
|
|
5100
|
-
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; } }
|
|
5101
|
-
|
|
5102
|
-
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
5103
|
-
|
|
5104
|
-
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); }
|
|
5105
|
-
|
|
5106
|
-
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
5099
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
5107
5100
|
|
|
5108
|
-
function
|
|
5101
|
+
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; }
|
|
5109
5102
|
|
|
5110
|
-
function
|
|
5103
|
+
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; }
|
|
5111
5104
|
|
|
5112
|
-
|
|
5113
|
-
|
|
5114
|
-
*
|
|
5115
|
-
*
|
|
5116
|
-
* @param {Object}
|
|
5117
|
-
* @param {Object} props
|
|
5105
|
+
/**
|
|
5106
|
+
* Check whether a `props` change should result in the video being updated.
|
|
5107
|
+
*
|
|
5108
|
+
* @param {Object} prevProps
|
|
5109
|
+
* @param {Object} props
|
|
5118
5110
|
*/
|
|
5119
|
-
|
|
5120
5111
|
function shouldUpdateVideo(prevProps, props) {
|
|
5121
5112
|
// A changing video should always trigger an update
|
|
5122
5113
|
if (prevProps.videoId !== props.videoId) {
|
|
5123
5114
|
return true;
|
|
5124
|
-
}
|
|
5125
|
-
// update.
|
|
5126
|
-
|
|
5115
|
+
}
|
|
5127
5116
|
|
|
5117
|
+
// Otherwise, a change in the start/end time playerVars also requires a player
|
|
5118
|
+
// update.
|
|
5128
5119
|
var prevVars = prevProps.opts.playerVars || {};
|
|
5129
5120
|
var vars = props.opts.playerVars || {};
|
|
5121
|
+
|
|
5130
5122
|
return prevVars.start !== vars.start || prevVars.end !== vars.end;
|
|
5131
5123
|
}
|
|
5132
|
-
/**
|
|
5133
|
-
* Neutralize API options that only require a video update, leaving only options
|
|
5134
|
-
* that require a player reset. The results can then be compared to see if a
|
|
5135
|
-
* player reset is necessary.
|
|
5136
|
-
*
|
|
5137
|
-
* @param {Object} opts
|
|
5138
|
-
*/
|
|
5139
|
-
|
|
5140
5124
|
|
|
5125
|
+
/**
|
|
5126
|
+
* Neutralise API options that only require a video update, leaving only options
|
|
5127
|
+
* that require a player reset. The results can then be compared to see if a
|
|
5128
|
+
* player reset is necessary.
|
|
5129
|
+
*
|
|
5130
|
+
* @param {Object} opts
|
|
5131
|
+
*/
|
|
5141
5132
|
function filterResetOptions(opts) {
|
|
5142
|
-
return
|
|
5143
|
-
playerVars:
|
|
5133
|
+
return _extends({}, opts, {
|
|
5134
|
+
playerVars: _extends({}, opts.playerVars, {
|
|
5144
5135
|
autoplay: 0,
|
|
5145
5136
|
start: 0,
|
|
5146
5137
|
end: 0
|
|
5147
5138
|
})
|
|
5148
5139
|
});
|
|
5149
5140
|
}
|
|
5150
|
-
/**
|
|
5151
|
-
* Check whether a `props` change should result in the player being reset.
|
|
5152
|
-
* The player is reset when the `props.opts` change, except if the only change
|
|
5153
|
-
* is in the `start` and `end` playerVars, because a video update can deal with
|
|
5154
|
-
* those.
|
|
5155
|
-
*
|
|
5156
|
-
* @param {Object} prevProps
|
|
5157
|
-
* @param {Object} props
|
|
5158
|
-
*/
|
|
5159
|
-
|
|
5160
5141
|
|
|
5142
|
+
/**
|
|
5143
|
+
* Check whether a `props` change should result in the player being reset.
|
|
5144
|
+
* The player is reset when the `props.opts` change, except if the only change
|
|
5145
|
+
* is in the `start` and `end` playerVars, because a video update can deal with
|
|
5146
|
+
* those.
|
|
5147
|
+
*
|
|
5148
|
+
* @param {Object} prevProps
|
|
5149
|
+
* @param {Object} props
|
|
5150
|
+
*/
|
|
5161
5151
|
function shouldResetPlayer(prevProps, props) {
|
|
5162
5152
|
return !fastDeepEqual(filterResetOptions(prevProps.opts), filterResetOptions(props.opts));
|
|
5163
5153
|
}
|
|
5164
|
-
/**
|
|
5165
|
-
* Check whether a props change should result in an id or className update.
|
|
5166
|
-
*
|
|
5167
|
-
* @param {Object} prevProps
|
|
5168
|
-
* @param {Object} props
|
|
5169
|
-
*/
|
|
5170
|
-
|
|
5171
5154
|
|
|
5155
|
+
/**
|
|
5156
|
+
* Check whether a props change should result in an id or className update.
|
|
5157
|
+
*
|
|
5158
|
+
* @param {Object} prevProps
|
|
5159
|
+
* @param {Object} props
|
|
5160
|
+
*/
|
|
5172
5161
|
function shouldUpdatePlayer(prevProps, props) {
|
|
5173
5162
|
return prevProps.id !== props.id || prevProps.className !== props.className;
|
|
5174
5163
|
}
|
|
5175
5164
|
|
|
5176
|
-
var YouTube =
|
|
5165
|
+
var YouTube = function (_React$Component) {
|
|
5177
5166
|
_inherits(YouTube, _React$Component);
|
|
5178
5167
|
|
|
5179
|
-
var _super = _createSuper(YouTube);
|
|
5180
|
-
|
|
5181
|
-
/**
|
|
5182
|
-
* Expose PlayerState constants for convenience. These constants can also be
|
|
5183
|
-
* accessed through the global YT object after the YouTube IFrame API is instantiated.
|
|
5184
|
-
* https://developers.google.com/youtube/iframe_api_reference#onStateChange
|
|
5185
|
-
*/
|
|
5186
5168
|
function YouTube(props) {
|
|
5187
|
-
var _this;
|
|
5188
|
-
|
|
5189
5169
|
_classCallCheck(this, YouTube);
|
|
5190
5170
|
|
|
5191
|
-
_this =
|
|
5171
|
+
var _this = _possibleConstructorReturn(this, (YouTube.__proto__ || Object.getPrototypeOf(YouTube)).call(this, props));
|
|
5192
5172
|
|
|
5193
|
-
|
|
5173
|
+
_this.onPlayerReady = function (event) {
|
|
5194
5174
|
return _this.props.onReady(event);
|
|
5195
|
-
}
|
|
5175
|
+
};
|
|
5196
5176
|
|
|
5197
|
-
|
|
5177
|
+
_this.onPlayerError = function (event) {
|
|
5198
5178
|
return _this.props.onError(event);
|
|
5199
|
-
}
|
|
5179
|
+
};
|
|
5200
5180
|
|
|
5201
|
-
|
|
5181
|
+
_this.onPlayerStateChange = function (event) {
|
|
5202
5182
|
_this.props.onStateChange(event);
|
|
5203
|
-
|
|
5204
5183
|
switch (event.data) {
|
|
5184
|
+
|
|
5205
5185
|
case YouTube.PlayerState.ENDED:
|
|
5206
5186
|
_this.props.onEnd(event);
|
|
5207
|
-
|
|
5208
5187
|
break;
|
|
5209
5188
|
|
|
5210
5189
|
case YouTube.PlayerState.PLAYING:
|
|
5211
5190
|
_this.props.onPlay(event);
|
|
5212
|
-
|
|
5213
5191
|
break;
|
|
5214
5192
|
|
|
5215
5193
|
case YouTube.PlayerState.PAUSED:
|
|
5216
5194
|
_this.props.onPause(event);
|
|
5217
|
-
|
|
5218
5195
|
break;
|
|
5219
5196
|
}
|
|
5220
|
-
}
|
|
5197
|
+
};
|
|
5221
5198
|
|
|
5222
|
-
|
|
5199
|
+
_this.onPlayerPlaybackRateChange = function (event) {
|
|
5223
5200
|
return _this.props.onPlaybackRateChange(event);
|
|
5224
|
-
}
|
|
5201
|
+
};
|
|
5225
5202
|
|
|
5226
|
-
|
|
5203
|
+
_this.onPlayerPlaybackQualityChange = function (event) {
|
|
5227
5204
|
return _this.props.onPlaybackQualityChange(event);
|
|
5228
|
-
}
|
|
5205
|
+
};
|
|
5229
5206
|
|
|
5230
|
-
|
|
5207
|
+
_this.createPlayer = function () {
|
|
5231
5208
|
// do not attempt to create a player server-side, it won't work
|
|
5232
|
-
if (typeof document === 'undefined') return;
|
|
5233
|
-
|
|
5234
|
-
var playerOpts =
|
|
5209
|
+
if (typeof document === 'undefined') return;
|
|
5210
|
+
// create player
|
|
5211
|
+
var playerOpts = _extends({}, _this.props.opts, {
|
|
5235
5212
|
// preload the `videoId` video if one is already given
|
|
5236
5213
|
videoId: _this.props.videoId
|
|
5237
5214
|
});
|
|
5238
|
-
|
|
5239
|
-
|
|
5240
|
-
|
|
5215
|
+
_this.internalPlayer = youTubePlayer(_this.container, playerOpts);
|
|
5216
|
+
// attach event handlers
|
|
5241
5217
|
_this.internalPlayer.on('ready', _this.onPlayerReady);
|
|
5242
|
-
|
|
5243
5218
|
_this.internalPlayer.on('error', _this.onPlayerError);
|
|
5244
|
-
|
|
5245
5219
|
_this.internalPlayer.on('stateChange', _this.onPlayerStateChange);
|
|
5246
|
-
|
|
5247
5220
|
_this.internalPlayer.on('playbackRateChange', _this.onPlayerPlaybackRateChange);
|
|
5248
|
-
|
|
5249
5221
|
_this.internalPlayer.on('playbackQualityChange', _this.onPlayerPlaybackQualityChange);
|
|
5250
|
-
}
|
|
5222
|
+
};
|
|
5251
5223
|
|
|
5252
|
-
|
|
5224
|
+
_this.resetPlayer = function () {
|
|
5253
5225
|
return _this.internalPlayer.destroy().then(_this.createPlayer);
|
|
5254
|
-
}
|
|
5226
|
+
};
|
|
5255
5227
|
|
|
5256
|
-
|
|
5228
|
+
_this.updatePlayer = function () {
|
|
5257
5229
|
_this.internalPlayer.getIframe().then(function (iframe) {
|
|
5258
5230
|
if (_this.props.id) iframe.setAttribute('id', _this.props.id);else iframe.removeAttribute('id');
|
|
5259
5231
|
if (_this.props.className) iframe.setAttribute('class', _this.props.className);else iframe.removeAttribute('class');
|
|
5260
5232
|
});
|
|
5261
|
-
}
|
|
5233
|
+
};
|
|
5262
5234
|
|
|
5263
|
-
|
|
5235
|
+
_this.updateVideo = function () {
|
|
5264
5236
|
if (typeof _this.props.videoId === 'undefined' || _this.props.videoId === null) {
|
|
5265
5237
|
_this.internalPlayer.stopVideo();
|
|
5266
|
-
|
|
5267
5238
|
return;
|
|
5268
|
-
}
|
|
5269
|
-
|
|
5239
|
+
}
|
|
5270
5240
|
|
|
5241
|
+
// set queueing options
|
|
5271
5242
|
var autoplay = false;
|
|
5272
5243
|
var opts = {
|
|
5273
5244
|
videoId: _this.props.videoId
|
|
5274
5245
|
};
|
|
5275
|
-
|
|
5276
5246
|
if ('playerVars' in _this.props.opts) {
|
|
5277
5247
|
autoplay = _this.props.opts.playerVars.autoplay === 1;
|
|
5278
|
-
|
|
5279
5248
|
if ('start' in _this.props.opts.playerVars) {
|
|
5280
5249
|
opts.startSeconds = _this.props.opts.playerVars.start;
|
|
5281
5250
|
}
|
|
5282
|
-
|
|
5283
5251
|
if ('end' in _this.props.opts.playerVars) {
|
|
5284
5252
|
opts.endSeconds = _this.props.opts.playerVars.end;
|
|
5285
5253
|
}
|
|
5286
|
-
}
|
|
5287
|
-
|
|
5254
|
+
}
|
|
5288
5255
|
|
|
5256
|
+
// if autoplay is enabled loadVideoById
|
|
5289
5257
|
if (autoplay) {
|
|
5290
5258
|
_this.internalPlayer.loadVideoById(opts);
|
|
5291
|
-
|
|
5292
5259
|
return;
|
|
5293
|
-
}
|
|
5294
|
-
|
|
5295
|
-
|
|
5260
|
+
}
|
|
5261
|
+
// default behaviour just cues the video
|
|
5296
5262
|
_this.internalPlayer.cueVideoById(opts);
|
|
5297
|
-
}
|
|
5263
|
+
};
|
|
5298
5264
|
|
|
5299
|
-
|
|
5265
|
+
_this.refContainer = function (container) {
|
|
5300
5266
|
_this.container = container;
|
|
5301
|
-
}
|
|
5267
|
+
};
|
|
5302
5268
|
|
|
5303
5269
|
_this.container = null;
|
|
5304
5270
|
_this.internalPlayer = null;
|
|
5305
5271
|
return _this;
|
|
5306
5272
|
}
|
|
5307
5273
|
|
|
5274
|
+
/**
|
|
5275
|
+
* Expose PlayerState constants for convenience. These constants can also be
|
|
5276
|
+
* accessed through the global YT object after the YouTube IFrame API is instantiated.
|
|
5277
|
+
* https://developers.google.com/youtube/iframe_api_reference#onStateChange
|
|
5278
|
+
*/
|
|
5279
|
+
|
|
5280
|
+
|
|
5308
5281
|
_createClass(YouTube, [{
|
|
5309
|
-
key:
|
|
5282
|
+
key: 'componentDidMount',
|
|
5310
5283
|
value: function componentDidMount() {
|
|
5311
5284
|
this.createPlayer();
|
|
5312
5285
|
}
|
|
5313
5286
|
}, {
|
|
5314
|
-
key:
|
|
5287
|
+
key: 'componentDidUpdate',
|
|
5315
5288
|
value: function componentDidUpdate(prevProps) {
|
|
5316
5289
|
if (shouldUpdatePlayer(prevProps, this.props)) {
|
|
5317
5290
|
this.updatePlayer();
|
|
@@ -5326,58 +5299,112 @@ var YouTube = /*#__PURE__*/function (_React$Component) {
|
|
|
5326
5299
|
}
|
|
5327
5300
|
}
|
|
5328
5301
|
}, {
|
|
5329
|
-
key:
|
|
5302
|
+
key: 'componentWillUnmount',
|
|
5330
5303
|
value: function componentWillUnmount() {
|
|
5331
|
-
/**
|
|
5332
|
-
* Note: The `youtube-player` package that is used promisifies all
|
|
5333
|
-
* Player API calls, which introduces a delay of a tick before it actually
|
|
5334
|
-
* gets destroyed. Since React attempts to remove the element instantly
|
|
5335
|
-
* this method isn't quick enough to reset the container element.
|
|
5304
|
+
/**
|
|
5305
|
+
* Note: The `youtube-player` package that is used promisifies all Youtube
|
|
5306
|
+
* Player API calls, which introduces a delay of a tick before it actually
|
|
5307
|
+
* gets destroyed. Since React attempts to remove the element instantly
|
|
5308
|
+
* this method isn't quick enough to reset the container element.
|
|
5336
5309
|
*/
|
|
5337
5310
|
this.internalPlayer.destroy();
|
|
5338
5311
|
}
|
|
5339
|
-
|
|
5340
|
-
|
|
5341
|
-
*
|
|
5342
|
-
*
|
|
5343
|
-
*
|
|
5312
|
+
|
|
5313
|
+
/**
|
|
5314
|
+
* https://developers.google.com/youtube/iframe_api_reference#onReady
|
|
5315
|
+
*
|
|
5316
|
+
* @param {Object} event
|
|
5317
|
+
* @param {Object} target - player object
|
|
5318
|
+
*/
|
|
5319
|
+
|
|
5320
|
+
|
|
5321
|
+
/**
|
|
5322
|
+
* https://developers.google.com/youtube/iframe_api_reference#onError
|
|
5323
|
+
*
|
|
5324
|
+
* @param {Object} event
|
|
5325
|
+
* @param {Integer} data - error type
|
|
5326
|
+
* @param {Object} target - player object
|
|
5327
|
+
*/
|
|
5328
|
+
|
|
5329
|
+
|
|
5330
|
+
/**
|
|
5331
|
+
* https://developers.google.com/youtube/iframe_api_reference#onStateChange
|
|
5332
|
+
*
|
|
5333
|
+
* @param {Object} event
|
|
5334
|
+
* @param {Integer} data - status change type
|
|
5335
|
+
* @param {Object} target - actual YT player
|
|
5336
|
+
*/
|
|
5337
|
+
|
|
5338
|
+
|
|
5339
|
+
/**
|
|
5340
|
+
* https://developers.google.com/youtube/iframe_api_reference#onPlaybackRateChange
|
|
5341
|
+
*
|
|
5342
|
+
* @param {Object} event
|
|
5343
|
+
* @param {Float} data - playback rate
|
|
5344
|
+
* @param {Object} target - actual YT player
|
|
5345
|
+
*/
|
|
5346
|
+
|
|
5347
|
+
|
|
5348
|
+
/**
|
|
5349
|
+
* https://developers.google.com/youtube/iframe_api_reference#onPlaybackQualityChange
|
|
5350
|
+
*
|
|
5351
|
+
* @param {Object} event
|
|
5352
|
+
* @param {String} data - playback quality
|
|
5353
|
+
* @param {Object} target - actual YT player
|
|
5354
|
+
*/
|
|
5355
|
+
|
|
5356
|
+
|
|
5357
|
+
/**
|
|
5358
|
+
* Initialize the Youtube Player API on the container and attach event handlers
|
|
5359
|
+
*/
|
|
5360
|
+
|
|
5361
|
+
|
|
5362
|
+
/**
|
|
5363
|
+
* Shorthand for destroying and then re-creating the Youtube Player
|
|
5364
|
+
*/
|
|
5365
|
+
|
|
5366
|
+
|
|
5367
|
+
/**
|
|
5368
|
+
* Method to update the id and class of the Youtube Player iframe.
|
|
5369
|
+
* React should update this automatically but since the Youtube Player API
|
|
5370
|
+
* replaced the DIV that is mounted by React we need to do this manually.
|
|
5371
|
+
*/
|
|
5372
|
+
|
|
5373
|
+
|
|
5374
|
+
/**
|
|
5375
|
+
* Call Youtube Player API methods to update the currently playing video.
|
|
5376
|
+
* Depeding on the `opts.playerVars.autoplay` this function uses one of two
|
|
5377
|
+
* Youtube Player API methods to update the video.
|
|
5344
5378
|
*/
|
|
5345
5379
|
|
|
5346
5380
|
}, {
|
|
5347
|
-
key:
|
|
5381
|
+
key: 'render',
|
|
5348
5382
|
value: function render() {
|
|
5349
|
-
return
|
|
5350
|
-
|
|
5351
|
-
|
|
5352
|
-
id: this.props.id,
|
|
5353
|
-
|
|
5354
|
-
ref: this.refContainer
|
|
5355
|
-
}));
|
|
5383
|
+
return React__default.createElement(
|
|
5384
|
+
'div',
|
|
5385
|
+
{ className: this.props.containerClassName },
|
|
5386
|
+
React__default.createElement('div', { id: this.props.id, className: this.props.className, ref: this.refContainer })
|
|
5387
|
+
);
|
|
5356
5388
|
}
|
|
5357
5389
|
}]);
|
|
5358
5390
|
|
|
5359
5391
|
return YouTube;
|
|
5360
5392
|
}(React__default.Component);
|
|
5361
5393
|
|
|
5362
|
-
_defineProperty(YouTube, "PlayerState", {
|
|
5363
|
-
UNSTARTED: -1,
|
|
5364
|
-
ENDED: 0,
|
|
5365
|
-
PLAYING: 1,
|
|
5366
|
-
PAUSED: 2,
|
|
5367
|
-
BUFFERING: 3,
|
|
5368
|
-
CUED: 5
|
|
5369
|
-
});
|
|
5370
|
-
|
|
5371
5394
|
YouTube.propTypes = {
|
|
5372
5395
|
videoId: PropTypes.string,
|
|
5396
|
+
|
|
5373
5397
|
// custom ID for player element
|
|
5374
5398
|
id: PropTypes.string,
|
|
5399
|
+
|
|
5375
5400
|
// custom class name for player element
|
|
5376
5401
|
className: PropTypes.string,
|
|
5377
5402
|
// custom class name for player container element
|
|
5378
5403
|
containerClassName: PropTypes.string,
|
|
5404
|
+
|
|
5379
5405
|
// https://developers.google.com/youtube/iframe_api_reference#Loading_a_Video_Player
|
|
5380
5406
|
opts: PropTypes.objectOf(PropTypes.any),
|
|
5407
|
+
|
|
5381
5408
|
// event subscriptions
|
|
5382
5409
|
onReady: PropTypes.func,
|
|
5383
5410
|
onError: PropTypes.func,
|
|
@@ -5389,7 +5416,6 @@ YouTube.propTypes = {
|
|
|
5389
5416
|
onPlaybackQualityChange: PropTypes.func
|
|
5390
5417
|
};
|
|
5391
5418
|
YouTube.defaultProps = {
|
|
5392
|
-
videoId: null,
|
|
5393
5419
|
id: null,
|
|
5394
5420
|
className: null,
|
|
5395
5421
|
opts: {},
|
|
@@ -5403,6 +5429,14 @@ YouTube.defaultProps = {
|
|
|
5403
5429
|
onPlaybackRateChange: function onPlaybackRateChange() {},
|
|
5404
5430
|
onPlaybackQualityChange: function onPlaybackQualityChange() {}
|
|
5405
5431
|
};
|
|
5432
|
+
YouTube.PlayerState = {
|
|
5433
|
+
UNSTARTED: -1,
|
|
5434
|
+
ENDED: 0,
|
|
5435
|
+
PLAYING: 1,
|
|
5436
|
+
PAUSED: 2,
|
|
5437
|
+
BUFFERING: 3,
|
|
5438
|
+
CUED: 5
|
|
5439
|
+
};
|
|
5406
5440
|
|
|
5407
5441
|
var YouTubePlayer = function YouTubePlayer(_ref) {
|
|
5408
5442
|
var url = _ref.url;
|
|
@@ -6437,8 +6471,8 @@ var window_1 = win;
|
|
|
6437
6471
|
|
|
6438
6472
|
/*! @name @brightcove/react-player-loader @version 1.4.0 @license Apache-2.0 */
|
|
6439
6473
|
|
|
6440
|
-
function _extends() {
|
|
6441
|
-
_extends = Object.assign || function (target) {
|
|
6474
|
+
function _extends$1() {
|
|
6475
|
+
_extends$1 = Object.assign || function (target) {
|
|
6442
6476
|
for (var i = 1; i < arguments.length; i++) {
|
|
6443
6477
|
var source = arguments[i];
|
|
6444
6478
|
|
|
@@ -6452,7 +6486,7 @@ function _extends() {
|
|
|
6452
6486
|
return target;
|
|
6453
6487
|
};
|
|
6454
6488
|
|
|
6455
|
-
return _extends.apply(this, arguments);
|
|
6489
|
+
return _extends$1.apply(this, arguments);
|
|
6456
6490
|
}
|
|
6457
6491
|
|
|
6458
6492
|
function _inheritsLoose(subClass, superClass) {
|
|
@@ -6461,7 +6495,7 @@ function _inheritsLoose(subClass, superClass) {
|
|
|
6461
6495
|
subClass.__proto__ = superClass;
|
|
6462
6496
|
}
|
|
6463
6497
|
|
|
6464
|
-
function _assertThisInitialized
|
|
6498
|
+
function _assertThisInitialized(self) {
|
|
6465
6499
|
if (self === void 0) {
|
|
6466
6500
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
6467
6501
|
}
|
|
@@ -6471,8 +6505,8 @@ function _assertThisInitialized$1(self) {
|
|
|
6471
6505
|
|
|
6472
6506
|
/*! @name @brightcove/player-loader @version 1.7.1 @license Apache-2.0 */
|
|
6473
6507
|
|
|
6474
|
-
function _extends$1() {
|
|
6475
|
-
_extends$1 = Object.assign || function (target) {
|
|
6508
|
+
function _extends$1$1() {
|
|
6509
|
+
_extends$1$1 = Object.assign || function (target) {
|
|
6476
6510
|
for (var i = 1; i < arguments.length; i++) {
|
|
6477
6511
|
var source = arguments[i];
|
|
6478
6512
|
|
|
@@ -6486,7 +6520,7 @@ function _extends$1() {
|
|
|
6486
6520
|
return target;
|
|
6487
6521
|
};
|
|
6488
6522
|
|
|
6489
|
-
return _extends$1.apply(this, arguments);
|
|
6523
|
+
return _extends$1$1.apply(this, arguments);
|
|
6490
6524
|
}
|
|
6491
6525
|
|
|
6492
6526
|
var version$1 = "1.7.1";
|
|
@@ -6494,7 +6528,7 @@ var version$1 = "1.7.1";
|
|
|
6494
6528
|
/*! @name @brightcove/player-url @version 1.2.0 @license Apache-2.0 */
|
|
6495
6529
|
var version$1$1 = "1.2.0";
|
|
6496
6530
|
|
|
6497
|
-
var _typeof
|
|
6531
|
+
var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) {
|
|
6498
6532
|
return typeof obj;
|
|
6499
6533
|
} : function (obj) {
|
|
6500
6534
|
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
@@ -6629,7 +6663,7 @@ var brightcovePlayerUrl = function brightcovePlayerUrl(_ref) {
|
|
|
6629
6663
|
|
|
6630
6664
|
var qs = '';
|
|
6631
6665
|
|
|
6632
|
-
if (iframe && queryParams && (typeof queryParams === 'undefined' ? 'undefined' : _typeof
|
|
6666
|
+
if (iframe && queryParams && (typeof queryParams === 'undefined' ? 'undefined' : _typeof(queryParams)) === 'object') {
|
|
6633
6667
|
qs = getQueryString(queryParams);
|
|
6634
6668
|
}
|
|
6635
6669
|
|
|
@@ -6863,7 +6897,7 @@ var wrapResponsive = function wrapResponsive(embedType, embedOptions, el) {
|
|
|
6863
6897
|
el.style.width = '100%';
|
|
6864
6898
|
el.style.height = '100%';
|
|
6865
6899
|
|
|
6866
|
-
var responsive = _extends$1({
|
|
6900
|
+
var responsive = _extends$1$1({
|
|
6867
6901
|
aspectRatio: DEFAULT_ASPECT_RATIO,
|
|
6868
6902
|
iframeHorizontalPlaylist: DEFAULT_IFRAME_HORIZONTAL_PLAYLIST,
|
|
6869
6903
|
maxWidth: DEFAULT_MAX_WIDTH
|
|
@@ -7548,7 +7582,7 @@ var loadPlayer = function loadPlayer(params, resolve, reject) {
|
|
|
7548
7582
|
|
|
7549
7583
|
|
|
7550
7584
|
var brightcovePlayerLoader = function brightcovePlayerLoader(parameters) {
|
|
7551
|
-
var params = _extends$1({}, DEFAULTS, parameters);
|
|
7585
|
+
var params = _extends$1$1({}, DEFAULTS, parameters);
|
|
7552
7586
|
|
|
7553
7587
|
var Promise = params.Promise,
|
|
7554
7588
|
onSuccess = params.onSuccess,
|
|
@@ -7690,7 +7724,7 @@ function (_React$Component) {
|
|
|
7690
7724
|
_this.refNode = ref;
|
|
7691
7725
|
};
|
|
7692
7726
|
|
|
7693
|
-
_this.loadPlayer = _this.loadPlayer.bind(_assertThisInitialized
|
|
7727
|
+
_this.loadPlayer = _this.loadPlayer.bind(_assertThisInitialized(_this));
|
|
7694
7728
|
return _this;
|
|
7695
7729
|
}
|
|
7696
7730
|
/**
|
|
@@ -7711,7 +7745,7 @@ function (_React$Component) {
|
|
|
7711
7745
|
var userSuccess = this.props.onSuccess;
|
|
7712
7746
|
var userFailure = this.props.onFailure;
|
|
7713
7747
|
|
|
7714
|
-
var options = _extends({}, this.props, {
|
|
7748
|
+
var options = _extends$1({}, this.props, {
|
|
7715
7749
|
refNode: this.refNode,
|
|
7716
7750
|
refNodeInsert: 'append',
|
|
7717
7751
|
onSuccess: function onSuccess(_ref) {
|
|
@@ -8020,7 +8054,7 @@ function (_React$Component) {
|
|
|
8020
8054
|
;
|
|
8021
8055
|
|
|
8022
8056
|
_proto.render = function render() {
|
|
8023
|
-
var props = _extends({
|
|
8057
|
+
var props = _extends$1({
|
|
8024
8058
|
className: 'brightcove-react-player-loader'
|
|
8025
8059
|
}, this.props.attrs, {
|
|
8026
8060
|
ref: this.setRefNode
|
|
@@ -8434,17 +8468,11 @@ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "functi
|
|
|
8434
8468
|
|
|
8435
8469
|
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; }
|
|
8436
8470
|
|
|
8437
|
-
function
|
|
8438
|
-
|
|
8439
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
8471
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }
|
|
8440
8472
|
|
|
8441
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance
|
|
8473
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); }
|
|
8442
8474
|
|
|
8443
|
-
function
|
|
8444
|
-
|
|
8445
|
-
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; }
|
|
8446
|
-
|
|
8447
|
-
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; }
|
|
8475
|
+
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; }
|
|
8448
8476
|
|
|
8449
8477
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
8450
8478
|
|
|
@@ -8574,12 +8602,12 @@ function getSDK(url, sdkGlobal) {
|
|
|
8574
8602
|
|
|
8575
8603
|
function getConfig(props$1, defaultProps, showWarning) {
|
|
8576
8604
|
var config = (0, _deepmerge["default"])(defaultProps.config, props$1.config);
|
|
8577
|
-
|
|
8578
|
-
var
|
|
8579
|
-
|
|
8605
|
+
var _iteratorNormalCompletion = true;
|
|
8606
|
+
var _didIteratorError = false;
|
|
8607
|
+
var _iteratorError = undefined;
|
|
8580
8608
|
|
|
8581
8609
|
try {
|
|
8582
|
-
for (_iterator.
|
|
8610
|
+
for (var _iterator = props.DEPRECATED_CONFIG_PROPS[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
|
|
8583
8611
|
var p = _step.value;
|
|
8584
8612
|
|
|
8585
8613
|
if (props$1[p]) {
|
|
@@ -8594,9 +8622,18 @@ function getConfig(props$1, defaultProps, showWarning) {
|
|
|
8594
8622
|
}
|
|
8595
8623
|
}
|
|
8596
8624
|
} catch (err) {
|
|
8597
|
-
|
|
8625
|
+
_didIteratorError = true;
|
|
8626
|
+
_iteratorError = err;
|
|
8598
8627
|
} finally {
|
|
8599
|
-
|
|
8628
|
+
try {
|
|
8629
|
+
if (!_iteratorNormalCompletion && _iterator["return"] != null) {
|
|
8630
|
+
_iterator["return"]();
|
|
8631
|
+
}
|
|
8632
|
+
} finally {
|
|
8633
|
+
if (_didIteratorError) {
|
|
8634
|
+
throw _iteratorError;
|
|
8635
|
+
}
|
|
8636
|
+
}
|
|
8600
8637
|
}
|
|
8601
8638
|
|
|
8602
8639
|
return config;
|
|
@@ -8743,16 +8780,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
8743
8780
|
|
|
8744
8781
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
8745
8782
|
|
|
8746
|
-
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); }; }
|
|
8747
|
-
|
|
8748
8783
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
8749
8784
|
|
|
8750
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
8751
|
-
|
|
8752
|
-
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; } }
|
|
8753
|
-
|
|
8754
8785
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
8755
8786
|
|
|
8787
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
8788
|
+
|
|
8756
8789
|
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); }
|
|
8757
8790
|
|
|
8758
8791
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -8761,12 +8794,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
8761
8794
|
|
|
8762
8795
|
var SEEK_ON_PLAY_EXPIRY = 5000;
|
|
8763
8796
|
|
|
8764
|
-
var Player =
|
|
8797
|
+
var Player =
|
|
8798
|
+
/*#__PURE__*/
|
|
8799
|
+
function (_Component) {
|
|
8765
8800
|
_inherits(Player, _Component);
|
|
8766
8801
|
|
|
8767
|
-
var _super = _createSuper(Player);
|
|
8768
|
-
|
|
8769
8802
|
function Player() {
|
|
8803
|
+
var _getPrototypeOf2;
|
|
8804
|
+
|
|
8770
8805
|
var _this;
|
|
8771
8806
|
|
|
8772
8807
|
_classCallCheck(this, Player);
|
|
@@ -8775,7 +8810,7 @@ var Player = /*#__PURE__*/function (_Component) {
|
|
|
8775
8810
|
_args[_key] = arguments[_key];
|
|
8776
8811
|
}
|
|
8777
8812
|
|
|
8778
|
-
_this =
|
|
8813
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Player)).call.apply(_getPrototypeOf2, [this].concat(_args)));
|
|
8779
8814
|
|
|
8780
8815
|
_defineProperty(_assertThisInitialized(_this), "mounted", false);
|
|
8781
8816
|
|
|
@@ -9100,7 +9135,7 @@ var Player = /*#__PURE__*/function (_Component) {
|
|
|
9100
9135
|
return null;
|
|
9101
9136
|
}
|
|
9102
9137
|
|
|
9103
|
-
return
|
|
9138
|
+
return _react["default"].createElement(Player, _extends({}, this.props, {
|
|
9104
9139
|
ref: this.ref,
|
|
9105
9140
|
onReady: this.handleReady,
|
|
9106
9141
|
onPlay: this.handlePlay,
|
|
@@ -9161,16 +9196,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
9161
9196
|
|
|
9162
9197
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
9163
9198
|
|
|
9164
|
-
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); }; }
|
|
9165
|
-
|
|
9166
9199
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
9167
9200
|
|
|
9168
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9169
|
-
|
|
9170
|
-
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; } }
|
|
9171
|
-
|
|
9172
9201
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
9173
9202
|
|
|
9203
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9204
|
+
|
|
9174
9205
|
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); }
|
|
9175
9206
|
|
|
9176
9207
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -9182,12 +9213,14 @@ var SUPPORTED_PROPS = Object.keys(props.propTypes);
|
|
|
9182
9213
|
function createSinglePlayer(activePlayer) {
|
|
9183
9214
|
var _class, _temp;
|
|
9184
9215
|
|
|
9185
|
-
return _temp = _class =
|
|
9216
|
+
return _temp = _class =
|
|
9217
|
+
/*#__PURE__*/
|
|
9218
|
+
function (_Component) {
|
|
9186
9219
|
_inherits(SinglePlayer, _Component);
|
|
9187
9220
|
|
|
9188
|
-
var _super = _createSuper(SinglePlayer);
|
|
9189
|
-
|
|
9190
9221
|
function SinglePlayer() {
|
|
9222
|
+
var _getPrototypeOf2;
|
|
9223
|
+
|
|
9191
9224
|
var _this;
|
|
9192
9225
|
|
|
9193
9226
|
_classCallCheck(this, SinglePlayer);
|
|
@@ -9196,7 +9229,7 @@ function createSinglePlayer(activePlayer) {
|
|
|
9196
9229
|
args[_key] = arguments[_key];
|
|
9197
9230
|
}
|
|
9198
9231
|
|
|
9199
|
-
_this =
|
|
9232
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(SinglePlayer)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
9200
9233
|
|
|
9201
9234
|
_defineProperty(_assertThisInitialized(_this), "config", (0, utils.getConfig)(_this.props, props.defaultProps, true));
|
|
9202
9235
|
|
|
@@ -9264,12 +9297,12 @@ function createSinglePlayer(activePlayer) {
|
|
|
9264
9297
|
height = _this$props.height,
|
|
9265
9298
|
Wrapper = _this$props.wrapper;
|
|
9266
9299
|
var otherProps = (0, utils.omit)(this.props, SUPPORTED_PROPS, props.DEPRECATED_CONFIG_PROPS);
|
|
9267
|
-
return
|
|
9300
|
+
return _react["default"].createElement(Wrapper, _extends({
|
|
9268
9301
|
style: _objectSpread({}, style, {
|
|
9269
9302
|
width: width,
|
|
9270
9303
|
height: height
|
|
9271
9304
|
})
|
|
9272
|
-
}, otherProps),
|
|
9305
|
+
}, otherProps), _react["default"].createElement(_Player["default"], _extends({}, this.props, {
|
|
9273
9306
|
ref: this.ref,
|
|
9274
9307
|
activePlayer: activePlayer,
|
|
9275
9308
|
config: this.config
|
|
@@ -9315,31 +9348,23 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
9315
9348
|
|
|
9316
9349
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
9317
9350
|
|
|
9318
|
-
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); }; }
|
|
9319
|
-
|
|
9320
9351
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
9321
9352
|
|
|
9322
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9323
|
-
|
|
9324
|
-
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; } }
|
|
9325
|
-
|
|
9326
9353
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
9327
9354
|
|
|
9355
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9356
|
+
|
|
9328
9357
|
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); }
|
|
9329
9358
|
|
|
9330
9359
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
9331
9360
|
|
|
9332
9361
|
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; }
|
|
9333
9362
|
|
|
9334
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) ||
|
|
9335
|
-
|
|
9336
|
-
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."); }
|
|
9337
|
-
|
|
9338
|
-
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); }
|
|
9363
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }
|
|
9339
9364
|
|
|
9340
|
-
function
|
|
9365
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); }
|
|
9341
9366
|
|
|
9342
|
-
function _iterableToArrayLimit(arr, i) { if (
|
|
9367
|
+
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; }
|
|
9343
9368
|
|
|
9344
9369
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
9345
9370
|
|
|
@@ -9364,12 +9389,14 @@ function parsePlaylist(url) {
|
|
|
9364
9389
|
return {};
|
|
9365
9390
|
}
|
|
9366
9391
|
|
|
9367
|
-
var YouTube =
|
|
9392
|
+
var YouTube =
|
|
9393
|
+
/*#__PURE__*/
|
|
9394
|
+
function (_Component) {
|
|
9368
9395
|
_inherits(YouTube, _Component);
|
|
9369
9396
|
|
|
9370
|
-
var _super = _createSuper(YouTube);
|
|
9371
|
-
|
|
9372
9397
|
function YouTube() {
|
|
9398
|
+
var _getPrototypeOf2;
|
|
9399
|
+
|
|
9373
9400
|
var _this;
|
|
9374
9401
|
|
|
9375
9402
|
_classCallCheck(this, YouTube);
|
|
@@ -9378,7 +9405,7 @@ var YouTube = /*#__PURE__*/function (_Component) {
|
|
|
9378
9405
|
args[_key] = arguments[_key];
|
|
9379
9406
|
}
|
|
9380
9407
|
|
|
9381
|
-
_this =
|
|
9408
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(YouTube)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
9382
9409
|
|
|
9383
9410
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
9384
9411
|
|
|
@@ -9566,9 +9593,9 @@ var YouTube = /*#__PURE__*/function (_Component) {
|
|
|
9566
9593
|
height: '100%',
|
|
9567
9594
|
display: display
|
|
9568
9595
|
};
|
|
9569
|
-
return
|
|
9596
|
+
return _react["default"].createElement("div", {
|
|
9570
9597
|
style: style
|
|
9571
|
-
},
|
|
9598
|
+
}, _react["default"].createElement("div", {
|
|
9572
9599
|
ref: this.ref
|
|
9573
9600
|
}));
|
|
9574
9601
|
}
|
|
@@ -9624,16 +9651,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
9624
9651
|
|
|
9625
9652
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
9626
9653
|
|
|
9627
|
-
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); }; }
|
|
9628
|
-
|
|
9629
9654
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
9630
9655
|
|
|
9631
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9632
|
-
|
|
9633
|
-
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; } }
|
|
9634
|
-
|
|
9635
9656
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
9636
9657
|
|
|
9658
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9659
|
+
|
|
9637
9660
|
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); }
|
|
9638
9661
|
|
|
9639
9662
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -9642,14 +9665,16 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
9642
9665
|
|
|
9643
9666
|
var SDK_URL = 'https://w.soundcloud.com/player/api.js';
|
|
9644
9667
|
var SDK_GLOBAL = 'SC';
|
|
9645
|
-
var MATCH_URL = /(
|
|
9668
|
+
var MATCH_URL = /(soundcloud\.com|snd\.sc)\/.+$/;
|
|
9646
9669
|
|
|
9647
|
-
var SoundCloud =
|
|
9670
|
+
var SoundCloud =
|
|
9671
|
+
/*#__PURE__*/
|
|
9672
|
+
function (_Component) {
|
|
9648
9673
|
_inherits(SoundCloud, _Component);
|
|
9649
9674
|
|
|
9650
|
-
var _super = _createSuper(SoundCloud);
|
|
9651
|
-
|
|
9652
9675
|
function SoundCloud() {
|
|
9676
|
+
var _getPrototypeOf2;
|
|
9677
|
+
|
|
9653
9678
|
var _this;
|
|
9654
9679
|
|
|
9655
9680
|
_classCallCheck(this, SoundCloud);
|
|
@@ -9658,7 +9683,7 @@ var SoundCloud = /*#__PURE__*/function (_Component) {
|
|
|
9658
9683
|
args[_key] = arguments[_key];
|
|
9659
9684
|
}
|
|
9660
9685
|
|
|
9661
|
-
_this =
|
|
9686
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(SoundCloud)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
9662
9687
|
|
|
9663
9688
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
9664
9689
|
|
|
@@ -9779,7 +9804,7 @@ var SoundCloud = /*#__PURE__*/function (_Component) {
|
|
|
9779
9804
|
height: '100%',
|
|
9780
9805
|
display: display
|
|
9781
9806
|
};
|
|
9782
|
-
return
|
|
9807
|
+
return _react["default"].createElement("iframe", {
|
|
9783
9808
|
ref: this.ref,
|
|
9784
9809
|
src: "https://w.soundcloud.com/player/?url=".concat(encodeURIComponent(this.props.url)),
|
|
9785
9810
|
style: style,
|
|
@@ -9841,16 +9866,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
9841
9866
|
|
|
9842
9867
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
9843
9868
|
|
|
9844
|
-
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); }; }
|
|
9845
|
-
|
|
9846
9869
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
9847
9870
|
|
|
9848
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9849
|
-
|
|
9850
|
-
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; } }
|
|
9851
|
-
|
|
9852
9871
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
9853
9872
|
|
|
9873
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
9874
|
+
|
|
9854
9875
|
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); }
|
|
9855
9876
|
|
|
9856
9877
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -9862,12 +9883,14 @@ var SDK_GLOBAL = 'Vimeo';
|
|
|
9862
9883
|
var MATCH_URL = /vimeo\.com\/.+/;
|
|
9863
9884
|
var MATCH_FILE_URL = /vimeo\.com\/external\/[0-9]+\..+/;
|
|
9864
9885
|
|
|
9865
|
-
var Vimeo =
|
|
9886
|
+
var Vimeo =
|
|
9887
|
+
/*#__PURE__*/
|
|
9888
|
+
function (_Component) {
|
|
9866
9889
|
_inherits(Vimeo, _Component);
|
|
9867
9890
|
|
|
9868
|
-
var _super = _createSuper(Vimeo);
|
|
9869
|
-
|
|
9870
9891
|
function Vimeo() {
|
|
9892
|
+
var _getPrototypeOf2;
|
|
9893
|
+
|
|
9871
9894
|
var _this;
|
|
9872
9895
|
|
|
9873
9896
|
_classCallCheck(this, Vimeo);
|
|
@@ -9876,7 +9899,7 @@ var Vimeo = /*#__PURE__*/function (_Component) {
|
|
|
9876
9899
|
args[_key] = arguments[_key];
|
|
9877
9900
|
}
|
|
9878
9901
|
|
|
9879
|
-
_this =
|
|
9902
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Vimeo)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
9880
9903
|
|
|
9881
9904
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
9882
9905
|
|
|
@@ -10033,7 +10056,7 @@ var Vimeo = /*#__PURE__*/function (_Component) {
|
|
|
10033
10056
|
overflow: 'hidden',
|
|
10034
10057
|
display: display
|
|
10035
10058
|
};
|
|
10036
|
-
return
|
|
10059
|
+
return _react["default"].createElement("div", {
|
|
10037
10060
|
key: this.props.url,
|
|
10038
10061
|
ref: this.ref,
|
|
10039
10062
|
style: style
|
|
@@ -10093,16 +10116,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
10093
10116
|
|
|
10094
10117
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
10095
10118
|
|
|
10096
|
-
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); }; }
|
|
10097
|
-
|
|
10098
10119
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
10099
10120
|
|
|
10100
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10101
|
-
|
|
10102
|
-
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; } }
|
|
10103
|
-
|
|
10104
10121
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
10105
10122
|
|
|
10123
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10124
|
+
|
|
10106
10125
|
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); }
|
|
10107
10126
|
|
|
10108
10127
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -10115,12 +10134,14 @@ var SDK_GLOBAL_READY = 'fbAsyncInit';
|
|
|
10115
10134
|
var MATCH_URL = /^https?:\/\/(www\.)?facebook\.com.*\/(video(s)?|watch|story)(\.php?|\/).+$/;
|
|
10116
10135
|
var PLAYER_ID_PREFIX = 'facebook-player-';
|
|
10117
10136
|
|
|
10118
|
-
var Facebook =
|
|
10137
|
+
var Facebook =
|
|
10138
|
+
/*#__PURE__*/
|
|
10139
|
+
function (_Component) {
|
|
10119
10140
|
_inherits(Facebook, _Component);
|
|
10120
10141
|
|
|
10121
|
-
var _super = _createSuper(Facebook);
|
|
10122
|
-
|
|
10123
10142
|
function Facebook() {
|
|
10143
|
+
var _getPrototypeOf2;
|
|
10144
|
+
|
|
10124
10145
|
var _this;
|
|
10125
10146
|
|
|
10126
10147
|
_classCallCheck(this, Facebook);
|
|
@@ -10129,7 +10150,7 @@ var Facebook = /*#__PURE__*/function (_Component) {
|
|
|
10129
10150
|
args[_key] = arguments[_key];
|
|
10130
10151
|
}
|
|
10131
10152
|
|
|
10132
|
-
_this =
|
|
10153
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Facebook)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
10133
10154
|
|
|
10134
10155
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
10135
10156
|
|
|
@@ -10245,7 +10266,7 @@ var Facebook = /*#__PURE__*/function (_Component) {
|
|
|
10245
10266
|
width: '100%',
|
|
10246
10267
|
height: '100%'
|
|
10247
10268
|
};
|
|
10248
|
-
return
|
|
10269
|
+
return _react["default"].createElement("div", {
|
|
10249
10270
|
style: style,
|
|
10250
10271
|
id: this.playerID,
|
|
10251
10272
|
className: "fb-video",
|
|
@@ -10305,16 +10326,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
10305
10326
|
|
|
10306
10327
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
10307
10328
|
|
|
10308
|
-
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); }; }
|
|
10309
|
-
|
|
10310
10329
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
10311
10330
|
|
|
10312
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10313
|
-
|
|
10314
|
-
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; } }
|
|
10315
|
-
|
|
10316
10331
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
10317
10332
|
|
|
10333
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10334
|
+
|
|
10318
10335
|
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); }
|
|
10319
10336
|
|
|
10320
10337
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -10325,12 +10342,14 @@ var SDK_URL = 'https://cdn.embed.ly/player-0.1.0.min.js';
|
|
|
10325
10342
|
var SDK_GLOBAL = 'playerjs';
|
|
10326
10343
|
var MATCH_URL = /streamable\.com\/([a-z0-9]+)$/;
|
|
10327
10344
|
|
|
10328
|
-
var Streamable =
|
|
10345
|
+
var Streamable =
|
|
10346
|
+
/*#__PURE__*/
|
|
10347
|
+
function (_Component) {
|
|
10329
10348
|
_inherits(Streamable, _Component);
|
|
10330
10349
|
|
|
10331
|
-
var _super = _createSuper(Streamable);
|
|
10332
|
-
|
|
10333
10350
|
function Streamable() {
|
|
10351
|
+
var _getPrototypeOf2;
|
|
10352
|
+
|
|
10334
10353
|
var _this;
|
|
10335
10354
|
|
|
10336
10355
|
_classCallCheck(this, Streamable);
|
|
@@ -10339,7 +10358,7 @@ var Streamable = /*#__PURE__*/function (_Component) {
|
|
|
10339
10358
|
args[_key] = arguments[_key];
|
|
10340
10359
|
}
|
|
10341
10360
|
|
|
10342
|
-
_this =
|
|
10361
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Streamable)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
10343
10362
|
|
|
10344
10363
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
10345
10364
|
|
|
@@ -10459,7 +10478,7 @@ var Streamable = /*#__PURE__*/function (_Component) {
|
|
|
10459
10478
|
width: '100%',
|
|
10460
10479
|
height: '100%'
|
|
10461
10480
|
};
|
|
10462
|
-
return
|
|
10481
|
+
return _react["default"].createElement("iframe", {
|
|
10463
10482
|
ref: this.ref,
|
|
10464
10483
|
src: "https://streamable.com/o/".concat(id),
|
|
10465
10484
|
frameBorder: "0",
|
|
@@ -10520,16 +10539,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
10520
10539
|
|
|
10521
10540
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
10522
10541
|
|
|
10523
|
-
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); }; }
|
|
10524
|
-
|
|
10525
10542
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
10526
10543
|
|
|
10527
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10528
|
-
|
|
10529
|
-
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; } }
|
|
10530
|
-
|
|
10531
10544
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
10532
10545
|
|
|
10546
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10547
|
+
|
|
10533
10548
|
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); }
|
|
10534
10549
|
|
|
10535
10550
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -10540,48 +10555,26 @@ var SDK_URL = 'https://fast.wistia.com/assets/external/E-v1.js';
|
|
|
10540
10555
|
var SDK_GLOBAL = 'Wistia';
|
|
10541
10556
|
var MATCH_URL = /(?:wistia\.com|wi\.st)\/(?:medias|embed)\/(.*)$/;
|
|
10542
10557
|
|
|
10543
|
-
var Wistia =
|
|
10558
|
+
var Wistia =
|
|
10559
|
+
/*#__PURE__*/
|
|
10560
|
+
function (_Component) {
|
|
10544
10561
|
_inherits(Wistia, _Component);
|
|
10545
10562
|
|
|
10546
|
-
var _super = _createSuper(Wistia);
|
|
10547
|
-
|
|
10548
10563
|
function Wistia() {
|
|
10564
|
+
var _getPrototypeOf2;
|
|
10565
|
+
|
|
10549
10566
|
var _this;
|
|
10550
10567
|
|
|
10551
10568
|
_classCallCheck(this, Wistia);
|
|
10552
10569
|
|
|
10553
|
-
for (var _len = arguments.length,
|
|
10554
|
-
|
|
10570
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
10571
|
+
args[_key] = arguments[_key];
|
|
10555
10572
|
}
|
|
10556
10573
|
|
|
10557
|
-
_this =
|
|
10574
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Wistia)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
10558
10575
|
|
|
10559
10576
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
10560
10577
|
|
|
10561
|
-
_defineProperty(_assertThisInitialized(_this), "onPlay", function () {
|
|
10562
|
-
var _this$props;
|
|
10563
|
-
|
|
10564
|
-
return (_this$props = _this.props).onPlay.apply(_this$props, arguments);
|
|
10565
|
-
});
|
|
10566
|
-
|
|
10567
|
-
_defineProperty(_assertThisInitialized(_this), "onPause", function () {
|
|
10568
|
-
var _this$props2;
|
|
10569
|
-
|
|
10570
|
-
return (_this$props2 = _this.props).onPause.apply(_this$props2, arguments);
|
|
10571
|
-
});
|
|
10572
|
-
|
|
10573
|
-
_defineProperty(_assertThisInitialized(_this), "onSeek", function () {
|
|
10574
|
-
var _this$props3;
|
|
10575
|
-
|
|
10576
|
-
return (_this$props3 = _this.props).onSeek.apply(_this$props3, arguments);
|
|
10577
|
-
});
|
|
10578
|
-
|
|
10579
|
-
_defineProperty(_assertThisInitialized(_this), "onEnded", function () {
|
|
10580
|
-
var _this$props4;
|
|
10581
|
-
|
|
10582
|
-
return (_this$props4 = _this.props).onEnded.apply(_this$props4, arguments);
|
|
10583
|
-
});
|
|
10584
|
-
|
|
10585
10578
|
_defineProperty(_assertThisInitialized(_this), "mute", function () {
|
|
10586
10579
|
_this.callPlayer('mute');
|
|
10587
10580
|
});
|
|
@@ -10603,13 +10596,17 @@ var Wistia = /*#__PURE__*/function (_Component) {
|
|
|
10603
10596
|
value: function load(url) {
|
|
10604
10597
|
var _this2 = this;
|
|
10605
10598
|
|
|
10606
|
-
var _this$
|
|
10607
|
-
playing = _this$
|
|
10608
|
-
muted = _this$
|
|
10609
|
-
controls = _this$
|
|
10610
|
-
_onReady = _this$
|
|
10611
|
-
|
|
10612
|
-
|
|
10599
|
+
var _this$props = this.props,
|
|
10600
|
+
playing = _this$props.playing,
|
|
10601
|
+
muted = _this$props.muted,
|
|
10602
|
+
controls = _this$props.controls,
|
|
10603
|
+
_onReady = _this$props.onReady,
|
|
10604
|
+
onPlay = _this$props.onPlay,
|
|
10605
|
+
onPause = _this$props.onPause,
|
|
10606
|
+
onSeek = _this$props.onSeek,
|
|
10607
|
+
onEnded = _this$props.onEnded,
|
|
10608
|
+
config = _this$props.config,
|
|
10609
|
+
onError = _this$props.onError;
|
|
10613
10610
|
(0, utils.getSDK)(SDK_URL, SDK_GLOBAL).then(function () {
|
|
10614
10611
|
window._wq = window._wq || [];
|
|
10615
10612
|
|
|
@@ -10626,28 +10623,19 @@ var Wistia = /*#__PURE__*/function (_Component) {
|
|
|
10626
10623
|
|
|
10627
10624
|
_this2.unbind();
|
|
10628
10625
|
|
|
10629
|
-
_this2.player.bind('play',
|
|
10626
|
+
_this2.player.bind('play', onPlay);
|
|
10630
10627
|
|
|
10631
|
-
_this2.player.bind('pause',
|
|
10628
|
+
_this2.player.bind('pause', onPause);
|
|
10632
10629
|
|
|
10633
|
-
_this2.player.bind('seek',
|
|
10630
|
+
_this2.player.bind('seek', onSeek);
|
|
10634
10631
|
|
|
10635
|
-
_this2.player.bind('end',
|
|
10632
|
+
_this2.player.bind('end', onEnded);
|
|
10636
10633
|
|
|
10637
10634
|
_onReady();
|
|
10638
10635
|
}
|
|
10639
10636
|
});
|
|
10640
10637
|
}, onError);
|
|
10641
10638
|
}
|
|
10642
|
-
}, {
|
|
10643
|
-
key: "unbind",
|
|
10644
|
-
value: function unbind() {
|
|
10645
|
-
this.player.unbind('play', this.onPlay);
|
|
10646
|
-
this.player.unbind('pause', this.onPause);
|
|
10647
|
-
this.player.unbind('seek', this.onSeek);
|
|
10648
|
-
this.player.unbind('end', this.onEnded);
|
|
10649
|
-
} // Proxy methods to prevent listener leaks
|
|
10650
|
-
|
|
10651
10639
|
}, {
|
|
10652
10640
|
key: "play",
|
|
10653
10641
|
value: function play() {
|
|
@@ -10658,6 +10646,19 @@ var Wistia = /*#__PURE__*/function (_Component) {
|
|
|
10658
10646
|
value: function pause() {
|
|
10659
10647
|
this.callPlayer('pause');
|
|
10660
10648
|
}
|
|
10649
|
+
}, {
|
|
10650
|
+
key: "unbind",
|
|
10651
|
+
value: function unbind() {
|
|
10652
|
+
var _this$props2 = this.props,
|
|
10653
|
+
onPlay = _this$props2.onPlay,
|
|
10654
|
+
onPause = _this$props2.onPause,
|
|
10655
|
+
onSeek = _this$props2.onSeek,
|
|
10656
|
+
onEnded = _this$props2.onEnded;
|
|
10657
|
+
this.player.unbind('play', onPlay);
|
|
10658
|
+
this.player.unbind('pause', onPause);
|
|
10659
|
+
this.player.unbind('seek', onSeek);
|
|
10660
|
+
this.player.unbind('end', onEnded);
|
|
10661
|
+
}
|
|
10661
10662
|
}, {
|
|
10662
10663
|
key: "stop",
|
|
10663
10664
|
value: function stop() {
|
|
@@ -10703,7 +10704,7 @@ var Wistia = /*#__PURE__*/function (_Component) {
|
|
|
10703
10704
|
width: '100%',
|
|
10704
10705
|
height: '100%'
|
|
10705
10706
|
};
|
|
10706
|
-
return
|
|
10707
|
+
return _react["default"].createElement("div", {
|
|
10707
10708
|
key: id,
|
|
10708
10709
|
className: className,
|
|
10709
10710
|
style: style
|
|
@@ -10763,16 +10764,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
10763
10764
|
|
|
10764
10765
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
10765
10766
|
|
|
10766
|
-
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); }; }
|
|
10767
|
-
|
|
10768
10767
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
10769
10768
|
|
|
10770
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10771
|
-
|
|
10772
|
-
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; } }
|
|
10773
|
-
|
|
10774
10769
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
10775
10770
|
|
|
10771
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10772
|
+
|
|
10776
10773
|
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); }
|
|
10777
10774
|
|
|
10778
10775
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -10785,12 +10782,14 @@ var MATCH_VIDEO_URL = /(?:www\.|go\.)?twitch\.tv\/videos\/(\d+)($|\?)/;
|
|
|
10785
10782
|
var MATCH_CHANNEL_URL = /(?:www\.|go\.)?twitch\.tv\/([a-z0-9_]+)($|\?)/;
|
|
10786
10783
|
var PLAYER_ID_PREFIX = 'twitch-player-';
|
|
10787
10784
|
|
|
10788
|
-
var Twitch =
|
|
10785
|
+
var Twitch =
|
|
10786
|
+
/*#__PURE__*/
|
|
10787
|
+
function (_Component) {
|
|
10789
10788
|
_inherits(Twitch, _Component);
|
|
10790
10789
|
|
|
10791
|
-
var _super = _createSuper(Twitch);
|
|
10792
|
-
|
|
10793
10790
|
function Twitch() {
|
|
10791
|
+
var _getPrototypeOf2;
|
|
10792
|
+
|
|
10794
10793
|
var _this;
|
|
10795
10794
|
|
|
10796
10795
|
_classCallCheck(this, Twitch);
|
|
@@ -10799,7 +10798,7 @@ var Twitch = /*#__PURE__*/function (_Component) {
|
|
|
10799
10798
|
args[_key] = arguments[_key];
|
|
10800
10799
|
}
|
|
10801
10800
|
|
|
10802
|
-
_this =
|
|
10801
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Twitch)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
10803
10802
|
|
|
10804
10803
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
10805
10804
|
|
|
@@ -10920,7 +10919,7 @@ var Twitch = /*#__PURE__*/function (_Component) {
|
|
|
10920
10919
|
width: '100%',
|
|
10921
10920
|
height: '100%'
|
|
10922
10921
|
};
|
|
10923
|
-
return
|
|
10922
|
+
return _react["default"].createElement("div", {
|
|
10924
10923
|
style: style,
|
|
10925
10924
|
id: this.playerID
|
|
10926
10925
|
});
|
|
@@ -10973,15 +10972,11 @@ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (O
|
|
|
10973
10972
|
|
|
10974
10973
|
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; }
|
|
10975
10974
|
|
|
10976
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) ||
|
|
10975
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }
|
|
10977
10976
|
|
|
10978
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance
|
|
10977
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); }
|
|
10979
10978
|
|
|
10980
|
-
function
|
|
10981
|
-
|
|
10982
|
-
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; }
|
|
10983
|
-
|
|
10984
|
-
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; }
|
|
10979
|
+
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; }
|
|
10985
10980
|
|
|
10986
10981
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
10987
10982
|
|
|
@@ -10991,16 +10986,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
10991
10986
|
|
|
10992
10987
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
10993
10988
|
|
|
10994
|
-
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); }; }
|
|
10995
|
-
|
|
10996
10989
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
10997
10990
|
|
|
10998
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10999
|
-
|
|
11000
|
-
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; } }
|
|
11001
|
-
|
|
11002
10991
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
11003
10992
|
|
|
10993
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10994
|
+
|
|
11004
10995
|
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); }
|
|
11005
10996
|
|
|
11006
10997
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -11012,12 +11003,14 @@ var SDK_GLOBAL = 'DM';
|
|
|
11012
11003
|
var SDK_GLOBAL_READY = 'dmAsyncInit';
|
|
11013
11004
|
var MATCH_URL = /^(?:(?:https?):)?(?:\/\/)?(?:www\.)?(?:(?:dailymotion\.com(?:\/embed)?\/video)|dai\.ly)\/([a-zA-Z0-9]+)(?:_[\w_-]+)?$/;
|
|
11014
11005
|
|
|
11015
|
-
var DailyMotion =
|
|
11006
|
+
var DailyMotion =
|
|
11007
|
+
/*#__PURE__*/
|
|
11008
|
+
function (_Component) {
|
|
11016
11009
|
_inherits(DailyMotion, _Component);
|
|
11017
11010
|
|
|
11018
|
-
var _super = _createSuper(DailyMotion);
|
|
11019
|
-
|
|
11020
11011
|
function DailyMotion() {
|
|
11012
|
+
var _getPrototypeOf2;
|
|
11013
|
+
|
|
11021
11014
|
var _this;
|
|
11022
11015
|
|
|
11023
11016
|
_classCallCheck(this, DailyMotion);
|
|
@@ -11026,7 +11019,7 @@ var DailyMotion = /*#__PURE__*/function (_Component) {
|
|
|
11026
11019
|
args[_key] = arguments[_key];
|
|
11027
11020
|
}
|
|
11028
11021
|
|
|
11029
|
-
_this =
|
|
11022
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(DailyMotion)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
11030
11023
|
|
|
11031
11024
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
11032
11025
|
|
|
@@ -11155,9 +11148,9 @@ var DailyMotion = /*#__PURE__*/function (_Component) {
|
|
|
11155
11148
|
height: '100%',
|
|
11156
11149
|
display: display
|
|
11157
11150
|
};
|
|
11158
|
-
return
|
|
11151
|
+
return _react["default"].createElement("div", {
|
|
11159
11152
|
style: style
|
|
11160
|
-
},
|
|
11153
|
+
}, _react["default"].createElement("div", {
|
|
11161
11154
|
ref: this.ref
|
|
11162
11155
|
}));
|
|
11163
11156
|
}
|
|
@@ -11215,16 +11208,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
11215
11208
|
|
|
11216
11209
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
11217
11210
|
|
|
11218
|
-
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); }; }
|
|
11219
|
-
|
|
11220
11211
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
11221
11212
|
|
|
11222
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
11223
|
-
|
|
11224
|
-
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; } }
|
|
11225
|
-
|
|
11226
11213
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
11227
11214
|
|
|
11215
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
11216
|
+
|
|
11228
11217
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
11229
11218
|
|
|
11230
11219
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -11235,12 +11224,14 @@ var SDK_URL = 'https://widget.mixcloud.com/media/js/widgetApi.js';
|
|
|
11235
11224
|
var SDK_GLOBAL = 'Mixcloud';
|
|
11236
11225
|
var MATCH_URL = /mixcloud\.com\/([^/]+\/[^/]+)/;
|
|
11237
11226
|
|
|
11238
|
-
var Mixcloud =
|
|
11227
|
+
var Mixcloud =
|
|
11228
|
+
/*#__PURE__*/
|
|
11229
|
+
function (_Component) {
|
|
11239
11230
|
_inherits(Mixcloud, _Component);
|
|
11240
11231
|
|
|
11241
|
-
var _super = _createSuper(Mixcloud);
|
|
11242
|
-
|
|
11243
11232
|
function Mixcloud() {
|
|
11233
|
+
var _getPrototypeOf2;
|
|
11234
|
+
|
|
11244
11235
|
var _this;
|
|
11245
11236
|
|
|
11246
11237
|
_classCallCheck(this, Mixcloud);
|
|
@@ -11249,7 +11240,7 @@ var Mixcloud = /*#__PURE__*/function (_Component) {
|
|
|
11249
11240
|
args[_key] = arguments[_key];
|
|
11250
11241
|
}
|
|
11251
11242
|
|
|
11252
|
-
_this =
|
|
11243
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Mixcloud)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
11253
11244
|
|
|
11254
11245
|
_defineProperty(_assertThisInitialized(_this), "callPlayer", utils.callPlayer);
|
|
11255
11246
|
|
|
@@ -11352,7 +11343,7 @@ var Mixcloud = /*#__PURE__*/function (_Component) {
|
|
|
11352
11343
|
})); // We have to give the iframe a key here to prevent a
|
|
11353
11344
|
// weird dialog appearing when loading a new track
|
|
11354
11345
|
|
|
11355
|
-
return
|
|
11346
|
+
return _react["default"].createElement("iframe", {
|
|
11356
11347
|
key: id,
|
|
11357
11348
|
ref: this.ref,
|
|
11358
11349
|
style: style,
|
|
@@ -11412,33 +11403,23 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
11412
11403
|
|
|
11413
11404
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
11414
11405
|
|
|
11415
|
-
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); }; }
|
|
11416
|
-
|
|
11417
11406
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
11418
11407
|
|
|
11419
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
11420
|
-
|
|
11421
|
-
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; } }
|
|
11422
|
-
|
|
11423
11408
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
11424
11409
|
|
|
11410
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
11411
|
+
|
|
11425
11412
|
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); }
|
|
11426
11413
|
|
|
11427
11414
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
11428
11415
|
|
|
11429
11416
|
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; }
|
|
11430
11417
|
|
|
11431
|
-
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; } } }; }
|
|
11432
|
-
|
|
11433
|
-
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); }
|
|
11434
|
-
|
|
11435
|
-
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; }
|
|
11436
|
-
|
|
11437
11418
|
var IOS = typeof navigator !== 'undefined' && /iPad|iPhone|iPod/.test(navigator.userAgent) && !window.MSStream;
|
|
11438
11419
|
var AUDIO_EXTENSIONS = /\.(m4a|mp4a|mpga|mp2|mp2a|mp3|m2a|m3a|wav|weba|aac|oga|spx)($|\?)/i;
|
|
11439
11420
|
var VIDEO_EXTENSIONS = /\.(mp4|og[gv]|webm|mov|m4v)($|\?)/i;
|
|
11440
11421
|
var HLS_EXTENSIONS = /\.(m3u8)($|\?)/i;
|
|
11441
|
-
var HLS_SDK_URL = 'https://cdn.jsdelivr.net/npm/hls.js@VERSION
|
|
11422
|
+
var HLS_SDK_URL = 'https://cdn.jsdelivr.net/npm/hls.js@VERSION';
|
|
11442
11423
|
var HLS_GLOBAL = 'Hls';
|
|
11443
11424
|
var DASH_EXTENSIONS = /\.(mpd)($|\?)/i;
|
|
11444
11425
|
var DASH_SDK_URL = 'https://cdnjs.cloudflare.com/ajax/libs/dashjs/VERSION/dash.all.min.js';
|
|
@@ -11447,11 +11428,12 @@ var MATCH_DROPBOX_URL = /www\.dropbox\.com\/.+/;
|
|
|
11447
11428
|
|
|
11448
11429
|
function canPlay(url) {
|
|
11449
11430
|
if (url instanceof Array) {
|
|
11450
|
-
var
|
|
11451
|
-
|
|
11431
|
+
var _iteratorNormalCompletion = true;
|
|
11432
|
+
var _didIteratorError = false;
|
|
11433
|
+
var _iteratorError = undefined;
|
|
11452
11434
|
|
|
11453
11435
|
try {
|
|
11454
|
-
for (_iterator.
|
|
11436
|
+
for (var _iterator = url[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
|
|
11455
11437
|
var item = _step.value;
|
|
11456
11438
|
|
|
11457
11439
|
if (typeof item === 'string' && canPlay(item)) {
|
|
@@ -11463,9 +11445,18 @@ function canPlay(url) {
|
|
|
11463
11445
|
}
|
|
11464
11446
|
}
|
|
11465
11447
|
} catch (err) {
|
|
11466
|
-
|
|
11448
|
+
_didIteratorError = true;
|
|
11449
|
+
_iteratorError = err;
|
|
11467
11450
|
} finally {
|
|
11468
|
-
|
|
11451
|
+
try {
|
|
11452
|
+
if (!_iteratorNormalCompletion && _iterator["return"] != null) {
|
|
11453
|
+
_iterator["return"]();
|
|
11454
|
+
}
|
|
11455
|
+
} finally {
|
|
11456
|
+
if (_didIteratorError) {
|
|
11457
|
+
throw _iteratorError;
|
|
11458
|
+
}
|
|
11459
|
+
}
|
|
11469
11460
|
}
|
|
11470
11461
|
|
|
11471
11462
|
return false;
|
|
@@ -11489,12 +11480,14 @@ function canEnablePIP(url) {
|
|
|
11489
11480
|
return canPlay(url) && (!!document.pictureInPictureEnabled || supportsWebKitPresentationMode()) && !AUDIO_EXTENSIONS.test(url);
|
|
11490
11481
|
}
|
|
11491
11482
|
|
|
11492
|
-
var FilePlayer =
|
|
11483
|
+
var FilePlayer =
|
|
11484
|
+
/*#__PURE__*/
|
|
11485
|
+
function (_Component) {
|
|
11493
11486
|
_inherits(FilePlayer, _Component);
|
|
11494
11487
|
|
|
11495
|
-
var _super = _createSuper(FilePlayer);
|
|
11496
|
-
|
|
11497
11488
|
function FilePlayer() {
|
|
11489
|
+
var _getPrototypeOf2;
|
|
11490
|
+
|
|
11498
11491
|
var _this;
|
|
11499
11492
|
|
|
11500
11493
|
_classCallCheck(this, FilePlayer);
|
|
@@ -11503,7 +11496,7 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
|
|
|
11503
11496
|
_args[_key] = arguments[_key];
|
|
11504
11497
|
}
|
|
11505
11498
|
|
|
11506
|
-
_this =
|
|
11499
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(FilePlayer)).call.apply(_getPrototypeOf2, [this].concat(_args)));
|
|
11507
11500
|
|
|
11508
11501
|
_defineProperty(_assertThisInitialized(_this), "onReady", function () {
|
|
11509
11502
|
var _this$props;
|
|
@@ -11590,19 +11583,19 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
|
|
|
11590
11583
|
|
|
11591
11584
|
_defineProperty(_assertThisInitialized(_this), "renderSourceElement", function (source, index) {
|
|
11592
11585
|
if (typeof source === 'string') {
|
|
11593
|
-
return
|
|
11586
|
+
return _react["default"].createElement("source", {
|
|
11594
11587
|
key: index,
|
|
11595
11588
|
src: source
|
|
11596
11589
|
});
|
|
11597
11590
|
}
|
|
11598
11591
|
|
|
11599
|
-
return
|
|
11592
|
+
return _react["default"].createElement("source", _extends({
|
|
11600
11593
|
key: index
|
|
11601
11594
|
}, source));
|
|
11602
11595
|
});
|
|
11603
11596
|
|
|
11604
11597
|
_defineProperty(_assertThisInitialized(_this), "renderTrack", function (track, index) {
|
|
11605
|
-
return
|
|
11598
|
+
return _react["default"].createElement("track", _extends({
|
|
11606
11599
|
key: index
|
|
11607
11600
|
}, track));
|
|
11608
11601
|
});
|
|
@@ -11640,10 +11633,6 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
|
|
|
11640
11633
|
key: "componentWillUnmount",
|
|
11641
11634
|
value: function componentWillUnmount() {
|
|
11642
11635
|
this.removeListeners(this.player);
|
|
11643
|
-
|
|
11644
|
-
if (this.hls) {
|
|
11645
|
-
this.hls.destroy();
|
|
11646
|
-
}
|
|
11647
11636
|
}
|
|
11648
11637
|
}, {
|
|
11649
11638
|
key: "addListeners",
|
|
@@ -11774,6 +11763,10 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
|
|
|
11774
11763
|
value: function stop() {
|
|
11775
11764
|
this.player.removeAttribute('src');
|
|
11776
11765
|
|
|
11766
|
+
if (this.hls) {
|
|
11767
|
+
this.hls.destroy();
|
|
11768
|
+
}
|
|
11769
|
+
|
|
11777
11770
|
if (this.dash) {
|
|
11778
11771
|
this.dash.reset();
|
|
11779
11772
|
}
|
|
@@ -11885,7 +11878,7 @@ var FilePlayer = /*#__PURE__*/function (_Component) {
|
|
|
11885
11878
|
width: width === 'auto' ? width : '100%',
|
|
11886
11879
|
height: height === 'auto' ? height : '100%'
|
|
11887
11880
|
};
|
|
11888
|
-
return
|
|
11881
|
+
return _react["default"].createElement(Element, _extends({
|
|
11889
11882
|
ref: this.ref,
|
|
11890
11883
|
src: this.getSource(url),
|
|
11891
11884
|
style: style,
|
|
@@ -11975,16 +11968,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
11975
11968
|
|
|
11976
11969
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
11977
11970
|
|
|
11978
|
-
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); }; }
|
|
11979
|
-
|
|
11980
11971
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
11981
11972
|
|
|
11982
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
11983
|
-
|
|
11984
|
-
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; } }
|
|
11985
|
-
|
|
11986
11973
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
11987
11974
|
|
|
11975
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
11976
|
+
|
|
11988
11977
|
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); }
|
|
11989
11978
|
|
|
11990
11979
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -11993,12 +11982,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
11993
11982
|
|
|
11994
11983
|
var ICON_SIZE = '64px';
|
|
11995
11984
|
|
|
11996
|
-
var Preview =
|
|
11985
|
+
var Preview =
|
|
11986
|
+
/*#__PURE__*/
|
|
11987
|
+
function (_Component) {
|
|
11997
11988
|
_inherits(Preview, _Component);
|
|
11998
11989
|
|
|
11999
|
-
var _super = _createSuper(Preview);
|
|
12000
|
-
|
|
12001
11990
|
function Preview() {
|
|
11991
|
+
var _getPrototypeOf2;
|
|
11992
|
+
|
|
12002
11993
|
var _this;
|
|
12003
11994
|
|
|
12004
11995
|
_classCallCheck(this, Preview);
|
|
@@ -12007,7 +11998,7 @@ var Preview = /*#__PURE__*/function (_Component) {
|
|
|
12007
11998
|
args[_key] = arguments[_key];
|
|
12008
11999
|
}
|
|
12009
12000
|
|
|
12010
|
-
_this =
|
|
12001
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(Preview)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
12011
12002
|
|
|
12012
12003
|
_defineProperty(_assertThisInitialized(_this), "mounted", false);
|
|
12013
12004
|
|
|
@@ -12105,15 +12096,15 @@ var Preview = /*#__PURE__*/function (_Component) {
|
|
|
12105
12096
|
}
|
|
12106
12097
|
};
|
|
12107
12098
|
|
|
12108
|
-
var defaultPlayIcon =
|
|
12099
|
+
var defaultPlayIcon = _react["default"].createElement("div", {
|
|
12109
12100
|
style: styles.shadow,
|
|
12110
12101
|
className: "react-player__shadow"
|
|
12111
|
-
},
|
|
12102
|
+
}, _react["default"].createElement("div", {
|
|
12112
12103
|
style: styles.playIcon,
|
|
12113
12104
|
className: "react-player__play-icon"
|
|
12114
12105
|
}));
|
|
12115
12106
|
|
|
12116
|
-
return
|
|
12107
|
+
return _react["default"].createElement("div", {
|
|
12117
12108
|
style: styles.preview,
|
|
12118
12109
|
className: "react-player__preview",
|
|
12119
12110
|
onClick: onClick
|
|
@@ -12150,12 +12141,6 @@ var _Player = _interopRequireDefault(Player_1);
|
|
|
12150
12141
|
|
|
12151
12142
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
12152
12143
|
|
|
12153
|
-
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; } } }; }
|
|
12154
|
-
|
|
12155
|
-
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); }
|
|
12156
|
-
|
|
12157
|
-
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; }
|
|
12158
|
-
|
|
12159
12144
|
var PRELOAD_PLAYERS = [{
|
|
12160
12145
|
Player: YouTube_1.YouTube,
|
|
12161
12146
|
configKey: 'youtube',
|
|
@@ -12176,16 +12161,16 @@ var PRELOAD_PLAYERS = [{
|
|
|
12176
12161
|
|
|
12177
12162
|
function renderPreloadPlayers(url, controls, config) {
|
|
12178
12163
|
var players = [];
|
|
12179
|
-
|
|
12180
|
-
var
|
|
12181
|
-
|
|
12164
|
+
var _iteratorNormalCompletion = true;
|
|
12165
|
+
var _didIteratorError = false;
|
|
12166
|
+
var _iteratorError = undefined;
|
|
12182
12167
|
|
|
12183
12168
|
try {
|
|
12184
|
-
for (_iterator.
|
|
12169
|
+
for (var _iterator = PRELOAD_PLAYERS[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
|
|
12185
12170
|
var player = _step.value;
|
|
12186
12171
|
|
|
12187
12172
|
if (!player.Player.canPlay(url) && config[player.configKey].preload) {
|
|
12188
|
-
players.push(
|
|
12173
|
+
players.push(_react["default"].createElement(_Player["default"], {
|
|
12189
12174
|
key: player.Player.displayName,
|
|
12190
12175
|
activePlayer: player.Player,
|
|
12191
12176
|
url: player.url,
|
|
@@ -12197,9 +12182,18 @@ function renderPreloadPlayers(url, controls, config) {
|
|
|
12197
12182
|
}
|
|
12198
12183
|
}
|
|
12199
12184
|
} catch (err) {
|
|
12200
|
-
|
|
12185
|
+
_didIteratorError = true;
|
|
12186
|
+
_iteratorError = err;
|
|
12201
12187
|
} finally {
|
|
12202
|
-
|
|
12188
|
+
try {
|
|
12189
|
+
if (!_iteratorNormalCompletion && _iterator["return"] != null) {
|
|
12190
|
+
_iterator["return"]();
|
|
12191
|
+
}
|
|
12192
|
+
} finally {
|
|
12193
|
+
if (_didIteratorError) {
|
|
12194
|
+
throw _iteratorError;
|
|
12195
|
+
}
|
|
12196
|
+
}
|
|
12203
12197
|
}
|
|
12204
12198
|
|
|
12205
12199
|
return players;
|
|
@@ -12323,17 +12317,13 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
|
|
|
12323
12317
|
|
|
12324
12318
|
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); }
|
|
12325
12319
|
|
|
12326
|
-
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) ||
|
|
12320
|
+
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _nonIterableSpread(); }
|
|
12327
12321
|
|
|
12328
|
-
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance
|
|
12322
|
+
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance"); }
|
|
12329
12323
|
|
|
12330
|
-
function
|
|
12324
|
+
function _iterableToArray(iter) { if (Symbol.iterator in Object(iter) || Object.prototype.toString.call(iter) === "[object Arguments]") return Array.from(iter); }
|
|
12331
12325
|
|
|
12332
|
-
function
|
|
12333
|
-
|
|
12334
|
-
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
12335
|
-
|
|
12336
|
-
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; }
|
|
12326
|
+
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; } }
|
|
12337
12327
|
|
|
12338
12328
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
12339
12329
|
|
|
@@ -12341,16 +12331,12 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
|
12341
12331
|
|
|
12342
12332
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
12343
12333
|
|
|
12344
|
-
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); }; }
|
|
12345
|
-
|
|
12346
12334
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
12347
12335
|
|
|
12348
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
12349
|
-
|
|
12350
|
-
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; } }
|
|
12351
|
-
|
|
12352
12336
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
12353
12337
|
|
|
12338
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
12339
|
+
|
|
12354
12340
|
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); }
|
|
12355
12341
|
|
|
12356
12342
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
@@ -12360,12 +12346,14 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
12360
12346
|
var SUPPORTED_PROPS = Object.keys(props.propTypes);
|
|
12361
12347
|
var customPlayers = [];
|
|
12362
12348
|
|
|
12363
|
-
var ReactPlayer =
|
|
12349
|
+
var ReactPlayer =
|
|
12350
|
+
/*#__PURE__*/
|
|
12351
|
+
function (_Component) {
|
|
12364
12352
|
_inherits(ReactPlayer, _Component);
|
|
12365
12353
|
|
|
12366
|
-
var _super = _createSuper(ReactPlayer);
|
|
12367
|
-
|
|
12368
12354
|
function ReactPlayer() {
|
|
12355
|
+
var _getPrototypeOf2;
|
|
12356
|
+
|
|
12369
12357
|
var _this;
|
|
12370
12358
|
|
|
12371
12359
|
_classCallCheck(this, ReactPlayer);
|
|
@@ -12374,7 +12362,7 @@ var ReactPlayer = /*#__PURE__*/function (_Component) {
|
|
|
12374
12362
|
args[_key] = arguments[_key];
|
|
12375
12363
|
}
|
|
12376
12364
|
|
|
12377
|
-
_this =
|
|
12365
|
+
_this = _possibleConstructorReturn(this, (_getPrototypeOf2 = _getPrototypeOf(ReactPlayer)).call.apply(_getPrototypeOf2, [this].concat(args)));
|
|
12378
12366
|
|
|
12379
12367
|
_defineProperty(_assertThisInitialized(_this), "config", (0, utils.getConfig)(_this.props, props.defaultProps, true));
|
|
12380
12368
|
|
|
@@ -12485,7 +12473,7 @@ var ReactPlayer = /*#__PURE__*/function (_Component) {
|
|
|
12485
12473
|
key: "renderActivePlayer",
|
|
12486
12474
|
value: function renderActivePlayer(url, activePlayer) {
|
|
12487
12475
|
if (!url) return null;
|
|
12488
|
-
return
|
|
12476
|
+
return _react["default"].createElement(_Player4["default"], _extends({}, this.props, {
|
|
12489
12477
|
key: activePlayer.displayName,
|
|
12490
12478
|
ref: this.activePlayerRef,
|
|
12491
12479
|
config: this.config,
|
|
@@ -12522,14 +12510,14 @@ var ReactPlayer = /*#__PURE__*/function (_Component) {
|
|
|
12522
12510
|
var preloadPlayers = (0, _preload["default"])(url, controls, this.config);
|
|
12523
12511
|
var players = [renderedActivePlayer].concat(_toConsumableArray(preloadPlayers)).sort(this.sortPlayers);
|
|
12524
12512
|
|
|
12525
|
-
var preview =
|
|
12513
|
+
var preview = _react["default"].createElement(_Preview["default"], {
|
|
12526
12514
|
url: url,
|
|
12527
12515
|
light: light,
|
|
12528
12516
|
playIcon: playIcon,
|
|
12529
12517
|
onClick: this.handleClickPreview
|
|
12530
12518
|
});
|
|
12531
12519
|
|
|
12532
|
-
return
|
|
12520
|
+
return _react["default"].createElement(Wrapper, _extends({
|
|
12533
12521
|
ref: this.wrapperRef,
|
|
12534
12522
|
style: _objectSpread({}, style, {
|
|
12535
12523
|
width: width,
|
|
@@ -13847,16 +13835,16 @@ var RelatedTopicsDropdown = function RelatedTopicsDropdown(_ref) {
|
|
|
13847
13835
|
_ref$className = _ref.className,
|
|
13848
13836
|
className = _ref$className === undefined ? '' : _ref$className;
|
|
13849
13837
|
|
|
13850
|
-
/*
|
|
13851
|
-
Props accepted - parentTaxonomy(required, object), subTaxonomy(required, array), page(optional), exclude(optional), variant(optional), className(optional)
|
|
13852
|
-
example:
|
|
13853
|
-
<RelatedTopicDropdown
|
|
13854
|
-
page='/clinical'
|
|
13855
|
-
exclude="clinical"
|
|
13856
|
-
className='mb-3'
|
|
13857
|
-
parentTaxonomy={props.parentTaxonomy}
|
|
13858
|
-
subTaxonomies={props.subTaxonomies}
|
|
13859
|
-
/>
|
|
13838
|
+
/*
|
|
13839
|
+
Props accepted - parentTaxonomy(required, object), subTaxonomy(required, array), page(optional), exclude(optional), variant(optional), className(optional)
|
|
13840
|
+
example:
|
|
13841
|
+
<RelatedTopicDropdown
|
|
13842
|
+
page='/clinical'
|
|
13843
|
+
exclude="clinical"
|
|
13844
|
+
className='mb-3'
|
|
13845
|
+
parentTaxonomy={props.parentTaxonomy}
|
|
13846
|
+
subTaxonomies={props.subTaxonomies}
|
|
13847
|
+
/>
|
|
13860
13848
|
*/
|
|
13861
13849
|
if (subTaxonomies.length === 0 && parentTaxonomy) {
|
|
13862
13850
|
if (parentTaxonomy.identifier == exclude) {
|
|
@@ -13894,19 +13882,19 @@ var RelatedTopicsDropdown = function RelatedTopicsDropdown(_ref) {
|
|
|
13894
13882
|
}
|
|
13895
13883
|
};
|
|
13896
13884
|
|
|
13897
|
-
/*
|
|
13898
|
-
This dropdown is used inside Article body to display related content placement pages
|
|
13899
|
-
sample usage: <ArticleDetailDropdown contentPlacement={content_placement} exclude={['News',]} />
|
|
13900
|
-
|
|
13901
|
-
in article query, need to add '...' to content_placement to retreive additional info needed
|
|
13902
|
-
|
|
13903
|
-
'content_placement': taxonomyMapping[]-> {
|
|
13904
|
-
...,
|
|
13905
|
-
'ancestor': parent->parent->identifier,
|
|
13906
|
-
'parent': parent->identifier,
|
|
13907
|
-
'path': identifier
|
|
13908
|
-
}
|
|
13909
|
-
|
|
13885
|
+
/*
|
|
13886
|
+
This dropdown is used inside Article body to display related content placement pages
|
|
13887
|
+
sample usage: <ArticleDetailDropdown contentPlacement={content_placement} exclude={['News',]} />
|
|
13888
|
+
|
|
13889
|
+
in article query, need to add '...' to content_placement to retreive additional info needed
|
|
13890
|
+
|
|
13891
|
+
'content_placement': taxonomyMapping[]-> {
|
|
13892
|
+
...,
|
|
13893
|
+
'ancestor': parent->parent->identifier,
|
|
13894
|
+
'parent': parent->identifier,
|
|
13895
|
+
'path': identifier
|
|
13896
|
+
}
|
|
13897
|
+
|
|
13910
13898
|
*/
|
|
13911
13899
|
|
|
13912
13900
|
var ArticleDetailDropdown = function ArticleDetailDropdown(props) {
|
|
@@ -14739,34 +14727,34 @@ var GridHero = function GridHero(props) {
|
|
|
14739
14727
|
);
|
|
14740
14728
|
};
|
|
14741
14729
|
|
|
14742
|
-
/*
|
|
14743
|
-
Sample query
|
|
14744
|
-
let references = ''
|
|
14745
|
-
if(article.taxonomyMapping.length > 0){
|
|
14746
|
-
article.taxonomyMapping.forEach((ref, index) => {
|
|
14747
|
-
references = references + `references('${ref._ref}') `
|
|
14748
|
-
if(index+1 !== article.taxonomyMapping.length){
|
|
14749
|
-
references = references + ` && `
|
|
14750
|
-
}
|
|
14751
|
-
})
|
|
14752
|
-
}
|
|
14753
|
-
|
|
14754
|
-
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] {
|
|
14755
|
-
...,
|
|
14756
|
-
title,
|
|
14757
|
-
summary,
|
|
14758
|
-
thumbnail,
|
|
14759
|
-
url,
|
|
14760
|
-
published,
|
|
14761
|
-
authorMapping[]->,
|
|
14762
|
-
contentCategory->
|
|
14763
|
-
}`
|
|
14764
|
-
const relatedArticles = await client.fetch(relatedArticlesQuery)
|
|
14765
|
-
|
|
14766
|
-
Sample usage
|
|
14767
|
-
<RelatedContent dataRecord={props.relatedArticles} client={client} showAuthor showPublished reverse/>
|
|
14768
|
-
|
|
14769
|
-
|
|
14730
|
+
/*
|
|
14731
|
+
Sample query
|
|
14732
|
+
let references = ''
|
|
14733
|
+
if(article.taxonomyMapping.length > 0){
|
|
14734
|
+
article.taxonomyMapping.forEach((ref, index) => {
|
|
14735
|
+
references = references + `references('${ref._ref}') `
|
|
14736
|
+
if(index+1 !== article.taxonomyMapping.length){
|
|
14737
|
+
references = references + ` && `
|
|
14738
|
+
}
|
|
14739
|
+
})
|
|
14740
|
+
}
|
|
14741
|
+
|
|
14742
|
+
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] {
|
|
14743
|
+
...,
|
|
14744
|
+
title,
|
|
14745
|
+
summary,
|
|
14746
|
+
thumbnail,
|
|
14747
|
+
url,
|
|
14748
|
+
published,
|
|
14749
|
+
authorMapping[]->,
|
|
14750
|
+
contentCategory->
|
|
14751
|
+
}`
|
|
14752
|
+
const relatedArticles = await client.fetch(relatedArticlesQuery)
|
|
14753
|
+
|
|
14754
|
+
Sample usage
|
|
14755
|
+
<RelatedContent dataRecord={props.relatedArticles} client={client} showAuthor showPublished reverse/>
|
|
14756
|
+
|
|
14757
|
+
|
|
14770
14758
|
*/
|
|
14771
14759
|
var RelatedContent = function RelatedContent(props) {
|
|
14772
14760
|
var client = props.client,
|
|
@@ -14833,21 +14821,21 @@ var RelatedContent = function RelatedContent(props) {
|
|
|
14833
14821
|
);
|
|
14834
14822
|
};
|
|
14835
14823
|
|
|
14836
|
-
/*
|
|
14837
|
-
Example usage - targetedonc.com/latest-conference
|
|
14838
|
-
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] {
|
|
14839
|
-
...,
|
|
14840
|
-
title,
|
|
14841
|
-
summary,
|
|
14842
|
-
thumbnail,
|
|
14843
|
-
url,
|
|
14844
|
-
published,
|
|
14845
|
-
documentGroup->,
|
|
14846
|
-
contentCategory->,
|
|
14847
|
-
'pageNumber': ${currentPage}
|
|
14848
|
-
}`
|
|
14849
|
-
|
|
14850
|
-
const posts = await client.fetch(query, params)
|
|
14824
|
+
/*
|
|
14825
|
+
Example usage - targetedonc.com/latest-conference
|
|
14826
|
+
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] {
|
|
14827
|
+
...,
|
|
14828
|
+
title,
|
|
14829
|
+
summary,
|
|
14830
|
+
thumbnail,
|
|
14831
|
+
url,
|
|
14832
|
+
published,
|
|
14833
|
+
documentGroup->,
|
|
14834
|
+
contentCategory->,
|
|
14835
|
+
'pageNumber': ${currentPage}
|
|
14836
|
+
}`
|
|
14837
|
+
|
|
14838
|
+
const posts = await client.fetch(query, params)
|
|
14851
14839
|
*/
|
|
14852
14840
|
|
|
14853
14841
|
var ConferenceArticleCard = function ConferenceArticleCard(props) {
|