@elliemae/ds-wysiwygeditor 2.2.0-alpha.2 → 2.2.0-beta.0

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.
Files changed (70) hide show
  1. package/cjs/DSWYSIWYGEditor.js +72 -83
  2. package/cjs/components/CustomImageUploader.js +94 -92
  3. package/cjs/components/CustomToolbar.js +193 -172
  4. package/cjs/components/DSWYSIWYGEditorImpl.js +185 -147
  5. package/cjs/components/ImageLibraryModal.js +55 -75
  6. package/cjs/components/InsertFieldModal.js +142 -109
  7. package/cjs/components/TippedButton.js +54 -56
  8. package/cjs/components/TippedSelect.js +39 -50
  9. package/cjs/components/colors.js +21 -41
  10. package/cjs/components/customFields.js +47 -66
  11. package/cjs/constants.js +38 -112
  12. package/cjs/index.js +21 -39
  13. package/cjs/quillMatchers/clipboardLinkWithTagMatcher.js +22 -37
  14. package/cjs/quillOverrides/IndentStyle.js +19 -41
  15. package/cjs/quillOverrides/LinkFormat.js +39 -57
  16. package/cjs/quillOverrides/PlainClipboard.js +21 -41
  17. package/cjs/utils.js +18 -41
  18. package/esm/DSWYSIWYGEditor.js +58 -50
  19. package/esm/components/CustomImageUploader.js +81 -60
  20. package/esm/components/CustomToolbar.js +184 -145
  21. package/esm/components/DSWYSIWYGEditorImpl.js +169 -113
  22. package/esm/components/ImageLibraryModal.js +47 -46
  23. package/esm/components/InsertFieldModal.js +124 -72
  24. package/esm/components/TippedButton.js +44 -27
  25. package/esm/components/TippedSelect.js +31 -21
  26. package/esm/components/colors.js +17 -12
  27. package/esm/components/customFields.js +40 -38
  28. package/esm/constants.js +30 -83
  29. package/esm/index.js +4 -10
  30. package/esm/quillMatchers/clipboardLinkWithTagMatcher.js +18 -8
  31. package/esm/quillOverrides/IndentStyle.js +17 -12
  32. package/esm/quillOverrides/LinkFormat.js +37 -28
  33. package/esm/quillOverrides/PlainClipboard.js +19 -12
  34. package/esm/utils.js +14 -12
  35. package/package.json +9 -9
  36. package/types/DSWYSIWYGEditor.d.ts +1 -12
  37. package/cjs/DSWYSIWYGEditor.js.map +0 -7
  38. package/cjs/components/CustomImageUploader.js.map +0 -7
  39. package/cjs/components/CustomToolbar.js.map +0 -7
  40. package/cjs/components/DSWYSIWYGEditorImpl.js.map +0 -7
  41. package/cjs/components/ImageLibraryModal.js.map +0 -7
  42. package/cjs/components/InsertFieldModal.js.map +0 -7
  43. package/cjs/components/TippedButton.js.map +0 -7
  44. package/cjs/components/TippedSelect.js.map +0 -7
  45. package/cjs/components/colors.js.map +0 -7
  46. package/cjs/components/customFields.js.map +0 -7
  47. package/cjs/constants.js.map +0 -7
  48. package/cjs/index.js.map +0 -7
  49. package/cjs/quillMatchers/clipboardLinkWithTagMatcher.js.map +0 -7
  50. package/cjs/quillOverrides/IndentStyle.js.map +0 -7
  51. package/cjs/quillOverrides/LinkFormat.js.map +0 -7
  52. package/cjs/quillOverrides/PlainClipboard.js.map +0 -7
  53. package/cjs/utils.js.map +0 -7
  54. package/esm/DSWYSIWYGEditor.js.map +0 -7
  55. package/esm/components/CustomImageUploader.js.map +0 -7
  56. package/esm/components/CustomToolbar.js.map +0 -7
  57. package/esm/components/DSWYSIWYGEditorImpl.js.map +0 -7
  58. package/esm/components/ImageLibraryModal.js.map +0 -7
  59. package/esm/components/InsertFieldModal.js.map +0 -7
  60. package/esm/components/TippedButton.js.map +0 -7
  61. package/esm/components/TippedSelect.js.map +0 -7
  62. package/esm/components/colors.js.map +0 -7
  63. package/esm/components/customFields.js.map +0 -7
  64. package/esm/constants.js.map +0 -7
  65. package/esm/index.js.map +0 -7
  66. package/esm/quillMatchers/clipboardLinkWithTagMatcher.js.map +0 -7
  67. package/esm/quillOverrides/IndentStyle.js.map +0 -7
  68. package/esm/quillOverrides/LinkFormat.js.map +0 -7
  69. package/esm/quillOverrides/PlainClipboard.js.map +0 -7
  70. package/esm/utils.js.map +0 -7
