@useinsider/guido 3.22.0 → 3.23.0

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 (70) hide show
  1. package/README.md +35 -4
  2. package/dist/components/Guido.vue.js +1 -1
  3. package/dist/components/Guido.vue2.js +118 -108
  4. package/dist/components/organisms/unsubscribe/UnsubscribePageSelection.vue.js +11 -11
  5. package/dist/components/organisms/unsubscribe/UnsubscribePageSelection.vue2.js +9 -9
  6. package/dist/composables/useEditorOpenMetrics.js +167 -0
  7. package/dist/composables/useStripo.js +93 -82
  8. package/dist/config/compiler/utils/recommendationCompilerUtils.js +22 -22
  9. package/dist/config/migrator/recommendation/compositionMapper.js +56 -49
  10. package/dist/config/migrator/recommendation/extractors.js +100 -40
  11. package/dist/config/migrator/recommendation/htmlBuilder.js +285 -207
  12. package/dist/config/migrator/recommendation/settingsMapper.js +37 -36
  13. package/dist/config/migrator/recommendation/themeMapper.js +53 -41
  14. package/dist/config/migrator/recommendationMigrator.js +68 -61
  15. package/dist/extensions/Blocks/Items/controls/button/link.js +14 -17
  16. package/dist/extensions/Blocks/Items/controls/cardComposition.js +14 -17
  17. package/dist/extensions/Blocks/Items/controls/image/link.js +14 -17
  18. package/dist/extensions/Blocks/Items/controls/name/trimming.js +9 -10
  19. package/dist/extensions/Blocks/Items/controls/price/currencyLocation.js +24 -25
  20. package/dist/extensions/Blocks/Items/controls/price/currencySymbol.js +12 -13
  21. package/dist/extensions/Blocks/Items/controls/price/formattedPrice.js +29 -30
  22. package/dist/extensions/Blocks/Items/controls/price/hideDiscount.js +15 -16
  23. package/dist/extensions/Blocks/Items/controls/price/priceOrientation.js +25 -26
  24. package/dist/extensions/Blocks/Items/controls/price/singlePrice.js +27 -28
  25. package/dist/extensions/Blocks/Items/controls/settingsControl.js +75 -80
  26. package/dist/extensions/Blocks/Recommendation/block.js +33 -24
  27. package/dist/extensions/Blocks/Recommendation/controls/cardBackground/index.js +3 -3
  28. package/dist/extensions/Blocks/Recommendation/controls/cardComposition/index.js +27 -26
  29. package/dist/extensions/Blocks/Recommendation/controls/customAttribute/textTrim.js +13 -13
  30. package/dist/extensions/Blocks/Recommendation/controls/main/index.js +165 -175
  31. package/dist/extensions/Blocks/Recommendation/controls/name/textTrim.js +5 -5
  32. package/dist/extensions/Blocks/Recommendation/controls/omnibusDiscount/textAfter.js +8 -8
  33. package/dist/extensions/Blocks/Recommendation/controls/omnibusDiscount/textBefore.js +15 -15
  34. package/dist/extensions/Blocks/Recommendation/controls/omnibusPrice/textAfter.js +12 -12
  35. package/dist/extensions/Blocks/Recommendation/controls/omnibusPrice/textBefore.js +10 -10
  36. package/dist/extensions/Blocks/Recommendation/controls/spacing/index.js +1 -1
  37. package/dist/extensions/Blocks/Recommendation/templates/grid/template.js +23 -22
  38. package/dist/extensions/Blocks/Recommendation/templates/list/template.js +19 -18
  39. package/dist/extensions/Blocks/Recommendation/templates/utils.js +82 -91
  40. package/dist/extensions/Blocks/Recommendation/utils/inlinePriceOrder.js +12 -0
  41. package/dist/extensions/Blocks/Recommendation/utils/legacyStrategyMap.js +3 -2
  42. package/dist/extensions/Blocks/common-control.js +62 -55
  43. package/dist/guido.css +1 -1
  44. package/dist/library.js +12 -10
  45. package/dist/package.json.js +6 -4
  46. package/dist/public/prefetchRuntime.js +4 -0
  47. package/dist/src/composables/useEditorOpenMetrics.d.ts +27 -0
  48. package/dist/src/composables/useStripo.d.ts +2 -1
  49. package/dist/src/config/migrator/recommendation/compositionMapper.d.ts +3 -1
  50. package/dist/src/config/migrator/recommendation/extractors.d.ts +35 -6
  51. package/dist/src/config/migrator/recommendation/htmlBuilder.d.ts +3 -1
  52. package/dist/src/config/migrator/recommendation/themeMapper.d.ts +3 -1
  53. package/dist/src/config/migrator/recommendation/types.d.ts +11 -1
  54. package/dist/src/extensions/Blocks/Items/controls/cardComposition.d.ts +0 -1
  55. package/dist/src/extensions/Blocks/Recommendation/block.d.ts +1 -0
  56. package/dist/src/extensions/Blocks/Recommendation/controls/main/index.d.ts +5 -10
  57. package/dist/src/extensions/Blocks/Recommendation/templates/utils.d.ts +1 -13
  58. package/dist/src/extensions/Blocks/Recommendation/utils/inlinePriceOrder.d.ts +9 -0
  59. package/dist/src/extensions/Blocks/Recommendation/utils/legacyStrategyMap.d.ts +2 -19
  60. package/dist/src/extensions/Blocks/common-control.d.ts +2 -0
  61. package/dist/src/library.d.ts +1 -0
  62. package/dist/src/public/prefetchRuntime.d.ts +1 -0
  63. package/dist/src/stores/unsubscribe.d.ts +10 -0
  64. package/dist/src/utils/runtimePrefetch.d.ts +4 -0
  65. package/dist/src/utils/stripoRuntime.d.ts +3 -0
  66. package/dist/static/stripo-runtime-manifest.json.js +9 -0
  67. package/dist/stores/unsubscribe.js +33 -29
  68. package/dist/utils/runtimePrefetch.js +26 -0
  69. package/dist/utils/stripoRuntime.js +13 -0
  70. package/package.json +7 -2
@@ -1,18 +1,21 @@
1
1
  import { RecommendationBlockId as g } from "../../../extensions/Blocks/Recommendation/constants/blockIds.js";
