@useinsider/guido 3.2.0-beta.78d83bd → 3.2.0-beta.7e0c6bd

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (265) hide show
  1. package/dist/@types/config/schemas.js +1 -1
  2. package/dist/@types/config/validator.js +27 -34
  3. package/dist/components/Guido.vue.js +1 -1
  4. package/dist/components/Guido.vue2.js +76 -81
  5. package/dist/components/organisms/base/Toaster.vue2.js +10 -11
  6. package/dist/components/organisms/email-preview/desktop-preview/DesktopPreview.vue2.js +12 -12
  7. package/dist/components/organisms/email-preview/mobile-preview/ContentView.vue2.js +6 -6
  8. package/dist/components/organisms/email-preview/mobile-preview/InboxView.vue2.js +9 -15
  9. package/dist/components/organisms/extensions/recommendation/FilterItem.vue2.js +31 -40
  10. package/dist/components/organisms/extensions/recommendation/FilterSelectionDrawer.vue2.js +19 -20
  11. package/dist/components/organisms/extensions/recommendation/Filters.vue2.js +11 -14
  12. package/dist/components/organisms/header/EditorActions.vue.js +11 -12
  13. package/dist/components/organisms/header/EditorActions.vue2.js +18 -22
  14. package/dist/components/organisms/header/HeaderWrapper.vue2.js +12 -15
  15. package/dist/components/organisms/header/LeftSlot.vue2.js +16 -19
  16. package/dist/components/organisms/header/MiddleSlot.vue2.js +14 -11
  17. package/dist/components/organisms/header/RightSlot.vue2.js +14 -17
  18. package/dist/components/organisms/onboarding/AMPOnboarding.vue.js +11 -12
  19. package/dist/components/organisms/onboarding/AMPOnboarding.vue2.js +49 -31
  20. package/dist/components/organisms/onboarding/GenericOnboarding.vue.js +12 -13
  21. package/dist/components/organisms/onboarding/GenericOnboarding.vue2.js +36 -38
  22. package/dist/components/organisms/onboarding/ItemsOnboarding.vue.js +12 -13
  23. package/dist/components/organisms/onboarding/ItemsOnboarding.vue2.js +47 -51
  24. package/dist/components/organisms/onboarding/NewVersionPopup.vue2.js +18 -21
  25. package/dist/components/organisms/onboarding/OnboardingWrapper.vue2.js +27 -31
  26. package/dist/components/organisms/onboarding/TextBlockOnboarding.vue.js +12 -13
  27. package/dist/components/organisms/onboarding/TextBlockOnboarding.vue2.js +33 -46
  28. package/dist/components/organisms/onboarding/VersionHistoryOnboarding.vue.js +11 -12
  29. package/dist/components/organisms/onboarding/VersionHistoryOnboarding.vue2.js +20 -21
  30. package/dist/components/organisms/save-as-template/SaveAsTemplateDrawer.vue2.js +8 -9
  31. package/dist/components/organisms/unsubscribe/UnsubscribeWrapper.vue.js +9 -10
  32. package/dist/composables/useActionsApi.js +37 -38
  33. package/dist/composables/useBlocksConfig.js +26 -26
  34. package/dist/composables/useFullStoryBridge.js +8 -9
  35. package/dist/composables/useHtmlCompiler.js +34 -26
  36. package/dist/composables/useHtmlValidator.js +101 -109
  37. package/dist/composables/useHttp.js +30 -30
  38. package/dist/composables/usePartner.js +1 -1
  39. package/dist/composables/useRecommendation.js +14 -15
  40. package/dist/composables/useRibbonOffset.js +21 -0
  41. package/dist/composables/useSave.js +21 -22
  42. package/dist/composables/useStripo.js +53 -50
  43. package/dist/composables/useSyncModuleExtractor.js +31 -29
  44. package/dist/composables/useTimerClone.js +24 -25
  45. package/dist/composables/useTranslations.js +23 -16
  46. package/dist/composables/useValidation.js +7 -8
  47. package/dist/composables/validators/useLiquidValidator.js +13 -13
  48. package/dist/config/compiler/unsubscribeCompilerRules.js +17 -19
  49. package/dist/config/compiler/utils/recommendationCompilerUtils.js +10 -11
  50. package/dist/config/migrator/checkboxMigrator.js +20 -21
  51. package/dist/config/migrator/couponBlockMigrator.js +18 -19
  52. package/dist/config/migrator/itemsBlockMigrator.js +87 -89
  53. package/dist/config/migrator/radioButtonMigrator.js +12 -13
  54. package/dist/config/migrator/recommendationMigrator.js +106 -109
  55. package/dist/config/migrator/unsubscribeMigrator.js +10 -11
  56. package/dist/enums/onboarding.js +7 -2
  57. package/dist/enums/unsubscribe.js +18 -19
  58. package/dist/extensions/Blocks/Items/block.js +9 -9
  59. package/dist/extensions/Blocks/Items/controls/button/link.js +14 -14
  60. package/dist/extensions/Blocks/Items/controls/cardComposition.js +89 -97
  61. package/dist/extensions/Blocks/Items/controls/image/link.js +14 -14
  62. package/dist/extensions/Blocks/Items/controls/name/trimming.js +23 -24
  63. package/dist/extensions/Blocks/Items/controls/price/currencyLocation.js +13 -14
  64. package/dist/extensions/Blocks/Items/controls/price/currencySymbol.js +44 -47
  65. package/dist/extensions/Blocks/Items/controls/price/formattedPrice.js +38 -38
  66. package/dist/extensions/Blocks/Items/controls/price/hideDiscount.js +11 -11
  67. package/dist/extensions/Blocks/Items/controls/price/priceOrientation.js +38 -40
  68. package/dist/extensions/Blocks/Items/controls/price/singlePrice.js +35 -35
  69. package/dist/extensions/Blocks/Items/controls/settingsControl.js +155 -162
  70. package/dist/extensions/Blocks/Items/enums/productEnums.js +9 -14
  71. package/dist/extensions/Blocks/Items/template.js +218 -216
  72. package/dist/extensions/Blocks/Recommendation/controls/button/index.js +36 -36
  73. package/dist/extensions/Blocks/Recommendation/controls/cardComposition/index.js +128 -133
  74. package/dist/extensions/Blocks/Recommendation/controls/customAttribute/index.js +9 -9
  75. package/dist/extensions/Blocks/Recommendation/controls/customAttribute/textTrim.js +10 -10
  76. package/dist/extensions/Blocks/Recommendation/controls/image/index.js +9 -9
  77. package/dist/extensions/Blocks/Recommendation/controls/main/algorithm.js +17 -18
  78. package/dist/extensions/Blocks/Recommendation/controls/main/filters.js +4 -6
  79. package/dist/extensions/Blocks/Recommendation/controls/main/index.js +82 -90
  80. package/dist/extensions/Blocks/Recommendation/controls/main/layoutOrientation.js +18 -18
  81. package/dist/extensions/Blocks/Recommendation/controls/main/productCount.js +4 -4
  82. package/dist/extensions/Blocks/Recommendation/controls/main/productLayout.js +35 -36
  83. package/dist/extensions/Blocks/Recommendation/controls/main/utils.js +134 -135
  84. package/dist/extensions/Blocks/Recommendation/controls/name/index.js +24 -24
  85. package/dist/extensions/Blocks/Recommendation/controls/name/textTrim.js +10 -10
  86. package/dist/extensions/Blocks/Recommendation/controls/oldPrice/index.js +24 -24
  87. package/dist/extensions/Blocks/Recommendation/controls/omnibusDiscount/index.js +24 -24
  88. package/dist/extensions/Blocks/Recommendation/controls/omnibusDiscount/textAfter.js +4 -4
  89. package/dist/extensions/Blocks/Recommendation/controls/omnibusDiscount/textBefore.js +4 -4
  90. package/dist/extensions/Blocks/Recommendation/controls/omnibusPrice/index.js +24 -24
  91. package/dist/extensions/Blocks/Recommendation/controls/omnibusPrice/textAfter.js +4 -4
  92. package/dist/extensions/Blocks/Recommendation/controls/omnibusPrice/textBefore.js +4 -4
  93. package/dist/extensions/Blocks/Recommendation/controls/price/index.js +24 -24
  94. package/dist/extensions/Blocks/Recommendation/controls/spacing/index.js +32 -32
  95. package/dist/extensions/Blocks/Recommendation/controls/syncInfoMessage.js +18 -20
  96. package/dist/extensions/Blocks/Recommendation/extension.js +31 -32
  97. package/dist/extensions/Blocks/Recommendation/settingsPanel.js +8 -16
  98. package/dist/extensions/Blocks/Recommendation/store/recommendation.js +55 -56
  99. package/dist/extensions/Blocks/Recommendation/templates/grid/elementRenderer.js +22 -23
  100. package/dist/extensions/Blocks/Recommendation/templates/grid/migration.js +10 -10
  101. package/dist/extensions/Blocks/Recommendation/templates/grid/template.js +10 -10
  102. package/dist/extensions/Blocks/Recommendation/templates/index.js +6 -6
  103. package/dist/extensions/Blocks/Recommendation/templates/list/elementRenderer.js +24 -25
  104. package/dist/extensions/Blocks/Recommendation/templates/list/template.js +1 -1
  105. package/dist/extensions/Blocks/Recommendation/templates/utils.js +45 -47
  106. package/dist/extensions/Blocks/Recommendation/validation/filterSchema.js +13 -16
  107. package/dist/extensions/Blocks/Unsubscribe/control.js +11 -13
  108. package/dist/extensions/Blocks/Unsubscribe/elements/preview.js +16 -18
  109. package/dist/extensions/Blocks/common-control.js +25 -26
  110. package/dist/extensions/DynamicContent/dynamic-content.js +53 -58
  111. package/dist/guido.css +1 -1
  112. package/dist/library.js +11 -12
  113. package/dist/node_modules/@stripoinc/ui-editor-extensions/dist/esm/index.js +233 -210
  114. package/dist/node_modules/valibot/dist/index.js +122 -126
  115. package/dist/package.json.js +1 -1
  116. package/dist/services/recommendationApi.js +14 -17
  117. package/dist/services/templateLibraryApi.js +37 -38
  118. package/dist/src/components/wrappers/WpModal.vue.d.ts +1 -1
  119. package/dist/src/composables/useHtmlCompiler.d.ts +1 -2
  120. package/dist/src/composables/useRibbonOffset.d.ts +4 -0
  121. package/dist/src/composables/useTranslations.d.ts +1 -1
  122. package/dist/src/enums/onboarding.d.ts +6 -0
  123. package/dist/src/stores/dynamic-content.d.ts +3 -3
  124. package/dist/src/stores/onboarding.d.ts +4 -0
  125. package/dist/stores/config.js +25 -81
  126. package/dist/stores/dynamic-content.js +6 -11
  127. package/dist/stores/onboarding.js +5 -1
  128. package/dist/stores/preview.js +6 -9
  129. package/dist/stores/unsubscribe.js +1 -4
  130. package/dist/utils/dateUtil.js +7 -10
  131. package/dist/utils/genericUtil.js +10 -13
  132. package/dist/utils/pairProductVariables.js +13 -14
  133. package/package.json +8 -5
  134. package/dist/node_modules/lodash-es/_DataView.js +0 -6
  135. package/dist/node_modules/lodash-es/_Hash.js +0 -20
  136. package/dist/node_modules/lodash-es/_ListCache.js +0 -20
  137. package/dist/node_modules/lodash-es/_Map.js +0 -6
  138. package/dist/node_modules/lodash-es/_MapCache.js +0 -20
  139. package/dist/node_modules/lodash-es/_Promise.js +0 -6
  140. package/dist/node_modules/lodash-es/_Set.js +0 -6
  141. package/dist/node_modules/lodash-es/_SetCache.js +0 -13
  142. package/dist/node_modules/lodash-es/_Stack.js +0 -18
  143. package/dist/node_modules/lodash-es/_Symbol.js +0 -5
  144. package/dist/node_modules/lodash-es/_Uint8Array.js +0 -5
  145. package/dist/node_modules/lodash-es/_WeakMap.js +0 -6
  146. package/dist/node_modules/lodash-es/_arrayFilter.js +0 -10
  147. package/dist/node_modules/lodash-es/_arrayLikeKeys.js +0 -20
  148. package/dist/node_modules/lodash-es/_arrayMap.js +0 -8
  149. package/dist/node_modules/lodash-es/_arrayPush.js +0 -8
  150. package/dist/node_modules/lodash-es/_arraySome.js +0 -9
  151. package/dist/node_modules/lodash-es/_assocIndexOf.js +0 -10
  152. package/dist/node_modules/lodash-es/_baseEach.js +0 -6
  153. package/dist/node_modules/lodash-es/_baseFlatten.js +0 -13
  154. package/dist/node_modules/lodash-es/_baseFor.js +0 -5
  155. package/dist/node_modules/lodash-es/_baseForOwn.js +0 -8
  156. package/dist/node_modules/lodash-es/_baseGet.js +0 -11
  157. package/dist/node_modules/lodash-es/_baseGetAllKeys.js +0 -9
  158. package/dist/node_modules/lodash-es/_baseGetTag.js +0 -10
  159. package/dist/node_modules/lodash-es/_baseHasIn.js +0 -6
  160. package/dist/node_modules/lodash-es/_baseIsArguments.js +0 -9
  161. package/dist/node_modules/lodash-es/_baseIsEqual.js +0 -8
  162. package/dist/node_modules/lodash-es/_baseIsEqualDeep.js +0 -32
  163. package/dist/node_modules/lodash-es/_baseIsMatch.js +0 -29
  164. package/dist/node_modules/lodash-es/_baseIsNative.js +0 -16
  165. package/dist/node_modules/lodash-es/_baseIsTypedArray.js +0 -12
  166. package/dist/node_modules/lodash-es/_baseIteratee.js +0 -11
  167. package/dist/node_modules/lodash-es/_baseKeys.js +0 -14
  168. package/dist/node_modules/lodash-es/_baseMap.js +0 -11
  169. package/dist/node_modules/lodash-es/_baseMatches.js +0 -12
  170. package/dist/node_modules/lodash-es/_baseMatchesProperty.js +0 -17
  171. package/dist/node_modules/lodash-es/_baseProperty.js +0 -8
  172. package/dist/node_modules/lodash-es/_basePropertyDeep.js +0 -9
  173. package/dist/node_modules/lodash-es/_baseRange.js +0 -9
  174. package/dist/node_modules/lodash-es/_baseTimes.js +0 -8
  175. package/dist/node_modules/lodash-es/_baseToString.js +0 -18
  176. package/dist/node_modules/lodash-es/_baseTrim.js +0 -8
  177. package/dist/node_modules/lodash-es/_baseUnary.js +0 -8
  178. package/dist/node_modules/lodash-es/_cacheHas.js +0 -6
  179. package/dist/node_modules/lodash-es/_castPath.js +0 -10
  180. package/dist/node_modules/lodash-es/_coreJsData.js +0 -5
  181. package/dist/node_modules/lodash-es/_createBaseEach.js +0 -15
  182. package/dist/node_modules/lodash-es/_createBaseFor.js +0 -13
  183. package/dist/node_modules/lodash-es/_createRange.js +0 -11
  184. package/dist/node_modules/lodash-es/_equalArrays.js +0 -40
  185. package/dist/node_modules/lodash-es/_equalByTag.js +0 -45
  186. package/dist/node_modules/lodash-es/_equalObjects.js +0 -36
  187. package/dist/node_modules/lodash-es/_freeGlobal.js +0 -4
  188. package/dist/node_modules/lodash-es/_getAllKeys.js +0 -9
  189. package/dist/node_modules/lodash-es/_getMapData.js +0 -8
  190. package/dist/node_modules/lodash-es/_getMatchData.js +0 -12
  191. package/dist/node_modules/lodash-es/_getNative.js +0 -9
  192. package/dist/node_modules/lodash-es/_getRawTag.js +0 -15
  193. package/dist/node_modules/lodash-es/_getSymbols.js +0 -10
  194. package/dist/node_modules/lodash-es/_getTag.js +0 -28
  195. package/dist/node_modules/lodash-es/_getValue.js +0 -6
  196. package/dist/node_modules/lodash-es/_hasPath.js +0 -19
  197. package/dist/node_modules/lodash-es/_hashClear.js +0 -7
  198. package/dist/node_modules/lodash-es/_hashDelete.js +0 -7
  199. package/dist/node_modules/lodash-es/_hashGet.js +0 -13
  200. package/dist/node_modules/lodash-es/_hashHas.js +0 -9
  201. package/dist/node_modules/lodash-es/_hashSet.js +0 -9
  202. package/dist/node_modules/lodash-es/_isFlattenable.js +0 -10
  203. package/dist/node_modules/lodash-es/_isIndex.js +0 -8
  204. package/dist/node_modules/lodash-es/_isIterateeCall.js +0 -13
  205. package/dist/node_modules/lodash-es/_isKey.js +0 -12
  206. package/dist/node_modules/lodash-es/_isKeyable.js +0 -7
  207. package/dist/node_modules/lodash-es/_isMasked.js +0 -11
  208. package/dist/node_modules/lodash-es/_isPrototype.js +0 -8
  209. package/dist/node_modules/lodash-es/_isStrictComparable.js +0 -7
  210. package/dist/node_modules/lodash-es/_listCacheClear.js +0 -6
  211. package/dist/node_modules/lodash-es/_listCacheDelete.js +0 -12
  212. package/dist/node_modules/lodash-es/_listCacheGet.js +0 -8
  213. package/dist/node_modules/lodash-es/_listCacheHas.js +0 -7
  214. package/dist/node_modules/lodash-es/_listCacheSet.js +0 -8
  215. package/dist/node_modules/lodash-es/_mapCacheClear.js +0 -13
  216. package/dist/node_modules/lodash-es/_mapCacheDelete.js +0 -8
  217. package/dist/node_modules/lodash-es/_mapCacheGet.js +0 -7
  218. package/dist/node_modules/lodash-es/_mapCacheHas.js +0 -7
  219. package/dist/node_modules/lodash-es/_mapCacheSet.js +0 -8
  220. package/dist/node_modules/lodash-es/_mapToArray.js +0 -9
  221. package/dist/node_modules/lodash-es/_matchesStrictComparable.js +0 -8
  222. package/dist/node_modules/lodash-es/_memoizeCapped.js +0 -11
  223. package/dist/node_modules/lodash-es/_nativeCreate.js +0 -5
  224. package/dist/node_modules/lodash-es/_nativeKeys.js +0 -5
  225. package/dist/node_modules/lodash-es/_nodeUtil.js +0 -11
  226. package/dist/node_modules/lodash-es/_objectToString.js +0 -7
  227. package/dist/node_modules/lodash-es/_overArg.js +0 -8
  228. package/dist/node_modules/lodash-es/_root.js +0 -5
  229. package/dist/node_modules/lodash-es/_setCacheAdd.js +0 -7
  230. package/dist/node_modules/lodash-es/_setCacheHas.js +0 -6
  231. package/dist/node_modules/lodash-es/_setToArray.js +0 -9
  232. package/dist/node_modules/lodash-es/_stackClear.js +0 -7
  233. package/dist/node_modules/lodash-es/_stackDelete.js +0 -7
  234. package/dist/node_modules/lodash-es/_stackGet.js +0 -6
  235. package/dist/node_modules/lodash-es/_stackHas.js +0 -6
  236. package/dist/node_modules/lodash-es/_stackSet.js +0 -17
  237. package/dist/node_modules/lodash-es/_stringToPath.js +0 -10
  238. package/dist/node_modules/lodash-es/_toKey.js +0 -10
  239. package/dist/node_modules/lodash-es/_toSource.js +0 -17
  240. package/dist/node_modules/lodash-es/_trimmedEndIndex.js +0 -9
  241. package/dist/node_modules/lodash-es/eq.js +0 -6
  242. package/dist/node_modules/lodash-es/flatMap.js +0 -8
  243. package/dist/node_modules/lodash-es/get.js +0 -8
  244. package/dist/node_modules/lodash-es/hasIn.js +0 -8
  245. package/dist/node_modules/lodash-es/identity.js +0 -6
  246. package/dist/node_modules/lodash-es/isArguments.js +0 -10
  247. package/dist/node_modules/lodash-es/isArray.js +0 -4
  248. package/dist/node_modules/lodash-es/isArrayLike.js +0 -8
  249. package/dist/node_modules/lodash-es/isBuffer.js +0 -6
  250. package/dist/node_modules/lodash-es/isFunction.js +0 -12
  251. package/dist/node_modules/lodash-es/isLength.js +0 -7
  252. package/dist/node_modules/lodash-es/isObject.js +0 -7
  253. package/dist/node_modules/lodash-es/isObjectLike.js +0 -6
  254. package/dist/node_modules/lodash-es/isSymbol.js +0 -9
  255. package/dist/node_modules/lodash-es/isTypedArray.js +0 -7
  256. package/dist/node_modules/lodash-es/keys.js +0 -9
  257. package/dist/node_modules/lodash-es/map.js +0 -11
  258. package/dist/node_modules/lodash-es/memoize.js +0 -18
  259. package/dist/node_modules/lodash-es/property.js +0 -10
  260. package/dist/node_modules/lodash-es/range.js +0 -5
  261. package/dist/node_modules/lodash-es/stubArray.js +0 -6
  262. package/dist/node_modules/lodash-es/stubFalse.js +0 -6
  263. package/dist/node_modules/lodash-es/toFinite.js +0 -14
  264. package/dist/node_modules/lodash-es/toNumber.js +0 -22
  265. package/dist/node_modules/lodash-es/toString.js +0 -7
