@useinsider/guido 3.26.0 → 3.27.0-beta.0dd857f

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 (124) hide show
  1. package/README.md +1 -0
  2. package/dist/@types/config/schemas.js +93 -91
  3. package/dist/@types/display-condition.js +25 -0
  4. package/dist/@types/email-be/html-validation.js +28 -0
  5. package/dist/components/Guido.vue.js +5 -5
  6. package/dist/components/Guido.vue2.js +104 -98
  7. package/dist/components/organisms/display-conditions/CodeEditorField.vue.js +17 -0
  8. package/dist/components/organisms/display-conditions/CodeEditorField.vue2.js +41 -0
  9. package/dist/components/organisms/display-conditions/DisplayConditionCreateDrawer.vue.js +30 -0
  10. package/dist/components/organisms/display-conditions/DisplayConditionCreateDrawer.vue2.js +81 -0
  11. package/dist/components/organisms/display-conditions/DisplayConditionListState.vue.js +17 -0
  12. package/dist/components/organisms/display-conditions/DisplayConditionListState.vue2.js +45 -0
  13. package/dist/components/organisms/display-conditions/DisplayConditionSelectDrawer.vue.js +36 -0
  14. package/dist/components/organisms/display-conditions/DisplayConditionSelectDrawer.vue2.js +63 -0
  15. package/dist/components/organisms/display-conditions/DisplayConditionsHost.vue.js +17 -0
  16. package/dist/components/organisms/display-conditions/DisplayConditionsHost.vue2.js +22 -0
  17. package/dist/components/organisms/onboarding/GenericOnboarding.vue.js +5 -5
  18. package/dist/components/organisms/onboarding/GenericOnboarding.vue2.js +15 -15
  19. package/dist/components/organisms/onboarding/ItemsOnboarding.vue.js +6 -6
  20. package/dist/components/organisms/onboarding/ItemsOnboarding.vue2.js +28 -27
  21. package/dist/components/organisms/onboarding/RecommendationLegacyStrategyOnboarding.vue.js +3 -3
  22. package/dist/components/organisms/onboarding/RecommendationLegacyStrategyOnboarding.vue2.js +42 -27
  23. package/dist/composables/useBlocksConfig.js +29 -20
  24. package/dist/composables/useCustomInterfaceAppearance.js +50 -50
  25. package/dist/composables/useDisplayConditions.js +116 -0
  26. package/dist/composables/useFullStoryBridge.js +10 -9
  27. package/dist/composables/useSave.js +19 -17
  28. package/dist/composables/useSaveValidation.js +134 -252
  29. package/dist/composables/useTranslations.js +14 -8
  30. package/dist/config/compiler/utils/itemsCompilerUtils.js +43 -42
  31. package/dist/config/compiler/utils/recommendationCompilerUtils.js +67 -64
  32. package/dist/enums/academy.js +1 -0
  33. package/dist/enums/display-condition.js +12 -0
  34. package/dist/enums/email-be.js +27 -0
  35. package/dist/enums/save-validation.js +2 -2
  36. package/dist/extensions/Blocks/Recommendation/controls/main/filters.js +14 -14
  37. package/dist/extensions/Blocks/Recommendation/controls/main/strategy.js +52 -40
  38. package/dist/extensions/Blocks/Recommendation/controls/syncInfoMessage.js +15 -15
  39. package/dist/extensions/Blocks/Recommendation/utils/priceFormatter.js +17 -15
  40. package/dist/extensions/Blocks/common-control.js +25 -25
  41. package/dist/extensions/DisplayConditions/bridge.js +25 -0
  42. package/dist/extensions/DisplayConditions/constants.js +26 -0
  43. package/dist/extensions/DisplayConditions/control.js +215 -0
  44. package/dist/extensions/DisplayConditions/display-conditions.css.js +226 -0
  45. package/dist/extensions/DisplayConditions/extension.js +28 -0
  46. package/dist/extensions/DisplayConditions/iconsRegistry.js +20 -0
  47. package/dist/extensions/DisplayConditions/library.js +30 -0
  48. package/dist/extensions/DisplayConditions/settingsPanel.js +17 -0
  49. package/dist/extensions/DynamicContent/dynamic-content.js +15 -17
  50. package/dist/guido.css +1 -1
  51. package/dist/node_modules/@stripoinc/ui-editor-extensions/dist/esm/index.js +93 -92
  52. package/dist/node_modules/valibot/dist/index.js +405 -291
  53. package/dist/package.json.js +2 -2
  54. package/dist/services/displayConditionApi.js +39 -0
  55. package/dist/services/emailBe/errors/ApiError.js +50 -0
  56. package/dist/services/emailBe/errors/handleApiError.js +31 -0
  57. package/dist/services/emailBe/errors/toApiError.js +71 -0
  58. package/dist/services/emailBe/html/HtmlValidationService.js +35 -0
  59. package/dist/services/emailBe/html/index.js +6 -0
  60. package/dist/services/emailBe/http/HttpManager.js +68 -0
  61. package/dist/services/emailBe/http/RetryStack.js +24 -0
  62. package/dist/services/emailBe/http/client.js +61 -0
  63. package/dist/services/emailBe/http/index.js +10 -0
  64. package/dist/services/emailBe/http/transportErrors.js +20 -0
  65. package/dist/src/@types/config/schemas.d.ts +4 -0
  66. package/dist/src/@types/display-condition.d.ts +61 -0
  67. package/dist/src/@types/email-be/html-validation.d.ts +51 -0
  68. package/dist/src/components/organisms/display-conditions/CodeEditorField.vue.d.ts +43 -0
  69. package/dist/src/components/organisms/display-conditions/DisplayConditionCreateDrawer.vue.d.ts +2 -0
  70. package/dist/src/components/organisms/display-conditions/DisplayConditionListState.vue.d.ts +18 -0
  71. package/dist/src/components/organisms/display-conditions/DisplayConditionSelectDrawer.vue.d.ts +2 -0
  72. package/dist/src/components/organisms/display-conditions/DisplayConditionsHost.vue.d.ts +2 -0
  73. package/dist/src/composables/useConfig.d.ts +2 -0
  74. package/dist/src/composables/useDisplayConditions.d.ts +18 -0
  75. package/dist/src/composables/useSaveValidation.d.ts +2 -2
  76. package/dist/src/enums/academy.d.ts +1 -0
  77. package/dist/src/enums/display-condition.d.ts +15 -0
  78. package/dist/src/enums/email-be.d.ts +26 -0
  79. package/dist/src/enums/save-validation.d.ts +3 -15
  80. package/dist/src/extensions/Blocks/Recommendation/controls/main/strategy.d.ts +2 -0
  81. package/dist/src/extensions/Blocks/common-control.d.ts +1 -1
  82. package/dist/src/extensions/DisplayConditions/bridge.d.ts +7 -0
  83. package/dist/src/extensions/DisplayConditions/constants.d.ts +23 -0
  84. package/dist/src/extensions/DisplayConditions/control.d.ts +25 -0
  85. package/dist/src/extensions/{Blocks/_Boilerplate → DisplayConditions}/iconsRegistry.d.ts +1 -1
  86. package/dist/src/extensions/DisplayConditions/library.d.ts +8 -0
  87. package/dist/src/extensions/DisplayConditions/settingsPanel.d.ts +5 -0
  88. package/dist/src/mock/api/display-conditions.d.ts +2 -0
  89. package/dist/src/services/displayConditionApi.d.ts +8 -0
  90. package/dist/src/services/emailBe/errors/ApiError.d.ts +40 -0
  91. package/dist/src/services/emailBe/errors/handleApiError.d.ts +11 -0
  92. package/dist/src/services/emailBe/errors/toApiError.d.ts +2 -0
  93. package/dist/src/services/emailBe/html/HtmlValidationService.d.ts +8 -0
  94. package/dist/src/services/emailBe/html/index.d.ts +2 -0
  95. package/dist/src/services/emailBe/http/HttpManager.d.ts +13 -0
  96. package/dist/src/services/emailBe/http/RetryStack.d.ts +6 -0
  97. package/dist/src/services/emailBe/http/client.d.ts +3 -0
  98. package/dist/src/services/emailBe/http/index.d.ts +2 -0
  99. package/dist/src/services/emailBe/http/transportErrors.d.ts +15 -0
  100. package/dist/src/services/emailBe/http/types.d.ts +46 -0
  101. package/dist/src/stores/config.d.ts +170 -0
  102. package/dist/src/stores/display-condition.d.ts +86 -0
  103. package/dist/src/stores/onboarding.d.ts +1 -0
  104. package/dist/src/utils/displayCondition.d.ts +11 -0
  105. package/dist/src/utils/editorShadowRoot.d.ts +1 -0
  106. package/dist/src/utils/protectTableText.d.ts +2 -0
  107. package/dist/static/styles/variables.css.js +1 -0
  108. package/dist/stores/config.js +13 -6
  109. package/dist/stores/display-condition.js +29 -0
  110. package/dist/stores/onboarding.js +4 -1
  111. package/dist/utils/displayCondition.js +29 -0
  112. package/dist/utils/editorShadowRoot.js +8 -0
  113. package/dist/utils/pairProductVariables.js +29 -28
  114. package/dist/utils/protectTableText.js +22 -0
  115. package/package.json +10 -2
  116. package/dist/src/extensions/Blocks/_Boilerplate/block.d.ts +0 -11
  117. package/dist/src/extensions/Blocks/_Boilerplate/constants/controlIds.d.ts +0 -7
  118. package/dist/src/extensions/Blocks/_Boilerplate/constants/index.d.ts +0 -10
  119. package/dist/src/extensions/Blocks/_Boilerplate/constants/selectors.d.ts +0 -16
  120. package/dist/src/extensions/Blocks/_Boilerplate/control.d.ts +0 -17
  121. package/dist/src/extensions/Blocks/_Boilerplate/controls/blockBackground/index.d.ts +0 -15
  122. package/dist/src/extensions/Blocks/_Boilerplate/settingsPanel.d.ts +0 -4
  123. package/dist/src/extensions/Blocks/_Boilerplate/template.d.ts +0 -6
  124. /package/dist/src/extensions/{Blocks/_Boilerplate → DisplayConditions}/extension.d.ts +0 -0
