@useinsider/guido 3.18.2-beta.8ef3138 → 3.18.2-beta.9be830c

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 (62) hide show
  1. package/dist/@types/config/schemas.js +15 -13
  2. package/dist/components/Guido.vue.js +7 -7
  3. package/dist/components/Guido.vue2.js +2 -2
  4. package/dist/components/organisms/AutoSaveController.vue2.js +10 -8
  5. package/dist/components/organisms/header/AutoSaveStatus.vue.js +17 -0
  6. package/dist/components/organisms/header/AutoSaveStatus.vue2.js +27 -0
  7. package/dist/components/organisms/header/EditorActions.vue.js +13 -13
  8. package/dist/components/organisms/header/EditorActions.vue2.js +36 -52
  9. package/dist/components/organisms/header/EditorActionsMenu.vue.js +20 -0
  10. package/dist/components/organisms/header/EditorActionsMenu.vue2.js +48 -0
  11. package/dist/components/organisms/header/HeaderWrapper.vue.js +6 -6
  12. package/dist/components/organisms/header/HeaderWrapper.vue2.js +9 -17
  13. package/dist/components/organisms/header/LeftSlot.vue.js +5 -5
  14. package/dist/components/organisms/header/LeftSlot.vue2.js +28 -23
  15. package/dist/components/organisms/header/MiddleSlot.vue.js +4 -4
  16. package/dist/components/organisms/header/MiddleSlot.vue2.js +8 -7
  17. package/dist/components/organisms/header/RightSlot.vue.js +9 -8
  18. package/dist/components/organisms/header/RightSlot.vue2.js +13 -18
  19. package/dist/components/organisms/header/accessibility/AccessibilityToolbar.vue.js +18 -0
  20. package/dist/components/organisms/header/accessibility/AccessibilityToolbar.vue2.js +37 -0
  21. package/dist/components/organisms/header/accessibility/ColorVisionSelect.vue.js +24 -0
  22. package/dist/components/organisms/header/accessibility/ColorVisionSelect.vue2.js +48 -0
  23. package/dist/components/organisms/onboarding/EditorTabBarOnboarding.vue.js +19 -0
  24. package/dist/components/organisms/onboarding/EditorTabBarOnboarding.vue2.js +82 -0
  25. package/dist/components/organisms/onboarding/OnboardingWrapper.vue.js +12 -12
  26. package/dist/components/organisms/onboarding/OnboardingWrapper.vue2.js +54 -36
  27. package/dist/composables/useAccessibilityApi.js +35 -0
  28. package/dist/composables/useCustomInterfaceAppearance.js +31 -28
  29. package/dist/config/i18n/en/labels.json.js +36 -4
  30. package/dist/config/i18n/en/tooltips.json.js +2 -1
  31. package/dist/guido.css +1 -1
  32. package/dist/node_modules/@vueuse/core/index.js +102 -0
  33. package/dist/node_modules/@vueuse/shared/index.js +40 -28
  34. package/dist/sprite.svg +6 -0
  35. package/dist/src/@types/config/schemas.d.ts +4 -0
  36. package/dist/src/components/organisms/AutoSaveController.vue.d.ts +3 -1
  37. package/dist/src/components/organisms/header/EditorActionsMenu.vue.d.ts +2 -0
  38. package/dist/src/components/organisms/header/HeaderWrapper.vue.d.ts +1 -3
  39. package/dist/src/components/organisms/header/RightSlot.vue.d.ts +1 -3
  40. package/dist/src/components/organisms/header/accessibility/AccessibilityToolbar.vue.d.ts +2 -0
  41. package/dist/src/components/organisms/header/accessibility/ColorVisionSelect.vue.d.ts +2 -0
  42. package/dist/src/components/organisms/onboarding/EditorTabBarOnboarding.vue.d.ts +2 -0
  43. package/dist/src/composables/useAccessibilityApi.d.ts +15 -0
  44. package/dist/src/composables/useActionsApi.d.ts +2 -2
  45. package/dist/src/composables/useConfig.d.ts +2 -0
  46. package/dist/src/stores/config.d.ts +18 -0
  47. package/dist/src/stores/editor.d.ts +107 -0
  48. package/dist/src/stores/onboarding.d.ts +552 -1
  49. package/dist/src/stores/version-history.d.ts +1 -1
  50. package/dist/src/utils/liquidDynamicContent.d.ts +20 -0
  51. package/dist/src/utils/timeUtil.d.ts +10 -0
  52. package/dist/static/styles/components/accessibility.css.js +282 -0
  53. package/dist/static/styles/variables.css.js +2 -0
  54. package/dist/stores/editor.js +13 -4
  55. package/dist/stores/onboarding.js +39 -18
  56. package/dist/utils/genericUtil.js +64 -61
  57. package/dist/utils/liquidDynamicContent.js +15 -0
  58. package/dist/utils/timeUtil.js +7 -17
  59. package/package.json +1 -1
  60. package/dist/components/organisms/header/AutoSaveToggle.vue.js +0 -22
  61. package/dist/components/organisms/header/AutoSaveToggle.vue2.js +0 -19
  62. /package/dist/src/components/organisms/header/{AutoSaveToggle.vue.d.ts → AutoSaveStatus.vue.d.ts} +0 -0
