@useinsider/guido 3.2.0-beta.e01b42a → 3.2.0-beta.e69fb3b
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/README.md +1 -0
- package/dist/@types/config/schemas.js +66 -54
- package/dist/@types/config/validator.js +27 -34
- package/dist/components/Guido.vue.js +4 -4
- package/dist/components/Guido.vue2.js +87 -82
- package/dist/components/organisms/base/Toaster.vue2.js +10 -11
- package/dist/components/organisms/email-preview/desktop-preview/DesktopPreview.vue2.js +12 -12
- package/dist/components/organisms/email-preview/desktop-preview/EmailSizeIndicator.vue.js +7 -7
- package/dist/components/organisms/email-preview/desktop-preview/EmailSizeIndicator.vue2.js +12 -20
- package/dist/components/organisms/email-preview/mobile-preview/ContentView.vue2.js +6 -6
- package/dist/components/organisms/email-preview/mobile-preview/InboxView.vue2.js +9 -15
- package/dist/components/organisms/extensions/recommendation/FilterItem.vue2.js +31 -40
- package/dist/components/organisms/extensions/recommendation/FilterSelectionDrawer.vue2.js +19 -20
- package/dist/components/organisms/extensions/recommendation/Filters.vue2.js +11 -14
- package/dist/components/organisms/header/EditorActions.vue.js +12 -13
- package/dist/components/organisms/header/EditorActions.vue2.js +51 -40
- package/dist/components/organisms/header/HeaderWrapper.vue2.js +12 -15
- package/dist/components/organisms/header/LeftSlot.vue2.js +16 -19
- package/dist/components/organisms/header/MiddleSlot.vue2.js +14 -11
- package/dist/components/organisms/header/RightSlot.vue.js +10 -10
- package/dist/components/organisms/header/RightSlot.vue2.js +13 -13
- package/dist/components/organisms/onboarding/AMPOnboarding.vue.js +11 -12
- package/dist/components/organisms/onboarding/AMPOnboarding.vue2.js +49 -31
- package/dist/components/organisms/onboarding/GenericOnboarding.vue.js +12 -13
- package/dist/components/organisms/onboarding/GenericOnboarding.vue2.js +36 -38
- package/dist/components/organisms/onboarding/ItemsOnboarding.vue.js +12 -13
- package/dist/components/organisms/onboarding/ItemsOnboarding.vue2.js +47 -51
- package/dist/components/organisms/onboarding/NewVersionPopup.vue2.js +18 -21
- package/dist/components/organisms/onboarding/OnboardingWrapper.vue2.js +27 -31
- package/dist/components/organisms/onboarding/TextBlockOnboarding.vue.js +12 -13
- package/dist/components/organisms/onboarding/TextBlockOnboarding.vue2.js +33 -46
- package/dist/components/organisms/onboarding/VersionHistoryOnboarding.vue.js +11 -12
- package/dist/components/organisms/onboarding/VersionHistoryOnboarding.vue2.js +20 -21
- package/dist/components/organisms/save-as-template/SaveAsTemplateDrawer.vue2.js +18 -18
- package/dist/components/organisms/unsubscribe/UnsubscribeWrapper.vue.js +9 -10
- package/dist/composables/useActionsApi.js +37 -38
- package/dist/composables/useBlocksConfig.js +26 -26
- package/dist/composables/useFullStoryBridge.js +13 -0
- package/dist/composables/useHtmlCompiler.js +34 -24
- package/dist/composables/useHtmlValidator.js +91 -97
- package/dist/composables/useHttp.js +30 -30
- package/dist/composables/usePartner.js +1 -1
- package/dist/composables/usePreviewMode.js +20 -16
- package/dist/composables/useRecommendation.js +14 -15
- package/dist/composables/useRibbonOffset.js +21 -0
- package/dist/composables/useSave.js +23 -16
- package/dist/composables/useStripo.js +55 -47
- package/dist/composables/useSyncModuleExtractor.js +31 -29
- package/dist/composables/useTimerClone.js +24 -25
- package/dist/composables/useTranslations.js +2 -3
- package/dist/composables/useValidation.js +7 -8
- package/dist/composables/validators/useLiquidValidator.js +42 -0
- package/dist/config/compiler/liquidCompilerRules.js +15 -0
- package/dist/config/compiler/recommendationCompilerRules.js +162 -43
- package/dist/config/compiler/unsubscribeCompilerRules.js +45 -44
- package/dist/config/compiler/utils/recommendationCompilerUtils.js +51 -46
- package/dist/config/migrator/checkboxMigrator.js +23 -22
- package/dist/config/migrator/couponBlockMigrator.js +18 -19
- package/dist/config/migrator/itemsBlockMigrator.js +87 -89
- package/dist/config/migrator/radioButtonMigrator.js +19 -18
- package/dist/config/migrator/recommendationMigrator.js +107 -110
- package/dist/config/migrator/unsubscribeMigrator.js +10 -11
- package/dist/enums/extensions/recommendationBlock.js +14 -11
- package/dist/enums/onboarding.js +7 -2
- package/dist/enums/recommendation.js +2 -2
- package/dist/enums/unsubscribe.js +33 -27
- package/dist/extensions/Blocks/CouponBlock/template.js +24 -13
- package/dist/extensions/Blocks/Items/block.js +9 -9
- package/dist/extensions/Blocks/Items/controls/button/link.js +14 -14
- package/dist/extensions/Blocks/Items/controls/cardComposition.js +89 -97
- package/dist/extensions/Blocks/Items/controls/image/link.js +14 -14
- package/dist/extensions/Blocks/Items/controls/name/trimming.js +23 -24
- package/dist/extensions/Blocks/Items/controls/price/currencyLocation.js +13 -14
- package/dist/extensions/Blocks/Items/controls/price/currencySymbol.js +44 -47
- package/dist/extensions/Blocks/Items/controls/price/formattedPrice.js +38 -38
- package/dist/extensions/Blocks/Items/controls/price/hideDiscount.js +11 -11
- package/dist/extensions/Blocks/Items/controls/price/priceOrientation.js +38 -40
- package/dist/extensions/Blocks/Items/controls/price/singlePrice.js +35 -35
- package/dist/extensions/Blocks/Items/controls/settingsControl.js +155 -162
- package/dist/extensions/Blocks/Items/enums/productEnums.js +21 -14
- package/dist/extensions/Blocks/Items/template.js +210 -210
- package/dist/extensions/Blocks/Recommendation/constants/controlIds.js +1 -1
- package/dist/extensions/Blocks/Recommendation/constants/selectors.js +27 -11
- package/dist/extensions/Blocks/Recommendation/controls/button/index.js +36 -36
- package/dist/extensions/Blocks/Recommendation/controls/cardComposition/index.js +208 -200
- package/dist/extensions/Blocks/Recommendation/controls/customAttribute/index.js +23 -20
- package/dist/extensions/Blocks/Recommendation/controls/customAttribute/textTrim.js +99 -0
- package/dist/extensions/Blocks/Recommendation/controls/image/index.js +9 -9
- package/dist/extensions/Blocks/Recommendation/controls/main/algorithm.js +19 -20
- package/dist/extensions/Blocks/Recommendation/controls/main/filters.js +4 -6
- package/dist/extensions/Blocks/Recommendation/controls/main/index.js +84 -90
- package/dist/extensions/Blocks/Recommendation/controls/main/layoutOrientation.js +18 -18
- package/dist/extensions/Blocks/Recommendation/controls/main/productCount.js +4 -4
- package/dist/extensions/Blocks/Recommendation/controls/main/productLayout.js +35 -36
- package/dist/extensions/Blocks/Recommendation/controls/main/utils.js +127 -126
- package/dist/extensions/Blocks/Recommendation/controls/name/index.js +24 -24
- package/dist/extensions/Blocks/Recommendation/controls/name/textTrim.js +27 -57
- package/dist/extensions/Blocks/Recommendation/controls/oldPrice/index.js +24 -24
- package/dist/extensions/Blocks/Recommendation/controls/omnibusDiscount/index.js +24 -24
- package/dist/extensions/Blocks/Recommendation/controls/omnibusDiscount/textAfter.js +4 -4
- package/dist/extensions/Blocks/Recommendation/controls/omnibusDiscount/textBefore.js +4 -4
- package/dist/extensions/Blocks/Recommendation/controls/omnibusPrice/index.js +24 -24
- package/dist/extensions/Blocks/Recommendation/controls/omnibusPrice/textAfter.js +4 -4
- package/dist/extensions/Blocks/Recommendation/controls/omnibusPrice/textBefore.js +4 -4
- package/dist/extensions/Blocks/Recommendation/controls/price/index.js +24 -24
- package/dist/extensions/Blocks/Recommendation/controls/shared/textTrimCssRules.js +14 -0
- package/dist/extensions/Blocks/Recommendation/controls/spacing/index.js +50 -50
- package/dist/extensions/Blocks/Recommendation/controls/syncInfoMessage.js +18 -20
- package/dist/extensions/Blocks/Recommendation/extension.js +31 -32
- package/dist/extensions/Blocks/Recommendation/settingsPanel.js +25 -32
- package/dist/extensions/Blocks/Recommendation/store/recommendation.js +72 -69
- package/dist/extensions/Blocks/Recommendation/templates/grid/elementRenderer.js +24 -23
- package/dist/extensions/Blocks/Recommendation/templates/grid/migration.js +10 -10
- package/dist/extensions/Blocks/Recommendation/templates/grid/template.js +28 -27
- package/dist/extensions/Blocks/Recommendation/templates/index.js +9 -9
- package/dist/extensions/Blocks/Recommendation/templates/list/elementRenderer.js +26 -25
- package/dist/extensions/Blocks/Recommendation/templates/list/template.js +21 -21
- package/dist/extensions/Blocks/Recommendation/templates/utils.js +53 -48
- package/dist/extensions/Blocks/Recommendation/utils/filterUtil.js +17 -14
- package/dist/extensions/Blocks/Recommendation/validation/filterSchema.js +13 -16
- package/dist/extensions/Blocks/Unsubscribe/block.js +11 -11
- package/dist/extensions/Blocks/Unsubscribe/control.js +11 -13
- package/dist/extensions/Blocks/Unsubscribe/elements/preview.js +16 -18
- package/dist/extensions/Blocks/common-control.js +25 -26
- package/dist/extensions/DynamicContent/dynamic-content.js +59 -59
- package/dist/guido.css +1 -1
- package/dist/library.js +11 -12
- package/dist/node_modules/@stripoinc/ui-editor-extensions/dist/esm/index.js +232 -210
- package/dist/node_modules/lodash-es/_getValue.js +1 -1
- package/dist/node_modules/valibot/dist/index.js +122 -126
- package/dist/package.json.js +1 -1
- package/dist/services/recommendationApi.js +12 -15
- package/dist/services/stripoApi.js +9 -9
- package/dist/services/templateLibraryApi.js +49 -48
- package/dist/src/@types/config/index.d.ts +1 -1
- package/dist/src/@types/config/schemas.d.ts +28 -0
- package/dist/src/@types/config/types.d.ts +3 -1
- package/dist/src/@types/generic.d.ts +0 -1
- package/dist/src/@types/save-as-template.d.ts +1 -0
- package/dist/src/components/wrappers/WpModal.vue.d.ts +1 -1
- package/dist/src/composables/useActionsApi.d.ts +1 -1
- package/dist/src/composables/useConfig.d.ts +12 -0
- package/dist/src/composables/useFullStoryBridge.d.ts +11 -0
- package/dist/src/composables/useHtmlCompiler.d.ts +1 -2
- package/dist/src/composables/useRibbonOffset.d.ts +4 -0
- package/dist/src/composables/validators/useLiquidValidator.d.ts +3 -0
- package/dist/src/config/compiler/liquidCompilerRules.d.ts +2 -0
- package/dist/src/config/compiler/utils/recommendationCompilerUtils.d.ts +1 -1
- package/dist/src/enums/extensions/recommendationBlock.d.ts +3 -0
- package/dist/src/enums/onboarding.d.ts +6 -0
- package/dist/src/enums/unsubscribe.d.ts +5 -0
- package/dist/src/extensions/Blocks/CouponBlock/template.d.ts +2 -0
- package/dist/src/extensions/Blocks/Recommendation/constants/controlIds.d.ts +1 -0
- package/dist/src/extensions/Blocks/Recommendation/constants/index.d.ts +1 -1
- package/dist/src/extensions/Blocks/Recommendation/constants/selectors.d.ts +5 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/cardComposition/index.d.ts +5 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/customAttribute/index.d.ts +3 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/customAttribute/textTrim.d.ts +35 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/name/textTrim.d.ts +3 -20
- package/dist/src/extensions/Blocks/Recommendation/controls/shared/textTrimCssRules.d.ts +29 -0
- package/dist/src/extensions/Blocks/Recommendation/templates/grid/template.d.ts +4 -4
- package/dist/src/extensions/Blocks/Recommendation/templates/list/template.d.ts +3 -3
- package/dist/src/extensions/Blocks/Recommendation/templates/utils.d.ts +20 -3
- package/dist/src/extensions/Blocks/Recommendation/utils/tagName.d.ts +3 -3
- package/dist/src/services/templateLibraryApi.d.ts +1 -1
- package/dist/src/stores/config.d.ts +108 -0
- package/dist/src/stores/dynamic-content.d.ts +3 -3
- package/dist/src/stores/onboarding.d.ts +4 -0
- package/dist/src/stores/preview.d.ts +3 -0
- package/dist/src/utils/genericUtil.d.ts +1 -1
- package/dist/src/utils/htmlCompiler.d.ts +2 -1
- package/dist/static/styles/base.css.js +7 -2
- package/dist/static/styles/components/button.css.js +3 -2
- package/dist/static/styles/components/loader.css.js +4 -0
- package/dist/stores/config.js +25 -81
- package/dist/stores/dynamic-content.js +6 -11
- package/dist/stores/onboarding.js +5 -1
- package/dist/stores/preview.js +8 -10
- package/dist/stores/unsubscribe.js +1 -4
- package/dist/utils/dateUtil.js +7 -10
- package/dist/utils/genericUtil.js +39 -20
- package/dist/utils/htmlCompiler.js +48 -41
- package/dist/utils/pairProductVariables.js +13 -14
- package/dist/utils/templatePreparation.js +36 -25
- package/dist/utils/tooltipUtils.js +4 -5
- package/package.json +9 -4
- package/dist/node_modules/lodash-es/_DataView.js +0 -6
- package/dist/node_modules/lodash-es/_Promise.js +0 -6
- package/dist/node_modules/lodash-es/_Set.js +0 -6
- package/dist/node_modules/lodash-es/_SetCache.js +0 -13
- package/dist/node_modules/lodash-es/_Stack.js +0 -18
- package/dist/node_modules/lodash-es/_Uint8Array.js +0 -5
- package/dist/node_modules/lodash-es/_WeakMap.js +0 -6
- package/dist/node_modules/lodash-es/_arrayFilter.js +0 -10
- package/dist/node_modules/lodash-es/_arrayLikeKeys.js +0 -20
- package/dist/node_modules/lodash-es/_arrayMap.js +0 -8
- package/dist/node_modules/lodash-es/_arrayPush.js +0 -8
- package/dist/node_modules/lodash-es/_arraySome.js +0 -9
- package/dist/node_modules/lodash-es/_baseEach.js +0 -6
- package/dist/node_modules/lodash-es/_baseFlatten.js +0 -13
- package/dist/node_modules/lodash-es/_baseFor.js +0 -5
- package/dist/node_modules/lodash-es/_baseForOwn.js +0 -8
- package/dist/node_modules/lodash-es/_baseGet.js +0 -11
- package/dist/node_modules/lodash-es/_baseGetAllKeys.js +0 -9
- package/dist/node_modules/lodash-es/_baseHasIn.js +0 -6
- package/dist/node_modules/lodash-es/_baseIsArguments.js +0 -9
- package/dist/node_modules/lodash-es/_baseIsEqual.js +0 -8
- package/dist/node_modules/lodash-es/_baseIsEqualDeep.js +0 -32
- package/dist/node_modules/lodash-es/_baseIsMatch.js +0 -29
- package/dist/node_modules/lodash-es/_baseIsTypedArray.js +0 -12
- package/dist/node_modules/lodash-es/_baseIteratee.js +0 -11
- package/dist/node_modules/lodash-es/_baseKeys.js +0 -14
- package/dist/node_modules/lodash-es/_baseMap.js +0 -11
- package/dist/node_modules/lodash-es/_baseMatches.js +0 -12
- package/dist/node_modules/lodash-es/_baseMatchesProperty.js +0 -17
- package/dist/node_modules/lodash-es/_baseProperty.js +0 -8
- package/dist/node_modules/lodash-es/_basePropertyDeep.js +0 -9
- package/dist/node_modules/lodash-es/_baseRange.js +0 -9
- package/dist/node_modules/lodash-es/_baseTimes.js +0 -8
- package/dist/node_modules/lodash-es/_baseToString.js +0 -18
- package/dist/node_modules/lodash-es/_baseTrim.js +0 -8
- package/dist/node_modules/lodash-es/_baseUnary.js +0 -8
- package/dist/node_modules/lodash-es/_cacheHas.js +0 -6
- package/dist/node_modules/lodash-es/_castPath.js +0 -10
- package/dist/node_modules/lodash-es/_createBaseEach.js +0 -15
- package/dist/node_modules/lodash-es/_createBaseFor.js +0 -13
- package/dist/node_modules/lodash-es/_createRange.js +0 -11
- package/dist/node_modules/lodash-es/_equalArrays.js +0 -40
- package/dist/node_modules/lodash-es/_equalByTag.js +0 -45
- package/dist/node_modules/lodash-es/_equalObjects.js +0 -36
- package/dist/node_modules/lodash-es/_getAllKeys.js +0 -9
- package/dist/node_modules/lodash-es/_getMatchData.js +0 -12
- package/dist/node_modules/lodash-es/_getSymbols.js +0 -10
- package/dist/node_modules/lodash-es/_getTag.js +0 -28
- package/dist/node_modules/lodash-es/_hasPath.js +0 -19
- package/dist/node_modules/lodash-es/_isFlattenable.js +0 -10
- package/dist/node_modules/lodash-es/_isIndex.js +0 -8
- package/dist/node_modules/lodash-es/_isIterateeCall.js +0 -13
- package/dist/node_modules/lodash-es/_isKey.js +0 -12
- package/dist/node_modules/lodash-es/_isPrototype.js +0 -8
- package/dist/node_modules/lodash-es/_isStrictComparable.js +0 -7
- package/dist/node_modules/lodash-es/_mapToArray.js +0 -9
- package/dist/node_modules/lodash-es/_matchesStrictComparable.js +0 -8
- package/dist/node_modules/lodash-es/_memoizeCapped.js +0 -11
- package/dist/node_modules/lodash-es/_nativeKeys.js +0 -5
- package/dist/node_modules/lodash-es/_nodeUtil.js +0 -11
- package/dist/node_modules/lodash-es/_overArg.js +0 -8
- package/dist/node_modules/lodash-es/_setCacheAdd.js +0 -7
- package/dist/node_modules/lodash-es/_setCacheHas.js +0 -6
- package/dist/node_modules/lodash-es/_setToArray.js +0 -9
- package/dist/node_modules/lodash-es/_stackClear.js +0 -7
- package/dist/node_modules/lodash-es/_stackDelete.js +0 -7
- package/dist/node_modules/lodash-es/_stackGet.js +0 -6
- package/dist/node_modules/lodash-es/_stackHas.js +0 -6
- package/dist/node_modules/lodash-es/_stackSet.js +0 -17
- package/dist/node_modules/lodash-es/_stringToPath.js +0 -10
- package/dist/node_modules/lodash-es/_toKey.js +0 -10
- package/dist/node_modules/lodash-es/_trimmedEndIndex.js +0 -9
- package/dist/node_modules/lodash-es/flatMap.js +0 -8
- package/dist/node_modules/lodash-es/get.js +0 -8
- package/dist/node_modules/lodash-es/hasIn.js +0 -8
- package/dist/node_modules/lodash-es/identity.js +0 -6
- package/dist/node_modules/lodash-es/isArguments.js +0 -10
- package/dist/node_modules/lodash-es/isArray.js +0 -4
- package/dist/node_modules/lodash-es/isArrayLike.js +0 -8
- package/dist/node_modules/lodash-es/isBuffer.js +0 -6
- package/dist/node_modules/lodash-es/isLength.js +0 -7
- package/dist/node_modules/lodash-es/isObjectLike.js +0 -6
- package/dist/node_modules/lodash-es/isSymbol.js +0 -9
- package/dist/node_modules/lodash-es/isTypedArray.js +0 -7
- package/dist/node_modules/lodash-es/keys.js +0 -9
- package/dist/node_modules/lodash-es/map.js +0 -11
- package/dist/node_modules/lodash-es/property.js +0 -10
- package/dist/node_modules/lodash-es/range.js +0 -5
- package/dist/node_modules/lodash-es/stubArray.js +0 -6
- package/dist/node_modules/lodash-es/stubFalse.js +0 -6
- package/dist/node_modules/lodash-es/toFinite.js +0 -14
- package/dist/node_modules/lodash-es/toNumber.js +0 -22
- package/dist/node_modules/lodash-es/toString.js +0 -7
|
@@ -1,46 +1,42 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
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";
|
|
1
|
+
import { defineComponent as h, defineAsyncComponent as i, computed as e, onMounted as w, watch as s } from "vue";
|
|
2
|
+
import { usePartner as P } from "../../../composables/usePartner.js";
|
|
3
|
+
import { useEditorStore as A } from "../../../stores/editor.js";
|
|
10
4
|
import { useOnboardingStore as _ } from "../../../stores/onboarding.js";
|
|
11
|
-
import { usePreviewStore as
|
|
12
|
-
const
|
|
5
|
+
import { usePreviewStore as H } from "../../../stores/preview.js";
|
|
6
|
+
const B = /* @__PURE__ */ h({
|
|
13
7
|
__name: "OnboardingWrapper",
|
|
14
8
|
emits: ["onboarding-finished"],
|
|
15
|
-
setup(
|
|
16
|
-
const
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
{ type: "
|
|
20
|
-
{ type: "
|
|
21
|
-
{ type: "
|
|
22
|
-
{ type: "
|
|
23
|
-
|
|
24
|
-
|
|
9
|
+
setup(M, { emit: y }) {
|
|
10
|
+
const a = i(() => import("./AMPOnboarding.vue.js")), p = i(() => import("./GenericOnboarding.vue.js")), d = i(() => import("./ItemsOnboarding.vue.js")), c = i(() => import("./NewVersionPopup.vue.js")), m = i(() => import("./TextBlockOnboarding.vue.js")), g = i(
|
|
11
|
+
() => import("./VersionHistoryOnboarding.vue.js")
|
|
12
|
+
), o = _(), r = A(), b = H(), { isTestPartner: O } = P(), f = e(() => r.isStripoInitialized), u = e(() => O()), v = [
|
|
13
|
+
{ type: "newVersionPopup", component: c },
|
|
14
|
+
{ type: "genericOnboarding", component: p },
|
|
15
|
+
{ type: "textBlockOnboarding", component: m },
|
|
16
|
+
{ type: "versionHistoryOnboarding", component: g },
|
|
17
|
+
{ type: "ampOnboarding", component: a },
|
|
18
|
+
{ type: "itemsOnboarding", component: d }
|
|
19
|
+
], l = (n) => u.value || !f.value ? !1 : n === "newVersionPopup" ? o.shouldShowOnboarding(n) : o.isActive(n), S = e(() => v.filter((n) => l(n.type)));
|
|
20
|
+
return w(async () => {
|
|
25
21
|
await o.fetchUserModalState();
|
|
26
|
-
}),
|
|
22
|
+
}), s(
|
|
27
23
|
() => r.isVersionHistoryOpen,
|
|
28
|
-
(n,
|
|
29
|
-
n && !
|
|
24
|
+
(n, t) => {
|
|
25
|
+
n && !t && o.shouldShowOnboarding("versionHistoryOnboarding") && o.start("versionHistoryOnboarding"), !n && t && o.isActive("versionHistoryOnboarding") && o.close("versionHistoryOnboarding");
|
|
30
26
|
}
|
|
31
|
-
),
|
|
32
|
-
() =>
|
|
33
|
-
(n,
|
|
34
|
-
|
|
27
|
+
), s(
|
|
28
|
+
() => b.emailFormat,
|
|
29
|
+
(n, t) => {
|
|
30
|
+
t !== "AMP" && n === "AMP" && o.shouldShowOnboarding("ampOnboarding") && o.start("ampOnboarding");
|
|
35
31
|
}
|
|
36
|
-
),
|
|
32
|
+
), s(
|
|
37
33
|
() => r.isPreviewModeOpen,
|
|
38
34
|
(n) => {
|
|
39
35
|
!n && o.isActive("ampOnboarding") && o.close("ampOnboarding");
|
|
40
36
|
}
|
|
41
|
-
), { __sfc: !0, emit:
|
|
37
|
+
), { __sfc: !0, AMPOnboarding: a, GenericOnboarding: p, ItemsOnboarding: d, NewVersionPopup: c, TextBlockOnboarding: m, VersionHistoryOnboarding: g, emit: y, onboardingStore: o, editorStore: r, previewStore: b, isTestPartner: O, isStripoReady: f, isTestPartnerActive: u, onboardingConfigs: v, shouldShow: l, visibleOnboardings: S };
|
|
42
38
|
}
|
|
43
39
|
});
|
|
44
40
|
export {
|
|
45
|
-
|
|
41
|
+
B as default
|
|
46
42
|
};
|
|
@@ -1,21 +1,20 @@
|
|
|
1
|
-
import
|
|
1
|
+
import n from "./TextBlockOnboarding.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
|
-
import
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
|
|
7
|
-
return o.isVisible ? c(o.InOnboard, { key: "guido__text-block-onboard", staticClass: "w-21-s p-a z-11", class: (e = o.onboardingStore.getTextBlockCurrentCard) == null ? void 0 : e.classes, attrs: { id: "guido__text-block-onboard", "is-multiple-page": "", visible: "", "image-source": "", title: "", "bottom-position": (n = o.onboardingStore.getTextBlockCurrentCard) == null ? void 0 : n.bottom, "left-position": (r = o.onboardingStore.getTextBlockCurrentCard) == null ? void 0 : r.left, "pages-config": o.onboardingStore.onboardings.textBlockOnboarding.config, "pointer-position": (i = o.onboardingStore.getTextBlockCurrentCard) == null ? void 0 : i.position, "right-position": (a = o.onboardingStore.getTextBlockCurrentCard) == null ? void 0 : a.right, "top-position": (s = o.onboardingStore.getTextBlockCurrentCard) == null ? void 0 : s.top }, on: { backButtonClick: o.handleBack, close: function(u) {
|
|
3
|
+
import r from "../../../_virtual/_plugin-vue2_normalizer.js";
|
|
4
|
+
var i = function() {
|
|
5
|
+
var t = this, e = t._self._c, o = t._self._setupProxy;
|
|
6
|
+
return o.isVisible ? e(o.InOnboard, { key: "guido__text-block-onboard", staticClass: "w-21-s p-a z-11", class: o.onboardingStore.getTextBlockCurrentCard?.classes, attrs: { id: "guido__text-block-onboard", "is-multiple-page": "", visible: "", "image-source": "", title: "", "bottom-position": o.onboardingStore.getTextBlockCurrentCard?.bottom, "left-position": o.onboardingStore.getTextBlockCurrentCard?.left, "pages-config": o.onboardingStore.onboardings.textBlockOnboarding.config, "pointer-position": o.onboardingStore.getTextBlockCurrentCard?.position, "right-position": o.onboardingStore.getTextBlockCurrentCard?.right, "top-position": o.onboardingStore.getTextBlockCurrentCard?.top }, on: { backButtonClick: o.handleBack, close: function(l) {
|
|
8
7
|
return o.onboardingStore.close("textBlockOnboarding");
|
|
9
8
|
}, nextButtonClick: o.handleNext } }) : t._e();
|
|
10
|
-
},
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
9
|
+
}, a = [], s = /* @__PURE__ */ r(
|
|
10
|
+
n,
|
|
11
|
+
i,
|
|
12
|
+
a,
|
|
14
13
|
!1,
|
|
15
14
|
null,
|
|
16
|
-
"
|
|
15
|
+
"cadfc82d"
|
|
17
16
|
);
|
|
18
|
-
const
|
|
17
|
+
const p = s.exports;
|
|
19
18
|
export {
|
|
20
|
-
|
|
19
|
+
p as default
|
|
21
20
|
};
|
|
@@ -1,74 +1,61 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
|
|
1
|
+
import { defineComponent as d, computed as i, watch as l } from "vue";
|
|
2
|
+
import { useRibbonOffset as g } from "../../../composables/useRibbonOffset.js";
|
|
3
|
+
import { useTranslations as b } from "../../../composables/useTranslations.js";
|
|
4
|
+
import { useOnboardingStore as x } from "../../../stores/onboarding.js";
|
|
5
|
+
import { InOnboard as u } from "@useinsider/design-system-vue";
|
|
6
|
+
const T = /* @__PURE__ */ d({
|
|
6
7
|
__name: "TextBlockOnboarding",
|
|
7
|
-
setup(
|
|
8
|
-
const
|
|
9
|
-
const n = window.innerHeight - 128, r = Math.max(90, n * 0.15), s = Math.max(490, n * 0.71), d = 200, g = 40;
|
|
10
|
-
return {
|
|
11
|
-
settings: {
|
|
12
|
-
top: `${r}px`,
|
|
13
|
-
position: r + d + g > n ? "Right Bottom" : "Right Top"
|
|
14
|
-
},
|
|
15
|
-
dynamic: {
|
|
16
|
-
top: `${s}px`,
|
|
17
|
-
position: s + d + g > n ? "Right Bottom" : "Right Top"
|
|
18
|
-
}
|
|
19
|
-
};
|
|
20
|
-
}), c = a(() => [
|
|
8
|
+
setup(p) {
|
|
9
|
+
const o = b(), t = x(), { getTopPosition: n } = g(), e = i(() => [
|
|
21
10
|
{
|
|
22
11
|
classes: "guido-text-block-onboarding-settings",
|
|
23
12
|
right: "426px",
|
|
24
|
-
top:
|
|
25
|
-
position:
|
|
26
|
-
title:
|
|
27
|
-
description:
|
|
13
|
+
top: n(90),
|
|
14
|
+
position: "Right Top",
|
|
15
|
+
title: o("email-editor.onboarding-text-block-title"),
|
|
16
|
+
description: o("email-editor.onboarding-text-block-description"),
|
|
28
17
|
imageSource: "",
|
|
29
18
|
backButtonClick: () => {
|
|
30
19
|
},
|
|
31
20
|
nextButtonType: "text",
|
|
32
|
-
nextButtonText:
|
|
21
|
+
nextButtonText: o("products.next"),
|
|
33
22
|
nextButtonClick: () => {
|
|
34
|
-
|
|
23
|
+
t.next("textBlockOnboarding");
|
|
35
24
|
}
|
|
36
25
|
},
|
|
37
26
|
{
|
|
38
27
|
classes: "guido-text-block-onboarding-dynamic",
|
|
39
|
-
right: "
|
|
40
|
-
top:
|
|
41
|
-
position:
|
|
42
|
-
title:
|
|
43
|
-
description:
|
|
28
|
+
right: "409px",
|
|
29
|
+
top: n(607),
|
|
30
|
+
position: "Right Top",
|
|
31
|
+
title: o("email-editor.onboarding-dynamic-content-title"),
|
|
32
|
+
description: o("email-editor.onboarding-dynamic-content-description"),
|
|
44
33
|
imageSource: "",
|
|
45
34
|
backButtonType: "text",
|
|
46
|
-
backButtonText:
|
|
35
|
+
backButtonText: o("ds-steps.back"),
|
|
47
36
|
backButtonClick: () => {
|
|
48
|
-
|
|
37
|
+
t.previous("textBlockOnboarding");
|
|
49
38
|
},
|
|
50
39
|
nextButtonType: "text",
|
|
51
|
-
nextButtonText:
|
|
40
|
+
nextButtonText: o("action-builder.ok"),
|
|
52
41
|
nextButtonClick: () => {
|
|
53
|
-
|
|
42
|
+
t.close("textBlockOnboarding");
|
|
54
43
|
}
|
|
55
44
|
}
|
|
56
|
-
]),
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
var t, n;
|
|
61
|
-
(n = (t = o.getTextBlockCurrentCard) == null ? void 0 : t.backButtonClick) == null || n.call(t);
|
|
45
|
+
]), r = i(() => t.onboardings.textBlockOnboarding.config.length > 0 && t.onboardings.textBlockOnboarding.isActive), c = () => {
|
|
46
|
+
t.getTextBlockCurrentCard?.nextButtonClick?.();
|
|
47
|
+
}, a = () => {
|
|
48
|
+
t.getTextBlockCurrentCard?.backButtonClick?.();
|
|
62
49
|
};
|
|
63
|
-
return
|
|
64
|
-
() =>
|
|
65
|
-
(
|
|
66
|
-
|
|
50
|
+
return l(
|
|
51
|
+
() => t.isActive("textBlockOnboarding"),
|
|
52
|
+
(s) => {
|
|
53
|
+
s && t.setConfig("textBlockOnboarding", e.value);
|
|
67
54
|
},
|
|
68
55
|
{ immediate: !0 }
|
|
69
|
-
), { __sfc: !0, trans:
|
|
56
|
+
), { __sfc: !0, trans: o, onboardingStore: t, getTopPosition: n, onboardingCardsConfig: e, isVisible: r, handleNext: c, handleBack: a, InOnboard: u };
|
|
70
57
|
}
|
|
71
58
|
});
|
|
72
59
|
export {
|
|
73
|
-
|
|
60
|
+
T as default
|
|
74
61
|
};
|
|
@@ -1,20 +1,19 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
|
|
6
|
-
return o.isVisible ? d(o.InOnboard, { key: "guido__version-history-onboard", staticClass: "w-21-s p-a z-11", class: (n = o.onboardingStore.getVersionHistoryCurrentCard) == null ? void 0 : n.classes, attrs: { id: "guido__version-history-onboard", "is-multiple-page": "", visible: "", "image-source": "", title: "", "bottom-position": (t = o.onboardingStore.getVersionHistoryCurrentCard) == null ? void 0 : t.bottom, "left-position": (i = o.onboardingStore.getVersionHistoryCurrentCard) == null ? void 0 : i.left, "pages-config": o.onboardingStore.onboardings.versionHistoryOnboarding.config, "pointer-position": (e = o.onboardingStore.getVersionHistoryCurrentCard) == null ? void 0 : e.position, "right-position": (s = o.onboardingStore.getVersionHistoryCurrentCard) == null ? void 0 : s.right, "top-position": (a = o.onboardingStore.getVersionHistoryCurrentCard) == null ? void 0 : a.top }, on: { backButtonClick: o.handleBack, close: function(b) {
|
|
1
|
+
import t from "./VersionHistoryOnboarding.vue2.js";
|
|
2
|
+
import i from "../../../_virtual/_plugin-vue2_normalizer.js";
|
|
3
|
+
var e = function() {
|
|
4
|
+
var r = this, n = r._self._c, o = r._self._setupProxy;
|
|
5
|
+
return o.isVisible ? n(o.InOnboard, { key: "guido__version-history-onboard", staticClass: "w-21-s p-a z-11", class: o.onboardingStore.getVersionHistoryCurrentCard?.classes, attrs: { id: "guido__version-history-onboard", "is-multiple-page": "", visible: "", "image-source": "", title: "", "bottom-position": o.onboardingStore.getVersionHistoryCurrentCard?.bottom, "left-position": o.onboardingStore.getVersionHistoryCurrentCard?.left, "pages-config": o.onboardingStore.onboardings.versionHistoryOnboarding.config, "pointer-position": o.onboardingStore.getVersionHistoryCurrentCard?.position, "right-position": o.onboardingStore.getVersionHistoryCurrentCard?.right, "top-position": o.onboardingStore.getVersionHistoryCurrentCard?.top }, on: { backButtonClick: o.handleBack, close: function(g) {
|
|
7
6
|
return o.onboardingStore.close("versionHistoryOnboarding");
|
|
8
7
|
}, nextButtonClick: o.handleNext } }) : r._e();
|
|
9
|
-
},
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
8
|
+
}, s = [], a = /* @__PURE__ */ i(
|
|
9
|
+
t,
|
|
10
|
+
e,
|
|
11
|
+
s,
|
|
13
12
|
!1,
|
|
14
13
|
null,
|
|
15
14
|
null
|
|
16
15
|
);
|
|
17
|
-
const
|
|
16
|
+
const _ = a.exports;
|
|
18
17
|
export {
|
|
19
|
-
|
|
18
|
+
_ as default
|
|
20
19
|
};
|
|
@@ -1,37 +1,36 @@
|
|
|
1
|
-
import { defineComponent as c, computed as
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
|
|
1
|
+
import { defineComponent as c, computed as r, watch as g } from "vue";
|
|
2
|
+
import { useRibbonOffset as b } from "../../../composables/useRibbonOffset.js";
|
|
3
|
+
import { useTranslations as u } from "../../../composables/useTranslations.js";
|
|
4
|
+
import { useOnboardingStore as l } from "../../../stores/onboarding.js";
|
|
5
|
+
import { InOnboard as m } from "@useinsider/design-system-vue";
|
|
6
|
+
const O = /* @__PURE__ */ c({
|
|
6
7
|
__name: "VersionHistoryOnboarding",
|
|
7
8
|
setup(p) {
|
|
8
|
-
const
|
|
9
|
+
const n = u(), o = l(), { getTopPosition: i } = b(), t = r(() => [
|
|
9
10
|
{
|
|
10
11
|
classes: "guido-version-history-onboarding",
|
|
11
12
|
left: "409px",
|
|
12
|
-
top:
|
|
13
|
+
top: i(192),
|
|
13
14
|
position: "Left Top",
|
|
14
|
-
title:
|
|
15
|
-
description:
|
|
15
|
+
title: n("email-editor.onboarding-version-history-title"),
|
|
16
|
+
description: n("email-editor.onboarding-version-history-description"),
|
|
16
17
|
imageSource: "",
|
|
17
18
|
backButtonClick: () => {
|
|
18
19
|
},
|
|
19
20
|
nextButtonType: "text",
|
|
20
|
-
nextButtonText:
|
|
21
|
-
nextButtonClick: () => void
|
|
21
|
+
nextButtonText: n("action-builder.ok"),
|
|
22
|
+
nextButtonClick: () => void o.close("versionHistoryOnboarding")
|
|
22
23
|
}
|
|
23
|
-
]),
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
var o, i;
|
|
28
|
-
(i = (o = n.getVersionHistoryCurrentCard) == null ? void 0 : o.backButtonClick) == null || i.call(o);
|
|
24
|
+
]), e = r(() => o.onboardings.versionHistoryOnboarding.config.length > 0 && o.onboardings.versionHistoryOnboarding.isActive), s = () => {
|
|
25
|
+
o.getVersionHistoryCurrentCard?.nextButtonClick?.();
|
|
26
|
+
}, a = () => {
|
|
27
|
+
o.getVersionHistoryCurrentCard?.backButtonClick?.();
|
|
29
28
|
};
|
|
30
|
-
return g(() =>
|
|
31
|
-
|
|
32
|
-
}, { immediate: !0 }), { __sfc: !0, trans:
|
|
29
|
+
return g(() => o.onboardings.versionHistoryOnboarding.isActive, (d) => {
|
|
30
|
+
d && o.setConfig("versionHistoryOnboarding", t.value);
|
|
31
|
+
}, { immediate: !0 }), { __sfc: !0, trans: n, onboardingStore: o, getTopPosition: i, onboardingCardsConfig: t, isVisible: e, handleNext: s, handleBack: a, InOnboard: m };
|
|
33
32
|
}
|
|
34
33
|
});
|
|
35
34
|
export {
|
|
36
|
-
|
|
35
|
+
O as default
|
|
37
36
|
};
|
|
@@ -10,29 +10,29 @@ import { useDebounceFn as V } from "../../../node_modules/@vueuse/shared/index.j
|
|
|
10
10
|
const H = /* @__PURE__ */ A({
|
|
11
11
|
__name: "SaveAsTemplateDrawer",
|
|
12
12
|
setup(E) {
|
|
13
|
-
const
|
|
13
|
+
const o = O(), n = D(), t = k(), { createTemplate: u } = B(), a = c(!1), r = c(!1), l = c(""), f = b(() => ({
|
|
14
14
|
primaryButton: {
|
|
15
15
|
styling: "solid",
|
|
16
16
|
type: "primary",
|
|
17
|
-
labelText:
|
|
17
|
+
labelText: o(a.value ? "newsletter.saving" : "products.save"),
|
|
18
18
|
loadingStatus: a.value,
|
|
19
19
|
disabledStatus: t.skeletonStatus
|
|
20
20
|
},
|
|
21
21
|
cancelOrBackButton: {
|
|
22
22
|
styling: "ghost",
|
|
23
23
|
type: "secondary",
|
|
24
|
-
labelText:
|
|
24
|
+
labelText: o("products.cancel"),
|
|
25
25
|
disabledStatus: a.value
|
|
26
26
|
}
|
|
27
27
|
})), p = () => {
|
|
28
|
-
|
|
29
|
-
},
|
|
30
|
-
const e = h(t, "templateName"), { success:
|
|
31
|
-
return
|
|
28
|
+
l.value = "", n.isSaveAsTemplateDrawerOpen = !1;
|
|
29
|
+
}, i = async () => {
|
|
30
|
+
const e = h(t, "templateName"), { success: s, errorMessage: _ } = await x(e).validate();
|
|
31
|
+
return l.value = _, s;
|
|
32
32
|
}, v = V(async (e) => {
|
|
33
|
-
t.templateName = e, await
|
|
33
|
+
t.templateName = e, await i();
|
|
34
34
|
}, 500), g = async (e) => {
|
|
35
|
-
|
|
35
|
+
r.value = !0, await t.addCategory(e), r.value = !1;
|
|
36
36
|
}, y = (e) => {
|
|
37
37
|
t.selectedCategories = e;
|
|
38
38
|
}, S = (e) => {
|
|
@@ -40,22 +40,22 @@ const H = /* @__PURE__ */ A({
|
|
|
40
40
|
}, T = () => {
|
|
41
41
|
t.selectedCategories = [];
|
|
42
42
|
}, w = async () => {
|
|
43
|
-
if (a.value = !0, !await
|
|
43
|
+
if (a.value = !0, !await i()) {
|
|
44
44
|
a.value = !1;
|
|
45
45
|
return;
|
|
46
46
|
}
|
|
47
|
-
|
|
48
|
-
|
|
47
|
+
const s = await u();
|
|
48
|
+
a.value = !1, s && p();
|
|
49
|
+
}, m = () => {
|
|
49
50
|
C(() => {
|
|
50
|
-
|
|
51
|
-
e == null || e.focus();
|
|
51
|
+
document.querySelector("input#guido__template-name-input")?.focus();
|
|
52
52
|
});
|
|
53
53
|
}, d = async () => {
|
|
54
|
-
t.$reset(), await t.fetchCategories(), t.skeletonStatus = !1,
|
|
54
|
+
t.$reset(), await t.fetchCategories(), t.skeletonStatus = !1, m();
|
|
55
55
|
};
|
|
56
|
-
return
|
|
57
|
-
|
|
58
|
-
}), { __sfc: !0, trans:
|
|
56
|
+
return n.$subscribe((e, { isSaveAsTemplateDrawerOpen: s }) => {
|
|
57
|
+
s && d();
|
|
58
|
+
}), { __sfc: !0, trans: o, editorStore: n, saveAsTemplateStore: t, createTemplate: u, isSaving: a, isAddingOption: r, templateNameError: l, footerButtonGroupOptions: f, closeModal: p, validateTemplateName: i, handleTemplateName: v, handleAddOption: g, handleCategoryChange: y, handleSelectAllOptions: S, handleResetAllOptions: T, saveTemplate: w, focusToInput: m, initializeDrawer: d, WpDrawer: N, InBasicTextInput: M, InMultiSelect: I };
|
|
59
59
|
}
|
|
60
60
|
});
|
|
61
61
|
export {
|
|
@@ -1,18 +1,17 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
var
|
|
4
|
-
var s, t;
|
|
1
|
+
import s from "./UnsubscribeWrapper.vue2.js";
|
|
2
|
+
import t from "../../../_virtual/_plugin-vue2_normalizer.js";
|
|
3
|
+
var _ = function() {
|
|
5
4
|
var e = this, r = e._self._c, n = e._self._setupProxy;
|
|
6
|
-
return
|
|
7
|
-
},
|
|
5
|
+
return n.config?.features?.unsubscribe ? r("div", [r(n.UnsubscribeTypeSelection), r(n.UnsubscribePageSelection)], 1) : e._e();
|
|
6
|
+
}, o = [], c = /* @__PURE__ */ t(
|
|
7
|
+
s,
|
|
8
8
|
_,
|
|
9
|
-
|
|
10
|
-
i,
|
|
9
|
+
o,
|
|
11
10
|
!1,
|
|
12
11
|
null,
|
|
13
12
|
null
|
|
14
13
|
);
|
|
15
|
-
const
|
|
14
|
+
const f = c.exports;
|
|
16
15
|
export {
|
|
17
|
-
|
|
16
|
+
f as default
|
|
18
17
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { useToaster as w } from "./useToaster.js";
|
|
2
2
|
const v = () => {
|
|
3
|
-
const { handleError:
|
|
4
|
-
const
|
|
3
|
+
const { handleError: o } = w(), m = (e = {}) => new Promise((t, i) => {
|
|
4
|
+
const a = { ...{
|
|
5
5
|
minimize: !0,
|
|
6
6
|
utmEntity: {
|
|
7
7
|
utmSource: "",
|
|
@@ -20,51 +20,51 @@ const v = () => {
|
|
|
20
20
|
forceAmp: !1,
|
|
21
21
|
resetDataSavedFlag: !1,
|
|
22
22
|
disableLineHeightsReplace: !0
|
|
23
|
-
}, ...
|
|
23
|
+
}, ...e }, s = {
|
|
24
24
|
callback: (l, r, d, c, u) => {
|
|
25
|
-
l ?
|
|
25
|
+
l ? i(l) : t({
|
|
26
26
|
html: r,
|
|
27
27
|
ampHtml: d,
|
|
28
28
|
ampErrors: c,
|
|
29
29
|
displayConditions: u
|
|
30
30
|
});
|
|
31
31
|
},
|
|
32
|
-
...
|
|
32
|
+
...a
|
|
33
33
|
};
|
|
34
34
|
window.StripoEditorApi.actionsApi.compileEmail(s);
|
|
35
35
|
});
|
|
36
36
|
return {
|
|
37
37
|
getCompiledEmail: m,
|
|
38
|
-
getTemplateData: () => new Promise((
|
|
39
|
-
const
|
|
40
|
-
html:
|
|
41
|
-
css:
|
|
42
|
-
width:
|
|
38
|
+
getTemplateData: () => new Promise((e) => {
|
|
39
|
+
const t = ({ html: i, css: n, width: a, height: p, utmParams: s, syncModulesIds: l }) => e({
|
|
40
|
+
html: i,
|
|
41
|
+
css: n,
|
|
42
|
+
width: a,
|
|
43
43
|
height: p,
|
|
44
44
|
utmParams: s,
|
|
45
45
|
syncModulesIds: l
|
|
46
46
|
});
|
|
47
|
-
window.StripoEditorApi.actionsApi.getTemplateData(
|
|
47
|
+
window.StripoEditorApi.actionsApi.getTemplateData(t);
|
|
48
48
|
}),
|
|
49
|
-
activateCustomViewStyles: (
|
|
50
|
-
window.StripoEditorApi.actionsApi.activateCustomViewStyles(
|
|
49
|
+
activateCustomViewStyles: (e = !0) => {
|
|
50
|
+
window.StripoEditorApi.actionsApi.activateCustomViewStyles(e);
|
|
51
51
|
},
|
|
52
|
-
getPreviewData: async (
|
|
52
|
+
getPreviewData: async (e) => {
|
|
53
53
|
try {
|
|
54
54
|
const {
|
|
55
|
-
html:
|
|
56
|
-
displayConditions:
|
|
57
|
-
ampHtml:
|
|
58
|
-
ampErrors:
|
|
59
|
-
} = await m({ minimize: !1, resetDataSavedFlag: !1, ...
|
|
55
|
+
html: t,
|
|
56
|
+
displayConditions: i,
|
|
57
|
+
ampHtml: n = "",
|
|
58
|
+
ampErrors: a = []
|
|
59
|
+
} = await m({ minimize: !1, resetDataSavedFlag: !1, ...e });
|
|
60
60
|
return {
|
|
61
|
-
html:
|
|
62
|
-
ampHtml:
|
|
63
|
-
ampErrors:
|
|
64
|
-
displayConditions:
|
|
61
|
+
html: t,
|
|
62
|
+
ampHtml: n,
|
|
63
|
+
ampErrors: a,
|
|
64
|
+
displayConditions: i
|
|
65
65
|
};
|
|
66
|
-
} catch (
|
|
67
|
-
return
|
|
66
|
+
} catch (t) {
|
|
67
|
+
return o(t, "Error loading preview"), {
|
|
68
68
|
html: "",
|
|
69
69
|
ampHtml: "",
|
|
70
70
|
ampErrors: [],
|
|
@@ -72,28 +72,27 @@ const v = () => {
|
|
|
72
72
|
};
|
|
73
73
|
}
|
|
74
74
|
},
|
|
75
|
-
updateTimerInClonedTemplate: () => new Promise((
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
t(null);
|
|
75
|
+
updateTimerInClonedTemplate: () => new Promise((e) => {
|
|
76
|
+
if (typeof window.StripoEditorApi?.actionsApi?.updateTimerInClonedTemplate != "function") {
|
|
77
|
+
e(null);
|
|
79
78
|
return;
|
|
80
79
|
}
|
|
81
80
|
try {
|
|
82
|
-
window.StripoEditorApi.actionsApi.updateTimerInClonedTemplate((
|
|
83
|
-
|
|
81
|
+
window.StripoEditorApi.actionsApi.updateTimerInClonedTemplate((t, i) => {
|
|
82
|
+
t ? (o(t, "Failed to update timer in cloned template"), e(null)) : e(i || null);
|
|
84
83
|
});
|
|
85
|
-
} catch (
|
|
86
|
-
|
|
84
|
+
} catch (t) {
|
|
85
|
+
o(t, "Failed to call updateTimerInClonedTemplate"), e(null);
|
|
87
86
|
}
|
|
88
87
|
}),
|
|
89
|
-
updateHtmlAndCss: (
|
|
90
|
-
window.StripoEditorApi.actionsApi.updateHtmlAndCss(
|
|
88
|
+
updateHtmlAndCss: (e, t) => {
|
|
89
|
+
window.StripoEditorApi.actionsApi.updateHtmlAndCss(e, t);
|
|
91
90
|
},
|
|
92
|
-
editorSave: () => {
|
|
91
|
+
editorSave: () => new Promise((e) => {
|
|
93
92
|
window.StripoEditorApi.actionsApi.save((t) => {
|
|
94
|
-
t &&
|
|
93
|
+
t && o(t, "Failed to save template"), e();
|
|
95
94
|
});
|
|
96
|
-
}
|
|
95
|
+
})
|
|
97
96
|
};
|
|
98
97
|
};
|
|
99
98
|
export {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { useConfigStore as
|
|
3
|
-
const
|
|
1
|
+
import l from "../extensions/ModulesTabIcons/extension.js";
|
|
2
|
+
import { useConfigStore as r } from "../stores/config.js";
|
|
3
|
+
const s = {
|
|
4
4
|
"amp-accordion": "ampAccordionEnabled",
|
|
5
5
|
"amp-carousel": "ampCarouselEnabled",
|
|
6
6
|
"amp-form-controls": "ampFormControlsEnabled",
|
|
@@ -14,7 +14,7 @@ const a = {
|
|
|
14
14
|
"text-block": "textEnabled",
|
|
15
15
|
"timer-block": "timerEnabled",
|
|
16
16
|
"video-block": "videoEnabled"
|
|
17
|
-
},
|
|
17
|
+
}, a = {
|
|
18
18
|
"dynamic-content": () => import("../extensions/DynamicContent/extension.js"),
|
|
19
19
|
"checkbox-block": () => import("../extensions/Blocks/Checkbox/extension.js"),
|
|
20
20
|
"radio-button-block": () => import("../extensions/Blocks/RadioButton/extension.js"),
|
|
@@ -22,40 +22,40 @@ const a = {
|
|
|
22
22
|
"unsubscribe-block": () => import("../extensions/Blocks/Unsubscribe/extension.js"),
|
|
23
23
|
"coupon-block": () => import("../extensions/Blocks/CouponBlock/extension.js"),
|
|
24
24
|
"items-block": () => import("../extensions/Blocks/Items/extension.js")
|
|
25
|
-
}, i = (
|
|
26
|
-
if (!
|
|
25
|
+
}, i = (o) => {
|
|
26
|
+
if (!o || !o.length)
|
|
27
27
|
return {};
|
|
28
|
-
const
|
|
29
|
-
return
|
|
30
|
-
const e =
|
|
31
|
-
e && (
|
|
32
|
-
}),
|
|
33
|
-
}, b = () => [
|
|
34
|
-
const
|
|
35
|
-
if (!
|
|
36
|
-
return
|
|
37
|
-
const
|
|
38
|
-
|
|
39
|
-
const c =
|
|
28
|
+
const n = {};
|
|
29
|
+
return o.forEach((t) => {
|
|
30
|
+
const e = s[t];
|
|
31
|
+
e && (n[e] = !1);
|
|
32
|
+
}), n;
|
|
33
|
+
}, b = () => [l], m = async (o) => {
|
|
34
|
+
const n = b();
|
|
35
|
+
if (!o || !o.length)
|
|
36
|
+
return n;
|
|
37
|
+
const t = await Promise.all(
|
|
38
|
+
o.map(async (e) => {
|
|
39
|
+
const c = a[e];
|
|
40
40
|
return c ? (await c()).default : null;
|
|
41
41
|
})
|
|
42
42
|
);
|
|
43
43
|
return [
|
|
44
|
-
...
|
|
45
|
-
...
|
|
44
|
+
...n,
|
|
45
|
+
...t.filter((e) => e !== null)
|
|
46
46
|
];
|
|
47
|
-
},
|
|
48
|
-
const
|
|
47
|
+
}, p = () => {
|
|
48
|
+
const o = r();
|
|
49
49
|
return {
|
|
50
50
|
getStripoBlocksConfig: async () => {
|
|
51
|
-
const
|
|
51
|
+
const t = o.blocks;
|
|
52
52
|
return {
|
|
53
|
-
baseBlocks: i(
|
|
54
|
-
extensions: await m(
|
|
53
|
+
baseBlocks: i(t?.excludeDefaults),
|
|
54
|
+
extensions: await m(t?.includeCustoms)
|
|
55
55
|
};
|
|
56
56
|
}
|
|
57
57
|
};
|
|
58
58
|
};
|
|
59
59
|
export {
|
|
60
|
-
|
|
60
|
+
p as useBlocksConfig
|
|
61
61
|
};
|