oolib 2.73.0 → 2.73.1
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.
|
@@ -101,9 +101,9 @@ var ButtonStyledWrapper = function (_a) {
|
|
|
101
101
|
preventDefault && e.preventDefault();
|
|
102
102
|
debouncedMouseDown && debouncedMouseDown(e);
|
|
103
103
|
}, composition: composition, width: width, color: color, forceHover: forceHover },
|
|
104
|
-
icon && react_1.default.createElement(DisplayIcon, { icon: icon, color: iconColor, size: calcIconSize(), iconWeight: iconWeight }),
|
|
104
|
+
icon && react_1.default.createElement(DisplayIcon, { icon: icon, color: iconColor, size: calcIconSize(), iconWeight: iconWeight || '' }),
|
|
105
105
|
displayText && react_1.default.createElement(Typo_1.SANS_3, { semibold: true }, displayText),
|
|
106
|
-
iconAfter && react_1.default.createElement(DisplayIcon, { icon: iconAfter, color: iconColor, size: calcIconSize(), iconWeight: iconWeight })));
|
|
106
|
+
iconAfter && react_1.default.createElement(DisplayIcon, { icon: iconAfter, color: iconColor, size: calcIconSize(), iconWeight: iconWeight || '' })));
|
|
107
107
|
};
|
|
108
108
|
var Button = function (_a) {
|
|
109
109
|
var props = _a.props, variant = _a.variant;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
export function VideoActionMenu({ isInRTE, value, inputRef, setShowEmbedLinkModal, onChange, isUploadedVideo, invert }: {
|
|
1
|
+
export function VideoActionMenu({ id, isInRTE, value, inputRef, setShowEmbedLinkModal, onChange, isUploadedVideo, invert }: {
|
|
2
|
+
id: any;
|
|
2
3
|
isInRTE: any;
|
|
3
4
|
value: any;
|
|
4
5
|
inputRef: any;
|
|
@@ -19,20 +19,20 @@ var react_1 = __importDefault(require("react"));
|
|
|
19
19
|
var styled_1 = require("../styled");
|
|
20
20
|
var ActionMenu_1 = require("../../ActionMenu");
|
|
21
21
|
var VideoActionMenu = function (_a) {
|
|
22
|
-
var isInRTE = _a.isInRTE, value = _a.value, inputRef = _a.inputRef, setShowEmbedLinkModal = _a.setShowEmbedLinkModal, onChange = _a.onChange, isUploadedVideo = _a.isUploadedVideo, invert = _a.invert;
|
|
22
|
+
var id = _a.id, isInRTE = _a.isInRTE, value = _a.value, inputRef = _a.inputRef, setShowEmbedLinkModal = _a.setShowEmbedLinkModal, onChange = _a.onChange, isUploadedVideo = _a.isUploadedVideo, invert = _a.invert;
|
|
23
23
|
return (react_1.default.createElement(styled_1.StyledActionButtonWrapper, null,
|
|
24
24
|
react_1.default.createElement("div", { style: __assign({}, (isInRTE ? { display: "none" } : {})) },
|
|
25
25
|
react_1.default.createElement(ActionMenu_1.ActionMenu, { popOutOfOverflowHiddenParent: true, ButtonComp: "ButtonPrimary", iconSize: "M", invert: invert, actions: [
|
|
26
26
|
isUploadedVideo(value) // Only allow user to replace URL when embed method is URL
|
|
27
27
|
? {
|
|
28
|
-
id: "
|
|
28
|
+
id: "".concat(id, "_uploadNewVideo"),
|
|
29
29
|
display: "Upload New Video",
|
|
30
30
|
onClick: function () {
|
|
31
31
|
inputRef.current.click(); // Trigger file explorer popup
|
|
32
32
|
},
|
|
33
33
|
}
|
|
34
34
|
: {
|
|
35
|
-
id: "
|
|
35
|
+
id: "".concat(id, "_replaceUrl"),
|
|
36
36
|
display: "Replace URL",
|
|
37
37
|
onClick: function (e) {
|
|
38
38
|
setShowEmbedLinkModal(true);
|
|
@@ -115,7 +115,7 @@ function VideoInput(_a) {
|
|
|
115
115
|
url.split("&list=")[0].match(regex)[1];
|
|
116
116
|
}
|
|
117
117
|
return (react_1.default.createElement(styled_1.StyledVideoEmbedPreviewSection, { style: { height: height } },
|
|
118
|
-
actionMenuButton && react_1.default.createElement(VideoActionMenu_1.VideoActionMenu, __assign({},
|
|
118
|
+
actionMenuButton && react_1.default.createElement(VideoActionMenu_1.VideoActionMenu, __assign({}, { isInRTE: isInRTE, value: value, inputRef: inputRef, setShowEmbedLinkModal: setShowEmbedLinkModal, onChange: onChange, isUploadedVideo: isUploadedVideo, invert: invert, id: id })),
|
|
119
119
|
react_1.default.createElement(react_player_1.default, { id: "outVideo", url: url, controls: true, width: width || "100%", height: height, light: lightPlayer, style: { overflow: "hidden" } })));
|
|
120
120
|
}
|
|
121
121
|
};
|