@desynova-digital/player 4.0.32 → 4.0.33
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/actions/player.js
CHANGED
|
@@ -333,10 +333,21 @@ function handleMarkerUpdate(leftMarker, rightMarker) {
|
|
|
333
333
|
};
|
|
334
334
|
return data;
|
|
335
335
|
}
|
|
336
|
-
|
|
336
|
+
|
|
337
|
+
// export function handleSDBorderChange(SDBorderActive) {
|
|
338
|
+
// let data = {
|
|
339
|
+
// type: SD_BORDER_SWITCH,
|
|
340
|
+
// SDBorderActive
|
|
341
|
+
// };
|
|
342
|
+
|
|
343
|
+
// return data;
|
|
344
|
+
// }
|
|
345
|
+
|
|
346
|
+
function handleSDBorderChange(safeAreaObj) {
|
|
337
347
|
var data = {
|
|
338
348
|
type: SD_BORDER_SWITCH,
|
|
339
|
-
|
|
349
|
+
key: safeAreaObj.key,
|
|
350
|
+
value: safeAreaObj.value
|
|
340
351
|
};
|
|
341
352
|
return data;
|
|
342
353
|
}
|
|
@@ -126,7 +126,8 @@ var ChildMenuButton = /*#__PURE__*/function (_Component) {
|
|
|
126
126
|
subtitleData = _this$props3.subtitleData,
|
|
127
127
|
theme = _this$props3.theme,
|
|
128
128
|
player = _this$props3.player,
|
|
129
|
-
activeChild = _this$props3.activeChild
|
|
129
|
+
activeChild = _this$props3.activeChild,
|
|
130
|
+
actions = _this$props3.actions;
|
|
130
131
|
switch (mainHeader) {
|
|
131
132
|
case 'Subtitle':
|
|
132
133
|
return subtitleData.map(function (subtitle, index) {
|
|
@@ -32,7 +32,7 @@ var propTypes = {
|
|
|
32
32
|
player: _propTypes.PropTypes.instanceOf(Object),
|
|
33
33
|
theme: _propTypes.PropTypes.string
|
|
34
34
|
};
|
|
35
|
-
var SafeAreaBlock = (0, _styledComponents["default"])('div')(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n background: transparent;\n font-family: SFUIText-Medium;\n font-size: 12px;\n text-transform: uppercase;\n justify-content: flex-start;\n align-items: center;\n &:hover {\n background: ", ";\n }\n p {\n margin-left: 10px;\n white-space: nowrap;\n }\n"])), function (props) {
|
|
35
|
+
var SafeAreaBlock = (0, _styledComponents["default"])('div')(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n background: transparent;\n font-family: SFUIText-Medium;\n font-size: 12px;\n text-transform: uppercase;\n justify-content: flex-start;\n // align-items: center;\n flex-direction: column;\n width: 100%;\n &:hover {\n background: ", ";\n }\n p {\n margin-left: 10px;\n white-space: nowrap;\n }\n"])), function (props) {
|
|
36
36
|
return props.theme ? " ".concat(_tokens.colors[props.theme].videoPlayer.rgbaThemeColor) : 'rgba(0, 206, 198, 0.1)';
|
|
37
37
|
});
|
|
38
38
|
var SafeAreaControl = exports["default"] = /*#__PURE__*/function (_Component) {
|
|
@@ -49,30 +49,36 @@ var SafeAreaControl = exports["default"] = /*#__PURE__*/function (_Component) {
|
|
|
49
49
|
value: function handleClick() {
|
|
50
50
|
var _this$props = this.props,
|
|
51
51
|
player = _this$props.player,
|
|
52
|
-
actions = _this$props.actions
|
|
53
|
-
|
|
52
|
+
actions = _this$props.actions,
|
|
53
|
+
keyData = _this$props.keyData,
|
|
54
|
+
siblingData = _this$props.siblingData;
|
|
55
|
+
actions.handleSDBorderChange({
|
|
56
|
+
key: keyData,
|
|
57
|
+
value: !player[keyData]
|
|
58
|
+
});
|
|
59
|
+
actions.handleSDBorderChange({
|
|
60
|
+
key: siblingData,
|
|
61
|
+
value: false
|
|
62
|
+
});
|
|
54
63
|
}
|
|
55
64
|
}, {
|
|
56
65
|
key: "render",
|
|
57
66
|
value: function render() {
|
|
58
67
|
var _this$props2 = this.props,
|
|
59
68
|
player = _this$props2.player,
|
|
60
|
-
theme = _this$props2.theme
|
|
69
|
+
theme = _this$props2.theme,
|
|
70
|
+
keyData = _this$props2.keyData,
|
|
71
|
+
name = _this$props2.name;
|
|
61
72
|
return /*#__PURE__*/_react["default"].createElement(SafeAreaBlock, {
|
|
62
73
|
onClick: this.handleClick,
|
|
63
74
|
theme: theme
|
|
64
|
-
}, /*#__PURE__*/_react["default"].createElement(
|
|
65
|
-
|
|
66
|
-
width: 20,
|
|
67
|
-
height: 20,
|
|
68
|
-
color: player.SDBorderActive ? theme ? "".concat(_tokens.colors[theme].videoPlayer.themeColor) : '#00cec6' : '#333333'
|
|
69
|
-
}), /*#__PURE__*/_react["default"].createElement("p", {
|
|
70
|
-
style: player.SDBorderActive ? {
|
|
75
|
+
}, /*#__PURE__*/_react["default"].createElement("p", {
|
|
76
|
+
style: player[keyData] ? {
|
|
71
77
|
color: theme ? " ".concat(_tokens.colors[theme].videoPlayer.themeColor) : '#00cec6'
|
|
72
78
|
} : {
|
|
73
79
|
color: '#333333'
|
|
74
80
|
}
|
|
75
|
-
},
|
|
81
|
+
}, name));
|
|
76
82
|
}
|
|
77
83
|
}]);
|
|
78
84
|
}(_react.Component);
|
package/package.json
CHANGED
package/reducers/player.js
CHANGED
|
@@ -22,7 +22,10 @@ var initialState = {
|
|
|
22
22
|
rightMarker: -1,
|
|
23
23
|
selectedMarker: {},
|
|
24
24
|
markerType: 'create',
|
|
25
|
-
SDBorderActive:
|
|
25
|
+
SDBorderActive: true,
|
|
26
|
+
HDBorderActive: true,
|
|
27
|
+
fourThreeSafeArea: true,
|
|
28
|
+
sixteenNineSafeArea: true,
|
|
26
29
|
buffered: null,
|
|
27
30
|
waiting: false,
|
|
28
31
|
seeking: false,
|
|
@@ -199,10 +202,13 @@ function player() {
|
|
|
199
202
|
return _objectSpread(_objectSpread({}, state), {}, {
|
|
200
203
|
controlType: action.controlType
|
|
201
204
|
});
|
|
205
|
+
// case SD_BORDER_SWITCH:
|
|
206
|
+
// return {
|
|
207
|
+
// ...state,
|
|
208
|
+
// SDBorderActive: action.SDBorderActive
|
|
209
|
+
// };
|
|
202
210
|
case _player.SD_BORDER_SWITCH:
|
|
203
|
-
return _objectSpread(_objectSpread({}, state), {}, {
|
|
204
|
-
SDBorderActive: action.SDBorderActive
|
|
205
|
-
});
|
|
211
|
+
return _objectSpread(_objectSpread({}, state), {}, _defineProperty({}, action.key, action.value));
|
|
206
212
|
case _player.SUBTITLE_STATUS:
|
|
207
213
|
return _objectSpread(_objectSpread({}, state), {}, {
|
|
208
214
|
SubtitleStatus: action.SubtitleStatus
|