useblocks 1.1.43 → 1.1.44

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.
@@ -1,5 +1,5 @@
1
1
  (function(){try{if(typeof document<"u"){var o=document.createElement("style");o.setAttribute("data-useblocks","true"),o.appendChild(document.createTextNode(".blocks-app .image-preview{text-align:center;min-height:100px;position:relative}.blocks-app .image-preview .image-editor-modal{border:1px solid red}.blocks-app .image-preview__edit-button{position:absolute;bottom:10px;left:50%;transform:translate(-50%)}.blocks-app .image-preview img{border:1px solid var(--colorBorder);border-radius:6px;max-width:100%;max-height:500px}.blocks-app .image-editor-modal .ant-modal-container{flex-direction:column;min-height:100vh;display:flex;border-radius:0!important}.blocks-app .image-editor-modal .ant-modal-body{flex-grow:1;display:flex}.blocks-app .image-editor-modal .ant-modal-body #pixie-editor{flex-grow:1;height:calc(100vh - 70px);min-height:calc(100vh - 70px);overflow:hidden}.blocks-app .image-editor-modal .pi .text-on-primary{background:var(--colorPrimary);border-color:var(--colorPrimary)}.blocks-app .image-editor-modal .pi .text-on-primary:hover{background:var(--colorPrimaryHover);border-color:var(--colorPrimaryHover)}.blocks-app .image-editor-modal .pi .text-on-primary.rounded-full{border-radius:calc(var(--borderRadius) * 1px)}.blocks-app .image-editor-modal .pi .shadow-xl{box-shadow:none}.blocks-app .image-editor-modal .w-\\[4ch\\].text-sm.text-center{width:5ch}.blocks-app .image-editor-modal .pi .border-white{border-color:var(--colorPrimary)}.blocks-app .image-editor-modal .pi .bg-white\\/50{background-color:var(--colorPrimary)}.blocks-app .image-editor-modal .pi .text-on-primary{color:var(--colorWhite)}.blocks-app .serach-results .ant-row{align-items:center}.blocks-app .serach-results .blocks-search__divider-wrapper{margin-top:12px;position:relative}.blocks-app .serach-results .blocks-search__divider-wrapper .ant-divider-horizontal{border-top:1px solid var(--colorBorderSecondary);background:0 0;width:100%;height:1px;min-height:0;margin:0;position:static}.blocks-app .slideshow-container{width:524px;height:350px;margin:auto;position:relative;overflow:hidden}.blocks-app .slideshow-image{opacity:0;width:100%;height:100%;position:absolute;top:0;left:0}.blocks-app .image-ai .slideshow-image{width:auto;height:auto}.blocks-app .image-ai__image-item{text-align:center;border-radius:6px;justify-content:center;align-items:center;min-height:100px;display:flex;position:relative}.blocks-app .image-ai__image-item .buttons{justify-content:space-between;display:flex;position:absolute;bottom:10px;left:50%;transform:translate(-50%)}.blocks-app .image-ai .text-area-input-hybrid{border:none;outline:none;min-height:0;padding:0 0 0 1px}.blocks-app .image-ai .text-area-input-hybrid textarea{height:32px;min-height:32px;padding:3px 11px;line-height:26px}.blocks-app .image-ai__loading{justify-content:center;align-items:center;min-height:150px;display:flex}.blocks-app .image-ai__loading .spin{flex-direction:column;justify-content:center;align-items:center;height:150px;display:flex}.blocks-app .image-ai__loading .status{margin:3px 0 0}.blocks-app .image-ai__preview{border-radius:6px;margin-top:24px;overflow:hidden}.blocks-app .image-ai__preview .image-ai__image-item img{border-radius:calc(var(--borderRadius) * 1px);object-fit:contain;max-height:100%;transition:height 1s;top:50%;left:50%;overflow:hidden;transform:translate(-50%,-50%)}.blocks-app .image-ai .small{width:302px;height:202px}.blocks-app .image-ai .large{width:524px;height:350px}.blocks-app .image-ai .image-ai__row{padding:0 2px}.blocks-app .image-ai .image-ai__input-affix-wrapper{border-style:solid;border-width:calc(var(--borderWidth) * 1px);border-color:var(--colorFillSecondaryDarken);border-radius:calc(var(--borderRadius) * 1px);width:100%;padding-left:0;display:inline-flex}.blocks-app .image-ai .image-ai__input-affix-wrapper:hover{border-color:var(--borderColorHover)}.blocks-app .image-ai .image-ai__input-affix-wrapper.ant-input-affix-wrapper-focused{border-color:var(--colorPrimaryBorder)}.blocks-app .image-ai .image-ai__textarea{font-size:16px}.blocks-app .image-ai .image-ai__input-icon{font-size:16px;top:0;right:0}.dark .blocks-app .image-ai .image-ai__preview .image-ai__image-item img{background:#2b2b2b;border:1px solid #434343}.dark .blocks-app .image-ai .ant-btn{background:#1f1f1f}.dark .blocks-app .image-ai .ant-btn:hover{color:var(--colorPrimary)}.blocks-app .stock-tab img{border-radius:0;max-width:none;max-height:none}.blocks-app .stock-tab .stock-search-input{padding:0 2px}.blocks-app .stock-tab .my-masonry-grid{text-align:center;width:auto;display:flex}.blocks-app .stock-tab .my-masonry-grid_column{background-clip:padding-box}.blocks-app .stock-tab .list-item{cursor:pointer;background:#f0f2f5;border:1px solid #f0f2f5;border-radius:6px;min-height:100px;max-height:100px;margin-bottom:20px;transition:all .3s;display:inline-block;position:relative;overflow:hidden}.blocks-app .stock-tab .list-item .overlay-image{opacity:0;background-size:cover;width:110px;height:40px;transition:opacity .5s;position:absolute;bottom:10px;right:10px}.blocks-app .stock-tab .list-item .ant-spin{color:#f0f2f5;font-size:20px;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%)}.blocks-app .stock-tab .list-item img{object-fit:cover;opacity:0;border-radius:6px;height:auto;transition:opacity .5s ease-in-out;display:block}.blocks-app .stock-tab .list-item.loaded{border:1px solid #d9d9d9;max-height:1000px}.blocks-app .stock-tab .list-item.loaded img{opacity:1;height:100%}.blocks-app .stock-tab .list-item.loaded .loaded-image{opacity:.5}.blocks-app .stock-tab .list-item:hover{box-shadow:0 1px 2px -2px #00000029,0 3px 6px #0000001f,0 5px 12px 4px #00000017}.blocks-app .stock-tab .list-item:hover p.creator-info,.blocks-app .stock-tab .list-item:hover .overlay-image{opacity:1}.blocks-app .stock-tab .list-item p.creator-info{color:#fff;opacity:0;background-color:#00000080;border-radius:0 0 6px;margin:0;padding:5px;font-size:10px;line-height:1.2;position:absolute;bottom:0;right:0}.blocks-app .stock-tab .list-item p.creator-info:hover a{color:#fff;text-decoration:underline}.blocks-app .stock-tab .list-item p.creator-info a{color:#fff;text-decoration:none}.blocks-app .stock-color-filter{display:flex}.blocks-app .stock-color-filter label{border-width:1px;width:24px;height:24px;margin:4px;padding:0;font-size:0;border-radius:6px!important}.blocks-app .stock-color-filter label.all-colors{background-image:linear-gradient(135deg,red,#ff7f00,#ff0,#0f0,#00f,#8b00ff)}.blocks-app .stock-color-filter label.black-color{background:#222}.blocks-app .stock-color-filter label.bw-color{background-image:linear-gradient(135deg,#222 50%,#fff 50%)}.blocks-app .stock-color-filter label.white-color{background:#fff}.blocks-app .stock-color-filter label.orange-color{background:#fa8c16}.blocks-app .stock-color-filter label.red-color{background:#f5222d}.blocks-app .stock-color-filter label.purple-color{background:#722ed1}.blocks-app .stock-color-filter label.magenta-color{background:#eb2f96}.blocks-app .stock-color-filter label.green-color{background:#52c41a}.blocks-app .stock-color-filter label.teal-color{background:#43c3c3}.blocks-app .stock-color-filter label.blue-color{background:#1677ff}.blocks-app .stock-color-filter .ant-radio-button-wrapper:not(:first-child):before{display:none}.blocks-app .serach-results{padding-top:6px}.blocks-app .serach-results .stock-search-input{width:322px;padding:0 2px}.blocks-app .serach-results .blocks-search__divider-wrapper{width:calc(100% + 48px);margin-top:12px;margin-left:-24px;margin-right:-24px;position:relative}.blocks-app .serach-results .blocks-search__divider-wrapper .ant-divider-horizontal{pointer-events:none;border-top:1px solid var(--colorBorderSecondary);background:linear-gradient(180deg, var(--colorBgContainerDisabled), transparent 40%);border-bottom:none;width:100%;height:20px;min-height:20px;margin:0;position:relative;bottom:auto;left:auto;right:auto}.dark .blocks-app .image-center .stock-tab .serach-results .blocks-search__divider-wrapper .ant-divider-horizontal{background:linear-gradient(180deg, var(--colorBgBase), transparent 40%)}.dark .blocks-app .stock-tab .list-item{background:#2b2b2b;border:1px solid #2b2b2b}.dark .blocks-app .stock-tab .list-item.loaded{border:1px solid #434343}.blocks-app .image-center .image-center-image-preview{justify-content:center;align-items:center;display:flex}.blocks-app .image-center .ant-divider-horizontal{pointer-events:none;z-index:1;background:linear-gradient(180deg, var(--colorBgContainerDisabled), transparent 40%);width:calc(100% + 48px);height:20px;margin:24px -24px 0;position:absolute;bottom:-19px}.dark .blocks-app .image-center .ant-divider-horizontal{background:linear-gradient(180deg, var(--colorBgBase), transparent 40%)}.blocks-app .image-center .ant-divider-horizontal.ant-divider-with-text{background:0 0;width:calc(100% + 38px);margin:0 -24px 20px;position:relative;top:0}.blocks-app .image-center img{border-radius:4px;max-width:524px;max-height:352px}.blocks-app .image-center .image-size{justify-content:center;margin-top:6px;font-size:14px;line-height:22px;display:flex}.blocks-app .image-center .ant-upload.ant-upload-drag{border-radius:6px}.blocks-app .image-center .ant-modal-body .stock-search-input{margin-bottom:0}.blocks-app .image-center .ant-modal-body .serach-results .stock-search-input{margin-bottom:10px}.blocks-app .image-center .ant-modal-body .ant-form:not(.serach-results) .ant-form-item:last-child{margin-bottom:0}.blocks-app .image-center .ant-modal-body .ant-tabs{transition:all .7s cubic-bezier(.075,.82,.165,1)}.blocks-app .image-center .ant-modal-body .ant-tabs .ant-tabs-content-holder{overflow-y:clip}.blocks-app .ant-modal{transition:width .7s ease-in-out}")),document.head.appendChild(o)}}catch(a){console.error("vite-plugin-css-injected-by-js",a)}})();
