@flozy/editor 5.3.4 → 5.3.6
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/CommonEditor.js +8 -14
- package/dist/Editor/Editor.css +22 -50
- package/dist/Editor/Elements/Accordion/Accordion.js +1 -8
- package/dist/Editor/Elements/AppHeader/AppHeader.js +6 -6
- package/dist/Editor/Elements/Button/EditorButton.js +2 -9
- package/dist/Editor/Elements/Color Picker/ColorButtons.js +2 -4
- package/dist/Editor/Elements/Divider/Divider.js +9 -24
- package/dist/Editor/Elements/Embed/Image.js +12 -31
- package/dist/Editor/Elements/Embed/Video.js +2 -13
- package/dist/Editor/Elements/Form/Form.js +0 -1
- package/dist/Editor/Elements/FreeGrid/breakpointConstants.js +4 -4
- package/dist/Editor/Elements/FreeGrid/styles.js +1 -2
- package/dist/Editor/Elements/Grid/GridItem.js +0 -2
- package/dist/Editor/Elements/Grid/Styles.js +0 -44
- package/dist/Editor/Elements/List/CheckList.js +1 -2
- package/dist/Editor/Elements/PageSettings/PageSettingsButton.js +0 -1
- package/dist/Editor/Elements/Search/SearchAttachment.js +0 -1
- package/dist/Editor/Elements/Signature/SignaturePopup.js +4 -4
- package/dist/Editor/Elements/SimpleText/index.js +1 -8
- package/dist/Editor/Elements/SimpleText/style.js +1 -10
- package/dist/Editor/Elements/TopBanner/TopBanner.js +1 -2
- package/dist/Editor/Styles/EditorStyles.js +3 -5
- package/dist/Editor/Toolbar/FormatTools/FontFamilyAutocomplete.js +1 -17
- package/dist/Editor/Toolbar/FormatTools/TextSize.js +3 -5
- package/dist/Editor/Toolbar/PopupTool/PopupToolStyle.js +72 -210
- package/dist/Editor/Toolbar/PopupTool/TextFormat.js +8 -55
- package/dist/Editor/Toolbar/Toolbar.js +0 -6
- package/dist/Editor/Toolbar/toolbarGroups.js +0 -4
- package/dist/Editor/assets/svg/SettingsIcon.js +4 -4
- package/dist/Editor/common/ColorPickerButton.js +3 -5
- package/dist/Editor/common/DnD/Draggable.js +1 -2
- package/dist/Editor/common/FontLoader/FontLoader.js +4 -4
- package/dist/Editor/common/Icon.js +0 -6
- package/dist/Editor/common/ImageSelector/Options/Upload.js +1 -2
- package/dist/Editor/common/ImageSelector/Styles.js +6 -47
- package/dist/Editor/common/ImageSelector/UploadStyles.js +6 -18
- package/dist/Editor/common/MentionsPopup/Styles.js +122 -109
- package/dist/Editor/common/RnD/ElementSettings/Settings/FormSettings.js +0 -1
- package/dist/Editor/common/RnD/GuideLines/styles.js +3 -3
- package/dist/Editor/common/RnD/ShadowElement.js +1 -1
- package/dist/Editor/common/RnD/SwitchViewport/SwitchViewport.js +2 -14
- package/dist/Editor/common/RnD/Utils/gridDropItem.js +6 -9
- package/dist/Editor/common/RnD/index.js +1 -2
- package/dist/Editor/common/Section/index.js +3 -3
- package/dist/Editor/common/Section/styles.js +1 -5
- package/dist/Editor/common/Shorthands/elements.js +1 -13
- package/dist/Editor/common/StyleBuilder/fieldTypes/backgroundImage.js +3 -9
- package/dist/Editor/common/StyleBuilder/fieldTypes/bannerSpacing.js +3 -27
- package/dist/Editor/common/StyleBuilder/fieldTypes/borderRadius.js +2 -15
- package/dist/Editor/common/StyleBuilder/fieldTypes/card.js +2 -10
- package/dist/Editor/common/StyleBuilder/fieldTypes/color.js +1 -2
- package/dist/Editor/common/StyleBuilder/fieldTypes/fontSize.js +1 -1
- package/dist/Editor/common/StyleBuilder/fieldTypes/icons.js +0 -2
- package/dist/Editor/common/StyleBuilder/fieldTypes/index.js +1 -3
- package/dist/Editor/common/StyleBuilder/fieldTypes/radiusStyle.js +4 -4
- package/dist/Editor/common/StyleBuilder/fieldTypes/saveAsTemplate.js +6 -22
- package/dist/Editor/common/StyleBuilder/fieldTypes/selectBox.js +2 -21
- package/dist/Editor/common/StyleBuilder/fieldTypes/textOptions.js +0 -7
- package/dist/Editor/common/StyleBuilder/index.js +3 -4
- package/dist/Editor/common/StyleBuilder/pageSettingsStyle.js +0 -4
- package/dist/Editor/common/ToolbarIcon.js +1 -2
- package/dist/Editor/common/Uploader.js +36 -46
- package/dist/Editor/common/iconListV2.js +130 -348
- package/dist/Editor/common/iconslist.js +3 -6
- package/dist/Editor/commonStyle.js +4 -290
- package/dist/Editor/helper/index.js +3 -16
- package/dist/Editor/helper/theme.js +1 -24
- package/dist/Editor/hooks/useMouseMove.js +2 -5
- package/dist/Editor/plugins/withCustomDeleteBackward.js +2 -33
- package/dist/Editor/plugins/withEmbeds.js +26 -30
- package/dist/Editor/utils/SlateUtilityFunctions.js +4 -27
- package/dist/Editor/utils/button.js +4 -4
- package/dist/Editor/utils/helper.js +13 -40
- package/dist/Editor/utils/pageSettings.js +2 -14
- package/package.json +2 -2
- package/dist/Editor/Elements/DataView/DataView.js +0 -124
- package/dist/Editor/Elements/DataView/DataViewButton.js +0 -23
- package/dist/Editor/Elements/DataView/Layouts/ColumnView.js +0 -67
- package/dist/Editor/Elements/DataView/Layouts/DataTypes/CheckType.js +0 -33
- package/dist/Editor/Elements/DataView/Layouts/DataTypes/Components/Select.js +0 -162
- package/dist/Editor/Elements/DataView/Layouts/DataTypes/Components/SimpleSelect.js +0 -40
- package/dist/Editor/Elements/DataView/Layouts/DataTypes/Components/styles.js +0 -67
- package/dist/Editor/Elements/DataView/Layouts/DataTypes/DateType.js +0 -35
- package/dist/Editor/Elements/DataView/Layouts/DataTypes/MultiSelectType.js +0 -39
- package/dist/Editor/Elements/DataView/Layouts/DataTypes/NumberType.js +0 -30
- package/dist/Editor/Elements/DataView/Layouts/DataTypes/PersonType.js +0 -30
- package/dist/Editor/Elements/DataView/Layouts/DataTypes/SelectType.js +0 -35
- package/dist/Editor/Elements/DataView/Layouts/DataTypes/TextType.js +0 -36
- package/dist/Editor/Elements/DataView/Layouts/DataTypes/index.js +0 -17
- package/dist/Editor/Elements/DataView/Layouts/FilterSort/SortOptions/ChooseField.js +0 -29
- package/dist/Editor/Elements/DataView/Layouts/FilterSort/SortOptions/ChooseSort.js +0 -38
- package/dist/Editor/Elements/DataView/Layouts/FilterSort/SortOptions/index.js +0 -74
- package/dist/Editor/Elements/DataView/Layouts/FilterSort/index.js +0 -64
- package/dist/Editor/Elements/DataView/Layouts/FilterSort/styles.js +0 -106
- package/dist/Editor/Elements/DataView/Layouts/FilterView.js +0 -174
- package/dist/Editor/Elements/DataView/Layouts/Formula.js +0 -29
- package/dist/Editor/Elements/DataView/Layouts/Options/AddOptions.js +0 -113
- package/dist/Editor/Elements/DataView/Layouts/Options/AddProperty.js +0 -37
- package/dist/Editor/Elements/DataView/Layouts/Options/AllProperties.js +0 -111
- package/dist/Editor/Elements/DataView/Layouts/Options/ChangeProperty.js +0 -60
- package/dist/Editor/Elements/DataView/Layouts/Options/ColumnsList.js +0 -36
- package/dist/Editor/Elements/DataView/Layouts/Options/Constants.js +0 -101
- package/dist/Editor/Elements/DataView/Layouts/Options/EditOption.js +0 -160
- package/dist/Editor/Elements/DataView/Layouts/Options/EditProperty.js +0 -190
- package/dist/Editor/Elements/DataView/Layouts/Options/FilterProperty.js +0 -42
- package/dist/Editor/Elements/DataView/Layouts/Options/PropertyList.js +0 -30
- package/dist/Editor/Elements/DataView/Layouts/Options/index.js +0 -110
- package/dist/Editor/Elements/DataView/Layouts/Options/styles.js +0 -179
- package/dist/Editor/Elements/DataView/Layouts/TableStyles.js +0 -112
- package/dist/Editor/Elements/DataView/Layouts/TableView.js +0 -227
- package/dist/Editor/Elements/DataView/Layouts/ViewData.js +0 -80
- package/dist/Editor/Elements/DataView/Layouts/colStyles.js +0 -10
- package/dist/Editor/Elements/DataView/Layouts/index.js +0 -25
- package/dist/Editor/Elements/DataView/Providers/DataViewProvider.js +0 -281
- package/dist/Editor/Elements/DataView/Utils/globalSearch.js +0 -15
- package/dist/Editor/Elements/DataView/Utils/multiSortRows.js +0 -74
- package/dist/Editor/Elements/DataView/styles.js +0 -154
- package/dist/Editor/common/StyleBuilder/fieldTypes/lineSpacing.js +0 -79
- package/dist/Editor/helper/enforceDateFormat.js +0 -41
- package/dist/Editor/utils/dataView.js +0 -43
|
@@ -26,7 +26,7 @@ import editorStyles from "./Styles/EditorStyles";
|
|
|
26
26
|
import DragAndDrop from "./common/DnD";
|
|
27
27
|
import Section from "./common/Section";
|
|
28
28
|
import decorators from "./utils/Decorators";
|
|
29
|
-
import {
|
|
29
|
+
import { getTRBLBreakPoints } from "./helper/theme";
|
|
30
30
|
import { getInitialValue, handleInsertLastElement, isFreeGrid, isFreeGridFragment, isPageSettings, outsideEditorClickLabel } from "./utils/helper";
|
|
31
31
|
import useWindowResize from "./hooks/useWindowResize";
|
|
32
32
|
import PopoverAIInput from "./Elements/AI/PopoverAIInput";
|
|
@@ -139,8 +139,7 @@ const CommonEditor = /*#__PURE__*/forwardRef((props, ref) => {
|
|
|
139
139
|
pageColor,
|
|
140
140
|
color: pageTextColor,
|
|
141
141
|
pageWidth,
|
|
142
|
-
maxWidth: pageMaxWidth
|
|
143
|
-
lineHeight
|
|
142
|
+
maxWidth: pageMaxWidth
|
|
144
143
|
} = pageSt?.pageProps || {
|
|
145
144
|
bannerSpacing: {
|
|
146
145
|
left: 0,
|
|
@@ -308,13 +307,11 @@ const CommonEditor = /*#__PURE__*/forwardRef((props, ref) => {
|
|
|
308
307
|
hideTools: updatedHideTools || []
|
|
309
308
|
}) : [];
|
|
310
309
|
const handleEditorChange = newValue => {
|
|
311
|
-
if (
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
setIsInteracted(true);
|
|
317
|
-
}
|
|
310
|
+
if (JSON.stringify(newValue) !== JSON.stringify(debouncedValue?.current)) {
|
|
311
|
+
updateTopBanner(newValue, setTopBanner);
|
|
312
|
+
debounced(newValue);
|
|
313
|
+
if (!isInteracted) {
|
|
314
|
+
setIsInteracted(true);
|
|
318
315
|
}
|
|
319
316
|
}
|
|
320
317
|
};
|
|
@@ -333,7 +330,6 @@ const CommonEditor = /*#__PURE__*/forwardRef((props, ref) => {
|
|
|
333
330
|
onDrawerOpen: onDrawerOpen,
|
|
334
331
|
ICON_API: "https://assets.agenciflow.com"
|
|
335
332
|
};
|
|
336
|
-
const lineH = getBreakpointLineSpacing(lineHeight, breakpoint);
|
|
337
333
|
const renderElement = useCallback(props => {
|
|
338
334
|
return /*#__PURE__*/_jsx(Element, {
|
|
339
335
|
...props,
|
|
@@ -536,7 +532,6 @@ const CommonEditor = /*#__PURE__*/forwardRef((props, ref) => {
|
|
|
536
532
|
padding: {
|
|
537
533
|
...getTRBLBreakPoints(bannerSpacing)
|
|
538
534
|
},
|
|
539
|
-
lineHeight: lineH,
|
|
540
535
|
width: !pageWidth || pageWidth === "fixed" ? fixedWidth : fullWidth,
|
|
541
536
|
height: viewport.h ? `${viewport.h}px` : `100%`,
|
|
542
537
|
alignSelf: "center",
|
|
@@ -594,9 +589,8 @@ const CommonEditor = /*#__PURE__*/forwardRef((props, ref) => {
|
|
|
594
589
|
setIsTextSelected: setIsTextSelected,
|
|
595
590
|
customProps: customProps,
|
|
596
591
|
editorWrapper: editorWrapper
|
|
597
|
-
}) : null, !readOnly ? /*#__PURE__*/_jsx(SwitchViewport, {
|
|
592
|
+
}) : null, !readOnly && showViewport ? /*#__PURE__*/_jsx(SwitchViewport, {
|
|
598
593
|
breakpoint: breakpoint,
|
|
599
|
-
show: showViewport,
|
|
600
594
|
onChange: b => onSwitchBreakpoint(b)
|
|
601
595
|
}) : null]
|
|
602
596
|
})
|
package/dist/Editor/Editor.css
CHANGED
|
@@ -31,7 +31,7 @@ blockquote {
|
|
|
31
31
|
border-left: 3px solid transparent;
|
|
32
32
|
margin-left: 0;
|
|
33
33
|
margin-right: 0;
|
|
34
|
-
|
|
34
|
+
padding-left: 10px;
|
|
35
35
|
margin: 0px;
|
|
36
36
|
}
|
|
37
37
|
|
|
@@ -149,7 +149,7 @@ blockquote {
|
|
|
149
149
|
.grid-item-toolbar button,
|
|
150
150
|
.element-toolbar button,
|
|
151
151
|
.element-toolbar a {
|
|
152
|
-
border-radius:
|
|
152
|
+
border-radius: 10px;
|
|
153
153
|
border: 1px solid rgba(37, 99, 235, 0.32);
|
|
154
154
|
background: #fff;
|
|
155
155
|
box-shadow: 0px 0px 10px 0px rgba(0, 0, 0, 0.16);
|
|
@@ -225,13 +225,9 @@ blockquote {
|
|
|
225
225
|
background-color: #0052cc;
|
|
226
226
|
padding: 8px 12px;
|
|
227
227
|
color: #ffffff;
|
|
228
|
-
font-weight:
|
|
229
|
-
font-size: 14px;
|
|
228
|
+
font-weight: bold;
|
|
230
229
|
opacity: 1;
|
|
231
230
|
border-radius: 32px;
|
|
232
|
-
text-transform: math-auto;
|
|
233
|
-
height: 36px;
|
|
234
|
-
padding: 0px 12px;
|
|
235
231
|
}
|
|
236
232
|
|
|
237
233
|
.signature-btn-container button:hover {
|
|
@@ -362,10 +358,6 @@ blockquote {
|
|
|
362
358
|
stroke: #2563eb;
|
|
363
359
|
}
|
|
364
360
|
|
|
365
|
-
.brushIcon:hover {
|
|
366
|
-
background: unset;
|
|
367
|
-
}
|
|
368
|
-
|
|
369
361
|
.react-datepicker__input-container {
|
|
370
362
|
display: flex !important;
|
|
371
363
|
align-items: center;
|
|
@@ -524,7 +516,7 @@ blockquote {
|
|
|
524
516
|
}
|
|
525
517
|
|
|
526
518
|
.deleteBtn {
|
|
527
|
-
background: #
|
|
519
|
+
background: #ffffff;
|
|
528
520
|
border: 1px solid #d32f2f !important;
|
|
529
521
|
box-shadow: 0px 8px 24px rgba(30, 64, 175, 0.08);
|
|
530
522
|
border-radius: 8px !important;
|
|
@@ -534,7 +526,6 @@ blockquote {
|
|
|
534
526
|
margin-right: 15px !important;
|
|
535
527
|
color: #d32f2f;
|
|
536
528
|
width: auto !important;
|
|
537
|
-
text-transform: capitalize !important;
|
|
538
529
|
}
|
|
539
530
|
|
|
540
531
|
@media (max-width: 480px) {
|
|
@@ -672,8 +663,7 @@ blockquote {
|
|
|
672
663
|
}
|
|
673
664
|
|
|
674
665
|
.resize-br.img-resizer {
|
|
675
|
-
bottom:
|
|
676
|
-
right: 5px;
|
|
666
|
+
bottom: 8px;
|
|
677
667
|
}
|
|
678
668
|
|
|
679
669
|
.visible-on-hover {
|
|
@@ -1033,11 +1023,11 @@ blockquote {
|
|
|
1033
1023
|
width: 200px;
|
|
1034
1024
|
cursor: pointer;
|
|
1035
1025
|
color: #464646;
|
|
1036
|
-
|
|
1026
|
+
background-color: #fff;
|
|
1037
1027
|
padding: 4px 6px;
|
|
1038
1028
|
border-radius: 12px;
|
|
1039
1029
|
span {
|
|
1040
|
-
text-transform:
|
|
1030
|
+
text-transform: capitalize;
|
|
1041
1031
|
}
|
|
1042
1032
|
@media only screen and (max-width: 599px) {
|
|
1043
1033
|
background-color: unset;
|
|
@@ -1059,7 +1049,7 @@ blockquote {
|
|
|
1059
1049
|
}
|
|
1060
1050
|
|
|
1061
1051
|
.textFontArrows .MuiIconButton-root {
|
|
1062
|
-
padding:
|
|
1052
|
+
padding: 2px;
|
|
1063
1053
|
}
|
|
1064
1054
|
|
|
1065
1055
|
.tools-drawer .MuiTypography-root {
|
|
@@ -1246,19 +1236,6 @@ blockquote {
|
|
|
1246
1236
|
pointer-events: auto;
|
|
1247
1237
|
}
|
|
1248
1238
|
|
|
1249
|
-
@media (max-width: 899px) {
|
|
1250
|
-
.MuiPopover-root {
|
|
1251
|
-
z-index: 1302 !important;
|
|
1252
|
-
}
|
|
1253
|
-
canvas {
|
|
1254
|
-
max-width: 100% !important;
|
|
1255
|
-
}
|
|
1256
|
-
}
|
|
1257
|
-
|
|
1258
|
-
.settingsHeader {
|
|
1259
|
-
font-size: 14px !important;
|
|
1260
|
-
font-weight: 500 !important;
|
|
1261
|
-
}
|
|
1262
1239
|
.hideScroll {
|
|
1263
1240
|
overflow-anchor: none;
|
|
1264
1241
|
}
|
|
@@ -1274,6 +1251,20 @@ blockquote {
|
|
|
1274
1251
|
.hideScroll::-webkit-scrollbar-thumb:hover {
|
|
1275
1252
|
background: none !important;
|
|
1276
1253
|
}
|
|
1254
|
+
@media (max-width: 899px) {
|
|
1255
|
+
.MuiPopover-root {
|
|
1256
|
+
z-index: 1302 !important;
|
|
1257
|
+
}
|
|
1258
|
+
|
|
1259
|
+
canvas {
|
|
1260
|
+
max-width: 100% !important;
|
|
1261
|
+
}
|
|
1262
|
+
}
|
|
1263
|
+
|
|
1264
|
+
.settingsHeader {
|
|
1265
|
+
font-size: 14px !important;
|
|
1266
|
+
font-weight: 500 !important;
|
|
1267
|
+
}
|
|
1277
1268
|
|
|
1278
1269
|
.custom-scroll::-webkit-scrollbar {
|
|
1279
1270
|
height: .6rem;
|
|
@@ -1293,22 +1284,3 @@ blockquote {
|
|
|
1293
1284
|
background: #A7AEC1;
|
|
1294
1285
|
}
|
|
1295
1286
|
|
|
1296
|
-
::selection {
|
|
1297
|
-
color: inherit;
|
|
1298
|
-
background: rgba(35, 131, 226, 0.35) !important;
|
|
1299
|
-
}
|
|
1300
|
-
|
|
1301
|
-
::-moz-selection {
|
|
1302
|
-
background: rgba(35, 131, 226, 0.35) !important;
|
|
1303
|
-
color: inherit;
|
|
1304
|
-
}
|
|
1305
|
-
|
|
1306
|
-
::-webkit-selection {
|
|
1307
|
-
background: rgba(35, 131, 226, 0.35) !important;
|
|
1308
|
-
color: inherit;
|
|
1309
|
-
}
|
|
1310
|
-
|
|
1311
|
-
.gradientFillBtn {
|
|
1312
|
-
background: linear-gradient(112.61deg, #2C63ED 19.3%, #8360FD 88.14%) !important;
|
|
1313
|
-
text-transform: math-auto !important;
|
|
1314
|
-
}
|
|
@@ -6,8 +6,7 @@ import { IconButton, Tooltip, Box } from "@mui/material";
|
|
|
6
6
|
import DeleteIcon from "@mui/icons-material/Delete";
|
|
7
7
|
import { GridSettingsIcon } from "../../common/iconslist";
|
|
8
8
|
import Icon from "../../common/Icon";
|
|
9
|
-
import {
|
|
10
|
-
import useCommonStyle from "../../commonStyle";
|
|
9
|
+
import { useEditorSelection } from "../../hooks/useMouseMove";
|
|
11
10
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
12
11
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
12
|
const accordionBtnStyleKeys = {
|
|
@@ -79,10 +78,6 @@ const Accordion = props => {
|
|
|
79
78
|
textColor,
|
|
80
79
|
bgColor
|
|
81
80
|
} = element;
|
|
82
|
-
const {
|
|
83
|
-
theme
|
|
84
|
-
} = useEditorContext();
|
|
85
|
-
const classes = useCommonStyle(theme);
|
|
86
81
|
const onToggle = () => {
|
|
87
82
|
setToggle(!toggle);
|
|
88
83
|
};
|
|
@@ -102,7 +97,6 @@ const Accordion = props => {
|
|
|
102
97
|
children: /*#__PURE__*/_jsx(IconButton, {
|
|
103
98
|
size: "small",
|
|
104
99
|
onClick: onSettings,
|
|
105
|
-
sx: classes.buttonMoreOption,
|
|
106
100
|
children: /*#__PURE__*/_jsx(GridSettingsIcon, {})
|
|
107
101
|
})
|
|
108
102
|
}), /*#__PURE__*/_jsx(Tooltip, {
|
|
@@ -111,7 +105,6 @@ const Accordion = props => {
|
|
|
111
105
|
children: /*#__PURE__*/_jsx(IconButton, {
|
|
112
106
|
size: "small",
|
|
113
107
|
onClick: onDelete,
|
|
114
|
-
sx: classes.buttonMoreOption2,
|
|
115
108
|
children: /*#__PURE__*/_jsx(DeleteIcon, {})
|
|
116
109
|
})
|
|
117
110
|
})]
|
|
@@ -250,10 +250,10 @@ function AppHeader(props) {
|
|
|
250
250
|
},
|
|
251
251
|
sx: {
|
|
252
252
|
mr: 2,
|
|
253
|
-
[theme
|
|
253
|
+
[theme.breakpoints.up("sm")]: {
|
|
254
254
|
display: "none"
|
|
255
255
|
},
|
|
256
|
-
[theme
|
|
256
|
+
[theme.breakpoints.between("xs", "md")]: {
|
|
257
257
|
display: "block"
|
|
258
258
|
}
|
|
259
259
|
},
|
|
@@ -272,10 +272,10 @@ function AppHeader(props) {
|
|
|
272
272
|
},
|
|
273
273
|
sx: {
|
|
274
274
|
flexGrow: 1,
|
|
275
|
-
[theme
|
|
275
|
+
[theme.breakpoints.up("sm")]: {
|
|
276
276
|
display: "block"
|
|
277
277
|
},
|
|
278
|
-
[theme
|
|
278
|
+
[theme.breakpoints.between("xs", "md")]: {
|
|
279
279
|
display: "none"
|
|
280
280
|
},
|
|
281
281
|
"& img": {
|
|
@@ -293,10 +293,10 @@ function AppHeader(props) {
|
|
|
293
293
|
}) : null, appTitle]
|
|
294
294
|
}), /*#__PURE__*/_jsxs(Box, {
|
|
295
295
|
sx: {
|
|
296
|
-
[theme
|
|
296
|
+
[theme.breakpoints.up("sm")]: {
|
|
297
297
|
display: "block"
|
|
298
298
|
},
|
|
299
|
-
[theme
|
|
299
|
+
[theme.breakpoints.between("xs", "md")]: {
|
|
300
300
|
display: "none"
|
|
301
301
|
}
|
|
302
302
|
},
|
|
@@ -11,7 +11,6 @@ import { handleLinkType, windowVar } from "../../utils/helper";
|
|
|
11
11
|
import LinkSettings from "../../common/LinkSettings";
|
|
12
12
|
import Icon from "../../common/Icon";
|
|
13
13
|
import { useEditorContext } from "../../hooks/useMouseMove";
|
|
14
|
-
import useCommonStyle from "../../commonStyle";
|
|
15
14
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
16
15
|
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
17
16
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
@@ -37,7 +36,6 @@ const EditorButton = props => {
|
|
|
37
36
|
const [edit, setEdit] = useState(false);
|
|
38
37
|
const [openNav, setOpenNav] = useState(false);
|
|
39
38
|
const [openMoreOptions, setOpenMoreOptions] = useState(false);
|
|
40
|
-
const classes = useCommonStyle(appTheme);
|
|
41
39
|
const {
|
|
42
40
|
label,
|
|
43
41
|
bgColor,
|
|
@@ -138,7 +136,6 @@ const EditorButton = props => {
|
|
|
138
136
|
arrow: true,
|
|
139
137
|
children: /*#__PURE__*/_jsx(IconButton, {
|
|
140
138
|
onClick: onMenuClick("edit"),
|
|
141
|
-
sx: classes.buttonMoreOption,
|
|
142
139
|
children: /*#__PURE__*/_jsx(Icon, {
|
|
143
140
|
icon: "pagesSettings"
|
|
144
141
|
})
|
|
@@ -148,7 +145,6 @@ const EditorButton = props => {
|
|
|
148
145
|
arrow: true,
|
|
149
146
|
children: /*#__PURE__*/_jsx(IconButton, {
|
|
150
147
|
onClick: onMenuClick("nav"),
|
|
151
|
-
sx: classes.buttonMoreOption,
|
|
152
148
|
children: /*#__PURE__*/_jsx(Icon, {
|
|
153
149
|
icon: "link"
|
|
154
150
|
})
|
|
@@ -161,9 +157,7 @@ const EditorButton = props => {
|
|
|
161
157
|
sx: {
|
|
162
158
|
display: "inline-flex",
|
|
163
159
|
color: "rgba(0, 0, 0, 0.54)",
|
|
164
|
-
marginBottom: "0px !important"
|
|
165
|
-
...classes.buttonMoreOption,
|
|
166
|
-
...classes.buttonMoreOption3
|
|
160
|
+
marginBottom: "0px !important"
|
|
167
161
|
},
|
|
168
162
|
...btnProps,
|
|
169
163
|
children: /*#__PURE__*/_jsx(Icon, {
|
|
@@ -265,12 +259,11 @@ const EditorButton = props => {
|
|
|
265
259
|
...btnSp,
|
|
266
260
|
borderStyle: borderStyle || "solid",
|
|
267
261
|
color: `${textColor || "#FFFFFF"}`,
|
|
268
|
-
fontSize: textSize || "
|
|
262
|
+
fontSize: textSize || "inherit",
|
|
269
263
|
fontFamily: fontFamily || "PoppinsRegular",
|
|
270
264
|
display: "inline-flex",
|
|
271
265
|
alignItems: "center",
|
|
272
266
|
position: "relative",
|
|
273
|
-
lineHeight: 1.43,
|
|
274
267
|
"& .element-toolbar": {
|
|
275
268
|
display: "none"
|
|
276
269
|
},
|
|
@@ -109,13 +109,11 @@ const ColorButtons = props => {
|
|
|
109
109
|
forMiniTool,
|
|
110
110
|
openColorTool,
|
|
111
111
|
onClose,
|
|
112
|
-
onColorPickerClick
|
|
113
|
-
defaultColors = []
|
|
112
|
+
onColorPickerClick
|
|
114
113
|
} = props;
|
|
115
114
|
const [row1, ...restRows] = ColorChunks([]);
|
|
116
115
|
const [anchorEl, setAnchorEl] = useState(null);
|
|
117
116
|
const open = Boolean(anchorEl);
|
|
118
|
-
const firstRow = defaultColors?.length ? defaultColors : row1;
|
|
119
117
|
const handleMore = e => {
|
|
120
118
|
setAnchorEl(e.currentTarget);
|
|
121
119
|
};
|
|
@@ -133,7 +131,7 @@ const ColorButtons = props => {
|
|
|
133
131
|
sx: classes.colorButtons,
|
|
134
132
|
children: [forMiniTool ? null : /*#__PURE__*/_jsx(Box, {
|
|
135
133
|
className: "buttonsWrpr first",
|
|
136
|
-
children: [
|
|
134
|
+
children: [row1].map((m, i) => {
|
|
137
135
|
return /*#__PURE__*/_jsx(SingleColorButton, {
|
|
138
136
|
id: `p1_${id}`,
|
|
139
137
|
crs: m,
|
|
@@ -5,7 +5,6 @@ import { IconButton, Tooltip } from "@mui/material";
|
|
|
5
5
|
import { GridSettingsIcon } from "../../common/iconslist";
|
|
6
6
|
import DividerPopup from "./DividerPopup";
|
|
7
7
|
import { Transforms } from "slate";
|
|
8
|
-
import useCommonStyle from "../../commonStyle";
|
|
9
8
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
10
9
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
11
10
|
const Divider = props => {
|
|
@@ -18,7 +17,6 @@ const Divider = props => {
|
|
|
18
17
|
const {
|
|
19
18
|
theme
|
|
20
19
|
} = useEditorContext();
|
|
21
|
-
const classes = useCommonStyle(theme);
|
|
22
20
|
const {
|
|
23
21
|
borderColor = theme?.palette?.primary?.main || "#0F172A",
|
|
24
22
|
borderWidth = "1px",
|
|
@@ -45,16 +43,11 @@ const Divider = props => {
|
|
|
45
43
|
showTool,
|
|
46
44
|
onSettings
|
|
47
45
|
}) => {
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
// ? `${theme?.palette?.greyshades?.light8} !important`
|
|
54
|
-
// : `${theme?.palette?.containers?.card} !important`,
|
|
55
|
-
// },
|
|
56
|
-
// }
|
|
57
|
-
// : {};
|
|
46
|
+
const hoverStyles = readOnly ? {
|
|
47
|
+
"&.MuiIconButton-root:hover": {
|
|
48
|
+
background: theme?.palette?.type === "dark" ? `${theme?.palette?.greyshades?.light8} !important` : `${theme?.palette?.containers?.card} !important`
|
|
49
|
+
}
|
|
50
|
+
} : {};
|
|
58
51
|
return /*#__PURE__*/_jsx("div", {
|
|
59
52
|
contentEditable: false,
|
|
60
53
|
className: "divider-settings",
|
|
@@ -68,22 +61,14 @@ const Divider = props => {
|
|
|
68
61
|
children: /*#__PURE__*/_jsx(IconButton, {
|
|
69
62
|
size: "small",
|
|
70
63
|
sx: {
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
// ? theme?.palette?.greyshades?.light8
|
|
74
|
-
// : theme?.palette?.containers?.card,
|
|
75
|
-
// border:
|
|
76
|
-
// theme?.palette?.type === "dark"
|
|
77
|
-
// ? "1px solid #E4E8EB33"
|
|
78
|
-
// : "none",
|
|
64
|
+
background: theme?.palette?.type === "dark" ? theme?.palette?.greyshades?.light8 : theme?.palette?.containers?.card,
|
|
65
|
+
border: theme?.palette?.type === "dark" ? "1px solid #E4E8EB33" : "none",
|
|
79
66
|
boxShadow: "0px 0px 4px 0px #00000040",
|
|
80
67
|
borderRadius: "50%",
|
|
81
68
|
"& svg": {
|
|
82
|
-
|
|
83
|
-
height: '16px'
|
|
69
|
+
stroke: theme?.palette?.text?.secondary3
|
|
84
70
|
},
|
|
85
|
-
|
|
86
|
-
...classes.buttonMoreOption
|
|
71
|
+
...hoverStyles
|
|
87
72
|
},
|
|
88
73
|
onClick: onSettings,
|
|
89
74
|
children: /*#__PURE__*/_jsx(GridSettingsIcon, {})
|
|
@@ -14,33 +14,28 @@ import ImageFrame from "./Frames/ImageFrame";
|
|
|
14
14
|
import LinkSettings from "../../common/LinkSettings";
|
|
15
15
|
import { handleLinkType } from "../../utils/helper";
|
|
16
16
|
import { wrapThemeBreakpoints } from "../FreeGrid/breakpointConstants";
|
|
17
|
-
import useCommonStyle from "../../commonStyle";
|
|
18
|
-
import SettingsIcon from "../../assets/svg/SettingsIcon";
|
|
19
17
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
20
18
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
21
19
|
const ToolBar = ({
|
|
22
20
|
isEmpty,
|
|
23
21
|
onSettings,
|
|
24
22
|
setOpenNav,
|
|
25
|
-
topM
|
|
26
|
-
classes
|
|
23
|
+
topM
|
|
27
24
|
}) => {
|
|
28
25
|
return !isEmpty ? /*#__PURE__*/_jsxs("div", {
|
|
29
26
|
className: "element-toolbar visible-on-hover",
|
|
30
27
|
contentEditable: false,
|
|
31
28
|
style: {
|
|
32
|
-
top: "-
|
|
29
|
+
top: "-5px",
|
|
33
30
|
left: topM ? "35px" : "0px",
|
|
34
|
-
margin: "0px"
|
|
35
|
-
gap: '3px'
|
|
31
|
+
margin: "0px"
|
|
36
32
|
},
|
|
37
33
|
children: [/*#__PURE__*/_jsx(Tooltip, {
|
|
38
34
|
title: "Image Settings",
|
|
39
35
|
arrow: true,
|
|
40
36
|
children: /*#__PURE__*/_jsx(IconButton, {
|
|
41
37
|
onClick: onSettings,
|
|
42
|
-
|
|
43
|
-
children: /*#__PURE__*/_jsx(SettingsIcon, {})
|
|
38
|
+
children: /*#__PURE__*/_jsx(GridSettingsIcon, {})
|
|
44
39
|
})
|
|
45
40
|
}), /*#__PURE__*/_jsx(Tooltip, {
|
|
46
41
|
title: "Link Settings",
|
|
@@ -48,7 +43,6 @@ const ToolBar = ({
|
|
|
48
43
|
children: /*#__PURE__*/_jsx(IconButton, {
|
|
49
44
|
className: "last-btn",
|
|
50
45
|
onClick: () => setOpenNav(true),
|
|
51
|
-
sx: classes.buttonMoreOption,
|
|
52
46
|
children: /*#__PURE__*/_jsx(LinkIcon, {})
|
|
53
47
|
})
|
|
54
48
|
})]
|
|
@@ -70,8 +64,7 @@ const ImageContent = props => {
|
|
|
70
64
|
handleImageClick,
|
|
71
65
|
onTouchEnd,
|
|
72
66
|
path,
|
|
73
|
-
theme
|
|
74
|
-
classes
|
|
67
|
+
theme
|
|
75
68
|
} = props;
|
|
76
69
|
return !url ? !readOnly ? /*#__PURE__*/_jsxs(Box, {
|
|
77
70
|
component: "button",
|
|
@@ -80,9 +73,6 @@ const ImageContent = props => {
|
|
|
80
73
|
onClick: () => {
|
|
81
74
|
setOpenSettings(true);
|
|
82
75
|
},
|
|
83
|
-
sx: {
|
|
84
|
-
...classes.emptyThumbBtn
|
|
85
|
-
},
|
|
86
76
|
children: [/*#__PURE__*/_jsx(Icon, {
|
|
87
77
|
icon: "image"
|
|
88
78
|
}), "Add Image"]
|
|
@@ -193,10 +183,6 @@ const Image = props => {
|
|
|
193
183
|
onClick,
|
|
194
184
|
onTouchEnd
|
|
195
185
|
} = handleLinkType(webAddress, linkType, readOnly, isNewTab);
|
|
196
|
-
const {
|
|
197
|
-
theme: appTheme
|
|
198
|
-
} = useEditorContext();
|
|
199
|
-
const classes = useCommonStyle(appTheme);
|
|
200
186
|
const handleImageClick = () => {
|
|
201
187
|
try {
|
|
202
188
|
Transforms.select(editor, {
|
|
@@ -307,8 +293,7 @@ const Image = props => {
|
|
|
307
293
|
isEmpty: isEmpty,
|
|
308
294
|
onSettings: onSettings,
|
|
309
295
|
setOpenNav: setOpenNav,
|
|
310
|
-
topM: size.width < 100
|
|
311
|
-
classes: classes
|
|
296
|
+
topM: size.width < 100
|
|
312
297
|
}), /*#__PURE__*/_jsx(ImageContent, {
|
|
313
298
|
...element,
|
|
314
299
|
readOnly: readOnly,
|
|
@@ -316,8 +301,7 @@ const Image = props => {
|
|
|
316
301
|
handleImageClick: handleImageClick,
|
|
317
302
|
onTouchEnd: onTouchEnd,
|
|
318
303
|
path: path,
|
|
319
|
-
theme: theme
|
|
320
|
-
classes: classes
|
|
304
|
+
theme: theme
|
|
321
305
|
}), url && frames[frame] ? /*#__PURE__*/_jsx(Box, {
|
|
322
306
|
component: "div",
|
|
323
307
|
className: "image-frame",
|
|
@@ -333,14 +317,11 @@ const Image = props => {
|
|
|
333
317
|
handleImageClick: handleImageClick
|
|
334
318
|
})
|
|
335
319
|
}) : null, selected && !readOnly && url && /*#__PURE__*/_jsx(IconButton, {
|
|
336
|
-
onPointerDown: onMouseDown
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
// }}
|
|
342
|
-
,
|
|
343
|
-
sx: classes.resizeButton,
|
|
320
|
+
onPointerDown: onMouseDown,
|
|
321
|
+
style: {
|
|
322
|
+
opacity: 1,
|
|
323
|
+
background: "#FFF"
|
|
324
|
+
},
|
|
344
325
|
className: "resize-br visible-on-hover img-resizer",
|
|
345
326
|
children: /*#__PURE__*/_jsx(AspectRatioIcon, {})
|
|
346
327
|
})]
|
|
@@ -11,8 +11,6 @@ import { GridSettingsIcon } from "../../common/iconslist";
|
|
|
11
11
|
import { gradientBorder } from "../../utils/helper";
|
|
12
12
|
import { getEmbedURL } from "../../helper";
|
|
13
13
|
import { getBreakPointsValue, getTRBLBreakPoints, groupByBreakpoint } from "../../helper/theme";
|
|
14
|
-
import { useEditorContext } from "../../hooks/useMouseMove";
|
|
15
|
-
import useCommonStyle from "../../commonStyle";
|
|
16
14
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
17
15
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
18
16
|
const VideoContent = props => {
|
|
@@ -70,16 +68,12 @@ const VideoPlaceholder = props => {
|
|
|
70
68
|
const {
|
|
71
69
|
url,
|
|
72
70
|
readOnly,
|
|
73
|
-
onSettings
|
|
74
|
-
classes
|
|
71
|
+
onSettings
|
|
75
72
|
} = props;
|
|
76
73
|
return !url ? !readOnly ? /*#__PURE__*/_jsxs(Box, {
|
|
77
74
|
component: "button",
|
|
78
75
|
className: "element-empty-btn",
|
|
79
76
|
onClick: onSettings,
|
|
80
|
-
sx: {
|
|
81
|
-
...classes.emptyThumbBtn
|
|
82
|
-
},
|
|
83
77
|
children: [/*#__PURE__*/_jsx(Icon, {
|
|
84
78
|
icon: "video"
|
|
85
79
|
}), "Embed Video or Other"]
|
|
@@ -127,10 +121,6 @@ const Video = ({
|
|
|
127
121
|
} = alignment || {};
|
|
128
122
|
const path = ReactEditor.findPath(editor, element);
|
|
129
123
|
const hasAspect = url && aspectRatio !== "custom" && aspectRatio;
|
|
130
|
-
const {
|
|
131
|
-
theme: appTheme
|
|
132
|
-
} = useEditorContext();
|
|
133
|
-
const classes = useCommonStyle(appTheme);
|
|
134
124
|
const getSize = () => {
|
|
135
125
|
if (element?.size === undefined) {
|
|
136
126
|
return {
|
|
@@ -277,8 +267,7 @@ const Video = ({
|
|
|
277
267
|
videoSX: videoSX,
|
|
278
268
|
url: url,
|
|
279
269
|
readOnly: readOnly,
|
|
280
|
-
resizing: resizing
|
|
281
|
-
classes: classes
|
|
270
|
+
resizing: resizing
|
|
282
271
|
}), !readOnly && url ? /*#__PURE__*/_jsx(IconButton, {
|
|
283
272
|
onPointerDown: onMouseDown,
|
|
284
273
|
style: {
|
|
@@ -47,22 +47,22 @@ export function wrapThemeBreakpoints(sxProp, prop, theme) {
|
|
|
47
47
|
const formatedSxProp = Object.keys(sxProp).reduce((a, b) => {
|
|
48
48
|
switch (b) {
|
|
49
49
|
case "md":
|
|
50
|
-
a[theme
|
|
50
|
+
a[theme.breakpoints.up("lg")] = {
|
|
51
51
|
[prop]: sxProp["md"] || sxProp["lg"]
|
|
52
52
|
};
|
|
53
53
|
break;
|
|
54
54
|
case "sm":
|
|
55
|
-
a[theme
|
|
55
|
+
a[theme.breakpoints.up("lg")] = {
|
|
56
56
|
[prop]: sxProp["sm"] || sxProp["lg"]
|
|
57
57
|
};
|
|
58
58
|
break;
|
|
59
59
|
case "xs":
|
|
60
|
-
a[theme
|
|
60
|
+
a[theme.breakpoints.between("xs", "md")] = {
|
|
61
61
|
[prop]: sxProp["xs"] || sxProp["lg"]
|
|
62
62
|
};
|
|
63
63
|
break;
|
|
64
64
|
default:
|
|
65
|
-
a[theme
|
|
65
|
+
a[theme.breakpoints.up("lg")] = {
|
|
66
66
|
[prop]: sxProp["lg"]
|
|
67
67
|
};
|
|
68
68
|
}
|
|
@@ -171,7 +171,6 @@ const useFreeGridStyles = ({
|
|
|
171
171
|
height: "100%",
|
|
172
172
|
"& .signature-container": {
|
|
173
173
|
height: "100%",
|
|
174
|
-
LineHeight: 1.43,
|
|
175
174
|
"& .signature-btn-container": {
|
|
176
175
|
height: "100%",
|
|
177
176
|
display: "flex",
|
|
@@ -319,7 +318,7 @@ const useFreeGridStyles = ({
|
|
|
319
318
|
"& .element-toolbar": {
|
|
320
319
|
display: "none"
|
|
321
320
|
},
|
|
322
|
-
[theme
|
|
321
|
+
[theme.breakpoints.between("xs", "md")]: {
|
|
323
322
|
marginLeft: `calc((100% - 320px) * 0.5)`
|
|
324
323
|
}
|
|
325
324
|
},
|
|
@@ -61,7 +61,6 @@ const GridItemToolbar = props => {
|
|
|
61
61
|
children: /*#__PURE__*/_jsx(IconButton, {
|
|
62
62
|
size: "small",
|
|
63
63
|
onClick: onSettings,
|
|
64
|
-
sx: classes.groupIcons,
|
|
65
64
|
children: /*#__PURE__*/_jsx(GridSettingsIcon, {})
|
|
66
65
|
})
|
|
67
66
|
}), /*#__PURE__*/_jsx(Tooltip, {
|
|
@@ -70,7 +69,6 @@ const GridItemToolbar = props => {
|
|
|
70
69
|
children: /*#__PURE__*/_jsx(IconButton, {
|
|
71
70
|
size: "small",
|
|
72
71
|
onClick: onAddColumn,
|
|
73
|
-
sx: classes.groupIcons2,
|
|
74
72
|
children: /*#__PURE__*/_jsx(AddIcon, {})
|
|
75
73
|
})
|
|
76
74
|
})]
|