@useinsider/guido 3.17.0-beta.a18fbda → 3.17.0-beta.a471c11

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 (131) hide show
  1. package/README.md +1 -0
  2. package/dist/@types/config/schemas.js +19 -16
  3. package/dist/components/Guido.vue.js +10 -10
  4. package/dist/components/Guido.vue2.js +81 -79
  5. package/dist/components/organisms/extensions/recommendation/AssignStrategyDrawer.vue.js +21 -0
  6. package/dist/components/organisms/extensions/recommendation/AssignStrategyDrawer.vue2.js +106 -0
  7. package/dist/components/organisms/extensions/recommendation/RemoveStrategyModal.vue.js +17 -0
  8. package/dist/components/organisms/extensions/recommendation/RemoveStrategyModal.vue2.js +57 -0
  9. package/dist/components/organisms/extensions/recommendation/StrategyInfoBoxContent.vue.js +19 -0
  10. package/dist/components/organisms/extensions/recommendation/StrategyInfoBoxContent.vue2.js +63 -0
  11. package/dist/components/organisms/header/AutoSaveStatus.vue.js +17 -0
  12. package/dist/components/organisms/header/AutoSaveStatus.vue2.js +21 -0
  13. package/dist/components/organisms/header/EditorActions.vue.js +11 -11
  14. package/dist/components/organisms/header/EditorActions.vue2.js +34 -63
  15. package/dist/components/organisms/header/EditorActionsMenu.vue.js +20 -0
  16. package/dist/components/organisms/header/EditorActionsMenu.vue2.js +39 -0
  17. package/dist/components/organisms/header/LeftSlot.vue.js +5 -5
  18. package/dist/components/organisms/header/LeftSlot.vue2.js +28 -23
  19. package/dist/components/organisms/header/MiddleSlot.vue.js +4 -4
  20. package/dist/components/organisms/header/MiddleSlot.vue2.js +8 -7
  21. package/dist/components/organisms/header/RightSlot.vue.js +6 -6
  22. package/dist/components/organisms/header/RightSlot.vue2.js +17 -15
  23. package/dist/components/organisms/header/accessibility/AccessibilityToolbar.vue.js +18 -0
  24. package/dist/components/organisms/header/accessibility/AccessibilityToolbar.vue2.js +37 -0
  25. package/dist/components/organisms/header/accessibility/ColorVisionSelect.vue.js +24 -0
  26. package/dist/components/organisms/header/accessibility/ColorVisionSelect.vue2.js +48 -0
  27. package/dist/components/organisms/onboarding/EditorTabBarOnboarding.vue.js +18 -0
  28. package/dist/components/organisms/onboarding/EditorTabBarOnboarding.vue2.js +74 -0
  29. package/dist/components/organisms/onboarding/OnboardingWrapper.vue2.js +43 -34
  30. package/dist/composables/useAccessibilityApi.js +31 -0
  31. package/dist/composables/useActionsApi.js +67 -82
  32. package/dist/composables/useAutoSave.js +26 -31
  33. package/dist/composables/useCustomInterfaceAppearance.js +52 -38
  34. package/dist/composables/useGuidoStateBridge.js +31 -37
  35. package/dist/composables/useRecommendation.js +41 -34
  36. package/dist/composables/useSave.js +36 -39
  37. package/dist/composables/useStripo.js +14 -14
  38. package/dist/config/i18n/en/labels.json.js +29 -5
  39. package/dist/config/migrator/index.js +9 -8
  40. package/dist/config/migrator/recommendation/compositionMapper.js +20 -20
  41. package/dist/config/migrator/recommendation/extractors.js +29 -24
  42. package/dist/config/migrator/recommendation/htmlBuilder.js +116 -130
  43. package/dist/config/migrator/recommendation/settingsMapper.js +17 -17
  44. package/dist/config/migrator/recommendationMigrator.js +31 -25
  45. package/dist/config/migrator/recommendationTitleMigrator.js +119 -0
  46. package/dist/enums/academy.js +2 -1
  47. package/dist/enums/date.js +5 -3
  48. package/dist/enums/extensions/recommendationBlock.js +3 -1
  49. package/dist/extensions/Blocks/Recommendation/block.js +35 -29
  50. package/dist/extensions/Blocks/Recommendation/constants/blockIds.js +1 -1
  51. package/dist/extensions/Blocks/Recommendation/constants/controlIds.js +1 -1
  52. package/dist/extensions/Blocks/Recommendation/constants/defaultConfig.js +29 -27
  53. package/dist/extensions/Blocks/Recommendation/constants/selectors.js +35 -28
  54. package/dist/extensions/Blocks/Recommendation/controls/cardComposition/index.js +309 -236
  55. package/dist/extensions/Blocks/Recommendation/controls/main/index.js +241 -180
  56. package/dist/extensions/Blocks/Recommendation/controls/main/strategy.js +124 -0
  57. package/dist/extensions/Blocks/Recommendation/controls/main/utils.js +1 -0
  58. package/dist/extensions/Blocks/Recommendation/controls/title/index.js +44 -0
  59. package/dist/extensions/Blocks/Recommendation/extension.js +31 -29
  60. package/dist/extensions/Blocks/Recommendation/services/configService.js +54 -36
  61. package/dist/extensions/Blocks/Recommendation/settingsPanel.js +23 -4
  62. package/dist/extensions/Blocks/Recommendation/store/recommendation.js +175 -79
  63. package/dist/extensions/Blocks/Recommendation/templates/grid/template.js +3 -3
  64. package/dist/extensions/Blocks/Recommendation/templates/titleRows.js +33 -0
  65. package/dist/extensions/Blocks/Recommendation/templates/utils.js +85 -107
  66. package/dist/extensions/Blocks/Recommendation/utils/nodeConfigWriter.js +22 -0
  67. package/dist/extensions/Blocks/common-control.js +22 -19
  68. package/dist/guido.css +1 -1
  69. package/dist/node_modules/@vueuse/core/index.js +102 -0
  70. package/dist/node_modules/@vueuse/shared/index.js +40 -28
  71. package/dist/services/recommendationApi.js +69 -30
  72. package/dist/src/@types/config/schemas.d.ts +6 -0
  73. package/dist/src/components/organisms/extensions/recommendation/AssignStrategyDrawer.vue.d.ts +3 -0
  74. package/dist/src/components/organisms/extensions/recommendation/StrategyInfoBoxContent.vue.d.ts +15 -0
  75. package/dist/src/components/organisms/header/AutoSaveStatus.vue.d.ts +2 -0
  76. package/dist/src/components/organisms/header/EditorActionsMenu.vue.d.ts +2 -0
  77. package/dist/src/components/organisms/header/accessibility/AccessibilityToolbar.vue.d.ts +2 -0
  78. package/dist/src/components/organisms/header/accessibility/ColorVisionSelect.vue.d.ts +2 -0
  79. package/dist/src/components/organisms/onboarding/EditorTabBarOnboarding.vue.d.ts +2 -0
  80. package/dist/src/composables/useAccessibilityApi.d.ts +15 -0
  81. package/dist/src/composables/useActionsApi.d.ts +2 -2
  82. package/dist/src/composables/useConfig.d.ts +4 -0
  83. package/dist/src/composables/useRecommendation.d.ts +1 -0
  84. package/dist/src/config/migrator/recommendation/extractors.d.ts +8 -0
  85. package/dist/src/config/migrator/recommendationTitleMigrator.d.ts +5 -0
  86. package/dist/src/enums/academy.d.ts +1 -0
  87. package/dist/src/enums/date.d.ts +1 -0
  88. package/dist/src/enums/extensions/recommendationBlock.d.ts +2 -0
  89. package/dist/src/extensions/Blocks/Recommendation/constants/blockIds.d.ts +2 -1
  90. package/dist/src/extensions/Blocks/Recommendation/constants/controlIds.d.ts +7 -0
  91. package/dist/src/extensions/Blocks/Recommendation/constants/defaultConfig.d.ts +3 -6
  92. package/dist/src/extensions/Blocks/Recommendation/constants/index.d.ts +2 -2
  93. package/dist/src/extensions/Blocks/Recommendation/constants/selectors.d.ts +12 -0
  94. package/dist/src/extensions/Blocks/Recommendation/controls/cardComposition/index.d.ts +11 -0
  95. package/dist/src/extensions/Blocks/Recommendation/controls/index.d.ts +1 -0
  96. package/dist/src/extensions/Blocks/Recommendation/controls/main/index.d.ts +44 -8
  97. package/dist/src/extensions/Blocks/Recommendation/controls/main/strategy.d.ts +16 -0
  98. package/dist/src/extensions/Blocks/Recommendation/controls/main/utils.d.ts +1 -0
  99. package/dist/src/extensions/Blocks/Recommendation/controls/title/index.d.ts +86 -0
  100. package/dist/src/extensions/Blocks/Recommendation/services/configService.d.ts +12 -1
  101. package/dist/src/extensions/Blocks/Recommendation/store/recommendation.d.ts +176 -10
  102. package/dist/src/extensions/Blocks/Recommendation/templates/titleRows.d.ts +13 -0
  103. package/dist/src/extensions/Blocks/Recommendation/types/nodeConfig.d.ts +7 -0
  104. package/dist/src/extensions/Blocks/Recommendation/utils/nodeConfigWriter.d.ts +31 -0
  105. package/dist/src/extensions/Blocks/common-control.d.ts +4 -1
  106. package/dist/src/mock/api/recommendation-strategies.d.ts +2 -0
  107. package/dist/src/services/recommendationApi.d.ts +4 -1
  108. package/dist/src/stores/config.d.ts +36 -0
  109. package/dist/src/stores/editor.d.ts +76 -0
  110. package/dist/src/stores/onboarding.d.ts +377 -0
  111. package/dist/src/stores/save-as-template.d.ts +4 -3
  112. package/dist/src/stores/version-history.d.ts +1 -1
  113. package/dist/src/utils/genericUtil.d.ts +5 -0
  114. package/dist/src/utils/timeUtil.d.ts +10 -0
  115. package/dist/static/assets/icons/line-change.svg.js +5 -0
  116. package/dist/static/assets/icons/line-delete.svg.js +5 -0
  117. package/dist/static/assets/icons/line-plus.svg.js +5 -0
  118. package/dist/static/styles/components/recommendation-strategy.css.js +155 -0
  119. package/dist/static/styles/customEditorStyle.css.js +3 -1
  120. package/dist/stores/editor.js +4 -1
  121. package/dist/stores/onboarding.js +16 -11
  122. package/dist/utils/dateUtil.js +23 -10
  123. package/dist/utils/genericUtil.js +28 -27
  124. package/dist/utils/templatePreparation.js +35 -34
  125. package/dist/utils/timeUtil.js +6 -17
  126. package/package.json +2 -1
  127. package/dist/components/organisms/header/AutoSaveToggle.vue.js +0 -22
  128. package/dist/components/organisms/header/AutoSaveToggle.vue2.js +0 -19
  129. package/dist/composables/useEditorLock.js +0 -20
  130. package/dist/src/composables/useEditorLock.d.ts +0 -10
  131. /package/dist/src/components/organisms/{header/AutoSaveToggle.vue.d.ts → extensions/recommendation/RemoveStrategyModal.vue.d.ts} +0 -0
