@flozy/editor 9.0.4 → 9.0.5
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.
@@ -43,19 +43,21 @@ const ColorPicker = props => {
|
|
43
43
|
};
|
44
44
|
const handleFormSubmit = color => {
|
45
45
|
if (!color) return;
|
46
|
-
selection && Transforms.select(editor, selection);
|
46
|
+
// selection && Transforms.select(editor, selection);
|
47
47
|
addMarkData(editor, {
|
48
48
|
format,
|
49
49
|
value: color
|
50
50
|
});
|
51
|
-
selection && ReactEditor.focus(editor);
|
52
|
-
handleClose();
|
51
|
+
// selection && ReactEditor.focus(editor);
|
52
|
+
// handleClose();
|
53
53
|
};
|
54
|
+
|
54
55
|
const onSelect = color => {
|
55
56
|
handleFormSubmit(color);
|
56
57
|
};
|
57
58
|
const handleClose = () => {
|
58
59
|
setAnchorEl(null);
|
60
|
+
setSelection(null);
|
59
61
|
};
|
60
62
|
const activeColor = activeMark(editor, format) || DEFAULT_COLOR[format];
|
61
63
|
return /*#__PURE__*/_jsxs(_Fragment, {
|
@@ -869,14 +869,19 @@ const usePopupStyle = theme => ({
|
|
869
869
|
overflow: "auto",
|
870
870
|
backgroundColor: theme?.palette?.editor?.background,
|
871
871
|
borderRadius: "14px !important",
|
872
|
-
border: `1px solid ${theme?.palette?.editor?.inputFieldBorder} !important
|
872
|
+
border: `1px solid ${theme?.palette?.editor?.inputFieldBorder} !important`,
|
873
|
+
minWidth: "fit-content",
|
874
|
+
"@media only screen and (max-width: 599px)": {
|
875
|
+
left: "0px !important"
|
876
|
+
}
|
873
877
|
},
|
874
878
|
"& .popup_tabs": {
|
875
|
-
backgroundColor: theme?.palette?.editor?.inputFieldBgColor
|
876
|
-
"@media only screen and (max-width:
|
877
|
-
|
878
|
-
}
|
879
|
+
backgroundColor: theme?.palette?.editor?.inputFieldBgColor
|
880
|
+
// "@media only screen and (max-width: 599px)": {
|
881
|
+
// width: "100% !important",
|
882
|
+
// },
|
879
883
|
},
|
884
|
+
|
880
885
|
"& .popup_tabs-header": {
|
881
886
|
fontFamily: "Inter, sans-serif",
|
882
887
|
fontWeight: 700,
|