@flozy/editor 4.3.6 → 4.3.8
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/dist/Editor/Editor.css
CHANGED
|
@@ -609,10 +609,14 @@ blockquote {
|
|
|
609
609
|
left: 0;
|
|
610
610
|
right: 0;
|
|
611
611
|
bottom: 0;
|
|
612
|
-
top:
|
|
612
|
+
top: auto;
|
|
613
613
|
width: fit-content;
|
|
614
614
|
height: fit-content;
|
|
615
|
-
margin: auto;
|
|
615
|
+
margin-left: auto;
|
|
616
|
+
margin-right: auto;
|
|
617
|
+
background: #000000b6;
|
|
618
|
+
padding: 6px 10px 2px 10px;
|
|
619
|
+
border-radius: 8px 8px 0 0;
|
|
616
620
|
}
|
|
617
621
|
|
|
618
622
|
.embed-code .element-toolbar {
|
|
@@ -22,7 +22,8 @@ const EditorButton = props => {
|
|
|
22
22
|
} = props;
|
|
23
23
|
const {
|
|
24
24
|
readOnly,
|
|
25
|
-
metadata
|
|
25
|
+
metadata,
|
|
26
|
+
isMobile
|
|
26
27
|
} = customProps;
|
|
27
28
|
const editor = useSlateStatic();
|
|
28
29
|
const path = ReactEditor.findPath(editor, element);
|
|
@@ -66,6 +67,9 @@ const EditorButton = props => {
|
|
|
66
67
|
const BtnIcon = buttonIcon ? buttonIcon : null;
|
|
67
68
|
windowVar.lastButtonProps = element;
|
|
68
69
|
const handleTrigger = async () => {
|
|
70
|
+
if (!readOnly) {
|
|
71
|
+
return;
|
|
72
|
+
}
|
|
69
73
|
if (metadata?.buttonLink?.handler) {
|
|
70
74
|
const response = isTrigger ? linkType : "click";
|
|
71
75
|
metadata.buttonLink.handler(response);
|
|
@@ -265,21 +269,21 @@ const EditorButton = props => {
|
|
|
265
269
|
paddingRight: "4px"
|
|
266
270
|
},
|
|
267
271
|
props: customProps
|
|
268
|
-
}), !readOnly && /*#__PURE__*/_jsx(IconButton, {
|
|
269
|
-
className: `moreBtnShow ${openMoreOptions && "activeBtnShow"}`,
|
|
270
|
-
sx: {
|
|
271
|
-
position: "absolute",
|
|
272
|
-
right: '-42px',
|
|
273
|
-
stroke: '#fff',
|
|
274
|
-
"& path": {
|
|
275
|
-
fill: openMoreOptions ? theme.palette.text.blueText : ""
|
|
276
|
-
}
|
|
277
|
-
},
|
|
278
|
-
onClick: handleMoreBtn,
|
|
279
|
-
children: /*#__PURE__*/_jsx(Icon, {
|
|
280
|
-
icon: "moreVertical"
|
|
281
|
-
})
|
|
282
272
|
})]
|
|
273
|
+
}), !readOnly && /*#__PURE__*/_jsx(IconButton, {
|
|
274
|
+
className: `moreBtnShow ${isMobile || openMoreOptions ? "activeBtnShow" : ""}`,
|
|
275
|
+
sx: {
|
|
276
|
+
position: "absolute",
|
|
277
|
+
right: "-42px",
|
|
278
|
+
stroke: "#fff",
|
|
279
|
+
"& path": {
|
|
280
|
+
fill: openMoreOptions ? theme.palette.text.blueText : ""
|
|
281
|
+
}
|
|
282
|
+
},
|
|
283
|
+
onClick: handleMoreBtn,
|
|
284
|
+
children: /*#__PURE__*/_jsx(Icon, {
|
|
285
|
+
icon: "moreVertical"
|
|
286
|
+
})
|
|
283
287
|
}), !readOnly && isTrigger ? /*#__PURE__*/_jsx(IconButton, {
|
|
284
288
|
className: "workflow-icon-btn",
|
|
285
289
|
children: /*#__PURE__*/_jsx(WorkflowIcon, {})
|