@useinsider/guido 2.0.0-beta.087a24f → 2.0.0-beta.0b0b5d1
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/organisms/email-preview/amp/AmpErrorModal.vue.js +7 -7
- package/dist/components/organisms/email-preview/amp/AmpToggle.vue.js +7 -8
- package/dist/components/organisms/email-preview/amp/AmpToggle.vue2.js +4 -3
- package/dist/components/organisms/email-preview/desktop-preview/DesktopPreview.vue.js +10 -14
- package/dist/components/organisms/email-preview/desktop-preview/DesktopPreview.vue2.js +18 -22
- package/dist/components/organisms/email-preview/desktop-preview/EmailSizeIndicator.vue.js +3 -3
- package/dist/components/organisms/email-preview/mobile-preview/ContentView.vue.js +5 -5
- package/dist/components/organisms/email-preview/mobile-preview/MobilePreview.vue.js +10 -10
- package/dist/components/organisms/email-preview/mobile-preview/MobilePreview.vue2.js +15 -14
- package/dist/components/organisms/header/LeftSlot.vue.js +2 -2
- package/dist/components/organisms/header/MiddleSlot.vue.js +5 -4
- package/dist/components/organisms/header/MiddleSlot.vue2.js +14 -13
- package/dist/components/organisms/header/RightSlot.vue.js +7 -7
- package/dist/components/wrappers/WpModal.vue.js +4 -3
- package/dist/composables/useStripo.js +37 -35
- package/dist/config/migrator/index.js +8 -9
- package/dist/extensions/Blocks/CouponBlock/constants.js +4 -0
- package/dist/extensions/Blocks/CouponBlock/controls/index.js +29 -0
- package/dist/extensions/Blocks/CouponBlock/extension.js +5 -4
- package/dist/extensions/Blocks/CouponBlock/settingsPanel.js +20 -14
- package/dist/extensions/Blocks/CouponBlock/template.js +22 -11
- package/dist/extensions/Blocks/Items/block.js +40 -39
- package/dist/extensions/Blocks/Items/controls/cardComposition.js +49 -46
- package/dist/extensions/Blocks/Items/controls/price/priceOrientation.js +26 -28
- package/dist/extensions/Blocks/Items/controls/settingsControl.js +127 -132
- package/dist/extensions/Blocks/Items/enums/settingsEnums.js +2 -2
- package/dist/extensions/Blocks/Items/layouts/horizontal.html.js +48 -58
- package/dist/extensions/Blocks/Items/layouts/vertical.html.js +58 -48
- package/dist/extensions/Blocks/Items/store/items-block.js +2 -2
- package/dist/extensions/Blocks/Items/template.js +123 -296
- package/dist/extensions/Blocks/Items/utils/syncAttributesFromConfigBlock.js +20 -11
- package/dist/extensions/Blocks/Recommendation/control.js +1 -1
- package/dist/extensions/Blocks/common-control.js +53 -64
- package/dist/extensions/Blocks/controlFactories.js +122 -111
- package/dist/guido.css +1 -1
- package/dist/node_modules/@stripoinc/ui-editor-extensions/dist/esm/index.js +290 -364
- package/dist/package.json.js +7 -0
- package/dist/src/extensions/Blocks/CouponBlock/constants.d.ts +14 -0
- package/dist/src/extensions/Blocks/CouponBlock/controls/index.d.ts +108 -0
- package/dist/src/extensions/Blocks/CouponBlock/template.d.ts +1 -1
- package/dist/src/extensions/Blocks/Items/controls/price/priceOrientation.d.ts +1 -1
- package/dist/src/extensions/Blocks/Items/controls/settingsControl.d.ts +4 -0
- package/dist/src/extensions/Blocks/Items/template.d.ts +1 -20
- package/dist/src/extensions/Blocks/common-control.d.ts +8 -13
- package/dist/src/extensions/Blocks/controlFactories.d.ts +30 -7
- package/dist/static/assets/desktop/desktop-mockup-center.svg.js +4 -0
- package/dist/static/assets/desktop/desktop-mockup-left.svg.js +4 -0
- package/dist/static/assets/desktop/desktop-mockup-right.svg.js +4 -0
- package/dist/static/assets/mobile/email-mockup.svg.js +4 -0
- package/dist/static/assets/mobile/inbox-mockup.svg.js +4 -0
- package/package.json +3 -3
- package/dist/components/organisms/email-preview/desktop-preview/EmailHeaderInfo.vue.js +0 -17
- package/dist/components/organisms/email-preview/desktop-preview/EmailHeaderInfo.vue2.js +0 -20
- package/dist/config/migrator/itemsBlockMigrator.js +0 -283
- package/dist/extensions/Blocks/Items/utils/nodeConfigUtils.js +0 -172
- package/dist/src/config/migrator/itemsBlockMigrator.d.ts +0 -6
- package/dist/src/extensions/Blocks/Items/utils/nodeConfigUtils.d.ts +0 -71
- package/dist/static/assets/inbox-mockup.svg.js +0 -4
- package/dist/static/assets/phone-mockup.svg.js +0 -4
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import s from "./AmpErrorModal.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
|
-
import
|
|
3
|
+
import i from "../../../../_virtual/_plugin-vue2_normalizer.js";
|
|
4
4
|
var n = function() {
|
|
5
|
-
var
|
|
6
|
-
return
|
|
5
|
+
var r = this, e = r._self._c, t = r._self._setupProxy;
|
|
6
|
+
return e(t.WpModal, { attrs: { id: "amp-error-modal", size: "small", description: t.trans("email-editor.amp-validation-description", { academyLink: "https://academy.insiderone.com/docs/amp-for-emails" }), "footer-button-options": t.footerButtonOptions, title: t.trans("email-editor.amp-validation-title") }, on: { close: function(o) {
|
|
7
7
|
return t.emit("close");
|
|
8
|
-
}, "primary-action": t.handleFixInCodeEditor } }, [
|
|
9
|
-
return
|
|
8
|
+
}, "primary-action": t.handleFixInCodeEditor } }, [e("div", { staticClass: "d-f f-d-c" }, [e("div", { staticClass: "mb-3" }, [e("div", { staticClass: "l-s-5 f-s-1 f-w-600 t-c-55 t-t-u" }, [r._v(" " + r._s(t.errorCountText) + " ")])]), e("div", { staticClass: "d-f f-d-c g-13 max-h-21-s o-y-a error-list" }, r._l(t.previewStore.ampErrors, function(o, a) {
|
|
9
|
+
return e(t.InOnPageMessage, { key: a, attrs: { icon: "filled-error-box", size: "small", type: "alert", text: o } });
|
|
10
10
|
}), 1)])]);
|
|
11
|
-
}, l = [], d = /* @__PURE__ */
|
|
11
|
+
}, l = [], d = /* @__PURE__ */ i(
|
|
12
12
|
s,
|
|
13
13
|
n,
|
|
14
14
|
l,
|
|
15
15
|
!1,
|
|
16
16
|
null,
|
|
17
|
-
"
|
|
17
|
+
"dc8bde8a"
|
|
18
18
|
);
|
|
19
19
|
const _ = d.exports;
|
|
20
20
|
export {
|
|
@@ -1,20 +1,19 @@
|
|
|
1
1
|
import o from "./AmpToggle.vue2.js";
|
|
2
|
-
/* empty css */
|
|
3
2
|
import n from "../../../../_virtual/_plugin-vue2_normalizer.js";
|
|
4
|
-
var
|
|
3
|
+
var a = function() {
|
|
5
4
|
var r = this, t = r._self._c, e = r._self._setupProxy;
|
|
6
|
-
return t("div", [t("div", { staticClass: "d-f a-i-c ml-3" }, [t(e.InSegments, { attrs: { id: "guido__amp-toggle", "segment-list": e.segmentList, selected: e.previewStore.emailFormat }, on: { click: e.handleFormatChange } }), e.previewStore.showAMPErrorButton ? t(e.InButtonV2, { staticClass: "ml-2
|
|
5
|
+
return t("div", [t("div", { staticClass: "d-f a-i-c ml-3" }, [t(e.InSegments, { attrs: { id: "guido__amp-toggle", "segment-list": e.segmentList, selected: e.previewStore.emailFormat }, on: { click: e.handleFormatChange } }), e.previewStore.showAMPErrorButton ? t(e.InButtonV2, { staticClass: "ml-2", attrs: { id: "guido__amp-error-button", "left-icon": "filled-amp", type: "danger", "label-text": e.trans("email-editor.check-amp-errors", { count: e.previewStore.ampErrors.length }) }, on: { click: function(m) {
|
|
7
6
|
return e.previewStore.openErrorModal();
|
|
8
7
|
} } }) : r._e()], 1)]);
|
|
9
|
-
},
|
|
8
|
+
}, s = [], i = /* @__PURE__ */ n(
|
|
10
9
|
o,
|
|
11
|
-
s,
|
|
12
10
|
a,
|
|
11
|
+
s,
|
|
13
12
|
!1,
|
|
14
13
|
null,
|
|
15
|
-
|
|
14
|
+
null
|
|
16
15
|
);
|
|
17
|
-
const
|
|
16
|
+
const p = i.exports;
|
|
18
17
|
export {
|
|
19
|
-
|
|
18
|
+
p as default
|
|
20
19
|
};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { defineComponent as m, computed as n } from "vue";
|
|
2
|
-
import { useTranslations as
|
|
3
|
-
import { usePreviewStore as
|
|
2
|
+
import { useTranslations as i } from "../../../../composables/useTranslations.js";
|
|
3
|
+
import { usePreviewStore as r } from "../../../../stores/preview.js";
|
|
4
4
|
import { InButtonV2 as s, InSegments as l } from "@useinsider/design-system-vue";
|
|
5
5
|
const _ = /* @__PURE__ */ m({
|
|
6
6
|
__name: "AmpToggle",
|
|
7
7
|
setup(p) {
|
|
8
|
-
const t =
|
|
8
|
+
const t = r(), e = i(), o = n(() => [
|
|
9
9
|
{
|
|
10
10
|
text: e("dynamic-creatives.html"),
|
|
11
11
|
value: "html"
|
|
@@ -13,6 +13,7 @@ const _ = /* @__PURE__ */ m({
|
|
|
13
13
|
{
|
|
14
14
|
text: e("email-editor.amp-html"),
|
|
15
15
|
value: "AMP",
|
|
16
|
+
icon: "filled-amp",
|
|
16
17
|
tooltipText: t.hasAMP ? "" : e("email-editor.preview-amp-unavailable-tooltip"),
|
|
17
18
|
position: "bottom",
|
|
18
19
|
align: "center",
|
|
@@ -1,22 +1,18 @@
|
|
|
1
|
-
import
|
|
1
|
+
import r from "./DesktopPreview.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import a from "../../../../_virtual/_plugin-vue2_normalizer.js";
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
return
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
return [t(e.EmailSizeIndicator)];
|
|
10
|
-
}, proxy: !0 }]) }, [e.isContainerReady ? t("iframe", { staticClass: "email-iframe w-1 bor-w-0", style: { height: e.iframeHeight }, attrs: { sandbox: "allow-same-origin allow-popups allow-forms allow-scripts allow-popups-to-escape-sandbox", srcdoc: e.previewStore.previewHtml } }) : r._e()])], 1);
|
|
11
|
-
}, i = [], n = /* @__PURE__ */ a(
|
|
12
|
-
o,
|
|
13
|
-
s,
|
|
4
|
+
var i = function() {
|
|
5
|
+
var t = this, e = t._self._c, s = t._self._setupProxy;
|
|
6
|
+
return e("div", { staticClass: "desktop-preview-wrapper" }, [e("p", { staticClass: "f-s-1 f-w-600 l-h-1 t-t-u t-c-53 mb-6 l-s-5" }, [t._v(" " + t._s(s.trans("email-editor.desktop-preview")) + " ")]), e("div", { ref: "containerRef", staticClass: "desktop-preview d-f f-d-c o-h s-1" }, [e("div", { staticClass: "desktop-preview__browser-header d-f w-1 f-sh-0" }, [e("img", { staticClass: "desktop-preview__browser-header-left f-sh-0", attrs: { alt: "", src: s.desktopMockupLeft } }), e("div", { staticClass: "desktop-preview__browser-header-center f-g-1", style: s.centerBackgroundStyle }), e("img", { staticClass: "desktop-preview__browser-header-right f-sh-0", attrs: { alt: "", src: s.desktopMockupRight } })]), e("div", { staticClass: "desktop-preview__content d-f f-g-1 o-h b-c-5 min-h-0" }, [e("div", { staticClass: "f-g-1 h-1 o-h b-c-4 min-w-0" }, [s.isContainerReady ? e("iframe", { staticClass: "desktop-preview__iframe d-b w-1 h-1 b-c-4 bor-s-n", attrs: { sandbox: "allow-same-origin allow-popups allow-forms allow-scripts", srcdoc: s.previewStore.previewHtml } }) : t._e()])])])]);
|
|
7
|
+
}, o = [], p = /* @__PURE__ */ a(
|
|
8
|
+
r,
|
|
14
9
|
i,
|
|
10
|
+
o,
|
|
15
11
|
!1,
|
|
16
12
|
null,
|
|
17
|
-
"
|
|
13
|
+
"8ab430ce"
|
|
18
14
|
);
|
|
19
|
-
const
|
|
15
|
+
const n = p.exports;
|
|
20
16
|
export {
|
|
21
|
-
|
|
17
|
+
n as default
|
|
22
18
|
};
|
|
@@ -1,31 +1,27 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
|
|
1
|
+
import { defineComponent as m, ref as s, computed as p, onMounted as u, onBeforeUnmount as f, nextTick as l } from "vue";
|
|
2
|
+
import { useTranslations as d } from "../../../../composables/useTranslations.js";
|
|
3
|
+
import k from "../../../../static/assets/desktop/desktop-mockup-center.svg.js";
|
|
4
|
+
import _ from "../../../../static/assets/desktop/desktop-mockup-left.svg.js";
|
|
5
|
+
import v from "../../../../static/assets/desktop/desktop-mockup-right.svg.js";
|
|
6
|
+
import { usePreviewStore as g } from "../../../../stores/preview.js";
|
|
7
|
+
const x = /* @__PURE__ */ m({
|
|
7
8
|
__name: "DesktopPreview",
|
|
8
|
-
setup(
|
|
9
|
-
const
|
|
10
|
-
if (!t.value)
|
|
11
|
-
return;
|
|
12
|
-
const o = t.value.querySelector(".in-container");
|
|
13
|
-
if (!o)
|
|
14
|
-
return;
|
|
15
|
-
const u = o.getBoundingClientRect(), s = o.querySelector(".in-container__header"), f = s ? s.getBoundingClientRect().height : 0, p = u.height - f;
|
|
16
|
-
i.value = `${p}px`;
|
|
17
|
-
};
|
|
9
|
+
setup(w) {
|
|
10
|
+
const c = d(), o = s(), t = s(!1), i = g();
|
|
18
11
|
let e = null;
|
|
19
|
-
const
|
|
20
|
-
|
|
21
|
-
|
|
12
|
+
const a = p(() => ({
|
|
13
|
+
backgroundImage: `url("${k}")`
|
|
14
|
+
})), n = () => {
|
|
15
|
+
o.value && (e = new ResizeObserver(() => {
|
|
16
|
+
}), e.observe(o.value), l(() => {
|
|
17
|
+
t.value = !0;
|
|
22
18
|
}));
|
|
23
|
-
},
|
|
19
|
+
}, r = () => {
|
|
24
20
|
e == null || e.disconnect();
|
|
25
21
|
};
|
|
26
|
-
return
|
|
22
|
+
return u(n), f(r), { __sfc: !0, trans: c, containerRef: o, isContainerReady: t, previewStore: i, resizeObserver: e, centerBackgroundStyle: a, initIframe: n, cleanIframe: r, desktopMockupLeft: _, desktopMockupRight: v };
|
|
27
23
|
}
|
|
28
24
|
});
|
|
29
25
|
export {
|
|
30
|
-
|
|
26
|
+
x as default
|
|
31
27
|
};
|
|
@@ -2,15 +2,15 @@ import i from "./EmailSizeIndicator.vue2.js";
|
|
|
2
2
|
/* empty css */
|
|
3
3
|
import r from "../../../../_virtual/_plugin-vue2_normalizer.js";
|
|
4
4
|
var o = function() {
|
|
5
|
-
var
|
|
6
|
-
return e("div", { staticClass: "d-f a-i-c j-c-c" }, [e
|
|
5
|
+
var t = this, s = t._self._c, e = t._self._setupProxy;
|
|
6
|
+
return e.previewStore.previewHtml ? s("div", { staticClass: "d-f a-i-c j-c-c" }, [s(e.InProgress, { staticClass: "min-w-15-s", attrs: { id: "email-size-progress", "description-status": "", "description-position": "left", description: e.htmlSize, "max-value": e.MAX_EMAIL_SIZE_IN_KB, type: e.progress.type, value: e.progress.value } }), s(e.InTooltip, { staticClass: "d-f ml-1", attrs: { id: "email-size-tooltip", align: "center", position: "bottom", text: e.trans("email-editor.preview-design-size-tooltip") } })], 1) : t._e();
|
|
7
7
|
}, a = [], n = /* @__PURE__ */ r(
|
|
8
8
|
i,
|
|
9
9
|
o,
|
|
10
10
|
a,
|
|
11
11
|
!1,
|
|
12
12
|
null,
|
|
13
|
-
"
|
|
13
|
+
"913a3417"
|
|
14
14
|
);
|
|
15
15
|
const m = n.exports;
|
|
16
16
|
export {
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import n from "./ContentView.vue2.js";
|
|
2
2
|
import e from "../../../../_virtual/_plugin-vue2_normalizer.js";
|
|
3
|
-
var
|
|
3
|
+
var c = function() {
|
|
4
4
|
var a = this, s = a._self._c, t = a._self._setupProxy;
|
|
5
5
|
return s("div", { staticClass: "w-1 h-1 b-c-4 d-f f-d-c" }, [s("div", { staticClass: "d-f j-c-s-b a-i-c p-2 h-6-s" }, [s("div", { staticClass: "d-f a-i-c cur-p", on: { click: function(l) {
|
|
6
6
|
return a.$emit("back-to-inbox");
|
|
7
|
-
} } }, [s(t.InIcons, { staticClass: "f-s-3 i-c-7", attrs: { name: "line-chevron-left" } }), s("span", { staticClass: "ml-2 f-s-1 f-w-400 l-h-1 t-c-7" }, [a._v(a._s(t.trans("newsletter.inbox")))])], 1), s("div", { staticClass: "d-f a-i-c" }, [s(t.InIcons, { staticClass: "i-c-52", attrs: { name: "line-chevron-down" } }), s(t.InIcons, { staticClass: "ml-1 i-c-52", attrs: { name: "line-chevron-up" } })], 1)]), s("iframe", { ref: "iframeRef", staticClass: "f-g-1 w-1 d-b b-c-4 bor-s-n", attrs: { sandbox: "allow-same-origin allow-popups allow-forms allow-scripts
|
|
8
|
-
},
|
|
7
|
+
} } }, [s(t.InIcons, { staticClass: "f-s-3 i-c-7", attrs: { name: "line-chevron-left" } }), s("span", { staticClass: "ml-2 f-s-1 f-w-400 l-h-1 t-c-7" }, [a._v(a._s(t.trans("newsletter.inbox")))])], 1), s("div", { staticClass: "d-f a-i-c" }, [s(t.InIcons, { staticClass: "i-c-52", attrs: { name: "line-chevron-down" } }), s(t.InIcons, { staticClass: "ml-1 i-c-52", attrs: { name: "line-chevron-up" } })], 1)]), s("iframe", { ref: "iframeRef", staticClass: "f-g-1 w-1 d-b b-c-4 bor-s-n", attrs: { sandbox: "allow-same-origin allow-popups allow-forms allow-scripts", srcdoc: t.previewStore.previewHtml }, on: { load: t.onLoad } })]);
|
|
8
|
+
}, i = [], o = /* @__PURE__ */ e(
|
|
9
9
|
n,
|
|
10
|
-
o,
|
|
11
10
|
c,
|
|
11
|
+
i,
|
|
12
12
|
!1,
|
|
13
13
|
null,
|
|
14
14
|
null
|
|
15
15
|
);
|
|
16
|
-
const d =
|
|
16
|
+
const d = o.exports;
|
|
17
17
|
export {
|
|
18
18
|
d as default
|
|
19
19
|
};
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
return s("div", { staticClass: "d-f j-c-c pl-5" }, [s("div", { staticClass: "p-r w-35-s h-26-s" }, [s("img", { staticClass: "w-1 h-1 d-b p-e-n", attrs: { alt: e.mockup.alt, src: e.mockup.image } }), s("div", { staticClass: "p-a w-21-s h-24-s o-h", style: { top: e.phoneScreenTopMargin, left: "20px" } }, [e.showInbox ? s(e.InboxView, { on: { "open-email": e.openEmail } }) : s(e.ContentView, { on: { "back-to-inbox": e.backToInbox } })], 1)])]);
|
|
6
|
-
}, r = [],
|
|
7
|
-
|
|
8
|
-
|
|
1
|
+
import o from "./MobilePreview.vue2.js";
|
|
2
|
+
import a from "../../../../_virtual/_plugin-vue2_normalizer.js";
|
|
3
|
+
var i = function() {
|
|
4
|
+
var t = this, s = t._self._c, e = t._self._setupProxy;
|
|
5
|
+
return s("div", { staticClass: "mobile-preview-wrapper" }, [s("p", { staticClass: "f-s-1 f-w-600 l-h-1 t-t-u t-c-53 ml-5 mb-6 l-s-5" }, [t._v(" " + t._s(e.trans("email-editor.mobile-preview")) + " ")]), s("div", { staticClass: "d-f j-c-c pl-5" }, [s("div", { staticClass: "mobile-preview-wrapper__phone p-r w-35-s h-26-s" }, [s("img", { staticClass: "w-1 h-1 d-b p-e-n", attrs: { alt: e.mockup.alt, src: e.mockup.image } }), s("div", { staticClass: "p-a w-21-s h-24-s o-h", style: { top: e.phoneScreenTopMargin, left: "20px" } }, [e.showInbox ? s(e.InboxView, { on: { "open-email": e.openEmail } }) : s(e.ContentView, { on: { "back-to-inbox": e.backToInbox } })], 1)])])]);
|
|
6
|
+
}, r = [], n = /* @__PURE__ */ a(
|
|
7
|
+
o,
|
|
8
|
+
i,
|
|
9
9
|
r,
|
|
10
10
|
!1,
|
|
11
11
|
null,
|
|
12
12
|
null
|
|
13
13
|
);
|
|
14
|
-
const
|
|
14
|
+
const m = n.exports;
|
|
15
15
|
export {
|
|
16
|
-
|
|
16
|
+
m as default
|
|
17
17
|
};
|
|
@@ -1,22 +1,23 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import c from "../../../../static/assets/
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
|
|
1
|
+
import { defineComponent as a, ref as i, computed as e } from "vue";
|
|
2
|
+
import { useTranslations as s } from "../../../../composables/useTranslations.js";
|
|
3
|
+
import c from "../../../../static/assets/mobile/email-mockup.svg.js";
|
|
4
|
+
import u from "../../../../static/assets/mobile/inbox-mockup.svg.js";
|
|
5
|
+
import f from "./ContentView.vue.js";
|
|
6
|
+
import l from "./InboxView.vue.js";
|
|
7
|
+
const k = /* @__PURE__ */ a({
|
|
7
8
|
__name: "MobilePreview",
|
|
8
|
-
setup(
|
|
9
|
-
const o = i(!1),
|
|
10
|
-
image: o.value ?
|
|
9
|
+
setup(v) {
|
|
10
|
+
const n = s(), o = i(!1), r = e(() => ({
|
|
11
|
+
image: o.value ? u : c,
|
|
11
12
|
alt: o.value ? "Inbox mockup" : "Phone mockup"
|
|
12
|
-
})),
|
|
13
|
+
})), t = () => {
|
|
13
14
|
o.value = !1;
|
|
14
|
-
},
|
|
15
|
+
}, m = () => {
|
|
15
16
|
o.value = !0;
|
|
16
|
-
}, p = e(() => o.value ? "88px" : "
|
|
17
|
-
return { __sfc: !0, showInbox: o, mockup:
|
|
17
|
+
}, p = e(() => o.value ? "88px" : "64px");
|
|
18
|
+
return { __sfc: !0, trans: n, showInbox: o, mockup: r, openEmail: t, backToInbox: m, phoneScreenTopMargin: p, ContentView: f, InboxView: l };
|
|
18
19
|
}
|
|
19
20
|
});
|
|
20
21
|
export {
|
|
21
|
-
|
|
22
|
+
k as default
|
|
22
23
|
};
|
|
@@ -3,14 +3,14 @@ import s from "./LeftSlot.vue2.js";
|
|
|
3
3
|
import r from "../../../_virtual/_plugin-vue2_normalizer.js";
|
|
4
4
|
var n = function() {
|
|
5
5
|
var e = this, o = e._self._c, t = e._self._setupProxy;
|
|
6
|
-
return o("div", { staticClass: "d-f a-i-c" }, [o(t.InButtonV2, { staticClass: "p-2", attrs: { id: "guido__back-button", "left-icon": "line-arrow-left", styling: "
|
|
6
|
+
return o("div", { staticClass: "d-f a-i-c" }, [o(t.InButtonV2, { staticClass: "p-2", attrs: { id: "guido__back-button", "left-icon": "line-arrow-left", styling: "ghost", type: "secondary", "label-text": t.backButtonLabel }, on: { click: t.handleBackClick } }), t.editorStore.isVersionHistoryOpen ? o(t.RestoreButton, { staticClass: "ml-3" }) : e._e()], 1);
|
|
7
7
|
}, a = [], i = /* @__PURE__ */ r(
|
|
8
8
|
s,
|
|
9
9
|
n,
|
|
10
10
|
a,
|
|
11
11
|
!1,
|
|
12
12
|
null,
|
|
13
|
-
"
|
|
13
|
+
"f0b166f5"
|
|
14
14
|
);
|
|
15
15
|
const p = i.exports;
|
|
16
16
|
export {
|
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
import i from "./MiddleSlot.vue2.js";
|
|
2
|
+
/* empty css */
|
|
2
3
|
import s from "../../../_virtual/_plugin-vue2_normalizer.js";
|
|
3
4
|
var n = function() {
|
|
4
5
|
var e = this, o = e._self._c, t = e._self._setupProxy;
|
|
5
|
-
return t.editorStore.isVersionHistoryOpen ? o("div", { staticClass: "d-f" }, [o(t.VersionHistory), o(t.VersionHistoryViewOptions)], 1) : o("div", { staticClass: "d-f" }, [o(t.InButtonV2, { attrs: { id: "guido__undo-button", "left-icon": "line-undo", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isUndoButtonDisabled, "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__undo-button"), "tooltip-text": t.trans("action-builder.undo") } }), o(t.InButtonV2, { attrs: { id: "guido__redo-button", "left-icon": "line-redo", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isRedoButtonDisabled, "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__redo-button"), "tooltip-text": t.trans("action-builder.redo") } }), o(t.InButtonV2, { attrs: { id: "guido__code-button", "data-testid": "Code Editor", "left-icon": "line-code", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isCodeEditorButtonDisabled, "label-text-status": !1, "selected-status": t.editorStore.isCodeEditorOpen, "tooltip-options": t.getTooltipOptions("guido__code-button"), "tooltip-text": t.codeEditorTooltipText } }), o(t.InButtonV2, { attrs: { id: "guido__preview-button", "left-icon": "line-show-on", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isPreviewButtonDisabled, "label-text-status": !1, "selected-status": t.editorStore.isPreviewModeOpen, "tooltip-options": t.getTooltipOptions("guido__preview-button"), "tooltip-text": t.previewTooltipText }, on: { click: t.handlePreviewToggle } }), o(t.ViewOptions, { staticClass: "ml-
|
|
6
|
+
return t.editorStore.isVersionHistoryOpen ? o("div", { staticClass: "d-f" }, [o(t.VersionHistory), o(t.VersionHistoryViewOptions)], 1) : t.editorStore.isPreviewModeOpen ? o("div", { staticClass: "d-f" }, [o(t.EmailSizeIndicator), o(t.AmpToggle)], 1) : o("div", { staticClass: "d-f middle-slot__buttons" }, [o(t.InButtonV2, { attrs: { id: "guido__undo-button", "left-icon": "line-undo", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isUndoButtonDisabled, "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__undo-button"), "tooltip-text": t.trans("action-builder.undo") } }), o(t.InButtonV2, { attrs: { id: "guido__redo-button", "left-icon": "line-redo", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isRedoButtonDisabled, "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__redo-button"), "tooltip-text": t.trans("action-builder.redo") } }), o(t.InButtonV2, { attrs: { id: "guido__code-button", "data-testid": "Code Editor", "left-icon": "line-code", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isCodeEditorButtonDisabled, "label-text-status": !1, "selected-status": t.editorStore.isCodeEditorOpen, "tooltip-options": t.getTooltipOptions("guido__code-button"), "tooltip-text": t.codeEditorTooltipText } }), o(t.InButtonV2, { attrs: { id: "guido__preview-button", "left-icon": "line-show-on", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isPreviewButtonDisabled, "label-text-status": !1, "selected-status": t.editorStore.isPreviewModeOpen, "tooltip-options": t.getTooltipOptions("guido__preview-button"), "tooltip-text": t.previewTooltipText }, on: { click: t.handlePreviewToggle } }), o(t.ViewOptions, { staticClass: "ml-2" })], 1);
|
|
6
7
|
}, d = [], l = /* @__PURE__ */ s(
|
|
7
8
|
i,
|
|
8
9
|
n,
|
|
9
10
|
d,
|
|
10
11
|
!1,
|
|
11
12
|
null,
|
|
12
|
-
|
|
13
|
+
"421621fe"
|
|
13
14
|
);
|
|
14
|
-
const
|
|
15
|
+
const _ = l.exports;
|
|
15
16
|
export {
|
|
16
|
-
|
|
17
|
+
_ as default
|
|
17
18
|
};
|
|
@@ -1,20 +1,21 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { usePreviewMode as
|
|
1
|
+
import { defineComponent as m, computed as i } from "vue";
|
|
2
|
+
import { usePreviewMode as p } from "../../../composables/usePreviewMode.js";
|
|
3
3
|
import { useTranslations as l } from "../../../composables/useTranslations.js";
|
|
4
4
|
import d from "../email-preview/amp/AmpToggle.vue.js";
|
|
5
|
-
import
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import a from "
|
|
9
|
-
import v from "./version-history/
|
|
10
|
-
import u from "./ViewOptions.vue.js";
|
|
11
|
-
|
|
5
|
+
import w from "../email-preview/desktop-preview/EmailSizeIndicator.vue.js";
|
|
6
|
+
import { useEditorStore as c } from "../../../stores/editor.js";
|
|
7
|
+
import { getTooltipOptions as f } from "../../../utils/tooltipUtils.js";
|
|
8
|
+
import { InButtonV2 as a } from "@useinsider/design-system-vue";
|
|
9
|
+
import v from "./version-history/VersionHistory.vue.js";
|
|
10
|
+
import u from "./version-history/ViewOptions.vue.js";
|
|
11
|
+
import T from "./ViewOptions.vue.js";
|
|
12
|
+
const I = /* @__PURE__ */ m({
|
|
12
13
|
__name: "MiddleSlot",
|
|
13
|
-
setup(
|
|
14
|
-
const o =
|
|
15
|
-
return { __sfc: !0, editorStore: o, trans: e, openPreviewMode: t, closePreviewMode: r, previewTooltipText: s, codeEditorTooltipText: n, handlePreviewToggle: () => o.isPreviewModeOpen ? r() : t(), AmpToggle: d, getTooltipOptions:
|
|
14
|
+
setup(_) {
|
|
15
|
+
const o = c(), e = l(), { openPreviewMode: t, closePreviewMode: r } = p(), s = i(() => o.isPreviewModeOpen ? e("newsletter.close-email-preview") : e("newsletter.email-preview")), n = i(() => o.isCodeEditorOpen ? e("newsletter.close-html-editor") : e("newsletter.html-editor"));
|
|
16
|
+
return { __sfc: !0, editorStore: o, trans: e, openPreviewMode: t, closePreviewMode: r, previewTooltipText: s, codeEditorTooltipText: n, handlePreviewToggle: () => o.isPreviewModeOpen ? r() : t(), AmpToggle: d, EmailSizeIndicator: w, getTooltipOptions: f, InButtonV2: a, VersionHistory: v, VersionHistoryViewOptions: u, ViewOptions: T };
|
|
16
17
|
}
|
|
17
18
|
});
|
|
18
19
|
export {
|
|
19
|
-
|
|
20
|
+
I as default
|
|
20
21
|
};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
1
|
+
import d from "./RightSlot.vue2.js";
|
|
2
|
+
import u from "../../../_virtual/_plugin-vue2_normalizer.js";
|
|
3
3
|
var p = function() {
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
return
|
|
4
|
+
var s, i, n, a, l, r;
|
|
5
|
+
var e = this, o = e._self._c, t = e._self._setupProxy;
|
|
6
|
+
return o("div", { staticClass: "d-f" }, [(i = (s = t.config) == null ? void 0 : s.features) != null && i.versionHistory && !t.editorStore.isPreviewModeOpen ? o(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 } }) : e._e(), o(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 } }), (a = (n = t.config) == null ? void 0 : n.features) != null && a.saveAsTemplate ? o(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 } }) : e._e(), (r = (l = t.config) == null ? void 0 : l.features) != null && r.testMessage ? 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"), "tooltip-text": t.trans("newsletter.test-email") }, on: { click: t.testEmailClick } }) : e._e(), 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(f) {
|
|
7
7
|
return t.handleSave(!1);
|
|
8
8
|
} } })], 1);
|
|
9
|
-
}, c = [], _ = /* @__PURE__ */
|
|
10
|
-
|
|
9
|
+
}, c = [], _ = /* @__PURE__ */ u(
|
|
10
|
+
d,
|
|
11
11
|
p,
|
|
12
12
|
c,
|
|
13
13
|
!1,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import r from "./WpModal.vue2.js";
|
|
2
|
+
/* empty css */
|
|
2
3
|
import s from "../../_virtual/_plugin-vue2_normalizer.js";
|
|
3
4
|
var i = function() {
|
|
4
5
|
var t = this, o = t._self._c, e = t._self._setupProxy;
|
|
@@ -19,9 +20,9 @@ var i = function() {
|
|
|
19
20
|
u,
|
|
20
21
|
!1,
|
|
21
22
|
null,
|
|
22
|
-
|
|
23
|
+
"5269640b"
|
|
23
24
|
);
|
|
24
|
-
const
|
|
25
|
+
const _ = c.exports;
|
|
25
26
|
export {
|
|
26
|
-
|
|
27
|
+
_ as default
|
|
27
28
|
};
|
|
@@ -1,25 +1,26 @@
|
|
|
1
|
-
import { useActionsApi as
|
|
2
|
-
import { useBlocksConfig as
|
|
3
|
-
import { useConfig as
|
|
4
|
-
import { useCustomInterfaceAppearance as
|
|
5
|
-
import { useStripoEventHandler as
|
|
6
|
-
import { useToaster as
|
|
1
|
+
import { useActionsApi as T } from "./useActionsApi.js";
|
|
2
|
+
import { useBlocksConfig as V } from "./useBlocksConfig.js";
|
|
3
|
+
import { useConfig as _ } from "./useConfig.js";
|
|
4
|
+
import { useCustomInterfaceAppearance as B } from "./useCustomInterfaceAppearance.js";
|
|
5
|
+
import { useStripoEventHandler as v } from "./useStripoEventHandler.js";
|
|
6
|
+
import { useToaster as A } from "./useToaster.js";
|
|
7
7
|
import { displayConditions as F } from "../enums/displayConditions.js";
|
|
8
8
|
import { useStripoApi as D } from "../services/stripoApi.js";
|
|
9
9
|
import I from "../static/styles/customEditorStyle.css.js";
|
|
10
10
|
import { useEditorStore as M } from "../stores/editor.js";
|
|
11
11
|
import { dynamicContentToMergeTags as U } from "../utils/genericUtil.js";
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
12
|
+
import P from "../package.json.js";
|
|
13
|
+
const K = (c) => {
|
|
14
|
+
const { features: l } = _(), { handleError: u } = A(), { getToken: y, getCustomFonts: S } = D(), { handleEvent: C } = v(), { getStripoBlocksConfig: E } = V(), h = async (i, n = []) => {
|
|
15
|
+
var g, f;
|
|
16
|
+
const o = M(), { html: r, css: p, forceRecreate: a } = i, { baseBlocks: t, extensions: d } = await E(), m = ((g = l.value) == null ? void 0 : g.displayConditions) ?? !0, b = ((f = l.value) == null ? void 0 : f.modulesDisabled) ?? !1;
|
|
16
17
|
window.UIEditor.initEditor(
|
|
17
18
|
document.querySelector("#guido-editor"),
|
|
18
19
|
{
|
|
19
|
-
metadata:
|
|
20
|
-
html:
|
|
21
|
-
css:
|
|
22
|
-
forceRecreate:
|
|
20
|
+
metadata: c,
|
|
21
|
+
html: r,
|
|
22
|
+
css: p,
|
|
23
|
+
forceRecreate: a,
|
|
23
24
|
locale: "en",
|
|
24
25
|
undoButtonSelector: "#guido__undo-button",
|
|
25
26
|
redoButtonSelector: "#guido__redo-button",
|
|
@@ -30,8 +31,8 @@ const $ = (a) => {
|
|
|
30
31
|
customAppearanceMergetagsBorderColor: "#f1f3fe",
|
|
31
32
|
customAppearanceMergetagsBackgroundColor: "#f1f3fe",
|
|
32
33
|
customViewStyles: I,
|
|
33
|
-
conditionsEnabled:
|
|
34
|
-
customConditionsEnabled:
|
|
34
|
+
conditionsEnabled: m,
|
|
35
|
+
customConditionsEnabled: m,
|
|
35
36
|
conditionCategories: F,
|
|
36
37
|
enableXSSSecurity: !0,
|
|
37
38
|
modulesDisabled: b,
|
|
@@ -41,7 +42,7 @@ const $ = (a) => {
|
|
|
41
42
|
displayTitle: !1,
|
|
42
43
|
displayUTM: !1,
|
|
43
44
|
selectElementAfterDrop: !0,
|
|
44
|
-
...
|
|
45
|
+
...t ? { baseBlocks: t } : {},
|
|
45
46
|
editorFonts: {
|
|
46
47
|
showDefaultStandardFonts: !0,
|
|
47
48
|
showDefaultNotStandardFonts: !0,
|
|
@@ -49,25 +50,25 @@ const $ = (a) => {
|
|
|
49
50
|
},
|
|
50
51
|
mergeTags: [
|
|
51
52
|
{
|
|
52
|
-
entries: U(
|
|
53
|
+
entries: U(c.preselectedDynamicContentList)
|
|
53
54
|
}
|
|
54
55
|
],
|
|
55
56
|
async onTokenRefreshRequest(e) {
|
|
56
57
|
try {
|
|
57
|
-
const
|
|
58
|
-
e(
|
|
59
|
-
} catch (
|
|
60
|
-
|
|
58
|
+
const s = await y();
|
|
59
|
+
e(s);
|
|
60
|
+
} catch (s) {
|
|
61
|
+
u(s, "Failed to refresh token");
|
|
61
62
|
}
|
|
62
63
|
},
|
|
63
64
|
onTemplateLoaded() {
|
|
64
65
|
try {
|
|
65
|
-
const { importCss: e } =
|
|
66
|
-
e(),
|
|
66
|
+
const { importCss: e } = B(), { activateCustomViewStyles: s, updateTimerInClonedTemplate: k } = T();
|
|
67
|
+
e(), s(), k(), c.onReady(), o.isStripoInitialized = !0, o.loadingStatus = !1, setTimeout(() => {
|
|
67
68
|
o.hasChanges = !1;
|
|
68
69
|
}, 1e3);
|
|
69
70
|
} catch (e) {
|
|
70
|
-
|
|
71
|
+
u(e, "Failed to load custom interface appearance");
|
|
71
72
|
}
|
|
72
73
|
},
|
|
73
74
|
onCodeEditorVisibilityChanged(e) {
|
|
@@ -82,34 +83,35 @@ const $ = (a) => {
|
|
|
82
83
|
onDataChanged() {
|
|
83
84
|
o.hasChanges = !0;
|
|
84
85
|
},
|
|
85
|
-
onEvent:
|
|
86
|
+
onEvent: C,
|
|
86
87
|
ignoreClickOutsideSelectors: [
|
|
87
88
|
"#guido-dynamic-content-modal",
|
|
88
89
|
".in-on-board-wrapper",
|
|
89
90
|
".in-drawer__container"
|
|
90
91
|
],
|
|
91
|
-
extensions:
|
|
92
|
+
extensions: d
|
|
92
93
|
}
|
|
93
94
|
);
|
|
94
|
-
},
|
|
95
|
+
}, w = (i) => new Promise((n, o) => {
|
|
96
|
+
var d;
|
|
95
97
|
if (document.getElementById("UiEditorScript")) {
|
|
96
98
|
i(), n();
|
|
97
99
|
return;
|
|
98
100
|
}
|
|
99
|
-
const
|
|
100
|
-
t.id = "UiEditorScript", t.type = "module", t.src =
|
|
101
|
+
const r = P.guido, a = `https://email-static.useinsider.com/guido/${(d = r == null ? void 0 : r.stripo) == null ? void 0 : d.version}/UIEditor.js`, t = document.createElement("script");
|
|
102
|
+
t.id = "UiEditorScript", t.type = "module", t.src = a, t.onload = () => {
|
|
101
103
|
i(), n();
|
|
102
104
|
}, t.onerror = () => {
|
|
103
|
-
o(new Error(`Failed to load Stripo UIEditor script from S3: ${
|
|
105
|
+
o(new Error(`Failed to load Stripo UIEditor script from S3: ${a}`));
|
|
104
106
|
}, document.body.appendChild(t);
|
|
105
107
|
});
|
|
106
108
|
return { initPlugin: async (i) => {
|
|
107
|
-
await
|
|
108
|
-
const n = await
|
|
109
|
-
await
|
|
109
|
+
await w(async () => {
|
|
110
|
+
const n = await S();
|
|
111
|
+
await h(i, n);
|
|
110
112
|
});
|
|
111
113
|
} };
|
|
112
114
|
};
|
|
113
115
|
export {
|
|
114
|
-
|
|
116
|
+
K as useStripo
|
|
115
117
|
};
|
|
@@ -1,13 +1,12 @@
|
|
|
1
|
-
import { migrateCheckbox as
|
|
1
|
+
import { migrateCheckbox as m } from "./checkboxMigrator.js";
|
|
2
2
|
import { migrateCouponBlock as o } from "./couponBlockMigrator.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
return m = t(m), m = e(m), m = await g(m), m = o(m), m = a(m), m = i(m), m;
|
|
3
|
+
import { migrateRadioButton as i } from "./radioButtonMigrator.js";
|
|
4
|
+
import { migrateRecommendation as e } from "./recommendationMigrator.js";
|
|
5
|
+
import { migrateUnsubscribe as a } from "./unsubscribeMigrator.js";
|
|
6
|
+
const s = async (t) => {
|
|
7
|
+
let r = t;
|
|
8
|
+
return r = m(r), r = i(r), r = await a(r), r = o(r), r = e(r), r;
|
|
10
9
|
};
|
|
11
10
|
export {
|
|
12
|
-
|
|
11
|
+
s as migrate
|
|
13
12
|
};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
var t = /* @__PURE__ */ ((c) => (c.TEXT_ALIGN = "coupon-block-text-align-control", c.TEXT_COLOR = "coupon-block-text-color-control", c.TEXT_SIZE = "coupon-block-text-size-control", c.TEXT_STYLE = "coupon-block-text-style-control", c.TEXT_FONT_FAMILY = "coupon-block-text-font-family-control", c.TEXT_BACKGROUND = "coupon-block-text-background-control", c.TEXT_PADDINGS = "coupon-block-text-paddings-control", c.TEXT_LINE_SPACING = "coupon-block-text-line-spacing-control", c))(t || {});
|
|
2
|
+
export {
|
|
3
|
+
t as CouponControlId
|
|
4
|
+
};
|