@@ -0,0 +1,63 @@
1
+ import { defineComponent as f, computed as i } from "vue";
2
+ import { useTranslations as _ } from "../../../../composables/useTranslations.js";
3
+ import { asText as c } from "../../../../utils/genericUtil.js";
4
+ const j = /* @__PURE__ */ f({
5
+ __name: "StrategyInfoBoxContent",
6
+ props: {
7
+ strategy: null
8
+ },
9
+ setup(p) {
10
+ const a = p, n = _(), s = i(() => n("recommendation-strategy.none")), u = i(() => {
11
+ const e = c(a.strategy.algorithm) === "MIXED" ? n("discovery-strategy.mixed-algorithm") : n("discovery-strategy.single-algorithm"), t = c(a.strategy.algorithm_used).split(",").map((r) => r.trim()).filter(Boolean).map((r) => n(`recommendation-algorithm-names.${r.replaceAll("_", "-").toLowerCase()}`));
12
+ return t.length ? `${e} · ${t.join(", ")}` : e;
13
+ }), d = i(() => [
14
+ [a.strategy.exclude_view, "discovery-strategy.exclude-recently-view-items"],
15
+ [a.strategy.exclude_purchase, "discovery-strategy.exclude-recently-purchased-items"],
16
+ [a.strategy.exclude_cart, "discovery-strategy.exclude-recently-added-cart-items"]
17
+ ].filter(([e]) => Number(e) === 1).map(([, e]) => n(e)).join(", ") || s.value), l = (e) => {
18
+ const t = c(e).trim();
19
+ if (!t)
20
+ return "";
21
+ let r;
22
+ try {
23
+ r = JSON.parse(t);
24
+ } catch {
25
+ return t;
26
+ }
27
+ if (Array.isArray(r))
28
+ return r.length ? String(r.length) : "";
29
+ if (r && typeof r == "object") {
30
+ const o = Object.keys(r).length;
31
+ return o ? String(o) : "";
32
+ }
33
+ return t;
34
+ }, m = i(() => l(a.strategy.manual_merchandising) || l(a.strategy.manual_merchandising_products) || s.value), g = (e) => {
35
+ if (Array.isArray(e))
36
+ return e.length;
37
+ const { conditionList: t } = e ?? {};
38
+ return Array.isArray(t) ? t.length : 1;
39
+ }, y = i(() => {
40
+ const e = a.strategy.filters;
41
+ if (!e)
42
+ return s.value;
43
+ try {
44
+ const t = typeof e == "string" ? JSON.parse(e) : e;
45
+ if (!t || typeof t != "object")
46
+ return s.value;
47
+ const r = Object.values(t).reduce((o, v) => o + g(v), 0);
48
+ return r ? String(r) : s.value;
49
+ } catch {
50
+ return s.value;
51
+ }
52
+ }), h = i(() => [
53
+ { title: n("gpt-app-builder.algorithms-and-method"), value: u.value },
54
+ { title: n("gpt-app-builder.exclusions"), value: d.value },
55
+ { title: n("discovery-strategy.filters"), value: y.value },
56
+ { title: n("action-builder.manual-merchandising"), value: m.value }
57
+ ]);
58
+ return { __sfc: !0, props: a, trans: n, none: s, algorithmsAndMethod: u, exclusions: d, asMerchandising: l, manualMerchandising: m, conditionsIn: g, filters: y, details: h };
59
+ }
60
+ });
61
+ export {
62
+ j as default
63
+ };
@@ -0,0 +1,17 @@
1
+ import e from "./AutoSaveStatus.vue2.js";
2
+ import r from "../../../_virtual/_plugin-vue2_normalizer.js";
3
+ var n = function() {
4
+ var s = this, t = s._self._c, a = s._self._setupProxy;
5
+ return a.isFeatureEnabled("autosave") ? t("div", { staticClass: "d-f a-i-c mr-3 auto-save-status" }, [a.autosaveStore.status === a.AUTOSAVE_STATUS.SAVING ? t("span", { staticClass: "d-f a-i-c f-s-1" }, [t(a.InLoading, { attrs: { "color-class": "i-c-53", size: "16" } }), t("span", { staticClass: "ml-1 t-c-53" }, [s._v(s._s(a.trans("newsletter.saving")))])], 1) : a.savedLabel ? t("span", { staticClass: "f-s-1 t-c-53" }, [s._v(s._s(a.savedLabel))]) : s._e()]) : s._e();
6
+ }, _ = [], o = /* @__PURE__ */ r(
7
+ e,
8
+ n,
9
+ _,
10
+ !1,
11
+ null,
12
+ null
13
+ );
14
+ const u = o.exports;
15
+ export {
16
+ u as default
17
+ };
@@ -0,0 +1,21 @@
1
+ import { defineComponent as i, computed as u } from "vue";
2
+ import { useConfig as d } from "../../../composables/useConfig.js";
3
+ import { useTranslations as p } from "../../../composables/useTranslations.js";
4
+ import { useAutosaveStore as f, AUTOSAVE_STATUS as o } from "../../../stores/autosave.js";
5
+ import { autoSaveTimestamp as S } from "../../../utils/timeUtil.js";
6
+ import { InLoading as c } from "@useinsider/design-system-vue";
7
+ const g = /* @__PURE__ */ i({
8
+ __name: "AutoSaveStatus",
9
+ setup(v) {
10
+ const { isFeatureEnabled: a } = d(), t = f(), e = p(), s = u(() => {
11
+ if (t.status !== o.SAVED || !t.lastSavedAt)
12
+ return "";
13
+ const { isToday: r, time: m, date: n } = S(t.lastSavedAt);
14
+ return r ? e("email-editor.autosaved-at-today", { time: m }) : e("email-editor.autosaved-at-date", { date: n });
15
+ });
16
+ return { __sfc: !0, isFeatureEnabled: a, autosaveStore: t, trans: e, savedLabel: s, AUTOSAVE_STATUS: o, InLoading: c };
17
+ }
18
+ });
19
+ export {
20
+ g as default
21
+ };
@@ -1,21 +1,21 @@
1
- import l from "./EditorActions.vue2.js";
1
+ import r from "./EditorActions.vue2.js";
2
2
  /* empty css */