@@ -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,18 @@
1
- import s from "./RightSlot.vue2.js";
1
+ import i from "./RightSlot.vue2.js";
2
+ /* empty css */
2
3
  import o from "../../../_virtual/_plugin-vue2_normalizer.js";
3
4
  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,
5
+ var e = this, s = e._self._c, t = e._self._setupProxy;
6
+ return s("div", { staticClass: "d-f a-i-c right-slot" }, [t.isNormalMode ? s(t.AutoSaveStatus) : e._e(), t.isLiquidEnabled && t.isNormalMode ? s(t.InChips, { 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) : t.editorStore.isVersionHistoryOpen ? s(t.RestoreButton) : e._e()], 1);
7
+ }, a = [], l = /* @__PURE__ */ o(
8
+ i,
8
9
  r,
9
10
  a,
10
11
  !1,
11
12
  null,
12
- null
13
+ "efc32e0d"
13
14
  );
14
- const u = n.exports;
15
+ const c = l.exports;
15
16
  export {
16
- u as default
17
+ c as default
17
18
  };
@@ -1,23 +1,18 @@
1
- import { defineComponent as a, ref as f, computed as p } from "vue";
2
- import { useConfig as u } from "../../../composables/useConfig.js";
3
- import { useTranslations as d } from "../../../composables/useTranslations.js";
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({
1
+ import { defineComponent as m, computed as r } from "vue";
2
+ import { useConfig as n } from "../../../composables/useConfig.js";
3
+ import { useTranslations as a } from "../../../composables/useTranslations.js";
4
+ import { useEditorStore as p } from "../../../stores/editor.js";
5
+ import { InChips as u } from "@useinsider/design-system-vue";
6
+ import f from "./AutoSaveStatus.vue.js";
7
+ import d from "./EditorActions.vue.js";
8
+ import c from "./version-history/RestoreButton.vue.js";
9
+ const x = /* @__PURE__ */ m({
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);
17
- }
18
- }), { __sfc: !0, isFeatureEnabled: o, trans: i, editorStore: n, editorActionsRef: t, isLiquidEnabled: s, InChips: c, AutoSaveToggle: _, EditorActions: S, RestoreButton: g };
11
+ setup(l) {
12
+ const { isFeatureEnabled: o } = n(), i = a(), t = p(), e = r(() => o("liquidSyntax")), s = r(() => t.isNormalMode);
13
+ return { __sfc: !0, isFeatureEnabled: o, trans: i, editorStore: t, isLiquidEnabled: e, isNormalMode: s, InChips: u, AutoSaveStatus: f, EditorActions: d, RestoreButton: c };
19
14
  }
20
15
  });
21
16
  export {
22
- T as default
17
+ x as default
23
18
  };
