@emailmaker/emailmaker 1.1.81 → 1.1.84

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 (41) hide show
  1. package/CHANGELOG.md +30 -0
  2. package/README.md +18 -7
  3. package/{emailmaker-core.5550faa5.js → emailmaker-core.79ea451d.js} +6 -6
  4. package/emailmaker-esm.js +4 -4
  5. package/{emailmaker-po.5550faa5.js → emailmaker-po.79ea451d.js} +1 -1
  6. package/emailmaker.d.ts +51 -24
  7. package/emailmaker.js +3 -3
  8. package/iframe/css/sandbox-dark.css +1 -1
  9. package/iframe/css/sandbox-darktheme.css +3 -3
  10. package/iframe/css/sandbox-light.css +1 -1
  11. package/iframe/css/sandbox.css +2 -2
  12. package/iframe/js/amp.BX1rGa_X.js +1 -0
  13. package/iframe/js/iframe-eblock.js +1 -1
  14. package/iframe/js/iframe.js +1 -1
  15. package/iframe/js/rules.B-wCbIo7.js +1 -1
  16. package/package.json +1 -1
  17. package/static/core/{8fe345a7.js → 12f8b705.js} +6 -6
  18. package/static/core/{438f4766.js → 1b3e2d70.js} +4 -4
  19. package/static/core/{4d48fdcd.js → 2180385a.js} +33 -33
  20. package/static/core/{26d559d32.js → 3834896e2.js} +124 -124
  21. package/static/core/{20625a132.js → 5ec924792.js} +857 -857
  22. package/static/core/{d34d3cc0.js → 62284a79.js} +77 -4
  23. package/static/core/{60e2f0e02.js → 69d13cd82.js} +49 -49
  24. package/static/core/{1cb65d65.js → 860577ca.js} +300 -300
  25. package/static/core/{ed08ded22.js → 8bf24c892.js} +982 -974
  26. package/static/core/{395f82fa.js → af78f5c5.js} +3 -3
  27. package/static/core/{adc7cd4e.js → c62226dd.js} +7 -7
  28. package/static/core/{f6e0d3702.js → d31af2772.js} +849 -836
  29. package/static/core/{5be7581f.js → d6d05bc8.js} +13058 -12638
  30. package/static/core/{d239a2a0.js → d825fdc8.js} +7 -7
  31. package/static/core/{16751762.js → dd044cfd.js} +7 -7
  32. package/static/core/{758a0c3c.js → f422bc19.js} +3 -3
  33. package/static/core/{d0a3e529.js → f4cfd2a7.js} +544 -539
  34. package/static/core/{544a8fe8.js → f740dd7d.js} +35 -35
  35. package/static/umd-runtime/{DntxC9N-.js → Py_VRWLn.js} +7 -1
  36. package/static/umd-runtime/runtime.js +2 -2
  37. package/static/umd-runtime/ui-kit.js +1742 -1734
  38. package/ui-kit/index.js +1859 -1851
  39. package/iframe/js/amp.BtGCOg7N.js +0 -1
  40. /package/iframe/{iframe-eblock.5550faa5.html → iframe-eblock.79ea451d.html} +0 -0
  41. /package/iframe/{iframe.5550faa5.html → iframe.79ea451d.html} +0 -0