@@ -1,75 +1,79 @@
1
- import { defineComponent as fe, defineAsyncComponent as m, ref as W, computed as u, watch as G, onMounted as ge, onUnmounted as ye } from "vue";
2
- import { useCortexBlueprintBridge as be } from "../composables/useCortexBlueprintBridge.js";
3
- import { useEditorLock as ve } from "../composables/useEditorLock.js";
4
- import { startEditorOpenMetrics as Se } from "../composables/useEditorOpenMetrics.js";
5
- import { provideGuidoActions as he } from "../composables/useGuidoActions.js";
6
- import { useGuidoStateBridge as Ee } from "../composables/useGuidoStateBridge.js";
7
- import { usePartner as Ce } from "../composables/usePartner.js";
8
- import { useSaveValidationRollout as we } from "../composables/useSaveValidationRollout.js";
9
- import { useStripo as Te } from "../composables/useStripo.js";
10
- import { useTimerClone as ke } from "../composables/useTimerClone.js";
11
- import { useToaster as Fe } from "../composables/useToaster.js";
12
- import { useTranslations as De } from "../composables/useTranslations.js";
13
- import { migrate as Ie } from "../config/migrator/index.js";
1
+ import { defineComponent as ye, defineAsyncComponent as a, ref as W, computed as l, watch as G, onMounted as be, onUnmounted as ve } from "vue";
2
+ import { useCortexBlueprintBridge as Se } from "../composables/useCortexBlueprintBridge.js";
3
+ import { useEditorLock as he } from "../composables/useEditorLock.js";
4
+ import { startEditorOpenMetrics as Ee } from "../composables/useEditorOpenMetrics.js";
5
+ import { provideGuidoActions as Ce } from "../composables/useGuidoActions.js";
6
+ import { useGuidoStateBridge as De } from "../composables/useGuidoStateBridge.js";
7
+ import { usePartner as we } from "../composables/usePartner.js";
8
+ import { useSaveValidationRollout as Te } from "../composables/useSaveValidationRollout.js";
9
+ import { useStripo as ke } from "../composables/useStripo.js";
10
+ import { useTimerClone as Fe } from "../composables/useTimerClone.js";
11
+ import { useToaster as Ie } from "../composables/useToaster.js";
12
+ import { useTranslations as Le } from "../composables/useTranslations.js";
13
+ import { migrate as Me } from "../config/migrator/index.js";
14
14
  import { ModuleFolderDefaults as $ } from "../enums/defaults.js";