3
- import d from "../../../_virtual/_plugin-vue2_normalizer.js";
4
- var u = function() {
5
- var s, i, n, a;
6
- var o = this, e = o._self._c, t = o._self._setupProxy;
7
- return e("div", { staticClass: "d-f editor-actions" }, [t.isVersionHistoryButtonVisible ? e(t.InButtonV2, { attrs: { id: "guido__history-button", "left-icon": "line-architect-version-history", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isVersionHistoryButtonDisabled, "label-text-status": !1, "selected-status": t.editorStore.isVersionHistoryOpen, "tooltip-options": t.getTooltipOptions("guido__history-button"), "tooltip-text": t.versionHistoryTooltipText }, on: { click: t.handleVersionHistory } }) : o._e(), e(t.InButtonV2, { attrs: { id: "guido__export-button", "left-icon": "line-export", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isExportButtonDisabled, "label-text-status": !1, "loading-status": t.isExporting, "tooltip-options": t.getTooltipOptions("guido__export-button"), "tooltip-text": t.trans("newsletter.export") }, on: { click: t.handleExport } }), (i = (s = t.config) == null ? void 0 : s.features) != null && i.saveAsTemplate ? e(t.InButtonV2, { attrs: { id: "guido__save-as-button", "left-icon": "line-newsletter-save-as-template", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isSaveAsButtonDisabled, "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__save-as-button"), "tooltip-text": t.trans("newsletter.save-templates") }, on: { click: t.handleSaveAs } }) : o._e(), (a = (n = t.config) == null ? void 0 : n.features) != null && a.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 } }) : o._e(), t.editorStore.isPreviewModeOpen ? o._e() : e(t.InButtonV2, { staticClass: "ml-3", attrs: { id: "guido__save-button", "label-text": "Save", "disabled-status": !t.isSaving && t.editorStore.isSaveButtonDisabled, "loading-status": t.isSaving }, on: { click: function(r) {
3
+ import a from "../../../_virtual/_plugin-vue2_normalizer.js";
4
+ var l = function() {
5
+ var i, s;
6
+ var e = this, o = e._self._c, t = e._self._setupProxy;
7
+ return o("div", { staticClass: "d-f a-i-c editor-actions" }, [(s = (i = t.config) == null ? void 0 : i.features) != null && s.testMessage && !t.editorStore.isPreviewModeOpen ? o(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 } }) : e._e(), t.editorStore.isPreviewModeOpen ? e._e() : o(t.EditorActionsMenu), t.editorStore.isPreviewModeOpen ? e._e() : o(t.InButtonV2, { staticClass: "ml-3", attrs: { id: "guido__save-button", "label-text": "Save", "disabled-status": !t.isSaving && t.editorStore.isSaveButtonDisabled, "loading-status": t.isSaving }, on: { click: function(n) {
8
8
  return t.handleSave(!1);
9
- } } }), e(t.MigrationConfirmModal, { ref: "migrationModalRef", on: { confirm: function(r) {
9
+ } } }), o(t.MigrationConfirmModal, { ref: "migrationModalRef", on: { confirm: function(n) {
10
10
  return t.executeSave(!1);
11
11
  } } })], 1);
12
- }, p = [], c = /* @__PURE__ */ d(
12
+ }, d = [], c = /* @__PURE__ */ a(
13
+ r,
13
14
  l,
14
- u,
15
- p,
15
+ d,
16
16
  !1,
17
17
  null,
18
- "1ca6baf0"
18
+ "d51fb931"
19
19
  );
20
20
  const v = c.exports;
21
21
  export {
@@ -1,79 +1,50 @@
1
- import { defineComponent as q, ref as l, computed as w } from "vue";
2
- import { useActionsApi as b } from "../../../composables/useActionsApi.js";
3
- import { useConfig as k } from "../../../composables/useConfig.js";
4
- import { useExport as B } from "../../../composables/useExport.js";
5
- import { useTestEmailClick as D } from "../../../composables/useGuidoActions.js";
6
- import { useHtmlCompiler as L } from "../../../composables/useHtmlCompiler.js";
7
- import { useSave as R } from "../../../composables/useSave.js";
8
- import { useToaster as z } from "../../../composables/useToaster.js";
9
- import { useTranslations as I } from "../../../composables/useTranslations.js";
10
- import { useVersionHistoryApi as P } from "../../../composables/useVersionHistoryApi.js";
11
- import { useLiquidValidator as j } from "../../../composables/validators/useLiquidValidator.js";
12
- import { useEditorStore as G } from "../../../stores/editor.js";
13
- import { useTemplateStore as J } from "../../../stores/template.js";
14
- import { getTooltipOptions as K } from "../../../utils/tooltipUtils.js";
15
- import { InButtonV2 as N } from "@useinsider/design-system-vue";
16
- import { storeToRefs as Q } from "pinia";
17
- import U from "./MigrationConfirmModal.vue.js";
18
- const ft = /* @__PURE__ */ q({
1
+ import { defineComponent as C, ref as g } from "vue";
2
+ import { useActionsApi as y } from "../../../composables/useActionsApi.js";
3
+ import { useConfig as T } from "../../../composables/useConfig.js";
4
+ import { useTestEmailClick as M } from "../../../composables/useGuidoActions.js";
5
+ import { useHtmlCompiler as h } from "../../../composables/useHtmlCompiler.js";
6
+ import { useSave as x } from "../../../composables/useSave.js";
7
+ import { useTranslations as A } from "../../../composables/useTranslations.js";
8
+ import { useLiquidValidator as V } from "../../../composables/validators/useLiquidValidator.js";
9
+ import { useEditorStore as q } from "../../../stores/editor.js";
10
+ import { useTemplateStore as w } from "../../../stores/template.js";
11
+ import { getTooltipOptions as H } from "../../../utils/tooltipUtils.js";
12
+ import { InButtonV2 as k } from "@useinsider/design-system-vue";
13
+ import { storeToRefs as F } from "pinia";
14
+ import L from "./EditorActionsMenu.vue.js";
15
+ import R from "./MigrationConfirmModal.vue.js";
16
+ const Z = /* @__PURE__ */ C({
19
17
  __name: "EditorActions",
20
- setup(W, { expose: x }) {
21
- const { config: m, isFeatureEnabled: c } = k(), { exportHtml: p } = B(), { save: u } = R(), { openVersionHistory: f, closeVersionHistory: d } = P(), { getCompiledEmail: v } = b(), { compileHtml: y } = L(), { validateLiquidSyntax: g } = j(), { handleError: r } = z(), e = G(), h = J(), { hasMigrations: H } = Q(h), s = I(), i = l(!1), a = l(!1), S = l(), V = D(), _ = () => {
22
- if (e.isVersionHistoryOpen) {
23
- d();
24
- return;
25
- }
26
- f();
27
- }, C = async () => {
28
- i.value = !0, await p(), i.value = !1;
29
- }, A = () => {
30
- e.isSaveAsTemplateDrawerOpen = !0;
31
- }, M = w(() => e.isVersionHistoryOpen ? s("newsletter.close-version-history") : s("newsletter.version-history")), O = w(
32
- () => {
33
- var t, o;
34
- return ((o = (t = m.value) == null ? void 0 : t.features) == null ? void 0 : o.versionHistory) && !e.isPreviewModeOpen;
35
- }
36
- ), E = async (t) => {
37
- a.value = !0, t || (e.loadingStatus = !0);
38
- let o;
39
- try {
40
- o = await u(t);
41
- } catch (n) {
42
- if (t)
43
- throw n;
44
- r(n, "Failed to save template");
45
- } finally {
46
- a.value = !1, !t && !o && (e.loadingStatus = !1);
47
- }
48
- return o;
49
- }, T = (t) => {
18
+ setup(b, { expose: v }) {
19
+ const { config: S, isFeatureEnabled: a } = T(), { save: r } = x(), { getCompiledEmail: s } = y(), { compileHtml: n } = h(), { validateLiquidSyntax: m } = V(), e = q(), l = w(), { hasMigrations: f } = F(l), E = A(), i = g(!1), u = g(), c = M(), p = async (t) => {
20
+ i.value = !0, t || (e.loadingStatus = !0);
21
+ const o = await r(t);
22
+ return i.value = !1, !t && !o && (e.loadingStatus = !1), o;
23
+ }, d = (t) => {
50
24
  var o;
51
- if (!t && H.value) {
52
- (o = S.value) == null || o.open();
25
+ if (!t && f.value) {
26
+ (o = u.value) == null || o.open();
53
27
  return;
54
28
  }
55
- return E(t);
56
- }, F = async () => {
57
- if (c("liquidSyntax")) {
29
+ return p(t);
30
+ }, _ = async () => {
31
+ if (a("liquidSyntax")) {
58
32
  e.loadingStatus = !0;
59
33
  try {
60
- const { html: t } = await v({ minimize: !0, resetDataSavedFlag: !1 }), { compiledHtml: o } = y(t);
61
- if (!await g(o))
34
+ const { html: t } = await s({ minimize: !0, resetDataSavedFlag: !1 }), { compiledHtml: o } = n(t);
35
+ if (!await m(o))
62
36
  return;
63
- } catch (t) {
64
- r(t, "Failed to prepare test email");
65
- return;
66
37
  } finally {
67
38
  e.loadingStatus = !1;
68
39
  }
69
40
  }
70
- V();
41
+ c();
71
42
  };
72
- return x({
73
- handleSave: T
74
- }), { __sfc: !0, config: m, isFeatureEnabled: c, exportHtml: p, save: u, openVersionHistory: f, closeVersionHistory: d, getCompiledEmail: v, compileHtml: y, validateLiquidSyntax: g, handleError: r, editorStore: e, templateStore: h, hasMigrations: H, trans: s, isExporting: i, isSaving: a, migrationModalRef: S, testEmailClick: V, handleVersionHistory: _, handleExport: C, handleSaveAs: A, versionHistoryTooltipText: M, isVersionHistoryButtonVisible: O, executeSave: E, handleSave: T, handleTestEmail: F, getTooltipOptions: K, InButtonV2: N, MigrationConfirmModal: U };
43
+ return v({
44
+ handleSave: d
45
+ }), { __sfc: !0, config: S, isFeatureEnabled: a, save: r, getCompiledEmail: s, compileHtml: n, validateLiquidSyntax: m, editorStore: e, templateStore: l, hasMigrations: f, trans: E, isSaving: i, migrationModalRef: u, testEmailClick: c, executeSave: p, handleSave: d, handleTestEmail: _, getTooltipOptions: H, InButtonV2: k, EditorActionsMenu: L, MigrationConfirmModal: R };
75
46
  }
76
47
  });
77
48
  export {
78
- ft as default
49
+ Z as default
79
50
  };
@@ -0,0 +1,20 @@
1
+ import i from "./EditorActionsMenu.vue2.js";
2
+ /* empty css */
3
+ import a from "../../../_virtual/_plugin-vue2_normalizer.js";
4
+ var o = function() {
5
+ var e = this, s = e._self._c, t = e._self._setupProxy;
6
+ return s("div", { ref: "root", staticClass: "editor-actions-menu p-r" }, [s(t.InButtonV2, { attrs: { id: "guido__kebab-button", "data-testid": "Editor Actions Menu", "left-icon": "line-more-vertical", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.loadingStatus, "label-text-status": !1, "selected-status": t.isOpen, "tooltip-options": t.getTooltipOptions("guido__kebab-button"), "tooltip-text": t.trans("email-editor.more-actions") }, on: { click: function(c) {
7
+ t.isOpen = !t.isOpen;
8
+ } } }), t.isOpen ? s("div", { staticClass: "editor-actions-menu__panel p-a" }, [t.isAutosaveVisible ? [s("p", { staticClass: "editor-actions-menu__section f-s-1 t-c-55" }, [e._v(" " + e._s(t.trans("email-editor.preferences")) + " ")]), s("div", { staticClass: "editor-actions-menu__row editor-actions-menu__row_static d-f a-i-c j-c-s-b" }, [s("span", { staticClass: "f-s-2" }, [e._v(e._s(t.trans("email-editor.auto-save")))]), s(t.InToggle, { attrs: { id: "guido__kebab-autosave-toggle", name: "guido-kebab-autosave-toggle", checked: t.autosaveStore.isOn, disable: t.editorStore.loadingStatus }, on: { click: t.toggleAutosave } })], 1), s("div", { staticClass: "editor-actions-menu__divider" })] : e._e(), s("p", { staticClass: "editor-actions-menu__section f-s-1 t-c-55" }, [e._v(" " + e._s(t.trans("email-editor.actions")) + " ")]), t.isVersionHistoryVisible ? s("button", { staticClass: "editor-actions-menu__row d-f a-i-c", attrs: { id: "guido__kebab-version-history", type: "button", disabled: t.editorStore.isVersionHistoryButtonDisabled }, on: { click: t.handleVersionHistory } }, [s(t.InIcons, { staticClass: "mr-2", attrs: { name: "line-reset", size: "16" } }), s("span", { staticClass: "f-s-2" }, [e._v(e._s(t.trans("newsletter.version-history")))])], 1) : e._e(), t.isAccessibilityVisible ? s("button", { staticClass: "editor-actions-menu__row d-f a-i-c", attrs: { id: "guido__kebab-accessibility", type: "button", disabled: t.editorStore.loadingStatus }, on: { click: t.handleAccessibility } }, [s("svg", { staticClass: "mr-2 editor-actions-menu__icon", attrs: { "aria-hidden": "true", fill: "none", height: "16", viewBox: "0 0 20 20", width: "16" } }, [s("rect", { attrs: { height: "18", rx: "9", stroke: "currentColor", "stroke-width": "2", width: "18", x: "1", y: "1" } }), s("path", { attrs: { fill: "currentColor", d: t.ACCESSIBILITY_ICON_PATH } })]), s("span", { staticClass: "f-s-2" }, [e._v(e._s(t.trans("email-editor.accessibility-test")))])]) : e._e(), t.isSaveAsVisible ? s("button", { staticClass: "editor-actions-menu__row d-f a-i-c", attrs: { id: "guido__kebab-save-as", type: "button", disabled: t.editorStore.isSaveAsButtonDisabled }, on: { click: t.handleSaveAs } }, [s(t.InIcons, { staticClass: "mr-2", attrs: { name: "line-newsletter-save-as-template", size: "16" } }), s("span", { staticClass: "f-s-2" }, [e._v(e._s(t.trans("newsletter.save-templates")))])], 1) : e._e(), s("button", { staticClass: "editor-actions-menu__row d-f a-i-c", attrs: { id: "guido__kebab-export", type: "button", disabled: t.isExporting || t.editorStore.isExportButtonDisabled }, on: { click: t.handleExport } }, [s(t.InIcons, { staticClass: "mr-2", attrs: { name: "line-export", size: "16" } }), s("span", { staticClass: "f-s-2" }, [e._v(e._s(t.trans("email-editor.export-html")))])], 1)], 2) : e._e()], 1);
9
+ }, n = [], r = /* @__PURE__ */ a(
10
+ i,
11
+ o,
12
+ n,
13
+ !1,
14
+ null,
15
+ "271b4133"
16
+ );
17
+ const b = r.exports;
18
+ export {
19
+ b as default
20
+ };
@@ -0,0 +1,39 @@
1
+ import { defineComponent as I, ref as c, computed as t } from "vue";
2
+ import { useAccessibilityApi as E } from "../../../composables/useAccessibilityApi.js";
3
+ import { useConfig as O } from "../../../composables/useConfig.js";
4
+ import { useExport as x } from "../../../composables/useExport.js";
5
+ import { useTranslations as h } from "../../../composables/useTranslations.js";
6
+ import { useVersionHistoryApi as B } from "../../../composables/useVersionHistoryApi.js";
7
+ import { useAutosaveStore as M } from "../../../stores/autosave.js";
8
+ import { useEditorStore as w } from "../../../stores/editor.js";
9
+ import { getTooltipOptions as Z } from "../../../utils/tooltipUtils.js";
10
+ import { InToggle as k, InIcons as D, InButtonV2 as F } from "@useinsider/design-system-vue";
11
+ import { onClickOutside as N } from "../../../node_modules/@vueuse/core/index.js";
12
+ const X = /* @__PURE__ */ I({
13
+ __name: "EditorActionsMenu",
14
+ setup(P) {
15
+ const v = "M14.8125 6.08473C15.332 5.94828 15.6875 6.47668 15.6875 6.95875C15.6873 7.44052 15.2498 7.66778 14.8125 7.8318C14.798 7.83727 14.7826 7.84147 14.7676 7.84547L12.3262 8.69898C12.013 8.81663 11.8784 8.93913 11.8486 8.99391L11.8467 8.99879C11.8153 9.05489 11.7235 9.29227 11.8379 10.0076L11.9961 11.238L12.8887 16.0154C12.8969 16.0521 12.9036 16.0895 12.9092 16.1267C12.9741 16.5696 12.6498 16.9997 12.0342 16.9998C11.4983 16.9998 11.2617 16.63 11.1592 16.1267C11.1592 16.1267 10.3701 11.8181 9.9873 11.8181C9.60444 11.8205 8.94137 15.6235 8.83887 16.1267C8.7363 16.63 8.49971 16.9998 7.96387 16.9998C7.34999 16.9996 7.02548 16.5711 7.08887 16.1296L7.0957 16.0955C7.09789 16.0818 7.09981 16.0676 7.10254 16.0545L7.9834 11.2371L8.1416 10.0066C8.17359 9.80644 8.26392 9.23379 8.15137 8.9441C8.11665 8.85389 8.0452 8.7492 7.7793 8.64723L5.17962 7.83495C5.17734 7.83424 5.17578 7.83212 5.17578 7.82972C5.17578 7.82745 5.17437 7.82541 5.17224 7.8246C4.74007 7.66146 4.31254 7.43412 4.3125 6.95777C4.31258 6.47553 4.66813 5.9482 5.1875 6.08473C5.26161 6.10405 5.33481 6.12744 5.40625 6.15504C6.12486 6.3593 8.37146 6.9607 9.98828 6.9607C11.7281 6.96068 14.1981 6.26431 14.707 6.115C14.7342 6.10658 14.7619 6.09917 14.7891 6.09156L14.7998 6.08766L14.8125 6.08473ZM9.70117 3.02906C9.99821 2.96998 10.3061 3.00106 10.5859 3.11695C10.8657 3.23286 11.1052 3.42866 11.2734 3.68043C11.4416 3.93217 11.5312 4.22828 11.5312 4.53101C11.5308 4.93693 11.369 5.326 11.082 5.61305C10.795 5.9001 10.406 6.06183 10 6.06226C9.69721 6.06226 9.40119 5.97264 9.14941 5.80445C8.89762 5.63621 8.70086 5.39673 8.58496 5.11695C8.46918 4.83725 8.439 4.52909 8.49805 4.23219C8.55716 3.93526 8.70292 3.6621 8.91699 3.44801C9.13112 3.23391 9.4042 3.08814 9.70117 3.02906Z", { config: i, isFeatureEnabled: n } = O(), { exportHtml: l } = x(), { openVersionHistory: C, closeVersionHistory: p } = B(), { toggleAccessibilityTestingMode: u } = E(), r = w(), m = M(), d = h(), f = c(!1), a = c(!1), A = c(null), y = t(() => n("autosave")), g = t(() => {
16
+ var o, e;
17
+ return !!((e = (o = i.value) == null ? void 0 : o.features) != null && e.versionHistory);
18
+ }), L = t(() => n("accessibilityTesting")), V = t(() => {
19
+ var o, e;
20
+ return !!((e = (o = i.value) == null ? void 0 : o.features) != null && e.saveAsTemplate);
21
+ }), s = () => {
22
+ f.value = !1;
23
+ }, b = () => {
24
+ r.isVersionHistoryOpen ? p() : C(), s();
25
+ }, _ = () => {
26
+ u(), s();
27
+ }, H = () => {
28
+ r.isSaveAsTemplateDrawerOpen = !0, s();
29
+ }, S = async () => {
30
+ a.value = !0, await l(), a.value = !1, s();
31
+ }, T = (o) => {
32
+ m.isOn = o;
33
+ };
34
+ return N(A, s), { __sfc: !0, ACCESSIBILITY_ICON_PATH: v, config: i, isFeatureEnabled: n, exportHtml: l, openVersionHistory: C, closeVersionHistory: p, toggleAccessibilityTestingMode: u, editorStore: r, autosaveStore: m, trans: d, isOpen: f, isExporting: a, root: A, isAutosaveVisible: y, isVersionHistoryVisible: g, isAccessibilityVisible: L, isSaveAsVisible: V, close: s, handleVersionHistory: b, handleAccessibility: _, handleSaveAs: H, handleExport: S, toggleAutosave: T, getTooltipOptions: Z, InButtonV2: F, InIcons: D, InToggle: k };
35
+ }
36
+ });
37
+ export {
38
+ X as default
39
+ };
@@ -1,16 +1,16 @@
1
1
  import o from "./LeftSlot.vue2.js";
2
2
  /* empty css */
3
- import a from "../../../_virtual/_plugin-vue2_normalizer.js";
4
- var n = function() {
3
+ import n from "../../../_virtual/_plugin-vue2_normalizer.js";
4
+ var a = function() {
5
5
  var e = this, s = e._self._c, t = e._self._setupProxy;
6
6
  return s("div", { staticClass: "d-f a-i-c" }, [s(t.InButtonV2, { attrs: { id: "guido__back-button", "left-icon": "line-arrow-left", styling: "ghost", type: "secondary", "disabled-status": t.isBackButtonDisabled, "label-text": t.backButtonLabel, "skeleton-sizing": { width: 150, height: 26 }, "skeleton-status": t.editorStore.loadingStatus }, on: { click: t.handleBackClick } })], 1);
7
- }, i = [], r = /* @__PURE__ */ a(
7
+ }, i = [], r = /* @__PURE__ */ n(
8
8
  o,
9
- n,
9
+ a,
10
10
  i,
11
11
  !1,
12
12
  null,
13
- "73199fa4"
13
+ "2f127fb6"
14
14
  );
15
15
  const f = r.exports;
16
16
  export {
@@ -1,36 +1,41 @@
1
- import { defineComponent as l, computed as p, ref as d } from "vue";
2
- import { useConfig as k } from "../../../composables/useConfig.js";
3
- import { useBack as B } from "../../../composables/useGuidoActions.js";
4
- import { usePreviewMode as b } from "../../../composables/usePreviewMode.js";
5
- import { useTranslations as v } from "../../../composables/useTranslations.js";
1
+ import { defineComponent as p, computed as d, ref as b } from "vue";
2
+ import { useAccessibilityApi as k } from "../../../composables/useAccessibilityApi.js";
3
+ import { useConfig as B } from "../../../composables/useConfig.js";
4
+ import { useBack as v } from "../../../composables/useGuidoActions.js";
5
+ import { usePreviewMode as y } from "../../../composables/usePreviewMode.js";
6
+ import { useTranslations as A } from "../../../composables/useTranslations.js";
6
7
  import { useVersionHistoryApi as _ } from "../../../composables/useVersionHistoryApi.js";
7
- import { useEditorStore as V } from "../../../stores/editor.js";
8
- import { InButtonV2 as w } from "@useinsider/design-system-vue";
9
- import { useDebounceFn as y } from "../../../node_modules/@vueuse/shared/index.js";
10
- const D = /* @__PURE__ */ l({
8
+ import { useEditorStore as g } from "../../../stores/editor.js";
9
+ import { InButtonV2 as O } from "@useinsider/design-system-vue";
10
+ import { useDebounceFn as M } from "../../../node_modules/@vueuse/shared/index.js";
11
+ const F = /* @__PURE__ */ p({
11
12
  __name: "LeftSlot",
12
- setup(C) {
13
- const e = V(), i = B(), { closeVersionHistory: n } = _(), { closePreviewMode: s } = b(), o = v(), { config: t } = k(), f = p(() => {
14
- var u, m;
15
- return e.isVersionHistoryOpen || e.isPreviewModeOpen ? o("email-editor.back-to-editor") : (m = (u = t.value) == null ? void 0 : u.ui) != null && m.backButtonLabel ? t.value.ui.backButtonLabel : o("email-editor.back-to-design");
16
- }), r = d(!1), c = () => {
13
+ setup(V) {
14
+ const e = g(), s = v(), { closeVersionHistory: r } = _(), { closePreviewMode: n } = y(), { closeAccessibilityTestingMode: c } = k(), o = A(), { config: t } = B(), f = d(() => {
15
+ var l, m;
16
+ return e.isVersionHistoryOpen || e.isPreviewModeOpen || e.isAccessibilityTestingOpen ? o("email-editor.back-to-editor") : (m = (l = t.value) == null ? void 0 : l.ui) != null && m.backButtonLabel ? t.value.ui.backButtonLabel : o("email-editor.back-to-design");
17
+ }), i = b(!1), a = () => {
17
18
  if (e.isVersionHistoryOpen) {
18
- n();
19
+ r();
19
20
  return;
20
21
  }
21
22
  if (e.isPreviewModeOpen) {
22
- s();
23
+ n();
24
+ return;
25
+ }
26
+ if (e.isAccessibilityTestingOpen) {
27
+ c();
23
28
  return;
24
29
  }
25
- i();
26
- }, a = y(() => {
27
- c(), r.value = !1;
30
+ s();
31
+ }, u = M(() => {
32
+ a(), i.value = !1;
28
33
  }, 500);
29
- return { __sfc: !0, editorStore: e, handleBack: i, closeVersionHistory: n, closePreviewMode: s, trans: o, config: t, backButtonLabel: f, isBackButtonDisabled: r, executeBackAction: c, debouncedBackAction: a, handleBackClick: () => {
30
- r.value = !0, a();
31
- }, InButtonV2: w };
34
+ return { __sfc: !0, editorStore: e, handleBack: s, closeVersionHistory: r, closePreviewMode: n, closeAccessibilityTestingMode: c, trans: o, config: t, backButtonLabel: f, isBackButtonDisabled: i, executeBackAction: a, debouncedBackAction: u, handleBackClick: () => {
35
+ i.value = !0, u();
36
+ }, InButtonV2: O };
32
37
  }
33
38
  });
34
39
  export {
35
- D as default
40
+ F as default
36
41
  };
@@ -1,8 +1,8 @@
1
1
  import r from "./MiddleSlot.vue2.js";
2
2
  import s from "../../../_virtual/_plugin-vue2_normalizer.js";
3
3
  var t = function() {
4
- var o = this, e = o._self._c, i = o._self._setupProxy;
5
- return e("div", { staticClass: "d-f a-i-c" }, [i.editorStore.isVersionHistoryOpen ? e("div", { staticClass: "d-f" }, [e(i.VersionHistory), e(i.VersionHistoryViewOptions)], 1) : i.editorStore.isPreviewModeOpen ? e("div", { staticClass: "d-f" }, [e(i.EmailSizeIndicator), e(i.AmpToggle)], 1) : o._e(), e(i.EditorToolbar, { directives: [{ name: "show", rawName: "v-show", value: i.editorStore.isEditorToolbarVisible, expression: "editorStore.isEditorToolbarVisible" }] })], 1);
4
+ var o = this, i = o._self._c, e = o._self._setupProxy;
5
+ return i("div", { staticClass: "d-f a-i-c" }, [e.editorStore.isVersionHistoryOpen ? i("div", { staticClass: "d-f" }, [i(e.VersionHistory), i(e.VersionHistoryViewOptions)], 1) : e.editorStore.isPreviewModeOpen ? i("div", { staticClass: "d-f" }, [i(e.EmailSizeIndicator), i(e.AmpToggle)], 1) : e.editorStore.isAccessibilityTestingOpen ? i(e.AccessibilityToolbar) : o._e(), i(e.EditorToolbar, { directives: [{ name: "show", rawName: "v-show", value: e.editorStore.isEditorToolbarVisible, expression: "editorStore.isEditorToolbarVisible" }] })], 1);
6
6
  }, a = [], n = /* @__PURE__ */ s(
7
7
  r,
8
8
  t,
@@ -11,7 +11,7 @@ var t = function() {
11
11
  null,
12
12
  null
13
13
  );
14
- const c = n.exports;
14
+ const _ = n.exports;
15
15
  export {
16
- c as default
16
+ _ as default
17
17
  };
@@ -2,15 +2,16 @@ import { defineComponent as o } from "vue";
2
2
  import r from "../email-preview/amp/AmpToggle.vue.js";
3
3
  import t from "../email-preview/desktop-preview/EmailSizeIndicator.vue.js";
4
4
  import { useEditorStore as i } from "../../../stores/editor.js";
5
- import e from "./EditorToolbar.vue.js";
6
- import m from "./version-history/VersionHistory.vue.js";
7
- import p from "./version-history/ViewOptions.vue.js";
8
- const S = /* @__PURE__ */ o({
5
+ import e from "./accessibility/AccessibilityToolbar.vue.js";
6
+ import m from "./EditorToolbar.vue.js";
7
+ import p from "./version-history/VersionHistory.vue.js";
8
+ import s from "./version-history/ViewOptions.vue.js";
9
+ const y = /* @__PURE__ */ o({
9
10
  __name: "MiddleSlot",
10
- setup(s) {
11
- return { __sfc: !0, editorStore: i(), AmpToggle: r, EmailSizeIndicator: t, EditorToolbar: e, VersionHistory: m, VersionHistoryViewOptions: p };
11
+ setup(f) {
12
+ return { __sfc: !0, editorStore: i(), AmpToggle: r, EmailSizeIndicator: t, AccessibilityToolbar: e, EditorToolbar: m, VersionHistory: p, VersionHistoryViewOptions: s };
12
13
  }
13
14
  });
14
15
  export {
15
- S as default
16
+ y as default
16
17
  };
@@ -1,17 +1,17 @@
1
- import s from "./RightSlot.vue2.js";
1
+ import i from "./RightSlot.vue2.js";
2
2
  import o from "../../../_virtual/_plugin-vue2_normalizer.js";
3
3
  var r = function() {
4
- var i = this, e = i._self._c, t = i._self._setupProxy;
5
- return e("div", { staticClass: "d-f a-i-c" }, [t.editorStore.isVersionHistoryOpen ? i._e() : e(t.AutoSaveToggle), t.isLiquidEnabled && !t.editorStore.isVersionHistoryOpen ? e(t.InChips, { staticClass: "mr-1", attrs: { id: "guido__liquid-tag-chip", styles: "stroke", type: "default", value: "liquid-tags", "close-button": !1, "disabled-status": t.editorStore.loadingStatus, interactive: !1, text: t.trans("email-editor.liquid-tags-enabled") } }) : i._e(), t.editorStore.isVersionHistoryOpen ? e(t.RestoreButton) : e(t.EditorActions, { ref: "editorActionsRef" })], 1);
6
- }, a = [], n = /* @__PURE__ */ o(
7
- s,
4
+ var e = this, s = e._self._c, t = e._self._setupProxy;
5
+ return s("div", { staticClass: "d-f a-i-c" }, [t.isNormalMode ? s(t.AutoSaveStatus) : e._e(), t.isLiquidEnabled && t.isNormalMode ? s(t.InChips, { staticClass: "mr-1", attrs: { id: "guido__liquid-tag-chip", styles: "stroke", type: "default", value: "liquid-tags", "close-button": !1, "disabled-status": t.editorStore.loadingStatus, interactive: !1, text: t.trans("email-editor.liquid-tags-enabled") } }) : e._e(), t.isNormalMode ? s(t.EditorActions, { ref: "editorActionsRef" }) : t.editorStore.isVersionHistoryOpen ? s(t.RestoreButton) : e._e()], 1);
6
+ }, a = [], l = /* @__PURE__ */ o(
7
+ i,
8
8
  r,
9
9
  a,
10
10
  !1,
11
11
  null,
12
12
  null
13
13
  );
14
- const u = n.exports;
14
+ const u = l.exports;
15
15
  export {
16
16
  u as default
17
17
  };
@@ -1,23 +1,25 @@
1
- import { defineComponent as a, ref as f, computed as p } from "vue";
2
- import { useConfig as u } from "../../../composables/useConfig.js";
1
+ import { defineComponent as u, ref as f, computed as r } from "vue";
2
+ import { useConfig as c } from "../../../composables/useConfig.js";
3
3
  import { useTranslations as d } from "../../../composables/useTranslations.js";
4
4
  import { useEditorStore as l } from "../../../stores/editor.js";
5
- import { InChips as c } from "@useinsider/design-system-vue";
6
- import _ from "./AutoSaveToggle.vue.js";
7
- import S from "./EditorActions.vue.js";
8
- import g from "./version-history/RestoreButton.vue.js";
9
- const T = /* @__PURE__ */ a({
5
+ import { InChips as S } from "@useinsider/design-system-vue";
6
+ import _ from "./AutoSaveStatus.vue.js";
7
+ import h from "./EditorActions.vue.js";
8
+ import v from "./version-history/RestoreButton.vue.js";
9
+ const O = /* @__PURE__ */ u({
10
10
  __name: "RightSlot",
11
- setup(h, { expose: r }) {
12
- const { isFeatureEnabled: o } = u(), i = d(), n = l(), t = f(null), s = p(() => o("liquidSyntax"));
13
- return r({
14
- handleSave: (m) => {
15
- var e;
16
- return (e = t.value) == null ? void 0 : e.handleSave(m);
11
+ setup(A, { expose: s }) {
12
+ const { isFeatureEnabled: t } = c(), n = d(), o = l(), e = f(null), m = r(() => t("liquidSyntax")), a = r(
13
+ () => !o.isVersionHistoryOpen && !o.isAccessibilityTestingOpen
14
+ );
15
+ return s({
16
+ handleSave: (p) => {
17
+ var i;
18
+ return (i = e.value) == null ? void 0 : i.handleSave(p);
17
19
  }
18
- }), { __sfc: !0, isFeatureEnabled: o, trans: i, editorStore: n, editorActionsRef: t, isLiquidEnabled: s, InChips: c, AutoSaveToggle: _, EditorActions: S, RestoreButton: g };
20
+ }), { __sfc: !0, isFeatureEnabled: t, trans: n, editorStore: o, editorActionsRef: e, isLiquidEnabled: m, isNormalMode: a, InChips: S, AutoSaveStatus: _, EditorActions: h, RestoreButton: v };
19
21
  }
20
22
  });
21
23
  export {
22
- T as default
24
+ O as default
23
25
  };
@@ -0,0 +1,18 @@
1
+ import o from "./AccessibilityToolbar.vue2.js";
2
+ /* empty css */
3
+ import s from "../../../../_virtual/_plugin-vue2_normalizer.js";
4
+ var a = function() {
5
+ var i = this, e = i._self._c, t = i._self._setupProxy;
6
+ return e("div", { staticClass: "d-f a-i-c accessibility-toolbar" }, [e(t.InButtonV2, { attrs: { id: "guido__a11y-no-images", "data-testid": "Accessibility No Images", "left-icon": "line-image", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.loadingStatus, "label-text-status": !1, "selected-status": t.editorStore.imagesHidden, "tooltip-options": t.getTooltipOptions("guido__a11y-no-images"), "tooltip-text": t.imagesTooltip }, on: { click: t.toggleImages } }), e(t.InButtonV2, { attrs: { id: "guido__a11y-code", "data-testid": "Accessibility Code Editor", "left-icon": "line-code", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.loadingStatus, "label-text-status": !1, "selected-status": t.editorStore.isCodeEditorOpen, "tooltip-options": t.getTooltipOptions("guido__a11y-code"), "tooltip-text": t.trans("newsletter.html-editor") }, on: { click: t.toggleCodeEditor } }), e("div", { staticClass: "accessibility-toolbar__divider" }), e(t.ColorVisionSelect), e(t.InSegments, { staticClass: "ml-2", attrs: { id: "guido__a11y-view-selection", "with-icon": "", "segment-list": t.segmentList, selected: t.editorStore.editorVisualMode }, on: { click: t.handleView } })], 1);
7
+ }, l = [], d = /* @__PURE__ */ s(
8
+ o,
9
+ a,
10
+ l,
11
+ !1,
12
+ null,
13
+ "e222d603"
14
+ );
15
+ const g = d.exports;
16
+ export {
17
+ g as default
18
+ };
@@ -0,0 +1,37 @@
1
+ import { defineComponent as d, computed as n } from "vue";
2
+ import { useAccessibilityApi as c } from "../../../../composables/useAccessibilityApi.js";
3
+ import { useTranslations as g } from "../../../../composables/useTranslations.js";
4
+ import { useEditorStore as u } from "../../../../stores/editor.js";
5
+ import { getTooltipOptions as e } from "../../../../utils/tooltipUtils.js";
6
+ import { InSegments as _, InButtonV2 as f } from "@useinsider/design-system-vue";
7
+ import w from "./ColorVisionSelect.vue.js";
8
+ const A = /* @__PURE__ */ d({
9
+ __name: "AccessibilityToolbar",
10
+ setup(b) {
11
+ const t = u(), o = g(), {
12
+ toggleImages: r,
13
+ toggleCodeEditor: m,
14
+ switchToDesktopPreview: i,
15
+ switchToMobilePreview: s
16
+ } = c(), l = n(() => [
17
+ {
18
+ text: "",
19
+ icon: "line-desktop",
20
+ value: "desktop",
21
+ tooltipText: o("newsletter.desktop"),
22
+ tooltipOptions: e("guido__a11y-view-desktop")
23
+ },
24
+ {
25
+ text: "",
26
+ icon: "line-menu-mobileapp",
27
+ value: "mobile",
28
+ tooltipText: o("newsletter.mobile"),
29
+ tooltipOptions: e("guido__a11y-view-mobile")
30
+ }
31
+ ]), p = n(() => t.imagesHidden ? o("email-editor.a11y-show-images") : o("email-editor.a11y-hide-images"));
32
+ return { __sfc: !0, editorStore: t, trans: o, toggleImages: r, toggleCodeEditor: m, switchToDesktopPreview: i, switchToMobilePreview: s, segmentList: l, imagesTooltip: p, handleView: (a) => a === "mobile" ? s() : i(), getTooltipOptions: e, InButtonV2: f, InSegments: _, ColorVisionSelect: w };
33
+ }
34
+ });
35
+ export {
36
+ A as default
37
+ };