@@ -1,4 +1,4 @@
1
- import { defineComponent as v, computed as l, ref as O, watch as f } from "vue";
1
+ import { defineComponent as v, computed as o, ref as O, watch as f } from "vue";
2
2
  import { useTranslations as g } from "../../../../composables/useTranslations.js";
3
3
  import { useRecommendationExtensionStore as R } from "../../../../extensions/Blocks/Recommendation/store/recommendation.js";
4
4
  import { getTooltipOptions as T } from "../../../../utils/tooltipUtils.js";
@@ -12,11 +12,11 @@ const V = /* @__PURE__ */ v({
12
12
  },
13
13
  emits: ["reset-validation"],
14
14
  setup(x, { expose: u, emit: s }) {
15
- const p = g(), t = R(), a = l(() => t.getUniqueFilterGroups.map((e) => ({
15
+ const p = g(), t = R(), n = o(() => t.getUniqueFilterGroups.map((e) => ({
16
16
  text: e.toString(),
17
17
  value: e
18
18
  }))), r = O(1);
19
- f(a, (e) => {
19
+ f(n, (e) => {
20
20
  if (!e.length)
21
21
  return;
22
22
  e.some((h) => h.value === r.value) || (r.value = e[0].value);
@@ -27,27 +27,24 @@ const V = /* @__PURE__ */ v({
27
27
  u({ switchToGroup: i });
28
28
  const c = () => {
29
29
  s("reset-validation");
30
- const e = t.getUniqueFilterGroups, o = e.length > 0 ? Math.max(...e) + 1 : 1;
31
- t.addFilterGroup(o), r.value = o;
32
- }, d = l(() => a.value.length >= 3), n = l(() => t.getSelectedFilterGroup(r.value)), F = l(() => n.value.length >= 10), _ = l(() => n.value.length > 1), G = l(() => a.value.length > 1), m = l(() => {
33
- var o;
34
- return ((o = n.value[0]) == null ? void 0 : o.outerGroupOperator) || "*";
35
- });
36
- return { __sfc: !0, MAX_FILTER_GROUP_COUNT: 3, MAX_FILTER_PER_GROUP_COUNT: 10, trans: p, store: t, emit: s, filterGroupList: a, selectedFilterGroup: r, switchToGroup: i, handleAddFilterGroup: c, isMaxFilterGroupCount: d, selectedFilterGroupFilters: n, isMaxFilterPerGroupCount: F, hasLogicAdapter: _, hasRemoveFilterButton: G, outerGroupOperator: m, handleOuterGroupOperatorChange: (e) => {
37
- n.value.forEach((o) => {
38
- t.updateFilter({ ...o, outerGroupOperator: e });
30
+ const e = t.getUniqueFilterGroups, a = e.length > 0 ? Math.max(...e) + 1 : 1;
31
+ t.addFilterGroup(a), r.value = a;
32
+ }, d = o(() => n.value.length >= 3), l = o(() => t.getSelectedFilterGroup(r.value)), F = o(() => l.value.length >= 10), _ = o(() => l.value.length > 1), G = o(() => n.value.length > 1), m = o(() => l.value[0]?.outerGroupOperator || "*");
33
+ return { __sfc: !0, MAX_FILTER_GROUP_COUNT: 3, MAX_FILTER_PER_GROUP_COUNT: 10, trans: p, store: t, emit: s, filterGroupList: n, selectedFilterGroup: r, switchToGroup: i, handleAddFilterGroup: c, isMaxFilterGroupCount: d, selectedFilterGroupFilters: l, isMaxFilterPerGroupCount: F, hasLogicAdapter: _, hasRemoveFilterButton: G, outerGroupOperator: m, handleOuterGroupOperatorChange: (e) => {
34
+ l.value.forEach((a) => {
35
+ t.updateFilter({ ...a, outerGroupOperator: e });
39
36
  });
40
37
  }, handleAddFilter: () => {
41
38
  s("reset-validation"), t.addFilter(
42
39
  t.createDefaultFilter(
43
40
  r.value,
44
- n.value.length + 1
41
+ l.value.length + 1
45
42
  )
46
43
  );
47
44
  }, handleDeleteFilter: (e) => {
48
45
  t.deleteFilter(e);
49
46
  }, handleDeleteFilterGroup: () => {
50
- a.value.length <= 1 || t.deleteFilterGroup(r.value);
47
+ n.value.length <= 1 || t.deleteFilterGroup(r.value);
51
48
  }, getTooltipOptions: T, InSegments: E, InButtonV2: U, FilterItem: A, LogicAdapter: C };
52
49
  }
53
50
  });
@@ -1,23 +1,22 @@
1
- import l from "./EditorActions.vue2.js";
1
+ import i from "./EditorActions.vue2.js";
2
2
  /* empty css */
3
- import d from "../../../_virtual/_plugin-vue2_normalizer.js";
4
- var u = function() {
5
- var s, i, n, a;
3
+ import n from "../../../_virtual/_plugin-vue2_normalizer.js";
4
+ var a = function() {
6
5
  var o = this, e = o._self._c, t = o._self._setupProxy;
7
- return e("div", { staticClass: "d-f editor-actions" }, [t.isVersionHistoryButtonVisible ? e(t.InButtonV2, { attrs: { id: "guido__history-button", "left-icon": "line-architect-version-history", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isVersionHistoryButtonDisabled, "label-text-status": !1, "selected-status": t.editorStore.isVersionHistoryOpen, "tooltip-options": t.getTooltipOptions("guido__history-button"), "tooltip-text": t.versionHistoryTooltipText }, on: { click: t.handleVersionHistory } }) : o._e(), e(t.InButtonV2, { attrs: { id: "guido__export-button", "left-icon": "line-export", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isExportButtonDisabled, "label-text-status": !1, "loading-status": t.isExporting, "tooltip-options": t.getTooltipOptions("guido__export-button"), "tooltip-text": t.trans("newsletter.export") }, on: { click: t.handleExport } }), (i = (s = t.config) == null ? void 0 : s.features) != null && i.saveAsTemplate ? e(t.InButtonV2, { attrs: { id: "guido__save-as-button", "left-icon": "line-newsletter-save-as-template", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isSaveAsButtonDisabled, "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__save-as-button"), "tooltip-text": t.trans("newsletter.save-templates") }, on: { click: t.handleSaveAs } }) : o._e(), (a = (n = t.config) == null ? void 0 : n.features) != null && a.testMessage ? e(t.InButtonV2, { attrs: { id: "guido__test-button", "left-icon": "line-architect-test-journey", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isTestButtonDisabled, "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__test-button", { staticPosition: "bottom right" }), "tooltip-text": t.trans("newsletter.test-email") }, on: { click: t.handleTestEmail } }) : o._e(), t.editorStore.isPreviewModeOpen ? o._e() : e(t.InButtonV2, { staticClass: "ml-3", attrs: { id: "guido__save-button", "label-text": "Save", "disabled-status": !t.isSaving && t.editorStore.isSaveButtonDisabled, "loading-status": t.isSaving }, on: { click: function(r) {
6
+ return e("div", { staticClass: "d-f editor-actions" }, [t.isVersionHistoryButtonVisible ? e(t.InButtonV2, { attrs: { id: "guido__history-button", "left-icon": "line-architect-version-history", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isVersionHistoryButtonDisabled, "label-text-status": !1, "selected-status": t.editorStore.isVersionHistoryOpen, "tooltip-options": t.getTooltipOptions("guido__history-button"), "tooltip-text": t.versionHistoryTooltipText }, on: { click: t.handleVersionHistory } }) : o._e(), e(t.InButtonV2, { attrs: { id: "guido__export-button", "left-icon": "line-export", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isExportButtonDisabled, "label-text-status": !1, "loading-status": t.isExporting, "tooltip-options": t.getTooltipOptions("guido__export-button"), "tooltip-text": t.trans("newsletter.export") }, on: { click: t.handleExport } }), t.config?.features?.saveAsTemplate ? e(t.InButtonV2, { attrs: { id: "guido__save-as-button", "left-icon": "line-newsletter-save-as-template", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isSaveAsButtonDisabled, "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__save-as-button"), "tooltip-text": t.trans("newsletter.save-templates") }, on: { click: t.handleSaveAs } }) : o._e(), t.config?.features?.testMessage ? e(t.InButtonV2, { attrs: { id: "guido__test-button", "left-icon": "line-architect-test-journey", styling: "ghost", type: "secondary", "disabled-status": t.editorStore.isTestButtonDisabled, "label-text-status": !1, "tooltip-options": t.getTooltipOptions("guido__test-button", { staticPosition: "bottom right" }), "tooltip-text": t.trans("newsletter.test-email") }, on: { click: t.handleTestEmail } }) : o._e(), t.editorStore.isPreviewModeOpen ? o._e() : e(t.InButtonV2, { staticClass: "ml-3", attrs: { id: "guido__save-button", "label-text": "Save", "disabled-status": !t.isSaving && t.editorStore.isSaveButtonDisabled, "loading-status": t.isSaving }, on: { click: function(s) {
8
7
  return t.handleSave(!1);
9
- } } }), e(t.MigrationConfirmModal, { ref: "migrationModalRef", on: { confirm: function(r) {
8
+ } } }), e(t.MigrationConfirmModal, { ref: "migrationModalRef", on: { confirm: function(s) {
10
9
  return t.executeSave(!1);
11
10
  } } })], 1);
12
- }, p = [], c = /* @__PURE__ */ d(
13
- l,
14
- u,
15
- p,
11
+ }, r = [], l = /* @__PURE__ */ n(
12
+ i,
13
+ a,
14
+ r,
16
15
  !1,
17
16
  null,
18
17
  "4e2a4adb"
19
18
  );
20
- const v = c.exports;
19
+ const _ = l.exports;
21
20
  export {
22
- v as default
21
+ _ as default
23
22
  };
@@ -17,8 +17,8 @@ import K from "./MigrationConfirmModal.vue.js";
17
17
  const ut = /* @__PURE__ */ O({
18
18
  __name: "EditorActions",
19
19
  setup(N, { expose: x }) {
20
- const { config: a, isFeatureEnabled: l } = b(), { exportHtml: m } = k(), { save: u } = F(), { openVersionHistory: c, closeVersionHistory: p } = R(), { getCompiledEmail: f } = q(), { compileHtml: d } = D(), { validateLiquidSyntax: v } = z(), e = I(), y = P(), { hasMigrations: S } = J(y), s = L(), i = n(!1), r = n(!1), g = n(), H = B(), T = () => {
21
- if (e.isVersionHistoryOpen) {
20
+ const { config: a, isFeatureEnabled: l } = b(), { exportHtml: m } = k(), { save: u } = F(), { openVersionHistory: c, closeVersionHistory: p } = R(), { getCompiledEmail: f } = q(), { compileHtml: d } = D(), { validateLiquidSyntax: v } = z(), t = I(), y = P(), { hasMigrations: S } = J(y), s = L(), i = n(!1), r = n(!1), g = n(), H = B(), T = () => {
21
+ if (t.isVersionHistoryOpen) {
22
22
  p();
23
23
  return;
24
24
  }
@@ -26,39 +26,35 @@ const ut = /* @__PURE__ */ O({
26
26
  }, w = async () => {
27
27
  i.value = !0, await m(), i.value = !1;
28
28
  }, _ = () => {
29
- e.isSaveAsTemplateDrawerOpen = !0;
30
- }, C = h(() => e.isVersionHistoryOpen ? s("newsletter.close-version-history") : s("newsletter.version-history")), A = h(
31
- () => {
32
- var t, o;
33
- return ((o = (t = a.value) == null ? void 0 : t.features) == null ? void 0 : o.versionHistory) && !e.isPreviewModeOpen;
34
- }
35
- ), V = async (t) => {
36
- r.value = !0, e.loadingStatus = !0;
37
- const o = await u(t);
38
- return r.value = !1, (t || !o) && (e.loadingStatus = !1), o;
39
- }, E = (t) => {
40
- var o;
41
- if (!t && S.value) {
42
- (o = g.value) == null || o.open();
29
+ t.isSaveAsTemplateDrawerOpen = !0;
30
+ }, C = h(() => t.isVersionHistoryOpen ? s("newsletter.close-version-history") : s("newsletter.version-history")), A = h(
31
+ () => a.value?.features?.versionHistory && !t.isPreviewModeOpen
32
+ ), V = async (o) => {
33
+ r.value = !0, t.loadingStatus = !0;
34
+ const e = await u(o);
35
+ return r.value = !1, (o || !e) && (t.loadingStatus = !1), e;
36
+ }, E = (o) => {
37
+ if (!o && S.value) {
38
+ g.value?.open();
43
39
  return;
44
40
  }
45
- return V(t);
41
+ return V(o);
46
42
  }, M = async () => {
47
43
  if (l("liquidSyntax")) {
48
- e.loadingStatus = !0;
44
+ t.loadingStatus = !0;
49
45
  try {
50
- const { html: t } = await f({ minimize: !0, resetDataSavedFlag: !1 }), { compiledHtml: o } = d(t);
51
- if (!await v(o))
46
+ const { html: o } = await f({ minimize: !0, resetDataSavedFlag: !1 }), { compiledHtml: e } = d(o);
47
+ if (!await v(e))
52
48
  return;
53
49
  } finally {
54
- e.loadingStatus = !1;
50
+ t.loadingStatus = !1;
55
51
  }
56
52
  }
57
53
  H();
58
54
  };
59
55
  return x({
60
56
  handleSave: E
61
- }), { __sfc: !0, config: a, isFeatureEnabled: l, exportHtml: m, save: u, openVersionHistory: c, closeVersionHistory: p, getCompiledEmail: f, compileHtml: d, validateLiquidSyntax: v, editorStore: e, templateStore: y, hasMigrations: S, trans: s, isExporting: i, isSaving: r, migrationModalRef: g, testEmailClick: H, handleVersionHistory: T, handleExport: w, handleSaveAs: _, versionHistoryTooltipText: C, isVersionHistoryButtonVisible: A, executeSave: V, handleSave: E, handleTestEmail: M, getTooltipOptions: j, InButtonV2: G, MigrationConfirmModal: K };
57
+ }), { __sfc: !0, config: a, isFeatureEnabled: l, exportHtml: m, save: u, openVersionHistory: c, closeVersionHistory: p, getCompiledEmail: f, compileHtml: d, validateLiquidSyntax: v, editorStore: t, templateStore: y, hasMigrations: S, trans: s, isExporting: i, isSaving: r, migrationModalRef: g, testEmailClick: H, handleVersionHistory: T, handleExport: w, handleSaveAs: _, versionHistoryTooltipText: C, isVersionHistoryButtonVisible: A, executeSave: V, handleSave: E, handleTestEmail: M, getTooltipOptions: j, InButtonV2: G, MigrationConfirmModal: K };
62
58
  }
63
59
  });
64
60
  export {
@@ -1,20 +1,17 @@
1
- import { defineComponent as n, ref as m } from "vue";
2
- import { InContainer as a } from "@useinsider/design-system-vue";
3
- import f from "./LeftSlot.vue.js";
4
- import p from "./MiddleSlot.vue.js";
5
- import i from "./RightSlot.vue.js";
6
- const c = /* @__PURE__ */ n({
1
+ import { defineComponent as t, ref as n } from "vue";
2
+ import { InContainer as m } from "@useinsider/design-system-vue";
3
+ import a from "./LeftSlot.vue.js";
4
+ import f from "./MiddleSlot.vue.js";
5
+ import p from "./RightSlot.vue.js";
6
+ const S = /* @__PURE__ */ t({
7
7
  __name: "HeaderWrapper",
8
- setup(l, { expose: r }) {
9
- const e = m(null);
10
- return r({
11
- handleSave: (t) => {
12
- var o;
13
- return (o = e.value) == null ? void 0 : o.handleSave(t);
14
- }
15
- }), { __sfc: !0, rightSlotRef: e, InContainer: a, LeftSlot: f, MiddleSlot: p, RightSlot: i };
8
+ setup(i, { expose: o }) {
9
+ const e = n(null);
10
+ return o({
11
+ handleSave: (r) => e.value?.handleSave(r)
12
+ }), { __sfc: !0, rightSlotRef: e, InContainer: m, LeftSlot: a, MiddleSlot: f, RightSlot: p };
16
13
  }
17
14
  });
18
15
  export {
19
- c as default
16
+ S as default
20
17
  };
@@ -1,19 +1,16 @@
1
- import { defineComponent as l, computed as d, ref as p } from "vue";
2
- import { useConfig as k } from "../../../composables/useConfig.js";
3
- import { useBack as B } from "../../../composables/useGuidoActions.js";
4
- import { usePreviewMode as b } from "../../../composables/usePreviewMode.js";
5
- import { useTranslations as v } from "../../../composables/useTranslations.js";
6
- import { useVersionHistoryApi as _ } from "../../../composables/useVersionHistoryApi.js";
7
- import { useEditorStore as V } from "../../../stores/editor.js";
8
- import { InButtonV2 as g } from "@useinsider/design-system-vue";
9
- import { useDebounceFn as w } from "../../../node_modules/@vueuse/shared/index.js";
10
- const D = /* @__PURE__ */ l({
1
+ import { defineComponent as m, computed as f, ref as l } from "vue";
2
+ import { useConfig as d } from "../../../composables/useConfig.js";
3
+ import { useBack as p } from "../../../composables/useGuidoActions.js";
4
+ import { usePreviewMode as k } from "../../../composables/usePreviewMode.js";
5
+ import { useTranslations as B } from "../../../composables/useTranslations.js";
6
+ import { useVersionHistoryApi as b } from "../../../composables/useVersionHistoryApi.js";
7
+ import { useEditorStore as v } from "../../../stores/editor.js";
8
+ import { InButtonV2 as _ } from "@useinsider/design-system-vue";
9
+ import { useDebounceFn as V } from "../../../node_modules/@vueuse/shared/index.js";
10
+ const A = /* @__PURE__ */ m({
11
11
  __name: "LeftSlot",
12
- setup(y) {
13
- const e = V(), i = B(), { closeVersionHistory: n } = _(), { closePreviewMode: s } = b(), o = v(), { config: t } = k(), f = d(() => {
14
- var u, m;
15
- return e.isVersionHistoryOpen || e.isPreviewModeOpen ? o("email-editor.back-to-editor") : (m = (u = t.value) == null ? void 0 : u.ui) != null && m.backButtonLabel ? t.value.ui.backButtonLabel : o("email-editor.back-to-design");
16
- }), r = p(!1), c = () => {
12
+ setup(g) {
13
+ const e = v(), i = p(), { closeVersionHistory: n } = b(), { closePreviewMode: s } = k(), o = B(), { config: t } = d(), u = f(() => e.isVersionHistoryOpen || e.isPreviewModeOpen ? o("email-editor.back-to-editor") : t.value?.ui?.backButtonLabel ? t.value.ui.backButtonLabel : o("email-editor.back-to-design")), r = l(!1), c = () => {
17
14
  if (e.isVersionHistoryOpen) {
18
15
  n();
19
16
  return;
@@ -23,14 +20,14 @@ const D = /* @__PURE__ */ l({
23
20
  return;
24
21
  }
25
22
  e.loadingStatus = !0, i();
26
- }, a = w(() => {
23
+ }, a = V(() => {
27
24
  c(), r.value = !1;
28
25
  }, 500);
29
- return { __sfc: !0, editorStore: e, handleBack: i, closeVersionHistory: n, closePreviewMode: s, trans: o, config: t, backButtonLabel: f, isBackButtonDisabled: r, executeBackAction: c, debouncedBackAction: a, handleBackClick: () => {
26
+ return { __sfc: !0, editorStore: e, handleBack: i, closeVersionHistory: n, closePreviewMode: s, trans: o, config: t, backButtonLabel: u, isBackButtonDisabled: r, executeBackAction: c, debouncedBackAction: a, handleBackClick: () => {
30
27
  r.value = !0, a();
31
- }, InButtonV2: g };
28
+ }, InButtonV2: _ };
32
29
  }
33
30
  });
34
31
  export {
35
- D as default
32
+ A as default
36
33
  };
@@ -1,16 +1,19 @@
1
- import { defineComponent as o } from "vue";
2
- import r from "../email-preview/amp/AmpToggle.vue.js";
3
- import t from "../email-preview/desktop-preview/EmailSizeIndicator.vue.js";
4
- import { useEditorStore as i } from "../../../stores/editor.js";
5
- import e from "./EditorToolbar.vue.js";
6
- import m from "./version-history/VersionHistory.vue.js";
7
- import p from "./version-history/ViewOptions.vue.js";
8
- const S = /* @__PURE__ */ o({
1
+ import { defineComponent as e, defineAsyncComponent as o } from "vue";
2
+ import m from "../email-preview/amp/AmpToggle.vue.js";
3
+ import n from "../email-preview/desktop-preview/EmailSizeIndicator.vue.js";
4
+ import { useEditorStore as s } from "../../../stores/editor.js";
5
+ import p from "./EditorToolbar.vue.js";
6
+ const u = /* @__PURE__ */ e({
9
7
  __name: "MiddleSlot",
10
- setup(s) {
11
- return { __sfc: !0, editorStore: i(), AmpToggle: r, EmailSizeIndicator: t, EditorToolbar: e, VersionHistory: m, VersionHistoryViewOptions: p };
8
+ setup(f) {
9
+ const r = o(
10
+ () => import("./version-history/VersionHistory.vue.js")
11
+ ), t = o(
12
+ () => import("./version-history/ViewOptions.vue.js")
13
+ ), i = s();
14
+ return { __sfc: !0, VersionHistory: r, VersionHistoryViewOptions: t, editorStore: i, AmpToggle: m, EmailSizeIndicator: n, EditorToolbar: p };
12
15
  }
13
16
  });
14
17
  export {
15
- S as default
18
+ u as default
16
19
  };
@@ -1,22 +1,19 @@
1
- import { defineComponent as a, ref as f, computed as p } from "vue";
2
- import { useConfig as u } from "../../../composables/useConfig.js";
3
- import { useTranslations as d } from "../../../composables/useTranslations.js";
4
- import { useEditorStore as c } from "../../../stores/editor.js";
5
- import { InChips as l } from "@useinsider/design-system-vue";
6
- import _ from "./EditorActions.vue.js";
7
- import S from "./version-history/RestoreButton.vue.js";
8
- const x = /* @__PURE__ */ a({
1
+ import { defineComponent as m, ref as a, computed as f } from "vue";
2
+ import { useConfig as p } from "../../../composables/useConfig.js";
3
+ import { useTranslations as u } from "../../../composables/useTranslations.js";
4
+ import { useEditorStore as d } from "../../../stores/editor.js";
5
+ import { InChips as c } from "@useinsider/design-system-vue";
6
+ import l from "./EditorActions.vue.js";
7
+ import _ from "./version-history/RestoreButton.vue.js";
8
+ const q = /* @__PURE__ */ m({
9
9
  __name: "RightSlot",
10
- setup(h, { expose: r }) {
11
- const { isFeatureEnabled: o } = u(), n = d(), i = c(), t = f(null), s = p(() => o("liquidSyntax"));
12
- return r({
13
- handleSave: (m) => {
14
- var e;
15
- return (e = t.value) == null ? void 0 : e.handleSave(m);
16
- }
17
- }), { __sfc: !0, isFeatureEnabled: o, trans: n, editorStore: i, editorActionsRef: t, isLiquidEnabled: s, InChips: l, EditorActions: _, RestoreButton: S };
10
+ setup(S, { expose: e }) {
11
+ const { isFeatureEnabled: o } = p(), r = u(), n = d(), t = a(null), i = f(() => o("liquidSyntax"));
12
+ return e({
13
+ handleSave: (s) => t.value?.handleSave(s)
14
+ }), { __sfc: !0, isFeatureEnabled: o, trans: r, editorStore: n, editorActionsRef: t, isLiquidEnabled: i, InChips: c, EditorActions: l, RestoreButton: _ };
18
15
  }
19
16
  });
20
17
  export {
21
- x as default
18
+ q as default
22
19
  };
@@ -1,20 +1,19 @@
1
- import d from "./AMPOnboarding.vue2.js";
2
- import g from "../../../_virtual/_plugin-vue2_normalizer.js";
3
- var l = function() {
4
- var t, r, e, i, a, s;
5
- var n = this, p = n._self._c, o = n._self._setupProxy;
6
- return o.isVisible ? p(o.InOnboard, { key: "guido__amp-onboard", staticClass: "w-21-s p-a z-11", class: (t = o.onboardingStore.getAmpCurrentCard) == null ? void 0 : t.classes, attrs: { id: "guido__amp-onboard", "is-multiple-page": "", visible: "", "image-source": "", title: "", "bottom-position": (r = o.onboardingStore.getAmpCurrentCard) == null ? void 0 : r.bottom, "left-position": (e = o.onboardingStore.getAmpCurrentCard) == null ? void 0 : e.left, "pages-config": o.onboardingStore.onboardings.ampOnboarding.config, "pointer-position": (i = o.onboardingStore.getAmpCurrentCard) == null ? void 0 : i.position, "right-position": (a = o.onboardingStore.getAmpCurrentCard) == null ? void 0 : a.right, "top-position": (s = o.onboardingStore.getAmpCurrentCard) == null ? void 0 : s.top }, on: { backButtonClick: o.handleBack, close: function(u) {
1
+ import r from "./AMPOnboarding.vue2.js";
2
+ import e from "../../../_virtual/_plugin-vue2_normalizer.js";
3
+ var i = function() {
4
+ var n = this, t = n._self._c, o = n._self._setupProxy;
5
+ return o.isVisible ? t(o.InOnboard, { key: "guido__amp-onboard", staticClass: "w-21-s p-a z-11", class: o.onboardingStore.getAmpCurrentCard?.classes, attrs: { id: "guido__amp-onboard", "is-multiple-page": "", visible: "", "image-source": "", title: "", "bottom-position": o.onboardingStore.getAmpCurrentCard?.bottom, "left-position": o.onboardingStore.getAmpCurrentCard?.left, "pages-config": o.onboardingStore.onboardings.ampOnboarding.config, "pointer-position": o.onboardingStore.getAmpCurrentCard?.position, "right-position": o.onboardingStore.getAmpCurrentCard?.right, "top-position": o.onboardingStore.getAmpCurrentCard?.top }, on: { backButtonClick: o.handleBack, close: function(d) {
7
6
  return o.onboardingStore.close("ampOnboarding");
8
7
  }, nextButtonClick: o.handleNext } }) : n._e();
9
- }, m = [], c = /* @__PURE__ */ g(
10
- d,
11
- l,
12
- m,
8
+ }, a = [], s = /* @__PURE__ */ e(
9
+ r,
10
+ i,
11
+ a,
13
12
  !1,
14
13
  null,
15
14
  null
16
15
  );
17
- const f = c.exports;
16
+ const m = s.exports;
18
17
  export {
19
- f as default
18
+ m as default
20
19
  };
@@ -1,37 +1,55 @@
1
- import { defineComponent as p, computed as e, watch as m } from "vue";
2
- import { useTranslations as g } from "../../../composables/useTranslations.js";
3
- import { useOnboardingStore as u } from "../../../stores/onboarding.js";
4
- import { InOnboard as b } from "@useinsider/design-system-vue";
5
- const O = /* @__PURE__ */ p({
1
+ import { defineComponent as u, computed as d, watch as b, nextTick as f } from "vue";
2
+ import { useTranslations as C } from "../../../composables/useTranslations.js";
3
+ import { HEADER_SELECTOR as O, AMP_TOGGLE_BUTTON_SELECTOR as _, AMP_TOGGLE_WRAPPER_SELECTOR as T, POPOVER_LEFT_OFFSET as g, POPOVER_TOP_GAP as E } from "../../../enums/onboarding.js";
4
+ import { useOnboardingStore as x } from "../../../stores/onboarding.js";
5
+ import { InOnboard as B } from "@useinsider/design-system-vue";
6
+ const G = /* @__PURE__ */ u({
6
7
  __name: "AMPOnboarding",
7
- setup(l) {
8
- const i = g(), o = u(), r = e(() => `${window.innerWidth / 2 - 110}px`), a = e(() => [
9
- {
10
- classes: "guido-amp-onboarding",
11
- left: r.value,
12
- top: "70px",
13
- position: "Top Center",
14
- title: i("email-editor.onboarding-amp-title"),
15
- description: i("email-editor.onboarding-amp-description"),
16
- imageSource: "",
17
- backButtonClick: () => {
18
- },
19
- nextButtonType: "text",
20
- nextButtonText: i("action-builder.ok"),
21
- nextButtonClick: () => void o.close("ampOnboarding")
22
- }
23
- ]), d = e(() => o.onboardings.ampOnboarding.config.length > 0 && o.onboardings.ampOnboarding.isActive), s = () => {
24
- var n, t;
25
- (t = (n = o.getAmpCurrentCard) == null ? void 0 : n.nextButtonClick) == null || t.call(n);
26
- }, c = () => {
27
- var n, t;
28
- (t = (n = o.getAmpCurrentCard) == null ? void 0 : n.backButtonClick) == null || t.call(n);
8
+ setup(P) {
9
+ const n = C(), t = x(), i = () => {
10
+ const o = document.querySelector(O), c = document.querySelector(_)?.closest(T);
11
+ if (!c || !o)
12
+ return {
13
+ left: `${(o?.offsetWidth ?? window.innerWidth) / 2 - g}px`,
14
+ top: "68px"
15
+ };
16
+ const s = o.getBoundingClientRect(), e = c.getBoundingClientRect();
17
+ return {
18
+ left: `${e.left - s.left + e.width / 2 - g}px`,
19
+ top: `${e.bottom - s.top + E}px`
20
+ };
21
+ }, r = d(() => {
22
+ const { left: o, top: a } = i();
23
+ return [
24
+ {
25
+ classes: "guido-amp-onboarding",
26
+ left: o,
27
+ top: a,
28
+ position: "Top Center",
29
+ title: n("email-editor.onboarding-amp-title"),
30
+ description: n("email-editor.onboarding-amp-description"),
31
+ imageSource: "",
32
+ backButtonClick: () => {
33
+ },
34
+ nextButtonType: "text",
35
+ nextButtonText: n("action-builder.ok"),
36
+ nextButtonClick: () => void t.close("ampOnboarding")
37
+ }
38
+ ];
39
+ }), l = d(() => t.onboardings.ampOnboarding.config.length > 0 && t.onboardings.ampOnboarding.isActive), p = () => {
40
+ t.getAmpCurrentCard?.nextButtonClick?.();
41
+ }, m = () => {
42
+ t.getAmpCurrentCard?.backButtonClick?.();
29
43
  };
30
- return m(() => o.onboardings.ampOnboarding.isActive, (n) => {
31
- n && o.setConfig("ampOnboarding", a.value);
32
- }, { immediate: !0 }), { __sfc: !0, trans: i, onboardingStore: o, centerLeft: r, onboardingCardsConfig: a, isVisible: d, handleNext: s, handleBack: c, InOnboard: b };
44
+ return b(
45
+ () => t.onboardings.ampOnboarding.isActive,
46
+ async (o) => {
47
+ o && (await f(), t.setConfig("ampOnboarding", r.value));
48
+ },
49
+ { immediate: !0 }
50
+ ), { __sfc: !0, trans: n, onboardingStore: t, getTogglePosition: i, onboardingCardsConfig: r, isVisible: l, handleNext: p, handleBack: m, InOnboard: B };
33
51
  }
34
52
  });
35
53
  export {
36
- O as default
54
+ G as default
37
55
  };
@@ -1,21 +1,20 @@
1
- import c from "./GenericOnboarding.vue2.js";
1
+ import n from "./GenericOnboarding.vue2.js";
2
2
  /* empty css */
3
- import g from "../../../_virtual/_plugin-vue2_normalizer.js";
4
- var l = function() {
5
- var r, n, t, i, a, s;
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) {
3
+ import t from "../../../_virtual/_plugin-vue2_normalizer.js";
4
+ var i = function() {
5
+ var o = this, r = o._self._c, e = o._self._setupProxy;
6
+ return e.isVisible ? r(e.InOnboard, { key: "guido__editor-onboard", staticClass: "w-21-s p-a z-11", class: e.onboardingStore.getGenericCurrentCard?.classes, attrs: { id: "guido__editor-onboard", "is-multiple-page": "", visible: "", "image-source": "", title: "", "bottom-position": e.onboardingStore.getGenericCurrentCard?.bottom, "left-position": e.onboardingStore.getGenericCurrentCard?.left, "pages-config": e.onboardingStore.onboardings.genericOnboarding.config, "pointer-position": e.onboardingStore.getGenericCurrentCard?.position, "right-position": e.onboardingStore.getGenericCurrentCard?.right, "top-position": e.onboardingStore.getGenericCurrentCard?.top }, on: { backButtonClick: e.handleBack, close: function(c) {
8
7
  return e.onboardingStore.close("genericOnboarding");
9
8
  }, nextButtonClick: e.handleNext } }) : o._e();
10
- }, p = [], _ = /* @__PURE__ */ g(
11
- c,
12
- l,
13
- p,
9
+ }, a = [], s = /* @__PURE__ */ t(
10
+ n,
11
+ i,
12
+ a,
14
13
  !1,
15
14
  null,
16
- "29b9af29"
15
+ "7419ae06"
17
16
  );
18
- const S = _.exports;
17
+ const _ = s.exports;
19
18
  export {
20
- S as default
19
+ _ as default
21
20
  };
@@ -1,33 +1,33 @@
1
- import { defineComponent as l, computed as i, watch as b } from "vue";
1
+ import { defineComponent as b, computed as i, watch as l } from "vue";
2
+ import { useRibbonOffset as m } from "../../../composables/useRibbonOffset.js";
2
3
  import { useTranslations as x } from "../../../composables/useTranslations.js";
3
- import { SERVICE_HOVER_SELECTORS as m } from "../../../enums/onboarding.js";
4
+ import { SERVICE_HOVER_SELECTORS as f } from "../../../enums/onboarding.js";
4
5
  import { useOnboardingStore as k } from "../../../stores/onboarding.js";
5
- import { InOnboard as f } from "@useinsider/design-system-vue";
6
- const S = /* @__PURE__ */ l({
6
+ import { InOnboard as B } from "@useinsider/design-system-vue";
7
+ const w = /* @__PURE__ */ b({
7
8
  __name: "GenericOnboarding",
8
- setup(B) {
9
- const e = x(), o = k(), r = i(() => `${window.innerWidth / 2 - 160}px`), c = () => {
10
- const t = document.querySelector("ui-editor");
11
- t != null && t.shadowRoot && m.forEach((n) => {
12
- var d;
13
- const a = (d = t.shadowRoot) == null ? void 0 : d.querySelector(n);
9
+ setup(C) {
10
+ const t = x(), e = k(), { getTopPosition: n } = m(), r = i(() => `${window.innerWidth / 2 - 146}px`), s = () => {
11
+ const o = document.querySelector("ui-editor");
12
+ o?.shadowRoot && f.forEach((p) => {
13
+ const a = o.shadowRoot?.querySelector(p);
14
14
  a && a.classList.add("hover");
15
15
  });
16
- }, s = i(() => [
16
+ }, c = i(() => [
17
17
  {
18
18
  classes: "guido-onboarding-blocks",
19
19
  left: "90px",
20
- top: "90px",
20
+ top: n(90),
21
21
  position: "Left Top",
22
- title: e("email-editor.onboarding-blocks-title"),
23
- description: e("email-editor.onboarding-blocks-description"),
22
+ title: t("email-editor.onboarding-blocks-title"),
23
+ description: t("email-editor.onboarding-blocks-description"),
24
24
  imageSource: "",
25
25
  backButtonClick: () => {
26
26
  },
27
27
  nextButtonType: "text",
28
- nextButtonText: e("products.next"),
28
+ nextButtonText: t("products.next"),
29
29
  nextButtonClick: () => {
30
- c(), o.next("genericOnboarding");
30
+ s(), e.next("genericOnboarding");
31
31
  }
32
32
  },
33
33
  {
@@ -35,49 +35,47 @@ const S = /* @__PURE__ */ l({
35
35
  right: "426px",
36
36
  bottom: "38px",
37
37
  position: "Right Bottom",
38
- title: e("email-editor.onboarding-stripes-title"),
39
- description: e("email-editor.onboarding-stripes-description"),
38
+ title: t("email-editor.onboarding-stripes-title"),
39
+ description: t("email-editor.onboarding-stripes-description"),
40
40
  imageSource: "",
41
41
  backButtonType: "text",
42
- backButtonText: e("ds-steps.back"),
42
+ backButtonText: t("ds-steps.back"),
43
43
  backButtonClick: () => {
44
- o.previous("genericOnboarding");
44
+ e.previous("genericOnboarding");
45
45
  },
46
46
  nextButtonType: "text",
47
- nextButtonText: e("products.next"),
47
+ nextButtonText: t("products.next"),
48
48
  nextButtonClick: () => {
49
- o.next("genericOnboarding");
49
+ e.next("genericOnboarding");
50
50
  }
51
51
  },
52
52
  {
53
53
  classes: "guido-onboarding-preview",
54
54
  left: r.value,
55
- top: "90px",
55
+ top: n(68),
56
56
  position: "Top Center",
57
- title: e("email-editor.onboarding-preview-title"),
58
- description: e("email-editor.onboarding-preview-description"),
57
+ title: t("email-editor.onboarding-preview-title"),
58
+ description: t("email-editor.onboarding-preview-description"),
59
59
  imageSource: "",
60
60
  backButtonType: "text",
61
- backButtonText: e("ds-steps.back"),
62
- backButtonClick: () => o.previous("genericOnboarding"),
61
+ backButtonText: t("ds-steps.back"),
62
+ backButtonClick: () => e.previous("genericOnboarding"),
63
63
  nextButtonType: "text",
64
- nextButtonText: e("action-builder.ok"),
64
+ nextButtonText: t("action-builder.ok"),
65
65
  nextButtonClick: () => {
66
- o.close("genericOnboarding");
66
+ e.close("genericOnboarding");
67
67
  }
68
68
  }
69
- ]), g = i(() => o.onboardings.genericOnboarding.config.length > 0 && o.onboardings.genericOnboarding.isActive), p = () => {
70
- var t, n;
71
- (n = (t = o.getGenericCurrentCard) == null ? void 0 : t.nextButtonClick) == null || n.call(t);
69
+ ]), d = i(() => e.onboardings.genericOnboarding.config.length > 0 && e.onboardings.genericOnboarding.isActive), g = () => {
70
+ e.getGenericCurrentCard?.nextButtonClick?.();
72
71
  }, u = () => {
73
- var t, n;
74
- (n = (t = o.getGenericCurrentCard) == null ? void 0 : t.backButtonClick) == null || n.call(t);
72
+ e.getGenericCurrentCard?.backButtonClick?.();
75
73
  };
76
- return b(() => o.onboardings.genericOnboarding.isActive, (t) => {
77
- t && o.setConfig("genericOnboarding", s.value);
78
- }, { immediate: !0 }), { __sfc: !0, trans: e, onboardingStore: o, centerLeft: r, addHoverToServiceElements: c, onboardingCardsConfig: s, isVisible: g, handleNext: p, handleBack: u, InOnboard: f };
74
+ return l(() => e.onboardings.genericOnboarding.isActive, (o) => {
75
+ o && e.setConfig("genericOnboarding", c.value);
76
+ }, { immediate: !0 }), { __sfc: !0, trans: t, onboardingStore: e, getTopPosition: n, centerLeft: r, addHoverToServiceElements: s, onboardingCardsConfig: c, isVisible: d, handleNext: g, handleBack: u, InOnboard: B };
79
77
  }
80
78
  });
81
79
  export {
82
- S as default
80
+ w as default
83
81
  };