@@ -0,0 +1,18 @@
1
+ import i from "./AccessibilityToolbar.vue2.js";
2
+ /* empty css */
3
+ import s from "../../../../_virtual/_plugin-vue2_normalizer.js";
4
+ var a = function() {
5
+ var o = this, e = o._self._c, t = o._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(t.ColorVisionSelect), e(t.InSegments, { 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
+ i,
9
+ a,
10
+ l,
11
+ !1,
12
+ null,
13
+ "a5b9b5d5"
14
+ );
15
+ const _ = d.exports;
16
+ export {
17
+ _ 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
+ };
@@ -0,0 +1,24 @@
1
+ import n from "./ColorVisionSelect.vue2.js";
2
+ /* empty css */
3
+ import i from "../../../../_virtual/_plugin-vue2_normalizer.js";
4
+ var l = function() {
5
+ var t = this, o = t._self._c, e = t._self._setupProxy;
6
+ return o("div", { ref: "root", staticClass: "color-vision-select p-r" }, [o(e.InButtonV2, { attrs: { id: "guido__a11y-color-vision-trigger", "left-icon": "line-show-on", "right-icon": "line-chevron-small-down", type: "secondary", "disabled-status": e.editorStore.loadingStatus, "label-text": e.selectedLabel }, on: { click: function(s) {
7
+ e.isOpen = !e.isOpen;
8
+ } } }), e.isOpen ? o("div", { staticClass: "color-vision-select__menu p-a" }, t._l(e.OPTIONS, function(s) {
9
+ return o("button", { key: s.value || "none", staticClass: "color-vision-select__option d-f f-d-c", class: { "color-vision-select__option_selected": s.value === e.editorStore.colorVisionDeficiency }, attrs: { type: "button" }, on: { click: function(_) {
10
+ return e.select(s.value);
11
+ } } }, [o("span", { staticClass: "color-vision-select__option-label f-s-2" }, [t._v(t._s(e.trans(s.labelKey)))]), s.descriptionKey ? o("span", { staticClass: "color-vision-select__option-description f-s-1 t-c-53" }, [t._v(" " + t._s(e.trans(s.descriptionKey)) + " ")]) : t._e()]);
12
+ }), 0) : t._e()], 1);
13
+ }, r = [], c = /* @__PURE__ */ i(
14
+ n,
15
+ l,
16
+ r,
17
+ !1,
18
+ null,
19
+ "869e2871"
20
+ );
21
+ const f = c.exports;
22
+ export {
23
+ f as default
24
+ };
@@ -0,0 +1,48 @@
1
+ import { defineComponent as p, ref as c, computed as m } from "vue";
2
+ import { useAccessibilityApi as u } from "../../../../composables/useAccessibilityApi.js";
3
+ import { useTranslations as v } from "../../../../composables/useTranslations.js";
4
+ import { useEditorStore as f } from "../../../../stores/editor.js";
5
+ import { InButtonV2 as y } from "@useinsider/design-system-vue";
6
+ import { onClickOutside as K } from "../../../../node_modules/@vueuse/core/index.js";
7
+ const A = /* @__PURE__ */ p({
8
+ __name: "ColorVisionSelect",
9
+ setup(b) {
10
+ const e = [
11
+ {
12
+ value: "",
13
+ labelKey: "email-editor.cvd-none"
14
+ },
15
+ {
16
+ value: "protanopia",
17
+ labelKey: "email-editor.cvd-protanopia",
18
+ descriptionKey: "email-editor.cvd-protanopia-description"
19
+ },
20
+ {
21
+ value: "deuteranopia",
22
+ labelKey: "email-editor.cvd-deuteranopia",
23
+ descriptionKey: "email-editor.cvd-deuteranopia-description"
24
+ },
25
+ {
26
+ value: "tritanopia",
27
+ labelKey: "email-editor.cvd-tritanopia",
28
+ descriptionKey: "email-editor.cvd-tritanopia-description"
29
+ },
30
+ {
31
+ value: "achromatopsia",
32
+ labelKey: "email-editor.cvd-achromatopsia",
33
+ descriptionKey: "email-editor.cvd-achromatopsia-description"
34
+ }
35
+ ], t = f(), a = v(), { setColorVisionDeficiency: r } = u(), o = c(!1), n = c(null), l = m(() => {
36
+ const i = e.find((d) => d.value === t.colorVisionDeficiency) ?? e[0];
37
+ return a(i.labelKey);
38
+ }), s = (i) => {
39
+ r(i), o.value = !1;
40
+ };
41
+ return K(n, () => {
42
+ o.value = !1;
43
+ }), { __sfc: !0, OPTIONS: e, editorStore: t, trans: a, setColorVisionDeficiency: r, isOpen: o, root: n, selectedLabel: l, select: s, InButtonV2: y };
44
+ }
45
+ });
46
+ export {
47
+ A as default
48
+ };
@@ -0,0 +1,19 @@
1
+ import e from "./EditorTabBarOnboarding.vue2.js";
2
+ /* empty css */
3
+ import i from "../../../_virtual/_plugin-vue2_normalizer.js";
4
+ var s = function() {
5
+ var r, n;
6
+ var t = this, a = t._self._c, o = t._self._setupProxy;
7
+ return o.isVisible ? a(o.InOnboard, { key: "guido__tab-bar-onboard", staticClass: "w-21-s p-a z-11", class: (r = o.onboardingStore.getEditorTabBarCurrentCard) == null ? void 0 : r.classes, attrs: { id: o.CARD_ID, "is-multiple-page": "", visible: "", "image-source": "", title: "", "pages-config": o.onboardingStore.onboardings.editorTabBarOnboarding.config, "pointer-position": (n = o.onboardingStore.getEditorTabBarCurrentCard) == null ? void 0 : n.position, "right-position": o.placement.right, "top-position": o.placement.top }, on: { backButtonClick: o.handleBack, close: o.finish, nextButtonClick: o.handleNext } }) : t._e();
8
+ }, c = [], d = /* @__PURE__ */ i(
9
+ e,
10
+ s,
11
+ c,
12
+ !1,
13
+ null,
14
+ "af34c57a"
15
+ );
16
+ const g = d.exports;
17
+ export {
18
+ g as default
19
+ };
@@ -0,0 +1,82 @@
1
+ import { defineComponent as I, ref as q, computed as w, watch as E, nextTick as R } from "vue";
2
+ import { useConfig as P } from "../../../composables/useConfig.js";
3
+ import { useRibbonOffset as D } from "../../../composables/useRibbonOffset.js";
4
+ import { useTranslations as M } from "../../../composables/useTranslations.js";
5
+ import { useOnboardingStore as F } from "../../../stores/onboarding.js";
6
+ import { InOnboard as G } from "@useinsider/design-system-vue";
7
+ const J = /* @__PURE__ */ I({
8
+ __name: "EditorTabBarOnboarding",
9
+ setup($) {
10
+ const i = "editorTabBarOnboarding", l = "guido__tab-bar-onboard", n = M(), o = F(), { isFeatureEnabled: p } = P(), { getTopPosition: m } = D(), B = () => o.next(i), x = () => o.previous(i), k = () => void o.close(i), f = 4, T = 17, a = "#guido__kebab-button", s = ".editor-actions-menu__panel", r = (t, e, d) => ({
11
+ classes: "guido-tab-bar-onboarding",
12
+ position: "Right Top",
13
+ title: n(t),
14
+ description: n(e),
15
+ imageSource: "",
16
+ backButtonType: "text",
17
+ backButtonText: n("action-builder.back"),
18
+ backButtonClick: x,
19
+ nextButtonType: "text",
20
+ nextButtonText: n("action-builder.next"),
21
+ nextButtonClick: B,
22
+ ...d
23
+ }), _ = () => p("autosave") ? [{
24
+ card: r("email-editor.onboarding-autosave-title", "email-editor.onboarding-autosave-description", {}),
25
+ edge: s,
26
+ target: "#guido__kebab-autosave"
27
+ }] : [], C = () => [
28
+ {
29
+ card: r("email-editor.onboarding-kebab-title", "email-editor.onboarding-kebab-description", {
30
+ backButtonType: void 0,
31
+ backButtonText: void 0,
32
+ backButtonClick: () => {
33
+ }
34
+ }),
35
+ edge: a,
36
+ target: a
37
+ },
38
+ ..._(),
39
+ {
40
+ card: r("email-editor.onboarding-accessibility-title", "email-editor.onboarding-accessibility-description", {
41
+ nextButtonText: n("action-builder.ok"),
42
+ nextButtonClick: k
43
+ }),
44
+ edge: s,
45
+ target: "#guido__kebab-accessibility"
46
+ }
47
+ ], b = () => ({ top: m(56), right: "150px" });
48
+ let c = [];
49
+ const u = q(b()), g = async () => {
50
+ var y;
51
+ await R();
52
+ const t = c[o.onboardings.editorTabBarOnboarding.cardIndex], e = (y = document.getElementById(l)) == null ? void 0 : y.offsetParent, d = (t && document.querySelector(t.edge)) ?? document.querySelector(a), O = (t && document.querySelector(t.target)) ?? document.querySelector(a);
53
+ if (!e || !d || !O) {
54
+ u.value = b();
55
+ return;
56
+ }
57
+ const h = e.getBoundingClientRect(), v = O.getBoundingClientRect();
58
+ u.value = {
59
+ top: `${Math.round(v.top + v.height / 2 - h.top - T)}px`,
60
+ right: `${Math.round(h.right - d.getBoundingClientRect().left - f)}px`
61
+ };
62
+ }, S = w(
63
+ () => o.onboardings.editorTabBarOnboarding.config.length > 0 && o.onboardings.editorTabBarOnboarding.isActive
64
+ ), N = () => {
65
+ var t, e;
66
+ (e = (t = o.getEditorTabBarCurrentCard) == null ? void 0 : t.nextButtonClick) == null || e.call(t);
67
+ }, A = () => {
68
+ var t, e;
69
+ (e = (t = o.getEditorTabBarCurrentCard) == null ? void 0 : t.backButtonClick) == null || e.call(t);
70
+ };
71
+ return E(
72
+ () => o.onboardings.editorTabBarOnboarding.isActive,
73
+ async (t) => {
74
+ t && (await R(), c = C(), o.setConfig(i, c.map((e) => e.card)), await g());
75
+ },
76
+ { immediate: !0 }
77
+ ), E(() => o.onboardings.editorTabBarOnboarding.cardIndex, g), { __sfc: !0, ONBOARDING: i, CARD_ID: l, trans: n, onboardingStore: o, isFeatureEnabled: p, getTopPosition: m, goNext: B, goBack: x, finish: k, ANCHOR_GAP: f, POINTER_CENTER: T, KEBAB: a, MENU: s, card: r, autoSaveStep: _, buildSteps: C, designFallback: b, steps: c, placement: u, place: g, isVisible: S, handleNext: N, handleBack: A, InOnboard: G };
78
+ }
79
+ });
80
+ export {
81
+ J as default
82
+ };
@@ -1,21 +1,21 @@
1
- import t from "./OnboardingWrapper.vue2.js";
2
- import i from "../../../_virtual/_plugin-vue2_normalizer.js";
3
- var s = function() {
4
- var n = this, e = n._self._c, r = n._self._setupProxy;
5
- return e("div", n._l(r.visibleOnboardings, function(o) {
6
- return e(o.component, { key: o.type, tag: "component", on: { "onboarding-finished": function(p) {
7
- return r.emit("onboarding-finished");
1
+ import o from "./OnboardingWrapper.vue2.js";
2
+ import s from "../../../_virtual/_plugin-vue2_normalizer.js";
3
+ var _ = function() {
4
+ var n = this, r = n._self._c, t = n._self._setupProxy;
5
+ return r("div", n._l(t.visibleOnboardings, function(e) {
6
+ return r(e.component, { key: e.type, tag: "component", on: { "onboarding-finished": function(l) {
7
+ return t.handleFinished(e.type);
8
8
  } } });
9
9
  }), 1);
10
- }, _ = [], a = /* @__PURE__ */ i(
11
- t,
12
- s,
10
+ }, i = [], a = /* @__PURE__ */ s(
11
+ o,
13
12
  _,
13
+ i,
14
14
  !1,
15
15
  null,
16
16
  null
17
17
  );
18
- const d = a.exports;
18
+ const f = a.exports;
19
19
  export {
20
- d as default
20
+ f as default
21
21
  };
@@ -1,46 +1,64 @@
1
- import { defineComponent as b, computed as e, onMounted as O, watch as t } from "vue";
2
- import u from "./AMPOnboarding.vue.js";
3
- import v from "./GenericOnboarding.vue.js";
4
- import l from "./ItemsOnboarding.vue.js";
5
- import y from "./NewVersionPopup.vue.js";
6
- import S from "./TextBlockOnboarding.vue.js";
7
- import h from "./VersionHistoryOnboarding.vue.js";
8
- import { usePartner as w } from "../../../composables/usePartner.js";
9
- import { useEditorStore as P } from "../../../stores/editor.js";
10
- import { useOnboardingStore as _ } from "../../../stores/onboarding.js";
11
- import { usePreviewStore as A } from "../../../stores/preview.js";
12
- const G = /* @__PURE__ */ b({
1
+ import { defineComponent as h, computed as r, onMounted as w, watch as e, ref as S } from "vue";
2
+ import T from "./AMPOnboarding.vue.js";
3
+ import y from "./EditorTabBarOnboarding.vue.js";
4
+ import P from "./GenericOnboarding.vue.js";
5
+ import B from "./ItemsOnboarding.vue.js";
6
+ import A from "./NewVersionPopup.vue.js";
7
+ import M from "./TextBlockOnboarding.vue.js";
8
+ import _ from "./VersionHistoryOnboarding.vue.js";
9
+ import { useConfig as H } from "../../../composables/useConfig.js";
10
+ import { usePartner as V } from "../../../composables/usePartner.js";
11
+ import { useEditorStore as C } from "../../../stores/editor.js";
12
+ import { useOnboardingStore as F } from "../../../stores/onboarding.js";
13
+ import { usePreviewStore as x } from "../../../stores/preview.js";
14
+ const L = /* @__PURE__ */ h({
13
15
  __name: "OnboardingWrapper",
14
16
  emits: ["onboarding-finished"],
15
- setup(H, { emit: f }) {
16
- const o = _(), r = P(), s = A(), { isTestPartner: a } = w(), p = e(() => r.isStripoInitialized), d = e(() => a()), m = [
17
- { type: "newVersionPopup", component: y },
18
- { type: "genericOnboarding", component: v },
19
- { type: "textBlockOnboarding", component: S },
20
- { type: "versionHistoryOnboarding", component: h },
21
- { type: "ampOnboarding", component: u },
22
- { type: "itemsOnboarding", component: l }
23
- ], c = (n) => d.value || !p.value ? !1 : n === "newVersionPopup" ? o.shouldShowOnboarding(n) : o.isActive(n), g = e(() => m.filter((n) => c(n.type)));
24
- return O(async () => {
17
+ setup(E, { emit: b }) {
18
+ const o = F(), n = C(), c = x(), { isTestPartner: m } = V(), { isFeatureEnabled: g } = H(), a = r(() => n.isStripoInitialized), s = r(() => m()), f = [
19
+ { type: "newVersionPopup", component: A },
20
+ { type: "genericOnboarding", component: P },
21
+ { type: "textBlockOnboarding", component: M },
22
+ { type: "versionHistoryOnboarding", component: _ },
23
+ { type: "ampOnboarding", component: T },
24
+ { type: "itemsOnboarding", component: B },
25
+ { type: "editorTabBarOnboarding", component: y }
26
+ ], O = (i) => s.value || !a.value ? !1 : i === "newVersionPopup" ? o.shouldShowOnboarding(i) : o.isActive(i), l = r(() => f.filter((i) => O(i.type)));
27
+ w(async () => {
25
28
  await o.fetchUserModalState();
26
- }), t(
27
- () => r.isVersionHistoryOpen,
28
- (n, i) => {
29
- n && !i && o.shouldShowOnboarding("versionHistoryOnboarding") && o.start("versionHistoryOnboarding"), !n && i && o.isActive("versionHistoryOnboarding") && o.close("versionHistoryOnboarding");
29
+ }), e(
30
+ () => n.isVersionHistoryOpen,
31
+ (i, t) => {
32
+ i && !t && (o.isActive("editorTabBarOnboarding") && o.close("editorTabBarOnboarding"), o.shouldShowOnboarding("versionHistoryOnboarding") && o.start("versionHistoryOnboarding")), !i && t && o.isActive("versionHistoryOnboarding") && o.close("versionHistoryOnboarding");
30
33
  }
31
- ), t(
32
- () => s.emailFormat,
33
- (n, i) => {
34
- i !== "AMP" && n === "AMP" && o.shouldShowOnboarding("ampOnboarding") && o.start("ampOnboarding");
34
+ ), e(
35
+ () => c.emailFormat,
36
+ (i, t) => {
37
+ t !== "AMP" && i === "AMP" && o.shouldShowOnboarding("ampOnboarding") && o.start("ampOnboarding");
35
38
  }
36
- ), t(
37
- () => r.isPreviewModeOpen,
38
- (n) => {
39
- !n && o.isActive("ampOnboarding") && o.close("ampOnboarding");
39
+ ), e(
40
+ () => n.isPreviewModeOpen,
41
+ (i) => {
42
+ !i && o.isActive("ampOnboarding") && o.close("ampOnboarding");
40
43
  }
41
- ), { __sfc: !0, emit: f, onboardingStore: o, editorStore: r, previewStore: s, isTestPartner: a, isStripoReady: p, isTestPartnerActive: d, onboardingConfigs: m, shouldShow: c, visibleOnboardings: g };
44
+ );
45
+ const d = S(!1), v = (i) => {
46
+ i === "newVersionPopup" && (d.value = !0), b("onboarding-finished");
47
+ }, p = r(() => n.isNormalMode && !n.isPreviewModeOpen), u = r(() => a.value && o.isFetched && g("accessibilityTesting") && !s.value && p.value && !(o.shouldShowOnboarding("newVersionPopup") && !d.value) && !o.isOnboardingActive() && !o.closedThisSession.includes("editorTabBarOnboarding") && o.shouldShowOnboarding("editorTabBarOnboarding"));
48
+ return e(
49
+ u,
50
+ (i) => {
51
+ i && o.start("editorTabBarOnboarding");
52
+ },
53
+ { immediate: !0 }
54
+ ), e(
55
+ p,
56
+ (i) => {
57
+ !i && o.isActive("editorTabBarOnboarding") && o.close("editorTabBarOnboarding");
58
+ }
59
+ ), { __sfc: !0, emit: b, onboardingStore: o, editorStore: n, previewStore: c, isTestPartner: m, isFeatureEnabled: g, isStripoReady: a, isTestPartnerActive: s, onboardingConfigs: f, shouldShow: O, visibleOnboardings: l, isNewVersionPopupClosed: d, handleFinished: v, isTourAnchored: p, canStartTabBarTour: u };
42
60
  }
43
61
  });
44
62
  export {
45
- G as default
63
+ L as default
46
64
  };
@@ -0,0 +1,35 @@
1
+ import { useEditorStore as r } from "../stores/editor.js";
2
+ const A = () => {
3
+ const e = r(), i = () => window.StripoEditorApi.accessibilityApi, s = () => {
4
+ i().openAccessibilityTestingMode(), e.isAccessibilityTestingOpen = !0;
5
+ }, o = () => {
6
+ try {
7
+ i().closeAccessibilityTestingMode();
8
+ } finally {
9
+ e.isAccessibilityTestingOpen = !1, e.imagesHidden = !1, e.colorVisionDeficiency = "";
10
+ }
11
+ }, l = () => e.isAccessibilityTestingOpen ? o() : s(), g = () => i().isAccessibilityTestingModeOpen(), t = () => {
12
+ i().showImages(), e.imagesHidden = !1;
13
+ }, c = () => {
14
+ i().hideImages(), e.imagesHidden = !0;
15
+ };
16
+ return {
17
+ openAccessibilityTestingMode: s,
18
+ closeAccessibilityTestingMode: o,
19
+ toggleAccessibilityTestingMode: l,
20
+ isAccessibilityTestingModeOpen: g,
21
+ showImages: t,
22
+ hideImages: c,
23
+ toggleImages: () => e.imagesHidden ? t() : c(),
24
+ setColorVisionDeficiency: (n) => {
25
+ i().setColorVisionDeficiency(n), e.colorVisionDeficiency = n;
26
+ },
27
+ getColorVisionDeficiency: () => i().getColorVisionDeficiency(),
28
+ switchToDesktopPreview: () => i().switchToDesktopPreview(),
29
+ switchToMobilePreview: () => i().switchToMobilePreview(),
30
+ toggleCodeEditor: () => i().emitToggleCodeEditor()
31
+ };
32
+ };
33
+ export {
34
+ A as useAccessibilityApi
35
+ };
@@ -2,60 +2,63 @@ import S from "../static/assets/icons/line-change.svg.js";
2
2
  import i from "../static/assets/icons/line-delete.svg.js";
3
3
  import n from "../static/assets/icons/line-plus.svg.js";
4
4
  import p from "../static/styles/base.css.js";
5
- import s from "../static/styles/components/alert-message.css.js";
6
- import C from "../static/styles/components/amp-block.css.js";
7
- import a from "../static/styles/components/base-input.css.js";
8
- import f from "../static/styles/components/button-group.css.js";
9
- import c from "../static/styles/components/button.css.js";
10
- import u from "../static/styles/components/combobox.css.js";
11
- import l from "../static/styles/components/counter.css.js";
12
- import d from "../static/styles/components/dropdown-menu.css.js";
13
- import h from "../static/styles/components/loader.css.js";
14
- import g from "../static/styles/components/narrow-panel.css.js";
5
+ import s from "../static/styles/components/accessibility.css.js";
6
+ import C from "../static/styles/components/alert-message.css.js";
7
+ import c from "../static/styles/components/amp-block.css.js";
8
+ import f from "../static/styles/components/base-input.css.js";
9
+ import a from "../static/styles/components/button-group.css.js";
10
+ import u from "../static/styles/components/button.css.js";
11
+ import l from "../static/styles/components/combobox.css.js";
12
+ import d from "../static/styles/components/counter.css.js";
13
+ import h from "../static/styles/components/dropdown-menu.css.js";
14
+ import g from "../static/styles/components/loader.css.js";
15
+ import y from "../static/styles/components/narrow-panel.css.js";
15
16
  import I from "../static/styles/components/popup.css.js";
16
- import w from "../static/styles/components/recommendation-strategy.css.js";
17
- import y from "../static/styles/components/switcher.css.js";
18
- import b from "../static/styles/components/tabs.css.js";
19
- import B from "../static/styles/components/tools.css.js";
20
- import $ from "../static/styles/components/version-history.css.js";
17
+ import b from "../static/styles/components/recommendation-strategy.css.js";
18
+ import w from "../static/styles/components/switcher.css.js";
19
+ import B from "../static/styles/components/tabs.css.js";
20
+ import $ from "../static/styles/components/tools.css.js";
21
+ import A from "../static/styles/components/version-history.css.js";
21
22
  import P from "../static/styles/components/wide-panel.css.js";
22
23
  import x from "../static/styles/variables.css.js";
23
24
  function r(t, o) {
24
25
  return `--guido-icon-${t}: url("data:image/svg+xml,${encodeURIComponent(o.trim())}");`;
25
26
  }
26
- const A = `:host {
27
+ const R = `:host {
27
28
  ${r("line-change", S)}
28
29
  ${r("line-delete", i)}
29
30
  ${r("line-plus", n)}
30
- }`, R = [
31
+ }`, V = [
31
32
  x,
32
33
  // Must be on top
33
- A,
34
+ R,
34
35
  p,
35
36
  // Must be on top
36
- s,
37
37
  C,
38
- a,
39
- f,
40
38
  c,
39
+ f,
40
+ a,
41
41
  u,
42
42
  l,
43
43
  d,
44
44
  h,
45
45
  g,
46
- I,
47
46
  y,
48
- b,
47
+ I,
48
+ w,
49
49
  B,
50
50
  $,
51
+ A,
51
52
  P,
52
- w
53
- // Last: overrides button.css / wide-panel.css defaults
53
+ b,
54
+ // Overrides button.css / wide-panel.css defaults
55
+ s
56
+ // Last: overrides button.css / tabs.css / tools.css defaults
54
57
  ].join(`
55
58
 
56
- `), Y = () => ({ importCss: () => {
59
+ `), _ = () => ({ importCss: () => {
57
60
  const o = new CSSStyleSheet();
58
- o.replaceSync(R);
61
+ o.replaceSync(V);
59
62
  const e = document.querySelector("ui-editor");
60
63
  if (!e)
61
64
  return;
@@ -63,5 +66,5 @@ const A = `:host {
63
66
  m && (m.adoptedStyleSheets = [o]);
64
67
  } });
65
68
  export {
66
- Y as useCustomInterfaceAppearance
69
+ _ as useCustomInterfaceAppearance
67
70
  };