@useinsider/guido 3.19.0-beta.4b9be3a → 3.19.0-beta.575d19c

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 (120) hide show
  1. package/README.md +21 -3
  2. package/dist/@types/config/schemas.js +76 -67
  3. package/dist/components/Guido.vue.js +6 -6
  4. package/dist/components/Guido.vue2.js +94 -91
  5. package/dist/components/organisms/AutoSaveController.vue2.js +18 -8
  6. package/dist/components/organisms/base/Toaster.vue2.js +13 -12
  7. package/dist/components/organisms/extensions/recommendation/AssignStrategyDrawer.vue.js +13 -11
  8. package/dist/components/organisms/extensions/recommendation/AssignStrategyDrawer.vue2.js +78 -57
  9. package/dist/components/organisms/extensions/recommendation/LegacyStrategyUpdatedModal.vue.js +18 -0
  10. package/dist/components/organisms/extensions/recommendation/LegacyStrategyUpdatedModal.vue2.js +25 -0
  11. package/dist/components/organisms/extensions/recommendation/RemoveStrategyModal.vue2.js +28 -42
  12. package/dist/components/organisms/header/AutoSaveStatus.vue.js +17 -0
  13. package/dist/components/organisms/header/AutoSaveStatus.vue2.js +25 -0
  14. package/dist/components/organisms/header/EditorActions.vue.js +13 -13
  15. package/dist/components/organisms/header/EditorActions.vue2.js +35 -53
  16. package/dist/components/organisms/header/EditorActionsMenu.vue.js +20 -0
  17. package/dist/components/organisms/header/EditorActionsMenu.vue2.js +98 -0
  18. package/dist/components/organisms/header/HeaderWrapper.vue.js +6 -6
  19. package/dist/components/organisms/header/HeaderWrapper.vue2.js +9 -17
  20. package/dist/components/organisms/header/LeftSlot.vue.js +5 -5
  21. package/dist/components/organisms/header/LeftSlot.vue2.js +32 -23
  22. package/dist/components/organisms/header/MiddleSlot.vue.js +4 -4
  23. package/dist/components/organisms/header/MiddleSlot.vue2.js +8 -7
  24. package/dist/components/organisms/header/RightSlot.vue.js +9 -8
  25. package/dist/components/organisms/header/RightSlot.vue2.js +13 -18
  26. package/dist/components/organisms/header/accessibility/AccessibilityToolbar.vue.js +18 -0
  27. package/dist/components/organisms/header/accessibility/AccessibilityToolbar.vue2.js +37 -0
  28. package/dist/components/organisms/header/accessibility/ColorVisionSelect.vue.js +22 -0
  29. package/dist/components/organisms/header/accessibility/ColorVisionSelect.vue2.js +48 -0
  30. package/dist/components/organisms/onboarding/EditorTabBarOnboarding.vue.js +19 -0
  31. package/dist/components/organisms/onboarding/EditorTabBarOnboarding.vue2.js +90 -0
  32. package/dist/components/organisms/onboarding/OnboardingWrapper.vue.js +12 -12
  33. package/dist/components/organisms/onboarding/OnboardingWrapper.vue2.js +56 -34
  34. package/dist/components/organisms/onboarding/RecommendationLegacyStrategyOnboarding.vue.js +21 -0
  35. package/dist/components/organisms/onboarding/RecommendationLegacyStrategyOnboarding.vue2.js +46 -0
  36. package/dist/components/organisms/onboarding/RecommendationStrategyOnboarding.vue.js +21 -0
  37. package/dist/components/organisms/onboarding/RecommendationStrategyOnboarding.vue2.js +47 -0
  38. package/dist/composables/useAccessibilityApi.js +45 -0
  39. package/dist/composables/useActionsApi.js +44 -43
  40. package/dist/composables/useCodeEditorApi.js +23 -9
  41. package/dist/composables/useCortexBlueprintBridge.js +54 -120
  42. package/dist/composables/useCustomInterfaceAppearance.js +67 -52
  43. package/dist/composables/useEmailTemplateApplier.js +51 -96
  44. package/dist/composables/useHtmlValidator.js +87 -82
  45. package/dist/composables/useLegacyStrategyConversion.js +61 -0
  46. package/dist/composables/useRecommendation.js +40 -35
  47. package/dist/composables/useStripo.js +30 -30
  48. package/dist/composables/useToaster.js +14 -20
  49. package/dist/composables/useTranslations.js +3 -2
  50. package/dist/composables/useVersionHistoryApi.js +33 -24
  51. package/dist/config/i18n/en/labels.json.js +36 -4
  52. package/dist/config/i18n/en/tooltips.json.js +2 -1
  53. package/dist/enums/extensions/recommendationBlock.js +49 -33
  54. package/dist/extensions/Blocks/Recommendation/block.js +61 -42
  55. package/dist/extensions/Blocks/Recommendation/constants/defaultConfig.js +21 -20
  56. package/dist/extensions/Blocks/Recommendation/controls/main/index.js +100 -94
  57. package/dist/extensions/Blocks/Recommendation/controls/main/strategy.js +130 -55
  58. package/dist/extensions/Blocks/Recommendation/controls/main/utils.js +74 -74
  59. package/dist/extensions/Blocks/Recommendation/store/recommendation.js +273 -92
  60. package/dist/extensions/Blocks/Recommendation/utils/legacyStrategyMigration.js +42 -0
  61. package/dist/extensions/Blocks/Recommendation/utils/nodeConfigWriter.js +26 -16
  62. package/dist/extensions/Blocks/Recommendation/utils/strategyCommit.js +24 -0
  63. package/dist/extensions/Blocks/Recommendation/validation/requiredFields.js +21 -12
  64. package/dist/guido.css +1 -1
  65. package/dist/services/recommendationApi.js +46 -37
  66. package/dist/sprite.svg +6 -0
  67. package/dist/src/@types/config/schemas.d.ts +18 -0
  68. package/dist/src/components/organisms/AutoSaveController.vue.d.ts +3 -1
  69. package/dist/src/components/organisms/header/AutoSaveStatus.vue.d.ts +2 -0
  70. package/dist/src/components/organisms/header/EditorActionsMenu.vue.d.ts +2 -0
  71. package/dist/src/components/organisms/header/HeaderWrapper.vue.d.ts +1 -3
  72. package/dist/src/components/organisms/header/RightSlot.vue.d.ts +1 -3
  73. package/dist/src/components/organisms/header/accessibility/AccessibilityToolbar.vue.d.ts +2 -0
  74. package/dist/src/components/organisms/header/accessibility/ColorVisionSelect.vue.d.ts +2 -0
  75. package/dist/src/components/organisms/onboarding/EditorTabBarOnboarding.vue.d.ts +2 -0
  76. package/dist/src/components/organisms/onboarding/RecommendationLegacyStrategyOnboarding.vue.d.ts +2 -0
  77. package/dist/src/components/organisms/onboarding/RecommendationStrategyOnboarding.vue.d.ts +2 -0
  78. package/dist/src/composables/useAccessibilityApi.d.ts +13 -0
  79. package/dist/src/composables/useActionsApi.d.ts +2 -2
  80. package/dist/src/composables/useConfig.d.ts +6 -0
  81. package/dist/src/composables/useCortexBlueprintBridge.d.ts +3 -4
  82. package/dist/src/composables/useEmailTemplateApplier.d.ts +5 -26
  83. package/dist/src/composables/useLegacyStrategyConversion.d.ts +3 -0
  84. package/dist/src/enums/extensions/recommendationBlock.d.ts +7 -1
  85. package/dist/src/extensions/Blocks/Recommendation/block.d.ts +10 -0
  86. package/dist/src/extensions/Blocks/Recommendation/constants/defaultConfig.d.ts +1 -0
  87. package/dist/src/extensions/Blocks/Recommendation/constants/index.d.ts +1 -1
  88. package/dist/src/extensions/Blocks/Recommendation/controls/main/index.d.ts +2 -0
  89. package/dist/src/extensions/Blocks/Recommendation/controls/main/strategy.d.ts +10 -0
  90. package/dist/src/extensions/Blocks/Recommendation/controls/main/utils.d.ts +7 -2
  91. package/dist/src/extensions/Blocks/Recommendation/store/recommendation.d.ts +162 -1
  92. package/dist/src/extensions/Blocks/Recommendation/utils/legacyStrategyMigration.d.ts +32 -0
  93. package/dist/src/extensions/Blocks/Recommendation/utils/strategyCommit.d.ts +14 -0
  94. package/dist/src/extensions/Blocks/Recommendation/validation/requiredFields.d.ts +4 -0
  95. package/dist/src/services/recommendationApi.d.ts +2 -1
  96. package/dist/src/stores/config.d.ts +342 -0
  97. package/dist/src/stores/editor.d.ts +109 -0
  98. package/dist/src/stores/guido-email-editor.d.ts +10 -32
  99. package/dist/src/stores/onboarding.d.ts +1865 -136
  100. package/dist/src/stores/version-history.d.ts +1 -1
  101. package/dist/src/utils/stripoEditorApi.d.ts +4 -0
  102. package/dist/src/utils/timeUtil.d.ts +5 -0
  103. package/dist/static/assets/icons/filled-arrow-rising.svg.js +5 -0
  104. package/dist/static/assets/icons/line-info.svg.js +5 -0
  105. package/dist/static/styles/components/accessibility.css.js +234 -0
  106. package/dist/static/styles/components/recommendation-strategy.css.js +104 -9
  107. package/dist/static/styles/components/skeleton.css.js +23 -0
  108. package/dist/static/styles/variables.css.js +2 -0
  109. package/dist/stores/config.js +74 -60
  110. package/dist/stores/editor.js +7 -4
  111. package/dist/stores/guido-email-editor.js +1 -3
  112. package/dist/stores/onboarding.js +79 -47
  113. package/dist/stores/unsubscribe.js +3 -3
  114. package/dist/utils/stripoEditorApi.js +11 -0
  115. package/dist/utils/templatePreparation.js +55 -55
  116. package/dist/utils/timeUtil.js +6 -17
  117. package/package.json +1 -1
  118. package/dist/components/organisms/header/AutoSaveToggle.vue.js +0 -22
  119. package/dist/components/organisms/header/AutoSaveToggle.vue2.js +0 -19
  120. /package/dist/src/components/organisms/{header/AutoSaveToggle.vue.d.ts → extensions/recommendation/LegacyStrategyUpdatedModal.vue.d.ts} +0 -0
