@useinsider/guido 3.20.0-beta.7b31fec → 3.20.0-beta.e801a3b
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -0
- package/dist/@types/config/schemas.js +102 -87
- package/dist/components/Guido.vue.js +4 -4
- package/dist/components/Guido.vue2.js +100 -86
- package/dist/components/organisms/AutoSaveController.vue2.js +9 -8
- package/dist/components/organisms/base/AuthErrorModal.vue.js +18 -0
- package/dist/components/organisms/base/AuthErrorModal.vue2.js +42 -0
- package/dist/components/organisms/header/EditorActions.vue.js +5 -5
- package/dist/components/organisms/header/EditorActions.vue2.js +90 -57
- package/dist/components/organisms/header/LeftSlot.vue.js +5 -5
- package/dist/components/organisms/header/LeftSlot.vue2.js +16 -12
- package/dist/components/organisms/validation/ValidationErrorDrawer.vue.js +20 -0
- package/dist/components/organisms/validation/ValidationErrorDrawer.vue2.js +49 -0
- package/dist/components/wrappers/WpDrawer.vue.js +9 -7
- package/dist/components/wrappers/WpDrawer.vue2.js +1 -1
- package/dist/components/wrappers/WpModal.vue.js +1 -1
- package/dist/components/wrappers/WpModal.vue2.js +4 -3
- package/dist/composables/useActionsApi.js +52 -47
- package/dist/composables/useAuthError.js +52 -0
- package/dist/composables/useAutoSave.js +11 -11
- package/dist/composables/useCodeEditorApi.js +23 -9
- package/dist/composables/useCortexBlueprintBridge.js +122 -54
- package/dist/composables/useEmailTemplateApplier.js +111 -50
- package/dist/composables/useHtmlCompiler.js +37 -26
- package/dist/composables/useHtmlValidator.js +2 -0
- package/dist/composables/useHttp.js +64 -54
- package/dist/composables/useLegacyStrategyConversion.js +23 -19
- package/dist/composables/useSave.js +90 -45
- package/dist/composables/useSaveValidation.js +282 -0
- package/dist/composables/useSaveValidationRollout.js +9 -0
- package/dist/composables/useStripo.js +24 -20
- package/dist/composables/useToaster.js +17 -15
- package/dist/composables/useTranslations.js +3 -2
- package/dist/composables/useVersionHistoryApi.js +33 -24
- package/dist/composables/validators/useCouponBlockValidator.js +24 -21
- package/dist/composables/validators/useLiquidValidator.js +15 -15
- package/dist/composables/validators/useUnsubscribeBlockValidator.js +34 -27
- package/dist/config/migrator/index.js +14 -13
- package/dist/config/migrator/itemsBlockMigrator.js +236 -248
- package/dist/config/migrator/recommendationMigrator.js +28 -21
- package/dist/config/migrator/recommendationPartnerMigrator.js +56 -0
- package/dist/enums/extensions/recommendationBlock.js +30 -29
- package/dist/enums/save-validation.js +4 -0
- package/dist/extensions/Blocks/Items/constants/cardLayout.js +20 -0
- package/dist/extensions/Blocks/Items/controls/name/trimming.js +18 -17
- package/dist/extensions/Blocks/Items/controls/settingsControl.js +114 -105
- package/dist/extensions/Blocks/Items/enums/productEnums.js +14 -9
- package/dist/extensions/Blocks/Items/layouts/horizontal.html.js +11 -9
- package/dist/extensions/Blocks/Items/template.js +219 -204
- package/dist/extensions/Blocks/Recommendation/block.js +15 -14
- package/dist/extensions/Blocks/Recommendation/controls/cardComposition/index.js +103 -91
- package/dist/extensions/Blocks/Recommendation/controls/main/index.js +45 -38
- package/dist/extensions/Blocks/Recommendation/controls/main/strategy.js +72 -49
- package/dist/extensions/Blocks/Recommendation/store/recommendation.js +30 -29
- package/dist/extensions/Blocks/Recommendation/utils/captureStyleTemplates.js +72 -70
- package/dist/extensions/Blocks/Recommendation/utils/compositionKeys.js +69 -60
- package/dist/extensions/Blocks/Recommendation/utils/partnerCustomizations.js +3 -1
- package/dist/extensions/Blocks/Recommendation/utils/partnerScope.js +25 -0
- package/dist/guido.css +1 -1
- package/dist/src/@types/config/schemas.d.ts +20 -0
- package/dist/src/@types/save-validation.d.ts +19 -0
- package/dist/src/components/Guido.vue.d.ts +17 -1
- package/dist/src/components/organisms/base/AuthErrorModal.vue.d.ts +2 -0
- package/dist/src/components/organisms/header/EditorActions.vue.d.ts +17 -1
- package/dist/src/components/organisms/header/HeaderWrapper.vue.d.ts +17 -1
- package/dist/src/components/organisms/header/RightSlot.vue.d.ts +17 -1
- package/dist/src/components/organisms/validation/ValidationErrorDrawer.vue.d.ts +2 -0
- package/dist/src/components/wrappers/WpDrawer.vue.d.ts +4 -3
- package/dist/src/components/wrappers/WpModal.vue.d.ts +5 -1
- package/dist/src/composables/useAuthError.d.ts +12 -0
- package/dist/src/composables/useConfig.d.ts +4 -0
- package/dist/src/composables/useCortexBlueprintBridge.d.ts +2 -3
- package/dist/src/composables/useEmailTemplateApplier.d.ts +18 -5
- package/dist/src/composables/useGuidoActions.d.ts +2 -0
- package/dist/src/composables/useHtmlValidator.d.ts +21 -0
- package/dist/src/composables/useHttp.d.ts +2 -0
- package/dist/src/composables/useSave.d.ts +6 -1
- package/dist/src/composables/useSaveValidation.d.ts +6 -0
- package/dist/src/composables/useSaveValidationRollout.d.ts +3 -0
- package/dist/src/composables/validators/useCouponBlockValidator.d.ts +3 -0
- package/dist/src/composables/validators/useUnsubscribeBlockValidator.d.ts +10 -0
- package/dist/src/config/migrator/index.d.ts +2 -1
- package/dist/src/config/migrator/recommendationPartnerMigrator.d.ts +19 -0
- package/dist/src/enums/extensions/recommendationBlock.d.ts +1 -1
- package/dist/src/enums/save-validation.d.ts +27 -0
- package/dist/src/extensions/Blocks/Items/constants/cardLayout.d.ts +44 -0
- package/dist/src/extensions/Blocks/Items/enums/productEnums.d.ts +3 -0
- package/dist/src/extensions/Blocks/Items/template.d.ts +19 -0
- package/dist/src/extensions/Blocks/Recommendation/controls/cardComposition/index.d.ts +3 -0
- package/dist/src/extensions/Blocks/Recommendation/types/nodeConfig.d.ts +6 -0
- package/dist/src/extensions/Blocks/Recommendation/utils/compositionKeys.d.ts +4 -0
- package/dist/src/extensions/Blocks/Recommendation/utils/partnerScope.d.ts +33 -0
- package/dist/src/mock/cortexChatStore.d.ts +12 -0
- package/dist/src/stores/config.d.ts +52 -0
- package/dist/src/stores/guido-email-editor.d.ts +20 -10
- package/dist/src/stores/onboarding.d.ts +4 -0
- package/dist/src/stores/recommendation.d.ts +5 -0
- package/dist/src/stores/save-validation.d.ts +22 -0
- package/dist/src/utils/dateUtil.d.ts +10 -0
- package/dist/src/utils/genericUtil.d.ts +3 -0
- package/dist/src/utils/stripoEditorApi.d.ts +4 -0
- package/dist/src/utils/templatePreparation.d.ts +30 -0
- package/dist/static/styles/components/recommendation-strategy.css.js +9 -0
- package/dist/static/styles/components/version-history.css.js +2 -6
- package/dist/stores/config.js +84 -67
- package/dist/stores/guido-email-editor.js +3 -1
- package/dist/stores/onboarding.js +4 -0
- package/dist/stores/save-validation.js +30 -0
- package/dist/stores/unsubscribe.js +3 -3
- package/dist/utils/pairProductVariables.js +71 -71
- package/dist/utils/stripoEditorApi.js +11 -0
- package/dist/utils/templatePreparation.js +39 -36
- package/package.json +2 -1
package/README.md
CHANGED
|
@@ -164,6 +164,7 @@ const config: GuidoConfigInput = {
|
|
|
164
164
|
liquidSyntax?: boolean, // Default: false - Enable Liquid template syntax
|
|
165
165
|
autosave?: boolean, // Default: false - Show the Auto Save toggle in the header. See wiki/AUTOSAVE.md.
|
|
166
166
|
allowlistEnabled?: boolean, // Default: false - Pre-save domain-allowlist check (opt-in). Guido self-serves the block toaster (role lookup, deep-link, copy from window.trans).
|
|
167
|
+
allowSaveWithErrors?: boolean, // Default: true - Allow the validation drawer's "Save and Continue" soft-save. Set false to hard-block invalid saves (transactional + unsubscribe pages).
|
|
167
168
|
reusableRecommendationStrategy?: boolean, // Default: false - Assign an RRS strategy to recommendation blocks instead of per-block algorithm/filters/shuffle/product-count settings.
|
|
168
169
|
},
|
|
169
170
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ModuleFolderDefaults as f } from "../../enums/defaults.js";
|
|
2
|
-
import { object as
|
|
2
|
+
import { object as a, number as s, optional as e, string as t, picklist as m, pipe as i, minLength as b, custom as k, boolean as o, array as c, transform as y, unknown as r, record as g, fallback as R, literal as u, looseObject as C, variant as I, union as h, lazy as T } from "../../node_modules/valibot/dist/index.js";
|
|
3
3
|
const p = {
|
|
4
4
|
/** Promotional/marketing emails */
|
|
5
5
|
PROMOTIONAL: 1,
|
|
@@ -12,14 +12,14 @@ const p = {
|
|
|
12
12
|
ARCHITECT: 49,
|
|
13
13
|
/** Unsubscribe page builder */
|
|
14
14
|
UNSUBSCRIBE_PAGES: 97
|
|
15
|
-
}, A =
|
|
15
|
+
}, A = a({
|
|
16
16
|
/** Unique identifier for the template being edited */
|
|
17
|
-
templateId:
|
|
17
|
+
templateId: i(
|
|
18
18
|
t(),
|
|
19
19
|
b(1, "templateId is required")
|
|
20
20
|
),
|
|
21
21
|
/** Unique identifier for the user editing the template */
|
|
22
|
-
userId:
|
|
22
|
+
userId: i(
|
|
23
23
|
t(),
|
|
24
24
|
b(1, "userId is required")
|
|
25
25
|
),
|
|
@@ -33,20 +33,20 @@ const p = {
|
|
|
33
33
|
* Stripo doc id) and is never an endpoint id.
|
|
34
34
|
*/
|
|
35
35
|
templateLibraryId: e(t())
|
|
36
|
-
}), L =
|
|
36
|
+
}), L = a({
|
|
37
37
|
/** Fallback font name (e.g., "Georgia") */
|
|
38
38
|
name: t(),
|
|
39
39
|
/** Fallback font family (e.g., "serif" or "sans-serif") */
|
|
40
40
|
family: t()
|
|
41
|
-
}),
|
|
41
|
+
}), E = a({
|
|
42
42
|
/** Partner/organization name (required) */
|
|
43
|
-
name:
|
|
43
|
+
name: i(
|
|
44
44
|
t(),
|
|
45
45
|
b(1, "partner.name is required")
|
|
46
46
|
),
|
|
47
47
|
/** Product type identifier */
|
|
48
48
|
productType: e(
|
|
49
|
-
|
|
49
|
+
m([
|
|
50
50
|
l.EMAIL,
|
|
51
51
|
l.ARCHITECT,
|
|
52
52
|
l.UNSUBSCRIBE_PAGES
|
|
@@ -55,14 +55,14 @@ const p = {
|
|
|
55
55
|
),
|
|
56
56
|
/** Message type (promotional or transactional) */
|
|
57
57
|
messageType: e(
|
|
58
|
-
|
|
58
|
+
m([p.PROMOTIONAL, p.TRANSACTIONAL]),
|
|
59
59
|
p.PROMOTIONAL
|
|
60
60
|
),
|
|
61
61
|
/** Display name for the current user */
|
|
62
62
|
username: e(t(), "Guido User"),
|
|
63
63
|
/** Fallback font settings from partner settings — used to match backend size calculation */
|
|
64
64
|
fallbackFont: e(L)
|
|
65
|
-
}),
|
|
65
|
+
}), M = a({
|
|
66
66
|
/** Display text for the dynamic content */
|
|
67
67
|
text: t(),
|
|
68
68
|
/** Template variable value (e.g., {{username}}) */
|
|
@@ -71,12 +71,12 @@ const p = {
|
|
|
71
71
|
fallback: e(t()),
|
|
72
72
|
/** Optional formatting options */
|
|
73
73
|
format: e(
|
|
74
|
-
|
|
74
|
+
a({
|
|
75
75
|
key: t(),
|
|
76
76
|
value: t()
|
|
77
77
|
})
|
|
78
78
|
)
|
|
79
|
-
}), S = T(() =>
|
|
79
|
+
}), S = T(() => C({
|
|
80
80
|
text: e(t()),
|
|
81
81
|
// eslint-disable-next-line camelcase -- backend field name
|
|
82
82
|
tag_text: e(t()),
|
|
@@ -84,20 +84,20 @@ const p = {
|
|
|
84
84
|
children: e(c(S)),
|
|
85
85
|
// eslint-disable-next-line camelcase -- backend field name
|
|
86
86
|
select_items: e(c(S))
|
|
87
|
-
})), N =
|
|
87
|
+
})), N = g(
|
|
88
88
|
t(),
|
|
89
89
|
R(c(S), [])
|
|
90
|
-
), P =
|
|
90
|
+
), P = C({
|
|
91
91
|
/** Block ID (matches the dictionary key and the legacy HTML element id) */
|
|
92
|
-
id: e(
|
|
92
|
+
id: e(s()),
|
|
93
93
|
/** Decimal places for price display (legacy data may use string or number) */
|
|
94
|
-
decimalCount: e(
|
|
94
|
+
decimalCount: e(h([t(), s()])),
|
|
95
95
|
/** Pinned product IDs (empty array when filter-driven) */
|
|
96
96
|
productIds: e(c(r())),
|
|
97
97
|
/** Whether the block requested live products at send time */
|
|
98
|
-
sendProductRequestFlag: e(
|
|
98
|
+
sendProductRequestFlag: e(o()),
|
|
99
99
|
/** Whether to randomize product order */
|
|
100
|
-
shuffleProducts: e(
|
|
100
|
+
shuffleProducts: e(o()),
|
|
101
101
|
/** Filter rules driving product selection */
|
|
102
102
|
filters: e(c(r())),
|
|
103
103
|
/** Currency code (e.g. 'EUR') — sometimes absent in legacy data */
|
|
@@ -111,28 +111,28 @@ const p = {
|
|
|
111
111
|
/** Snapshot of products as rendered by the legacy block */
|
|
112
112
|
recommendedProducts: e(c(r())),
|
|
113
113
|
/** Number of product cards per row */
|
|
114
|
-
cardsInRow: e(
|
|
114
|
+
cardsInRow: e(s()),
|
|
115
115
|
/** Mobile-only padding (right) */
|
|
116
|
-
mobileRightPadding: e(
|
|
116
|
+
mobileRightPadding: e(s()),
|
|
117
117
|
/** Mobile-only padding (left) */
|
|
118
|
-
mobileLeftPadding: e(
|
|
118
|
+
mobileLeftPadding: e(s()),
|
|
119
119
|
/** Disable responsive scaling */
|
|
120
|
-
unresponsive: e(
|
|
120
|
+
unresponsive: e(o()),
|
|
121
121
|
/** Layout orientation ('vertical' | 'horizontal') */
|
|
122
122
|
orientation: e(t()),
|
|
123
123
|
/** Whether long text is trimmed */
|
|
124
|
-
textTrimming: e(
|
|
124
|
+
textTrimming: e(o()),
|
|
125
125
|
/** Block type marker used by some legacy variants */
|
|
126
126
|
blockType: e(t()),
|
|
127
127
|
/** Size variant marker (legacy data may use string or number) */
|
|
128
|
-
size: e(
|
|
128
|
+
size: e(h([t(), s()])),
|
|
129
129
|
/** Vertical responsiveness flag (legacy size=1 variants) */
|
|
130
|
-
verticalResponsiveness: e(
|
|
130
|
+
verticalResponsiveness: e(o()),
|
|
131
131
|
/** Legacy "Move to next line" price placement toggle (cardPricePlacement.js) */
|
|
132
|
-
isPriceMovedToNextLine: e(
|
|
132
|
+
isPriceMovedToNextLine: e(o()),
|
|
133
133
|
/** Legacy "Hide if same as discounted" / delete-price-for-zero-sale toggle */
|
|
134
|
-
isPriceDeletedForZeroSale: e(
|
|
135
|
-
}), v =
|
|
134
|
+
isPriceDeletedForZeroSale: e(o())
|
|
135
|
+
}), v = a({
|
|
136
136
|
/**
|
|
137
137
|
* Legacy recommendation block configs keyed by block ID.
|
|
138
138
|
* Pass this when loading a template authored with the v1
|
|
@@ -140,17 +140,17 @@ const p = {
|
|
|
140
140
|
* strategy, currency, locale, and layout data.
|
|
141
141
|
*/
|
|
142
142
|
recommendationConfigs: e(
|
|
143
|
-
|
|
143
|
+
g(t(), P),
|
|
144
144
|
{}
|
|
145
145
|
)
|
|
146
|
-
}), x =
|
|
146
|
+
}), x = a({
|
|
147
147
|
/** Initial HTML content */
|
|
148
148
|
html: e(t(), ""),
|
|
149
149
|
/** Initial CSS content */
|
|
150
150
|
css: e(t(), ""),
|
|
151
151
|
/** Preselected dynamic content items */
|
|
152
152
|
preselectedDynamicContent: e(
|
|
153
|
-
c(
|
|
153
|
+
c(M),
|
|
154
154
|
[]
|
|
155
155
|
),
|
|
156
156
|
/**
|
|
@@ -163,9 +163,9 @@ const p = {
|
|
|
163
163
|
/** Valid custom field attribute names from the partner's categorized fields */
|
|
164
164
|
customFieldAttributes: e(c(t()), []),
|
|
165
165
|
/** Selected unsubscribe page IDs */
|
|
166
|
-
selectedUnsubscribePages: e(c(
|
|
166
|
+
selectedUnsubscribePages: e(c(s()), []),
|
|
167
167
|
/** Force recreate template in Stripo storage (use true when updating externally modified templates) */
|
|
168
|
-
forceRecreate: e(
|
|
168
|
+
forceRecreate: e(o(), !1),
|
|
169
169
|
/**
|
|
170
170
|
* Consumer-persisted tracking-id high-water mark (SD-141414). Used as the id floor
|
|
171
171
|
* during migration so a rolled-back document never re-mints retired tracking ids.
|
|
@@ -174,62 +174,77 @@ const p = {
|
|
|
174
174
|
* mount. Non-numbers still fail, like every other field in this schema.
|
|
175
175
|
*/
|
|
176
176
|
trackIdCounter: e(
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
177
|
+
i(
|
|
178
|
+
s(),
|
|
179
|
+
y((n) => Number.isFinite(n) ? Math.max(0, Math.floor(n)) : 0)
|
|
180
180
|
),
|
|
181
181
|
0
|
|
182
182
|
),
|
|
183
|
+
/**
|
|
184
|
+
* The variation's saved `recommendationCampaignUrls`, keyed by block id. A block
|
|
185
|
+
* that still names a strategy but has no entry here had it dropped by a
|
|
186
|
+
* cross-account duplicate, so Guido resets it on load (SD-151945). Omit it and
|
|
187
|
+
* that check is off, and so is any non-object value such as `null`, because a reset
|
|
188
|
+
* cannot be undone. Hosts send `[]` for an empty map.
|
|
189
|
+
*/
|
|
190
|
+
recommendationCampaignUrls: e(
|
|
191
|
+
i(
|
|
192
|
+
r(),
|
|
193
|
+
y((n) => n && typeof n == "object" ? { ...n } : void 0)
|
|
194
|
+
)
|
|
195
|
+
),
|
|
183
196
|
/** Migration-only inputs (legacy block configs) */
|
|
184
197
|
migration: e(v, {})
|
|
185
|
-
}), D =
|
|
198
|
+
}), D = a({
|
|
186
199
|
/** Sender display name */
|
|
187
200
|
senderName: e(t(), ""),
|
|
188
201
|
/** Email subject line */
|
|
189
202
|
subject: e(t(), "")
|
|
190
|
-
}), O =
|
|
203
|
+
}), O = a({
|
|
191
204
|
/** Locale for the editor UI */
|
|
192
205
|
locale: e(t(), "en"),
|
|
193
206
|
/** Path to translations object */
|
|
194
207
|
translationsPath: e(t(), "window.trans[Object.keys(window.trans)[0]]"),
|
|
195
208
|
/** Migration date for template compatibility */
|
|
196
|
-
migrationDate: e(
|
|
209
|
+
migrationDate: e(s(), 1759696858),
|
|
197
210
|
/** Email header settings */
|
|
198
211
|
emailHeader: e(D, { senderName: "", subject: "" }),
|
|
199
212
|
/** Folder name for user-saved modules (used by Stripo plugin panel for path construction) */
|
|
200
213
|
savedModulesFolderName: e(t(), f.SAVED_MODULES),
|
|
201
214
|
/** Folder name for default/prebuilt modules (used by Stripo plugin panel for path construction) */
|
|
202
215
|
defaultModulesFolderName: e(t(), f.DEFAULT_MODULES)
|
|
203
|
-
}), F =
|
|
216
|
+
}), F = a({
|
|
204
217
|
/** Whether to show the header bar */
|
|
205
|
-
showHeader: e(
|
|
218
|
+
showHeader: e(o(), !0),
|
|
206
219
|
/** Custom label for back button (if shown) */
|
|
207
220
|
backButtonLabel: e(t())
|
|
208
|
-
}), U =
|
|
221
|
+
}), U = a({
|
|
209
222
|
/** Enable dynamic content insertion */
|
|
210
|
-
dynamicContent: e(
|
|
223
|
+
dynamicContent: e(o(), !0),
|
|
211
224
|
/** Enable save as template functionality */
|
|
212
|
-
saveAsTemplate: e(
|
|
225
|
+
saveAsTemplate: e(o(), !0),
|
|
213
226
|
/** Enable version history */
|
|
214
|
-
versionHistory: e(
|
|
227
|
+
versionHistory: e(o(), !0),
|
|
215
228
|
/** Enable test message sending */
|
|
216
|
-
testMessage: e(
|
|
229
|
+
testMessage: e(o(), !0),
|
|
217
230
|
/** Enable display conditions */
|
|
218
|
-
displayConditions: e(
|
|
231
|
+
displayConditions: e(o(), !0),
|
|
219
232
|
/** Enable unsubscribe block */
|
|
220
|
-
unsubscribe: e(
|
|
233
|
+
unsubscribe: e(o(), !0),
|
|
221
234
|
/** Disable modules panel in the editor */
|
|
222
|
-
modulesDisabled: e(
|
|
235
|
+
modulesDisabled: e(o(), !1),
|
|
223
236
|
/** Enable Liquid template syntax */
|
|
224
|
-
liquidSyntax: e(
|
|
237
|
+
liquidSyntax: e(o(), !1),
|
|
225
238
|
/** Enable autosave (3-min interval + tab-hide). User toggles on/off from the header. */
|
|
226
|
-
autosave: e(
|
|
239
|
+
autosave: e(o(), !1),
|
|
227
240
|
/** Enable pre-save domain-allowlist validation (opt-in; Guido self-serves the block toaster) */
|
|
228
|
-
allowlistEnabled: e(
|
|
241
|
+
allowlistEnabled: e(o(), !1),
|
|
229
242
|
/** Enable persistent link tracking-id assignment for the click heatmap (opt-in) */
|
|
230
|
-
linkTrackingIds: e(
|
|
231
|
-
|
|
232
|
-
|
|
243
|
+
linkTrackingIds: e(o(), !1),
|
|
244
|
+
/** Allow persisting a template that still has validation errors (drawer "Save and Continue" soft-save). Host sets false for transactional + unsubscribe. */
|
|
245
|
+
allowSaveWithErrors: e(o(), !0),
|
|
246
|
+
reusableRecommendationStrategy: e(o(), !1)
|
|
247
|
+
}), w = m([
|
|
233
248
|
"amp-accordion",
|
|
234
249
|
"amp-carousel",
|
|
235
250
|
"amp-form-controls",
|
|
@@ -243,7 +258,7 @@ const p = {
|
|
|
243
258
|
"text-block",
|
|
244
259
|
"timer-block",
|
|
245
260
|
"video-block"
|
|
246
|
-
]),
|
|
261
|
+
]), B = m([
|
|
247
262
|
"dynamic-content",
|
|
248
263
|
"checkbox-block",
|
|
249
264
|
"radio-button-block",
|
|
@@ -251,25 +266,25 @@ const p = {
|
|
|
251
266
|
"unsubscribe-block",
|
|
252
267
|
"coupon-block",
|
|
253
268
|
"items-block"
|
|
254
|
-
]),
|
|
269
|
+
]), j = a({
|
|
255
270
|
/** Default blocks to exclude from the editor */
|
|
256
271
|
excludeDefaults: e(
|
|
257
|
-
c(
|
|
272
|
+
c(w),
|
|
258
273
|
[]
|
|
259
274
|
),
|
|
260
275
|
/** Custom blocks to include in the editor */
|
|
261
276
|
includeCustoms: e(
|
|
262
|
-
c(
|
|
277
|
+
c(B),
|
|
263
278
|
[]
|
|
264
279
|
)
|
|
265
|
-
}), d =
|
|
280
|
+
}), d = a({
|
|
266
281
|
/** Unique identifier for the rule */
|
|
267
282
|
id: t(),
|
|
268
283
|
/** Human-readable description */
|
|
269
284
|
description: e(t()),
|
|
270
285
|
/** Priority for rule ordering (lower = earlier) */
|
|
271
|
-
priority:
|
|
272
|
-
}),
|
|
286
|
+
priority: s()
|
|
287
|
+
}), H = a({
|
|
273
288
|
...d.entries,
|
|
274
289
|
type: u("replace"),
|
|
275
290
|
/** String to search for */
|
|
@@ -277,8 +292,8 @@ const p = {
|
|
|
277
292
|
/** Replacement string */
|
|
278
293
|
replacement: t(),
|
|
279
294
|
/** Replace all occurrences (default: false) */
|
|
280
|
-
replaceAll: e(
|
|
281
|
-
}),
|
|
295
|
+
replaceAll: e(o())
|
|
296
|
+
}), _ = a({
|
|
282
297
|
...d.entries,
|
|
283
298
|
type: u("regex"),
|
|
284
299
|
/** Regex pattern string */
|
|
@@ -287,46 +302,46 @@ const p = {
|
|
|
287
302
|
replacement: t(),
|
|
288
303
|
/** Regex flags (e.g., 'gi') */
|
|
289
304
|
flags: e(t())
|
|
290
|
-
}), q =
|
|
305
|
+
}), q = a({
|
|
291
306
|
...d.entries,
|
|
292
307
|
type: u("remove"),
|
|
293
308
|
/** Strings or patterns to remove */
|
|
294
309
|
targets: c(t())
|
|
295
|
-
}), G =
|
|
310
|
+
}), G = a({
|
|
296
311
|
...d.entries,
|
|
297
312
|
type: u("custom"),
|
|
298
313
|
/** Custom processor function */
|
|
299
|
-
processor:
|
|
300
|
-
(
|
|
314
|
+
processor: k(
|
|
315
|
+
(n) => typeof n == "function",
|
|
301
316
|
"processor must be a function"
|
|
302
317
|
)
|
|
303
318
|
}), V = I("type", [
|
|
319
|
+
H,
|
|
304
320
|
_,
|
|
305
|
-
j,
|
|
306
321
|
q,
|
|
307
322
|
G
|
|
308
|
-
]), z =
|
|
323
|
+
]), z = a({
|
|
309
324
|
/** Custom compiler rules to apply */
|
|
310
325
|
customRules: e(c(V), []),
|
|
311
326
|
/** Skip default compiler rules */
|
|
312
|
-
ignoreDefaultRules: e(
|
|
313
|
-
}),
|
|
327
|
+
ignoreDefaultRules: e(o(), !1)
|
|
328
|
+
}), W = a({
|
|
314
329
|
/**
|
|
315
330
|
* External validation handler called before save completes.
|
|
316
331
|
* Return false to cancel the save operation.
|
|
317
332
|
*/
|
|
318
333
|
externalValidation: e(
|
|
319
|
-
|
|
320
|
-
(
|
|
334
|
+
k(
|
|
335
|
+
(n) => typeof n == "function",
|
|
321
336
|
"externalValidation must be a function"
|
|
322
337
|
)
|
|
323
338
|
)
|
|
324
|
-
}),
|
|
339
|
+
}), K = a({
|
|
325
340
|
// Required sections
|
|
326
341
|
/** Identity configuration (required) */
|
|
327
342
|
identity: A,
|
|
328
343
|
/** Partner configuration (required) */
|
|
329
|
-
partner:
|
|
344
|
+
partner: E,
|
|
330
345
|
// Optional sections (with defaults)
|
|
331
346
|
/** Template content and presets */
|
|
332
347
|
template: e(x, {}),
|
|
@@ -337,36 +352,36 @@ const p = {
|
|
|
337
352
|
/** Feature toggles */
|
|
338
353
|
features: e(U, {}),
|
|
339
354
|
/** Block configuration */
|
|
340
|
-
blocks: e(
|
|
355
|
+
blocks: e(j, {}),
|
|
341
356
|
/** Compiler configuration */
|
|
342
357
|
compiler: e(z, {}),
|
|
343
358
|
/** Callbacks and event handlers */
|
|
344
|
-
callbacks: e(
|
|
359
|
+
callbacks: e(W, {})
|
|
345
360
|
});
|
|
346
361
|
export {
|
|
347
|
-
|
|
348
|
-
|
|
362
|
+
j as BlocksSchema,
|
|
363
|
+
W as CallbacksSchema,
|
|
349
364
|
V as CompilerRuleSchema,
|
|
350
365
|
z as CompilerSchema,
|
|
351
|
-
|
|
366
|
+
B as CustomBlockTypeSchema,
|
|
352
367
|
G as CustomRuleSchema,
|
|
353
|
-
|
|
368
|
+
w as DefaultBlockTypeSchema,
|
|
354
369
|
N as DynamicContentListSchema,
|
|
355
370
|
S as DynamicContentNodeSchema,
|
|
356
|
-
|
|
371
|
+
M as DynamicContentSchema,
|
|
357
372
|
O as EditorSchema,
|
|
358
373
|
D as EmailHeaderSchema,
|
|
359
374
|
L as FallbackFontSchema,
|
|
360
375
|
U as FeaturesSchema,
|
|
361
|
-
|
|
376
|
+
K as GuidoConfigSchema,
|
|
362
377
|
A as IdentitySchema,
|
|
363
378
|
P as LegacyRecommendationConfigSchema,
|
|
364
379
|
p as MessageType,
|
|
365
|
-
|
|
380
|
+
E as PartnerSchema,
|
|
366
381
|
l as ProductType,
|
|
367
|
-
|
|
382
|
+
_ as RegexRuleSchema,
|
|
368
383
|
q as RemoveRuleSchema,
|
|
369
|
-
|
|
384
|
+
H as ReplaceRuleSchema,
|
|
370
385
|
v as TemplateMigrationSchema,
|
|
371
386
|
x as TemplateSchema,
|
|
372
387
|
F as UISchema
|
|
@@ -3,7 +3,7 @@ import o from "./Guido.vue2.js";
|
|
|
3
3
|
import i from "../_virtual/_plugin-vue2_normalizer.js";
|
|
4
4
|
var t = function() {
|
|
5
5
|
var a = this, r = a._self._c, e = a._self._setupProxy;
|
|
6
|
-
return r("div", { ref: "wrapperRef", staticClass: "guido-editor__wrapper", class: { "guido-editor__no-header": e.noHeader } }, [r(e.HeaderWrapper, { ref: "headerWrapperRef" }), r(e.AutoSaveController), e.editorStore.isPreviewModeOpen ? r(e.PreviewContainer) : a._e(), r("div", { directives: [{ name: "show", rawName: "v-show", value: !e.previewStore.isLoaded, expression: "!previewStore.isLoaded" }], staticClass: "guido-editor__container", class: { "guido-editor__no-header": e.noHeader }, attrs: { id: "guido-editor" } }), r(e.Toaster), r(e.FilterSelectionDrawer), e.isRrsEnabled || e.hasAssignedStrategy ? r(e.AssignStrategyDrawer) : a._e(), e.isRrsEnabled || e.hasAssignedStrategy ? r(e.RemoveStrategyModal) : a._e(), e.isRrsEnabled ? r(e.LegacyStrategyUpdatedModal) : a._e(), r(e.SaveAsTemplateDrawer), e.isTestPartner() ? a._e() : r(e.OnboardingWrapper, { on: { "onboarding-finished": function(_) {
|
|
6
|
+
return r("div", { ref: "wrapperRef", staticClass: "guido-editor__wrapper", class: { "guido-editor__no-header": e.noHeader } }, [r(e.HeaderWrapper, { ref: "headerWrapperRef" }), r(e.AutoSaveController), e.editorStore.isPreviewModeOpen ? r(e.PreviewContainer) : a._e(), r("div", { directives: [{ name: "show", rawName: "v-show", value: !e.previewStore.isLoaded, expression: "!previewStore.isLoaded" }], staticClass: "guido-editor__container", class: { "guido-editor__no-header": e.noHeader }, attrs: { id: "guido-editor" } }), r(e.Toaster), r(e.AuthErrorModal), r(e.FilterSelectionDrawer), e.isRrsEnabled || e.hasAssignedStrategy ? r(e.AssignStrategyDrawer) : a._e(), e.isRrsEnabled || e.hasAssignedStrategy ? r(e.RemoveStrategyModal) : a._e(), e.isRrsEnabled ? r(e.LegacyStrategyUpdatedModal) : a._e(), r(e.SaveAsTemplateDrawer), e.isSaveValidationEnabled ? r(e.ValidationErrorDrawer) : a._e(), e.isTestPartner() ? a._e() : r(e.OnboardingWrapper, { on: { "onboarding-finished": function(_) {
|
|
7
7
|
return e.emit("onboarding:finished");
|
|
8
8
|
} } }), r(e.UnsubscribeWrapper), r(e.LoadingWrapper)], 1);
|
|
9
9
|
}, s = [], n = /* @__PURE__ */ i(
|
|
@@ -12,9 +12,9 @@ var t = function() {
|
|
|
12
12
|
s,
|
|
13
13
|
!1,
|
|
14
14
|
null,
|
|
15
|
-
"
|
|
15
|
+
"1b5c844a"
|
|
16
16
|
);
|
|
17
|
-
const
|
|
17
|
+
const v = n.exports;
|
|
18
18
|
export {
|
|
19
|
-
|
|
19
|
+
v as default
|
|
20
20
|
};
|