@useinsider/guido 2.0.0-beta.9b144a9 → 2.0.0-beta.a4f9fa2
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 +2 -0
- package/dist/@types/config/schemas.js +9 -5
- package/dist/components/Guido.vue.js +1 -1
- package/dist/components/Guido.vue2.js +15 -17
- package/dist/components/organisms/email-preview/desktop-preview/DesktopPreview.vue.js +2 -2
- package/dist/components/organisms/email-preview/mobile-preview/ContentView.vue.js +5 -5
- package/dist/components/organisms/header/LeftSlot.vue.js +12 -12
- package/dist/components/organisms/header/LeftSlot.vue2.js +6 -6
- package/dist/composables/useStripo.js +57 -56
- package/dist/config/migrator/index.js +9 -8
- package/dist/config/migrator/itemsBlockMigrator.js +342 -0
- package/dist/extensions/Blocks/CouponBlock/constants.js +4 -0
- package/dist/extensions/Blocks/CouponBlock/controls/index.js +29 -0
- package/dist/extensions/Blocks/CouponBlock/extension.js +5 -4
- package/dist/extensions/Blocks/CouponBlock/settingsPanel.js +20 -14
- package/dist/extensions/Blocks/CouponBlock/template.js +22 -11
- package/dist/extensions/Blocks/Items/block.js +39 -40
- package/dist/extensions/Blocks/Items/controls/button/link.js +22 -29
- package/dist/extensions/Blocks/Items/controls/cardComposition.js +66 -46
- package/dist/extensions/Blocks/Items/controls/image/link.js +23 -30
- package/dist/extensions/Blocks/Items/controls/name/trimming.js +25 -25
- package/dist/extensions/Blocks/Items/controls/price/currencyLocation.js +19 -17
- package/dist/extensions/Blocks/Items/controls/price/currencySymbol.js +31 -29
- package/dist/extensions/Blocks/Items/controls/price/formattedPrice.js +36 -36
- package/dist/extensions/Blocks/Items/controls/price/hideDiscount.js +21 -19
- package/dist/extensions/Blocks/Items/controls/price/priceOrientation.js +29 -27
- package/dist/extensions/Blocks/Items/controls/price/singlePrice.js +93 -0
- package/dist/extensions/Blocks/Items/controls/settingsControl.js +152 -143
- package/dist/extensions/Blocks/Items/enums/controlEnums.js +2 -2
- package/dist/extensions/Blocks/Items/enums/productEnums.js +43 -45
- package/dist/extensions/Blocks/Items/enums/settingsEnums.js +4 -3
- package/dist/extensions/Blocks/Items/extension.js +7 -6
- package/dist/extensions/Blocks/Items/layouts/horizontal.html.js +58 -49
- package/dist/extensions/Blocks/Items/layouts/vertical.html.js +48 -59
- package/dist/extensions/Blocks/Items/settingsPanel.js +27 -26
- package/dist/extensions/Blocks/Items/store/items-block.js +11 -7
- package/dist/extensions/Blocks/Items/template.js +366 -129
- package/dist/extensions/Blocks/Items/utils/nodeConfigUtils.js +184 -0
- package/dist/extensions/Blocks/Recommendation/control.js +1 -1
- package/dist/extensions/Blocks/common-control.js +29 -30
- package/dist/extensions/Blocks/controlFactories.js +139 -118
- package/dist/guido.css +1 -1
- package/dist/node_modules/@stripoinc/ui-editor-extensions/dist/esm/index.js +370 -286
- package/dist/package.json.js +1 -1
- package/dist/services/stripoApi.js +6 -10
- package/dist/src/@types/config/schemas.d.ts +8 -0
- package/dist/src/composables/useConfig.d.ts +4 -0
- package/dist/src/config/migrator/itemsBlockMigrator.d.ts +6 -0
- package/dist/src/extensions/Blocks/CouponBlock/constants.d.ts +14 -0
- package/dist/src/extensions/Blocks/CouponBlock/controls/index.d.ts +108 -0
- package/dist/src/extensions/Blocks/CouponBlock/template.d.ts +1 -1
- package/dist/src/extensions/Blocks/Items/controls/button/link.d.ts +0 -2
- package/dist/src/extensions/Blocks/Items/controls/cardComposition.d.ts +9 -0
- package/dist/src/extensions/Blocks/Items/controls/image/link.d.ts +0 -2
- package/dist/src/extensions/Blocks/Items/controls/price/priceOrientation.d.ts +1 -1
- package/dist/src/extensions/Blocks/Items/controls/price/singlePrice.d.ts +18 -0
- package/dist/src/extensions/Blocks/Items/controls/settingsControl.d.ts +0 -4
- package/dist/src/extensions/Blocks/Items/enums/controlEnums.d.ts +1 -0
- package/dist/src/extensions/Blocks/Items/enums/productEnums.d.ts +24 -26
- package/dist/src/extensions/Blocks/Items/enums/settingsEnums.d.ts +1 -0
- package/dist/src/extensions/Blocks/Items/store/items-block.d.ts +2 -0
- package/dist/src/extensions/Blocks/Items/template.d.ts +22 -1
- package/dist/src/extensions/Blocks/Items/utils/nodeConfigUtils.d.ts +73 -0
- package/dist/src/extensions/Blocks/common-control.d.ts +9 -10
- package/dist/src/extensions/Blocks/controlFactories.d.ts +30 -7
- package/dist/src/stores/config.d.ts +34 -0
- package/dist/static/styles/components/narrow-panel.css.js +0 -10
- package/dist/utils/pairProductVariables.js +61 -58
- package/package.json +3 -3
- package/dist/extensions/Blocks/Items/utils/configBlockUtils.js +0 -17
- package/dist/extensions/Blocks/Items/utils/syncAttributeFromConfigBlock.js +0 -28
- package/dist/extensions/Blocks/Items/utils/syncAttributesFromConfigBlock.js +0 -76
- package/dist/extensions/Blocks/Items/utils/updateAttributes.js +0 -46
- package/dist/src/extensions/Blocks/Items/utils/configBlockUtils.d.ts +0 -23
- package/dist/src/extensions/Blocks/Items/utils/syncAttributeFromConfigBlock.d.ts +0 -32
- package/dist/src/extensions/Blocks/Items/utils/syncAttributesFromConfigBlock.d.ts +0 -50
- package/dist/src/extensions/Blocks/Items/utils/updateAttributes.d.ts +0 -8
|
@@ -0,0 +1,184 @@
|
|
|
1
|
+
import { ModificationDescription as b } from "../../../../node_modules/@stripoinc/ui-editor-extensions/dist/esm/index.js";
|
|
2
|
+
import { DefaultConfigValues as r, SETTINGS_ENUMS as n, ItemInCartOptions as g } from "../enums/settingsEnums.js";
|
|
3
|
+
function d() {
|
|
4
|
+
return String(Date.now() + Math.floor(Math.random() * 1e3));
|
|
5
|
+
}
|
|
6
|
+
function f() {
|
|
7
|
+
return {
|
|
8
|
+
initialized: !0,
|
|
9
|
+
blockInstanceId: d(),
|
|
10
|
+
source: n.ITEMS_TYPE.CART_ITEMS,
|
|
11
|
+
type: n.ITEMS_TYPE.CART_ITEMS,
|
|
12
|
+
itemsSelectValue: r.cartItemsSelectControlValue,
|
|
13
|
+
orientation: n.ORIENTATION.VERTICAL,
|
|
14
|
+
nameTrimming: r.productNameTrimmingControlValue === "1",
|
|
15
|
+
nameControlEnabled: r.productNameControlEnabled === "1",
|
|
16
|
+
priceHideDiscount: r.productPriceHideDiscountControlValue === "1",
|
|
17
|
+
priceFormatted: r.productPriceFormattedControlValue === "1",
|
|
18
|
+
priceSinglePrice: !1,
|
|
19
|
+
priceCurrencySymbol: r.productPriceCurrencySymbolControlValue,
|
|
20
|
+
priceCurrencyLocation: r.productPriceCurrencyLocationControlValue,
|
|
21
|
+
priceControlOpened: r.productPriceControlOpened === "1",
|
|
22
|
+
priceOrientation: "horizontal",
|
|
23
|
+
quantityControlEnabled: r.productQuantityControlEnabled === "1",
|
|
24
|
+
buttonLink: r.productButtonLinkControlValue,
|
|
25
|
+
imageLink: r.productImageLinkControlValue,
|
|
26
|
+
buttonLabel: "Buy",
|
|
27
|
+
buttonFullWidth: !0,
|
|
28
|
+
// Default to full width (es-fw class)
|
|
29
|
+
imageVisible: r.productImageVisible === "1",
|
|
30
|
+
nameVisible: r.productNameVisible === "1",
|
|
31
|
+
quantityVisible: r.productQuantityVisible === "1",
|
|
32
|
+
priceVisible: r.productPriceVisible === "1",
|
|
33
|
+
originalPriceVisible: r.productOriginalPriceVisible === "1",
|
|
34
|
+
buttonVisible: r.productButtonVisible === "1"
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
function p(o) {
|
|
38
|
+
if (!o)
|
|
39
|
+
return null;
|
|
40
|
+
const t = o.closest(".items-block-v2");
|
|
41
|
+
return t || o.closest(".esd-cart-items-block");
|
|
42
|
+
}
|
|
43
|
+
function m(o) {
|
|
44
|
+
return o ? {
|
|
45
|
+
CartItems: n.ITEMS_TYPE.CART_ITEMS,
|
|
46
|
+
BrowsedItems: n.ITEMS_TYPE.BROWSED_ITEMS,
|
|
47
|
+
PurchasedItems: n.ITEMS_TYPE.PURCHASED_ITEMS,
|
|
48
|
+
// Also handle already correct formats
|
|
49
|
+
CART_ITEMS: n.ITEMS_TYPE.CART_ITEMS,
|
|
50
|
+
BROWSED_ITEMS: n.ITEMS_TYPE.BROWSED_ITEMS,
|
|
51
|
+
PURCHASED_ITEMS: n.ITEMS_TYPE.PURCHASED_ITEMS
|
|
52
|
+
}[o] || n.ITEMS_TYPE.CART_ITEMS : n.ITEMS_TYPE.CART_ITEMS;
|
|
53
|
+
}
|
|
54
|
+
function C(o, t) {
|
|
55
|
+
if (!o)
|
|
56
|
+
return r.cartItemsSelectControlValue;
|
|
57
|
+
if (o.includes("{{"))
|
|
58
|
+
return o;
|
|
59
|
+
if (/^\d+$/.test(o)) {
|
|
60
|
+
const e = parseInt(o) - 1, i = g[t];
|
|
61
|
+
if (i && i[e])
|
|
62
|
+
return i[e].value;
|
|
63
|
+
}
|
|
64
|
+
return r.cartItemsSelectControlValue;
|
|
65
|
+
}
|
|
66
|
+
function I(o) {
|
|
67
|
+
const t = o.querySelector("esd-config-block");
|
|
68
|
+
if (!t)
|
|
69
|
+
return null;
|
|
70
|
+
const e = (c, a) => c == null ? a : c === "1" || c === "true", i = (c, a) => c || a, l = t.getAttribute("data-type"), u = m(l), s = t.getAttribute("data-cart_items_select_control_value"), _ = C(s, u);
|
|
71
|
+
return {
|
|
72
|
+
initialized: e(t.getAttribute("data-initialized"), !1),
|
|
73
|
+
blockInstanceId: i(
|
|
74
|
+
t.getAttribute("data-block-instance-id"),
|
|
75
|
+
d()
|
|
76
|
+
),
|
|
77
|
+
source: u,
|
|
78
|
+
type: u,
|
|
79
|
+
itemsSelectValue: _,
|
|
80
|
+
orientation: t.getAttribute("data-card_orientation_control_value") || n.ORIENTATION.VERTICAL,
|
|
81
|
+
nameTrimming: e(
|
|
82
|
+
t.getAttribute("data-product_name_control_trim"),
|
|
83
|
+
!0
|
|
84
|
+
),
|
|
85
|
+
nameControlEnabled: e(
|
|
86
|
+
t.getAttribute("data-product_name_control_enabled"),
|
|
87
|
+
!0
|
|
88
|
+
),
|
|
89
|
+
priceHideDiscount: e(
|
|
90
|
+
t.getAttribute("data-product_price_control_nodup"),
|
|
91
|
+
!0
|
|
92
|
+
),
|
|
93
|
+
priceFormatted: e(
|
|
94
|
+
t.getAttribute("data-product_price_control_formated"),
|
|
95
|
+
!0
|
|
96
|
+
),
|
|
97
|
+
priceSinglePrice: e(
|
|
98
|
+
t.getAttribute("data-product_price_control_single_price"),
|
|
99
|
+
!1
|
|
100
|
+
),
|
|
101
|
+
priceCurrencySymbol: i(
|
|
102
|
+
t.getAttribute("data-product_price_currency_symbol"),
|
|
103
|
+
r.productPriceCurrencySymbolControlValue
|
|
104
|
+
),
|
|
105
|
+
priceCurrencyLocation: i(
|
|
106
|
+
t.getAttribute("data-product_price_currency_location"),
|
|
107
|
+
r.productPriceCurrencyLocationControlValue
|
|
108
|
+
),
|
|
109
|
+
priceControlOpened: e(
|
|
110
|
+
t.getAttribute("data-product_price_control_opened"),
|
|
111
|
+
!0
|
|
112
|
+
),
|
|
113
|
+
priceOrientation: t.getAttribute("data-product_original_price_control_orientation") || "horizontal",
|
|
114
|
+
quantityControlEnabled: e(
|
|
115
|
+
t.getAttribute("data-product_quantity_control_enabled"),
|
|
116
|
+
!0
|
|
117
|
+
),
|
|
118
|
+
buttonLink: i(
|
|
119
|
+
t.getAttribute("data-product_button_link"),
|
|
120
|
+
r.productButtonLinkControlValue
|
|
121
|
+
),
|
|
122
|
+
imageLink: i(
|
|
123
|
+
t.getAttribute("data-product_image_link"),
|
|
124
|
+
r.productImageLinkControlValue
|
|
125
|
+
),
|
|
126
|
+
buttonLabel: i(
|
|
127
|
+
t.getAttribute("data-product_button_control_label"),
|
|
128
|
+
"Buy"
|
|
129
|
+
),
|
|
130
|
+
buttonFullWidth: e(
|
|
131
|
+
t.getAttribute("data-product_button_control_atw"),
|
|
132
|
+
!0
|
|
133
|
+
// Default to full width
|
|
134
|
+
),
|
|
135
|
+
imageVisible: e(
|
|
136
|
+
t.getAttribute("data-product_image_control_enabled"),
|
|
137
|
+
!0
|
|
138
|
+
),
|
|
139
|
+
nameVisible: e(
|
|
140
|
+
t.getAttribute("data-product_name_control_enabled"),
|
|
141
|
+
!0
|
|
142
|
+
),
|
|
143
|
+
quantityVisible: e(
|
|
144
|
+
t.getAttribute("data-product_quantity_visible"),
|
|
145
|
+
!0
|
|
146
|
+
),
|
|
147
|
+
priceVisible: e(
|
|
148
|
+
t.getAttribute("data-product_price_visible"),
|
|
149
|
+
!0
|
|
150
|
+
),
|
|
151
|
+
originalPriceVisible: e(
|
|
152
|
+
t.getAttribute("data-product_original_price_control_enabled"),
|
|
153
|
+
!0
|
|
154
|
+
),
|
|
155
|
+
buttonVisible: e(
|
|
156
|
+
t.getAttribute("data-product_button_visible"),
|
|
157
|
+
!0
|
|
158
|
+
)
|
|
159
|
+
};
|
|
160
|
+
}
|
|
161
|
+
function S(o) {
|
|
162
|
+
const t = p(o);
|
|
163
|
+
if (!t)
|
|
164
|
+
return null;
|
|
165
|
+
const e = t.getNodeConfig();
|
|
166
|
+
if (e && e.initialized)
|
|
167
|
+
return e;
|
|
168
|
+
const i = I(t);
|
|
169
|
+
return i || null;
|
|
170
|
+
}
|
|
171
|
+
function A(o, t, e) {
|
|
172
|
+
const i = p(o);
|
|
173
|
+
if (!i)
|
|
174
|
+
return;
|
|
175
|
+
const u = { ...i.getNodeConfig() || {}, ...e };
|
|
176
|
+
t.getDocumentModifier().modifyHtml(i).setNodeConfig(u).apply(new b("Update Items block configuration"));
|
|
177
|
+
}
|
|
178
|
+
export {
|
|
179
|
+
d as generateBlockInstanceId,
|
|
180
|
+
f as getDefaultItemsBlockConfig,
|
|
181
|
+
S as getItemsBlockConfig,
|
|
182
|
+
p as getItemsBlockContainer,
|
|
183
|
+
A as setItemsBlockConfig
|
|
184
|
+
};
|
|
@@ -289,7 +289,7 @@ class b extends g {
|
|
|
289
289
|
t.CURRENCY_DECIMAL_COUNT
|
|
290
290
|
].forEach((i) => {
|
|
291
291
|
this.api.onValueChanged(i, (a) => this._onCurrencyConfigChange(i, a));
|
|
292
|
-
}), this.api.onValueChanged(t.PRODUCT_COUNT, (i) => this._onDataChange(t.PRODUCT_COUNT, i
|
|
292
|
+
}), this.api.onValueChanged(t.PRODUCT_COUNT, (i) => this._onDataChange(t.PRODUCT_COUNT, String(i))), this.api.onValueChanged(t.PRODUCT_IN_ROW, (i) => this._onDataChange(t.PRODUCT_IN_ROW, i)), this.api.onValueChanged(t.SHUFFLE_PRODUCTS, (i) => this._onDataChange(t.SHUFFLE_PRODUCTS, i)), this.api.onValueChanged(t.RESPONSIVE, (i) => this._onDataChange(t.RESPONSIVE, i)), this.addFilterListener = this._onFilterSelectClick.bind(this), this.addFilterButton = this.getContainer().querySelector("#guido__btn-add-filter"), (o = this.addFilterButton) == null || o.addEventListener("click", this.addFilterListener);
|
|
293
293
|
}
|
|
294
294
|
_listenStateUpdates() {
|
|
295
295
|
this.storeUnsubscription = this.store.$subscribe((e) => {
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
1
|
+
var I = Object.defineProperty;
|
|
2
|
+
var c = (T, r, e) => r in T ? I(T, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : T[r] = e;
|
|
3
|
+
var u = (T, r, e) => c(T, typeof r != "symbol" ? r + "" : r, e);
|
|
4
4
|
import { Control as O, UIElementType as t, UEAttr as $ } from "../../node_modules/@stripoinc/ui-editor-extensions/dist/esm/index.js";
|
|
5
5
|
class _ extends O {
|
|
6
6
|
constructor() {
|
|
7
7
|
super(...arguments);
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
u(this, "currentNode");
|
|
9
|
+
u(this, "lastBlockInstanceId", null);
|
|
10
10
|
}
|
|
11
11
|
getContainer() {
|
|
12
12
|
var e;
|
|
@@ -19,38 +19,37 @@ class _ extends O {
|
|
|
19
19
|
this.lastBlockInstanceId = null;
|
|
20
20
|
}
|
|
21
21
|
/**
|
|
22
|
-
* Gets the
|
|
23
|
-
* @returns The
|
|
22
|
+
* Gets the Items block container element from the current node.
|
|
23
|
+
* @returns The container element or null if not found
|
|
24
24
|
*/
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
return null;
|
|
28
|
-
const e = this.currentNode.closest(".items-block-v2");
|
|
29
|
-
return e ? e.querySelector("esd-config-block") : null;
|
|
25
|
+
getItemsBlockContainer() {
|
|
26
|
+
return this.currentNode ? this.currentNode.closest(".items-block-v2") : null;
|
|
30
27
|
}
|
|
31
28
|
/**
|
|
32
|
-
* Gets the current block instance ID from the config
|
|
33
|
-
* @param blockInstanceIdAttribute - The attribute name for block instance ID (default: 'data-block-instance-id')
|
|
29
|
+
* Gets the current block instance ID from the node config (Stripo V2).
|
|
34
30
|
* @returns The block instance ID or null if not found
|
|
35
31
|
*/
|
|
36
|
-
getBlockInstanceId(
|
|
37
|
-
const
|
|
38
|
-
|
|
32
|
+
getBlockInstanceId() {
|
|
33
|
+
const e = this.getItemsBlockContainer();
|
|
34
|
+
if (!e)
|
|
35
|
+
return null;
|
|
36
|
+
const n = e.getNodeConfig();
|
|
37
|
+
return n && typeof n.blockInstanceId == "string" ? n.blockInstanceId : null;
|
|
39
38
|
}
|
|
40
39
|
/**
|
|
41
40
|
* Handles block instance change detection and syncing.
|
|
42
|
-
* This is a helper method for controls that need to sync
|
|
43
|
-
*
|
|
41
|
+
* This is a helper method for controls that need to sync config when switching between block instances.
|
|
42
|
+
* Uses Stripo V2 nodeConfig API for block instance tracking.
|
|
43
|
+
* @param syncFunction - Function to call when block instance changes (to sync from node config)
|
|
44
44
|
* @param updateUI - Function to call to update the UI (called both on change and when same block)
|
|
45
|
-
* @param blockInstanceIdAttribute - The attribute name for block instance ID (default: 'data-block-instance-id')
|
|
46
45
|
* @returns true if block instance changed, false otherwise
|
|
47
46
|
*/
|
|
48
|
-
handleBlockInstanceChange(e, n
|
|
49
|
-
const
|
|
50
|
-
if (!
|
|
47
|
+
handleBlockInstanceChange(e, n) {
|
|
48
|
+
const E = this.getBlockInstanceId();
|
|
49
|
+
if (!E)
|
|
51
50
|
return !1;
|
|
52
|
-
const
|
|
53
|
-
return
|
|
51
|
+
const o = E !== this.lastBlockInstanceId;
|
|
52
|
+
return o ? (this.currentNode && e(this.currentNode), n(), this.lastBlockInstanceId = E) : n(), o;
|
|
54
53
|
}
|
|
55
54
|
_GuLabel({ text: e, name: n = "", position: E = "top" }) {
|
|
56
55
|
return `
|
|
@@ -81,7 +80,7 @@ class _ extends O {
|
|
|
81
80
|
class="${o}"
|
|
82
81
|
${$.SELECTPICKER.name}="${e}"
|
|
83
82
|
${$.SELECTPICKER.placeholder}="${n}">
|
|
84
|
-
${E.map((
|
|
83
|
+
${E.map((a) => this._GuSelectItem(a)).join("")}
|
|
85
84
|
</${t.SELECTPICKER}>
|
|
86
85
|
`;
|
|
87
86
|
}
|
|
@@ -169,11 +168,11 @@ class _ extends O {
|
|
|
169
168
|
*/
|
|
170
169
|
_GuOrderable(e, n) {
|
|
171
170
|
let E = "";
|
|
172
|
-
n.forEach((
|
|
173
|
-
const
|
|
171
|
+
n.forEach((a) => {
|
|
172
|
+
const l = $.ORDERABLE_ITEM && "name" in $.ORDERABLE_ITEM ? $.ORDERABLE_ITEM.name : "name";
|
|
174
173
|
E += `
|
|
175
|
-
<${t.ORDERABLE_ITEM} ${
|
|
176
|
-
${
|
|
174
|
+
<${t.ORDERABLE_ITEM} ${l}="${a.key}">
|
|
175
|
+
${a.content}
|
|
177
176
|
</${t.ORDERABLE_ITEM}>
|
|
178
177
|
`;
|
|
179
178
|
});
|
|
@@ -1,223 +1,244 @@
|
|
|
1
|
-
import { TextAlignBuiltInControl as
|
|
2
|
-
function
|
|
3
|
-
return class extends r {
|
|
4
|
-
getId() {
|
|
5
|
-
return e;
|
|
6
|
-
}
|
|
7
|
-
getTargetNodes(o) {
|
|
8
|
-
return o.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
9
|
-
}
|
|
10
|
-
};
|
|
11
|
-
}
|
|
12
|
-
function N(e, t, n = ".ins-recommendation-product-container") {
|
|
1
|
+
import { TextAlignBuiltInControl as l, TextColorBuiltInControl as s, TextSizeBuiltInControl as u, TextStyleBuiltInControl as i, TextFontFamilyBuiltInControl as c, ButtonBackgroundColorBuiltInControl as d, TextPaddingsBuiltInControl as a, ImageSizeBuiltInControl as g, ImageMarginsBuiltInControl as x, ButtonAlignBuiltInControl as C, ButtonBorderBuiltInControl as B, ButtonBorderRadiusBuiltInControl as T, ButtonColorBuiltInControl as I, ButtonFontFamilyBuiltInControl as f, ButtonMarginsBuiltInControl as y, ButtonPaddingsBuiltInControl as m, ButtonTextBuiltInControl as A, ButtonTextSizeBuiltInControl as S, ButtonTextStyleAndFontColorBuiltInControl as N, ButtonFitToContainerBuiltInControl as b, TextLineSpacingBuiltInControl as q } from "../../node_modules/@stripoinc/ui-editor-extensions/dist/esm/index.js";
|
|
2
|
+
function k(r, t, n) {
|
|
13
3
|
return class extends l {
|
|
14
4
|
getId() {
|
|
15
|
-
return
|
|
5
|
+
return r;
|
|
16
6
|
}
|
|
17
|
-
getTargetNodes(
|
|
18
|
-
return
|
|
7
|
+
getTargetNodes(e) {
|
|
8
|
+
return !t || !n ? [e] : e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
19
9
|
}
|
|
20
10
|
};
|
|
21
11
|
}
|
|
22
|
-
function
|
|
12
|
+
function p(r, t, n) {
|
|
23
13
|
return class extends s {
|
|
24
14
|
getId() {
|
|
25
|
-
return
|
|
15
|
+
return r;
|
|
26
16
|
}
|
|
27
|
-
getTargetNodes(
|
|
28
|
-
return
|
|
17
|
+
getTargetNodes(e) {
|
|
18
|
+
return !t || !n ? [e] : e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
29
19
|
}
|
|
30
20
|
};
|
|
31
21
|
}
|
|
32
|
-
function
|
|
33
|
-
return class extends
|
|
22
|
+
function F(r, t, n) {
|
|
23
|
+
return class extends u {
|
|
34
24
|
getId() {
|
|
35
|
-
return
|
|
25
|
+
return r;
|
|
36
26
|
}
|
|
37
|
-
getTargetNodes(
|
|
38
|
-
return
|
|
27
|
+
getTargetNodes(e) {
|
|
28
|
+
return !t || !n ? [e] : e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
39
29
|
}
|
|
40
30
|
};
|
|
41
31
|
}
|
|
42
|
-
function
|
|
43
|
-
return class extends
|
|
32
|
+
function z(r, t, n) {
|
|
33
|
+
return class extends i {
|
|
44
34
|
getId() {
|
|
45
|
-
return
|
|
35
|
+
return r;
|
|
46
36
|
}
|
|
47
|
-
getTargetNodes(
|
|
48
|
-
return
|
|
37
|
+
getTargetNodes(e) {
|
|
38
|
+
return !t || !n ? [e] : e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
49
39
|
}
|
|
50
40
|
};
|
|
51
41
|
}
|
|
52
|
-
function
|
|
53
|
-
return class extends
|
|
42
|
+
function M(r, t, n) {
|
|
43
|
+
return class extends c {
|
|
54
44
|
getId() {
|
|
55
|
-
return
|
|
45
|
+
return r;
|
|
56
46
|
}
|
|
57
|
-
getTargetNodes(
|
|
58
|
-
return
|
|
47
|
+
getTargetNodes(e) {
|
|
48
|
+
return !t || !n ? [e] : e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
59
49
|
}
|
|
60
50
|
};
|
|
61
51
|
}
|
|
62
|
-
function
|
|
52
|
+
function P(r, t, n) {
|
|
63
53
|
return class extends d {
|
|
64
54
|
getId() {
|
|
65
|
-
return
|
|
55
|
+
return r;
|
|
66
56
|
}
|
|
67
|
-
getTargetNodes(
|
|
68
|
-
return
|
|
57
|
+
getTargetNodes(e) {
|
|
58
|
+
return !t || !n ? [e] : e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
69
59
|
}
|
|
70
60
|
};
|
|
71
61
|
}
|
|
72
|
-
function
|
|
73
|
-
return class extends
|
|
62
|
+
function h(r, t, n) {
|
|
63
|
+
return class extends a {
|
|
74
64
|
getId() {
|
|
75
|
-
return
|
|
65
|
+
return r;
|
|
76
66
|
}
|
|
77
|
-
getTargetNodes(
|
|
78
|
-
return
|
|
67
|
+
getTargetNodes(e) {
|
|
68
|
+
return !t || !n ? [e] : e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
79
69
|
}
|
|
80
70
|
};
|
|
81
71
|
}
|
|
82
|
-
function
|
|
83
|
-
return class extends
|
|
72
|
+
function L(r, t, n) {
|
|
73
|
+
return class extends q {
|
|
84
74
|
getId() {
|
|
85
|
-
return
|
|
75
|
+
return r;
|
|
86
76
|
}
|
|
87
|
-
getTargetNodes(
|
|
88
|
-
return
|
|
77
|
+
getTargetNodes(e) {
|
|
78
|
+
return [e];
|
|
89
79
|
}
|
|
90
80
|
};
|
|
91
81
|
}
|
|
92
|
-
function
|
|
82
|
+
function R(r, t, n = ".ins-recommendation-product-container") {
|
|
93
83
|
return class extends C {
|
|
94
84
|
getId() {
|
|
95
|
-
return
|
|
85
|
+
return r;
|
|
96
86
|
}
|
|
97
|
-
getTargetNodes(
|
|
98
|
-
return
|
|
87
|
+
getTargetNodes(e) {
|
|
88
|
+
return e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
99
89
|
}
|
|
100
90
|
};
|
|
101
91
|
}
|
|
102
|
-
function j(
|
|
103
|
-
return class extends
|
|
92
|
+
function j(r, t, n = ".ins-recommendation-product-container") {
|
|
93
|
+
return class extends I {
|
|
104
94
|
getId() {
|
|
105
|
-
return
|
|
95
|
+
return r;
|
|
106
96
|
}
|
|
107
|
-
getTargetNodes(
|
|
108
|
-
return
|
|
97
|
+
getTargetNodes(e) {
|
|
98
|
+
return e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
109
99
|
}
|
|
110
100
|
};
|
|
111
101
|
}
|
|
112
|
-
function v(
|
|
113
|
-
return class extends
|
|
102
|
+
function v(r, t, n = ".ins-recommendation-product-container") {
|
|
103
|
+
return class extends B {
|
|
114
104
|
getId() {
|
|
115
|
-
return
|
|
105
|
+
return r;
|
|
116
106
|
}
|
|
117
|
-
getTargetNodes(
|
|
118
|
-
return
|
|
107
|
+
getTargetNodes(e) {
|
|
108
|
+
return e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
119
109
|
}
|
|
120
110
|
};
|
|
121
111
|
}
|
|
122
|
-
function w(
|
|
112
|
+
function w(r, t, n = ".ins-recommendation-product-container") {
|
|
123
113
|
return class extends T {
|
|
124
114
|
getId() {
|
|
125
|
-
return
|
|
115
|
+
return r;
|
|
126
116
|
}
|
|
127
|
-
getTargetNodes(
|
|
128
|
-
return
|
|
117
|
+
getTargetNodes(e) {
|
|
118
|
+
return e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
129
119
|
}
|
|
130
120
|
};
|
|
131
121
|
}
|
|
132
|
-
function D(
|
|
133
|
-
return class extends
|
|
122
|
+
function D(r, t, n = ".ins-recommendation-product-container") {
|
|
123
|
+
return class extends f {
|
|
134
124
|
getId() {
|
|
135
|
-
return
|
|
125
|
+
return r;
|
|
136
126
|
}
|
|
137
|
-
getTargetNodes(
|
|
138
|
-
return
|
|
127
|
+
getTargetNodes(e) {
|
|
128
|
+
return e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
139
129
|
}
|
|
140
130
|
};
|
|
141
131
|
}
|
|
142
|
-
function E(
|
|
132
|
+
function E(r, t, n = ".ins-recommendation-product-container") {
|
|
143
133
|
return class extends y {
|
|
144
134
|
getId() {
|
|
145
|
-
return
|
|
135
|
+
return r;
|
|
146
136
|
}
|
|
147
|
-
getTargetNodes(
|
|
148
|
-
return
|
|
137
|
+
getTargetNodes(e) {
|
|
138
|
+
return e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
149
139
|
}
|
|
150
140
|
};
|
|
151
141
|
}
|
|
152
|
-
function G(
|
|
142
|
+
function G(r, t, n = ".ins-recommendation-product-container") {
|
|
143
|
+
return class extends m {
|
|
144
|
+
getId() {
|
|
145
|
+
return r;
|
|
146
|
+
}
|
|
147
|
+
getTargetNodes(e) {
|
|
148
|
+
return e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
149
|
+
}
|
|
150
|
+
};
|
|
151
|
+
}
|
|
152
|
+
function H(r, t, n = ".ins-recommendation-product-container") {
|
|
153
153
|
return class extends A {
|
|
154
154
|
getId() {
|
|
155
|
-
return
|
|
155
|
+
return r;
|
|
156
156
|
}
|
|
157
|
-
getTargetNodes(
|
|
158
|
-
return
|
|
157
|
+
getTargetNodes(e) {
|
|
158
|
+
return e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
159
159
|
}
|
|
160
160
|
};
|
|
161
161
|
}
|
|
162
|
-
function
|
|
163
|
-
return class extends
|
|
162
|
+
function J(r, t, n = ".ins-recommendation-product-container") {
|
|
163
|
+
return class extends S {
|
|
164
164
|
getId() {
|
|
165
|
-
return
|
|
165
|
+
return r;
|
|
166
166
|
}
|
|
167
|
-
getTargetNodes(
|
|
168
|
-
return
|
|
167
|
+
getTargetNodes(e) {
|
|
168
|
+
return e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
169
169
|
}
|
|
170
170
|
};
|
|
171
171
|
}
|
|
172
|
-
function
|
|
173
|
-
return class extends
|
|
172
|
+
function K(r, t, n) {
|
|
173
|
+
return class extends N {
|
|
174
174
|
getId() {
|
|
175
|
-
return
|
|
175
|
+
return r;
|
|
176
176
|
}
|
|
177
|
-
getTargetNodes(
|
|
178
|
-
return
|
|
177
|
+
getTargetNodes(e) {
|
|
178
|
+
return e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
179
179
|
}
|
|
180
180
|
};
|
|
181
181
|
}
|
|
182
|
-
function
|
|
183
|
-
return class extends
|
|
182
|
+
function O(r, t, n) {
|
|
183
|
+
return class extends b {
|
|
184
184
|
getId() {
|
|
185
|
-
return
|
|
185
|
+
return r;
|
|
186
186
|
}
|
|
187
|
-
getTargetNodes(
|
|
188
|
-
return
|
|
187
|
+
getTargetNodes(e) {
|
|
188
|
+
return e.closest(n).querySelectorAll(`[esd-extension-block-id="${t}"]`);
|
|
189
189
|
}
|
|
190
190
|
};
|
|
191
191
|
}
|
|
192
|
-
function
|
|
192
|
+
function Q(r, t, n) {
|
|
193
193
|
return class extends g {
|
|
194
194
|
getId() {
|
|
195
|
-
return
|
|
195
|
+
return r;
|
|
196
|
+
}
|
|
197
|
+
getTargetNodes(e) {
|
|
198
|
+
try {
|
|
199
|
+
const o = e.closest(n);
|
|
200
|
+
return o ? o.querySelectorAll(`[esd-extension-block-id="${t}"]`) : [];
|
|
201
|
+
} catch {
|
|
202
|
+
return [];
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
};
|
|
206
|
+
}
|
|
207
|
+
function U(r, t, n) {
|
|
208
|
+
return class extends x {
|
|
209
|
+
getId() {
|
|
210
|
+
return r;
|
|
196
211
|
}
|
|
197
|
-
getTargetNodes(
|
|
198
|
-
|
|
212
|
+
getTargetNodes(e) {
|
|
213
|
+
try {
|
|
214
|
+
const o = e.closest(n);
|
|
215
|
+
return o ? o.querySelectorAll(`[esd-extension-block-id="${t}"]`) : [];
|
|
216
|
+
} catch {
|
|
217
|
+
return [];
|
|
218
|
+
}
|
|
199
219
|
}
|
|
200
220
|
};
|
|
201
221
|
}
|
|
202
222
|
export {
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
+
R as createButtonAlignControl,
|
|
224
|
+
v as createButtonBorderControl,
|
|
225
|
+
w as createButtonBorderRadiusControl,
|
|
226
|
+
j as createButtonColorControl,
|
|
227
|
+
O as createButtonFitToContainerControl,
|
|
228
|
+
D as createButtonFontFamilyControl,
|
|
229
|
+
E as createButtonMarginsControl,
|
|
230
|
+
G as createButtonPaddingsControl,
|
|
231
|
+
H as createButtonTextControl,
|
|
232
|
+
J as createButtonTextSizeControl,
|
|
233
|
+
K as createButtonTextStyleAndFontColorControl,
|
|
234
|
+
U as createImageMarginsControl,
|
|
235
|
+
Q as createImageSizeControl,
|
|
236
|
+
h as createPaddingsControl,
|
|
237
|
+
k as createTextAlignControl,
|
|
238
|
+
P as createTextBackgroundColorControl,
|
|
239
|
+
p as createTextColorControl,
|
|
240
|
+
M as createTextFontFamilyControl,
|
|
241
|
+
L as createTextLineSpacingControl,
|
|
242
|
+
F as createTextSizeControl,
|
|
243
|
+
z as createTextStyleControl
|
|
223
244
|
};
|