@@ -1,23 +1,23 @@
1
- import { useActionsApi as x } from "./useActionsApi.js";
2
- import { useBlocksConfig as L } from "./useBlocksConfig.js";
3
- import { useConfig as O } from "./useConfig.js";
4
- import { useCustomInterfaceAppearance as H } from "./useCustomInterfaceAppearance.js";
1
+ import { useActionsApi as L } from "./useActionsApi.js";
2
+ import { useBlocksConfig as O } from "./useBlocksConfig.js";
3
+ import { useConfig as H } from "./useConfig.js";
4
+ import { useCustomInterfaceAppearance as w } from "./useCustomInterfaceAppearance.js";
5
5
  import { useFullStoryBridge as N } from "./useFullStoryBridge.js";
6
6
  import { useModuleRepair as j } from "./useModuleRepair.js";
7
7
  import { useStripoEventHandler as z } from "./useStripoEventHandler.js";
8
8
  import { useStripoNotifications as $ } from "./useStripoNotifications.js";
9
9
  import { useToaster as G } from "./useToaster.js";
10
10
  import { localePatch as J } from "../config/i18n/index.js";
11
- import { en as w } from "../config/i18n/en/index.js";
11
+ import { en as b } from "../config/i18n/en/index.js";
12
12
  import { ToasterTypeOptions as X } from "../enums/toaster.js";
