@useinsider/guido 3.28.1-beta.5ee9839 → 3.28.1-beta.6aafa21
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 +16 -0
- package/dist/@types/config/schemas.js +7 -5
- package/dist/composables/useStripo.js +66 -60
- package/dist/package.json.js +3 -3
- package/dist/src/@types/config/schemas.d.ts +4 -0
- package/dist/src/@types/generic.d.ts +10 -0
- package/dist/src/composables/useConfig.d.ts +2 -0
- package/dist/src/stores/config.d.ts +21 -0
- package/dist/src/utils/genericUtil.d.ts +6 -1
- package/dist/static/stripo-runtime-manifest.json.js +1 -1
- package/dist/utils/genericUtil.js +55 -45
- package/dist/utils/templatePreparation.js +9 -9
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -173,6 +173,7 @@ const config: GuidoConfigInput = {
|
|
|
173
173
|
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).
|
|
174
174
|
allowSaveWithErrors?: boolean, // Default: true - Allow the validation drawer's "Save and Continue" soft-save. Set false to hard-block invalid saves (transactional + unsubscribe pages).
|
|
175
175
|
reusableRecommendationStrategy?: boolean, // Default: false - Assign an RRS strategy to recommendation blocks instead of per-block algorithm/filters/shuffle/product-count settings.
|
|
176
|
+
dynamicContentSpecialLinks?: boolean, // Default: false - List the catalogue's URL attributes (token ends in `url` or `url_<n>`) and every Call an API variable as Stripo special links (Personalization tab of the link type selector)
|
|
176
177
|
legacyUnsubscribeConversion?: boolean, // Default: false - Convert legacy unsubscribe blocks that have no unsubscribe link into text blocks (on load and on module drop/copy) and show a warning modal.
|
|
177
178
|
accessibilityTesting?: boolean, // Default: false - Show the Accessibility Test entry in the header kebab menu (Stripo's checker: contrast, image alternatives, colour-vision simulation) and the tab-bar onboarding tour that points at it.
|
|
178
179
|
itemsPriceFormatting?: boolean, // Default: false - Items block price formatting: thousand/decimal separator + decimal count on the block root, raw price tags in the export (formatted at send time).
|
|
@@ -690,6 +691,21 @@ const closeModal = () => {
|
|
|
690
691
|
</script>
|
|
691
692
|
```
|
|
692
693
|
|
|
694
|
+
### Special links in the link type selector
|
|
695
|
+
|
|
696
|
+
Behind `features.dynamicContentSpecialLinks` (default `false`). Guido passes the `template.dynamicContentList`
|
|
697
|
+
catalogue to Stripo as `specialLinks`, one group per top-level category, keeping only the attributes whose
|
|
698
|
+
token ends in `url` or `url_<n>` (`last_visited_product_url`, `ins_apr_url_1`), each entry valued `{{token}}`.
|
|
699
|
+
Call an API variables are the exception: their tokens are id-based (`call_an_api_response_<id>`) and carry no
|
|
700
|
+
usable type, so the whole category is listed as its own group regardless of suffix. The link type dropdown of
|
|
701
|
+
link fields gains a **Personalization** tab with those groups and a search box; picking an entry writes the
|
|
702
|
+
token into the URL field and the dropdown label shows the entry's label.
|
|
703
|
+
|
|
704
|
+
- Link fields only: the image path, alt text and button text are not covered; they keep Stripo's native
|
|
705
|
+
merge-tag dropdown fed by `mergeTags`.
|
|
706
|
+
- The list is fixed at editor init and the host picker is not involved, so nothing is added to the selected
|
|
707
|
+
list; `template.customFieldAttributes` must list every token for save validation.
|
|
708
|
+
|
|
693
709
|
### Saved-module token repair
|
|
694
710
|
|
|
695
711
|
Legacy or hand-written **saved modules** may carry tokens by display label
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ModuleFolderDefaults as y } from "../../enums/defaults.js";
|
|
2
|
-
import { object as o, number as c, optional as e, string as t, picklist as m, pipe as r, minLength as p, custom as
|
|
2
|
+
import { object as o, number as c, optional as e, string as t, picklist as m, pipe as r, minLength as p, custom as h, boolean as a, array as n, transform as S, unknown as i, record as g, fallback as R, literal as u, looseObject as C, variant as T, union as k, lazy as I } from "../../node_modules/valibot/dist/index.js";
|
|
3
3
|
const b = {
|
|
4
4
|
/** Promotional/marketing emails */
|
|
5
5
|
PROMOTIONAL: 1,
|
|
@@ -91,7 +91,7 @@ const b = {
|
|
|
91
91
|
/** Block ID (matches the dictionary key and the legacy HTML element id) */
|
|
92
92
|
id: e(c()),
|
|
93
93
|
/** Decimal places for price display (legacy data may use string or number) */
|
|
94
|
-
decimalCount: e(
|
|
94
|
+
decimalCount: e(k([t(), c()])),
|
|
95
95
|
/** Pinned product IDs (empty array when filter-driven) */
|
|
96
96
|
productIds: e(n(i())),
|
|
97
97
|
/** Whether the block requested live products at send time */
|
|
@@ -125,7 +125,7 @@ const b = {
|
|
|
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(k([t(), c()])),
|
|
129
129
|
/** Vertical responsiveness flag (legacy size=1 variants) */
|
|
130
130
|
verticalResponsiveness: e(a()),
|
|
131
131
|
/** Legacy "Move to next line" price placement toggle (cardPricePlacement.js) */
|
|
@@ -247,6 +247,8 @@ const b = {
|
|
|
247
247
|
/** Allow persisting a template that still has validation errors (drawer "Save and Continue" soft-save). Host sets false for transactional + unsubscribe. */
|
|
248
248
|
allowSaveWithErrors: e(a(), !0),
|
|
249
249
|
reusableRecommendationStrategy: e(a(), !1),
|
|
250
|
+
/** List the dynamic-content catalogue as Stripo special links in the link type selector */
|
|
251
|
+
dynamicContentSpecialLinks: e(a(), !1),
|
|
250
252
|
/** Convert linkless legacy unsubscribe blocks into text blocks and warn with a modal (opt-in) */
|
|
251
253
|
legacyUnsubscribeConversion: e(a(), !1),
|
|
252
254
|
/** Items block: Recommendation-style price formatting (root currency-* attrs, raw price tags). Released dark. */
|
|
@@ -320,7 +322,7 @@ const b = {
|
|
|
320
322
|
...d.entries,
|
|
321
323
|
type: u("custom"),
|
|
322
324
|
/** Custom processor function */
|
|
323
|
-
processor:
|
|
325
|
+
processor: h(
|
|
324
326
|
(s) => typeof s == "function",
|
|
325
327
|
"processor must be a function"
|
|
326
328
|
)
|
|
@@ -340,7 +342,7 @@ const b = {
|
|
|
340
342
|
* Return false to cancel the save operation.
|
|
341
343
|
*/
|
|
342
344
|
externalValidation: e(
|
|
343
|
-
|
|
345
|
+
h(
|
|
344
346
|
(s) => typeof s == "function",
|
|
345
347
|
"externalValidation must be a function"
|
|
346
348
|
)
|
|
@@ -1,69 +1,75 @@
|
|
|
1
|
-
import { useActionsApi as
|
|
2
|
-
import { useAmbiguousDynamicContent as
|
|
3
|
-
import { useBlocksConfig as
|
|
4
|
-
import { useConfig as
|
|
5
|
-
import { useCustomInterfaceAppearance as
|
|
6
|
-
import { useFullStoryBridge as
|
|
7
|
-
import { useModuleRepair as
|
|
8
|
-
import { useStripoEventHandler as
|
|
9
|
-
import { useStripoNotifications as
|
|
10
|
-
import { useToaster as
|
|
11
|
-
import { localePatch as
|
|
12
|
-
import { en as
|
|
13
|
-
import { ToasterTypeOptions as
|
|
14
|
-
import { useStripoApi as
|
|
15
|
-
import
|
|
16
|
-
import { useEditorStore as
|
|
17
|
-
import { buildMergeTagEntries as
|
|
18
|
-
import { getStripoRuntimeBaseUrl as
|
|
19
|
-
let d = null,
|
|
20
|
-
const
|
|
21
|
-
const { features:
|
|
1
|
+
import { useActionsApi as G } from "./useActionsApi.js";
|
|
2
|
+
import { useAmbiguousDynamicContent as $ } from "./useAmbiguousDynamicContent.js";
|
|
3
|
+
import { useBlocksConfig as X } from "./useBlocksConfig.js";
|
|
4
|
+
import { useConfig as J } from "./useConfig.js";
|
|
5
|
+
import { useCustomInterfaceAppearance as B } from "./useCustomInterfaceAppearance.js";
|
|
6
|
+
import { useFullStoryBridge as K } from "./useFullStoryBridge.js";
|
|
7
|
+
import { useModuleRepair as Q } from "./useModuleRepair.js";
|
|
8
|
+
import { useStripoEventHandler as W } from "./useStripoEventHandler.js";
|
|
9
|
+
import { useStripoNotifications as Y } from "./useStripoNotifications.js";
|
|
10
|
+
import { useToaster as Z } from "./useToaster.js";
|
|
11
|
+
import { localePatch as ee } from "../config/i18n/index.js";
|
|
12
|
+
import { en as T } from "../config/i18n/en/index.js";
|
|
13
|
+
import { ToasterTypeOptions as te } from "../enums/toaster.js";
|
|
14
|
+
import { useStripoApi as oe } from "../services/stripoApi.js";
|
|
15
|
+
import re from "../static/styles/customEditorStyle.css.js";
|
|
16
|
+
import { useEditorStore as F } from "../stores/editor.js";
|
|
17
|
+
import { buildMergeTagEntries as ie, flattenDynamicContentList as ne, buildSpecialLinkGroups as ae } from "../utils/genericUtil.js";
|
|
18
|
+
import { getStripoRuntimeBaseUrl as se } from "../utils/stripoRuntime.js";
|
|
19
|
+
let d = null, A = !1;
|
|
20
|
+
const Fe = (t) => {
|
|
21
|
+
const { features: p, template: u, isFeatureEnabled: c } = J(), { handleError: f, showToaster: P } = Z(), { getToken: L, getCustomFonts: R, getSyncModulesStatus: D } = oe(), { handleEvent: U } = W(), { handleModuleAdd: V } = Q(), { restorePending: I } = $(), { getStripoBlocksConfig: q } = X(), { getStripoNotifications: x } = Y(), g = () => d || (d = new Promise((n, a) => {
|
|
22
22
|
if (document.getElementById("UiEditorScript")) {
|
|
23
23
|
n();
|
|
24
24
|
return;
|
|
25
25
|
}
|
|
26
|
-
const i =
|
|
26
|
+
const i = se();
|
|
27
27
|
if (!i) {
|
|
28
|
-
|
|
28
|
+
a(
|
|
29
29
|
new Error("guido.stripo.version is not set in package.json. Please configure the Stripo version.")
|
|
30
30
|
);
|
|
31
31
|
return;
|
|
32
32
|
}
|
|
33
|
-
const
|
|
34
|
-
e.id = "UiEditorScript", e.type = "module", e.src =
|
|
35
|
-
|
|
33
|
+
const s = `${i}UIEditor.js`, e = document.createElement("script");
|
|
34
|
+
e.id = "UiEditorScript", e.type = "module", e.src = s, e.onload = () => {
|
|
35
|
+
A = !0, n();
|
|
36
36
|
}, e.onerror = () => {
|
|
37
|
-
e.remove(),
|
|
37
|
+
e.remove(), a(new Error(`Failed to load Stripo UIEditor script from S3: ${s}`));
|
|
38
38
|
}, document.body.appendChild(e);
|
|
39
39
|
}), d.catch(() => {
|
|
40
40
|
d = null;
|
|
41
|
-
}), d),
|
|
42
|
-
var
|
|
43
|
-
const o =
|
|
41
|
+
}), d), O = async (n, a, i, s = [], e = !1, m = !1) => {
|
|
42
|
+
var k, w, b, _, v;
|
|
43
|
+
const o = F(), { html: S, css: y } = n, { baseBlocks: E, extensions: H } = await q();
|
|
44
44
|
t.mark("blocks_config_ready");
|
|
45
|
-
const
|
|
46
|
-
t.setTemplate({ html: S, css: y, forceRecreate:
|
|
45
|
+
const C = ((k = p.value) == null ? void 0 : k.displayConditions) ?? !0, M = ((w = p.value) == null ? void 0 : w.modulesDisabled) ?? !1, N = c("dynamicContentSpecialLinks"), h = m || (((b = u.value) == null ? void 0 : b.forceRecreate) ?? !1), j = "https://email-static.useinsider.com https://edge.fullstory.com https://rs.fullstory.com";
|
|
46
|
+
t.setTemplate({ html: S, css: y, forceRecreate: h }), B().importCss(), t.mark("init_editor"), await window.UIEditor.initEditor(
|
|
47
47
|
document.querySelector("#guido-editor"),
|
|
48
48
|
{
|
|
49
|
-
metadata:
|
|
49
|
+
metadata: a,
|
|
50
50
|
html: S,
|
|
51
51
|
css: y,
|
|
52
|
-
forceRecreate:
|
|
52
|
+
forceRecreate: h,
|
|
53
53
|
locale: "en",
|
|
54
54
|
undoButtonSelector: "#guido__undo-button",
|
|
55
55
|
redoButtonSelector: "#guido__redo-button",
|
|
56
56
|
mobileViewButtonSelector: ".guido__view-option-selection-mobile",
|
|
57
57
|
desktopViewButtonSelector: ".guido__view-option-selection-desktop",
|
|
58
58
|
codeEditorButtonSelector: "#guido__code-button",
|
|
59
|
-
customAppearanceMergetags: !
|
|
59
|
+
customAppearanceMergetags: !c("liquidSyntax"),
|
|
60
60
|
customAppearanceMergetagsBorderColor: "#f1f3fe",
|
|
61
61
|
customAppearanceMergetagsBackgroundColor: "#f1f3fe",
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
62
|
+
...N ? {
|
|
63
|
+
specialLinks: ae(
|
|
64
|
+
(_ = u.value) == null ? void 0 : _.dynamicContentList,
|
|
65
|
+
c("liquidSyntax")
|
|
66
|
+
)
|
|
67
|
+
} : {},
|
|
68
|
+
customViewStyles: re,
|
|
69
|
+
conditionsEnabled: C,
|
|
70
|
+
customConditionsEnabled: C,
|
|
65
71
|
enableXSSSecurity: !0,
|
|
66
|
-
modulesDisabled:
|
|
72
|
+
modulesDisabled: M,
|
|
67
73
|
syncModulesEnabled: e,
|
|
68
74
|
messageSettingsEnabled: !0,
|
|
69
75
|
displayGmailAnnotations: !0,
|
|
@@ -74,26 +80,26 @@ const ve = (t) => {
|
|
|
74
80
|
copyPasteEnabled: !1,
|
|
75
81
|
selectElementAfterDrop: !0,
|
|
76
82
|
sameFontSizeForOutlook: !0,
|
|
77
|
-
allowedScriptSourceDomains:
|
|
83
|
+
allowedScriptSourceDomains: j,
|
|
78
84
|
...E ? { baseBlocks: E } : {},
|
|
79
85
|
editorFonts: {
|
|
80
86
|
showDefaultStandardFonts: !0,
|
|
81
87
|
showDefaultNotStandardFonts: !0,
|
|
82
|
-
customFonts:
|
|
88
|
+
customFonts: s
|
|
83
89
|
},
|
|
84
90
|
mergeTags: [
|
|
85
91
|
{
|
|
86
|
-
entries:
|
|
92
|
+
entries: ie(
|
|
87
93
|
i.preselectedDynamicContentList,
|
|
88
|
-
|
|
89
|
-
|
|
94
|
+
ne((v = u.value) == null ? void 0 : v.dynamicContentList),
|
|
95
|
+
c("liquidSyntax")
|
|
90
96
|
)
|
|
91
97
|
}
|
|
92
98
|
],
|
|
93
99
|
async onTokenRefreshRequest(r) {
|
|
94
100
|
try {
|
|
95
101
|
t.mark("token_start");
|
|
96
|
-
const l = await
|
|
102
|
+
const l = await L();
|
|
97
103
|
t.mark("token_end"), r(l);
|
|
98
104
|
} catch (l) {
|
|
99
105
|
f(l, "Failed to refresh token");
|
|
@@ -101,8 +107,8 @@ const ve = (t) => {
|
|
|
101
107
|
},
|
|
102
108
|
onTemplateLoaded() {
|
|
103
109
|
try {
|
|
104
|
-
const { activateCustomViewStyles: r, updateTimerInClonedTemplate: l } =
|
|
105
|
-
|
|
110
|
+
const { activateCustomViewStyles: r, updateTimerInClonedTemplate: l } = G(), { injectFullStory: z } = K();
|
|
111
|
+
B().importCss(), r(), z(), I(), l(), i.onReady(), o.isStripoInitialized = !0, o.loadingStatus = !1, setTimeout(() => {
|
|
106
112
|
o.hasChanges = !1;
|
|
107
113
|
}, 1e3), t.markReady();
|
|
108
114
|
} catch (r) {
|
|
@@ -123,7 +129,7 @@ const ve = (t) => {
|
|
|
123
129
|
},
|
|
124
130
|
onEvent: U,
|
|
125
131
|
onModuleAdd: V,
|
|
126
|
-
notifications:
|
|
132
|
+
notifications: x(),
|
|
127
133
|
// Stripo deselects the block on any click outside the canvas, so every surface
|
|
128
134
|
// that belongs to the block's own flow has to be listed here (SD-153273).
|
|
129
135
|
ignoreClickOutsideSelectors: [
|
|
@@ -133,26 +139,26 @@ const ve = (t) => {
|
|
|
133
139
|
".in-modal-v2-wrapper",
|
|
134
140
|
".in-toasts-wrapper"
|
|
135
141
|
],
|
|
136
|
-
extensions:
|
|
137
|
-
localePatch:
|
|
142
|
+
extensions: H,
|
|
143
|
+
localePatch: ee
|
|
138
144
|
}
|
|
139
145
|
);
|
|
140
146
|
};
|
|
141
|
-
return { initPlugin: async (n,
|
|
142
|
-
const e =
|
|
147
|
+
return { initPlugin: async (n, a, i, s = !1) => {
|
|
148
|
+
const e = F();
|
|
143
149
|
try {
|
|
144
|
-
t.mark("plugin_start"), t.setScriptPreloaded(
|
|
145
|
-
const [
|
|
150
|
+
t.mark("plugin_start"), t.setScriptPreloaded(A), await g(), t.mark("script_ready");
|
|
151
|
+
const [m, o] = await Promise.all([
|
|
146
152
|
R(),
|
|
147
153
|
D()
|
|
148
154
|
]);
|
|
149
|
-
t.mark("fonts_sync_ready"), e.syncModulesEnabled = o, await
|
|
155
|
+
t.mark("fonts_sync_ready"), e.syncModulesEnabled = o, await O(n, a, i, m, o, s);
|
|
150
156
|
} catch {
|
|
151
|
-
e.loadingStatus = !1,
|
|
152
|
-
type:
|
|
153
|
-
message:
|
|
157
|
+
e.loadingStatus = !1, P({
|
|
158
|
+
type: te.Error,
|
|
159
|
+
message: T["An error has occurred. Please report the error code to support."],
|
|
154
160
|
actionButton: {
|
|
155
|
-
text:
|
|
161
|
+
text: T["Reload page"],
|
|
156
162
|
onClick: () => window.location.reload()
|
|
157
163
|
}
|
|
158
164
|
}), t.markFailed();
|
|
@@ -163,5 +169,5 @@ const ve = (t) => {
|
|
|
163
169
|
} };
|
|
164
170
|
};
|
|
165
171
|
export {
|
|
166
|
-
|
|
172
|
+
Fe as useStripo
|
|
167
173
|
};
|
package/dist/package.json.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
const o = "3.28.1-beta.
|
|
1
|
+
const o = "3.28.1-beta.6aafa21", a = { stripo: { version: "2.86.1" } }, s = {
|
|
2
2
|
version: o,
|
|
3
|
-
guido:
|
|
3
|
+
guido: a
|
|
4
4
|
};
|
|
5
5
|
export {
|
|
6
6
|
s as default,
|
|
7
|
-
|
|
7
|
+
a as guido,
|
|
8
8
|
o as version
|
|
9
9
|
};
|
|
@@ -417,6 +417,8 @@ export declare const FeaturesSchema: v.ObjectSchema<{
|
|
|
417
417
|
/** Allow persisting a template that still has validation errors (drawer "Save and Continue" soft-save). Host sets false for transactional + unsubscribe. */
|
|
418
418
|
readonly allowSaveWithErrors: v.OptionalSchema<v.BooleanSchema<undefined>, true>;
|
|
419
419
|
readonly reusableRecommendationStrategy: v.OptionalSchema<v.BooleanSchema<undefined>, false>;
|
|
420
|
+
/** List the dynamic-content catalogue as Stripo special links in the link type selector */
|
|
421
|
+
readonly dynamicContentSpecialLinks: v.OptionalSchema<v.BooleanSchema<undefined>, false>;
|
|
420
422
|
/** Convert linkless legacy unsubscribe blocks into text blocks and warn with a modal (opt-in) */
|
|
421
423
|
readonly legacyUnsubscribeConversion: v.OptionalSchema<v.BooleanSchema<undefined>, false>;
|
|
422
424
|
/** Items block: Recommendation-style price formatting (root currency-* attrs, raw price tags). Released dark. */
|
|
@@ -844,6 +846,8 @@ export declare const GuidoConfigSchema: v.ObjectSchema<{
|
|
|
844
846
|
/** Allow persisting a template that still has validation errors (drawer "Save and Continue" soft-save). Host sets false for transactional + unsubscribe. */
|
|
845
847
|
readonly allowSaveWithErrors: v.OptionalSchema<v.BooleanSchema<undefined>, true>;
|
|
846
848
|
readonly reusableRecommendationStrategy: v.OptionalSchema<v.BooleanSchema<undefined>, false>;
|
|
849
|
+
/** List the dynamic-content catalogue as Stripo special links in the link type selector */
|
|
850
|
+
readonly dynamicContentSpecialLinks: v.OptionalSchema<v.BooleanSchema<undefined>, false>;
|
|
847
851
|
/** Convert linkless legacy unsubscribe blocks into text blocks and warn with a modal (opt-in) */
|
|
848
852
|
readonly legacyUnsubscribeConversion: v.OptionalSchema<v.BooleanSchema<undefined>, false>;
|
|
849
853
|
/** Items block: Recommendation-style price formatting (root currency-* attrs, raw price tags). Released dark. */
|
|
@@ -22,6 +22,8 @@ export type DynamicContentNode = {
|
|
|
22
22
|
text?: string;
|
|
23
23
|
tag_text?: string;
|
|
24
24
|
value?: string;
|
|
25
|
+
description?: string;
|
|
26
|
+
type?: string;
|
|
25
27
|
children?: DynamicContentNode[];
|
|
26
28
|
select_items?: DynamicContentNode[];
|
|
27
29
|
};
|
|
@@ -44,6 +46,14 @@ export type MergeTag = BaseDynamicContent & {
|
|
|
44
46
|
selEnd?: number;
|
|
45
47
|
hidden?: boolean;
|
|
46
48
|
};
|
|
49
|
+
export type SpecialLinkGroup = {
|
|
50
|
+
category: string;
|
|
51
|
+
entries: {
|
|
52
|
+
label: string;
|
|
53
|
+
value: string;
|
|
54
|
+
hidden?: boolean;
|
|
55
|
+
}[];
|
|
56
|
+
};
|
|
47
57
|
export type PositionData = {
|
|
48
58
|
x: number;
|
|
49
59
|
y: number;
|
|
@@ -106,6 +106,7 @@ export declare const useConfig: () => {
|
|
|
106
106
|
linkTrackingIds: boolean;
|
|
107
107
|
allowSaveWithErrors: boolean;
|
|
108
108
|
reusableRecommendationStrategy: boolean;
|
|
109
|
+
dynamicContentSpecialLinks: boolean;
|
|
109
110
|
legacyUnsubscribeConversion: boolean;
|
|
110
111
|
itemsPriceFormatting: boolean;
|
|
111
112
|
blockUnsubscribeLinks: boolean;
|
|
@@ -250,6 +251,7 @@ export declare const useConfig: () => {
|
|
|
250
251
|
linkTrackingIds: boolean;
|
|
251
252
|
allowSaveWithErrors: boolean;
|
|
252
253
|
reusableRecommendationStrategy: boolean;
|
|
254
|
+
dynamicContentSpecialLinks: boolean;
|
|
253
255
|
legacyUnsubscribeConversion: boolean;
|
|
254
256
|
itemsPriceFormatting: boolean;
|
|
255
257
|
blockUnsubscribeLinks: boolean;
|
|
@@ -111,6 +111,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
111
111
|
linkTrackingIds: boolean;
|
|
112
112
|
allowSaveWithErrors: boolean;
|
|
113
113
|
reusableRecommendationStrategy: boolean;
|
|
114
|
+
dynamicContentSpecialLinks: boolean;
|
|
114
115
|
legacyUnsubscribeConversion: boolean;
|
|
115
116
|
itemsPriceFormatting: boolean;
|
|
116
117
|
blockUnsubscribeLinks: boolean;
|
|
@@ -261,6 +262,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
261
262
|
linkTrackingIds: boolean;
|
|
262
263
|
allowSaveWithErrors: boolean;
|
|
263
264
|
reusableRecommendationStrategy: boolean;
|
|
265
|
+
dynamicContentSpecialLinks: boolean;
|
|
264
266
|
legacyUnsubscribeConversion: boolean;
|
|
265
267
|
itemsPriceFormatting: boolean;
|
|
266
268
|
blockUnsubscribeLinks: boolean;
|
|
@@ -411,6 +413,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
411
413
|
linkTrackingIds: boolean;
|
|
412
414
|
allowSaveWithErrors: boolean;
|
|
413
415
|
reusableRecommendationStrategy: boolean;
|
|
416
|
+
dynamicContentSpecialLinks: boolean;
|
|
414
417
|
legacyUnsubscribeConversion: boolean;
|
|
415
418
|
itemsPriceFormatting: boolean;
|
|
416
419
|
blockUnsubscribeLinks: boolean;
|
|
@@ -561,6 +564,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
561
564
|
linkTrackingIds: boolean;
|
|
562
565
|
allowSaveWithErrors: boolean;
|
|
563
566
|
reusableRecommendationStrategy: boolean;
|
|
567
|
+
dynamicContentSpecialLinks: boolean;
|
|
564
568
|
legacyUnsubscribeConversion: boolean;
|
|
565
569
|
itemsPriceFormatting: boolean;
|
|
566
570
|
blockUnsubscribeLinks: boolean;
|
|
@@ -711,6 +715,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
711
715
|
linkTrackingIds: boolean;
|
|
712
716
|
allowSaveWithErrors: boolean;
|
|
713
717
|
reusableRecommendationStrategy: boolean;
|
|
718
|
+
dynamicContentSpecialLinks: boolean;
|
|
714
719
|
legacyUnsubscribeConversion: boolean;
|
|
715
720
|
itemsPriceFormatting: boolean;
|
|
716
721
|
blockUnsubscribeLinks: boolean;
|
|
@@ -861,6 +866,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
861
866
|
linkTrackingIds: boolean;
|
|
862
867
|
allowSaveWithErrors: boolean;
|
|
863
868
|
reusableRecommendationStrategy: boolean;
|
|
869
|
+
dynamicContentSpecialLinks: boolean;
|
|
864
870
|
legacyUnsubscribeConversion: boolean;
|
|
865
871
|
itemsPriceFormatting: boolean;
|
|
866
872
|
blockUnsubscribeLinks: boolean;
|
|
@@ -1011,6 +1017,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
1011
1017
|
linkTrackingIds: boolean;
|
|
1012
1018
|
allowSaveWithErrors: boolean;
|
|
1013
1019
|
reusableRecommendationStrategy: boolean;
|
|
1020
|
+
dynamicContentSpecialLinks: boolean;
|
|
1014
1021
|
legacyUnsubscribeConversion: boolean;
|
|
1015
1022
|
itemsPriceFormatting: boolean;
|
|
1016
1023
|
blockUnsubscribeLinks: boolean;
|
|
@@ -1161,6 +1168,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
1161
1168
|
linkTrackingIds: boolean;
|
|
1162
1169
|
allowSaveWithErrors: boolean;
|
|
1163
1170
|
reusableRecommendationStrategy: boolean;
|
|
1171
|
+
dynamicContentSpecialLinks: boolean;
|
|
1164
1172
|
legacyUnsubscribeConversion: boolean;
|
|
1165
1173
|
itemsPriceFormatting: boolean;
|
|
1166
1174
|
blockUnsubscribeLinks: boolean;
|
|
@@ -1311,6 +1319,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
1311
1319
|
linkTrackingIds: boolean;
|
|
1312
1320
|
allowSaveWithErrors: boolean;
|
|
1313
1321
|
reusableRecommendationStrategy: boolean;
|
|
1322
|
+
dynamicContentSpecialLinks: boolean;
|
|
1314
1323
|
legacyUnsubscribeConversion: boolean;
|
|
1315
1324
|
itemsPriceFormatting: boolean;
|
|
1316
1325
|
blockUnsubscribeLinks: boolean;
|
|
@@ -1461,6 +1470,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
1461
1470
|
linkTrackingIds: boolean;
|
|
1462
1471
|
allowSaveWithErrors: boolean;
|
|
1463
1472
|
reusableRecommendationStrategy: boolean;
|
|
1473
|
+
dynamicContentSpecialLinks: boolean;
|
|
1464
1474
|
legacyUnsubscribeConversion: boolean;
|
|
1465
1475
|
itemsPriceFormatting: boolean;
|
|
1466
1476
|
blockUnsubscribeLinks: boolean;
|
|
@@ -1611,6 +1621,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
1611
1621
|
linkTrackingIds: boolean;
|
|
1612
1622
|
allowSaveWithErrors: boolean;
|
|
1613
1623
|
reusableRecommendationStrategy: boolean;
|
|
1624
|
+
dynamicContentSpecialLinks: boolean;
|
|
1614
1625
|
legacyUnsubscribeConversion: boolean;
|
|
1615
1626
|
itemsPriceFormatting: boolean;
|
|
1616
1627
|
blockUnsubscribeLinks: boolean;
|
|
@@ -1761,6 +1772,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
1761
1772
|
linkTrackingIds: boolean;
|
|
1762
1773
|
allowSaveWithErrors: boolean;
|
|
1763
1774
|
reusableRecommendationStrategy: boolean;
|
|
1775
|
+
dynamicContentSpecialLinks: boolean;
|
|
1764
1776
|
legacyUnsubscribeConversion: boolean;
|
|
1765
1777
|
itemsPriceFormatting: boolean;
|
|
1766
1778
|
blockUnsubscribeLinks: boolean;
|
|
@@ -1911,6 +1923,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
1911
1923
|
linkTrackingIds: boolean;
|
|
1912
1924
|
allowSaveWithErrors: boolean;
|
|
1913
1925
|
reusableRecommendationStrategy: boolean;
|
|
1926
|
+
dynamicContentSpecialLinks: boolean;
|
|
1914
1927
|
legacyUnsubscribeConversion: boolean;
|
|
1915
1928
|
itemsPriceFormatting: boolean;
|
|
1916
1929
|
blockUnsubscribeLinks: boolean;
|
|
@@ -2061,6 +2074,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
2061
2074
|
linkTrackingIds: boolean;
|
|
2062
2075
|
allowSaveWithErrors: boolean;
|
|
2063
2076
|
reusableRecommendationStrategy: boolean;
|
|
2077
|
+
dynamicContentSpecialLinks: boolean;
|
|
2064
2078
|
legacyUnsubscribeConversion: boolean;
|
|
2065
2079
|
itemsPriceFormatting: boolean;
|
|
2066
2080
|
blockUnsubscribeLinks: boolean;
|
|
@@ -2211,6 +2225,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
2211
2225
|
linkTrackingIds: boolean;
|
|
2212
2226
|
allowSaveWithErrors: boolean;
|
|
2213
2227
|
reusableRecommendationStrategy: boolean;
|
|
2228
|
+
dynamicContentSpecialLinks: boolean;
|
|
2214
2229
|
legacyUnsubscribeConversion: boolean;
|
|
2215
2230
|
itemsPriceFormatting: boolean;
|
|
2216
2231
|
blockUnsubscribeLinks: boolean;
|
|
@@ -2361,6 +2376,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
2361
2376
|
linkTrackingIds: boolean;
|
|
2362
2377
|
allowSaveWithErrors: boolean;
|
|
2363
2378
|
reusableRecommendationStrategy: boolean;
|
|
2379
|
+
dynamicContentSpecialLinks: boolean;
|
|
2364
2380
|
legacyUnsubscribeConversion: boolean;
|
|
2365
2381
|
itemsPriceFormatting: boolean;
|
|
2366
2382
|
blockUnsubscribeLinks: boolean;
|
|
@@ -2511,6 +2527,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
2511
2527
|
linkTrackingIds: boolean;
|
|
2512
2528
|
allowSaveWithErrors: boolean;
|
|
2513
2529
|
reusableRecommendationStrategy: boolean;
|
|
2530
|
+
dynamicContentSpecialLinks: boolean;
|
|
2514
2531
|
legacyUnsubscribeConversion: boolean;
|
|
2515
2532
|
itemsPriceFormatting: boolean;
|
|
2516
2533
|
blockUnsubscribeLinks: boolean;
|
|
@@ -2673,6 +2690,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
2673
2690
|
linkTrackingIds: boolean;
|
|
2674
2691
|
allowSaveWithErrors: boolean;
|
|
2675
2692
|
reusableRecommendationStrategy: boolean;
|
|
2693
|
+
dynamicContentSpecialLinks: boolean;
|
|
2676
2694
|
legacyUnsubscribeConversion: boolean;
|
|
2677
2695
|
itemsPriceFormatting: boolean;
|
|
2678
2696
|
blockUnsubscribeLinks: boolean;
|
|
@@ -2823,6 +2841,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
2823
2841
|
linkTrackingIds: boolean;
|
|
2824
2842
|
allowSaveWithErrors: boolean;
|
|
2825
2843
|
reusableRecommendationStrategy: boolean;
|
|
2844
|
+
dynamicContentSpecialLinks: boolean;
|
|
2826
2845
|
legacyUnsubscribeConversion: boolean;
|
|
2827
2846
|
itemsPriceFormatting: boolean;
|
|
2828
2847
|
blockUnsubscribeLinks: boolean;
|
|
@@ -2973,6 +2992,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
2973
2992
|
linkTrackingIds: boolean;
|
|
2974
2993
|
allowSaveWithErrors: boolean;
|
|
2975
2994
|
reusableRecommendationStrategy: boolean;
|
|
2995
|
+
dynamicContentSpecialLinks: boolean;
|
|
2976
2996
|
legacyUnsubscribeConversion: boolean;
|
|
2977
2997
|
itemsPriceFormatting: boolean;
|
|
2978
2998
|
blockUnsubscribeLinks: boolean;
|
|
@@ -3125,6 +3145,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
|
|
|
3125
3145
|
linkTrackingIds: boolean;
|
|
3126
3146
|
allowSaveWithErrors: boolean;
|
|
3127
3147
|
reusableRecommendationStrategy: boolean;
|
|
3148
|
+
dynamicContentSpecialLinks: boolean;
|
|
3128
3149
|
legacyUnsubscribeConversion: boolean;
|
|
3129
3150
|
itemsPriceFormatting: boolean;
|
|
3130
3151
|
blockUnsubscribeLinks: boolean;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { DynamicContent, DynamicContentCandidate, DynamicContentList, MergeTag } from '@@/Types/generic';
|
|
1
|
+
import type { DynamicContent, DynamicContentCandidate, DynamicContentList, MergeTag, SpecialLinkGroup } from '@@/Types/generic';
|
|
2
2
|
export declare const mergeTagToDynamicContent: (mergeTag: MergeTag) => DynamicContent;
|
|
3
3
|
export declare const dynamicContentToMergeTags: (dynamicContentList: DynamicContent[], liquidSyntax?: boolean) => MergeTag[];
|
|
4
4
|
/**
|
|
@@ -14,6 +14,11 @@ export declare const flattenDynamicContentList: (list: DynamicContentList | unde
|
|
|
14
14
|
* token — including ones repaired on module drop — render as a chip.
|
|
15
15
|
*/
|
|
16
16
|
export declare const buildMergeTagEntries: (preselected: DynamicContent[], available: DynamicContent[], liquidSyntax?: boolean) => MergeTag[];
|
|
17
|
+
/**
|
|
18
|
+
* Groups the active partner's URL attributes and every Call an API variable under
|
|
19
|
+
* their top-level category for Stripo's `specialLinks` option.
|
|
20
|
+
*/
|
|
21
|
+
export declare const buildSpecialLinkGroups: (list: DynamicContentList | undefined | null, liquidSyntax?: boolean) => SpecialLinkGroup[];
|
|
17
22
|
export declare const getCsrfToken: () => string;
|
|
18
23
|
/**
|
|
19
24
|
* URL Parameter utilities
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const s = "2.
|
|
1
|
+
const s = "2.86.1", n = ["UIEditor.js", "zone.js", "styles-BWH3PMR4.css", "polyfills-FF3RLU5F.js", "main-QEKXZ3YR.js", "chunk-5T7CEBI5.js", "chunk-62K3AMOD.js", "chunk-66LFOY5U.js", "chunk-AMCKJHBC.js", "chunk-BOERNIOQ.js", "chunk-BVZUBVXH.js", "chunk-I2DLD5I4.js", "chunk-IEC5XOV2.js", "chunk-ILRQX7FO.js", "chunk-LBYVYY25.js", "chunk-LC3XAPU2.js", "chunk-OZSNTS6D.js", "chunk-PBUSX63H.js", "chunk-PYISBD2D.js", "assets/css/uiEditor.css", "assets/i18n/en.json", "assets/icons/ui-editor-icons.sprite.svg", "assets/icons/ui-editor-icons.map.json", "assets/imageeditor/scripts.min.js", "assets/imageeditor/assets/icons/merged.svg"], c = {
|
|
2
2
|
version: s,
|
|
3
3
|
files: n
|
|
4
4
|
};
|
|
@@ -1,78 +1,88 @@
|
|
|
1
|
-
import { formatToLiquidFilter as
|
|
2
|
-
const
|
|
1
|
+
import { formatToLiquidFilter as g, liquidFilterToFormat as p, quoteArgument as y } from "./liquidDynamicContent.js";
|
|
2
|
+
const m = (t) => {
|
|
3
3
|
if (!t.includes("="))
|
|
4
4
|
return null;
|
|
5
|
-
const [
|
|
6
|
-
return { key:
|
|
7
|
-
}, u = "default:",
|
|
5
|
+
const [a, e] = t.split("=");
|
|
6
|
+
return { key: a.trim(), value: e.trim() };
|
|
7
|
+
}, u = "default:", b = (t) => {
|
|
8
8
|
if (!t.startsWith(u))
|
|
9
9
|
return t;
|
|
10
|
-
const
|
|
11
|
-
return e('"') || e("'") ?
|
|
12
|
-
},
|
|
13
|
-
const e = t.value.match(/\{\{([^}]+)\}\}/)[1].split("|").map((
|
|
10
|
+
const a = t.slice(u.length).trim(), e = (r) => a.length >= 2 && a.startsWith(r) && a.endsWith(r);
|
|
11
|
+
return e('"') || e("'") ? a.slice(1, -1) : a;
|
|
12
|
+
}, A = (t) => {
|
|
13
|
+
const e = t.value.match(/\{\{([^}]+)\}\}/)[1].split("|").map((n) => n.trim()), [r] = e, l = {
|
|
14
14
|
text: t.label,
|
|
15
|
-
value:
|
|
15
|
+
value: r || ""
|
|
16
16
|
};
|
|
17
17
|
if (e.length >= 2) {
|
|
18
|
-
const [,
|
|
19
|
-
if (
|
|
20
|
-
|
|
18
|
+
const [, n, c] = e;
|
|
19
|
+
if (n.startsWith(u))
|
|
20
|
+
l.fallback = b(n);
|
|
21
21
|
else {
|
|
22
|
-
const
|
|
23
|
-
|
|
22
|
+
const s = p(n) ?? m(n);
|
|
23
|
+
s ? l.format = s : c || (l.fallback = n), c && (l.fallback = b(c));
|
|
24
24
|
}
|
|
25
25
|
}
|
|
26
|
-
return
|
|
27
|
-
},
|
|
28
|
-
const e = !Number.isNaN(Number(t)) && t.trim() !== "" ? t :
|
|
26
|
+
return l;
|
|
27
|
+
}, d = (t) => {
|
|
28
|
+
const e = !Number.isNaN(Number(t)) && t.trim() !== "" ? t : y(t);
|
|
29
29
|
return e === null ? null : `${u} ${e}`;
|
|
30
|
-
},
|
|
31
|
-
const
|
|
30
|
+
}, v = (t) => {
|
|
31
|
+
const a = t.format ? g(t.format) : null, e = t.fallback ? d(t.fallback) : null, r = [t.value, a, e].filter(Boolean);
|
|
32
32
|
return {
|
|
33
|
-
label: [t.text,
|
|
34
|
-
value: `{{ ${
|
|
33
|
+
label: [t.text, a, e && t.fallback].filter(Boolean).join(" | "),
|
|
34
|
+
value: `{{ ${r.join(" | ")} }}`
|
|
35
35
|
};
|
|
36
|
-
},
|
|
36
|
+
}, i = (t, a = !1) => t.map((e) => a ? v(e) : e.format ? {
|
|
37
37
|
label: `${e.text} | ${e.format.key}=${e.format.value}`,
|
|
38
38
|
value: `{{${e.value}|${e.format.key}=${e.format.value}}}`
|
|
39
39
|
} : {
|
|
40
40
|
label: e.fallback ? `${e.text} | ${e.fallback}` : e.text,
|
|
41
41
|
value: e.fallback ? `{{${e.value}|${e.fallback}}}` : `{{${e.value}}}`
|
|
42
|
-
}),
|
|
43
|
-
const
|
|
44
|
-
Array.isArray(
|
|
45
|
-
const f = [...
|
|
42
|
+
}), T = (t) => {
|
|
43
|
+
const a = [], e = /* @__PURE__ */ new Set(), r = (n, c) => {
|
|
44
|
+
Array.isArray(n) && n.forEach((s) => {
|
|
45
|
+
const f = [...s.children ?? [], ...s.select_items ?? []], o = s.text || s.tag_text;
|
|
46
46
|
if (f.length > 0) {
|
|
47
|
-
|
|
47
|
+
r(f, o ? [...c, o] : c);
|
|
48
48
|
return;
|
|
49
49
|
}
|
|
50
|
-
|
|
50
|
+
o && s.value && !e.has(s.value) && (e.add(s.value), a.push({ value: s.value, text: o, tagText: s.tag_text || o, path: c }));
|
|
51
51
|
});
|
|
52
|
-
}, [
|
|
53
|
-
return
|
|
54
|
-
},
|
|
55
|
-
const
|
|
52
|
+
}, [l] = Object.values(t ?? {});
|
|
53
|
+
return r(l, []), a;
|
|
54
|
+
}, h = (t) => T(t).map(({ text: a, value: e }) => ({ text: a, value: e })), L = (t, a, e = !1) => {
|
|
55
|
+
const r = new Set(t.map((n) => n.value)), l = a.filter((n) => r.has(n.value) ? !1 : (r.add(n.value), !0));
|
|
56
56
|
return [
|
|
57
|
-
...
|
|
58
|
-
...
|
|
57
|
+
...i(t, e),
|
|
58
|
+
...i(l, e)
|
|
59
59
|
];
|
|
60
|
+
}, k = /url(_\d+)?$/i, _ = /^call_an_api_response_/, $ = (t) => k.test(t) || _.test(t), P = (t, a = !1) => {
|
|
61
|
+
const [e] = Object.values(t ?? {});
|
|
62
|
+
return (e ?? []).map((r) => {
|
|
63
|
+
const l = h({ node: [r] }).filter((n) => $(n.value));
|
|
64
|
+
return {
|
|
65
|
+
category: r.text || r.tag_text || "",
|
|
66
|
+
entries: i(l, a).map(({ label: n, value: c }) => ({ label: n, value: c }))
|
|
67
|
+
};
|
|
68
|
+
}).filter((r) => r.category && r.entries.length > 0);
|
|
60
69
|
}, F = () => {
|
|
61
70
|
var t;
|
|
62
71
|
return ((t = document.head.querySelector('meta[name="csrf-token"]')) == null ? void 0 : t.getAttribute("content")) ?? "";
|
|
63
|
-
},
|
|
72
|
+
}, N = (t) => typeof t == "string" ? t : typeof t == "number" ? String(t) : "", C = (t) => {
|
|
64
73
|
if (t === null || typeof t != "object" || Array.isArray(t))
|
|
65
74
|
return !1;
|
|
66
|
-
const
|
|
67
|
-
return
|
|
75
|
+
const a = Object.getPrototypeOf(t);
|
|
76
|
+
return a === Object.prototype || a === null;
|
|
68
77
|
};
|
|
69
78
|
export {
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
79
|
+
N as asText,
|
|
80
|
+
L as buildMergeTagEntries,
|
|
81
|
+
P as buildSpecialLinkGroups,
|
|
82
|
+
i as dynamicContentToMergeTags,
|
|
83
|
+
T as flattenDynamicContentCandidates,
|
|
84
|
+
h as flattenDynamicContentList,
|
|
75
85
|
F as getCsrfToken,
|
|
76
|
-
|
|
77
|
-
|
|
86
|
+
C as isPlainObject,
|
|
87
|
+
A as mergeTagToDynamicContent
|
|
78
88
|
};
|
|
@@ -50,17 +50,17 @@ const Y = () => {
|
|
|
50
50
|
const n = L(), s = N(), o = z(), { getCompiledEmail: r, getTemplateData: e } = x(), { writeTrackingIds: i } = F(), { compileHtml: t, compileAmpHtml: c } = I(), { isFeatureEnabled: a } = D();
|
|
51
51
|
return {
|
|
52
52
|
prepareTemplateDetails: async (h) => {
|
|
53
|
-
let { html: m, css:
|
|
53
|
+
let { html: m, css: u, syncModulesIds: f = [] } = h ?? await e();
|
|
54
54
|
if (a("linkTrackingIds")) {
|
|
55
55
|
const { changed: P, nextSeq: E } = i(s.trackIdSessionFloor);
|
|
56
|
-
s.trackIdSessionFloor = E, P && ({ html: m, css:
|
|
56
|
+
s.trackIdSessionFloor = E, P && ({ html: m, css: u, syncModulesIds: f = [] } = await e());
|
|
57
57
|
}
|
|
58
58
|
const { html: T, ampHtml: d = "", ampErrors: w = [] } = await r({
|
|
59
59
|
minimize: !0,
|
|
60
60
|
resetDataSavedFlag: !1
|
|
61
|
-
});
|
|
62
|
-
o.selectedUnsubscribePages.length && await o.fetchTemplates(), await S(m);
|
|
63
|
-
const { compiledHtml: A, stats: l, appliedRules: y } = t(T), C = d && c(d).compiledHtml, k = n.getSelectedDynamicContentList, H = b()
|
|
61
|
+
}), p = M(m);
|
|
62
|
+
(p.length || o.selectedUnsubscribePages.length) && await o.fetchTemplates(), await S(m);
|
|
63
|
+
const { compiledHtml: A, stats: l, appliedRules: y } = t(T), C = d && c(d).compiledHtml, k = n.getSelectedDynamicContentList, H = b();
|
|
64
64
|
return console.debug("HTML Compilation Stats:", {
|
|
65
65
|
originalSize: l.originalSize,
|
|
66
66
|
compiledSize: l.compiledSize,
|
|
@@ -71,17 +71,17 @@ const Y = () => {
|
|
|
71
71
|
dynamicContentList: k,
|
|
72
72
|
compiledHtml: A,
|
|
73
73
|
rawHtml: m,
|
|
74
|
-
css:
|
|
74
|
+
css: u,
|
|
75
75
|
ampHtml: C,
|
|
76
76
|
ampErrors: w,
|
|
77
|
-
modules:
|
|
77
|
+
modules: f.map(Number),
|
|
78
78
|
recommendation: {
|
|
79
79
|
campaignUrls: H.recommendationCampaignUrls,
|
|
80
80
|
configs: {}
|
|
81
81
|
},
|
|
82
82
|
unsubscribe: {
|
|
83
|
-
status:
|
|
84
|
-
config:
|
|
83
|
+
status: p.length > 0,
|
|
84
|
+
config: p
|
|
85
85
|
}
|
|
86
86
|
};
|
|
87
87
|
},
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@useinsider/guido",
|
|
3
|
-
"version": "3.28.1-beta.
|
|
3
|
+
"version": "3.28.1-beta.6aafa21",
|
|
4
4
|
"description": "Guido is a Vue + TypeScript wrapper for Email Plugin. Easily embed the email editor in your Vue applications.",
|
|
5
5
|
"main": "./dist/guido.umd.cjs",
|
|
6
6
|
"module": "./dist/library.js",
|
|
@@ -136,7 +136,7 @@
|
|
|
136
136
|
},
|
|
137
137
|
"guido": {
|
|
138
138
|
"stripo": {
|
|
139
|
-
"version": "2.
|
|
139
|
+
"version": "2.86.1"
|
|
140
140
|
}
|
|
141
141
|
}
|
|
142
142
|
}
|