@@ -1,23 +1,23 @@
1
- __emailmaker__.define("static/core/544a8fe8.js", [
1
+ __emailmaker__.define("static/core/f740dd7d.js", [
2
2
  "require",
3
3
  "exports",
4
4
  "module",
5
5
  "static/core/7df48ae1.js",
6
6
  "static/core/9883f8862.js",
7
- "static/core/f6e0d3702.js",
7
+ "static/core/d31af2772.js",
8
8
  "react",
9
9
  "antd",
10
10
  "react/jsx-runtime"
11
- ], function(m, X, ge) {
12
- const Y = m("./7df48ae1.js"), M = m("./9883f8862.js"), P = m("./f6e0d3702.js");
11
+ ], function(m, J, ge) {
12
+ const K = m("./7df48ae1.js"), M = m("./9883f8862.js"), P = m("./d31af2772.js");
13
13
  let o = m("react");
14
- o = Y.__toESM(o, 1);
14
+ o = K.__toESM(o, 1);
15
15
  let c = m("antd"), r = m("react/jsx-runtime");
16
- var S = ({ size: C = 24, color: _ = "currentColor", ...s }) => o.createElement("svg", {
16
+ var S = ({ size: C = 24, color: E = "currentColor", ...s }) => o.createElement("svg", {
17
17
  viewBox: "0 0 24 24",
18
18
  width: C,
19
19
  height: C,
20
- stroke: _,
20
+ stroke: E,
21
21
  strokeWidth: "2",
22
22
  fill: "none",
23
23
  strokeLinecap: "round",
@@ -26,7 +26,7 @@ __emailmaker__.define("static/core/544a8fe8.js", [
26
26
  ...s
27
27
  }, o.createElement("path", { d: "m14 10 7-7m0 0h-6m6 0v6m-11 5-7 7m0 0h6m-6 0v-6" }));
28
28
  S.displayName = "Expand01";
29
- var J = P.Xn(), t = {
29
+ var X = P.tr(), t = {
30
30
  "em-filemanager": "em-filemanager",
31
31
  emFilemanager: "em-filemanager",
32
32
  root: "root",
@@ -51,12 +51,12 @@ __emailmaker__.define("static/core/544a8fe8.js", [
51
51
  previewCanvas: "previewCanvas",
52
52
  previewCanvasBarcode: "previewCanvasBarcode",
53
53
  actions: "actions"
54
- }, z = 80, F = 600, K = 200, T = 24, q = 130, Z = 60, ee = 280, ae = 72;
54
+ }, z = 80, D = 600, Y = 200, T = 24, F = 130, Z = 60, ee = 280, ae = 72;
55
55
  function re() {
56
56
  return typeof window > "u" ? 2 : Math.min(3, Math.max(2, window.devicePixelRatio || 2));
57
57
  }
58
- var te = ({ customRequest: C, state: _, setState: s }) => {
59
- let { t: l } = P.Pn(), { options: oe } = P.V(), D = oe?.config?.iconStrokeWidth ?? 1.75, G = (0, o.useRef)(null), { mode: d, rawText: x, foregroundHex: g, backgroundHex: v, transparentBackground: p, qrSidePx: j, barcodeBarHeightPx: N } = _, le = (0, o.useCallback)((e) => s((a) => ({
58
+ var te = ({ customRequest: C, state: E, setState: s }) => {
59
+ let { t: l } = P.zn(), { options: oe } = P.B(), q = oe?.config?.iconStrokeWidth ?? 1.75, G = (0, o.useRef)(null), { mode: d, rawText: x, foregroundHex: g, backgroundHex: v, transparentBackground: p, qrSidePx: j, barcodeBarHeightPx: N } = E, le = (0, o.useCallback)((e) => s((a) => ({
60
60
  ...a,
61
61
  mode: e
62
62
  })), [s]), ie = (0, o.useCallback)((e) => s((a) => ({
@@ -77,7 +77,7 @@ __emailmaker__.define("static/core/544a8fe8.js", [
77
77
  })), [s]), he = (0, o.useCallback)((e) => s((a) => ({
78
78
  ...a,
79
79
  barcodeBarHeightPx: e
80
- })), [s]), [E, ue] = (0, o.useState)(x), [L, b] = (0, o.useState)(null), [R, V] = (0, o.useState)(!1), y = (0, o.useMemo)(() => (0, J.debounce)((e) => ue(e), 300), []);
80
+ })), [s]), [_, ue] = (0, o.useState)(x), [R, b] = (0, o.useState)(null), [L, Q] = (0, o.useState)(!1), y = (0, o.useMemo)(() => (0, X.debounce)((e) => ue(e), 300), []);
81
81
  (0, o.useEffect)(() => (y(x), () => {
82
82
  y.cancel();
83
83
  }), [x, y]);
@@ -101,7 +101,7 @@ __emailmaker__.define("static/core/544a8fe8.js", [
101
101
  g,
102
102
  k,
103
103
  j
104
- ]), Q = (0, o.useCallback)(async (e, a) => {
104
+ ]), U = (0, o.useCallback)(async (e, a) => {
105
105
  let n = (await Promise.resolve().then(() => m("./793710d0.js")).then((f) => M.l(f.default))).default, h = a.trim(), u = p ? "rgba(0,0,0,0)" : v, i = Math.min(ae, Math.max(T, N)), W = Math.max(1, Math.round(i / 42)), H = Math.max(4, Math.round(i * .07)), I = Math.max(10, Math.round(i * .15));
106
106
  if (!h) {
107
107
  e.width = Math.round(i * 4), e.height = Math.round(i * 1.65);
@@ -131,7 +131,7 @@ __emailmaker__.define("static/core/544a8fe8.js", [
131
131
  let a = !1;
132
132
  return (async () => {
133
133
  try {
134
- d === "qr" ? await $(e, E) : await Q(e, E), a || b(null);
134
+ d === "qr" ? await $(e, _) : await U(e, _), a || b(null);
135
135
  } catch (n) {
136
136
  let h = n instanceof Error ? n.message : String(n);
137
137
  if (!a) {
@@ -145,18 +145,18 @@ __emailmaker__.define("static/core/544a8fe8.js", [
145
145
  };
146
146
  }, [
147
147
  d,
148
- E,
149
- Q,
148
+ _,
149
+ U,
150
150
  $,
151
151
  l
152
152
  ]);
153
- let U = (0, o.useCallback)(async () => {
153
+ let V = (0, o.useCallback)(async () => {
154
154
  y.flush();
155
155
  let e = x.trim();
156
156
  if (!e) throw Error(l("Enter text or URL to preview"));
157
157
  let a = re();
158
158
  if (d === "qr") {
159
- let w = Math.round(Math.min(F, Math.max(z, j)) * a), B = document.createElement("canvas");
159
+ let w = Math.round(Math.min(D, Math.max(z, j)) * a), B = document.createElement("canvas");
160
160
  B.width = w, B.height = w, await (await Promise.resolve().then(() => m("./d28e9842.js")).then((A) => M.l(A.default))).default.toCanvas(B, e, {
161
161
  width: w,
162
162
  margin: 2,
@@ -169,7 +169,7 @@ __emailmaker__.define("static/core/544a8fe8.js", [
169
169
  if (!O) throw Error("PNG export failed");
170
170
  return O;
171
171
  }
172
- let n = (await Promise.resolve().then(() => m("./793710d0.js")).then((w) => M.l(w.default))).default, h = document.createElement("canvas"), u = p ? "rgba(0,0,0,0)" : v, i = Math.min(q, Math.max(T, N)), W = Math.max(6, Math.round(i * .1)), H = Math.max(2, Math.round(i / 36)), I = Math.max(12, Math.round(i * .16));
172
+ let n = (await Promise.resolve().then(() => m("./793710d0.js")).then((w) => M.l(w.default))).default, h = document.createElement("canvas"), u = p ? "rgba(0,0,0,0)" : v, i = Math.min(F, Math.max(T, N)), W = Math.max(6, Math.round(i * .1)), H = Math.max(2, Math.round(i / 36)), I = Math.max(12, Math.round(i * .16));
173
173
  n(h, e, {
174
174
  format: "CODE128",
175
175
  displayValue: !0,
@@ -195,12 +195,12 @@ __emailmaker__.define("static/core/544a8fe8.js", [
195
195
  y,
196
196
  l
197
197
  ]), me = (0, o.useCallback)(async () => {
198
- if (!R && x.trim()) {
199
- V(!0);
198
+ if (!L && x.trim()) {
199
+ Q(!0);
200
200
  try {
201
201
  let e;
202
202
  try {
203
- e = await U();
203
+ e = await V();
204
204
  } catch (n) {
205
205
  let h = n instanceof Error ? n.message : String(n);
206
206
  b(h);
@@ -212,16 +212,16 @@ __emailmaker__.define("static/core/544a8fe8.js", [
212
212
  });
213
213
  await Promise.resolve(C({ file: a }));
214
214
  } finally {
215
- V(!1);
215
+ Q(!1);
216
216
  }
217
217
  }
218
218
  }, [
219
219
  C,
220
- U,
220
+ V,
221
221
  d,
222
222
  x,
223
- R
224
- ]), xe = !!x.trim() && !L;
223
+ L
224
+ ]), xe = !!x.trim() && !R;
225
225
  return (0, r.jsx)("div", {
226
226
  className: t.root,
227
227
  children: (0, r.jsxs)("div", {
@@ -242,10 +242,10 @@ __emailmaker__.define("static/core/544a8fe8.js", [
242
242
  value: "barcode"
243
243
  }]
244
244
  }),
245
- L && (0, r.jsx)(c.Alert, {
245
+ R && (0, r.jsx)(c.Alert, {
246
246
  type: "error",
247
247
  title: l("Validation error"),
248
- description: L,
248
+ description: R,
249
249
  showIcon: !0,
250
250
  closable: !0,
251
251
  onClose: () => b(null)
@@ -269,13 +269,13 @@ __emailmaker__.define("static/core/544a8fe8.js", [
269
269
  }), d === "qr" ? (0, r.jsx)(c.InputNumber, {
270
270
  className: t.sizeInputNumber,
271
271
  min: z,
272
- max: F,
272
+ max: D,
273
273
  step: 8,
274
274
  value: j,
275
- onChange: (e) => de(typeof e == "number" && !Number.isNaN(e) ? e : K),
275
+ onChange: (e) => de(typeof e == "number" && !Number.isNaN(e) ? e : Y),
276
276
  prefix: (0, r.jsx)(S, {
277
277
  size: 18,
278
- strokeWidth: D
278
+ strokeWidth: q
279
279
  }),
280
280
  suffix: (0, r.jsx)("span", {
281
281
  className: t.sizeSuffix,
@@ -285,13 +285,13 @@ __emailmaker__.define("static/core/544a8fe8.js", [
285
285
  }) : (0, r.jsx)(c.InputNumber, {
286
286
  className: t.sizeInputNumber,
287
287
  min: T,
288
- max: q,
288
+ max: F,
289
289
  step: 4,
290
290
  value: N,
291
291
  onChange: (e) => he(typeof e == "number" && !Number.isNaN(e) ? e : Z),
292
292
  prefix: (0, r.jsx)(S, {
293
293
  size: 18,
294
- strokeWidth: D
294
+ strokeWidth: q
295
295
  }),
296
296
  suffix: (0, r.jsx)("span", {
297
297
  className: t.sizeSuffix,
@@ -376,7 +376,7 @@ __emailmaker__.define("static/core/544a8fe8.js", [
376
376
  onClick: () => {
377
377
  me();
378
378
  },
379
- loading: R,
379
+ loading: L,
380
380
  disabled: !xe,
381
381
  children: l("Add to My files")
382
382
  })
@@ -385,5 +385,5 @@ __emailmaker__.define("static/core/544a8fe8.js", [
385
385
  })
386
386
  });
387
387
  };
388
- X.default = te;
388
+ J.default = te;
389
389
  });
@@ -1,4 +1,4 @@
1
- __emailmaker__.define("static/umd-runtime/DntxC9N-.js", [
1
+ __emailmaker__.define("static/umd-runtime/Py_VRWLn.js", [
2
2
  "require",
3
3
  "exports",
4
4
  "module"
@@ -107902,6 +107902,12 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
107902
107902
  return py;
107903
107903
  }
107904
107904
  });
107905
+ Object.defineProperty(exports, "q", {
107906
+ enumerable: true,
107907
+ get: function() {
107908
+ return q$4;
107909
+ }
107910
+ });
107905
107911
  Object.defineProperty(exports, "q11", {
107906
107912
  enumerable: true,
107907
107913
  get: function() {
@@ -2,10 +2,10 @@ __emailmaker__.define("static/umd-runtime/runtime.js", [
2
2
  "require",
3
3
  "exports",
4
4
  "module",
5
- "static/umd-runtime/DntxC9N-.js"
5
+ "static/umd-runtime/Py_VRWLn.js"
6
6
  ], function(require, exports, module) {
7
7
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
8
- const require_es_DcH6fwd6 = require("./DntxC9N-.js");
8
+ const require_es_DcH6fwd6 = require("./Py_VRWLn.js");
9
9
  //#region build/runtime/react-dom/index.js
10
10
  var react_dom_exports = /* @__PURE__ */ require_es_DcH6fwd6.__exportAll({
11
11
  __DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE: () => u$3,