@@ -1,71 +1,101 @@
1
- import * as React from "react";
2
- import React2, { useState } from "react";
3
- import DSButton from "@elliemae/ds-button";
4
- import { ArrowheadDown } from "@elliemae/ds-icons";
5
- import DSDropdownMenu from "@elliemae/ds-dropdownmenu";
6
- import { colors, fonts, sizes, sizesReal } from "../constants";
7
- import { TippedButton } from "./TippedButton";
8
- import { TippedSelect } from "./TippedSelect";
9
- const optionsToValues = (options) => options.map((opt) => opt.toLowerCase().replace(" ", "-"));
10
- const CustomFields = () => /* @__PURE__ */ React2.createElement("span", null, "\u1438\u1433");
11
- const Color = ({ color }) => /* @__PURE__ */ React2.createElement("option", {
12
- value: color
13
- });
14
- const Colors = ({ className, tip, zIndex }) => /* @__PURE__ */ React2.createElement(TippedSelect, {
15
- className,
16
- tip,
17
- zIndex
18
- }, colors.map((color) => /* @__PURE__ */ React2.createElement(Color, {
19
- key: color,
20
- color
21
- })));
22
- const CustomDropdown = ({
23
- options,
24
- label,
25
- onSelectMenuItem = () => null,
26
- onClickOutsideMenu = () => null,
27
- onClose = () => null,
28
- closeMenuOnItemSelection,
29
- isOpen,
30
- minWidth,
31
- maxWidth,
32
- zIndex = 10
33
- }) => /* @__PURE__ */ React2.createElement(DSDropdownMenu, {
34
- onClickOutsideMenu,
35
- options,
36
- onSelectMenuItem,
37
- onClose,
38
- closeMenuOnItemSelection,
39
- isOpen,
40
- minWidth,
41
- maxWidth,
42
- zIndex,
43
- preventOverflow: "scrollParent",
44
- triggerComponent: /* @__PURE__ */ React2.createElement(DSButton, {
45
- labelText: label,
46
- buttonType: "text",
47
- icon: /* @__PURE__ */ React2.createElement(ArrowheadDown, null)
48
- })
49
- });
50
- const Divider = () => /* @__PURE__ */ React2.createElement("div", {
1
+ import _jsx from '@babel/runtime/helpers/esm/jsx';
2
+ import 'core-js/modules/esnext.async-iterator.map.js';
3
+ import 'core-js/modules/esnext.iterator.map.js';
4
+ import 'core-js/modules/es.string.replace.js';
5
+ import 'core-js/modules/web.dom-collections.iterator.js';
6
+ import { useState } from 'react';
7
+ import DSButton from '@elliemae/ds-button';
8
+ import { ArrowheadDown } from '@elliemae/ds-icons';
9
+ import DSDropdownMenu from '@elliemae/ds-dropdownmenu';
10
+ import { fonts, sizes, sizesReal, colors } from '../constants.js';
11
+ import { TippedButton } from './TippedButton.js';
12
+ import { TippedSelect } from './TippedSelect.js';
13
+ import { jsxs, Fragment } from 'react/jsx-runtime';
14
+
15
+ var _span, _ArrowheadDown, _Divider, _Divider2, _Divider3, _Divider4, _Divider5, _Divider6, _Divider7, _Divider8, _Divider9, _CustomFields, _Divider10;
16
+
17
+ const optionsToValues = options => options.map(opt => opt.toLowerCase().replace(' ', '-')); // Stateless Components -----------------------------------------
18
+
19
+
20
+ const CustomFields = () => _span || (_span = /*#__PURE__*/_jsx("span", {}, void 0, "\u1438\u1433")); // eslint-disable-line react/jsx-one-expression-per-line
21
+
22
+
23
+ const Color = _ref => {
24
+ let {
25
+ color
26
+ } = _ref;
27
+ return /*#__PURE__*/_jsx("option", {
28
+ value: color
29
+ });
30
+ };
31
+
32
+ const Colors = _ref2 => {
33
+ let {
34
+ className,
35
+ tip,
36
+ zIndex
37
+ } = _ref2;
38
+ return /*#__PURE__*/_jsx(TippedSelect, {
39
+ className: className,
40
+ tip: tip,
41
+ zIndex: zIndex
42
+ }, void 0, colors.map(color => /*#__PURE__*/_jsx(Color, {
43
+ color: color
44
+ }, color)));
45
+ };
46
+
47
+ const CustomDropdown = _ref3 => {
48
+ let {
49
+ options,
50
+ label,
51
+ onSelectMenuItem = () => null,
52
+ onClickOutsideMenu = () => null,
53
+ onClose = () => null,
54
+ closeMenuOnItemSelection,
55
+ isOpen,
56
+ minWidth,
57
+ maxWidth,
58
+ zIndex = 10
59
+ } = _ref3;
60
+ return /*#__PURE__*/_jsx(DSDropdownMenu, {
61
+ onClickOutsideMenu: onClickOutsideMenu,
62
+ options: options,
63
+ onSelectMenuItem: onSelectMenuItem,
64
+ onClose: onClose,
65
+ closeMenuOnItemSelection: closeMenuOnItemSelection,
66
+ isOpen: isOpen,
67
+ minWidth: minWidth,
68
+ maxWidth: maxWidth,
69
+ zIndex: zIndex,
70
+ preventOverflow: "scrollParent",
71
+ triggerComponent: /*#__PURE__*/_jsx(DSButton, {
72
+ labelText: label,
73
+ buttonType: "text",
74
+ icon: _ArrowheadDown || (_ArrowheadDown = /*#__PURE__*/_jsx(ArrowheadDown, {}))
75
+ })
76
+ });
77
+ };
78
+
79
+ const Divider = () => /*#__PURE__*/_jsx("div", {
51
80
  style: {
52
- height: "21px",
53
- width: "1px",
54
- margin: "0 10px",
55
- padding: "0",
56
- borderLeft: "1px solid #bbb",
57
- display: "inline-block"
81
+ height: '21px',
82
+ width: '1px',
83
+ margin: '0 10px',
84
+ padding: '0',
85
+ borderLeft: '1px solid #bbb',
86
+ display: 'inline-block'
58
87
  }
59
88
  });
60
- const CustomToolbar = ({
61
- customFields,
62
- customItems = [],
63
- hideItems = {},
64
- onShowHTML = () => {
65
- },
66
- id = "toolbar",
67
- userProps
68
- }) => {
89
+
90
+ const CustomToolbar = _ref4 => {
91
+ let {
92
+ customFields,
93
+ customItems = [],
94
+ hideItems = {},
95
+ onShowHTML = () => {},
96
+ id = 'toolbar',
97
+ userProps
98
+ } = _ref4;
69
99
  const {
70
100
  HEADER,
71
101
  FONT,
@@ -89,144 +119,153 @@ const CustomToolbar = ({
89
119
  SHOW_HTML
90
120
  } = hideItems;
91
121
  const [showHTML, setShowHTML] = useState(false);
92
- const handleShowHTML = (e) => {
122
+
123
+ const handleShowHTML = e => {
93
124
  e.preventDefault();
94
125
  setShowHTML(!showHTML);
95
126
  onShowHTML();
96
127
  };
97
- return /* @__PURE__ */ React2.createElement("div", {
98
- id,
128
+
129
+ return /*#__PURE__*/_jsx("div", {
130
+ id: id,
99
131
  className: "ds-ql-custom-toolbar"
100
- }, (!HEADER || !FONT || !FONT_SIZE) && /* @__PURE__ */ React2.createElement("span", {
132
+ }, void 0, (!HEADER || !FONT || !FONT_SIZE) && /*#__PURE__*/_jsx("span", {
101
133
  className: "ql-formats"
102
- }, !HEADER && /* @__PURE__ */ React2.createElement(React2.Fragment, null, /* @__PURE__ */ React2.createElement(TippedSelect, {
103
- className: "ql-header",
104
- tip: "Header",
105
- values: ["", "1", "2", "3", "4", "5", "6"],
106
- zIndex: userProps?.zIndex || 1
107
- }), /* @__PURE__ */ React2.createElement(Divider, null)), !FONT && /* @__PURE__ */ React2.createElement(React2.Fragment, null, /* @__PURE__ */ React2.createElement(TippedSelect, {
108
- className: "ql-font",
109
- defaultValue: "sans-serif",
110
- options: fonts,
111
- tip: "Font",
112
- values: optionsToValues(fonts),
113
- zIndex: userProps?.zIndex || 1
114
- }), /* @__PURE__ */ React2.createElement(Divider, null)), !FONT_SIZE && /* @__PURE__ */ React2.createElement(React2.Fragment, null, /* @__PURE__ */ React2.createElement(TippedSelect, {
115
- className: "ql-size",
116
- options: sizes,
117
- tip: "Font Size",
118
- values: optionsToValues(sizesReal),
119
- zIndex: userProps?.zIndex || 1
120
- }), /* @__PURE__ */ React2.createElement(Divider, null))), (!BOLD || !ITALIC || !UNDERLINE || !STRIKE) && /* @__PURE__ */ React2.createElement("span", {
134
+ }, void 0, !HEADER && /*#__PURE__*/jsxs(Fragment, {
135
+ children: [/*#__PURE__*/_jsx(TippedSelect, {
136
+ className: "ql-header",
137
+ tip: "Header",
138
+ values: ['', '1', '2', '3', '4', '5', '6'],
139
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1
140
+ }), _Divider || (_Divider = /*#__PURE__*/_jsx(Divider, {}))]
141
+ }), !FONT && /*#__PURE__*/jsxs(Fragment, {
142
+ children: [/*#__PURE__*/_jsx(TippedSelect, {
143
+ className: "ql-font",
144
+ defaultValue: "sans-serif",
145
+ options: fonts,
146
+ tip: "Font",
147
+ values: optionsToValues(fonts),
148
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1
149
+ }), _Divider2 || (_Divider2 = /*#__PURE__*/_jsx(Divider, {}))]
150
+ }), !FONT_SIZE && /*#__PURE__*/jsxs(Fragment, {
151
+ children: [/*#__PURE__*/_jsx(TippedSelect, {
152
+ className: "ql-size",
153
+ options: sizes,
154
+ tip: "Font Size",
155
+ values: optionsToValues(sizesReal),
156
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1
157
+ }), _Divider3 || (_Divider3 = /*#__PURE__*/_jsx(Divider, {}))]
158
+ })), (!BOLD || !ITALIC || !UNDERLINE || !STRIKE) && /*#__PURE__*/_jsx("span", {
121
159
  className: "ql-formats"
122
- }, !BOLD && /* @__PURE__ */ React2.createElement(TippedButton, {
123
- zIndex: userProps?.zIndex || 1,
160
+ }, void 0, !BOLD && /*#__PURE__*/_jsx(TippedButton, {
161
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
124
162
  className: "ql-bold",
125
163
  tip: "Bold"
126
- }), !ITALIC && /* @__PURE__ */ React2.createElement(TippedButton, {
127
- zIndex: userProps?.zIndex || 1,
164
+ }), !ITALIC && /*#__PURE__*/_jsx(TippedButton, {
165
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
128
166
  className: "ql-italic",
129
167
  tip: "Italic"
130
- }), !UNDERLINE && /* @__PURE__ */ React2.createElement(TippedButton, {
131
- zIndex: userProps?.zIndex || 1,
168
+ }), !UNDERLINE && /*#__PURE__*/_jsx(TippedButton, {
169
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
132
170
  className: "ql-underline",
133
171
  tip: "Underline"
134
- }), !STRIKE && /* @__PURE__ */ React2.createElement(TippedButton, {
135
- zIndex: userProps?.zIndex || 1,
172
+ }), !STRIKE && /*#__PURE__*/_jsx(TippedButton, {
173
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
136
174
  className: "ql-strike",
137
175
  tip: "Strike"
138
- })), (!SUB || !SUPER) && /* @__PURE__ */ React2.createElement("span", {
176
+ })), (!SUB || !SUPER) && /*#__PURE__*/_jsx("span", {
139
177
  className: "ql-formats"
140
- }, !SUB && /* @__PURE__ */ React2.createElement(TippedButton, {
141
- zIndex: userProps?.zIndex || 1,
178
+ }, void 0, !SUB && /*#__PURE__*/_jsx(TippedButton, {
179
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
142
180
  className: "ql-script",
143
181
  tip: "Sub",
144
182
  value: "sub"
145
- }), !SUPER && /* @__PURE__ */ React2.createElement(TippedButton, {
146
- zIndex: userProps?.zIndex || 1,
183
+ }), !SUPER && /*#__PURE__*/_jsx(TippedButton, {
184
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
147
185
  className: "ql-script",
148
186
  tip: "Super",
149
187
  value: "super"
150
- }), /* @__PURE__ */ React2.createElement(Divider, null)), (!ORDERED_LIST || !BULLET_LIST) && /* @__PURE__ */ React2.createElement("span", {
188
+ }), _Divider4 || (_Divider4 = /*#__PURE__*/_jsx(Divider, {}))), (!ORDERED_LIST || !BULLET_LIST) && /*#__PURE__*/_jsx("span", {
151
189
  className: "ql-formats"
152
- }, !ORDERED_LIST && /* @__PURE__ */ React2.createElement(TippedButton, {
153
- zIndex: userProps?.zIndex || 1,
190
+ }, void 0, !ORDERED_LIST && /*#__PURE__*/_jsx(TippedButton, {
191
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
154
192
  className: "ql-list",
155
193
  tip: "Ordered List",
156
194
  value: "ordered"
157
- }), !BULLET_LIST && /* @__PURE__ */ React2.createElement(TippedButton, {
158
- zIndex: userProps?.zIndex || 1,
195
+ }), !BULLET_LIST && /*#__PURE__*/_jsx(TippedButton, {
196
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
159
197
  className: "ql-list",
160
198
  tip: "Bullet List",
161
199
  value: "bullet"
162
- })), (!INDENT_MINUS_ONE || !INDENT_PLUS_ONE) && /* @__PURE__ */ React2.createElement("span", {
200
+ })), (!INDENT_MINUS_ONE || !INDENT_PLUS_ONE) && /*#__PURE__*/_jsx("span", {
163
201
  className: "ql-formats"
164
- }, !INDENT_MINUS_ONE && /* @__PURE__ */ React2.createElement(TippedButton, {
165
- zIndex: userProps?.zIndex || 1,
202
+ }, void 0, !INDENT_MINUS_ONE && /*#__PURE__*/_jsx(TippedButton, {
203
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
166
204
  className: "ql-indent",
167
205
  tip: "Indent -1",
168
206
  value: "-1"
169
- }), !INDENT_PLUS_ONE && /* @__PURE__ */ React2.createElement(TippedButton, {
170
- zIndex: userProps?.zIndex || 1,
207
+ }), !INDENT_PLUS_ONE && /*#__PURE__*/_jsx(TippedButton, {
208
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
171
209
  className: "ql-indent",
172
210
  tip: "Indent +1",
173
211
  value: "+1"
174
- })), !ALIGN && /* @__PURE__ */ React2.createElement("span", {
212
+ })), !ALIGN && /*#__PURE__*/_jsx("span", {
175
213
  className: "ql-formats"
176
- }, /* @__PURE__ */ React2.createElement(TippedSelect, {
177
- zIndex: userProps?.zIndex || 1,
214
+ }, void 0, /*#__PURE__*/_jsx(TippedSelect, {
215
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
178
216
  className: "ql-align",
179
217
  tip: "Align"
180
- }), /* @__PURE__ */ React2.createElement(Divider, null)), (!FONT_COLOR || !FONT_BACKGROUND_COLOR) && /* @__PURE__ */ React2.createElement("span", {
218
+ }), _Divider5 || (_Divider5 = /*#__PURE__*/_jsx(Divider, {}))), (!FONT_COLOR || !FONT_BACKGROUND_COLOR) && /*#__PURE__*/_jsx("span", {
181
219
  className: "ql-formats"
182
- }, !FONT_COLOR && /* @__PURE__ */ React2.createElement(Colors, {
183
- zIndex: userProps?.zIndex || 1,
220
+ }, void 0, !FONT_COLOR && /*#__PURE__*/_jsx(Colors, {
221
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
184
222
  className: "ql-color",
185
223
  tip: "Font Color"
186
- }), !FONT_BACKGROUND_COLOR && /* @__PURE__ */ React2.createElement(Colors, {
187
- zIndex: userProps?.zIndex || 1,
224
+ }), !FONT_BACKGROUND_COLOR && /*#__PURE__*/_jsx(Colors, {
225
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
188
226
  className: "ql-background",
189
227
  tip: "Font Background Color"
190
- }), /* @__PURE__ */ React2.createElement(Divider, null)), (!HYPERLINK || !IMAGE) && /* @__PURE__ */ React2.createElement("span", {
228
+ }), _Divider6 || (_Divider6 = /*#__PURE__*/_jsx(Divider, {}))), (!HYPERLINK || !IMAGE) && /*#__PURE__*/_jsx("span", {
191
229
  className: "ql-formats"
192
- }, !HYPERLINK && /* @__PURE__ */ React2.createElement(TippedButton, {
193
- zIndex: userProps?.zIndex || 1,
230
+ }, void 0, !HYPERLINK && /*#__PURE__*/_jsx(TippedButton, {
231
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
194
232
  className: "ql-link",
195
233
  tip: "Hyperlink: Select Text First"
196
- }), !IMAGE && /* @__PURE__ */ React2.createElement(TippedButton, {
197
- zIndex: userProps?.zIndex || 1,
234
+ }), !IMAGE && /*#__PURE__*/_jsx(TippedButton, {
235
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
198
236
  className: "ql-image",
199
237
  tip: "Insert Image"
200
- }), /* @__PURE__ */ React2.createElement(Divider, null)), !CLEAR_FORMAT && /* @__PURE__ */ React2.createElement("span", {
238
+ }), _Divider7 || (_Divider7 = /*#__PURE__*/_jsx(Divider, {}))), !CLEAR_FORMAT && /*#__PURE__*/_jsx("span", {
201
239
  className: "ql-formats"
202
- }, /* @__PURE__ */ React2.createElement(TippedButton, {
203
- zIndex: userProps?.zIndex || 1,
240
+ }, void 0, /*#__PURE__*/_jsx(TippedButton, {
241
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
204
242
  className: "ql-clean",
205
243
  tip: "Clear Format (Select Text)"
206
- })), !SHOW_HTML && /* @__PURE__ */ React2.createElement("span", {
244
+ })), !SHOW_HTML && /*#__PURE__*/_jsx("span", {
207
245
  className: "ql-formats"
208
- }, /* @__PURE__ */ React2.createElement(Divider, null), /* @__PURE__ */ React2.createElement(TippedButton, {
209
- zIndex: userProps?.zIndex || 1,
246
+ }, void 0, _Divider8 || (_Divider8 = /*#__PURE__*/_jsx(Divider, {})), /*#__PURE__*/_jsx(TippedButton, {
247
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
210
248
  style: {
211
- width: "fit-content",
212
- color: "#1e79c2",
213
- fontWeight: "500"
249
+ width: 'fit-content',
250
+ color: '#1e79c2',
251
+ fontWeight: '500'
214
252
  },
215
253
  onClick: handleShowHTML,
216
- tip: showHTML ? "SHOW TEXT" : "SHOW HTML",
254
+ tip: showHTML ? 'SHOW TEXT' : 'SHOW HTML',
217
255
  className: "ql-customFields-html"
218
- }, showHTML ? "SHOW TEXT" : "SHOW HTML")), customFields && /* @__PURE__ */ React2.createElement("span", {
256
+ }, void 0, showHTML ? 'SHOW TEXT' : 'SHOW HTML')), customFields && /*#__PURE__*/_jsx("span", {
219
257
  className: "ql-formats"
220
- }, /* @__PURE__ */ React2.createElement(Divider, null), /* @__PURE__ */ React2.createElement(TippedButton, {
221
- zIndex: userProps?.zIndex || 1,
258
+ }, void 0, _Divider9 || (_Divider9 = /*#__PURE__*/_jsx(Divider, {})), /*#__PURE__*/_jsx(TippedButton, {
259
+ zIndex: (userProps === null || userProps === void 0 ? void 0 : userProps.zIndex) || 1,
222
260
  className: "ql-customFields",
223
261
  tip: "Insert Custom Field"
224
- }, /* @__PURE__ */ React2.createElement(CustomFields, null))), customItems && /* @__PURE__ */ React2.createElement("span", {
225
- style: { display: "inline-flex" }
226
- }, customItems.map((Item) => /* @__PURE__ */ React2.createElement(React2.Fragment, null, /* @__PURE__ */ React2.createElement(Divider, null), /* @__PURE__ */ React2.createElement(Item, null)))));
227
- };
228
- export {
229
- CustomDropdown,
230
- CustomToolbar
262
+ }, void 0, _CustomFields || (_CustomFields = /*#__PURE__*/_jsx(CustomFields, {})))), customItems && /*#__PURE__*/_jsx("span", {
263
+ style: {
264
+ display: 'inline-flex'
265
+ }
266
+ }, void 0, customItems.map(Item => /*#__PURE__*/jsxs(Fragment, {
267
+ children: [_Divider10 || (_Divider10 = /*#__PURE__*/_jsx(Divider, {})), /*#__PURE__*/_jsx(Item, {})]
268
+ }))));
231
269
  };
232
- //# sourceMappingURL=CustomToolbar.js.map
270
+
271
+ export { CustomDropdown, CustomToolbar };