2
- __useblocks__.define("static/core/922866fe.js", [
2
+ __useblocks__.define("static/core/d8749999.js", [
3
3
  "require",
4
4
  "exports",
5
5
  "module",
@@ -7,15 +7,15 @@ __useblocks__.define("static/core/922866fe.js", [
7
7
  "static/core/bb774fb9.js",
8
8
  "static/core/632d894f.js",
9
9
  "static/core/04557bf3.js",
10
- "static/core/f99bda3c.js",
11
- "static/core/e97665732.js",
12
- "static/core/db330968.js",
10
+ "static/core/94f2c0df.js",
11
+ "static/core/a59902082.js",
12
+ "static/core/d2b26db6.js",
13
13
  "react",
14
14
  "prop-types",
15
15
  "react-router-dom",
16
16
  "react/jsx-runtime"
17
17
  ], function(ee, bt, on) {
18
- const nt = ee("./bd36b180.js"), d = ee("./bb774fb9.js"), z = ee("./632d894f.js"), u = ee("./04557bf3.js"), Ct = ee("./f99bda3c.js"), U = ee("./e97665732.js"), q = ee("./db330968.js");
18
+ const nt = ee("./bd36b180.js"), d = ee("./bb774fb9.js"), z = ee("./632d894f.js"), u = ee("./04557bf3.js"), Ct = ee("./94f2c0df.js"), U = ee("./a59902082.js"), q = ee("./d2b26db6.js");
19
19
  let o = ee("react");
20
20
  o = nt.__toESM(o);
21
21
  let Fe = ee("prop-types");
@@ -213,38 +213,38 @@ __useblocks__.define("static/core/922866fe.js", [
213
213
  const b = d.useStore(), j = d.useAppConfig(), y = d.useSelector(d.selectedCurrentUser), M = d.useSelector(z.selectSecondModal), v = d.useSelector(d.selectProject), k = (0, o.useMemo)(() => {
214
214
  if (!j?.icons) return;
215
215
  const E = {};
216
- for (const [L, R] of Object.entries(j.icons)) typeof R == "string" && (E[L] = U.sanitizeHtml(R));
216
+ for (const [R, O] of Object.entries(j.icons)) typeof O == "string" && (E[R] = U.sanitizeHtml(O));
217
217
  return Object.keys(E).length > 0 ? E : void 0;
218
- }, [j?.icons]), O = (0, o.useRef)(!1), [T, H] = (0, o.useState)(), B = d.useEventEmitter(d.events.FILE_PROXY_EVENT_ID);
218
+ }, [j?.icons]), L = (0, o.useRef)(!1), [T, H] = (0, o.useState)(), B = d.useEventEmitter(d.events.FILE_PROXY_EVENT_ID);
219
219
  (0, o.useEffect)(() => {
220
220
  (async () => {
221
- const L = n;
222
- if (!L && !e) return;
223
- let R;
221
+ const R = n;
222
+ if (!R && !e) return;
223
+ let O;
224
224
  if (e) try {
225
225
  const I = await fetch(e);
226
- I.ok && (R = await I.blob());
226
+ I.ok && (O = await I.blob());
227
227
  } catch {
228
- R = void 0;
228
+ O = void 0;
229
229
  }
230
- if (!R && L) try {
231
- R = await (await fetch(L)).blob();
230
+ if (!O && R) try {
231
+ O = await (await fetch(R)).blob();
232
232
  } catch {
233
- if (R = await B.fire({
234
- url: L,
233
+ if (O = await B.fire({
234
+ url: R,
235
235
  project: v
236
- }).filter((I) => I instanceof Blob)[0], !R) {
236
+ }).filter((I) => I instanceof Blob)[0], !O) {
237
237
  const I = l.get(d.APP_COOKIES.em_token) || await d.di.getInstance(b, z.TOKEN_ID);
238
- R = await (await fetch(`https://app.useblocks.io/api/wp-json/cors-proxy/v1/get?url=${encodeURIComponent(L)}`, { headers: { authorization: `Bearer ${I}` } })).blob();
238
+ O = await (await fetch(`https://app.useblocks.io/api/wp-json/cors-proxy/v1/get?url=${encodeURIComponent(R)}`, { headers: { authorization: `Bearer ${I}` } })).blob();
239
239
  }
240
240
  }
241
- if (R) {
241
+ if (O) {
242
242
  let I = new FileReader();
243
243
  I.onload = () => {
244
- T?.tools.import.openBackgroundImage(h), I.result !== h && (C(I.result), S(R.type));
245
- }, I.readAsDataURL(R);
244
+ T?.tools.import.openBackgroundImage(h), I.result !== h && (C(I.result), S(O.type));
245
+ }, I.readAsDataURL(O);
246
246
  }
247
- })().catch((L) => {});
247
+ })().catch((R) => {});
248
248
  }, [
249
249
  n,
250
250
  e,
@@ -260,23 +260,23 @@ __useblocks__.define("static/core/922866fe.js", [
260
260
  const D = (0, o.useCallback)(() => {
261
261
  C(null), S(null), f(z.closeSecondModal()), f(z.closeModal(d.MODALS.UPLOAD_IMAGE_MODAL));
262
262
  }, [f]), F = (0, o.useRef)();
263
- F.current = async function(E, L, R) {
264
- const I = await xt(R, E);
265
- t && t(new File([I], L, {
263
+ F.current = async function(E, R, O) {
264
+ const I = await xt(O, E);
265
+ t && t(new File([I], R, {
266
266
  lastModified: new Date().getTime(),
267
267
  type: I.type
268
268
  }));
269
269
  };
270
270
  const Z = (0, o.useCallback)((E) => {
271
- if (E && !(O.current && T)) {
272
- O.current = !0;
273
- const L = y.locale ? y.locale.replace("_", "-") : "en-US", R = y.theme === "system" ? matchMedia("(prefers-color-scheme: dark)").matches ? d.DARK : d.LIGHT : y.theme;
271
+ if (E && !(L.current && T)) {
272
+ L.current = !0;
273
+ const R = y.locale ? y.locale.replace("_", "-") : "en-US", O = y.theme === "system" ? matchMedia("(prefers-color-scheme: dark)").matches ? d.DARK : d.LIGHT : y.theme;
274
274
  Ct.Tf.init({
275
275
  selector: "#pixie-editor",
276
276
  baseUrl: u.getAssetUrl("assets/pixie"),
277
277
  image: h,
278
- activeLanguage: L,
279
- languages: wt(L, x),
278
+ activeLanguage: R,
279
+ languages: wt(R, x),
280
280
  tools: At,
281
281
  ui: {
282
282
  menubar: {
@@ -318,7 +318,7 @@ __useblocks__.define("static/core/922866fe.js", [
318
318
  ]
319
319
  },
320
320
  nav: { position: "top" },
321
- activeTheme: R,
321
+ activeTheme: O,
322
322
  mode: "inline",
323
323
  forceOverlayModeOnMobile: !1
324
324
  },
@@ -419,7 +419,7 @@ __useblocks__.define("static/core/922866fe.js", [
419
419
  for (var i in t) t.hasOwnProperty(i) && (s[i] = t[i]);
420
420
  }, ze(n, e);
421
421
  };
422
- function Rt(n, e) {
422
+ function Ot(n, e) {
423
423
  ze(n, e);
424
424
  function s() {
425
425
  this.constructor = n;
@@ -435,7 +435,7 @@ __useblocks__.define("static/core/922866fe.js", [
435
435
  return e;
436
436
  }, we.apply(this, arguments);
437
437
  };
438
- function Lt(n, e, s, t) {
438
+ function Rt(n, e, s, t) {
439
439
  var i, l = !1, h = 0;
440
440
  function C() {
441
441
  i && clearTimeout(i);
@@ -477,7 +477,7 @@ __useblocks__.define("static/core/922866fe.js", [
477
477
  } : st : st;
478
478
  }
479
479
  var ot = (function(n) {
480
- Rt(e, n);
480
+ Ot(e, n);
481
481
  function e(s) {
482
482
  var t = n.call(this, s) || this;
483
483
  return t.lastScrollTop = 0, t.actionTriggered = !1, t.startY = 0, t.currentY = 0, t.dragging = !1, t.maxPullDownDistance = 0, t.getScrollableTarget = function() {
@@ -500,7 +500,7 @@ __useblocks__.define("static/core/922866fe.js", [
500
500
  showLoader: !1,
501
501
  pullToRefreshThresholdBreached: !1,
502
502
  prevDataLength: s.dataLength
503
- }, t.throttledOnScrollListener = Lt(150, t.onScrollListener).bind(t), t.onStart = t.onStart.bind(t), t.onMove = t.onMove.bind(t), t.onEnd = t.onEnd.bind(t), t;
503
+ }, t.throttledOnScrollListener = Rt(150, t.onScrollListener).bind(t), t.onStart = t.onStart.bind(t), t.onMove = t.onMove.bind(t), t.onEnd = t.onEnd.bind(t), t;
504
504
  }
505
505
  return e.prototype.componentDidMount = function() {
506
506
  if (typeof this.props.dataLength > "u") throw new Error("mandatory prop \"dataLength\" is missing. The prop is needed when loading more content. Check README.md for usage");
@@ -549,7 +549,7 @@ __useblocks__.define("static/core/922866fe.js", [
549
549
  } }, this.state.pullToRefreshThresholdBreached ? this.props.releaseToRefreshContent : this.props.pullDownToRefreshContent)), this.props.children, !this.state.showLoader && !i && this.props.hasMore && this.props.loader, this.state.showLoader && this.props.hasMore && this.props.loader, !this.props.hasMore && this.props.endMessage));
550
550
  }, e;
551
551
  })(o.Component);
552
- function Ot(n, e) {
552
+ function Lt(n, e) {
553
553
  if (n == null) return {};
554
554
  var s = kt(n, e), t, i;
555
555
  if (Object.getOwnPropertySymbols) {
@@ -664,7 +664,7 @@ __useblocks__.define("static/core/922866fe.js", [
664
664
  }
665
665
  logDeprecated(n) {}
666
666
  render() {
667
- const n = this.props, { children: e, breakpointCols: s, columnClassName: t, columnAttrs: i, column: l, className: h } = n, C = Ot(n, [
667
+ const n = this.props, { children: e, breakpointCols: s, columnClassName: t, columnAttrs: i, column: l, className: h } = n, C = Lt(n, [
668
668
  "children",
669
669
  "breakpointCols",
670
670
  "columnClassName",
@@ -714,8 +714,8 @@ __useblocks__.define("static/core/922866fe.js", [
714
714
  const M = Ke(y.handleChangeSrc?.(), y.src);
715
715
  return M?.changed && M.src && (S[b] = M.src), y.subscribeToSrcChange?.((v) => {
716
716
  const k = Ke(v, y.src);
717
- !k?.changed || !k.src || l((O) => O[b] === k.src ? O : {
718
- ...O,
717
+ !k?.changed || !k.src || l((L) => L[b] === k.src ? L : {
718
+ ...L,
719
719
  [b]: k.src
720
720
  });
721
721
  });
@@ -743,7 +743,7 @@ __useblocks__.define("static/core/922866fe.js", [
743
743
  };
744
744
  }
745
745
  var lt = "blocks", Tt = ({ setCurrentImageLink: n, setModalHeight: e, setModalWidth: s, setImageStockList: t, imageStockList: i, currentReq: l, setCurrentReq: h, inputRef: C, setStockLink: g, customRequest: S }) => {
746
- const x = d.useAppConfig(), f = d.useIsStandalone(), [b, j] = (0, o.useState)(!1), [y, M] = (0, o.useState)(2), { __: v } = u.useI18n(), k = u.useNotification(), [O] = z.useLazyGetUnsplashImageQuery(), [T] = z.useLazyGetSearchImageQuery(), H = (0, o.useCallback)((a) => a instanceof Error || typeof a?.message == "string" && a.message ? a.message : typeof a?.error?.message == "string" && a.error.message ? a.error.message : v("Failed to load stock images through the configured proxy chain."), [v]), B = (0, o.useCallback)((a) => {
746
+ const x = d.useAppConfig(), f = d.useIsStandalone(), [b, j] = (0, o.useState)(!1), [y, M] = (0, o.useState)(2), { __: v } = u.useI18n(), k = u.useNotification(), [L] = z.useLazyGetUnsplashImageQuery(), [T] = z.useLazyGetSearchImageQuery(), H = (0, o.useCallback)((a) => a instanceof Error || typeof a?.message == "string" && a.message ? a.message : typeof a?.error?.message == "string" && a.error.message ? a.error.message : v("Failed to load stock images through the configured proxy chain."), [v]), B = (0, o.useCallback)((a) => {
747
747
  k.error({
748
748
  id: "STOCK_IMAGES_SEARCH_FAILED",
749
749
  title: v("Failed to load stock images"),
@@ -784,22 +784,22 @@ __useblocks__.define("static/core/922866fe.js", [
784
784
  m.length > 0 ? (t(m), setTimeout(() => {
785
785
  s(1060), e("84vh");
786
786
  }, 0)) : t([]);
787
- }, [Z, G] = (0, o.useState)(null), E = (0, o.useCallback)((a, m, K) => `${a}${a.includes("?") ? "&" : "?"}w=${m}&q=${K}`, []), L = (0, o.useCallback)((a) => d.getProxiedUrl(a, {
787
+ }, [Z, G] = (0, o.useState)(null), E = (0, o.useCallback)((a, m, K) => `${a}${a.includes("?") ? "&" : "?"}w=${m}&q=${K}`, []), R = (0, o.useCallback)((a) => d.getProxiedUrl(a, {
788
788
  config: x,
789
789
  standalone: f,
790
790
  resourceType: "stockImages",
791
791
  intent: "display"
792
- }), [x, f]), { getDisplaySrc: R, handleLoad: I, handleError: Y } = it({
792
+ }), [x, f]), { getDisplaySrc: O, handleLoad: I, handleError: Y } = it({
793
793
  items: i,
794
794
  getItemId: (0, o.useCallback)((a) => a.id, []),
795
795
  getRequestUrl: (0, o.useCallback)((a) => E(a.urls.raw, 644, 96), [E]),
796
- createController: L
796
+ createController: R
797
797
  }), W = (a) => (m) => {
798
798
  I(a), m.target.parentNode.classList.add("loaded");
799
799
  }, X = (a) => () => {
800
800
  Y(a);
801
801
  }, V = (a, m, K) => {
802
- O(m.download_location), G(K), setTimeout(() => G(null), 2e3), g(`${a.raw}&w=1200&q=96`), n(`${a.raw}&w=1200&q=96`), S(`${a.raw}&w=1200&q=96`);
802
+ L(m.download_location), G(K), setTimeout(() => G(null), 2e3), g(`${a.raw}&w=1200&q=96`), n(`${a.raw}&w=1200&q=96`), S(`${a.raw}&w=1200&q=96`);
803
803
  };
804
804
  return (0, r.jsxs)("div", {
805
805
  className: "stock-tab",
@@ -977,7 +977,7 @@ __useblocks__.define("static/core/922866fe.js", [
977
977
  (0, r.jsx)("img", {
978
978
  className: Z === a.id ? "loaded-image" : "",
979
979
  width: "322px",
980
- src: R(a),
980
+ src: O(a),
981
981
  alt: a.description,
982
982
  onLoad: W(a),
983
983
  onError: X(a)
@@ -1045,7 +1045,7 @@ __useblocks__.define("static/core/922866fe.js", [
1045
1045
  });
1046
1046
  };
1047
1047
  function Ut({ setModalHeight: n, customRequest: e, aiTabRef: s, isImageUploaded: t, setIsImageUploaded: i, aiImageRequest: l, imageAiList: h, setImageAiList: C, isLoadingAi: g, setIsLoadingAi: S, onPluginAiImageLimitExceeded: x, onImageGenerateLimitExceeded: f }) {
1048
- const { __: b } = u.useI18n(), j = d.useAppConfig(), y = u.useNotification(), M = d.usePushToDataLayer(), { emailId: v, blockId: k, projectId: O } = (0, Ge.useParams)(), [T] = z.useLazySendAiImageRequestQuery(), [H, { data: B = [] }] = z.useLazyGetAiImageSSEQuery(), [D] = z.useLazyGetLimitsStatsByTypeQuery(), F = j?.sendAIImageRequest || T, Z = j?.trigger || H, G = j?.handleLimitUsageEmitter || d.useEventEmitter(d.events.ON_LIMIT_ID), [E, L] = (0, o.useState)(0), [R, I] = (0, o.useState)(null), [Y, W] = (0, o.useState)(!1), [X, V] = (0, o.useState)(b("Evaluating the task")), [a, m] = (0, o.useState)(!1), K = v || k, { limits: fe } = j?.limits ? j : { limits: { ai_img_limit: 0 } }, { ai_img_limit: $ } = fe, he = $ > 0 && E >= $, P = !!(j.limits && j.counters) && d.PLUGIN.isPlugin, J = (0, o.useCallback)(() => {
1048
+ const { __: b } = u.useI18n(), j = d.useAppConfig(), y = u.useNotification(), M = d.usePushToDataLayer(), { emailId: v, blockId: k, projectId: L } = (0, Ge.useParams)(), [T] = z.useLazySendAiImageRequestQuery(), [H, { data: B = [] }] = z.useLazyGetAiImageSSEQuery(), [D] = z.useLazyGetLimitsStatsByTypeQuery(), F = j?.sendAIImageRequest || T, Z = j?.trigger || H, G = j?.handleLimitUsageEmitter || d.useEventEmitter(d.events.ON_LIMIT_ID), [E, R] = (0, o.useState)(0), [O, I] = (0, o.useState)(null), [Y, W] = (0, o.useState)(!1), [X, V] = (0, o.useState)(b("Evaluating the task")), [a, m] = (0, o.useState)(!1), K = v || k, { limits: fe } = j?.limits ? j : { limits: { ai_img_limit: 0 } }, { ai_img_limit: $ } = fe, he = $ > 0 && E >= $, P = !!(j.limits && j.counters) && d.PLUGIN.isPlugin, J = (0, o.useCallback)(() => {
1049
1049
  G.fire({
1050
1050
  name: "AiImgCount",
1051
1051
  count: E + 1
@@ -1060,9 +1060,9 @@ __useblocks__.define("static/core/922866fe.js", [
1060
1060
  event: "submit_form",
1061
1061
  action: "ai_image_generation",
1062
1062
  entity_id: v,
1063
- project_id: O
1063
+ project_id: L
1064
1064
  }), F({ body: {
1065
- project_id: O,
1065
+ project_id: L,
1066
1066
  request: "create-image",
1067
1067
  connection: "midjourney",
1068
1068
  message: l
@@ -1095,7 +1095,7 @@ __useblocks__.define("static/core/922866fe.js", [
1095
1095
  C,
1096
1096
  M,
1097
1097
  v,
1098
- O,
1098
+ L,
1099
1099
  F,
1100
1100
  y,
1101
1101
  Z,
@@ -1110,7 +1110,7 @@ __useblocks__.define("static/core/922866fe.js", [
1110
1110
  return;
1111
1111
  }
1112
1112
  }
1113
- P && (L((w) => w + 1), J()), xe();
1113
+ P && (R((w) => w + 1), J()), xe();
1114
1114
  } else P && (x ? x() : y.error({
1115
1115
  title: b("The usage limit has been exceeded"),
1116
1116
  description: b(`The maximum number of requests for the current subscription period has been reached.
@@ -1122,7 +1122,7 @@ Select the appropriate plan to fulfil more requests`),
1122
1122
  P,
1123
1123
  D,
1124
1124
  f,
1125
- L,
1125
+ R,
1126
1126
  J,
1127
1127
  xe,
1128
1128
  y,
@@ -1130,7 +1130,7 @@ Select the appropriate plan to fulfil more requests`),
1130
1130
  x
1131
1131
  ]);
1132
1132
  (0, o.useEffect)(() => {
1133
- P && L(j?.counters?.ai_img_counter || 0);
1133
+ P && R(j?.counters?.ai_img_counter || 0);
1134
1134
  }, [j, P]);
1135
1135
  const ue = (0, o.useCallback)((w) => {
1136
1136
  if (!t) {
@@ -1151,7 +1151,7 @@ Select the appropriate plan to fulfil more requests`),
1151
1151
  id: "AI_IMAGE_GET_ERROR",
1152
1152
  title: b("Something went wrong, please try again"),
1153
1153
  placement: "bottomRight",
1154
- data: R
1154
+ data: O
1155
1155
  }));
1156
1156
  }, [
1157
1157
  C,
@@ -1159,7 +1159,7 @@ Select the appropriate plan to fulfil more requests`),
1159
1159
  b,
1160
1160
  S,
1161
1161
  n,
1162
- R,
1162
+ O,
1163
1163
  y,
1164
1164
  m
1165
1165
  ]);
@@ -1178,7 +1178,7 @@ Select the appropriate plan to fulfil more requests`),
1178
1178
  n
1179
1179
  ]), {
1180
1180
  aiImageCounter: E,
1181
- setAiImageCounter: L,
1181
+ setAiImageCounter: R,
1182
1182
  currentAiImgLimits: $,
1183
1183
  isFieldsDisabled: he,
1184
1184
  canGenerateImage: te,
@@ -1196,13 +1196,13 @@ Select the appropriate plan to fulfil more requests`),
1196
1196
  convertBase64ToFile: ue,
1197
1197
  isShiftPressed: Y,
1198
1198
  setIsShiftPressed: W,
1199
- currentReqId: R,
1199
+ currentReqId: O,
1200
1200
  setCurrentReqId: I,
1201
1201
  limitsInPlugin: P
1202
1202
  };
1203
1203
  }
1204
1204
  var Mt = ({ setModalHeight: n, customRequest: e, aiTabRef: s, inputAiRef: t, isImageUploaded: i, setIsImageUploaded: l, aiImageRequest: h, setAiImageRequest: C, imageAiList: g, setImageAiList: S, isLoadingAi: x, setIsLoadingAi: f }) => {
1205
- const b = (0, Ge.useNavigate)(), j = d.useDispatch(), { __: y, _n: M } = u.useI18n(), v = d.useAppConfig(), [k, O] = (0, o.useState)(!1), [T, H] = (0, o.useState)(null), { aiImageCounter: B, currentAiImgLimits: D, loadingDuringGeneration: F, requestStatus: Z, handleGenerate: G, convertBase64ToFile: E, isShiftPressed: L, setIsShiftPressed: R, limitsInPlugin: I } = Ut({
1205
+ const b = (0, Ge.useNavigate)(), j = d.useDispatch(), { __: y, _n: M } = u.useI18n(), v = d.useAppConfig(), [k, L] = (0, o.useState)(!1), [T, H] = (0, o.useState)(null), { aiImageCounter: B, currentAiImgLimits: D, loadingDuringGeneration: F, requestStatus: Z, handleGenerate: G, convertBase64ToFile: E, isShiftPressed: R, setIsShiftPressed: O, limitsInPlugin: I } = Ut({
1206
1206
  setModalHeight: n,
1207
1207
  customRequest: e,
1208
1208
  aiTabRef: s,
@@ -1213,30 +1213,30 @@ Select the appropriate plan to fulfil more requests`),
1213
1213
  setImageAiList: S,
1214
1214
  isLoadingAi: x,
1215
1215
  setIsLoadingAi: f,
1216
- onPluginAiImageLimitExceeded: () => O(!0),
1216
+ onPluginAiImageLimitExceeded: () => L(!0),
1217
1217
  onImageGenerateLimitExceeded: H
1218
1218
  }), Y = k && D > 0 ? q.getAiTariffUpgradeStep(D) : null, W = Y ? U.getLimitUpgradePresetDefinition(Y.presetId) : null, X = T ? U.getLimitUpgradePresetDefinition(T.presetId) : null, [V, a] = (0, o.useState)(!1), m = (0, o.useCallback)(() => a(!0), []), K = (0, o.useCallback)(() => a(!1), []), fe = (0, o.useCallback)((J) => C(J.target.value), [C]), $ = (0, o.useCallback)((J) => {
1219
- J.key === "Shift" ? R(!0) : J.key === "Enter" && !L && (J.preventDefault(), G());
1219
+ J.key === "Shift" ? O(!0) : J.key === "Enter" && !R && (J.preventDefault(), G());
1220
1220
  }, [
1221
- L,
1221
+ R,
1222
1222
  G,
1223
- R
1223
+ O
1224
1224
  ]), he = (0, o.useCallback)((J) => {
1225
- J.key === "Shift" && R(!1);
1226
- }, [R]), P = g[g.length - 1];
1225
+ J.key === "Shift" && O(!1);
1226
+ }, [O]), P = g[g.length - 1];
1227
1227
  return (0, r.jsxs)("div", {
1228
1228
  className: "image-ai",
1229
1229
  children: [
1230
1230
  W && Y ? (0, r.jsx)(U.LimitUpgradeModal, {
1231
1231
  open: !0,
1232
- onClose: () => O(!1),
1232
+ onClose: () => L(!1),
1233
1233
  title: y(W.titleKey),
1234
1234
  subtitle: y(W.subtitleKey),
1235
1235
  usageResource: W.usageResource,
1236
1236
  previousDisplay: U.presetLimitDisplay(Y.previousLimit),
1237
1237
  nextDisplay: U.presetLimitDisplay(Y.nextLimit),
1238
1238
  onChangePlan: () => {
1239
- O(!1), document.body.classList.remove("editor"), b("/billing"), j(z.openModal(d.MODALS.SWITCH_TO_PLAN_MODAL));
1239
+ L(!1), document.body.classList.remove("editor"), b("/billing"), j(z.openModal(d.MODALS.SWITCH_TO_PLAN_MODAL));
1240
1240
  }
1241
1241
  }) : null,
1242
1242
  X && T ? (0, r.jsx)(U.LimitUpgradeModal, {
@@ -1332,7 +1332,7 @@ Select the appropriate plan to fulfil more requests`),
1332
1332
  ]
1333
1333
  });
1334
1334
  }, Pt = ({ setNewLink: n, setCurrentImageLink: e, setModalHeight: s, setModalWidth: t, setImageGifList: i, imageGifList: l, currentReqGif: h, setCurrentReqGif: C, inputRef: g, setStockLink: S, customRequest: x }) => {
1335
- const { __: f } = u.useI18n(), b = d.useAppConfig(), j = d.useIsStandalone(), y = u.useNotification(), [M, v] = (0, o.useState)(null), [k, O] = (0, o.useState)(!1), [T, H] = (0, o.useState)(25), [B] = z.useLazyGetSearchGifQuery(), D = (0, o.useCallback)((a) => a instanceof Error || typeof a?.message == "string" && a.message ? a.message : typeof a?.error?.message == "string" && a.error.message ? a.error.message : f("Failed to load GIFs through the configured proxy chain."), [f]), F = (0, o.useCallback)((a) => {
1335
+ const { __: f } = u.useI18n(), b = d.useAppConfig(), j = d.useIsStandalone(), y = u.useNotification(), [M, v] = (0, o.useState)(null), [k, L] = (0, o.useState)(!1), [T, H] = (0, o.useState)(25), [B] = z.useLazyGetSearchGifQuery(), D = (0, o.useCallback)((a) => a instanceof Error || typeof a?.message == "string" && a.message ? a.message : typeof a?.error?.message == "string" && a.error.message ? a.error.message : f("Failed to load GIFs through the configured proxy chain."), [f]), F = (0, o.useCallback)((a) => {
1336
1336
  y.error({
1337
1337
  id: "STOCK_GIFS_SEARCH_FAILED",
1338
1338
  title: f("Failed to load GIFs"),
@@ -1343,17 +1343,17 @@ Select the appropriate plan to fulfil more requests`),
1343
1343
  D,
1344
1344
  y
1345
1345
  ]), Z = async () => {
1346
- k || (O(!0), B({
1346
+ k || (L(!0), B({
1347
1347
  query: h,
1348
1348
  page: T
1349
1349
  }).then((a) => {
1350
1350
  if (a?.error) {
1351
- F(a.error), O(!1);
1351
+ F(a.error), L(!1);
1352
1352
  return;
1353
1353
  }
1354
- i((m) => [...m, ...a.data.data]), O(!1), H((m) => m + 25);
1354
+ i((m) => [...m, ...a.data.data]), L(!1), H((m) => m + 25);
1355
1355
  }).catch(() => {
1356
- O(!1);
1356
+ L(!1);
1357
1357
  }));
1358
1358
  }, G = async () => {
1359
1359
  const a = await B({
@@ -1371,7 +1371,7 @@ Select the appropriate plan to fulfil more requests`),
1371
1371
  v(m), setTimeout(() => {
1372
1372
  v(null);
1373
1373
  }, 2e3), S(`${a}`), e(`${a}`), x(`${a}`);
1374
- }, L = { default: 3 }, R = (0, o.useCallback)((a) => d.getProxiedUrl(a, {
1374
+ }, R = { default: 3 }, O = (0, o.useCallback)((a) => d.getProxiedUrl(a, {
1375
1375
  config: b,
1376
1376
  standalone: j,
1377
1377
  resourceType: "generic",
@@ -1380,7 +1380,7 @@ Select the appropriate plan to fulfil more requests`),
1380
1380
  items: l,
1381
1381
  getItemId: (0, o.useCallback)((a) => a.id, []),
1382
1382
  getRequestUrl: (0, o.useCallback)((a) => a.images.downsized.url, []),
1383
- createController: R
1383
+ createController: O
1384
1384
  }), X = (a) => (m) => {
1385
1385
  Y(a), m.target.parentNode.classList.add("loaded");
1386
1386
  }, V = (a) => () => {
@@ -1448,7 +1448,7 @@ Select the appropriate plan to fulfil more requests`),
1448
1448
  style: { overflow: "visible" },
1449
1449
  loader: (0, r.jsx)(u.Spin, { size: "small" }),
1450
1450
  children: (0, r.jsx)(We, {
1451
- breakpointCols: L,
1451
+ breakpointCols: R,
1452
1452
  className: "my-masonry-grid",
1453
1453
  columnClassName: "my-masonry-grid_column",
1454
1454
  children: l.map((a, m) => (0, r.jsxs)("div", {
@@ -1568,12 +1568,12 @@ Select the appropriate plan to fulfil more requests`),
1568
1568
  const s = Se(e);
1569
1569
  return !s || n.includes(".") ? n : `${n}.${s}`;
1570
1570
  }, _t = (n, e) => new File([n], Vt(Yt(e), n.type), { type: n.type || "application/octet-stream" }), dt = ({ dataProvider: n }) => {
1571
- const e = d.useAppConfig(), s = d.useIsStandalone(), { __: t } = u.useI18n(), i = d.useDispatch(), { projectId: l } = (0, Ge.useParams)(), [h] = z.useLazyGetImageInfoQuery(), { modal: C } = u.App.useApp(), g = u.useNotification(), S = d.useSelector(d.selectedIsUserPaySmth), x = d.useSelector(d.selectedCurrentUser), f = d.useSelector(z.selectActiveModal), { request: b, resolveImagePicker: j } = U.useImagePicker(), [y, M] = (0, o.useState)(""), [v, k] = (0, o.useState)(""), [O, T] = (0, o.useState)(""), [H, B] = (0, o.useState)(""), [D, F] = (0, o.useState)(oe), [Z, G] = (0, o.useState)({
1571
+ const e = d.useAppConfig(), s = d.useIsStandalone(), { __: t } = u.useI18n(), i = d.useDispatch(), { projectId: l } = (0, Ge.useParams)(), [h] = z.useLazyGetImageInfoQuery(), { modal: C } = u.App.useApp(), g = u.useNotification(), S = d.useSelector(d.selectedIsUserPaySmth), x = d.useSelector(d.selectedCurrentUser), f = d.useSelector(z.selectActiveModal), { request: b, resolveImagePicker: j } = U.useImagePicker(), [y, M] = (0, o.useState)(""), [v, k] = (0, o.useState)(""), [L, T] = (0, o.useState)(""), [H, B] = (0, o.useState)(""), [D, F] = (0, o.useState)(oe), [Z, G] = (0, o.useState)({
1572
1572
  width: "",
1573
1573
  height: "",
1574
1574
  size: "",
1575
1575
  format: ""
1576
- }), [E, L] = (0, o.useState)("success"), [R, I] = (0, o.useState)(!1), Y = o.default.useRef(null), W = o.default.useRef(null), X = o.default.useRef(null), V = o.default.useRef(null), a = o.default.useRef(null), m = o.default.useRef(null), K = o.default.useRef(null), fe = o.default.useRef(null), $ = o.default.useRef(null), [he, P] = (0, o.useState)("auto"), [J, te] = (0, o.useState)(572), [xe, De] = (0, o.useState)(!1), [ue, be] = (0, o.useState)({
1576
+ }), [E, R] = (0, o.useState)("success"), [O, I] = (0, o.useState)(!1), Y = o.default.useRef(null), W = o.default.useRef(null), X = o.default.useRef(null), V = o.default.useRef(null), a = o.default.useRef(null), m = o.default.useRef(null), K = o.default.useRef(null), fe = o.default.useRef(null), $ = o.default.useRef(null), [he, P] = (0, o.useState)("auto"), [J, te] = (0, o.useState)(572), [xe, De] = (0, o.useState)(!1), [ue, be] = (0, o.useState)({
1577
1577
  keywords: "",
1578
1578
  color: "",
1579
1579
  orientation: ""
@@ -1596,10 +1596,10 @@ Select the appropriate plan to fulfil more requests`),
1596
1596
  }, [t, g]), $t = (0, o.useCallback)(async (c) => U.pickUploadImageUrlFromFireResults(await mt.fire({
1597
1597
  file: c,
1598
1598
  project: ht
1599
- })), [ht, mt]), Re = q.useImageBlobFetch(), Ne = async (c) => {
1599
+ })), [ht, mt]), Oe = q.useImageBlobFetch(), Ne = async (c) => {
1600
1600
  if (c) try {
1601
1601
  const p = await en(c);
1602
- p && et(p) ? await Le({ file: p }) : p || Pe({ url: c }, null, t("Failed to download image from URL."));
1602
+ p && et(p) ? await Re({ file: p }) : p || Pe({ url: c }, null, t("Failed to download image from URL."));
1603
1603
  } catch (p) {
1604
1604
  Pe({ url: c }, p, t("Failed to process image URL."));
1605
1605
  }
@@ -1622,7 +1622,7 @@ Select the appropriate plan to fulfil more requests`),
1622
1622
  const en = async (c) => {
1623
1623
  try {
1624
1624
  const p = q.canonicalImageUrlKey(c);
1625
- return _t(await je.current.resolve(p, void 0, Re), p);
1625
+ return _t(await je.current.resolve(p, void 0, Oe), p);
1626
1626
  } catch {}
1627
1627
  };
1628
1628
  document.onpaste = function(c) {
@@ -1632,7 +1632,7 @@ Select the appropriate plan to fulfil more requests`),
1632
1632
  const N = p.getAsFile();
1633
1633
  et(N);
1634
1634
  const Q = { file: N };
1635
- k(""), Le(Q);
1635
+ k(""), Re(Q);
1636
1636
  return;
1637
1637
  }
1638
1638
  const A = c.clipboardData?.getData("text/plain");
@@ -1687,9 +1687,9 @@ Select the appropriate plan to fulfil more requests`),
1687
1687
  g
1688
1688
  ]);
1689
1689
  (0, o.useEffect)(() => {
1690
- const c = v || O, p = q.canonicalImageUrlKey(c);
1690
+ const c = v || L, p = q.canonicalImageUrlKey(c);
1691
1691
  if (!c || !p) {
1692
- L(""), Ze.current = "", ne(), le(), je.current.invalidateAll();
1692
+ R(""), Ze.current = "", ne(), le(), je.current.invalidateAll();
1693
1693
  return;
1694
1694
  }
1695
1695
  const A = Ze.current;
@@ -1697,7 +1697,7 @@ Select the appropriate plan to fulfil more requests`),
1697
1697
  const N = new AbortController(), Q = v ? 800 : 0, _ = ++ge.current, tt = setTimeout(async () => {
1698
1698
  try {
1699
1699
  const ce = async () => {
1700
- const re = await je.current.resolve(p, N.signal, Re);
1700
+ const re = await je.current.resolve(p, N.signal, Oe);
1701
1701
  if (_ !== ge.current) return;
1702
1702
  const { width: pe, height: rn } = await q.getImageDimensionsFromBlob(re);
1703
1703
  if (_ !== ge.current) return;
@@ -1730,13 +1730,13 @@ Select the appropriate plan to fulfil more requests`),
1730
1730
  } else await ce();
1731
1731
  }
1732
1732
  if (_ !== ge.current) return;
1733
- L("success"), M(c), te(572), setTimeout(() => {
1733
+ R("success"), M(c), te(572), setTimeout(() => {
1734
1734
  let re = 0;
1735
1735
  W.current && (re = W.current.offsetHeight + 62), P(re);
1736
1736
  }, 0);
1737
1737
  } catch (ce) {
1738
1738
  if (ce?.name === "AbortError" || N.signal.aborted || _ !== ge.current) return;
1739
- ne(), le(), L("error");
1739
+ ne(), le(), R("error");
1740
1740
  }
1741
1741
  }, Q);
1742
1742
  return () => {
@@ -1744,19 +1744,19 @@ Select the appropriate plan to fulfil more requests`),
1744
1744
  };
1745
1745
  }, [
1746
1746
  v,
1747
- O,
1747
+ L,
1748
1748
  s,
1749
1749
  ne,
1750
- Re,
1750
+ Oe,
1751
1751
  h,
1752
1752
  le,
1753
1753
  n
1754
1754
  ]), (0, o.useEffect)(() => {
1755
- if (!y || v || O) return;
1755
+ if (!y || v || L) return;
1756
1756
  const c = q.canonicalImageUrlKey(y), p = new AbortController();
1757
1757
  let A = !1;
1758
1758
  const N = async () => {
1759
- const Q = await je.current.resolve(c, p.signal, Re);
1759
+ const Q = await je.current.resolve(c, p.signal, Oe);
1760
1760
  if (A) return;
1761
1761
  const { width: _, height: tt } = await q.getImageDimensionsFromBlob(Q);
1762
1762
  if (A) return;
@@ -1801,11 +1801,11 @@ Select the appropriate plan to fulfil more requests`),
1801
1801
  s,
1802
1802
  ne,
1803
1803
  y,
1804
- Re,
1804
+ Oe,
1805
1805
  h,
1806
1806
  n,
1807
1807
  v,
1808
- O
1808
+ L
1809
1809
  ]);
1810
1810
  const tn = () => {
1811
1811
  i(z.closeModal()), setTimeout(() => {
@@ -1855,7 +1855,7 @@ Select the appropriate plan to fulfil more requests`),
1855
1855
  title: "Upload",
1856
1856
  description: "You can only upload JPG/JPEG/PNG/WEBP/GIF/SVG file!"
1857
1857
  }), p;
1858
- }, Le = async ({ file: c }) => {
1858
+ }, Re = async ({ file: c }) => {
1859
1859
  try {
1860
1860
  De(!0);
1861
1861
  const p = await q.prepareImageForEditorUpload(c, e), A = await $t(p);
@@ -1870,8 +1870,8 @@ Select the appropriate plan to fulfil more requests`),
1870
1870
  } finally {
1871
1871
  De(!1);
1872
1872
  }
1873
- }, sn = (c) => Le({ file: c });
1874
- let Oe = [{
1873
+ }, sn = (c) => Re({ file: c });
1874
+ let Le = [{
1875
1875
  label: t("Upload"),
1876
1876
  key: oe,
1877
1877
  children: (0, r.jsxs)("div", {
@@ -1881,7 +1881,7 @@ Select the appropriate plan to fulfil more requests`),
1881
1881
  showUploadList: !1,
1882
1882
  name: "Image",
1883
1883
  beforeUpload: et,
1884
- customRequest: Le,
1884
+ customRequest: Re,
1885
1885
  style: { marginBottom: 10 },
1886
1886
  multiple: !1,
1887
1887
  accept: "image/png, image/jpeg, image/jpg, image/webp, image/gif, image/svg+xml",
@@ -1916,7 +1916,7 @@ Select the appropriate plan to fulfil more requests`),
1916
1916
  })]
1917
1917
  })
1918
1918
  }];
1919
- return e.imageCenterStockEnabled && !de && Oe.push({
1919
+ return e.imageCenterStockEnabled && !de && Le.push({
1920
1920
  label: t("Stock"),
1921
1921
  key: Ye,
1922
1922
  children: (0, r.jsx)("div", {
@@ -1935,7 +1935,7 @@ Select the appropriate plan to fulfil more requests`),
1935
1935
  customRequest: Ne
1936
1936
  })
1937
1937
  })
1938
- }), e.imageCenterGifEnabled && !de && Oe.push({
1938
+ }), e.imageCenterGifEnabled && !de && Le.push({
1939
1939
  label: t("GIF"),
1940
1940
  key: Ve,
1941
1941
  children: (0, r.jsx)("div", {
@@ -1954,7 +1954,7 @@ Select the appropriate plan to fulfil more requests`),
1954
1954
  customRequest: Ne
1955
1955
  })
1956
1956
  })
1957
- }), e.elementAIimageEnabled && !de && Oe.push({
1957
+ }), e.elementAIimageEnabled && !de && Le.push({
1958
1958
  label: t("AI"),
1959
1959
  key: _e,
1960
1960
  children: (0, r.jsx)("div", {
@@ -1962,7 +1962,7 @@ Select the appropriate plan to fulfil more requests`),
1962
1962
  style: { paddingBottom: 24 },
1963
1963
  children: (0, r.jsx)(Mt, {
1964
1964
  setModalHeight: P,
1965
- customRequest: Le,
1965
+ customRequest: Re,
1966
1966
  aiImageRequest: ft,
1967
1967
  setAiImageRequest: Qe,
1968
1968
  imageAiList: Be,
@@ -1971,11 +1971,11 @@ Select the appropriate plan to fulfil more requests`),
1971
1971
  setIsLoadingAi: pt,
1972
1972
  aiTabRef: a,
1973
1973
  inputAiRef: $,
1974
- isImageUploaded: R,
1974
+ isImageUploaded: O,
1975
1975
  setIsImageUploaded: I
1976
1976
  })
1977
1977
  })
1978
- }), e.imageCenterEditorEnabled && Oe.push({
1978
+ }), e.imageCenterEditorEnabled && Le.push({
1979
1979
  label: "",
1980
1980
  key: ve,
1981
1981
  children: (0, r.jsx)("div", {
@@ -2004,7 +2004,7 @@ Select the appropriate plan to fulfil more requests`),
2004
2004
  children: (0, r.jsx)(u.Tabs, {
2005
2005
  activeKey: D,
2006
2006
  onChange: nn,
2007
- items: Oe,
2007
+ items: Le,
2008
2008
  className: "modal-tabs",
2009
2009
  style: {
2010
2010
  height: he,
@@ -3,7 +3,7 @@
3
3
  <head>
4
4
  <meta charset="utf-8" />
5
5
  <title>Two-step flow: design → subject/preheader (headless)</title>
6
- <script id="plugin-script" type="text/javascript" src="useblocks.js?56efb32e"></script>
6
+ <script id="plugin-script" type="text/javascript" src="useblocks.js?bb621219"></script>
7
7
  <style>
8
8
  body {
9
9
  margin: 0;