15
- import { RIBBON_SELECTOR as Me } from "../enums/onboarding.js";
16
- import { ToasterTypeOptions as Le } from "../enums/toaster.js";
17
- import { useRecommendationExtensionStore as z, disposeStrategyPageReturnListeners as Re } from "../extensions/Blocks/Recommendation/store/recommendation.js";
18
- import { disposeUnsubscribeListeners as Ue } from "../extensions/Blocks/Unsubscribe/block.js";
19
- import Oe from "./organisms/AutoSaveController.vue.js";
20
- import Ne from "./organisms/base/AuthErrorModal.vue.js";
21
- import _e from "./organisms/base/Toaster.vue.js";
22
- import Ae from "./organisms/extensions/recommendation/FilterSelectionDrawer.vue.js";
23
- import Pe from "./organisms/header/HeaderWrapper.vue.js";
24
- import Be from "./organisms/LoadingWrapper.vue.js";
25
- import xe from "./organisms/save-as-template/SaveAsTemplateDrawer.vue.js";
26
- import He from "./organisms/unsubscribe/UnsubscribeWrapper.vue.js";
27
- import Ve from "./organisms/validation/ValidationErrorDrawer.vue.js";
28
- import { useStripoApi as We } from "../services/stripoApi.js";
29
- import { useConfigStore as Ge } from "../stores/config.js";
30
- import { useDynamicContentStore as $e } from "../stores/dynamic-content.js";
15
+ import { RIBBON_SELECTOR as Re } from "../enums/onboarding.js";
16
+ import { ToasterTypeOptions as Oe } from "../enums/toaster.js";
17
+ import { useRecommendationExtensionStore as z, disposeStrategyPageReturnListeners as Ue } from "../extensions/Blocks/Recommendation/store/recommendation.js";
18
+ import { disposeUnsubscribeListeners as Ne } from "../extensions/Blocks/Unsubscribe/block.js";
19
+ import { disposeDisplayConditionRequest as _e } from "../extensions/DisplayConditions/bridge.js";
20
+ import Ae from "./organisms/AutoSaveController.vue.js";
21
+ import Pe from "./organisms/base/AuthErrorModal.vue.js";
22
+ import xe from "./organisms/base/Toaster.vue.js";
23
+ import Be from "./organisms/extensions/recommendation/FilterSelectionDrawer.vue.js";
24
+ import He from "./organisms/header/HeaderWrapper.vue.js";
25
+ import Ve from "./organisms/LoadingWrapper.vue.js";
26
+ import We from "./organisms/save-as-template/SaveAsTemplateDrawer.vue.js";
27
+ import Ge from "./organisms/unsubscribe/UnsubscribeWrapper.vue.js";
28
+ import $e from "./organisms/validation/ValidationErrorDrawer.vue.js";
29
+ import { useStripoApi as ze } from "../services/stripoApi.js";
30
+ import { useConfigStore as qe } from "../stores/config.js";
31
+ import { useDynamicContentStore as Ke } from "../stores/dynamic-content.js";
31
32
  import { useEditorStore as C } from "../stores/editor.js";
32
- import { usePreviewStore as ze } from "../stores/preview.js";
33
- import { useSaveValidationStore as qe } from "../stores/save-validation.js";
34
- import { useTemplateStore as Ke } from "../stores/template.js";
35
- import { useUnsubscribeStore as je } from "../stores/unsubscribe.js";
33
+ import { useOnboardingStore as je } from "../stores/onboarding.js";
34
+ import { usePreviewStore as Je } from "../stores/preview.js";
35
+ import { useSaveValidationStore as Qe } from "../stores/save-validation.js";
36
+ import { useTemplateStore as Xe } from "../stores/template.js";
37
+ import { useUnsubscribeStore as Ye } from "../stores/unsubscribe.js";
36
38
  import { readTrackFloor as q } from "../utils/linkTrackingIds.js";
