@useinsider/guido 1.0.2-beta.85ea6e2 → 1.0.2-beta.86f7e79
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Guido.vue.js +2 -2
- package/dist/components/Guido.vue2.js +36 -36
- package/dist/components/organisms/email-preview/amp/AmpToggle.vue2.js +14 -15
- package/dist/components/organisms/header/ViewOptions.vue.js +5 -5
- package/dist/components/organisms/header/ViewOptions.vue2.js +5 -5
- package/dist/components/organisms/header/version-history/ViewOptions.vue.js +5 -5
- package/dist/components/organisms/header/version-history/ViewOptions.vue2.js +5 -5
- package/dist/components/organisms/onboarding/GenericOnboarding.vue.js +5 -5
- package/dist/components/organisms/onboarding/GenericOnboarding.vue2.js +1 -1
- package/dist/components/organisms/onboarding/OnboardingWrapper.vue2.js +25 -20
- package/dist/composables/usePreviewMode.js +14 -15
- package/dist/guido.css +1 -1
- package/dist/stores/onboarding.d.ts +72 -8
- package/dist/stores/preview.js +1 -3
- package/package.json +4 -2
|
@@ -3,14 +3,14 @@ import a from "./Guido.vue2.js";
|
|
|
3
3
|
import i from "../_virtual/_plugin-vue2_normalizer.js";
|
|
4
4
|
var t = function() {
|
|
5
5
|
var o = this, r = o._self._c, e = o._self._setupProxy;
|
|
6
|
-
return r("div", { staticClass: "guido-editor__wrapper", class: { "guido-editor__no-header": e.noHeader } }, [r(e.HeaderWrapper), e.editorStore.isPreviewModeOpen ? r(e.PreviewContainer) : o._e(), r("div", { directives: [{ name: "show", rawName: "v-show", value: !e.previewStore.isLoaded, expression: "!previewStore.isLoaded" }], staticClass: "guido-editor__container", class: { "guido-editor__no-header": e.noHeader }, attrs: { id: "guido-editor" } }), r(e.Toaster), r(e.SaveAsTemplateDrawer), r(e.OnboardingWrapper), r(e.LoadingWrapper)], 1);
|
|
6
|
+
return r("div", { staticClass: "guido-editor__wrapper", class: { "guido-editor__no-header": e.noHeader } }, [r(e.HeaderWrapper), e.editorStore.isPreviewModeOpen ? r(e.PreviewContainer) : o._e(), r("div", { directives: [{ name: "show", rawName: "v-show", value: !e.previewStore.isLoaded, expression: "!previewStore.isLoaded" }], staticClass: "guido-editor__container", class: { "guido-editor__no-header": e.noHeader }, attrs: { id: "guido-editor" } }), r(e.Toaster), r(e.SaveAsTemplateDrawer), e.isTestPartner() ? o._e() : r(e.OnboardingWrapper), r(e.LoadingWrapper)], 1);
|
|
7
7
|
}, s = [], d = /* @__PURE__ */ i(
|
|
8
8
|
a,
|
|
9
9
|
t,
|
|
10
10
|
s,
|
|
11
11
|
!1,
|
|
12
12
|
null,
|
|
13
|
-
"
|
|
13
|
+
"39783038"
|
|
14
14
|
);
|
|
15
15
|
const v = d.exports;
|
|
16
16
|
export {
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { provideGuidoActions as
|
|
3
|
-
import { usePartner as
|
|
4
|
-
import { useStripo as
|
|
5
|
-
import { DefaultUsername as
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import { useStripoApi as
|
|
11
|
-
import { useDynamicContentStore as
|
|
12
|
-
import { useEditorStore as
|
|
13
|
-
import { usePreviewStore as
|
|
14
|
-
import
|
|
15
|
-
const
|
|
1
|
+
import { defineComponent as A, defineAsyncComponent as b, computed as T, watch as W, onMounted as H, onUnmounted as N } from "vue";
|
|
2
|
+
import { provideGuidoActions as U } from "../composables/useGuidoActions.js";
|
|
3
|
+
import { usePartner as x } from "../composables/usePartner.js";
|
|
4
|
+
import { useStripo as M } from "../composables/useStripo.js";
|
|
5
|
+
import { DefaultUsername as z, DefaultMessageType as B, DefaultGuidoConfig as F } from "../enums/defaults.js";
|
|
6
|
+
import K from "./organisms/base/Toaster.vue.js";
|
|
7
|
+
import O from "./organisms/header/HeaderWrapper.vue.js";
|
|
8
|
+
import R from "./organisms/LoadingWrapper.vue.js";
|
|
9
|
+
import j from "./organisms/save-as-template/SaveAsTemplateDrawer.vue.js";
|
|
10
|
+
import { useStripoApi as q } from "../services/stripoApi.js";
|
|
11
|
+
import { useDynamicContentStore as J } from "../stores/dynamic-content.js";
|
|
12
|
+
import { useEditorStore as Q } from "../stores/editor.js";
|
|
13
|
+
import { usePreviewStore as V } from "../stores/preview.js";
|
|
14
|
+
import X from "../node_modules/lodash-es/merge.js";
|
|
15
|
+
const le = /* @__PURE__ */ A({
|
|
16
16
|
__name: "Guido",
|
|
17
17
|
props: {
|
|
18
18
|
templateId: null,
|
|
@@ -27,12 +27,12 @@ const de = /* @__PURE__ */ k({
|
|
|
27
27
|
guidoConfig: null
|
|
28
28
|
},
|
|
29
29
|
emits: ["dynamic-content:open", "back", "save:start", "save:complete", "on-change"],
|
|
30
|
-
setup(
|
|
31
|
-
const
|
|
30
|
+
setup(E, { expose: G, emit: t }) {
|
|
31
|
+
const o = E, P = b(
|
|
32
32
|
() => import("./organisms/email-preview/PreviewContainer.vue.js")
|
|
33
|
-
),
|
|
33
|
+
), I = b(
|
|
34
34
|
() => import("./organisms/onboarding/OnboardingWrapper.vue.js")
|
|
35
|
-
), n =
|
|
35
|
+
), n = J(), c = Q(), L = V(), r = T(() => c.hasChanges), a = o.preselectedDynamicContentList || [], { getPartnerName: m, getProductType: d, isTestPartner: _ } = x(), {
|
|
36
36
|
templateId: l,
|
|
37
37
|
userId: p,
|
|
38
38
|
guidoConfig: u,
|
|
@@ -40,34 +40,34 @@ const de = /* @__PURE__ */ k({
|
|
|
40
40
|
css: f = "",
|
|
41
41
|
partnerName: i = m(),
|
|
42
42
|
productType: s = d(),
|
|
43
|
-
messageType: y =
|
|
44
|
-
username: C =
|
|
45
|
-
} =
|
|
46
|
-
window.GuidoConfig =
|
|
43
|
+
messageType: y = B,
|
|
44
|
+
username: C = z
|
|
45
|
+
} = o;
|
|
46
|
+
window.GuidoConfig = X(F, u), window.GuidoConfig.partner = {
|
|
47
47
|
partnerName: i,
|
|
48
48
|
productType: s,
|
|
49
49
|
messageType: y
|
|
50
50
|
};
|
|
51
|
-
const { initPlugin: v } =
|
|
51
|
+
const { initPlugin: v } = M({
|
|
52
52
|
emailId: l,
|
|
53
53
|
userId: p,
|
|
54
54
|
username: C,
|
|
55
55
|
partnerName: i,
|
|
56
56
|
productType: s,
|
|
57
57
|
preselectedDynamicContentList: a
|
|
58
|
-
}), { getDefaultTemplate: w } =
|
|
58
|
+
}), { getDefaultTemplate: w } = q(), k = T(() => {
|
|
59
59
|
var e;
|
|
60
60
|
return !((e = window.GuidoConfig) != null && e.useHeader);
|
|
61
61
|
});
|
|
62
|
-
|
|
62
|
+
U({
|
|
63
63
|
onBack: () => {
|
|
64
|
-
console.debug("guido:back"),
|
|
64
|
+
console.debug("guido:back"), t("back");
|
|
65
65
|
},
|
|
66
66
|
onSaveStart: () => {
|
|
67
|
-
console.debug("guido:save:start"),
|
|
67
|
+
console.debug("guido:save:start"), t("save:start");
|
|
68
68
|
},
|
|
69
69
|
onSaveComplete: (e) => {
|
|
70
|
-
console.debug("guido:save:complete", e),
|
|
70
|
+
console.debug("guido:save:complete", e), t("save:complete", e);
|
|
71
71
|
}
|
|
72
72
|
});
|
|
73
73
|
const h = (e) => {
|
|
@@ -75,9 +75,9 @@ const de = /* @__PURE__ */ k({
|
|
|
75
75
|
}, D = () => {
|
|
76
76
|
console.debug("dynamic-content:close", "Without Data"), document.dispatchEvent(new CustomEvent("dynamic-content:close", { detail: { text: "", value: "" } }));
|
|
77
77
|
};
|
|
78
|
-
return
|
|
79
|
-
|
|
80
|
-
}),
|
|
78
|
+
return W(() => r.value, () => {
|
|
79
|
+
t("on-change");
|
|
80
|
+
}), H(async () => {
|
|
81
81
|
console.debug("Guido says happy coding 🎉"), console.debug("🚗 Ka-Chow");
|
|
82
82
|
try {
|
|
83
83
|
let e = {
|
|
@@ -92,9 +92,9 @@ const de = /* @__PURE__ */ k({
|
|
|
92
92
|
}
|
|
93
93
|
document.addEventListener("dynamic-content:open", (e) => {
|
|
94
94
|
const S = e;
|
|
95
|
-
console.debug("dynamic-content:open", S.detail),
|
|
95
|
+
console.debug("dynamic-content:open", S.detail), t("dynamic-content:open", S.detail);
|
|
96
96
|
});
|
|
97
|
-
}),
|
|
97
|
+
}), N(() => {
|
|
98
98
|
window.UIEditor.removeEditor();
|
|
99
99
|
}), G({
|
|
100
100
|
dynamicContent: {
|
|
@@ -102,9 +102,9 @@ const de = /* @__PURE__ */ k({
|
|
|
102
102
|
close: D
|
|
103
103
|
},
|
|
104
104
|
hasChanges: r
|
|
105
|
-
}), { __sfc: !0, PreviewContainer:
|
|
105
|
+
}), { __sfc: !0, PreviewContainer: P, OnboardingWrapper: I, dynamicContentStore: n, props: o, editorStore: c, previewStore: L, hasChanges: r, preselectedDynamicContentList: a, getPartnerName: m, getProductType: d, isTestPartner: _, templateId: l, userId: p, guidoConfig: u, html: g, css: f, partnerName: i, productType: s, messageType: y, username: C, emit: t, initPlugin: v, getDefaultTemplate: w, noHeader: k, insertDynamicContent: h, closeDynamicContent: D, Toaster: K, HeaderWrapper: O, LoadingWrapper: R, SaveAsTemplateDrawer: j };
|
|
106
106
|
}
|
|
107
107
|
});
|
|
108
108
|
export {
|
|
109
|
-
|
|
109
|
+
le as default
|
|
110
110
|
};
|
|
@@ -1,30 +1,29 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { useTranslations as
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
const v = /* @__PURE__ */ r({
|
|
1
|
+
import { defineComponent as m, computed as n } from "vue";
|
|
2
|
+
import { useTranslations as r } from "../../../../composables/useTranslations.js";
|
|
3
|
+
import { usePreviewStore as i } from "../../../../stores/preview.js";
|
|
4
|
+
import { InButtonV2 as s, InSegments as l } from "@useinsider/design-system-vue";
|
|
5
|
+
const _ = /* @__PURE__ */ m({
|
|
7
6
|
__name: "AmpToggle",
|
|
8
|
-
setup(
|
|
9
|
-
const t =
|
|
7
|
+
setup(p) {
|
|
8
|
+
const t = i(), e = r(), o = n(() => [
|
|
10
9
|
{
|
|
11
|
-
text:
|
|
10
|
+
text: e("dynamic-creatives.html"),
|
|
12
11
|
value: "html"
|
|
13
12
|
},
|
|
14
13
|
{
|
|
15
|
-
text:
|
|
14
|
+
text: e("email-editor.amp-html"),
|
|
16
15
|
value: "AMP",
|
|
17
|
-
tooltipText: t.hasAMP ? "" :
|
|
16
|
+
tooltipText: t.hasAMP ? "" : e("email-editor.preview-amp-unavailable-tooltip"),
|
|
18
17
|
position: "bottom",
|
|
19
18
|
align: "center",
|
|
20
19
|
disable: !t.hasAMP
|
|
21
20
|
}
|
|
22
21
|
]);
|
|
23
|
-
return { __sfc: !0, previewStore: t,
|
|
24
|
-
t.setEmailFormat(
|
|
25
|
-
}, InSegments:
|
|
22
|
+
return { __sfc: !0, previewStore: t, trans: e, segmentList: o, handleFormatChange: (a) => {
|
|
23
|
+
t.setEmailFormat(a);
|
|
24
|
+
}, InSegments: l, InButtonV2: s };
|
|
26
25
|
}
|
|
27
26
|
});
|
|
28
27
|
export {
|
|
29
|
-
|
|
28
|
+
_ as default
|
|
30
29
|
};
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import i from "./ViewOptions.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import o from "../../../_virtual/_plugin-vue2_normalizer.js";
|
|
4
|
-
var
|
|
4
|
+
var n = function() {
|
|
5
5
|
var t = this, s = t._self._c, e = t._self._setupProxy;
|
|
6
|
-
return s("div", { staticClass: "view-options-wrapper" }, [s(e.InSegments, { attrs: { id: "guido__view-option-selection", "with-icon": "", disable: e.editorStore.isViewOptionsDisabled, "segment-list": e.segmentList, selected: e.editorStore.editorVisualMode } }), e.editorStore.isViewOptionsDisabled ? t._e() : s("
|
|
7
|
-
},
|
|
6
|
+
return s("div", { staticClass: "view-options-wrapper" }, [s(e.InSegments, { attrs: { id: "guido__view-option-selection", "with-icon": "", disable: e.editorStore.isViewOptionsDisabled, "segment-list": e.segmentList, selected: e.editorStore.editorVisualMode } }), e.editorStore.isViewOptionsDisabled ? t._e() : s(e.InChips, { staticClass: "new-tag", attrs: { id: "guido__view-options-new-tag", styles: "stroke", value: "chips", "close-button": !1, interactive: !1, text: e.trans("settings.new") } })], 1);
|
|
7
|
+
}, r = [], a = /* @__PURE__ */ o(
|
|
8
8
|
i,
|
|
9
|
-
r,
|
|
10
9
|
n,
|
|
10
|
+
r,
|
|
11
11
|
!1,
|
|
12
12
|
null,
|
|
13
|
-
"
|
|
13
|
+
"195ab6d4"
|
|
14
14
|
);
|
|
15
15
|
const c = a.exports;
|
|
16
16
|
export {
|
|
@@ -2,10 +2,10 @@ import { defineComponent as n } from "vue";
|
|
|
2
2
|
import { useTranslations as p } from "../../../composables/useTranslations.js";
|
|
3
3
|
import { useEditorStore as s } from "../../../stores/editor.js";
|
|
4
4
|
import { getTooltipOptions as o } from "../../../utils/tooltipUtils.js";
|
|
5
|
-
import {
|
|
6
|
-
const
|
|
5
|
+
import { InChips as r, InSegments as m } from "@useinsider/design-system-vue";
|
|
6
|
+
const f = /* @__PURE__ */ n({
|
|
7
7
|
__name: "ViewOptions",
|
|
8
|
-
setup(
|
|
8
|
+
setup(l) {
|
|
9
9
|
const e = s(), t = p(), i = [
|
|
10
10
|
{
|
|
11
11
|
text: "",
|
|
@@ -26,9 +26,9 @@ const d = /* @__PURE__ */ n({
|
|
|
26
26
|
tooltipOptions: o("guido__view-option-mobile")
|
|
27
27
|
}
|
|
28
28
|
];
|
|
29
|
-
return { __sfc: !0, editorStore: e, trans: t, segmentList: i, InSegments: r };
|
|
29
|
+
return { __sfc: !0, editorStore: e, trans: t, segmentList: i, InSegments: m, InChips: r };
|
|
30
30
|
}
|
|
31
31
|
});
|
|
32
32
|
export {
|
|
33
|
-
|
|
33
|
+
f as default
|
|
34
34
|
};
|
|
@@ -2,17 +2,17 @@ import i from "./ViewOptions.vue2.js";
|
|
|
2
2
|
/* empty css */
|
|
3
3
|
import o from "../../../../_virtual/_plugin-vue2_normalizer.js";
|
|
4
4
|
var n = function() {
|
|
5
|
-
var
|
|
6
|
-
return
|
|
5
|
+
var s = this, t = s._self._c, e = s._self._setupProxy;
|
|
6
|
+
return t("div", { staticClass: "view-options-wrapper" }, [t(e.InSegments, { attrs: { id: "guido__verion-history-view-option-selection", "with-icon": "", "segment-list": e.segmentList, selected: e.versionHistoryStore.editorVisualMode }, on: { click: e.changeVisualMode } }), t(e.InChips, { staticClass: "new-tag", attrs: { id: "guido__view-options-new-tag", styles: "stroke", value: "chips", "close-button": !1, interactive: !1, text: e.trans("settings.new") } })], 1);
|
|
7
7
|
}, r = [], a = /* @__PURE__ */ o(
|
|
8
8
|
i,
|
|
9
9
|
n,
|
|
10
10
|
r,
|
|
11
11
|
!1,
|
|
12
12
|
null,
|
|
13
|
-
"
|
|
13
|
+
"d405ca59"
|
|
14
14
|
);
|
|
15
|
-
const
|
|
15
|
+
const d = a.exports;
|
|
16
16
|
export {
|
|
17
|
-
|
|
17
|
+
d as default
|
|
18
18
|
};
|
|
@@ -3,10 +3,10 @@ import { useTranslations as m } from "../../../../composables/useTranslations.js
|
|
|
3
3
|
import { useVersionHistoryApi as l } from "../../../../composables/useVersionHistoryApi.js";
|
|
4
4
|
import { useVersionHistoryStore as a } from "../../../../stores/version-history.js";
|
|
5
5
|
import { getTooltipOptions as n } from "../../../../utils/tooltipUtils.js";
|
|
6
|
-
import {
|
|
7
|
-
const
|
|
6
|
+
import { InChips as c, InSegments as u } from "@useinsider/design-system-vue";
|
|
7
|
+
const T = /* @__PURE__ */ p({
|
|
8
8
|
__name: "ViewOptions",
|
|
9
|
-
setup(
|
|
9
|
+
setup(_) {
|
|
10
10
|
const t = a(), { switchToDesktopPreview: e, switchToMobilePreview: i } = l(), o = m(), r = [
|
|
11
11
|
{
|
|
12
12
|
text: "",
|
|
@@ -33,9 +33,9 @@ const h = /* @__PURE__ */ p({
|
|
|
33
33
|
return;
|
|
34
34
|
}
|
|
35
35
|
e();
|
|
36
|
-
}, InSegments: c };
|
|
36
|
+
}, InSegments: u, InChips: c };
|
|
37
37
|
}
|
|
38
38
|
});
|
|
39
39
|
export {
|
|
40
|
-
|
|
40
|
+
T as default
|
|
41
41
|
};
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import
|
|
1
|
+
import c from "./GenericOnboarding.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import g from "../../../_virtual/_plugin-vue2_normalizer.js";
|
|
4
4
|
var l = function() {
|
|
5
5
|
var r, n, t, i, a, s;
|
|
6
|
-
var o = this,
|
|
7
|
-
return e.isVisible ?
|
|
6
|
+
var o = this, d = o._self._c, e = o._self._setupProxy;
|
|
7
|
+
return e.isVisible ? d(e.InOnboard, { key: "guido__editor-onboard", staticClass: "w-21-s p-a z-11", class: (r = e.onboardingStore.getGenericCurrentCard) == null ? void 0 : r.classes, attrs: { id: "guido__editor-onboard", "is-multiple-page": "", visible: "", "image-source": "", title: "", "bottom-position": (n = e.onboardingStore.getGenericCurrentCard) == null ? void 0 : n.bottom, "left-position": (t = e.onboardingStore.getGenericCurrentCard) == null ? void 0 : t.left, "pages-config": e.onboardingStore.onboardings.genericOnboarding.config, "pointer-position": (i = e.onboardingStore.getGenericCurrentCard) == null ? void 0 : i.position, "right-position": (a = e.onboardingStore.getGenericCurrentCard) == null ? void 0 : a.right, "top-position": (s = e.onboardingStore.getGenericCurrentCard) == null ? void 0 : s.top }, on: { backButtonClick: e.handleBack, close: function(u) {
|
|
8
8
|
return e.onboardingStore.close("genericOnboarding");
|
|
9
9
|
}, nextButtonClick: e.handleNext } }) : o._e();
|
|
10
10
|
}, p = [], _ = /* @__PURE__ */ g(
|
|
11
|
-
|
|
11
|
+
c,
|
|
12
12
|
l,
|
|
13
13
|
p,
|
|
14
14
|
!1,
|
|
15
15
|
null,
|
|
16
|
-
"
|
|
16
|
+
"3b4afa54"
|
|
17
17
|
);
|
|
18
18
|
const S = _.exports;
|
|
19
19
|
export {
|
|
@@ -33,7 +33,7 @@ const S = /* @__PURE__ */ l({
|
|
|
33
33
|
{
|
|
34
34
|
classes: "guido-onboarding-stripes",
|
|
35
35
|
right: "450px",
|
|
36
|
-
bottom: "
|
|
36
|
+
bottom: "-38px",
|
|
37
37
|
position: "Right Top",
|
|
38
38
|
title: e("email-editor.onboarding-stripes-title"),
|
|
39
39
|
description: e("email-editor.onboarding-stripes-description"),
|
|
@@ -1,36 +1,41 @@
|
|
|
1
|
-
import { defineComponent as g, computed as
|
|
1
|
+
import { defineComponent as g, computed as e, onMounted as b, watch as t } from "vue";
|
|
2
2
|
import { usePartner as O } from "../../../composables/usePartner.js";
|
|
3
3
|
import { useEditorStore as u } from "../../../stores/editor.js";
|
|
4
|
-
import { useOnboardingStore as
|
|
5
|
-
import { usePreviewStore as
|
|
4
|
+
import { useOnboardingStore as v } from "../../../stores/onboarding.js";
|
|
5
|
+
import { usePreviewStore as l } from "../../../stores/preview.js";
|
|
6
6
|
import y from "./AMPOnboarding.vue.js";
|
|
7
7
|
import S from "./GenericOnboarding.vue.js";
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
8
|
+
import w from "./NewVersionPopup.vue.js";
|
|
9
|
+
import P from "./TextBlockOnboarding.vue.js";
|
|
10
|
+
import h from "./VersionHistoryOnboarding.vue.js";
|
|
11
11
|
const E = /* @__PURE__ */ g({
|
|
12
12
|
__name: "OnboardingWrapper",
|
|
13
13
|
setup(_) {
|
|
14
|
-
const o =
|
|
15
|
-
{ type: "newVersionPopup", component:
|
|
14
|
+
const o = v(), r = u(), s = l(), { isTestPartner: a } = O(), p = e(() => r.isStripoInitialized), d = e(() => a()), m = [
|
|
15
|
+
{ type: "newVersionPopup", component: w },
|
|
16
16
|
{ type: "genericOnboarding", component: S },
|
|
17
|
-
{ type: "textBlockOnboarding", component:
|
|
18
|
-
{ type: "versionHistoryOnboarding", component:
|
|
17
|
+
{ type: "textBlockOnboarding", component: P },
|
|
18
|
+
{ type: "versionHistoryOnboarding", component: h },
|
|
19
19
|
{ type: "ampOnboarding", component: y }
|
|
20
|
-
],
|
|
20
|
+
], c = (n) => d.value || !p.value ? !1 : n === "newVersionPopup" ? o.shouldShowOnboarding(n) : o.isActive(n), f = e(() => m.filter((n) => c(n.type)));
|
|
21
21
|
return b(async () => {
|
|
22
22
|
await o.fetchUserModalState();
|
|
23
|
-
}),
|
|
24
|
-
() =>
|
|
25
|
-
(
|
|
26
|
-
|
|
23
|
+
}), t(
|
|
24
|
+
() => r.isVersionHistoryOpen,
|
|
25
|
+
(n, i) => {
|
|
26
|
+
n && !i && o.shouldShowOnboarding("versionHistoryOnboarding") && o.start("versionHistoryOnboarding"), !n && i && o.isActive("versionHistoryOnboarding") && o.close("versionHistoryOnboarding");
|
|
27
27
|
}
|
|
28
|
-
),
|
|
29
|
-
() =>
|
|
30
|
-
(
|
|
31
|
-
|
|
28
|
+
), t(
|
|
29
|
+
() => s.emailFormat,
|
|
30
|
+
(n, i) => {
|
|
31
|
+
i !== "AMP" && n === "AMP" && o.shouldShowOnboarding("ampOnboarding") && o.start("ampOnboarding");
|
|
32
32
|
}
|
|
33
|
-
),
|
|
33
|
+
), t(
|
|
34
|
+
() => r.isPreviewModeOpen,
|
|
35
|
+
(n) => {
|
|
36
|
+
!n && o.isActive("ampOnboarding") && o.close("ampOnboarding");
|
|
37
|
+
}
|
|
38
|
+
), { __sfc: !0, onboardingStore: o, editorStore: r, previewStore: s, isTestPartner: a, isStripoReady: p, isTestPartnerActive: d, onboardingConfigs: m, shouldShow: c, visibleOnboardings: f };
|
|
34
39
|
}
|
|
35
40
|
});
|
|
36
41
|
export {
|
|
@@ -1,27 +1,26 @@
|
|
|
1
|
-
import { useEditorStore as
|
|
2
|
-
import { useOnboardingStore as m } from "../stores/onboarding.js";
|
|
1
|
+
import { useEditorStore as n } from "../stores/editor.js";
|
|
3
2
|
import { usePreviewStore as l } from "../stores/preview.js";
|
|
4
|
-
import { useActionsApi as
|
|
5
|
-
import { useCodeEditorApi as
|
|
3
|
+
import { useActionsApi as m } from "./useActionsApi.js";
|
|
4
|
+
import { useCodeEditorApi as p } from "./useCodeEditorApi.js";
|
|
6
5
|
const E = () => {
|
|
7
|
-
const
|
|
8
|
-
|
|
6
|
+
const o = n(), e = l(), { closeCodeEditor: a } = p(), { getPreviewData: s } = m(), r = () => {
|
|
7
|
+
o.isPreviewModeOpen = !1, e.$reset();
|
|
9
8
|
};
|
|
10
9
|
return {
|
|
11
|
-
closePreviewMode:
|
|
10
|
+
closePreviewMode: r,
|
|
12
11
|
openPreviewMode: () => {
|
|
13
|
-
|
|
12
|
+
o.isCodeEditorOpen && a(), o.isPreviewModeOpen = !0;
|
|
14
13
|
},
|
|
15
14
|
loadPreviewData: async () => {
|
|
16
|
-
if (!(
|
|
17
|
-
|
|
15
|
+
if (!(o.loadingStatus || e.isLoaded)) {
|
|
16
|
+
o.loadingStatus = !0;
|
|
18
17
|
try {
|
|
19
|
-
const { html:
|
|
20
|
-
|
|
21
|
-
} catch (
|
|
22
|
-
console.error("Failed to load preview data:",
|
|
18
|
+
const { html: t, ampHtml: i, ampErrors: d } = await s();
|
|
19
|
+
e.templateHtml = t || "", e.ampHtml = i || "", e.ampErrors = d || [], e.setEmailFormat(i ? "AMP" : "html"), e.isLoaded = !0;
|
|
20
|
+
} catch (t) {
|
|
21
|
+
console.error("Failed to load preview data:", t), r();
|
|
23
22
|
} finally {
|
|
24
|
-
|
|
23
|
+
o.loadingStatus = !1;
|
|
25
24
|
}
|
|
26
25
|
}
|
|
27
26
|
}
|
package/dist/guido.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
[data-v-a18ac2d3] .in-button-v2__wrapper{line-height:0}.version-history-item[data-v-ee4b9c3f]{flex-basis:200px}.version-history-wrapper[data-v-52a77eec]{gap:8px}.view-options-wrapper[data-v-
|
|
1
|
+
[data-v-a18ac2d3] .in-button-v2__wrapper{line-height:0}.version-history-item[data-v-ee4b9c3f]{flex-basis:200px}.version-history-wrapper[data-v-52a77eec]{gap:8px}.view-options-wrapper[data-v-d405ca59]{position:relative;display:inline-block}.new-tag[data-v-d405ca59]{position:absolute;top:-8px;right:-16px;z-index:10}[data-v-d405ca59] .guido__verion-history-view-option-selection-desktop svg,[data-v-d405ca59] .guido__verion-history-view-option-selection-mobile svg{margin:0 0 0 2px}[data-v-d405ca59] .in-segments-wrapper__button_selected,[data-v-d405ca59] .in-segments-wrapper__button_selected:hover{background-color:#dae1fb}[data-v-d405ca59] .in-tooltip-wrapper__icon{cursor:pointer}.view-options-wrapper[data-v-195ab6d4]{position:relative;display:inline-block}.new-tag[data-v-195ab6d4]{position:absolute;top:-8px;right:-16px;z-index:10}[data-v-195ab6d4] .guido__view-option-selection-desktop svg,[data-v-195ab6d4] .guido__view-option-selection-mobile svg{margin:0 0 0 2px}[data-v-195ab6d4] .in-segments-wrapper__button_selected,[data-v-195ab6d4] .in-segments-wrapper__button_selected:hover{background-color:#dae1fb}[data-v-195ab6d4] .in-tooltip-wrapper__icon{cursor:pointer}.guido-loading__wrapper[data-v-2d4cd446]{height:calc(100% - 75px);top:75px}.guido-editor__wrapper[data-v-39783038],.guido-editor__container[data-v-39783038]{width:100%;height:calc(100vh - 128px)}.guido-editor__no-header[data-v-39783038]{height:calc(100vh - 75px)}.error-list[data-v-7a09985c]{gap:16px}[data-v-c2adc57d] .in-progress-wrapper__progress p span:last-child{display:none!important}.desktop-preview-container[data-v-2dd60b0c],[data-v-2dd60b0c] .desktop-preview-container .in-container{min-height:720px!important;height:100%}.cropped-text[data-v-f20b3a9b]{width:220px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}[data-v-3b4afa54] .vueperslides__bullets,[data-v-bccb3b50] .vueperslides__bullets{pointer-events:none!important}
|
|
@@ -108,7 +108,15 @@ export declare const useOnboardingStore: import("pinia").StoreDefinition<"onboar
|
|
|
108
108
|
}[];
|
|
109
109
|
};
|
|
110
110
|
};
|
|
111
|
-
userModalState:
|
|
111
|
+
userModalState: {
|
|
112
|
+
Guido?: {
|
|
113
|
+
newVersionPopup?: boolean | undefined;
|
|
114
|
+
genericOnboarding?: boolean | undefined;
|
|
115
|
+
textBlockOnboarding?: boolean | undefined;
|
|
116
|
+
versionHistoryOnboarding?: boolean | undefined;
|
|
117
|
+
ampOnboarding?: boolean | undefined;
|
|
118
|
+
} | undefined;
|
|
119
|
+
};
|
|
112
120
|
isFetched: boolean;
|
|
113
121
|
} & import("pinia").PiniaCustomStateProperties<OnboardingStoreState>) => (type: OnboardingType) => {
|
|
114
122
|
cardIndex: number;
|
|
@@ -239,7 +247,15 @@ export declare const useOnboardingStore: import("pinia").StoreDefinition<"onboar
|
|
|
239
247
|
}[];
|
|
240
248
|
};
|
|
241
249
|
};
|
|
242
|
-
userModalState:
|
|
250
|
+
userModalState: {
|
|
251
|
+
Guido?: {
|
|
252
|
+
newVersionPopup?: boolean | undefined;
|
|
253
|
+
genericOnboarding?: boolean | undefined;
|
|
254
|
+
textBlockOnboarding?: boolean | undefined;
|
|
255
|
+
versionHistoryOnboarding?: boolean | undefined;
|
|
256
|
+
ampOnboarding?: boolean | undefined;
|
|
257
|
+
} | undefined;
|
|
258
|
+
};
|
|
243
259
|
isFetched: boolean;
|
|
244
260
|
} & import("pinia").PiniaCustomStateProperties<OnboardingStoreState>) => (type: OnboardingType) => boolean;
|
|
245
261
|
getCurrentCard: (state: {
|
|
@@ -350,7 +366,15 @@ export declare const useOnboardingStore: import("pinia").StoreDefinition<"onboar
|
|
|
350
366
|
}[];
|
|
351
367
|
};
|
|
352
368
|
};
|
|
353
|
-
userModalState:
|
|
369
|
+
userModalState: {
|
|
370
|
+
Guido?: {
|
|
371
|
+
newVersionPopup?: boolean | undefined;
|
|
372
|
+
genericOnboarding?: boolean | undefined;
|
|
373
|
+
textBlockOnboarding?: boolean | undefined;
|
|
374
|
+
versionHistoryOnboarding?: boolean | undefined;
|
|
375
|
+
ampOnboarding?: boolean | undefined;
|
|
376
|
+
} | undefined;
|
|
377
|
+
};
|
|
354
378
|
isFetched: boolean;
|
|
355
379
|
} & import("pinia").PiniaCustomStateProperties<OnboardingStoreState>) => (type: OnboardingType) => {
|
|
356
380
|
classes: string;
|
|
@@ -477,7 +501,15 @@ export declare const useOnboardingStore: import("pinia").StoreDefinition<"onboar
|
|
|
477
501
|
}[];
|
|
478
502
|
};
|
|
479
503
|
};
|
|
480
|
-
userModalState:
|
|
504
|
+
userModalState: {
|
|
505
|
+
Guido?: {
|
|
506
|
+
newVersionPopup?: boolean | undefined;
|
|
507
|
+
genericOnboarding?: boolean | undefined;
|
|
508
|
+
textBlockOnboarding?: boolean | undefined;
|
|
509
|
+
versionHistoryOnboarding?: boolean | undefined;
|
|
510
|
+
ampOnboarding?: boolean | undefined;
|
|
511
|
+
} | undefined;
|
|
512
|
+
};
|
|
481
513
|
isFetched: boolean;
|
|
482
514
|
} & import("pinia").PiniaCustomStateProperties<OnboardingStoreState>) => {
|
|
483
515
|
classes: string;
|
|
@@ -604,7 +636,15 @@ export declare const useOnboardingStore: import("pinia").StoreDefinition<"onboar
|
|
|
604
636
|
}[];
|
|
605
637
|
};
|
|
606
638
|
};
|
|
607
|
-
userModalState:
|
|
639
|
+
userModalState: {
|
|
640
|
+
Guido?: {
|
|
641
|
+
newVersionPopup?: boolean | undefined;
|
|
642
|
+
genericOnboarding?: boolean | undefined;
|
|
643
|
+
textBlockOnboarding?: boolean | undefined;
|
|
644
|
+
versionHistoryOnboarding?: boolean | undefined;
|
|
645
|
+
ampOnboarding?: boolean | undefined;
|
|
646
|
+
} | undefined;
|
|
647
|
+
};
|
|
608
648
|
isFetched: boolean;
|
|
609
649
|
} & import("pinia").PiniaCustomStateProperties<OnboardingStoreState>) => {
|
|
610
650
|
classes: string;
|
|
@@ -731,7 +771,15 @@ export declare const useOnboardingStore: import("pinia").StoreDefinition<"onboar
|
|
|
731
771
|
}[];
|
|
732
772
|
};
|
|
733
773
|
};
|
|
734
|
-
userModalState:
|
|
774
|
+
userModalState: {
|
|
775
|
+
Guido?: {
|
|
776
|
+
newVersionPopup?: boolean | undefined;
|
|
777
|
+
genericOnboarding?: boolean | undefined;
|
|
778
|
+
textBlockOnboarding?: boolean | undefined;
|
|
779
|
+
versionHistoryOnboarding?: boolean | undefined;
|
|
780
|
+
ampOnboarding?: boolean | undefined;
|
|
781
|
+
} | undefined;
|
|
782
|
+
};
|
|
735
783
|
isFetched: boolean;
|
|
736
784
|
} & import("pinia").PiniaCustomStateProperties<OnboardingStoreState>) => {
|
|
737
785
|
classes: string;
|
|
@@ -858,7 +906,15 @@ export declare const useOnboardingStore: import("pinia").StoreDefinition<"onboar
|
|
|
858
906
|
}[];
|
|
859
907
|
};
|
|
860
908
|
};
|
|
861
|
-
userModalState:
|
|
909
|
+
userModalState: {
|
|
910
|
+
Guido?: {
|
|
911
|
+
newVersionPopup?: boolean | undefined;
|
|
912
|
+
genericOnboarding?: boolean | undefined;
|
|
913
|
+
textBlockOnboarding?: boolean | undefined;
|
|
914
|
+
versionHistoryOnboarding?: boolean | undefined;
|
|
915
|
+
ampOnboarding?: boolean | undefined;
|
|
916
|
+
} | undefined;
|
|
917
|
+
};
|
|
862
918
|
isFetched: boolean;
|
|
863
919
|
} & import("pinia").PiniaCustomStateProperties<OnboardingStoreState>) => {
|
|
864
920
|
classes: string;
|
|
@@ -985,7 +1041,15 @@ export declare const useOnboardingStore: import("pinia").StoreDefinition<"onboar
|
|
|
985
1041
|
}[];
|
|
986
1042
|
};
|
|
987
1043
|
};
|
|
988
|
-
userModalState:
|
|
1044
|
+
userModalState: {
|
|
1045
|
+
Guido?: {
|
|
1046
|
+
newVersionPopup?: boolean | undefined;
|
|
1047
|
+
genericOnboarding?: boolean | undefined;
|
|
1048
|
+
textBlockOnboarding?: boolean | undefined;
|
|
1049
|
+
versionHistoryOnboarding?: boolean | undefined;
|
|
1050
|
+
ampOnboarding?: boolean | undefined;
|
|
1051
|
+
} | undefined;
|
|
1052
|
+
};
|
|
989
1053
|
isFetched: boolean;
|
|
990
1054
|
} & import("pinia").PiniaCustomStateProperties<OnboardingStoreState>) => (type: OnboardingType) => boolean;
|
|
991
1055
|
}, {
|
package/dist/stores/preview.js
CHANGED
|
@@ -27,9 +27,7 @@ const s = () => ({
|
|
|
27
27
|
},
|
|
28
28
|
actions: {
|
|
29
29
|
updateAMPData(t) {
|
|
30
|
-
this.ampHtml = t.ampHtml ?? "", this.ampErrors = t.ampErrors ?? [];
|
|
31
|
-
const r = t.ampHtml ? "AMP" : "html";
|
|
32
|
-
this.emailFormat = r;
|
|
30
|
+
this.ampHtml = t.ampHtml ?? "", this.ampErrors = t.ampErrors ?? [], this.emailFormat = t.ampHtml ? "AMP" : "html";
|
|
33
31
|
},
|
|
34
32
|
setEmailFormat(t) {
|
|
35
33
|
this.emailFormat = t;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@useinsider/guido",
|
|
3
|
-
"version": "1.0.2-beta.
|
|
3
|
+
"version": "1.0.2-beta.86f7e79",
|
|
4
4
|
"description": "Guido is a Vue + TypeScript wrapper for Email Plugin. Easily embed the email editor in your Vue applications.",
|
|
5
5
|
"main": "./dist/guido.umd.cjs",
|
|
6
6
|
"module": "./dist/library.js",
|
|
@@ -24,7 +24,8 @@
|
|
|
24
24
|
"lint": "NODE_OPTIONS=--max-old-space-size=2048 eslint ./ && bun run type-check",
|
|
25
25
|
"lint:fix": "NODE_OPTIONS=--max-old-space-size=2048 eslint --fix ./",
|
|
26
26
|
"type-check": "vue-tsc --noEmit --project tsconfig.config.json && vue-tsc --noEmit --project tsconfig.app.json",
|
|
27
|
-
"test:visual-update": "npx playwright test --update-snapshots --reporter html"
|
|
27
|
+
"test:visual-update": "npx playwright test --update-snapshots --reporter html",
|
|
28
|
+
"prepare": "husky"
|
|
28
29
|
},
|
|
29
30
|
"keywords": [],
|
|
30
31
|
"author": "",
|
|
@@ -65,6 +66,7 @@
|
|
|
65
66
|
"eslint-plugin-vue": "10.1.0",
|
|
66
67
|
"eslint-plugin-vue-scoped-css": "2.6.1",
|
|
67
68
|
"globals": "16.0.0",
|
|
69
|
+
"husky": "9.1.7",
|
|
68
70
|
"msw": "2.10.3",
|
|
69
71
|
"sass": "1.69.7",
|
|
70
72
|
"typescript": "5.5.4",
|