13
13
  import { useStripoApi as K } from "../services/stripoApi.js";
14
14
  import Q from "../static/styles/customEditorStyle.css.js";
15
- import { useEditorStore as b } from "../stores/editor.js";
15
+ import { useEditorStore as k } from "../stores/editor.js";
16
16
  import { buildMergeTagEntries as W, flattenDynamicContentList as Y } from "../utils/genericUtil.js";
17
17
  import Z from "../package.json.js";
18
18
  let n = null;
19
- const Ce = () => {
20
- const { features: c, template: u, isFeatureEnabled: m } = O(), { handleError: p, showToaster: k } = G(), { getToken: B, getCustomFonts: M, getSyncModulesStatus: T } = K(), { handleEvent: v } = z(), { handleModuleAdd: F } = j(), { getStripoBlocksConfig: A } = L(), { getStripoNotifications: V } = $(), f = () => n || (n = new Promise((i, s) => {
19
+ const he = () => {
20
+ const { features: c, template: u, isFeatureEnabled: m } = H(), { handleError: p, showToaster: B } = G(), { getToken: M, getCustomFonts: T, getSyncModulesStatus: v } = K(), { handleEvent: F } = z(), { handleModuleAdd: A } = j(), { getStripoBlocksConfig: V } = O(), { getStripoNotifications: _ } = $(), f = () => n || (n = new Promise((i, s) => {
21
21
  var d;
22
22
  if (document.getElementById("UiEditorScript")) {
23
23
  i();
@@ -29,16 +29,16 @@ const Ce = () => {
29
29
  }, document.body.appendChild(e);
30
30
  }), n.catch(() => {
31
31
  n = null;
32
- }), n), _ = async (i, s, o, a = [], r = !1) => {
32
+ }), n), D = async (i, s, o, a = [], r = !1) => {
33
33
  var y, E, h, C;
34
- const e = b(), { html: d, css: D } = i, { baseBlocks: g, extensions: R } = await A(), S = ((y = c.value) == null ? void 0 : y.displayConditions) ?? !0, P = ((E = c.value) == null ? void 0 : E.modulesDisabled) ?? !1, U = !!d || (((h = u.value) == null ? void 0 : h.forceRecreate) ?? !1);
35
- await window.UIEditor.initEditor(
34
+ const e = k(), { html: d, css: R } = i, { baseBlocks: g, extensions: P } = await V(), S = ((y = c.value) == null ? void 0 : y.displayConditions) ?? !0, U = ((E = c.value) == null ? void 0 : E.modulesDisabled) ?? !1, I = !!d || (((h = u.value) == null ? void 0 : h.forceRecreate) ?? !1), q = "https://email-static.useinsider.com https://edge.fullstory.com https://rs.fullstory.com";
35
+ w().importCss(), await window.UIEditor.initEditor(
36
36
  document.querySelector("#guido-editor"),
37
37
  {
38
38
  metadata: s,
39
39
  html: d,
40
- css: D,
41
- forceRecreate: U,
40
+ css: R,
41
+ forceRecreate: I,
42
42
  locale: "en",
43
43
  undoButtonSelector: "#guido__undo-button",
44
44
  redoButtonSelector: "#guido__redo-button",
@@ -52,7 +52,7 @@ const Ce = () => {
52
52
  conditionsEnabled: S,
53
53
  customConditionsEnabled: S,
54
54
  enableXSSSecurity: !0,
55
- modulesDisabled: P,
55
+ modulesDisabled: U,
56
56
  syncModulesEnabled: r,
57
57
  messageSettingsEnabled: !0,
58
58
  displayGmailAnnotations: !0,
@@ -62,7 +62,7 @@ const Ce = () => {
62
62
  displayUTM: !1,
63
63
  selectElementAfterDrop: !0,
64
64
  sameFontSizeForOutlook: !0,
65
- allowedScriptSourceDomains: "https://email-static.useinsider.com https://edge.fullstory.com https://rs.fullstory.com",
65
+ allowedScriptSourceDomains: q,
66
66
  ...g ? { baseBlocks: g } : {},
67
67
  editorFonts: {
68
68
  showDefaultStandardFonts: !0,
@@ -80,7 +80,7 @@ const Ce = () => {
80
80
  ],
81
81
  async onTokenRefreshRequest(t) {
82
82
  try {
83
- const l = await B();
83
+ const l = await M();
84
84
  t(l);
85
85
  } catch (l) {
86
86
  p(l, "Failed to refresh token");
@@ -88,8 +88,8 @@ const Ce = () => {
88
88
  },
89
89
  onTemplateLoaded() {
90
90
  try {
91
- const { importCss: t } = H(), { activateCustomViewStyles: l, updateTimerInClonedTemplate: I } = x(), { injectFullStory: q } = N();
92
- t(), l(), q(), I(), o.onReady(), e.isStripoInitialized = !0, e.loadingStatus = !1, setTimeout(() => {
91
+ const { activateCustomViewStyles: t, updateTimerInClonedTemplate: l } = L(), { injectFullStory: x } = N();
92
+ w().importCss(), t(), x(), l(), o.onReady(), e.isStripoInitialized = !0, e.loadingStatus = !1, setTimeout(() => {
93
93
  e.hasChanges = !1;
94
94
  }, 1e3);
95
95
  } catch (t) {
@@ -108,34 +108,34 @@ const Ce = () => {
108
108
  onDataChanged() {
109
109
  e.hasChanges = !0, e.changeSeq += 1;
110
110
  },
111
- onEvent: v,
112
- onModuleAdd: F,
113
- notifications: V(),
111
+ onEvent: F,
112
+ onModuleAdd: A,
113
+ notifications: _(),
114
114
  ignoreClickOutsideSelectors: [
115
115
  "#guido-dynamic-content-modal",
116
116
  ".in-on-board-wrapper",
117
117
  ".in-drawer__container"
118
118
  ],
119
- extensions: R,
119
+ extensions: P,
120
120
  localePatch: J
121
121
  }
122
122
  );
123
123
  };
124
124
  return { initPlugin: async (i, s, o) => {
125
- const a = b();
125
+ const a = k();
126
126
  try {
127
127
  await f();
128
128
  const [r, e] = await Promise.all([
129
- M(),
130
- T()
129
+ T(),
130
+ v()
131
131
  ]);
132
- a.syncModulesEnabled = e, await _(i, s, o, r, e);
132
+ a.syncModulesEnabled = e, await D(i, s, o, r, e);
133
133
  } catch {
134
- a.loadingStatus = !1, k({
134
+ a.loadingStatus = !1, B({
135
135
  type: X.Error,
136
- message: w["An error has occurred. Please report the error code to support."],
136
+ message: b["An error has occurred. Please report the error code to support."],
137
137
  actionButton: {
138
- text: w["Reload page"],
138
+ text: b["Reload page"],
139
139
  onClick: () => window.location.reload()
140
140
  }
141
141
  });
@@ -146,5 +146,5 @@ const Ce = () => {
146
146
  } };
147
147
  };
148
148
  export {
149
- Ce as useStripo
149
+ he as useStripo
150
150
  };
@@ -1,32 +1,26 @@
1
1
  import { ToasterTypeOptions as T } from "../enums/toaster.js";
2
2
  import { useToasterStore as c } from "../stores/toaster.js";
3
- import { watch as u, nextTick as f } from "vue";
4
- const p = () => {
5
- const o = c();
6
- let t = null;
7
- const s = () => {
8
- t && (clearTimeout(t), t = null);
3
+ import { nextTick as u } from "vue";
4
+ const s = /* @__PURE__ */ new WeakMap(), p = () => {
5
+ const e = c(), o = () => {
6
+ const t = s.get(e);
7
+ t && (clearTimeout(t), s.delete(e));
9
8
  };
10
- function r(e = { message: "" }) {
11
- s(), o.hideToaster(), f(() => {
12
- o.showToaster(e);
9
+ function r(t = { message: "" }) {
10
+ o(), e.hideToaster(), u(() => {
11
+ e.showToaster(t), e.shouldAutoHide && s.set(e, setTimeout(() => {
12
+ e.hideToaster(), o();
13
+ }, 6e3));
13
14
  });
14
15
  }
15
16
  function i() {
16
- s(), o.hideToaster();
17
+ o(), e.hideToaster();
17
18
  }
18
- function n(e, a) {
19
- const m = e instanceof Error ? e.message : String(e);
19
+ function n(t, a) {
20
+ const m = t instanceof Error ? t.message : String(t);
20
21
  r({ type: T.Error, message: `${a}: ${m}` });
21
22
  }
22
- return u(
23
- () => o.shouldAutoHide,
24
- (e) => {
25
- s(), e && (t = setTimeout(() => {
26
- o.hideToaster(), s();
27
- }, 6e3));
28
- }
29
- ), { showToaster: r, hideToaster: i, handleError: n };
23
+ return { showToaster: r, hideToaster: i, handleError: n };
30
24
  };
31
25
  export {
32
26
  p as useToaster
@@ -6,9 +6,10 @@ import { useConfig } from "./useConfig.js";
6
6
  const useTranslations = () => {
7
7
  var o, e;
8
8
  const { config } = useConfig(), translationsPath = ((e = (o = config.value) == null ? void 0 : o.editor) == null ? void 0 : e.translationsPath) || DEFAULT_EDITOR.translationsPath, translations = ref(eval(translationsPath)), trans = (t, n) => {
9
- const r = translations.value[t];
9
+ var s;
10
+ const r = (s = translations.value) == null ? void 0 : s[t];
10
11
  return r ? n ? Object.entries(n).reduce(
11
- (s, [i, a]) => s.replace(new RegExp(`{${i}}`, "g"), String(a)),
12
+ (i, [a, l]) => i.replace(new RegExp(`{${a}}`, "g"), String(l)),
12
13
  r
13
14
  ) : r : (console.warn(`Translation key not found: ${t}`), t);
14
15
  };
@@ -1,54 +1,63 @@
1
1
  import { ToasterTypeOptions as t } from "../enums/toaster.js";
2
- import { useVersionHistoryStore as c } from "../stores/version-history.js";
3
- import { useToaster as w } from "./useToaster.js";
4
- const S = () => {
5
- const i = c(), { showToaster: s } = w(), n = (e) => {
6
- i.$reset(), i.updateState(e);
7
- }, p = () => {
8
- i.$reset();
2
+ import { useVersionHistoryStore as m } from "../stores/version-history.js";
3
+ import { findEditorApi as w, EDITOR_NOT_READY_MESSAGE as y } from "../utils/stripoEditorApi.js";
4
+ import { useToaster as V } from "./useToaster.js";
5
+ const d = () => {
6
+ const n = m(), { showToaster: i } = V(), o = (e) => {
7
+ var s;
8
+ const r = (s = w()) == null ? void 0 : s.versionHistoryApi;
9
+ if (!r) {
10
+ i({ type: t.Error, message: y });
11
+ return;
12
+ }
13
+ e(r);
14
+ }, p = (e) => {
15
+ n.$reset(), n.updateState(e);
16
+ }, a = () => {
17
+ n.$reset();
9
18
  };
10
19
  return {
11
20
  openVersionHistory: () => {
12
- window.StripoEditorApi.versionHistoryApi.openVersionHistory(n, p);
21
+ o((e) => e.openVersionHistory(p, a));
13
22
  },
14
23
  closeVersionHistory: () => {
15
- window.StripoEditorApi.versionHistoryApi.closeVersionHistory();
24
+ o((e) => e.closeVersionHistory());
16
25
  },
17
26
  switchToDesktopPreview: () => {
18
- window.StripoEditorApi.versionHistoryApi.switchToDesktopPreview();
27
+ o((e) => e.switchToDesktopPreview());
19
28
  },
20
29
  switchToMobilePreview: () => {
21
- window.StripoEditorApi.versionHistoryApi.switchToMobilePreview();
30
+ o((e) => e.switchToMobilePreview());
22
31
  },
23
32
  previewVersion: (e) => {
24
- window.StripoEditorApi.versionHistoryApi.previewVersion(e, (o) => {
25
- const r = o instanceof Error ? o.message : String(o);
26
- s({
33
+ o((r) => r.previewVersion(e, (s) => {
34
+ const c = s instanceof Error ? s.message : String(s);
35
+ i({
27
36
  type: t.Error,
28
- message: `Error compiling email: ${r}`
37
+ message: `Error compiling email: ${c}`
29
38
  });
30
- });
39
+ }));
31
40
  },
32
41
  restoreVersion: (e) => {
33
- window.StripoEditorApi.versionHistoryApi.restoreVersion(
42
+ o((r) => r.restoreVersion(
34
43
  e,
35
44
  () => {
36
- s({
45
+ i({
37
46
  type: t.Success,
38
47
  message: "Your version has been restored successfully."
39
48
  });
40
49
  },
41
- (o) => {
42
- const r = o instanceof Error ? o.message : String(o);
43
- s({
50
+ (s) => {
51
+ const c = s instanceof Error ? s.message : String(s);
52
+ i({
44
53
  type: t.Error,
45
- message: `Error compiling email: ${r}`
54
+ message: `Error compiling email: ${c}`
46
55
  });
47
56
  }
48
- );
57
+ ));
49
58
  }
50
59
  };
51
60
  };
52
61
  export {
53
- S as useVersionHistoryApi
62
+ d as useVersionHistoryApi
54
63
  };
@@ -1,19 +1,51 @@
1
- const e = "Items", o = "Default", t = "Custom", s = {
1
+ const e = "Items", o = "Default", i = "Custom", t = {
2
2
  "Global Styles & Layout": "Global Styles and Layout",
3
3
  "Structures & Modules": "Structures and Modules",
4
4
  "Recommendation Block": "Recommendation Block",
5
5
  Items: e,
6
6
  "This block is switched from the Old Version to the New Version. We recommend you check the Recommendation block and test your message to ensure it works properly.": "This block is switched from the Old Version to the New Version. We recommend you check the Recommendation block and test your message to ensure it works properly.",
7
7
  "This block is switched from the Old Version to the New Version. We recommend you check the Items block and test your message to ensure it works properly.": "This block is switched from the Old Version to the New Version. We recommend you check the Items block and test your message to ensure it works properly.",
8
+ "email-editor.a11y-hide-images": "Hide images",
9
+ "email-editor.a11y-show-images": "Show images",
10
+ "email-editor.cvd-none": "No Color Deficiency",
11
+ "email-editor.cvd-protanopia": "Protanopia",
12
+ "email-editor.cvd-protanopia-description": "Causes red-green confusion and makes reds appear darker.",
13
+ "email-editor.cvd-deuteranopia": "Deuteranopia",
14
+ "email-editor.cvd-deuteranopia-description": "Causes red-green confusion.",
15
+ "email-editor.cvd-tritanopia": "Tritanopia",
16
+ "email-editor.cvd-tritanopia-description": "Causes blue-yellow confusion.",
17
+ "email-editor.cvd-achromatopsia": "Achromatopsia",
18
+ "email-editor.cvd-achromatopsia-description": "Causes complete color blindness.",
19
+ "email-editor.more-actions": "More actions",
20
+ "email-editor.preferences": "Preferences",
21
+ "email-editor.actions": "Actions",
22
+ "email-editor.accessibility-test": "Accessibility Test",
23
+ "email-editor.autosaved-at-today": "{boldStart}Autosaved{boldEnd} at {time}, Today",
24
+ "email-editor.autosaved-at-date": "{boldStart}Autosaved{boldEnd} at {date}",
25
+ "email-editor.export-html": "Export HTML",
26
+ "email-editor.onboarding-kebab-title": "Discover Preferences and Actions",
27
+ "email-editor.onboarding-kebab-description": "You can now access your Preferences and Actions easily such as Autosave, Export HTML, Version History, Accessibility Test and Save As Template.",
28
+ "email-editor.onboarding-autosave-title": "Autosave Your Design",
29
+ "email-editor.onboarding-autosave-description": "You can save your design automatically by enabling Autosave without losing your work.",
30
+ "email-editor.onboarding-accessibility-title": "Test Accessibility of Your Design",
31
+ "email-editor.onboarding-accessibility-description": "You can test the accessibility of your design to see the Failed, Passed items and update the Failed ones accordingly.",
8
32
  "Pixel Tracking Opt-in": "Pixel Tracking Opt-in",
9
33
  "OPT-IN SELECTION": "OPT-IN SELECTION",
10
34
  "UNSUBSCRIBE GROUPS": "UNSUBSCRIBE GROUPS",
11
35
  Default: o,
12
- Custom: t
36
+ Custom: i,
37
+ "Foreground color": "Foreground Color",
38
+ "Contrast ratio": "Contrast Ratio",
39
+ "You’ve fixed all issues!": `No Failed Items
40
+ You have no failed items.`,
41
+ "No accessibility issues found": `No Failed Items
42
+ You have no failed items.`,
43
+ "You have no ignored issues yet": `No Ignored Items
44
+ You have no ignored items.`
13
45
  };
14
46
  export {
15
- t as Custom,
47
+ i as Custom,
16
48
  o as Default,
17
49
  e as Items,
18
- s as default
50
+ t as default
19
51
  };
@@ -76,7 +76,8 @@ const e = {
76
76
  "The data source link is unavailable. Please, make sure there is an access to the data source.": "Enter an accessible Data Source Link to contiue.",
77
77
  "The file should not exceed the maximum resolution of {maxImageResolution}px.": "Upload files up to 1024x512 pixels to continue.",
78
78
  "The option is disabled because was overridden in the Code editor": "The option is disabled because it was overridden in the Code Editor.",
79
- "Dropdown with a list of available data services, preliminarily created in the Data section → Services tab of the Account.": "Service for Data Collection lets you enter a form submission URL for the recipients to submit."
79
+ "Dropdown with a list of available data services, preliminarily created in the Data section → Services tab of the Account.": "Service for Data Collection lets you enter a form submission URL for the recipients to submit.",
80
+ 'Read more about the issue on <a target="_blank" rel="noopener noreferrer" href="{url}">ACT Rules Community Group forum</a>': 'Read more about the issue on <a target="_blank" rel="noopener noreferrer" href="{url}">ACT Rules Community Group forum.</a>'
80
81
  };
81
82
  export {
82
83
  e as default
@@ -1,14 +1,28 @@
1
- import { useTranslations as r } from "../../composables/useTranslations.js";
2
- const l = {
1
+ import { useTranslations as s } from "../../composables/useTranslations.js";
2
+ const a = {
3
3
  RECOMMENDATION_API_URL: "https://recommendationv2.api.useinsider.com",
4
4
  // Relative path → same-origin as the embedding inone dashboard.
5
5
  PRODUCT_ATTRIBUTES_PATH: "/product-attributes/get-attributes",
6
6
  RECOMMENDATION_STRATEGIES_PATH: "/api/recommendation-strategies",
7
- RECOMMENDATION_STRATEGIES_PANEL_PATH: "/discovery/recommendation-strategies"
8
- }, c = {
7
+ RECOMMENDATION_STRATEGIES_PANEL_PATH: "/discovery/recommendation-strategies",
8
+ NEWSLETTER_RECOMMENDATIONS_PATH: "/newsletter/recommendations",
9
+ MIGRATE_STRATEGIES_PATH: "/newsletter/recommendations/migrate-strategies",
10
+ // The template route narrows the recommendations resource before the action: the id
11
+ // travels in the body, not the path.
12
+ TEMPLATE_MIGRATE_STRATEGIES_PATH: "/newsletter/recommendations/template/migrate-strategies",
13
+ // Smart Recommender hides the Email channel unless the URL asks for it, so a strategy created
14
+ // without this flag can never be Email-suitable and would never reach the editor's list.
15
+ RECOMMENDATION_STRATEGY_CREATE_PATH: "/discovery/recommendation-strategies/create?isEmail=true"
16
+ }, d = (e) => {
17
+ const { RECOMMENDATION_STRATEGIES_PANEL_PATH: n } = a;
18
+ return `${n}/${e}/edit?isEmail=true`;
19
+ }, m = {
20
+ campaign: a.MIGRATE_STRATEGIES_PATH,
21
+ template: a.TEMPLATE_MIGRATE_STRATEGIES_PATH
22
+ }, T = {
9
23
  CLIENT_ID: "clientId"
10
- }, d = () => {
11
- const e = r();
24
+ }, E = () => {
25
+ const e = s();
12
26
  return [
13
27
  {
14
28
  id: 11,
@@ -71,73 +85,75 @@ const l = {
71
85
  path: "top-sellers"
72
86
  }
73
87
  ];
74
- }, m = ["discount", "omnibus_price", "omnibus_discount", "price", "original_price"], p = [
88
+ }, p = ["discount", "omnibus_price", "omnibus_discount", "price", "original_price"], A = [
75
89
  { text: "before the amount", value: "0" },
76
90
  { text: "after the amount", value: "1" }
77
91
  ], v = [
78
92
  { text: "dot(.)", value: "." },
79
93
  { text: "comma(,)", value: "," },
80
94
  { text: "space( )", value: " " }
81
- ], h = [
95
+ ], _ = [
82
96
  { text: "0", value: "0" },
83
97
  { text: "1", value: "1" },
84
98
  { text: "2", value: "2" },
85
99
  { text: "3", value: "3" },
86
100
  { text: "4", value: "4" },
87
101
  { text: "5", value: "5" }
88
- ], a = "||", t = [
102
+ ], r = "||", t = [
89
103
  { text: "is exactly", value: "=" },
90
104
  { text: "contains", value: "~" },
91
105
  { text: "does not contain", value: "!~" },
92
- { text: "any of", value: a }
93
- ], n = [
106
+ { text: "any of", value: r }
107
+ ], o = [
94
108
  { text: "is exactly", value: "=" },
95
109
  { text: "is not exactly", value: "!==" },
96
110
  { text: "contains", value: "~" },
97
111
  { text: "does not contain", value: "!~" },
98
- { text: "any of", value: a }
99
- ], o = [
112
+ { text: "any of", value: r }
113
+ ], i = [
100
114
  { text: "is equal to", value: "=" },
101
115
  { text: "is greater than", value: ">" },
102
116
  { text: "is less than", value: "<" }
103
- ], s = [
117
+ ], u = [
104
118
  { text: "is equal to", value: "=" },
105
119
  { text: "after", value: ">" },
106
120
  { text: "before", value: "<" }
107
- ], i = [
121
+ ], c = [
108
122
  { text: "true", value: "==" },
109
123
  { text: "false", value: "!=" }
110
- ], x = (e) => {
124
+ ], h = (e) => {
111
125
  if (!e)
112
126
  return t;
113
127
  switch (e) {
114
128
  case "Boolean":
115
- return i;
129
+ return c;
116
130
  case "Date":
117
- return s;
131
+ return u;
118
132
  case "Number":
119
- return o;
133
+ return i;
120
134
  case "String":
121
135
  return t;
122
136
  case "Strings":
123
- return n;
137
+ return o;
124
138
  default:
125
139
  return t;
126
140
  }
127
141
  };
128
142
  export {
129
- a as OP_ANY_OF,
130
- m as PriceAttributes,
131
- c as QUERY_PARAMS,
132
- l as URLS,
133
- h as currencyDecimalCounts,
134
- p as currencyLocationMaps,
143
+ m as MIGRATION_PATHS,
144
+ r as OP_ANY_OF,
145
+ p as PriceAttributes,
146
+ T as QUERY_PARAMS,
147
+ a as URLS,
148
+ _ as currencyDecimalCounts,
149
+ A as currencyLocationMaps,
135
150
  v as currencyOperators,
136
- x as getOperatorOptions,
137
- d as getRecommendationFeedSourceMaps,
138
- n as operatorOptionsForArrayOfStrings,
139
- i as operatorOptionsForBooleans,
140
- s as operatorOptionsForDates,
141
- o as operatorOptionsForNumbers,
142
- t as operatorOptionsForStrings
151
+ h as getOperatorOptions,
152
+ E as getRecommendationFeedSourceMaps,
153
+ o as operatorOptionsForArrayOfStrings,
154
+ c as operatorOptionsForBooleans,
155
+ u as operatorOptionsForDates,
156
+ i as operatorOptionsForNumbers,
157
+ t as operatorOptionsForStrings,
158
+ d as strategyEditPath
143
159
  };