2
- import { CSS_CLASS_SKIP_COMPILE as st, ATTR_RECOMMENDATION_TITLE as lt, CURRENCY_ATTR as R, ATTR_PRODUCT_IMAGE as I, ATTR_PRODUCT_BUTTON as O, CSS_CLASS_RECO_BUTTON as H, ATTR_PRODUCT_NAME as j, ATTR_PRODUCT_PRICE as V, ATTR_PRODUCT_OLD_PRICE as Y, ATTR_PRODUCT_OMNIBUS_PRICE as M, ATTR_PRODUCT_OMNIBUS_DISCOUNT as F, ATTR_CUSTOM_PREFIX as K } from "../../../extensions/Blocks/Recommendation/constants/selectors.js";
3
- import { buildTitleRows as it } from "../../../extensions/Blocks/Recommendation/templates/titleRows.js";
4
- import { compositionKeyToProductAttr as J, bareAttributeName as X } from "../../../extensions/Blocks/Recommendation/utils/compositionKeys.js";
5
- import { formatPrice as B } from "../../../extensions/Blocks/Recommendation/utils/priceFormatter.js";
2
+ import { CSS_CLASS_SKIP_COMPILE as dt, ATTR_RECOMMENDATION_TITLE as pt, CURRENCY_ATTR as O, ATTR_PRODUCT_PRICE as v, ATTR_PRODUCT_OLD_PRICE as k, ATTR_PRODUCT_IMAGE as L, ATTR_PRODUCT_BUTTON as U, CSS_CLASS_RECO_BUTTON as J, ATTR_PRODUCT_NAME as q, ATTR_PRODUCT_OMNIBUS_PRICE as H, ATTR_PRODUCT_OMNIBUS_DISCOUNT as Q, ATTR_CUSTOM_PREFIX as Z } from "../../../extensions/Blocks/Recommendation/constants/selectors.js";
3
+ import { CSS_CLASS_NO_MOBILE_LAYOUT as ut } from "../../../extensions/Blocks/Recommendation/controls/mobileLayout/cssRules.js";
4
+ import { CSS_CLASS_TEXT_TRIM as bt } from "../../../extensions/Blocks/Recommendation/controls/shared/textTrimCssRules.js";
5
+ import { buildTitleRows as $t } from "../../../extensions/Blocks/Recommendation/templates/titleRows.js";
6
+ import { compositionKeyToProductAttr as W, bareAttributeName as tt } from "../../../extensions/Blocks/Recommendation/utils/compositionKeys.js";
7
+ import { resolveInlinePriceOrder as gt } from "../../../extensions/Blocks/Recommendation/utils/inlinePriceOrder.js";
8
+ import { formatPrice as V } from "../../../extensions/Blocks/Recommendation/utils/priceFormatter.js";
6
9
  import { escapeHtml as r } from "../../../utils/htmlEscape.js";