37
- const Rt = /* @__PURE__ */ fe({
39
+ const Pt = /* @__PURE__ */ ye({
38
40
  __name: "Guido",
39
41
  props: {
40
42
  config: null,
41
43
  ready: { type: Boolean, default: !0 }
42
44
  },
43
45
  emits: ["dynamic-content:open", "back", "save:start", "save:complete", "on-change", "ready", "onboarding:finished", "test-email:click"],
44
- setup(K, { expose: j, emit: s }) {
45
- const a = K, n = Se(), J = m(
46
+ setup(K, { expose: j, emit: i }) {
47
+ const c = K, r = Ee(), J = a(
46
48
  () => import("./organisms/email-preview/PreviewContainer.vue.js")
47
- ), Q = m(
49
+ ), Q = a(
48
50
  () => import("./organisms/onboarding/OnboardingWrapper.vue.js")
49
- ), X = m(
51
+ ), X = a(
50
52
  () => import("./organisms/extensions/recommendation/AssignStrategyDrawer.vue.js")
51
- ), Y = m(
53
+ ), Y = a(
52
54
  () => import("./organisms/extensions/recommendation/RemoveStrategyModal.vue.js")
53
- ), w = W(), Z = m(
55
+ ), Z = a(
56
+ () => import("./organisms/display-conditions/DisplayConditionsHost.vue.js")
57
+ ), D = W(), ee = a(
54
58
  () => import("./organisms/extensions/recommendation/LegacyStrategyUpdatedModal.vue.js")
55
- ), ee = m(
59
+ ), te = a(
56
60
  () => import("./organisms/unsubscribe/LegacyUnsubscribeConvertedModal.vue.js")
57
- ), g = W(), y = $e(), T = je(), o = Ge();
58
- a.ready && o.init(a.config);
59
- const c = C(), te = ze(), p = u(() => c.hasChanges), { isTestPartner: oe } = Ce(), { isEnabled: re, loadRollout: k } = we(), { showToaster: F } = Fe(), D = De(), I = () => {
61
+ ), g = W(), y = Ke(), w = Ye(), o = qe();
62
+ c.ready && o.init(c.config);
63
+ const d = C(), oe = Je(), p = l(() => d.hasChanges), { isTestPartner: ne } = we(), { isEnabled: re, loadRollout: T } = Te(), { showToaster: k } = Ie(), F = Le(), I = () => {
60
64
  var t;
61
- if (c.isVersionHistoryOpen) {
62
- console.debug("guido:save:silent:blocked", { isVersionHistoryOpen: !0 }), F({
63
- type: Le.Warning,
64
- message: D("email-editor.save-blocked-outside-editor")
65
+ if (d.isVersionHistoryOpen) {
66
+ console.debug("guido:save:silent:blocked", { isVersionHistoryOpen: !0 }), k({
67
+ type: Oe.Warning,
68
+ message: F("email-editor.save-blocked-outside-editor")
65
69
  });
66
70
  return;
67
71
  }
68
- return (t = w.value) == null ? void 0 : t.saveSilent();
69
- }, M = (t) => {
70
- c.loadingStatus = t;
72
+ return (t = D.value) == null ? void 0 : t.saveSilent();
73
+ }, L = (t) => {
74
+ d.loadingStatus = t;
71
75
  };
72
- be(), Ee();
76
+ Se(), De();
73
77
  const b = () => {
74
78
  var t, e;
75
79
  return {
@@ -80,109 +84,111 @@ const Rt = /* @__PURE__ */ fe({
80
84
  savedModulesFolderName: ((t = o.editor) == null ? void 0 : t.savedModulesFolderName) || $.SAVED_MODULES,
81
85
  defaultModulesFolderName: ((e = o.editor) == null ? void 0 : e.defaultModulesFolderName) || $.DEFAULT_MODULES
82
86
  };
83
- }, { initPlugin: L, preloadRuntime: R } = Te(n), { runExclusive: U, beginMount: O, isCurrentMount: v } = ve();
87
+ }, { initPlugin: M, preloadRuntime: R } = ke(r), { runExclusive: O, beginMount: U, isCurrentMount: v } = he();
84
88
  let f = 0;
85
- const { getDefaultTemplate: N } = We(), { cloneTimersOnSave: _, hasTimerBlocks: A } = ke(), ne = u(() => {
89
+ const { getDefaultTemplate: N } = ze(), { cloneTimersOnSave: _, hasTimerBlocks: A } = Fe(), ie = l(() => {
86
90
  var t;
87
91
  return !((t = o.ui) != null && t.showHeader);
88
- }), se = u(() => o.isFeatureEnabled("reusableRecommendationStrategy")), ie = u(
92
+ }), se = l(() => o.isFeatureEnabled("reusableRecommendationStrategy")), ae = l(() => o.externalDisplayConditions), ce = l(
89
93
  () => o.isFeatureEnabled("legacyUnsubscribeConversion")
90
- ), ae = u(
94
+ ), de = l(
91
95
  () => !!z().recommendationConfigs.strategyId
92
96
  );
93
- he({
97
+ Ce({
94
98
  onBack: () => {
95
- console.debug("guido:back"), s("back");
99
+ console.debug("guido:back"), i("back");
96
100
  },
97
101
  onSaveStart: () => {
98
- console.debug("guido:save:start"), s("save:start");
102
+ console.debug("guido:save:start"), i("save:start");
99
103
  },
100
104
  onSaveComplete: (t) => {
101
105
  const e = { ...t, metadata: b() };
102
- console.debug("guido:save:complete", e), s("save:complete", e);
106
+ console.debug("guido:save:complete", e), i("save:complete", e);
103
107
  },
104
108
  onTestEmailClick: () => {
105
- console.debug("guido:test-email:click"), s("test-email:click");
109
+ console.debug("guido:test-email:click"), i("test-email:click");
106
110
  }
107
111
  });
108
112
  const P = (t) => {
109
113
  console.debug("dynamic-content:close", t), y.setSelectedDynamicContent(t), document.dispatchEvent(new CustomEvent("dynamic-content:close", { detail: t }));
110
- }, B = () => {
114
+ }, x = () => {
111
115
  console.debug("dynamic-content:close", "Without Data"), document.dispatchEvent(new CustomEvent("dynamic-content:close", { detail: { text: "", value: "" } }));
112
116
  };
113
117
  G(() => p.value, () => {
114
- s("on-change", p.value);
118
+ i("on-change", p.value);
115
119
  });
116
120
  const S = (t) => {
117
- const e = t, { attribute: i, position: l } = e.detail;
118
- console.debug("dynamic-content:open", e.detail), s("dynamic-content:open", i, l);
121
+ const e = t, { attribute: s, position: u } = e.detail;
122
+ console.debug("dynamic-content:open", e.detail), i("dynamic-content:open", s, u);
119
123
  };
120
- let d = null;
124
+ let m = null;
121
125
  const h = () => {
122
126
  var e;
123
- const t = document.querySelector(Me);
127
+ const t = document.querySelector(Re);
124
128
  (e = g.value) == null || e.style.setProperty("--ribbon-offset", `${(t == null ? void 0 : t.offsetHeight) ?? 0}px`);
125
129
  }, E = async () => {
126
130
  var t;
127
- n.mark("host_ready");
131
+ r.mark("host_ready");
128
132
  try {
129
- o.initialized || o.init(a.config), c.templateId = o.templateId, n.setContext({
133
+ o.initialized || o.init(c.config), d.templateId = o.templateId, r.setContext({
130
134
  partnerName: o.partnerName,
131
135
  productType: o.productType,
132
136
  templateId: o.templateId,
133
137
  variationId: o.variationId
134
138
  });
135
- const e = o.template, i = (e == null ? void 0 : e.html) || "", l = (e == null ? void 0 : e.css) || "", x = (e == null ? void 0 : e.preselectedDynamicContent) || [];
136
- T.selectedUnsubscribePages = (e == null ? void 0 : e.selectedUnsubscribePages) || [];
137
- const ce = ((t = e == null ? void 0 : e.migration) == null ? void 0 : t.recommendationConfigs) ?? {}, H = o.isFeatureEnabled("linkTrackingIds"), de = {
139
+ const e = o.template, s = (e == null ? void 0 : e.html) || "", u = (e == null ? void 0 : e.css) || "", B = (e == null ? void 0 : e.preselectedDynamicContent) || [];
140
+ w.selectedUnsubscribePages = (e == null ? void 0 : e.selectedUnsubscribePages) || [];
141
+ const me = ((t = e == null ? void 0 : e.migration) == null ? void 0 : t.recommendationConfigs) ?? {}, H = o.isFeatureEnabled("linkTrackingIds"), le = {
138
142
  partnerName: o.partnerName,
139
143
  campaignUrls: e == null ? void 0 : e.recommendationCampaignUrls,
140
144
  rrsEnabled: o.isFeatureEnabled("reusableRecommendationStrategy")
141
- }, me = {
145
+ }, ue = {
142
146
  itemsPriceFormatting: o.isFeatureEnabled("itemsPriceFormatting")
143
- }, V = (pe) => n.timed(
147
+ }, V = (ge) => r.timed(
144
148
  "migration",
145
- () => Ie(pe, ce, de, me)
149
+ () => Me(ge, me, le, ue)
146
150
  );
147
- let r = {
148
- html: i && await V(i),
149
- css: l
151
+ let n = {
152
+ html: s && await V(s),
153
+ css: u
150
154
  };
151
- r.html || (r = await n.timed("default_template", () => N()), r.html = await V(r.html));
152
- const le = H ? q(r.html, (e == null ? void 0 : e.trackIdCounter) || 0) : 0;
153
- A(r.html) && (r.html = await n.timed("timer_clone", () => _(r.html))), H && (c.trackIdSessionFloor = Math.max(le, q(r.html)));
154
- const ue = {
155
- preselectedDynamicContentList: x,
155
+ n.html || (n = await r.timed("default_template", () => N()), n.html = await V(n.html));
156
+ const pe = H ? q(n.html, (e == null ? void 0 : e.trackIdCounter) || 0) : 0;
157
+ A(n.html) && (n.html = await r.timed("timer_clone", () => _(n.html))), H && (d.trackIdSessionFloor = Math.max(pe, q(n.html)));
158
+ const fe = {
159
+ preselectedDynamicContentList: B,
156
160
  onReady: () => {
157
- console.debug("guido:ready"), s("ready");
161
+ console.debug("guido:ready"), i("ready");
158
162
  }
159
163
  };
160
- f = O(), await L(r, b(), ue, r.html !== i), y.selectedDynamicContentList = x;
164
+ f = U(), await M(n, b(), fe, n.html !== s), y.selectedDynamicContentList = B;
161
165
  } catch (e) {
162
- console.error("Failed to initialize Stripo editor:", e), n.markFailed();
166
+ console.error("Failed to initialize Stripo editor:", e), r.markFailed();
163
167
  }
164
168
  };
165
- return ge(async () => {
169
+ return be(async () => {
166
170
  var e;
167
- console.debug("Guido says happy coding 🎉"), console.debug("🚗 Ka-Chow"), z().$reset(), C().$reset(), Ke().$reset(), qe().$reset(), k(), h();
171
+ console.debug("Guido says happy coding 🎉"), console.debug("🚗 Ka-Chow"), z().$reset(), C().$reset(), Xe().$reset(), Qe().$reset(), je().resetOnboarding("recommendationLegacyStrategyOnboarding"), T(), h();
168
172
  const t = (e = g.value) == null ? void 0 : e.parentElement;
169
- if (t && (d = new ResizeObserver(h), d.observe(t)), R(), a.ready)
173
+ if (t && (m = new ResizeObserver(h), m.observe(t)), R(), c.ready)
170
174
  await E();
171
175
  else {
172
- const i = G(() => a.ready, (l) => {
173
- l && (i(), E());
176
+ const s = G(() => c.ready, (u) => {
177
+ u && (s(), E());
174
178
  });
175
179
  }
176
180
  document.addEventListener("dynamic-content:open", S);
177
- }), ye(() => {
178
- if (Ue(), Re(), n.dispose(), d == null || d.disconnect(), document.removeEventListener("dynamic-content:open", S), v(f))
181
+ }), ve(() => {
182
+ if (Ne(), Ue(), r.dispose(), m == null || m.disconnect(), document.removeEventListener("dynamic-content:open", S), v(f)) {
183
+ _e();
179
184
  try {
180
185
  const t = C();
181
186
  t.isStripoInitialized = !1, t.isAccessibilityTestingOpen = !1, t.imagesHidden = !1, t.colorVisionDeficiency = "";
182
187
  } catch (t) {
183
188
  console.debug("Failed to close the editor readiness gate on unmount", t);
184
189
  }
185
- U(async () => {
190
+ }
191
+ O(async () => {
186
192
  if (v(f))
187
193
  try {
188
194
  window.UIEditor.removeEditor();
@@ -193,14 +199,14 @@ const Rt = /* @__PURE__ */ fe({
193
199
  }), j({
194
200
  dynamicContent: {
195
201
  insert: P,
196
- close: B
202
+ close: x
197
203
  },
198
204
  hasChanges: p,
199
205
  saveSilent: I,
200
- setLoading: M
201
- }), { __sfc: !0, openMetrics: n, PreviewContainer: J, OnboardingWrapper: Q, AssignStrategyDrawer: X, RemoveStrategyModal: Y, autoSaveControllerRef: w, LegacyStrategyUpdatedModal: Z, LegacyUnsubscribeConvertedModal: ee, wrapperRef: g, dynamicContentStore: y, unsubscribeStore: T, props: a, configStore: o, editorStore: c, previewStore: te, hasChanges: p, isTestPartner: oe, isSaveValidationEnabled: re, loadRollout: k, showToaster: F, trans: D, saveSilent: I, setLoading: M, emit: s, buildMetadata: b, initPlugin: L, preloadRuntime: R, runExclusive: U, beginMount: O, isCurrentMount: v, mountGeneration: f, getDefaultTemplate: N, cloneTimersOnSave: _, hasTimerBlocks: A, noHeader: ne, isRrsEnabled: se, isLegacyUnsubscribeConversionEnabled: ie, hasAssignedStrategy: ae, insertDynamicContent: P, closeDynamicContent: B, handleDynamicContentOpen: S, ribbonObserver: d, updateRibbonOffset: h, startEditor: E, AutoSaveController: Oe, AuthErrorModal: Ne, Toaster: _e, FilterSelectionDrawer: Ae, HeaderWrapper: Pe, LoadingWrapper: Be, SaveAsTemplateDrawer: xe, UnsubscribeWrapper: He, ValidationErrorDrawer: Ve };
206
+ setLoading: L
207
+ }), { __sfc: !0, openMetrics: r, PreviewContainer: J, OnboardingWrapper: Q, AssignStrategyDrawer: X, RemoveStrategyModal: Y, DisplayConditionsHost: Z, autoSaveControllerRef: D, LegacyStrategyUpdatedModal: ee, LegacyUnsubscribeConvertedModal: te, wrapperRef: g, dynamicContentStore: y, unsubscribeStore: w, props: c, configStore: o, editorStore: d, previewStore: oe, hasChanges: p, isTestPartner: ne, isSaveValidationEnabled: re, loadRollout: T, showToaster: k, trans: F, saveSilent: I, setLoading: L, emit: i, buildMetadata: b, initPlugin: M, preloadRuntime: R, runExclusive: O, beginMount: U, isCurrentMount: v, mountGeneration: f, getDefaultTemplate: N, cloneTimersOnSave: _, hasTimerBlocks: A, noHeader: ie, isRrsEnabled: se, isExternalDisplayConditionsEnabled: ae, isLegacyUnsubscribeConversionEnabled: ce, hasAssignedStrategy: de, insertDynamicContent: P, closeDynamicContent: x, handleDynamicContentOpen: S, ribbonObserver: m, updateRibbonOffset: h, startEditor: E, AutoSaveController: Ae, AuthErrorModal: Pe, Toaster: xe, FilterSelectionDrawer: Be, HeaderWrapper: He, LoadingWrapper: Ve, SaveAsTemplateDrawer: We, UnsubscribeWrapper: Ge, ValidationErrorDrawer: $e };
202
208
  }
203
209
  });
204
210
  export {
205
- Rt as default
211
+ Pt as default
206
212
  };
@@ -0,0 +1,17 @@
1
+ import r from "./CodeEditorField.vue2.js";
2
+ import s from "../../../_virtual/_plugin-vue2_normalizer.js";
3
+ var i = function() {
4
+ var e = this, t = e._self._c, o = e._self._setupProxy;
5
+ return t("div", { staticClass: "guido-code-editor-field", attrs: { id: e.id } }, [t("p", { staticClass: "guido-code-editor-field__label mt-0 mb-2 f-s-1 f-w-400 l-h-1 t-c-1" }, [e._v(" " + e._s(e.label) + " ")]), t(o.InCodeSnippet, { attrs: { code: e.value, disable: e.disabled, "focus-editor": !1, invalid: !!e.error, "invalid-message": e.error, options: o.options, size: { height: e.error ? 196 : 216 }, "syntax-check": !1 }, on: { input: o.onInput, ready: o.onReady } })], 1);
6
+ }, a = [], n = /* @__PURE__ */ s(
7
+ r,
8
+ i,
9
+ a,
10
+ !1,
11
+ null,
12
+ null
13
+ );
14
+ const c = n.exports;
15
+ export {
16
+ c as default
17
+ };
@@ -0,0 +1,41 @@
1
+ import { defineComponent as f, computed as m, nextTick as _ } from "vue";
2
+ import { InCodeSnippet as I } from "@useinsider/design-system-vue";
3
+ const S = /* @__PURE__ */ f({
4
+ __name: "CodeEditorField",
5
+ props: {
6
+ id: null,
7
+ label: null,
8
+ value: null,
9
+ placeholder: { default: "" },
10
+ error: { default: "" },
11
+ disabled: { type: Boolean, default: !1 }
12
+ },
13
+ emits: ["input"],
14
+ setup(r, { expose: a, emit: n }) {
15
+ const l = r, u = 700;
16
+ let t = null, e = null;
17
+ const d = m(() => ({
18
+ mode: "liquid",
19
+ lint: !1,
20
+ foldGutter: !1,
21
+ placeholder: l.placeholder
22
+ })), p = (o) => {
23
+ t = o;
24
+ }, s = (o) => {
25
+ n("input", o), e == null || e();
26
+ }, i = () => new Promise((o) => {
27
+ if (!t || t.state.doc.toString() === l.value) {
28
+ o(l.value);
29
+ return;
30
+ }
31
+ const c = setTimeout(() => e == null ? void 0 : e(), u);
32
+ e = () => {
33
+ clearTimeout(c), e = null, _(() => o(l.value));
34
+ };
35
+ });
36
+ return a({ read: i }), { __sfc: !0, props: l, emit: n, SANITIZED_INPUT_WAIT_MS: u, view: t, settleRead: e, options: d, onReady: p, onInput: s, read: i, InCodeSnippet: I };
37
+ }
38
+ });
39
+ export {
40
+ S as default
41
+ };
@@ -0,0 +1,30 @@
1
+ import a from "./DisplayConditionCreateDrawer.vue2.js";
2
+ /* empty css */
3
+ import r from "../../../_virtual/_plugin-vue2_normalizer.js";
4
+ var n = function() {
5
+ var i = this, t = i._self._c, e = i._self._setupProxy;
6
+ return t(e.WpDrawer, { attrs: { id: "guido__display-condition-create-drawer", "description-status": "", "class-name": "guido-display-condition-create-drawer", size: "large", "close-on-outside-click": !1, "description-text": e.descriptionText, "footer-button-group-options": e.footerButtonGroupOptions, status: e.store.isCreateOpen, "title-text": e.trans(`${e.KEY}.create-title`) }, on: { cancelOrBackButtonEvent: e.close, onCloseEvent: e.close, primaryButtonEvent: function(o) {
7
+ return e.submit("inline");
8
+ }, secondaryButtonEvent: function(o) {
9
+ return e.submit("save");
10
+ } } }, [t("div", { staticClass: "guido-display-condition-create" }, [t(e.InBasicTextInput, { staticClass: "mb-4 w-1", attrs: { id: "guido__display-condition-name-input", name: "displayConditionName", "character-counter-status": !1, "disabled-status": e.isSaving, "label-text": e.trans(`${e.KEY}.condition-name`), "max-character-length": e.DISPLAY_CONDITION_LIMITS.NAME_MAX, "placeholder-text": e.trans(`${e.KEY}.condition-name-placeholder`), "state-message": e.errors.name || "", states: e.errors.name ? "error" : "default", "tooltip-status": !1, value: e.draft.name }, on: { input: function(o) {
11
+ return e.updateField("name", o);
12
+ } } }), t(e.InBasicTextInput, { staticClass: "mb-4 w-1", attrs: { id: "guido__display-condition-description-input", name: "displayConditionDescription", "character-counter-status": !1, "disabled-status": e.isSaving, "label-text": e.descriptionLabel, "max-character-length": e.DISPLAY_CONDITION_LIMITS.DESCRIPTION_MAX, "placeholder-text": e.trans(`${e.KEY}.condition-description-placeholder`), "state-message": e.errors.description || "", states: e.errors.description ? "error" : "default", "tooltip-status": !1, value: e.draft.description }, on: { input: function(o) {
13
+ return e.updateField("description", o);
14
+ } } }), t("div", { staticClass: "guido-display-condition-create__separator t-c-3" }), t("p", { staticClass: "guido-display-condition-create__method-title mt-0 mb-4 f-s-1 f-w-600 l-h-6 l-s-5 t-t-u t-c-55" }, [i._v(" " + i._s(e.trans(`${e.KEY}.select-method`)) + " ")]), t("div", { staticClass: "guido-display-condition-create__methods d-f mb-4" }, [t(e.InRadioButton, { attrs: { id: "guido__display-condition-method-logic-builder", disable: "", disabled: "", name: "displayConditionMethod", selected: "codeOnly", value: "logicBuilder", label: e.trans(`${e.KEY}.logic-builder`) } }), t(e.InRadioButton, { attrs: { id: "guido__display-condition-method-code-only", name: "displayConditionMethod", selected: "codeOnly", value: "codeOnly", label: e.trans(`${e.KEY}.code-only`) } })], 1), t(e.CodeEditorField, { ref: "codeBeforeRef", staticClass: "mb-3", attrs: { id: "guido__display-condition-code-before", disabled: e.isSaving, error: e.errors.codeBefore, label: e.trans(`${e.KEY}.code-before`), placeholder: e.trans(`${e.KEY}.code-placeholder`), value: e.draft.codeBefore }, on: { input: function(o) {
15
+ return e.updateField("codeBefore", o);
16
+ } } }), t(e.CodeEditorField, { ref: "codeAfterRef", attrs: { id: "guido__display-condition-code-after", disabled: e.isSaving, error: e.errors.codeAfter, label: e.trans(`${e.KEY}.code-after`), placeholder: e.trans(`${e.KEY}.code-placeholder`), value: e.draft.codeAfter }, on: { input: function(o) {
17
+ return e.updateField("codeAfter", o);
18
+ } } })], 1)]);
19
+ }, s = [], d = /* @__PURE__ */ r(
20
+ a,
21
+ n,
22
+ s,
23
+ !1,
24
+ null,
25
+ "929822bc"
26
+ );
27
+ const f = d.exports;
28
+ export {
29
+ f as default
30
+ };
@@ -0,0 +1,81 @@
1
+ import { defineComponent as w, reactive as L, ref as c, computed as u, watch as N } from "vue";
2
+ import R from "../../wrappers/WpDrawer.vue.js";
3
+ import { useDisplayConditions as k, DISPLAY_CONDITIONS_TRANS_KEY as i } from "../../../composables/useDisplayConditions.js";
4
+ import { useTranslations as Y } from "../../../composables/useTranslations.js";
5
+ import { DISPLAY_CONDITION_LIMITS as j } from "../../../enums/display-condition.js";
6
+ import { useDisplayConditionStore as E } from "../../../stores/display-condition.js";
7
+ import { InRadioButton as P, InBasicTextInput as F } from "@useinsider/design-system-vue";
8
+ import G from "./CodeEditorField.vue.js";
9
+ const Z = /* @__PURE__ */ w({
10
+ __name: "DisplayConditionCreateDrawer",
11
+ setup(K) {
12
+ const n = Y(), p = E(), {
13
+ validate: v,
14
+ notifyInvalid: f,
15
+ createInline: y,
16
+ createAndSave: _,
17
+ cancel: b,
18
+ describeWithAcademyLink: B
19
+ } = k(), m = () => ({ name: "", description: "", codeBefore: "", codeAfter: "" }), e = L(m()), o = c({}), r = c(!1), l = c(!1), s = u(() => r.value || l.value), g = c(), I = c();
20
+ let d = 0;
21
+ N(() => p.isCreateOpen, (a) => {
22
+ if (d += 1, !a)
23
+ return;
24
+ const { editing: t } = p;
25
+ Object.assign(e, t ? {
26
+ name: t.name,
27
+ description: t.description,
28
+ codeBefore: t.beforeScript,
29
+ codeAfter: t.afterScript
30
+ } : m()), o.value = {}, r.value = !1;
31
+ }, { immediate: !0 });
32
+ const C = u(() => B("create-description")), D = u(() => ({
33
+ cancelOrBackButton: {
34
+ styling: "ghost",
35
+ type: "secondary",
36
+ labelText: n(`${i}.cancel`),
37
+ disabledStatus: s.value
38
+ },
39
+ secondaryButton: {
40
+ styling: "solid",
41
+ type: "subtle-primary",
42
+ labelText: n(`${i}.create-and-save`),
43
+ loadingStatus: r.value
44
+ },
45
+ primaryButton: {
46
+ styling: "solid",
47
+ type: "primary",
48
+ labelText: n(`${i}.create`),
49
+ disabledStatus: s.value
50
+ }
51
+ })), O = (a, t) => {
52
+ t !== e[a] && (e[a] = t, o.value[a] && (o.value = { ...o.value, [a]: void 0 }));
53
+ }, T = u(() => `${n(`${i}.condition-description`)} <span class="guido-display-condition-create__optional t-c-53">(${n(`${i}.optional`)})</span>`);
54
+ return { __sfc: !0, trans: n, store: p, validate: v, notifyInvalid: f, createInline: y, createAndSave: _, cancel: b, describeWithAcademyLink: B, emptyDraft: m, draft: e, errors: o, isSaving: r, isReadingCode: l, isBusy: s, codeBeforeRef: g, codeAfterRef: I, openGeneration: d, descriptionText: C, footerButtonGroupOptions: D, updateField: O, descriptionLabel: T, submit: async (a) => {
55
+ var S, A;
56
+ if (s.value)
57
+ return;
58
+ const t = d;
59
+ l.value = !0;
60
+ const [$, x] = await Promise.all([(S = g.value) == null ? void 0 : S.read(), (A = I.value) == null ? void 0 : A.read()]);
61
+ if (l.value = !1, t !== d)
62
+ return;
63
+ if (e.codeBefore = $ ?? e.codeBefore, e.codeAfter = x ?? e.codeAfter, o.value = v(e), Object.keys(o.value).length) {
64
+ f();
65
+ return;
66
+ }
67
+ if (a === "inline") {
68
+ y({ ...e });
69
+ return;
70
+ }
71
+ r.value = !0;
72
+ const h = await _({ ...e });
73
+ r.value = !1, o.value = h ?? {}, Object.keys(o.value).length && f();
74
+ }, close: () => {
75
+ s.value || b();
76
+ }, WpDrawer: R, KEY: i, DISPLAY_CONDITION_LIMITS: j, InBasicTextInput: F, InRadioButton: P, CodeEditorField: G };
77
+ }
78
+ });
79
+ export {
80
+ Z as default
81
+ };
@@ -0,0 +1,17 @@
1
+ import n from "./DisplayConditionListState.vue2.js";
2
+ import o from "../../../_virtual/_plugin-vue2_normalizer.js";
3
+ var s = function() {
4
+ var e = this, i = e._self._c, t = e._self._setupProxy;
5
+ return i(t.InNoData, { staticClass: "d-f f-d-c j-c-c f-g-1", attrs: { id: t.view.id, "button-status": !!t.view.buttonText, "button-text": t.view.buttonText, description: t.view.description, icon: t.view.icon, title: t.view.title }, on: { click: t.onClick } });
6
+ }, r = [], c = /* @__PURE__ */ o(
7
+ n,
8
+ s,
9
+ r,
10
+ !1,
11
+ null,
12
+ null
13
+ );
14
+ const f = c.exports;
15
+ export {
16
+ f as default
17
+ };
@@ -0,0 +1,45 @@
1
+ import { defineComponent as s, computed as a } from "vue";
2
+ import { DISPLAY_CONDITIONS_TRANS_KEY as e } from "../../../composables/useDisplayConditions.js";
3
+ import { useTranslations as c } from "../../../composables/useTranslations.js";
4
+ import { InNoData as p } from "@useinsider/design-system-vue";
5
+ const y = /* @__PURE__ */ s({
6
+ __name: "DisplayConditionListState",
7
+ props: {
8
+ state: null
9
+ },
10
+ emits: ["retry", "create"],
11
+ setup(i, { emit: r }) {
12
+ const o = i, t = c(), n = a(() => {
13
+ switch (o.state) {
14
+ case "error":
15
+ return {
16
+ id: "guido__display-condition-error",
17
+ icon: "no-data",
18
+ title: t(`${e}.error-load-title`),
19
+ description: t(`${e}.error-load`),
20
+ buttonText: t(`${e}.retry`)
21
+ };
22
+ case "empty":
23
+ return {
24
+ id: "guido__display-condition-empty",
25
+ icon: "no-personalization",
26
+ title: t(`${e}.empty-title`),
27
+ description: t(`${e}.empty-description`),
28
+ buttonText: t(`${e}.create-new`)
29
+ };
30
+ default:
31
+ return {
32
+ id: "guido__display-condition-no-result",
33
+ icon: "no-data",
34
+ title: t(`${e}.no-result`)
35
+ };
36
+ }
37
+ });
38
+ return { __sfc: !0, props: o, emit: r, trans: t, view: n, onClick: () => {
39
+ o.state === "error" ? r("retry") : o.state === "empty" && r("create");
40
+ }, InNoData: p };
41
+ }
42
+ });
43
+ export {
44
+ y as default
45
+ };
@@ -0,0 +1,36 @@
1
+ import o from "./DisplayConditionSelectDrawer.vue2.js";
2
+ /* empty css */
3
+ import d from "../../../_virtual/_plugin-vue2_normalizer.js";
4
+ var a = function() {
5
+ var s = this, e = s._self._c, t = s._self._setupProxy;
6
+ return e("div", { staticClass: "guido-display-condition-select-root" }, [e(t.WpDrawer, { attrs: { id: "guido__display-condition-select-drawer", "description-status": "", "class-name": "guido-display-condition-select-drawer", size: "large", "description-text": t.descriptionText, "footer-button-group-options": t.footerButtonGroupOptions, status: t.store.isSelectOpen, "title-text": t.trans(`${t.KEY}.select-title`) }, on: { cancelOrBackButtonEvent: t.cancel, onCloseEvent: t.cancel } }, [e("div", { staticClass: "guido-display-condition-select d-f f-d-c f-g-1" }, [t.store.listStatus === "loaded" && t.store.list.length ? e(t.InBasicTextInput, { staticClass: "mb-4 w-1", attrs: { id: "guido__display-condition-search-input", name: "displayConditionSearch", "character-counter-status": !1, "label-status": !1, "placeholder-text": t.trans(`${t.KEY}.search`), "tooltip-status": !1, value: t.search }, on: { input: function(i) {
7
+ t.search = i;
8
+ } } }) : s._e(), t.store.listStatus === "loading" || t.store.listStatus === "idle" ? e("div", { staticClass: "guido-display-condition-select__list", attrs: { "data-testid": "display-condition-loading" } }, s._l(t.SKELETON_HEIGHTS, function(i, n) {
9
+ return e(t.InSkeleton, { key: n, attrs: { sizing: { width: 856, height: i } } });
10
+ }), 1) : t.listState ? e(t.DisplayConditionListState, { attrs: { state: t.listState }, on: { create: function(i) {
11
+ return t.store.openCreate();
12
+ }, retry: t.loadList } }) : e("ul", { staticClass: "guido-display-condition-select__list" }, s._l(t.filteredList, function(i) {
13
+ return e("li", { key: i.id, staticClass: "guido-display-condition-card bor-w-1 bor-s-s bor-c-50 bor-r-1 b-c-4", attrs: { "data-condition-id": i.id } }, [e("div", { staticClass: "guido-display-condition-card__header" }, [e("div", { staticClass: "guido-display-condition-card__text" }, [e("p", { staticClass: "guido-display-condition-card__name m-0 f-s-13 f-w-600 l-h-2 t-c-55" }, [s._v(" " + s._s(i.name) + " ")]), i.description ? e("p", { staticClass: "guido-display-condition-card__description mt-1 mb-0 f-s-1 l-h-1 t-c-53" }, [s._v(" " + s._s(i.description) + " ")]) : s._e()]), e("div", { staticClass: "guido-display-condition-card__actions" }, [e("div", { staticClass: "guido-display-condition-card__split" }, [e(t.InButtonV2, { attrs: { id: `guido__display-condition-select-${i.id}`, type: "subtle-primary", "label-text": t.trans(`${t.KEY}.select`) }, on: { click: function(n) {
14
+ return t.select(i);
15
+ } } }), e(t.InButtonV2, { attrs: { id: `guido__display-condition-menu-${i.id}`, "left-icon": "filled-dropdown-down", type: "subtle-primary", "label-text-status": !1 }, on: { click: function(n) {
16
+ return t.toggleMenu(i);
17
+ } } }), e(t.InDropdownMenu, { staticClass: "guido-display-condition-card__menu", attrs: { id: `guido__display-condition-menu-list-${i.id}`, "box-width": "basedOnLongestItem", "static-position": "bottom right", "dynamic-position": !1, options: t.menuOptions(i), "select-all-option-status": !1, status: t.menuId === i.id }, on: { clickOutside: function(n) {
18
+ return t.closeMenu(i);
19
+ }, optionClick: function(n) {
20
+ return t.requestDelete(i);
21
+ } } })], 1), e("span", { staticClass: "guido-display-condition-card__divider b-c-6" }), e(t.InButtonV2, { attrs: { id: `guido__display-condition-expand-${i.id}`, styling: "text", type: "secondary", "label-text-status": !1, "left-icon": t.expandedId === i.id ? "filled-dropdown-up" : "filled-dropdown-down", "selected-status": t.expandedId === i.id, "tooltip-options": t.expandTooltip(i), "tooltip-text": t.trans(`${t.KEY}.preview`) }, on: { click: function(n) {
22
+ return t.toggleExpanded(i);
23
+ } } })], 1)]), t.expandedId === i.id ? e("pre", { staticClass: "guido-display-condition-card__code bor-w-1 bor-s-s bor-c-50 bor-r-1 b-c-4 t-c-35 f-s-2 l-h-2" }, [s._v(s._s(t.codeOf(i)))]) : s._e()]);
24
+ }), 0)], 1)]), t.store.pendingDelete ? e("div", { staticClass: "guido-display-condition-select__delete-modal" }, [e(t.WpModal, { attrs: { id: "guido__display-condition-delete-modal", size: "X-small", state: "danger", "close-on-outside-click": !1, "footer-button-options": t.deleteModalButtons, title: t.trans(`${t.KEY}.delete-confirm-title`) }, on: { close: t.closeDeleteModal, "primary-action": t.confirmDelete } }, [e("p", { staticClass: "guido-display-condition-select__delete-text m-0 t-c-55" }, [s._v(" " + s._s(t.trans(`${t.KEY}.delete-confirm-description`, { name: t.store.pendingDelete.name })) + " ")])])], 1) : s._e()], 1);
25
+ }, l = [], c = /* @__PURE__ */ d(
26
+ o,
27
+ a,
28
+ l,
29
+ !1,
30
+ null,
31
+ "0d740001"
32
+ );
33
+ const f = c.exports;
34
+ export {
35
+ f as default
36
+ };