@desynova-digital/player 4.0.19 → 4.0.20
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/Manager.js +15 -17
- package/actions/player.js +18 -35
- package/actions/video.js +25 -50
- package/colors.js +1 -2
- package/components/AudioMeter.js +31 -34
- package/components/BigPlayButton.js +23 -26
- package/components/ImageViewer.js +25 -28
- package/components/MarkerBar.js +23 -26
- package/components/Menu.js +2 -2
- package/components/Player.js +36 -39
- package/components/PlayerHeader.js +23 -26
- package/components/Playlist.js +25 -25
- package/components/PointersBar.js +31 -30
- package/components/PosterImage.js +2 -3
- package/components/SDOutline.js +2 -2
- package/components/Shortcut.js +45 -49
- package/components/Slider.js +34 -36
- package/components/TagsBar.js +22 -25
- package/components/Video.js +61 -65
- package/components/control-bar/AudioTracksMenuButton.js +21 -24
- package/components/control-bar/CameraButton.js +22 -25
- package/components/control-bar/CaptionControlMenuButton.js +22 -25
- package/components/control-bar/CommentsButton.js +23 -26
- package/components/control-bar/ControlBar.js +24 -27
- package/components/control-bar/EditorControlMenuButton.js +23 -26
- package/components/control-bar/ForwardControl.js +2 -3
- package/components/control-bar/ForwardReplayControl.js +23 -26
- package/components/control-bar/FullscreenToggle.js +22 -25
- package/components/control-bar/PlayToggle.js +22 -25
- package/components/control-bar/ReplayControl.js +2 -3
- package/components/control-bar/SettingsMenuButton.js +4 -4
- package/components/control-bar/SubtitleLanguagesMenuButton.js +21 -24
- package/components/control-bar/SubtitleMovementMenu.js +23 -26
- package/components/control-bar/VolumeMenuButton.js +23 -26
- package/components/control-bar/ZoomMenuButton.js +23 -26
- package/components/marking-controls/MarkInControl.js +22 -25
- package/components/marking-controls/MarkOutControl.js +22 -25
- package/components/marking-controls/MarkingAddButton.js +22 -25
- package/components/marking-controls/MarkingControl.js +2 -2
- package/components/marking-controls/MarkingDeleteButton.js +22 -25
- package/components/marking-controls/MarkingDuration.js +2 -2
- package/components/marking-controls/MarkingPreview.js +22 -25
- package/components/progress-bar/AudioWaveform.js +22 -25
- package/components/progress-bar/LoadProgressBar.js +1 -1
- package/components/progress-bar/MouseTimeDisplay.js +2 -3
- package/components/progress-bar/PlayProgressBar.js +2 -2
- package/components/progress-bar/ProgressControl.js +45 -40
- package/components/progress-bar/SeekBar.js +29 -32
- package/components/progress-bar/Timeline.js +22 -25
- package/components/settings-menu-control/CameraControl.js +6 -7
- package/components/settings-menu-control/ChildMenuComponent.js +25 -29
- package/components/settings-menu-control/ParentMenuComponent.js +22 -25
- package/components/settings-menu-control/PlaybackRateControl.js +22 -25
- package/components/settings-menu-control/SafeAreaControl.js +22 -25
- package/components/settings-menu-control/SettingsMenu.js +13 -13
- package/components/time-controls/CurrentTimeDisplay.js +11 -12
- package/components/time-controls/DurationDisplay.js +3 -4
- package/components/time-controls/TimeDivider.js +2 -2
- package/components/volume-control/VolumeBar.js +31 -34
- package/components/volume-control/VolumeControl.js +1 -1
- package/components/volume-control/VolumeLevel.js +3 -4
- package/components/zoom-control/ZoomBar.js +30 -33
- package/components/zoom-control/ZoomLevel.js +3 -4
- package/index.js +4 -4
- package/package.json +1 -1
- package/reducers/index.js +2 -4
- package/reducers/operation.js +7 -8
- package/reducers/player.js +7 -9
- package/utils/browser.js +4 -8
- package/utils/fullscreen.js +8 -10
- package/utils/index.js +13 -14
package/utils/browser.js
CHANGED
|
@@ -18,17 +18,13 @@ var USER_AGENT = typeof window !== 'undefined' && window.navigator ? window.navi
|
|
|
18
18
|
* @constant
|
|
19
19
|
* @private
|
|
20
20
|
*/
|
|
21
|
-
var IS_IPAD = /iPad/i.test(USER_AGENT);
|
|
21
|
+
var IS_IPAD = exports.IS_IPAD = /iPad/i.test(USER_AGENT);
|
|
22
22
|
|
|
23
23
|
/*
|
|
24
24
|
* The Facebook app's UIWebView identifies as both an iPhone and iPad, so
|
|
25
25
|
* to identify iPhones, we need to exclude iPads.
|
|
26
26
|
* http://artsy.github.io/blog/2012/10/18/the-perils-of-ios-user-agent-sniffing/
|
|
27
27
|
*/
|
|
28
|
-
exports.
|
|
29
|
-
var
|
|
30
|
-
exports.
|
|
31
|
-
var IS_IPOD = /iPod/i.test(USER_AGENT);
|
|
32
|
-
exports.IS_IPOD = IS_IPOD;
|
|
33
|
-
var IS_IOS = IS_IPHONE || IS_IPAD || IS_IPOD;
|
|
34
|
-
exports.IS_IOS = IS_IOS;
|
|
28
|
+
var IS_IPHONE = exports.IS_IPHONE = /iPhone/i.test(USER_AGENT) && !IS_IPAD;
|
|
29
|
+
var IS_IPOD = exports.IS_IPOD = /iPod/i.test(USER_AGENT);
|
|
30
|
+
var IS_IOS = exports.IS_IOS = IS_IPHONE || IS_IPAD || IS_IPOD;
|
package/utils/fullscreen.js
CHANGED
|
@@ -4,17 +4,17 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports["default"] = void 0;
|
|
7
|
-
function _typeof(
|
|
8
|
-
function _classCallCheck(
|
|
9
|
-
function _defineProperties(
|
|
10
|
-
function _createClass(
|
|
11
|
-
function _toPropertyKey(
|
|
12
|
-
function _toPrimitive(
|
|
7
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
8
|
+
function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
|
|
9
|
+
function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
|
|
10
|
+
function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
|
|
11
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
12
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
13
13
|
var Fullscreen = /*#__PURE__*/function () {
|
|
14
14
|
function Fullscreen() {
|
|
15
15
|
_classCallCheck(this, Fullscreen);
|
|
16
16
|
}
|
|
17
|
-
_createClass(Fullscreen, [{
|
|
17
|
+
return _createClass(Fullscreen, [{
|
|
18
18
|
key: "request",
|
|
19
19
|
value: function request(elm) {
|
|
20
20
|
if (elm.requestFullscreen) {
|
|
@@ -67,7 +67,5 @@ var Fullscreen = /*#__PURE__*/function () {
|
|
|
67
67
|
document.removeEventListener('MSFullscreenChange', handler);
|
|
68
68
|
}
|
|
69
69
|
}]);
|
|
70
|
-
return Fullscreen;
|
|
71
70
|
}();
|
|
72
|
-
var _default = new Fullscreen();
|
|
73
|
-
exports["default"] = _default;
|
|
71
|
+
var _default = exports["default"] = new Fullscreen();
|
package/utils/index.js
CHANGED
|
@@ -13,19 +13,19 @@ exports.secondsToTime = secondsToTime;
|
|
|
13
13
|
exports.throttle = throttle;
|
|
14
14
|
exports.timeToSeconds = timeToSeconds;
|
|
15
15
|
var _react = _interopRequireDefault(require("react"));
|
|
16
|
-
function _interopRequireDefault(
|
|
17
|
-
function _typeof(
|
|
18
|
-
function _toConsumableArray(
|
|
16
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
|
17
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
18
|
+
function _toConsumableArray(r) { return _arrayWithoutHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableSpread(); }
|
|
19
19
|
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
20
|
-
function _unsupportedIterableToArray(
|
|
21
|
-
function _iterableToArray(
|
|
22
|
-
function _arrayWithoutHoles(
|
|
23
|
-
function _arrayLikeToArray(
|
|
24
|
-
function ownKeys(
|
|
25
|
-
function _objectSpread(
|
|
26
|
-
function _defineProperty(
|
|
27
|
-
function _toPropertyKey(
|
|
28
|
-
function _toPrimitive(
|
|
20
|
+
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
21
|
+
function _iterableToArray(r) { if ("undefined" != typeof Symbol && null != r[Symbol.iterator] || null != r["@@iterator"]) return Array.from(r); }
|
|
22
|
+
function _arrayWithoutHoles(r) { if (Array.isArray(r)) return _arrayLikeToArray(r); }
|
|
23
|
+
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
24
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
25
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
26
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
27
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
28
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
29
29
|
/**
|
|
30
30
|
* @file seconds-to-time.js
|
|
31
31
|
*
|
|
@@ -225,14 +225,13 @@ function throttle(callback, limit) {
|
|
|
225
225
|
}
|
|
226
226
|
};
|
|
227
227
|
}
|
|
228
|
-
var mediaProperties = ['error', 'src', 'srcObject', 'currentSrc', 'crossOrigin', 'networkState', 'preload', 'buffered', 'readyState', 'seeking', 'currentTime', 'duration', 'paused', 'defaultPlaybackRate', 'playbackRate', 'played', 'seekable', 'ended', 'autoplay', 'loop', 'mediaGroup', 'controller', 'controls', 'volume', 'muted', 'defaultMuted', 'audioTracks', 'videoTracks', 'textTracks', 'width', 'height', 'videoWidth', 'videoHeight', 'poster'];
|
|
228
|
+
var mediaProperties = exports.mediaProperties = ['error', 'src', 'srcObject', 'currentSrc', 'crossOrigin', 'networkState', 'preload', 'buffered', 'readyState', 'seeking', 'currentTime', 'duration', 'paused', 'defaultPlaybackRate', 'playbackRate', 'played', 'seekable', 'ended', 'autoplay', 'loop', 'mediaGroup', 'controller', 'controls', 'volume', 'muted', 'defaultMuted', 'audioTracks', 'videoTracks', 'textTracks', 'width', 'height', 'videoWidth', 'videoHeight', 'poster'];
|
|
229
229
|
|
|
230
230
|
/**
|
|
231
231
|
*
|
|
232
232
|
* @param {Number} currentTime current time of video
|
|
233
233
|
* @returns adjusting the current time to the nearest frame
|
|
234
234
|
*/
|
|
235
|
-
exports.mediaProperties = mediaProperties;
|
|
236
235
|
function handleAdjustingVideoAsPerFrame(currentTime) {
|
|
237
236
|
var frameRate = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 25;
|
|
238
237
|
var frameDuration = 1 / frameRate;
|