7
- import { appendStyle as $ } from "./themeMapper.js";
8
- const q = "https://email-static.useinsider.com/stripo/modules/email-recommendation-v3/assets/images/image-placeholder.png", Q = "attribute-cell", Z = "Buy", W = "border-width: 1px; background: rgb(217, 234, 211); border-color: rgb(106, 168, 79)", tt = "color: rgb(56, 118, 29); background: rgb(217, 234, 211); font-family: arial, 'helvetica neue', helvetica, sans-serif; font-size: 16px; font-weight: normal; line-height: 120%; mso-border-alt: 10px solid rgb(217, 234, 211); mso-padding-alt: 0", rt = "ins-recommendation-product-container ins-recommendation-desktop-container";
9
- function ct(t) {
10
+ import { appendStyle as m } from "./themeMapper.js";
11
+ const et = "https://email-static.useinsider.com/stripo/modules/email-recommendation-v3/assets/images/image-placeholder.png", ot = "attribute-cell", nt = "Buy", lt = "border-width: 1px; background: rgb(217, 234, 211); border-color: rgb(106, 168, 79)", it = "color: rgb(56, 118, 29); background: rgb(217, 234, 211); font-family: arial, 'helvetica neue', helvetica, sans-serif; font-size: 16px; font-weight: normal; line-height: 120%; mso-border-alt: 10px solid rgb(217, 234, 211); mso-padding-alt: 0", mt = "ins-recommendation-product-container ins-recommendation-desktop-container", ft = "ins-recommendation-product-container ins-recommendation-mobile-container", st = "font-size: 16px; color: #333333", j = "font-size: 14px; color: #999999", ct = `${j}; text-decoration: line-through; margin: 0`;
12
+ function yt(t) {
10
13
  return t.replace(/>\s+</g, "><").trim();
11
14
  }
12
15
  function f(t) {
13
16
  return t ? ` align="${r(t)}"` : ' align="center"';
14
17
  }
15
- function _() {
18
+ function P() {
16
19
  return {
17
20
  tdStyle: "",
18
21
  pStyle: "",
@@ -21,25 +24,28 @@ function _() {
21
24
  textTrimming: !1
22
25
  };
23
26
  }
24
- function et(t) {
25
- return t ? { ...t, wrapBold: !0 } : { ..._(), wrapBold: !0 };
27
+ function G(t) {
28
+ return t ? { ...t, wrapBold: !0 } : { ...P(), wrapBold: !0 };
26
29
  }
27
- function N(t, o) {
28
- let e = r(t);
29
- return o.wrapBold && o.wrapItalic ? e = `<strong><em>${e}</em></strong>` : o.wrapBold ? e = `<strong>${e}</strong>` : o.wrapItalic && (e = `<em>${e}</em>`), e;
30
+ function x(t, e) {
31
+ let o = r(t);
32
+ return e.wrapBold && e.wrapItalic ? o = `<strong><em>${o}</em></strong>` : e.wrapBold ? o = `<strong>${o}</strong>` : e.wrapItalic && (o = `<em>${o}</em>`), o;
30
33
  }
31
34
  function u(t) {
32
35
  return t ? ` style="${r(t)}"` : "";
33
36
  }
34
- function P(t, o) {
35
- return `<td width="${t}%" class="${Q}" ${o}`;
37
+ function D(t) {
38
+ return t.textTrimming ? ` ${bt}` : "";
36
39
  }
37
- function at(t, o, e, s) {
38
- const l = t.width ? ` width="${t.width}"` : "", n = t.height ? ` height="${t.height}"` : "", i = ["display: block", "max-width: 100%", "height: auto"];
40
+ function R(t, e) {
41
+ return `<td width="${t}%" class="${ot}" ${e}`;
42
+ }
43
+ function St(t, e, o, n) {
44
+ const s = t.width ? ` width="${t.width}"` : "", l = t.height ? ` height="${t.height}"` : "", i = ["display: block", "max-width: 100%", "height: auto"];
39
45
  t.width && i.push(`width: ${t.width}px`), t.height && i.push(`height: ${t.height}px`);
40
- const c = i.join("; "), a = e ? ` style="background-color: ${r(e)}"` : "";
46
+ const c = i.join("; "), a = o ? ` style="background-color: ${r(o)}"` : "";
41
47
  return `
42
- ${P(s, 'valign="top" style="padding: 0 5px; height: 100%"')}>
48
+ ${R(n, 'valign="top" style="padding: 0 5px; height: 100%"')}>
43
49
  <table width="100%" height="100%" cellpadding="0" cellspacing="0" border="0"
44
50
  class="product-card-segment"${a}>
45
51
  <tbody>
@@ -47,9 +53,9 @@ function at(t, o, e, s) {
47
53
  <td align="center"
48
54
  class="esd-block-image product-image es-p5"
49
55
  esd-extension-block-id="${g.IMAGE}">
50
- <a target="_blank" href="https://example.com/product/${o + 1}">
51
- <img src="${q}" alt="Product Name"
52
- class="adapt-img"${l}${n}
56
+ <a target="_blank" href="https://example.com/product/${e + 1}">
57
+ <img src="${et}" alt="Product Name"
58
+ class="adapt-img"${s}${l}
53
59
  style="${c}">
54
60
  </a>
55
61
  </td>
@@ -59,18 +65,18 @@ function at(t, o, e, s) {
59
65
  </td>
60
66
  `;
61
67
  }
62
- function G(t, o, e, s, l, n, i) {
63
- const a = `table-layout: fixed${n ? `; background-color: ${r(n)}` : ""}`, d = u(l.tdStyle), p = f(l.align), b = `esd-block-text ${o}`.trim(), m = $(s, l.pStyle);
68
+ function F(t, e, o, n, s, l, i) {
69
+ const a = `table-layout: fixed${l ? `; background-color: ${r(l)}` : ""}`, p = u(s.tdStyle), d = f(s.align), b = `esd-block-text ${e}`.trim(), $ = m(n, s.pStyle);
64
70
  return `
65
- ${P(i, 'valign="top" style="padding: 0 5px; height: 100%"')}>
71
+ ${R(i, 'valign="top" style="padding: 0 5px; height: 100%"')}>
66
72
  <table width="100%" height="100%" cellpadding="0" cellspacing="0" border="0"
67
73
  class="product-card-segment" style="${a}">
68
74
  <tbody>
69
75
  <tr valign="top">
70
- <td${p}
76
+ <td${d}
71
77
  class="${b}"
72
- esd-extension-block-id="${t}"${d}>
73
- <p contenteditable="false"${u(m)}>${N(e, l)}</p>
78
+ esd-extension-block-id="${t}"${p}>
79
+ <p contenteditable="false"${u($)}>${x(o, s)}</p>
74
80
  </td>
75
81
  </tr>
76
82
  </tbody>
@@ -78,19 +84,19 @@ function G(t, o, e, s, l, n, i) {
78
84
  </td>
79
85
  `;
80
86
  }
81
- function dt(t, o, e, s) {
82
- const l = o ? ` style="background-color: ${r(o)}"` : "", n = u(t.tdStyle), i = f(t.align), a = $("font-size: 14px; color: #999999", t.pStyle);
87
+ function ht(t, e, o, n) {
88
+ const s = e ? ` style="background-color: ${r(e)}"` : "", l = u(t.tdStyle), i = f(t.align), c = m(j, t.pStyle);
83
89
  return `
84
- ${P(e, 'valign="top" style="padding: 0 5px; height: 100%"')}>
90
+ ${R(o, 'valign="top" style="padding: 0 5px; height: 100%"')}>
85
91
  <table width="100%" height="100%" cellpadding="0" cellspacing="0" border="0"
86
- class="product-card-segment"${l}>
92
+ class="product-card-segment"${s}>
87
93
  <tbody>
88
94
  <tr valign="top">
89
95
  <td${i}
90
96
  class="esd-block-text product-old-price es-p15l es-p15r"
91
- esd-extension-block-id="${g.OLD_PRICE}"${n}>
92
- <p contenteditable="false"${u(a)}>
93
- <s>${N(s, t)}</s>
97
+ esd-extension-block-id="${g.OLD_PRICE}"${l}>
98
+ <p contenteditable="false"${u(c)}>
99
+ <s>${x(n, t)}</s>
94
100
  </p>
95
101
  </td>
96
102
  </tr>
@@ -99,21 +105,21 @@ function dt(t, o, e, s) {
99
105
  </td>
100
106
  `;
101
107
  }
102
- function z(t, o, e, s, l, n, i) {
103
- const c = l ? `; background-color: ${r(l)}` : "", a = u(s.tdStyle), d = f(s.align), b = $("font-size: 12px; color: #666666", s.pStyle);
108
+ function K(t, e, o, n, s, l, i) {
109
+ const c = s ? `; background-color: ${r(s)}` : "", a = u(n.tdStyle), p = f(n.align), b = m("font-size: 12px; color: #666666", n.pStyle);
104
110
  return `
105
- ${P(i, 'valign="top" style="padding: 0 5px; height: 100%"')}>
111
+ ${R(i, 'valign="top" style="padding: 0 5px; height: 100%"')}>
106
112
  <table width="100%" height="100%" cellpadding="0" cellspacing="0" border="0"
107
113
  class="product-card-segment" style="table-layout: fixed${c}">
108
114
  <tbody>
109
115
  <tr valign="top">
110
- <td${d}
116
+ <td${p}
111
117
  data-text-before="" data-text-after=""
112
- class="esd-block-text ${n} es-p15l es-p15r"
118
+ class="esd-block-text ${l} es-p15l es-p15r"
113
119
  esd-extension-block-id="${t}"${a}>
114
120
  <p contenteditable="false"${u(b)}>
115
121
  <span class="omnibus-text-before"></span>
116
- <span class="${o}">${r(e)}</span>
122
+ <span class="${e}">${r(o)}</span>
117
123
  <span class="omnibus-text-after"></span>
118
124
  </p>
119
125
  </td>
@@ -123,12 +129,12 @@ function z(t, o, e, s, l, n, i) {
123
129
  </td>
124
130
  `;
125
131
  }
126
- function pt(t, o, e, s) {
127
- const l = e ? ` style="background-color: ${r(e)}"` : "", n = $("padding: 0 5px; height: 100%", o.tdStyle), i = f(o.align), c = o.text || Z, a = $(W, o.spanStyle), d = $(tt, o.aStyle);
132
+ function xt(t, e, o, n) {
133
+ const s = o ? ` style="background-color: ${r(o)}"` : "", l = m("padding: 0 5px; height: 100%", e.tdStyle), i = f(e.align), c = e.text || nt, a = m(lt, e.spanStyle), p = m(it, e.aStyle);
128
134
  return `
129
- ${P(s, `valign="top" style="${r(n)}"`)}>
135
+ ${R(n, `valign="top" style="${r(l)}"`)}>
130
136
  <table width="100%" height="100%" cellpadding="0" cellspacing="0" border="0"
131
- class="product-card-segment"${l}>
137
+ class="product-card-segment"${s}>
132
138
  <tbody>
133
139
  <tr valign="top">
134
140
  <td${i}
@@ -136,8 +142,8 @@ function pt(t, o, e, s) {
136
142
  esd-extension-block-id="${g.BUTTON}">
137
143
  <span class="es-button-border" style="${r(a)}">
138
144
  <a href="https://example.com/product/${t + 1}" target="_blank"
139
- class="es-button ${H}"
140
- style="${r(d)}">${r(c)}</a>
145
+ class="es-button ${J}"
146
+ style="${r(p)}">${r(c)}</a>
141
147
  </span>
142
148
  </td>
143
149
  </tr>
@@ -146,18 +152,18 @@ function pt(t, o, e, s) {
146
152
  </td>
147
153
  `;
148
154
  }
149
- function ut(t, o, e, s, l) {
150
- const n = s ? `; background-color: ${r(s)}` : "", i = u(e.tdStyle), c = f(e.align), d = $("font-size: 12px; color: #666666; margin: 0", e.pStyle), p = o.replace(/_/g, " ").replace(/\b\w/g, (b) => b.toUpperCase());
155
+ function Ct(t, e, o, n, s) {
156
+ const l = n ? `; background-color: ${r(n)}` : "", i = u(o.tdStyle), c = f(o.align), p = m("font-size: 12px; color: #666666; margin: 0", o.pStyle), d = `esd-block-text product-custom-attribute es-p0t es-p0b es-p15l es-p15r${D(o)}`, b = e.replace(/_/g, " ").replace(/\b\w/g, ($) => $.toUpperCase());
151
157
  return `
152
- ${P(l, 'valign="middle" style="padding: 0 5px; height: 100%"')}>
158
+ ${R(s, 'valign="middle" style="padding: 0 5px; height: 100%"')}>
153
159
  <table width="100%" height="100%" cellpadding="0" cellspacing="0" border="0"
154
- class="product-card-segment" style="table-layout: fixed${n}">
160
+ class="product-card-segment" style="table-layout: fixed${l}">
155
161
  <tbody>
156
162
  <tr valign="top">
157
163
  <td product-attr="${r(t)}"${c}
158
- class="esd-block-text product-custom-attribute es-p0t es-p0b es-p15l es-p15r"
164
+ class="${d}"
159
165
  esd-extension-block-id="${g.CUSTOM_ATTRIBUTE}"${i}>
160
- <p contenteditable="false"${u(d)}>${r(p)}</p>
166
+ <p contenteditable="false"${u(p)}>${r(b)}</p>
161
167
  </td>
162
168
  </tr>
163
169
  </tbody>
@@ -165,111 +171,155 @@ function ut(t, o, e, s, l) {
165
171
  </td>
166
172
  `;
167
173
  }
168
- function bt(t, o, e, s, l, n, i) {
169
- const c = o[t], a = c ?? _();
174
+ function Tt(t, e, o, n, s) {
175
+ const l = e ? ` style="background-color: ${r(e)}"` : "", i = G(t[v]), c = t[k] ?? P(), a = ($) => `
176
+ <td${f(i.align)} valign="middle"
177
+ class="esd-block-text product-price ${$}"
178
+ esd-extension-block-id="${g.PRICE}"${u(i.tdStyle)}>
179
+ <p contenteditable="false"${u(m(st, i.pStyle))}>${x(n.pricePlaceholder, i)}</p>
180
+ </td>
181
+ `, p = ($) => `
182
+ <td${f(c.align)} valign="middle"
183
+ class="esd-block-text product-old-price ${$}"
184
+ esd-extension-block-id="${g.OLD_PRICE}"${u(c.tdStyle)}>
185
+ <p contenteditable="false"${u(m(j, c.pStyle))}>
186
+ <s>${x(n.oldPricePlaceholder, c)}</s>
187
+ </p>
188
+ </td>
189
+ `, d = s ? p("es-p15l es-p5r") : a("es-p15l es-p5r"), b = s ? a("es-p5l es-p15r") : p("es-p5l es-p15r");
190
+ return `
191
+ ${R(o, 'valign="top" style="padding: 0 5px; height: 100%"')}>
192
+ <table width="100%" height="100%" cellpadding="0" cellspacing="0" border="0"
193
+ class="product-card-segment"${l}>
194
+ <tbody>
195
+ <tr valign="top">
196
+ <td align="center">
197
+ <table cellpadding="0" cellspacing="0" border="0" align="center" style="margin: 0 auto">
198
+ <tbody>
199
+ <tr valign="middle">${d}${b}</tr>
200
+ </tbody>
201
+ </table>
202
+ </td>
203
+ </tr>
204
+ </tbody>
205
+ </table>
206
+ </td>
207
+ `;
208
+ }
209
+ function Pt(t, e, o, n, s, l, i) {
210
+ const c = e[t], a = c ?? P();
211
+ if (i.inlinePrice && t === i.inlinePrice.anchor)
212
+ return Tt(e, n, l, i, i.inlinePrice.originalFirst);
170
213
  switch (t) {
171
- case I:
172
- return at(
214
+ case L:
215
+ return St(
173
216
  c ?? {},
174
- l,
175
217
  s,
176
- n
218
+ n,
219
+ l
177
220
  );
178
- case j:
179
- return G(
221
+ case q:
222
+ return F(
180
223
  g.NAME,
181
- "product-name es-p10t es-p10b es-p15l es-p15r",
224
+ `product-name es-p10t es-p10b es-p15l es-p15r${D(a)}`,
182
225
  "Product Name",
183
226
  "font-size: 16px; color: #333333",
184
227
  a,
185
- s,
186
- n
228
+ n,
229
+ l
187
230
  );
188
- case V:
189
- return G(
231
+ case v:
232
+ return F(
190
233
  g.PRICE,
191
234
  "product-price es-p15l es-p15r",
192
235
  i.pricePlaceholder,
193
236
  "font-size: 16px; color: #333333",
194
- et(c),
195
- s,
196
- n
237
+ G(c),
238
+ n,
239
+ l
197
240
  );
198
- case Y:
199
- return dt(a, s, n, i.oldPricePlaceholder);
200
- case M:
201
- return z(
241
+ case k:
242
+ return ht(a, n, l, i.oldPricePlaceholder);
243
+ case H:
244
+ return K(
202
245
  g.OMNIBUS_PRICE,
203
246
  "omnibus-price-value",
204
247
  i.omnibusPricePlaceholder,
205
248
  a,
206
- s,
249
+ n,
207
250
  "product-omnibus-price",
208
- n
251
+ l
209
252
  );
210
- case F:
211
- return z(
253
+ case Q:
254
+ return K(
212
255
  g.OMNIBUS_DISCOUNT,
213
256
  "omnibus-discount-value",
214
257
  "-10%",
215
258
  a,
216
- s,
259
+ n,
217
260
  "product-omnibus-discount",
218
- n
261
+ l
219
262
  );
220
- case O:
221
- return pt(
222
- l,
223
- c ?? {},
263
+ case U:
264
+ return xt(
224
265
  s,
225
- n
266
+ c ?? {},
267
+ n,
268
+ l
226
269
  );
227
270
  default:
228
- if (t.startsWith(K)) {
229
- const d = e[t] ?? J(t), p = X(d);
230
- return ut(d, p, a, s, n);
271
+ if (t.startsWith(Z)) {
272
+ const p = o[t] ?? W(t), d = tt(p);
273
+ return Ct(p, d, a, n, l);
231
274
  }
232
275
  return null;
233
276
  }
234
277
  }
235
- const ot = `
278
+ const rt = `
236
279
  <tr>
237
280
  <td class="spacer" style="height: 10px"></td>
238
281
  </tr>
239
282
  `;
240
- function gt(t) {
283
+ function wt(t) {
241
284
  return {
242
- pricePlaceholder: B({ price: 18, currency: t }),
243
- oldPricePlaceholder: B({ price: 20, currency: t }),
244
- omnibusPricePlaceholder: B({ price: 20, currency: t })
285
+ pricePlaceholder: V({ price: 18, currency: t }),
286
+ oldPricePlaceholder: V({ price: 20, currency: t }),
287
+ omnibusPricePlaceholder: V({ price: 20, currency: t })
245
288
  };
246
289
  }
247
- function mt(t, o, e, s) {
248
- const { composition: l, visibility: n, perElement: i, customAttrValues: c, cardBg: a } = s, d = (100 / e).toFixed(2), p = e - o, b = `<td class="${Q}" style="padding: 0 5px;" width="${d}%"></td>`, m = p > 0 ? b.repeat(p) : "";
290
+ function At(t, e, o) {
291
+ const n = e.includes(v) && e.includes(k), l = o[v] !== !1 === (o[k] !== !1);
292
+ return t || !n || !l ? null : gt(e);
293
+ }
294
+ function _t(t, e, o, n) {
295
+ const { composition: s, visibility: l, perElement: i, customAttrValues: c, cardBg: a } = n, p = (100 / o).toFixed(2), d = o - e, b = `<td class="${ot}" style="padding: 0 5px;" width="${p}%"></td>`, $ = d > 0 ? b.repeat(d) : "";
249
296
  return `
250
297
  <tr class="recommendation-product-row">
251
298
  <td>
252
299
  <table width="100%" height="100%" cellpadding="0" cellspacing="0" border="0"
253
300
  class="product-card-wrapper" style="table-layout: fixed">
254
- <tbody>${l.map((w) => {
255
- const C = n[w] !== !1, S = C ? "" : ' style="display: none"', A = C ? "1" : "0", x = [];
256
- for (let T = 0; T < o; T += 1) {
257
- const E = bt(
258
- w,
301
+ <tbody>${s.filter((C) => {
302
+ var y;
303
+ return C !== ((y = n.inlinePrice) == null ? void 0 : y.skip);
304
+ }).map((C) => {
305
+ const y = l[C] !== !1, T = y ? "" : ' style="display: none"', I = y ? "1" : "0", A = [];
306
+ for (let _ = 0; _ < e; _ += 1) {
307
+ const E = Pt(
308
+ C,
259
309
  i,
260
310
  c,
261
311
  a,
262
- t + T,
263
- d,
264
- s
312
+ t + _,
313
+ p,
314
+ n
265
315
  );
266
- E && x.push(E);
316
+ E && A.push(E);
267
317
  }
268
- return x.length === 0 ? "" : `
318
+ return A.length === 0 ? "" : `
269
319
  <tr class="recommendation-attribute-row"
270
- data-attribute-type="${r(w)}"
271
- data-visibility="${A}"${S}>
272
- ${x.join("")}${m}
320
+ data-attribute-type="${r(C)}"
321
+ data-visibility="${I}"${T}>
322
+ ${A.join("")}${$}
273
323
  </tr>
274
324
  `;
275
325
  }).filter(Boolean).join("")}</tbody>
@@ -278,49 +328,67 @@ function mt(t, o, e, s) {
278
328
  </tr>
279
329
  `;
280
330
  }
281
- function $t(t, o, e) {
282
- const s = [];
283
- for (let l = 0; l < t; l += o) {
284
- const n = Math.min(o, t - l);
285
- l > 0 && s.push(ot), s.push(mt(l, n, o, e));
331
+ function X(t, e, o) {
332
+ const n = [];
333
+ for (let s = 0; s < t; s += e) {
334
+ const l = Math.min(e, t - s);
335
+ s > 0 && n.push(rt), n.push(_t(s, l, e, o));
286
336
  }
287
- return s.join("");
337
+ return n.join("");
338
+ }
339
+ function Rt(t, e, o) {
340
+ const n = G(t[v]), s = t[k] ?? P(), l = (c) => `
341
+ <td class="esd-block-text product-price" esd-extension-block-id="${g.PRICE}"
342
+ ${f(n.align ?? "left")} valign="middle"
343
+ ${u(m(`width: auto${c}`, n.tdStyle))}>
344
+ <p contenteditable="false"${u(m(`${st}; margin: 0`, n.pStyle))}>${x(e.pricePlaceholder, n)}</p>
345
+ </td>
346
+ `, i = (c) => `
347
+ <td class="esd-block-text product-old-price" esd-extension-block-id="${g.OLD_PRICE}"
348
+ ${f(s.align ?? "left")} valign="middle"
349
+ ${u(m(`width: auto${c}`, s.tdStyle))}>
350
+ <p contenteditable="false"${u(m(ct, s.pStyle))}>${`<s>${x(e.oldPricePlaceholder, s)}</s>`}</p>
351
+ </td>
352
+ `;
353
+ return o ? i("; padding-right: 8px") + l("") : l("; padding-right: 8px") + i("");
288
354
  }
289
- function ft(t, o, e, s) {
290
- const l = o[t];
291
- if (t === j) {
292
- const n = l ?? _(), i = $("font-size: 16px; color: #333333; margin: 0", n.pStyle), c = f(n.align ?? "left");
355
+ function It(t, e, o, n) {
356
+ const s = e[t];
357
+ if (n.inlinePrice && t === n.inlinePrice.anchor)
358
+ return Rt(e, n, n.inlinePrice.originalFirst);
359
+ if (t === q) {
360
+ const l = s ?? P(), i = m("font-size: 16px; color: #333333; margin: 0", l.pStyle), c = f(l.align ?? "left");
293
361
  return `
294
- <td class="esd-block-text product-name"
295
- esd-extension-block-id="${g.NAME}"${c}${u(n.tdStyle)}>
296
- <p contenteditable="false"${u(i)}>${N("Product Name", n)}</p>
362
+ <td class="esd-block-text product-name${D(l)}"
363
+ esd-extension-block-id="${g.NAME}"${c}${u(l.tdStyle)}>
364
+ <p contenteditable="false"${u(i)}>${x("Product Name", l)}</p>
297
365
  </td>
298
366
  `;
299
367
  }
300
- if (t === V) {
301
- const n = et(l), i = $("font-size: 16px; color: #333333; margin: 0", n.pStyle), c = f(n.align ?? "left");
368
+ if (t === v) {
369
+ const l = G(s), i = m("font-size: 16px; color: #333333; margin: 0", l.pStyle), c = f(l.align ?? "left");
302
370
  return `
303
371
  <td class="esd-block-text product-price"
304
- esd-extension-block-id="${g.PRICE}"${c}${u(n.tdStyle)}>
305
- <p contenteditable="false"${u(i)}>${N(s.pricePlaceholder, n)}</p>
372
+ esd-extension-block-id="${g.PRICE}"${c}${u(l.tdStyle)}>
373
+ <p contenteditable="false"${u(i)}>${x(n.pricePlaceholder, l)}</p>
306
374
  </td>
307
375
  `;
308
376
  }
309
- if (t === Y) {
310
- const n = l ?? _(), c = $("font-size: 14px; color: #999999; text-decoration: line-through; margin: 0", n.pStyle), a = f(n.align ?? "left");
377
+ if (t === k) {
378
+ const l = s ?? P(), i = m(ct, l.pStyle), c = f(l.align ?? "left");
311
379
  return `
312
380
  <td class="esd-block-text product-old-price"
313
- esd-extension-block-id="${g.OLD_PRICE}"${a}${u(n.tdStyle)}>
314
- <p contenteditable="false"${u(c)}><s>${N(s.oldPricePlaceholder, n)}</s></p>
381
+ esd-extension-block-id="${g.OLD_PRICE}"${c}${u(l.tdStyle)}>
382
+ <p contenteditable="false"${u(i)}><s>${x(n.oldPricePlaceholder, l)}</s></p>
315
383
  </td>
316
384
  `;
317
385
  }
318
- if (t === M || t === F) {
319
- const n = t === M, i = n ? g.OMNIBUS_PRICE : g.OMNIBUS_DISCOUNT, c = n ? "omnibus-price-value" : "omnibus-discount-value", a = n ? s.omnibusPricePlaceholder : "-10%", d = n ? "product-omnibus-price" : "product-omnibus-discount", p = l ?? _(), b = $("font-size: 12px; color: #666666; margin: 0", p.pStyle), m = f(p.align ?? "left");
386
+ if (t === H || t === Q) {
387
+ const l = t === H, i = l ? g.OMNIBUS_PRICE : g.OMNIBUS_DISCOUNT, c = l ? "omnibus-price-value" : "omnibus-discount-value", a = l ? n.omnibusPricePlaceholder : "-10%", p = l ? "product-omnibus-price" : "product-omnibus-discount", d = s ?? P(), b = m("font-size: 12px; color: #666666; margin: 0", d.pStyle), $ = f(d.align ?? "left");
320
388
  return `
321
- <td class="esd-block-text ${d}"
389
+ <td class="esd-block-text ${p}"
322
390
  data-text-before="" data-text-after=""
323
- esd-extension-block-id="${i}"${m}${u(p.tdStyle)}>
391
+ esd-extension-block-id="${i}"${$}${u(d.tdStyle)}>
324
392
  <p contenteditable="false"${u(b)}>
325
393
  <span class="omnibus-text-before"></span>
326
394
  <span class="${c}">${r(a)}</span>
@@ -329,56 +397,59 @@ function ft(t, o, e, s) {
329
397
  </td>
330
398
  `;
331
399
  }
332
- if (t.startsWith(K)) {
333
- const n = l ?? _(), i = e[t] ?? J(t), a = X(i).replace(/_/g, " ").replace(/\b\w/g, (m) => m.toUpperCase()), d = $("font-size: 12px; color: #666666; margin: 0", n.pStyle), p = f(n.align ?? "left"), b = g.CUSTOM_ATTRIBUTE;
400
+ if (t.startsWith(Z)) {
401
+ const l = s ?? P(), i = o[t] ?? W(t), a = tt(i).replace(/_/g, " ").replace(/\b\w/g, ($) => $.toUpperCase()), p = m("font-size: 12px; color: #666666; margin: 0", l.pStyle), d = f(l.align ?? "left"), b = g.CUSTOM_ATTRIBUTE;
334
402
  return `
335
403
  <td product-attr="${r(i)}"
336
- class="esd-block-text product-custom-attribute"
337
- esd-extension-block-id="${b}"${p}${u(n.tdStyle)}>
338
- <p contenteditable="false"${u(d)}>${r(a)}</p>
404
+ class="esd-block-text product-custom-attribute${D(l)}"
405
+ esd-extension-block-id="${b}"${d}${u(l.tdStyle)}>
406
+ <p contenteditable="false"${u(p)}>${r(a)}</p>
339
407
  </td>
340
408
  `;
341
409
  }
342
410
  return null;
343
411
  }
344
- function yt(t, o) {
345
- const { composition: e, visibility: s, perElement: l, customAttrValues: n, cardBg: i } = o, c = i ? `background-color: ${r(i)}` : "", a = c ? `style="table-layout: fixed; ${c}"` : 'style="table-layout: fixed"', d = l[I] ?? {}, p = s[I] !== !1, b = d.width ? ` width="${d.width}"` : "", m = p ? "" : ' style="display: none"', h = `
412
+ function Et(t, e) {
413
+ const { composition: o, visibility: n, perElement: s, customAttrValues: l, cardBg: i } = e, c = i ? `background-color: ${r(i)}` : "", a = c ? `style="table-layout: fixed; ${c}"` : 'style="table-layout: fixed"', p = s[L] ?? {}, d = n[L] !== !1, b = p.width ? ` width="${p.width}"` : "", $ = d ? "" : ' style="display: none"', w = `
346
414
  <td width="120"
347
415
  class="esd-block-image product-image-cell recommendation-attribute-row es-p5"
348
416
  esd-extension-block-id="${g.IMAGE}"
349
- data-attribute-type="${I}"
350
- data-visibility="${p ? "1" : "0"}"
351
- align="center" valign="middle"${m}>
417
+ data-attribute-type="${L}"
418
+ data-visibility="${d ? "1" : "0"}"
419
+ align="center" valign="middle"${$}>
352
420
  <a target="_blank" href="https://example.com/product/${t + 1}">
353
- <img src="${q}" alt="Product Name"
421
+ <img src="${et}" alt="Product Name"
354
422
  class="adapt-img product-image"${b}
355
423
  style="display: block; max-width: 100%; height: auto">
356
424
  </a>
357
425
  </td>
358
- `, C = `
426
+ `, y = `
359
427
  <td class="product-info-cell" valign="middle" style="padding: 15px">
360
428
  <table cellpadding="0" cellspacing="0" role="presentation" width="100%"
361
429
  style="table-layout: fixed">
362
- <tbody>${e.filter((y) => y !== I && y !== O).map((y) => {
363
- const v = s[y] !== !1, L = v ? "" : ' style="display: none"', nt = v ? "1" : "0", D = ft(y, l, n, o);
364
- return D ? `<tr class="recommendation-attribute-row"
365
- data-attribute-type="${r(y)}"
366
- data-visibility="${nt}"${L}>${D}</tr>` : "";
430
+ <tbody>${o.filter((S) => {
431
+ var h;
432
+ return S !== L && S !== U && S !== ((h = e.inlinePrice) == null ? void 0 : h.skip);
433
+ }).map((S) => {
434
+ const h = n[S] !== !1, N = h ? "" : ' style="display: none"', B = h ? "1" : "0", M = It(S, s, l, e);
435
+ return M ? `<tr class="recommendation-attribute-row"
436
+ data-attribute-type="${r(S)}"
437
+ data-visibility="${B}"${N}>${M}</tr>` : "";
367
438
  }).filter(Boolean).join(`
368
439
  `)}</tbody>
369
440
  </table>
370
441
  </td>
371
- `, S = l[O] ?? {}, A = s[O] !== !1, x = S.text || Z, T = $(W, S.spanStyle ?? ""), E = $(tt, S.aStyle ?? ""), U = A ? "" : ' style="display: none"', k = `
442
+ `, T = s[U] ?? {}, I = n[U] !== !1, A = T.text || nt, _ = m(lt, T.spanStyle ?? ""), E = m(it, T.aStyle ?? ""), z = I ? "" : ' style="display: none"', Y = `
372
443
  <td width="100"
373
444
  class="esd-block-button button-cell recommendation-attribute-row product-button es-p5l es-p5r"
374
445
  esd-extension-block-id="${g.BUTTON}"
375
- data-attribute-type="${O}"
376
- data-visibility="${A ? "1" : "0"}"
377
- align="${r(S.align ?? "center")}" valign="middle"${U}>
378
- <span class="es-button-border" style="${r(T)}">
446
+ data-attribute-type="${U}"
447
+ data-visibility="${I ? "1" : "0"}"
448
+ align="${r(T.align ?? "center")}" valign="middle"${z}>
449
+ <span class="es-button-border" style="${r(_)}">
379
450
  <a href="https://example.com/product/${t + 1}" target="_blank"
380
- class="es-button ${H}"
381
- style="${r(E)}">${r(x)}</a>
451
+ class="es-button ${J}"
452
+ style="${r(E)}">${r(A)}</a>
382
453
  </span>
383
454
  </td>
384
455
  `;
@@ -388,64 +459,71 @@ function yt(t, o) {
388
459
  <table width="100%" cellpadding="0" cellspacing="0" border="0"
389
460
  class="product-card-wrapper" ${a}>
390
461
  <tbody>
391
- <tr>${h}${C}${k}</tr>
462
+ <tr>${w}${y}${Y}</tr>
392
463
  </tbody>
393
464
  </table>
394
465
  </td>
395
466
  </tr>
396
467
  `;
397
468
  }
398
- function St(t, o) {
399
- const e = [];
400
- for (let s = 0; s < t; s += 1)
401
- s > 0 && e.push(ot), e.push(yt(s, o));
402
- return e.join("");
469
+ function Ot(t, e) {
470
+ const o = [];
471
+ for (let n = 0; n < t; n += 1)
472
+ n > 0 && o.push(rt), o.push(Et(n, e));
473
+ return o.join("");
403
474
  }
404
- function ht(t, o) {
405
- var a, d, p, b, m, h;
406
- const e = t == null ? void 0 : t.theme, s = [];
407
- (a = e == null ? void 0 : e.textStyle) != null && a["font-family"] && s.push(`font-family: ${e.textStyle["font-family"]}`), s.push(`font-size: ${((d = e == null ? void 0 : e.textStyle) == null ? void 0 : d["font-size"]) ?? "28px"}`), s.push(`color: ${((p = e == null ? void 0 : e.textColor) == null ? void 0 : p.color) ?? "#333333"}`), (b = e == null ? void 0 : e.textStyle) != null && b["font-weight"] && s.push(`font-weight: ${e.textStyle["font-weight"]}`), (m = e == null ? void 0 : e.textStyle) != null && m["font-style"] && s.push(`font-style: ${e.textStyle["font-style"]}`);
408
- const l = s.join("; "), n = ((h = e == null ? void 0 : e.textStyle) == null ? void 0 : h["font-weight"]) !== "normal", i = r(o), c = n ? `<strong>${i}</strong>` : i;
409
- return `<p${u(l)}>${c}</p>`;
475
+ function vt(t, e) {
476
+ var a, p, d, b, $, w;
477
+ const o = t == null ? void 0 : t.theme, n = [];
478
+ (a = o == null ? void 0 : o.textStyle) != null && a["font-family"] && n.push(`font-family: ${o.textStyle["font-family"]}`), n.push(`font-size: ${((p = o == null ? void 0 : o.textStyle) == null ? void 0 : p["font-size"]) ?? "28px"}`), n.push(`color: ${((d = o == null ? void 0 : o.textColor) == null ? void 0 : d.color) ?? "#333333"}`), (b = o == null ? void 0 : o.textStyle) != null && b["font-weight"] && n.push(`font-weight: ${o.textStyle["font-weight"]}`), ($ = o == null ? void 0 : o.textStyle) != null && $["font-style"] && n.push(`font-style: ${o.textStyle["font-style"]}`);
479
+ const s = n.join("; "), l = ((w = o == null ? void 0 : o.textStyle) == null ? void 0 : w["font-weight"]) !== "normal", i = r(e), c = l ? `<strong>${i}</strong>` : i;
480
+ return `<p${u(s)}>${c}</p>`;
410
481
  }
411
- function xt(t) {
412
- const o = t.alignment === "before" ? "0" : "1";
413
- return ` ${R.CURRENCY}="${r(t.code)}" ${R.SYMBOL}="${r(t.symbol)}" ${R.ALIGNMENT}="${o}" ${R.THOUSAND_SEPARATOR}="${r(t.thousandSeparator)}" ${R.DECIMAL_SEPARATOR}="${r(t.decimalSeparator)}" ${R.DECIMAL_COUNT}="${t.decimalCount}"`;
482
+ function kt(t) {
483
+ const e = t.alignment === "before" ? "0" : "1";
484
+ return ` ${O.CURRENCY}="${r(t.code)}" ${O.SYMBOL}="${r(t.symbol)}" ${O.ALIGNMENT}="${e}" ${O.THOUSAND_SEPARATOR}="${r(t.thousandSeparator)}" ${O.DECIMAL_SEPARATOR}="${r(t.decimalSeparator)}" ${O.DECIMAL_COUNT}="${t.decimalCount}"`;
414
485
  }
415
- function Et(t) {
486
+ function Yt(t) {
416
487
  const {
417
- nodeConfig: o,
418
- composition: e,
419
- cardBg: s,
420
- titleText: l,
421
- extraClasses: n = "",
488
+ nodeConfig: e,
489
+ composition: o,
490
+ cardBg: n,
491
+ titleText: s,
492
+ extraClasses: l = "",
422
493
  legacyId: i,
423
494
  legacyBgColor: c,
424
495
  preserveInnerHtml: a,
425
- skipCompile: d = !1
426
- } = t, p = o.layout === "list" ? ' data-layout="list"' : "", b = o.layout === "list" ? " es-m-p0 ins-recommendation-list-layout" : "", m = e.composition.join(","), h = JSON.stringify(e.customAttributes), w = [
496
+ skipCompile: p = !1,
497
+ blockPadding: d
498
+ } = t, b = e.layout === "list" ? ' data-layout="list"' : "", $ = e.layout === "list" ? " es-m-p0 ins-recommendation-list-layout" : "", w = o.composition.join(","), C = JSON.stringify(o.customAttributes), y = [
427
499
  "recommendation-block-v2",
428
500
  "esd-block-recommendation-v3-block",
429
- `es-p20${b}`,
430
- `ins-recommendation-v3-block-${o.recommendationId}`,
501
+ `${d ? d.classes : "es-p20"}${$}`,
502
+ `ins-recommendation-v3-block-${e.recommendationId}`,
431
503
  // Marker class Stripo's block infrastructure uses to identify recommendation
432
504
  // blocks. Without it, certain Styles-panel controls (e.g. button "Fit to
433
505
  // Container") are suppressed even though every other selector matches.
434
506
  "esd-recommendation-block",
435
507
  "esd-extension-block",
436
508
  "esd-container-frame",
437
- "ins-recommendation-no-mobile-layout",
438
- d ? st : "",
439
- n
440
- ].filter(Boolean).join(" "), C = xt(o.currency), S = o.visibility[lt] !== !1, A = ` esd-ext-config="${r(JSON.stringify(o))}"`, x = i ? ` id="${r(i)}"` : "", T = c ? ` bgcolor="${r(c)}"` : "", U = a ?? (() => {
441
- const k = parseInt(o.size) || 6, y = {
442
- composition: e.composition,
443
- visibility: e.visibility,
444
- perElement: e.perElementStyles,
445
- customAttrValues: e.customAttrValues,
446
- cardBg: s,
447
- ...gt(o.currency)
448
- }, v = o.layout === "list" ? St(k, y) : $t(k, o.cardsInRow, y);
509
+ e.mobileLayoutEnabled ? "" : ut,
510
+ p ? dt : "",
511
+ l
512
+ ].filter(Boolean).join(" "), T = kt(e.currency), I = e.visibility[pt] !== !1, A = ` esd-ext-config="${r(JSON.stringify(e))}"`, _ = i ? ` id="${r(i)}"` : "", E = c ? ` bgcolor="${r(c)}"` : "", z = d != null && d.style ? ` style="${d.style}"` : "", S = a ?? (() => {
513
+ const h = parseInt(e.size) || 6, N = {
514
+ composition: o.composition,
515
+ visibility: o.visibility,
516
+ perElement: o.perElementStyles,
517
+ customAttrValues: o.customAttrValues,
518
+ cardBg: n,
519
+ ...wt(e.currency),
520
+ inlinePrice: At(
521
+ e.priceMovedToNextLine,
522
+ o.composition,
523
+ o.visibility
524
+ )
525
+ }, B = e.layout === "list", M = B ? Ot(h, N) : X(h, e.cardsInRow, N), at = e.mobileLayoutEnabled && !B ? `<td><table width="100%" cellpadding="0" cellspacing="0" border="0"
526
+ class="${ft}" style="display: none">${X(h, e.mobileCardsInRow, N)}</table></td>` : "";
449
527
  return `
450
528
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
451
529
  <tbody>
@@ -453,15 +531,15 @@ function Et(t) {
453
531
  <td align="center">
454
532
  <table class="container" width="100%" cellpadding="0" cellspacing="0" border="0">
455
533
  <tbody>
456
- ${S ? it(ht(e.titleVariable, l), !0, o.rowSpacing) : ""}
534
+ ${I ? $t(vt(o.titleVariable, s), !0, e.rowSpacing) : ""}
457
535
  <tr>
458
536
  <td>
459
537
  <table width="100%" cellpadding="0" cellspacing="0" border="0"
460
- class="${rt}">${v}
538
+ class="${mt}">${M}
461
539
  </table>
462
540
  </td>
463
541
  </tr>
464
- <tr class="ins-recommendation-mobile-row"></tr>
542
+ <tr class="ins-recommendation-mobile-row">${at}</tr>
465
543
  </tbody>
466
544
  </table>
467
545
  </td>
@@ -469,22 +547,22 @@ function Et(t) {
469
547
  </tbody>
470
548
  </table>`;
471
549
  })();
472
- return ct(`
550
+ return yt(`
473
551
  <td align="left"
474
552
  esd-extension-block-id="recommendation-block"
475
553
  width="520"
476
- class="${w}"${x}${T}
477
- recommendation-id="${o.recommendationId}"${C}
478
- data-card-composition="${r(m)}"
479
- data-custom-attributes="${r(h)}"
480
- data-column-spacing="${o.columnSpacing}"
481
- data-row-spacing="${o.rowSpacing}"
482
- data-mobile-column-spacing="${o.mobileColumnSpacing}"
483
- data-mobile-row-spacing="${o.mobileRowSpacing}"
484
- hide-price="${o.priceHideIfSameAsDiscounted}"${p}${A}>${U}
554
+ class="${y}"${_}${E}${z}
555
+ recommendation-id="${e.recommendationId}"${T}
556
+ data-card-composition="${r(w)}"
557
+ data-custom-attributes="${r(C)}"
558
+ data-column-spacing="${e.columnSpacing}"
559
+ data-row-spacing="${e.rowSpacing}"
560
+ data-mobile-column-spacing="${e.mobileColumnSpacing}"
561
+ data-mobile-row-spacing="${e.mobileRowSpacing}"
562
+ hide-price="${e.priceHideIfSameAsDiscounted}"${b}${A}>${S}
485
563
  </td>
486
564
  `);
487
565
  }
488
566
  export {
489
- Et as buildBlockHtml
567
+ Yt as buildBlockHtml
490
568
  };