@useinsider/guido 3.30.0-beta.a1f329f → 3.30.0-beta.abc28c7

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/README.md CHANGED
@@ -174,7 +174,6 @@ const config: GuidoConfigInput = {
174
174
  allowSaveWithErrors?: boolean, // Default: true - Allow the validation drawer's "Save and Continue" soft-save. Set false to hard-block invalid saves (transactional + unsubscribe pages).
175
175
  reusableRecommendationStrategy?: boolean, // Default: false - Assign an RRS strategy to recommendation blocks instead of per-block algorithm/filters/shuffle/product-count settings.
176
176
  legacyUnsubscribeConversion?: boolean, // Default: false - Convert legacy unsubscribe blocks that have no unsubscribe link into text blocks (on load and on module drop/copy) and show a warning modal.
177
- readonly?: boolean, // Default: false - Opens the design with Save disabled: no save path persists (toolbar Save, "Save and Continue", autosave, saveSilent() resolves undefined), no save:start / save:complete, and edits never emit on-change, so the host shows no leave-page warning. Read at mount; to change it, remount Guido.
178
177
  accessibilityTesting?: boolean, // Default: false - Show the Accessibility Test entry in the header kebab menu (Stripo's checker: contrast, image alternatives, colour-vision simulation) and the tab-bar onboarding tour that points at it.
179
178
  itemsPriceFormatting?: boolean, // Default: false - Items block price formatting: thousand/decimal separator + decimal count on the block root, raw price tags in the export (formatted at send time).
180
179
  blockUnsubscribeLinks?: boolean, // Default: false - Warn on save when the design carries an Insider unsubscribe link or code ({{ins-*-unsubscribe-link}}, <%asm_*_raw_url%>, <%unsub%>): the legacy save is rejected with a warning toaster; with the validation drawer on it is a warning row that "Save and Continue" can skip. Launch blocking is up to the host. Set true for accounts whose unsubscribes are managed outside Insider (SFMC).
@@ -1,5 +1,5 @@
1
1
  import { ModuleFolderDefaults as y } from "../../enums/defaults.js";
2
- import { object as o, number as c, optional as e, string as t, picklist as m, pipe as i, minLength as p, custom as k, boolean as a, array as n, transform as S, unknown as r, record as g, fallback as R, literal as u, lazy as T, looseObject as C, variant as I, union as h } from "../../node_modules/valibot/dist/index.js";
2
+ import { object as o, number as c, optional as e, string as t, picklist as m, pipe as r, minLength as p, custom as k, boolean as a, array as n, transform as S, unknown as i, record as g, fallback as R, literal as u, lazy as T, looseObject as C, variant as I, union as h } from "../../node_modules/valibot/dist/index.js";
3
3
  const b = {
4
4
  /** Promotional/marketing emails */
5
5
  PROMOTIONAL: 1,
@@ -14,12 +14,12 @@ const b = {
14
14
  UNSUBSCRIBE_PAGES: 97
15
15
  }, A = o({
16
16
  /** Unique identifier for the template being edited */
17
- templateId: i(
17
+ templateId: r(
18
18
  t(),
19
19
  p(1, "templateId is required")
20
20
  ),
21
21
  /** Unique identifier for the user editing the template */
22
- userId: i(
22
+ userId: r(
23
23
  t(),
24
24
  p(1, "userId is required")
25
25
  ),
@@ -40,7 +40,7 @@ const b = {
40
40
  family: t()
41
41
  }), E = o({
42
42
  /** Partner/organization name (required) */
43
- name: i(
43
+ name: r(
44
44
  t(),
45
45
  p(1, "partner.name is required")
46
46
  ),
@@ -93,23 +93,23 @@ const b = {
93
93
  /** Decimal places for price display (legacy data may use string or number) */
94
94
  decimalCount: e(h([t(), c()])),
95
95
  /** Pinned product IDs (empty array when filter-driven) */
96
- productIds: e(n(r())),
96
+ productIds: e(n(i())),
97
97
  /** Whether the block requested live products at send time */
98
98
  sendProductRequestFlag: e(a()),
99
99
  /** Whether to randomize product order */
100
100
  shuffleProducts: e(a()),
101
101
  /** Filter rules driving product selection */
102
- filters: e(n(r())),
102
+ filters: e(n(i())),
103
103
  /** Currency code (e.g. 'EUR') — sometimes absent in legacy data */
104
104
  currency: e(t()),
105
105
  /** Currency display settings (separators, alignment, decimals) */
106
- currencySettings: e(r()),
106
+ currencySettings: e(i()),
107
107
  /** Locale (e.g. 'nl_NL') */
108
108
  language: e(t()),
109
109
  /** Recommendation strategy key (e.g. 'newArrivals') */
110
110
  strategy: e(t()),
111
111
  /** Snapshot of products as rendered by the legacy block */
112
- recommendedProducts: e(n(r())),
112
+ recommendedProducts: e(n(i())),
113
113
  /** Number of product cards per row */
114
114
  cardsInRow: e(c()),
115
115
  /** Mobile-only padding (right) */
@@ -174,7 +174,7 @@ const b = {
174
174
  * mount. Non-numbers still fail, like every other field in this schema.
175
175
  */
176
176
  trackIdCounter: e(
177
- i(
177
+ r(
178
178
  c(),
179
179
  S((s) => Number.isFinite(s) ? Math.max(0, Math.floor(s)) : 0)
180
180
  ),
@@ -188,8 +188,8 @@ const b = {
188
188
  * cannot be undone. Hosts send `[]` for an empty map.
189
189
  */
190
190
  recommendationCampaignUrls: e(
191
- i(
192
- r(),
191
+ r(
192
+ i(),
193
193
  S((s) => s && typeof s == "object" ? { ...s } : void 0)
194
194
  )
195
195
  ),
@@ -249,8 +249,6 @@ const b = {
249
249
  reusableRecommendationStrategy: e(a(), !1),
250
250
  /** Convert linkless legacy unsubscribe blocks into text blocks and warn with a modal (opt-in) */
251
251
  legacyUnsubscribeConversion: e(a(), !1),
252
- /** Disable every save path and the unsaved-changes signal; read at mount only. */
253
- readonly: e(a(), !1),
254
252
  /** Items block: Recommendation-style price formatting (root currency-* attrs, raw price tags). Released dark. */
255
253
  itemsPriceFormatting: e(a(), !1),
256
254
  /** Warn on save when the design carries an Insider unsubscribe link or code (host sets true for SFMC accounts) */
@@ -4,7 +4,7 @@ import r from "../../../_virtual/_plugin-vue2_normalizer.js";
4
4
  var d = function() {
5
5
  var o, s;
6
6
  var i = this, e = i._self._c, t = i._self._setupProxy;
7
- return e("div", { staticClass: "d-f a-i-c editor-actions" }, [!t.editorStore.isPreviewModeOpen && t.hasContentOnTheLeft ? e("div", { staticClass: "editor-actions__divider" }) : i._e(), (s = (o = t.config) == null ? void 0 : o.features) != null && s.testMessage ? e(t.InButtonV2, { attrs: { id: "guido__test-button", "left-icon": "line-architect-test-journey", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isTestButtonDisabled, "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__test-button", { staticPosition: "bottom right" }), "tooltip-text": t.trans("newsletter.test-email") }, on: { click: t.handleTestEmail } }) : i._e(), e(t.EditorActionsMenu), t.editorStore.isPreviewModeOpen ? i._e() : e("div", { staticClass: "editor-actions__divider" }), t.editorStore.isPreviewModeOpen ? i._e() : e(t.InButtonV2, { staticClass: "ml-3", attrs: { id: "guido__save-button", "disabled-status": t.isFeatureEnabled("readonly") || !t.isSaving && t.editorStore.isSaveButtonDisabled, "label-text": t.saveLabel, "loading-status": t.isSaving }, on: { click: function(n) {
7
+ return e("div", { staticClass: "d-f a-i-c editor-actions" }, [!t.editorStore.isPreviewModeOpen && t.hasContentOnTheLeft ? e("div", { staticClass: "editor-actions__divider" }) : i._e(), (s = (o = t.config) == null ? void 0 : o.features) != null && s.testMessage ? e(t.InButtonV2, { attrs: { id: "guido__test-button", "left-icon": "line-architect-test-journey", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isTestButtonDisabled, "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__test-button", { staticPosition: "bottom right" }), "tooltip-text": t.trans("newsletter.test-email") }, on: { click: t.handleTestEmail } }) : i._e(), e(t.EditorActionsMenu), t.editorStore.isPreviewModeOpen ? i._e() : e("div", { staticClass: "editor-actions__divider" }), t.editorStore.isPreviewModeOpen ? i._e() : e(t.InButtonV2, { staticClass: "ml-3", attrs: { id: "guido__save-button", "disabled-status": !t.isSaving && t.editorStore.isSaveButtonDisabled, "label-text": t.saveLabel, "loading-status": t.isSaving }, on: { click: function(n) {
8
8
  return t.handleSave(!1);
9
9
  } } }), e(t.MigrationConfirmModal, { ref: "migrationModalRef", on: { confirm: function(n) {
10
10
  return t.executeSave(!1);
@@ -15,7 +15,7 @@ var d = function() {
15
15
  l,
16
16
  !1,
17
17
  null,
18
- "b3603ae4"
18
+ "9a028d08"
19
19
  );
20
20
  const p = c.exports;
21
21
  export {
@@ -1,101 +1,101 @@
1
- import { useActionsApi as D } from "./useActionsApi.js";
2
- import { useConfig as F } from "./useConfig.js";
3
- import { useEditorLock as I } from "./useEditorLock.js";
4
- import { useSaveStart as N, useSaveComplete as j } from "./useGuidoActions.js";
5
- import { useSaveValidation as z } from "./useSaveValidation.js";
6
- import { useSaveValidationRollout as G } from "./useSaveValidationRollout.js";
7
- import { useSyncModuleExtractor as J } from "./useSyncModuleExtractor.js";
8
- import { ToasterTypeOptions as K } from "../enums/toaster.js";
9
- import { useStripoApi as Q } from "../services/stripoApi.js";
10
- import { useConfigStore as X } from "../stores/config.js";
11
- import { useDynamicContentStore as Y } from "../stores/dynamic-content.js";
12
- import { useSaveValidationStore as Z } from "../stores/save-validation.js";
13
- import { useTemplatePreparation as _, getHtmlReferencedUnsubscribePages as $ } from "../utils/templatePreparation.js";
14
- import { useAllowlist as ee } from "./useAllowlist.js";
15
- import { useHtmlValidator as te } from "./useHtmlValidator.js";
16
- import { useToaster as oe } from "./useToaster.js";
17
- import { useCouponBlockValidator as ie } from "./validators/useCouponBlockValidator.js";
18
- import { useHtmlDocumentCountValidator as se } from "./validators/useHtmlDocumentCountValidator.js";
19
- import { useLiquidValidator as re } from "./validators/useLiquidValidator.js";
20
- import { useSyncModuleBlockValidator as ae } from "./validators/useSyncModuleBlockValidator.js";
21
- import { useUnsubscribeBlockValidator as ne } from "./validators/useUnsubscribeBlockValidator.js";
22
- const Ue = () => {
23
- const l = N(), S = j(), { validateHtml: b } = te(), { validateLiquidSyntax: H } = re(), { validateCouponBlockTags: E } = ie(), {
24
- validateUnsubscribeBlockUniqueness: g,
25
- validateUnsubscribeBlockHasTemplate: V,
26
- validateNoInsiderUnsubscribeCode: x
27
- } = ne(), { validateSyncModuleBlocks: c } = ae(), { validateSingleHtmlDocument: u } = se(), { callbacks: a, isFeatureEnabled: n } = F(), { extractSyncModuleData: k } = J(), { setSyncModuleUnsubscriptionPages: C } = Q(), { editorSave: h, getTemplateData: d } = D(), { showToaster: B } = oe(), { getBlockedDomains: P, resolveToast: T } = ee(), { prepareTemplateDetails: w } = _(), { collectSaveValidationErrors: L } = z(), { isEnabled: U } = G(), A = Z(), M = Y(), y = X(), { runExclusive: m } = I(), f = async (e, t, i) => {
28
- if (!n("allowlistEnabled"))
1
+ import { useActionsApi as O } from "./useActionsApi.js";
2
+ import { useConfig as D } from "./useConfig.js";
3
+ import { useEditorLock as F } from "./useEditorLock.js";
4
+ import { useSaveStart as I, useSaveComplete as N } from "./useGuidoActions.js";
5
+ import { useSaveValidation as j } from "./useSaveValidation.js";
6
+ import { useSaveValidationRollout as z } from "./useSaveValidationRollout.js";
7
+ import { useSyncModuleExtractor as G } from "./useSyncModuleExtractor.js";
8
+ import { ToasterTypeOptions as J } from "../enums/toaster.js";
9
+ import { useStripoApi as K } from "../services/stripoApi.js";
10
+ import { useConfigStore as Q } from "../stores/config.js";
11
+ import { useDynamicContentStore as X } from "../stores/dynamic-content.js";
12
+ import { useSaveValidationStore as Y } from "../stores/save-validation.js";
13
+ import { useTemplatePreparation as Z, getHtmlReferencedUnsubscribePages as _ } from "../utils/templatePreparation.js";
14
+ import { useAllowlist as $ } from "./useAllowlist.js";
15
+ import { useHtmlValidator as tt } from "./useHtmlValidator.js";
16
+ import { useToaster as et } from "./useToaster.js";
17
+ import { useCouponBlockValidator as ot } from "./validators/useCouponBlockValidator.js";
18
+ import { useHtmlDocumentCountValidator as it } from "./validators/useHtmlDocumentCountValidator.js";
19
+ import { useLiquidValidator as rt } from "./validators/useLiquidValidator.js";
20
+ import { useSyncModuleBlockValidator as st } from "./validators/useSyncModuleBlockValidator.js";
21
+ import { useUnsubscribeBlockValidator as at } from "./validators/useUnsubscribeBlockValidator.js";
22
+ const Pt = () => {
23
+ const n = I(), S = N(), { validateHtml: y } = tt(), { validateLiquidSyntax: b } = rt(), { validateCouponBlockTags: H } = ot(), {
24
+ validateUnsubscribeBlockUniqueness: E,
25
+ validateUnsubscribeBlockHasTemplate: g,
26
+ validateNoInsiderUnsubscribeCode: V
27
+ } = at(), { validateSyncModuleBlocks: l } = st(), { validateSingleHtmlDocument: c } = it(), { callbacks: a, isFeatureEnabled: u } = D(), { extractSyncModuleData: x } = G(), { setSyncModuleUnsubscriptionPages: k } = K(), { editorSave: C, getTemplateData: m } = O(), { showToaster: h } = et(), { getBlockedDomains: B, resolveToast: T } = $(), { prepareTemplateDetails: p } = Z(), { collectSaveValidationErrors: L } = j(), { isEnabled: P } = z(), U = Y(), A = X(), w = Q(), { runExclusive: d } = F(), f = async (t, e, i) => {
28
+ if (!u("allowlistEnabled"))
29
29
  return !1;
30
- const o = await P(e, t);
30
+ const o = await B(t, e);
31
31
  if (!o.length)
32
32
  return !1;
33
33
  if (!i) {
34
- const s = await T(o);
35
- s != null && s.message && B({
36
- type: K.Warning,
37
- message: s.message,
38
- actionButton: s.actionButton
34
+ const r = await T(o);
35
+ r != null && r.message && h({
36
+ type: J.Warning,
37
+ message: r.message,
38
+ actionButton: r.actionButton
39
39
  });
40
40
  }
41
41
  return !0;
42
- }, R = async (e, t) => !E(e.compiledHtml) || n("blockUnsubscribeLinks") && !x(e.rawHtml, t) || !g(e.compiledHtml) || !V(e.compiledHtml) ? !1 : n("liquidSyntax") ? H(e.compiledHtml) : b(e.compiledHtml, e.dynamicContentList, !0), v = async (e, t) => {
43
- if (!await h())
42
+ }, M = async (t, e) => !H(t.compiledHtml) || u("blockUnsubscribeLinks") && !V(t.rawHtml, e) || !E(t.compiledHtml) || !g(t.compiledHtml) ? !1 : u("liquidSyntax") ? b(t.compiledHtml) : y(t.compiledHtml, t.dynamicContentList, !0), v = async (t, e) => {
43
+ if (!await C())
44
44
  return;
45
- const { unsubscribePayload: o, stripoModules: s } = k(e.rawHtml);
46
- if (await C(o), e.modules = s, !t.suppress) {
47
- const r = t.blankCompiled ? { compiledHtml: "", ampHtml: "" } : {};
48
- S({ ...e, ...r, silent: t.silent });
45
+ const { unsubscribePayload: o, stripoModules: r } = x(t.rawHtml);
46
+ if (await k(o), t.modules = r, !e.suppress) {
47
+ const s = e.blankCompiled ? { compiledHtml: "", ampHtml: "" } : {};
48
+ S({ ...t, ...s, silent: e.silent });
49
49
  }
50
- return e;
51
- }, W = async (e, t) => {
52
- var s;
53
- l();
54
- const i = await d();
55
- if (!u(i.html, t))
50
+ return t;
51
+ }, W = async (t, e) => {
52
+ var r;
53
+ n();
54
+ const i = await m();
55
+ if (!c(i.html, e))
56
56
  return;
57
- const o = await w(i);
58
- if (c(o.rawHtml, t)) {
59
- if (U.value && !t) {
60
- const r = await L(
57
+ const o = await p(i);
58
+ if (l(o.rawHtml, e)) {
59
+ if (P.value && !e) {
60
+ const s = await L(
61
61
  o.compiledHtml,
62
62
  o.dynamicContentList,
63
63
  o.rawHtml
64
64
  );
65
- if (!r)
65
+ if (!s)
66
66
  return;
67
- if (r.length) {
68
- A.open(r, "save");
67
+ if (s.length) {
68
+ U.open(s, "save");
69
69
  return;
70
70
  }
71
- } else if (!await R(o, t))
71
+ } else if (!await M(o, e))
72
72
  return;
73
- if (!((s = a.value) != null && s.externalValidation && !await a.value.externalValidation(o)) && !await f(o.compiledHtml, o.css, t))
74
- return v(o, { silent: t, suppress: e });
73
+ if (!((r = a.value) != null && r.externalValidation && !await a.value.externalValidation(o)) && !await f(o.compiledHtml, o.css, e))
74
+ return v(o, { silent: e, suppress: t });
75
75
  }
76
- }, q = async () => {
76
+ }, R = async () => {
77
77
  var i;
78
- if (!y.allowSaveWithErrors)
78
+ if (!w.allowSaveWithErrors)
79
79
  return;
80
- l();
81
- const e = await d();
82
- if (!u(e.html, !1))
80
+ n();
81
+ const t = await m();
82
+ if (!c(t.html, !1))
83
83
  return;
84
- const t = await w(e);
85
- if (c(t.rawHtml, !1) && !((i = a.value) != null && i.externalValidation && !await a.value.externalValidation(t)) && !await f(t.compiledHtml, t.css, !1))
86
- return v(t, { silent: !1, blankCompiled: !0 });
87
- }, O = async () => {
88
- if (!y.allowSaveWithErrors)
84
+ const e = await p(t);
85
+ if (l(e.rawHtml, !1) && !((i = a.value) != null && i.externalValidation && !await a.value.externalValidation(e)) && !await f(e.compiledHtml, e.css, !1))
86
+ return v(e, { silent: !1, blankCompiled: !0 });
87
+ }, q = async () => {
88
+ if (!w.allowSaveWithErrors)
89
89
  return;
90
- l();
91
- const { html: e, css: t } = await d();
92
- if (!u(e, !0) || !c(e, !0) || await f(e, t, !0))
90
+ n();
91
+ const { html: t, css: e } = await m();
92
+ if (!c(t, !0) || !l(t, !0) || await f(t, e, !0))
93
93
  return;
94
- const i = $(e), o = {
95
- dynamicContentList: M.getSelectedDynamicContentList,
94
+ const i = _(t), o = {
95
+ dynamicContentList: A.getSelectedDynamicContentList,
96
96
  compiledHtml: "",
97
- rawHtml: e,
98
- css: t,
97
+ rawHtml: t,
98
+ css: e,
99
99
  ampHtml: "",
100
100
  ampErrors: [],
101
101
  modules: [],
@@ -107,9 +107,11 @@ const Ue = () => {
107
107
  }
108
108
  };
109
109
  return v(o, { silent: !0 });
110
- }, p = () => n("readonly");
111
- return { save: (e = !1, t = !1) => p() ? Promise.resolve(void 0) : m(() => W(e, t)), saveWithErrors: () => p() ? Promise.resolve(void 0) : m(q), saveRawOnly: () => p() ? Promise.resolve(void 0) : m(O) };
110
+ };
111
+ return { save: (t = !1, e = !1) => d(
112
+ () => W(t, e)
113
+ ), saveWithErrors: () => d(R), saveRawOnly: () => d(q) };
112
114
  };
113
115
  export {
114
- Ue as useSave
116
+ Pt as useSave
115
117
  };
@@ -18,37 +18,37 @@ import { buildMergeTagEntries as oe, flattenDynamicContentList as re } from "../
18
18
  import { getStripoRuntimeBaseUrl as ie } from "../utils/stripoRuntime.js";
19
19
  let d = null, F = !1;
20
20
  const ve = (t) => {
21
- const { features: m, template: p, isFeatureEnabled: c } = G(), { handleError: f, showToaster: A } = W(), { getToken: P, getCustomFonts: R, getSyncModulesStatus: D } = ee(), { handleEvent: U } = K(), { handleModuleAdd: V } = J(), { restorePending: I } = z(), { getStripoBlocksConfig: L } = $(), { getStripoNotifications: q } = Q(), g = () => d || (d = new Promise((n, a) => {
21
+ const { features: u, template: m, isFeatureEnabled: p } = G(), { handleError: f, showToaster: A } = W(), { getToken: P, getCustomFonts: R, getSyncModulesStatus: D } = ee(), { handleEvent: U } = K(), { handleModuleAdd: V } = J(), { restorePending: I } = z(), { getStripoBlocksConfig: L } = $(), { getStripoNotifications: q } = Q(), g = () => d || (d = new Promise((n, s) => {
22
22
  if (document.getElementById("UiEditorScript")) {
23
23
  n();
24
24
  return;
25
25
  }
26
26
  const i = ie();
27
27
  if (!i) {
28
- a(
28
+ s(
29
29
  new Error("guido.stripo.version is not set in package.json. Please configure the Stripo version.")
30
30
  );
31
31
  return;
32
32
  }
33
- const s = `${i}UIEditor.js`, e = document.createElement("script");
34
- e.id = "UiEditorScript", e.type = "module", e.src = s, e.onload = () => {
33
+ const a = `${i}UIEditor.js`, e = document.createElement("script");
34
+ e.id = "UiEditorScript", e.type = "module", e.src = a, e.onload = () => {
35
35
  F = !0, n();
36
36
  }, e.onerror = () => {
37
- e.remove(), a(new Error(`Failed to load Stripo UIEditor script from S3: ${s}`));
37
+ e.remove(), s(new Error(`Failed to load Stripo UIEditor script from S3: ${a}`));
38
38
  }, document.body.appendChild(e);
39
39
  }), d.catch(() => {
40
40
  d = null;
41
- }), d), x = async (n, a, i, s = [], e = !1, u = !1) => {
41
+ }), d), x = async (n, s, i, a = [], e = !1, c = !1) => {
42
42
  var w, k, b, _;
43
- const o = T(), { html: y, css: S } = n, { baseBlocks: E, extensions: O } = await L();
43
+ const o = T(), { html: S, css: y } = n, { baseBlocks: E, extensions: O } = await L();
44
44
  t.mark("blocks_config_ready");
45
- const h = ((w = m.value) == null ? void 0 : w.displayConditions) ?? !0, H = ((k = m.value) == null ? void 0 : k.modulesDisabled) ?? !1, C = u || (((b = p.value) == null ? void 0 : b.forceRecreate) ?? !1), M = "https://email-static.useinsider.com https://edge.fullstory.com https://rs.fullstory.com";
46
- t.setTemplate({ html: y, css: S, forceRecreate: C }), v().importCss(), t.mark("init_editor"), await window.UIEditor.initEditor(
45
+ const h = ((w = u.value) == null ? void 0 : w.displayConditions) ?? !0, H = ((k = u.value) == null ? void 0 : k.modulesDisabled) ?? !1, C = c || (((b = m.value) == null ? void 0 : b.forceRecreate) ?? !1), M = "https://email-static.useinsider.com https://edge.fullstory.com https://rs.fullstory.com";
46
+ t.setTemplate({ html: S, css: y, forceRecreate: C }), v().importCss(), t.mark("init_editor"), await window.UIEditor.initEditor(
47
47
  document.querySelector("#guido-editor"),
48
48
  {
49
- metadata: a,
50
- html: y,
51
- css: S,
49
+ metadata: s,
50
+ html: S,
51
+ css: y,
52
52
  forceRecreate: C,
53
53
  locale: "en",
54
54
  undoButtonSelector: "#guido__undo-button",
@@ -56,7 +56,7 @@ const ve = (t) => {
56
56
  mobileViewButtonSelector: ".guido__view-option-selection-mobile",
57
57
  desktopViewButtonSelector: ".guido__view-option-selection-desktop",
58
58
  codeEditorButtonSelector: "#guido__code-button",
59
- customAppearanceMergetags: !c("liquidSyntax"),
59
+ customAppearanceMergetags: !p("liquidSyntax"),
60
60
  customAppearanceMergetagsBorderColor: "#f1f3fe",
61
61
  customAppearanceMergetagsBackgroundColor: "#f1f3fe",
62
62
  customViewStyles: te,
@@ -79,14 +79,14 @@ const ve = (t) => {
79
79
  editorFonts: {
80
80
  showDefaultStandardFonts: !0,
81
81
  showDefaultNotStandardFonts: !0,
82
- customFonts: s
82
+ customFonts: a
83
83
  },
84
84
  mergeTags: [
85
85
  {
86
86
  entries: oe(
87
87
  i.preselectedDynamicContentList,
88
- re((_ = p.value) == null ? void 0 : _.dynamicContentList),
89
- c("liquidSyntax")
88
+ re((_ = m.value) == null ? void 0 : _.dynamicContentList),
89
+ p("liquidSyntax")
90
90
  )
91
91
  }
92
92
  ],
@@ -119,7 +119,7 @@ const ve = (t) => {
119
119
  o.isVersionHistoryOpen = r;
120
120
  },
121
121
  onDataChanged() {
122
- c("readonly") || (o.hasChanges = !0), o.changeSeq += 1;
122
+ o.hasChanges = !0, o.changeSeq += 1;
123
123
  },
124
124
  onEvent: U,
125
125
  onModuleAdd: V,
@@ -138,15 +138,15 @@ const ve = (t) => {
138
138
  }
139
139
  );
140
140
  };
141
- return { initPlugin: async (n, a, i, s = !1) => {
141
+ return { initPlugin: async (n, s, i, a = !1) => {
142
142
  const e = T();
143
143
  try {
144
144
  t.mark("plugin_start"), t.setScriptPreloaded(F), await g(), t.mark("script_ready");
145
- const [u, o] = await Promise.all([
145
+ const [c, o] = await Promise.all([
146
146
  R(),
147
147
  D()
148
148
  ]);
149
- t.mark("fonts_sync_ready"), e.syncModulesEnabled = o, await x(n, a, i, u, o, s);
149
+ t.mark("fonts_sync_ready"), e.syncModulesEnabled = o, await x(n, s, i, c, o, a);
150
150
  } catch {
151
151
  e.loadingStatus = !1, A({
152
152
  type: Z.Error,