@useinsider/guido 2.0.0-beta.5ccd854 → 2.0.0-beta.689d09e
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 +55 -39
- package/dist/components/Guido.vue.js +1 -1
- package/dist/components/Guido.vue2.js +15 -17
- package/dist/components/organisms/header/LeftSlot.vue.js +12 -12
- package/dist/components/organisms/header/LeftSlot.vue2.js +6 -6
- package/dist/components/organisms/header/RightSlot.vue2.js +10 -10
- package/dist/composables/useConfig.js +29 -27
- package/dist/composables/useSave.js +13 -11
- package/dist/composables/useStripo.js +42 -40
- package/dist/config/migrator/itemsBlockMigrator.js +184 -125
- 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 +1 -1
- package/dist/extensions/Blocks/Items/controls/button/link.js +22 -29
- package/dist/extensions/Blocks/Items/controls/cardComposition.js +59 -36
- 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 +44 -38
- package/dist/extensions/Blocks/Items/controls/price/hideDiscount.js +21 -19
- package/dist/extensions/Blocks/Items/controls/price/priceOrientation.js +1 -1
- package/dist/extensions/Blocks/Items/controls/price/singlePrice.js +93 -0
- package/dist/extensions/Blocks/Items/controls/settingsControl.js +99 -95
- 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 +2 -1
- package/dist/extensions/Blocks/Items/extension.js +7 -6
- package/dist/extensions/Blocks/Items/layouts/horizontal.html.js +0 -1
- package/dist/extensions/Blocks/Items/layouts/vertical.html.js +0 -1
- package/dist/extensions/Blocks/Items/settingsPanel.js +27 -26
- package/dist/extensions/Blocks/Items/store/items-block.js +9 -5
- package/dist/extensions/Blocks/Items/template.js +285 -221
- package/dist/extensions/Blocks/Items/utils/nodeConfigUtils.js +94 -82
- package/dist/extensions/Blocks/Unsubscribe/extension.js +9 -9
- package/dist/extensions/Blocks/common-control.js +45 -57
- 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 +53 -48
- package/dist/package.json.js +7 -0
- package/dist/services/stripoApi.js +6 -10
- package/dist/src/@types/config/index.d.ts +2 -2
- package/dist/src/@types/config/schemas.d.ts +30 -0
- package/dist/src/@types/config/types.d.ts +7 -1
- package/dist/src/composables/useConfig.d.ts +8 -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/singlePrice.d.ts +18 -0
- 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 +3 -1
- package/dist/src/extensions/Blocks/Items/utils/nodeConfigUtils.d.ts +4 -2
- package/dist/src/extensions/Blocks/common-control.d.ts +1 -7
- package/dist/src/extensions/Blocks/controlFactories.d.ts +30 -7
- package/dist/src/stores/config.d.ts +164 -1
- package/dist/static/styles/components/button.css.js +1 -1
- package/dist/stores/config.js +7 -0
- package/dist/utils/pairProductVariables.js +61 -58
- package/package.json +1 -1
- 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 -67
- 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
|
@@ -1,28 +1,28 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { UEAttr as
|
|
5
|
-
import { CommonControl as
|
|
6
|
-
import { ItemsBlockId as
|
|
7
|
-
import { productPairs as
|
|
8
|
-
import { ItemTypeOptions as
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import { useItemsBlockStore as
|
|
12
|
-
import { getDefaultTemplate as
|
|
13
|
-
import { getItemsBlockConfig as
|
|
14
|
-
const
|
|
1
|
+
var L = Object.defineProperty;
|
|
2
|
+
var M = (h, d, e) => d in h ? L(h, d, { enumerable: !0, configurable: !0, writable: !0, value: e }) : h[d] = e;
|
|
3
|
+
var O = (h, d, e) => M(h, typeof d != "symbol" ? d + "" : d, e);
|
|
4
|
+
import { UEAttr as C, ModificationDescription as u } from "../../../../node_modules/@stripoinc/ui-editor-extensions/dist/esm/index.js";
|
|
5
|
+
import { CommonControl as D } from "../../common-control.js";
|
|
6
|
+
import { ItemsBlockId as m } from "../enums/controlEnums.js";
|
|
7
|
+
import { productPairs as p, templateFirstLine as b } from "../enums/productEnums.js";
|
|
8
|
+
import { ItemTypeOptions as R, OrientationOptions as x, ItemInCartOptions as N, SETTINGS_ENUMS as S, DefaultConfigValues as A } from "../enums/settingsEnums.js";
|
|
9
|
+
import H from "../layouts/horizontal.html.js";
|
|
10
|
+
import k from "../layouts/vertical.html.js";
|
|
11
|
+
import { useItemsBlockStore as U } from "../store/items-block.js";
|
|
12
|
+
import { getDefaultTemplate as F } from "../template.js";
|
|
13
|
+
import { getItemsBlockConfig as P, setItemsBlockConfig as f } from "../utils/nodeConfigUtils.js";
|
|
14
|
+
const $ = "ui-elements-items-block", a = {
|
|
15
15
|
ITEMS_TYPE: "itemsType",
|
|
16
16
|
ORIENTATION: "orientation",
|
|
17
17
|
ITEM_IDS: "itemIds"
|
|
18
18
|
};
|
|
19
|
-
class
|
|
19
|
+
class K extends D {
|
|
20
20
|
constructor() {
|
|
21
21
|
super(...arguments);
|
|
22
|
-
|
|
22
|
+
O(this, "store", U());
|
|
23
23
|
}
|
|
24
24
|
getId() {
|
|
25
|
-
return
|
|
25
|
+
return $;
|
|
26
26
|
}
|
|
27
27
|
getTemplate() {
|
|
28
28
|
return `
|
|
@@ -35,22 +35,22 @@ class j extends L {
|
|
|
35
35
|
}
|
|
36
36
|
onRender() {
|
|
37
37
|
this.api.updateValues({
|
|
38
|
-
[
|
|
39
|
-
[
|
|
40
|
-
[
|
|
38
|
+
[a.ORIENTATION]: this.store.orientation,
|
|
39
|
+
[a.ITEMS_TYPE]: this.store.itemsType,
|
|
40
|
+
[a.ITEM_IDS]: this.store.itemIds
|
|
41
41
|
}), this._listenToFormUpdates();
|
|
42
42
|
}
|
|
43
43
|
onTemplateNodeUpdated(e) {
|
|
44
|
-
super.onTemplateNodeUpdated(e), this.handleBlockInstanceChange(
|
|
44
|
+
super.onTemplateNodeUpdated(e), console.debug("Items Block Config", e.getNodeConfig()), this.handleBlockInstanceChange(
|
|
45
45
|
() => {
|
|
46
|
-
const t =
|
|
47
|
-
t && (this.store.setItemsType(t.type), this.store.setItemIds(t.itemsSelectValue), this.store.setOrientation(t.orientation), this.store.setCurrencySymbol(t.priceCurrencySymbol), this.store.setCurrencyLocation(t.priceCurrencyLocation), this.store.setFormattedPrice(t.priceFormatted));
|
|
46
|
+
const t = P(this.currentNode);
|
|
47
|
+
t && (this.store.setItemsType(t.type), this.store.setItemIds(t.itemsSelectValue), this.store.setOrientation(t.orientation), this.store.setCurrencySymbol(t.priceCurrencySymbol), this.store.setCurrencyLocation(t.priceCurrencyLocation), this.store.setFormattedPrice(t.priceFormatted), this.store.setImageLink(t.imageLink), this.store.setButtonLink(t.buttonLink));
|
|
48
48
|
},
|
|
49
49
|
() => {
|
|
50
50
|
this.api.updateValues({
|
|
51
|
-
[
|
|
52
|
-
[
|
|
53
|
-
[
|
|
51
|
+
[a.ORIENTATION]: this.store.orientation,
|
|
52
|
+
[a.ITEMS_TYPE]: this.store.itemsType,
|
|
53
|
+
[a.ITEM_IDS]: this.store.itemIds
|
|
54
54
|
}), this._initializeSelectItems();
|
|
55
55
|
}
|
|
56
56
|
);
|
|
@@ -64,10 +64,10 @@ class j extends L {
|
|
|
64
64
|
${this._GuOneColumn([
|
|
65
65
|
this._GuLabel({ text: "Item Type" }),
|
|
66
66
|
this._GuSelect({
|
|
67
|
-
name:
|
|
67
|
+
name: a.ITEMS_TYPE,
|
|
68
68
|
className: "es-100",
|
|
69
69
|
placeholder: "Select Item Type",
|
|
70
|
-
options:
|
|
70
|
+
options: R
|
|
71
71
|
})
|
|
72
72
|
])}
|
|
73
73
|
`;
|
|
@@ -77,8 +77,8 @@ class j extends L {
|
|
|
77
77
|
${this._GuTwoColumns([
|
|
78
78
|
this._GuLabel({ text: "Orientation" }),
|
|
79
79
|
this._GuRadioButton({
|
|
80
|
-
name:
|
|
81
|
-
buttons:
|
|
80
|
+
name: a.ORIENTATION,
|
|
81
|
+
buttons: x
|
|
82
82
|
})
|
|
83
83
|
])}
|
|
84
84
|
`;
|
|
@@ -88,7 +88,7 @@ class j extends L {
|
|
|
88
88
|
${this._GuTwoColumns([
|
|
89
89
|
this._GuLabel({ text: "Item in Cart" }),
|
|
90
90
|
this._GuSelect({
|
|
91
|
-
name:
|
|
91
|
+
name: a.ITEM_IDS,
|
|
92
92
|
className: "es-100",
|
|
93
93
|
placeholder: "Select Item In Cart",
|
|
94
94
|
options: []
|
|
@@ -97,7 +97,7 @@ class j extends L {
|
|
|
97
97
|
`;
|
|
98
98
|
}
|
|
99
99
|
_onOrientationChange(e) {
|
|
100
|
-
this.store.setOrientation(e), this.store.setPriceOrientation("horizontal"), this.api.updateValues({ [
|
|
100
|
+
this.store.setOrientation(e), this.store.setPriceOrientation("horizontal"), this.api.updateValues({ [a.ORIENTATION]: e }), f(this.currentNode, this.api, {
|
|
101
101
|
orientation: e,
|
|
102
102
|
priceOrientation: "horizontal"
|
|
103
103
|
}), this._reOrderTemplate(), setTimeout(() => {
|
|
@@ -109,42 +109,46 @@ class j extends L {
|
|
|
109
109
|
!t || !r || (this.store.setItemsType(t), this.store.setItemIds(r.value), f(this.currentNode, this.api, {
|
|
110
110
|
source: t,
|
|
111
111
|
type: t,
|
|
112
|
-
itemsSelectValue: r.value
|
|
112
|
+
itemsSelectValue: r.value,
|
|
113
|
+
imageLink: this.store.imageLink,
|
|
114
|
+
buttonLink: this.store.buttonLink
|
|
113
115
|
}), this._updateDataTypeAttributes(t), this._initializeSelectItems(), this._reFillTemplate());
|
|
114
116
|
}
|
|
115
117
|
_onItemIdsChange(e) {
|
|
116
|
-
this.store.setItemIds(e), this.api.updateValues({ [
|
|
117
|
-
itemsSelectValue: e
|
|
118
|
+
this.store.setItemIds(e), this.api.updateValues({ [a.ITEM_IDS]: e }), f(this.currentNode, this.api, {
|
|
119
|
+
itemsSelectValue: e,
|
|
120
|
+
imageLink: this.store.imageLink,
|
|
121
|
+
buttonLink: this.store.buttonLink
|
|
118
122
|
}), this._updateDataNumberAttributes(e), this._reFillTemplate();
|
|
119
123
|
}
|
|
120
124
|
_initializeSelectItems() {
|
|
121
125
|
this.api.setUIEAttribute(
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
126
|
+
a.ITEMS_TYPE,
|
|
127
|
+
C.SELECTPICKER.items,
|
|
128
|
+
R
|
|
125
129
|
);
|
|
126
130
|
const { itemsType: e, itemIds: t } = this.store;
|
|
127
131
|
this.api.updateValues({
|
|
128
|
-
[
|
|
132
|
+
[a.ITEMS_TYPE]: e
|
|
129
133
|
});
|
|
130
134
|
const i = N[e];
|
|
131
135
|
this.api.setUIEAttribute(
|
|
132
|
-
|
|
133
|
-
|
|
136
|
+
a.ITEM_IDS,
|
|
137
|
+
C.SELECTPICKER.items,
|
|
134
138
|
i
|
|
135
139
|
), this.api.updateValues({
|
|
136
|
-
[
|
|
140
|
+
[a.ITEM_IDS]: t
|
|
137
141
|
});
|
|
138
142
|
}
|
|
139
143
|
_listenToFormUpdates() {
|
|
140
144
|
this.api.onValueChanged(
|
|
141
|
-
|
|
145
|
+
a.ITEMS_TYPE,
|
|
142
146
|
(e) => this._onItemsTypeChange(e)
|
|
143
147
|
), this.api.onValueChanged(
|
|
144
|
-
|
|
148
|
+
a.ORIENTATION,
|
|
145
149
|
(e) => this._onOrientationChange(e)
|
|
146
150
|
), this.api.onValueChanged(
|
|
147
|
-
|
|
151
|
+
a.ITEM_IDS,
|
|
148
152
|
(e) => this._onItemIdsChange(e)
|
|
149
153
|
);
|
|
150
154
|
}
|
|
@@ -157,55 +161,55 @@ class j extends L {
|
|
|
157
161
|
currencyLocation: n,
|
|
158
162
|
formattedPrice: s
|
|
159
163
|
} = this.store;
|
|
160
|
-
this.api.getDocumentModifier().modifyHtml(this.currentNode).setInnerHtml(
|
|
164
|
+
this.api.getDocumentModifier().modifyHtml(this.currentNode).setInnerHtml(F({
|
|
161
165
|
orientation: e,
|
|
162
166
|
itemsType: t,
|
|
163
167
|
itemId: i,
|
|
164
168
|
currencySymbol: r,
|
|
165
169
|
currencyLocation: n,
|
|
166
170
|
formattedPrice: s
|
|
167
|
-
})).apply(new
|
|
171
|
+
})).apply(new u("Updated template"));
|
|
168
172
|
}
|
|
169
173
|
_getTemplateData() {
|
|
170
174
|
const { itemsType: e, itemIds: t, formattedPrice: i } = this.store, r = N[e].findIndex((s) => s.value === t), n = r > -1 ? r : 0;
|
|
171
175
|
return {
|
|
172
|
-
imageSrc:
|
|
173
|
-
name:
|
|
174
|
-
price: i ?
|
|
175
|
-
originalPrice: i ?
|
|
176
|
-
quantity:
|
|
177
|
-
button:
|
|
176
|
+
imageSrc: p.PAIRS_FOR_EXTENSION.imageSrc[e].DEFAULT[n],
|
|
177
|
+
name: p.PAIRS_FOR_EXTENSION.name[e].DEFAULT[n],
|
|
178
|
+
price: i ? p.PAIRS_FOR_EXTENSION.price[e].DEFAULT_PRICE_FORMATTED : p.PAIRS_FOR_EXTENSION.price[e].DEFAULT_PRICE,
|
|
179
|
+
originalPrice: i ? p.PAIRS_FOR_EXTENSION.originalPrice[e].DEFAULT_PRICE_FORMATTED : p.PAIRS_FOR_EXTENSION.originalPrice[e].DEFAULT_PRICE,
|
|
180
|
+
quantity: p.PAIRS_FOR_EXTENSION.quantity[e].DEFAULT,
|
|
181
|
+
button: p.PAIRS_FOR_EXTENSION.button[e].DEFAULT_LABEL
|
|
178
182
|
};
|
|
179
183
|
}
|
|
180
184
|
_updateImageSrc(e) {
|
|
181
185
|
var i;
|
|
182
|
-
const t = (i = this.currentNode) == null ? void 0 : i.querySelector(`[esd-extension-block-id="${
|
|
183
|
-
t && this.api.getDocumentModifier().modifyHtml(t).setAttribute("src", e).apply(new
|
|
186
|
+
const t = (i = this.currentNode) == null ? void 0 : i.querySelector(`[esd-extension-block-id="${m.IMAGE}"] img`);
|
|
187
|
+
t && this.api.getDocumentModifier().modifyHtml(t).setAttribute("src", e).apply(new u("Updated image src"));
|
|
184
188
|
}
|
|
185
189
|
_updateName(e) {
|
|
186
190
|
var n;
|
|
187
|
-
const t = (n = this.currentNode) == null ? void 0 : n.querySelector(`[esd-extension-block-id="${
|
|
191
|
+
const t = (n = this.currentNode) == null ? void 0 : n.querySelector(`[esd-extension-block-id="${m.NAME}"]`);
|
|
188
192
|
if (!t)
|
|
189
193
|
return;
|
|
190
194
|
const i = t.getInnerText().trim();
|
|
191
195
|
let r = t.getInnerHTML();
|
|
192
|
-
r = r.replace(i, e), this.api.getDocumentModifier().modifyHtml(t).setInnerHtml(r).apply(new
|
|
196
|
+
r = r.replace(i, e), this.api.getDocumentModifier().modifyHtml(t).setInnerHtml(r).apply(new u("Updated name"));
|
|
193
197
|
}
|
|
194
198
|
_updatePrice(e) {
|
|
195
199
|
var g;
|
|
196
|
-
const t = (g = this.currentNode) == null ? void 0 : g.querySelector(`[esd-extension-block-id="${
|
|
200
|
+
const t = (g = this.currentNode) == null ? void 0 : g.querySelector(`[esd-extension-block-id="${m.PRICE}"]`);
|
|
197
201
|
if (!t)
|
|
198
202
|
return;
|
|
199
203
|
const i = this._getParagraphFromBlock(t);
|
|
200
204
|
if (!i)
|
|
201
205
|
return;
|
|
202
|
-
const r = i.getInnerHTML() || "", n = i.getInnerText() || "", { currencySymbol: s, currencyLocation:
|
|
203
|
-
this.api.getDocumentModifier().modifyHtml(i).setInnerHtml(_).apply(new
|
|
206
|
+
const r = i.getInnerHTML() || "", n = i.getInnerText() || "", { currencySymbol: s, currencyLocation: l } = this.store, o = (s == null ? void 0 : s.trim()) || "", c = this._removeCurrencySymbol(n, o), T = this._replacePriceNumber(c, e), I = this._buildPriceContent(T, o, l), _ = r.replace(n, I);
|
|
207
|
+
this.api.getDocumentModifier().modifyHtml(i).setInnerHtml(_).apply(new u("Updated price"));
|
|
204
208
|
}
|
|
205
209
|
_updateOriginalPrice(e) {
|
|
206
|
-
var
|
|
207
|
-
const t = (
|
|
208
|
-
`[esd-extension-block-id="${
|
|
210
|
+
var E;
|
|
211
|
+
const t = (E = this.currentNode) == null ? void 0 : E.querySelector(
|
|
212
|
+
`[esd-extension-block-id="${m.ORIGINAL_PRICE}"]`
|
|
209
213
|
);
|
|
210
214
|
if (!t)
|
|
211
215
|
return;
|
|
@@ -215,29 +219,29 @@ class j extends L {
|
|
|
215
219
|
const r = i.querySelector("s");
|
|
216
220
|
if (!r)
|
|
217
221
|
return;
|
|
218
|
-
const n = r.getInnerHTML() || "", s = r.getInnerText() || "", { currencySymbol:
|
|
219
|
-
this.api.getDocumentModifier().modifyHtml(i).setInnerHtml(
|
|
222
|
+
const n = r.getInnerHTML() || "", s = r.getInnerText() || "", { currencySymbol: l, currencyLocation: o } = this.store, c = (l == null ? void 0 : l.trim()) || "", T = this._removeCurrencySymbol(s, c), I = this._replacePriceNumber(T, e), _ = this._buildPriceContent(I, c, o), y = `<s>${n.replace(s, _)}</s>`;
|
|
223
|
+
this.api.getDocumentModifier().modifyHtml(i).setInnerHtml(y).apply(new u("Updated original price"));
|
|
220
224
|
}
|
|
221
225
|
_updateQuantity(e) {
|
|
222
|
-
var
|
|
223
|
-
const t = this.store.itemsType !== S.ITEMS_TYPE.BROWSED_ITEMS, i = (s = this.currentNode) == null ? void 0 :
|
|
224
|
-
if (!
|
|
226
|
+
var c;
|
|
227
|
+
const t = this.store.itemsType !== S.ITEMS_TYPE.BROWSED_ITEMS, i = P(this.currentNode), r = (i == null ? void 0 : i.quantityControlEnabled) !== !1, n = t && r, s = (c = this.currentNode) == null ? void 0 : c.querySelector(`[esd-extension-block-id="${m.QUANTITY}"]`);
|
|
228
|
+
if (!s)
|
|
225
229
|
return;
|
|
226
|
-
const
|
|
227
|
-
let
|
|
228
|
-
|
|
230
|
+
const l = s.getInnerText().trim();
|
|
231
|
+
let o = s.getInnerHTML();
|
|
232
|
+
o = o.replace(l, e), this.api.getDocumentModifier().modifyHtml(s).setInnerHtml(o).setStyle("display", n ? "table-cell" : "none").apply(new u("Updated quantity"));
|
|
229
233
|
}
|
|
230
234
|
_reOrderTemplate() {
|
|
231
|
-
var I, _, g,
|
|
232
|
-
const e = (
|
|
233
|
-
`[esd-extension-block-id="${
|
|
234
|
-
), n = (y = this.currentNode) == null ? void 0 : y.querySelector(`[esd-extension-block-id="${
|
|
235
|
+
var T, I, _, g, y, E;
|
|
236
|
+
const e = (T = this.currentNode) == null ? void 0 : T.querySelector(`[esd-extension-block-id="${m.IMAGE}"]`), t = (I = this.currentNode) == null ? void 0 : I.querySelector(`[esd-extension-block-id="${m.NAME}"]`), i = (_ = this.currentNode) == null ? void 0 : _.querySelector(`[esd-extension-block-id="${m.PRICE}"]`), r = (g = this.currentNode) == null ? void 0 : g.querySelector(
|
|
237
|
+
`[esd-extension-block-id="${m.ORIGINAL_PRICE}"]`
|
|
238
|
+
), n = (y = this.currentNode) == null ? void 0 : y.querySelector(`[esd-extension-block-id="${m.QUANTITY}"]`), s = (E = this.currentNode) == null ? void 0 : E.querySelector(`[esd-extension-block-id="${m.BUTTON}"]`);
|
|
235
239
|
if (!e || !t || !i || !r || !n || !s)
|
|
236
240
|
return;
|
|
237
|
-
const { orientation:
|
|
238
|
-
let
|
|
239
|
-
this.api.getDocumentModifier().modifyHtml(e.querySelector("img")).setAttribute("width",
|
|
240
|
-
|
|
241
|
+
const { orientation: l } = this.store, o = l === S.ORIENTATION.VERTICAL;
|
|
242
|
+
let c = o ? k : H;
|
|
243
|
+
this.api.getDocumentModifier().modifyHtml(e.querySelector("img")).setAttribute("width", A.productImageWidth).setAttribute("height", A.productImageWidth).apply(new u("Updated image width")), setTimeout(() => {
|
|
244
|
+
c = c.replace("{-{-TEMPLATE_FIRST_LINE-}-}", o ? b : "").replace("{-{-PRODUCT_IMAGE-}-}", e.getOuterHTML()).replace("{-{-PRODUCT_NAME-}-}", t.getOuterHTML()).replaceAll("{-{-PRODUCT_PRICE-}-}", i.getOuterHTML()).replaceAll("{-{-PRODUCT_ORIGINAL_PRICE-}-}", r.getOuterHTML()).replace("{-{-PRODUCT_QUANTITY-}-}", n.getOuterHTML()).replace("{-{-PRODUCT_BUTTON-}-}", s.getOuterHTML()), c = c.trim().replace(b, "").slice(0, -5), this.api.getDocumentModifier().modifyHtml(this.currentNode).setInnerHtml(c).apply(new u("Reordered template"));
|
|
241
245
|
}, 50);
|
|
242
246
|
}
|
|
243
247
|
_updateDataTypeAttributes(e) {
|
|
@@ -247,27 +251,27 @@ class j extends L {
|
|
|
247
251
|
t && i.modifyHtml(t).setAttribute("data-type", e), this.currentNode.querySelectorAll("[data-type]").forEach((n) => {
|
|
248
252
|
const s = n;
|
|
249
253
|
i.modifyHtml(s).setAttribute("data-type", e);
|
|
250
|
-
}), i.apply(new
|
|
254
|
+
}), i.apply(new u("Updated data-type attribute"));
|
|
251
255
|
}
|
|
252
256
|
_updateDataNumberAttributes(e) {
|
|
253
257
|
if (!this.currentNode)
|
|
254
258
|
return;
|
|
255
|
-
const { itemsType: t } = this.store, i = N[t].findIndex((
|
|
259
|
+
const { itemsType: t } = this.store, i = N[t].findIndex((o) => o.value === e);
|
|
256
260
|
let r = "1";
|
|
257
261
|
if (i >= 0)
|
|
258
262
|
r = String(i + 1);
|
|
259
263
|
else if (e) {
|
|
260
|
-
const
|
|
261
|
-
if (
|
|
262
|
-
const [,
|
|
263
|
-
r =
|
|
264
|
+
const o = e.match(/\((\d+)\)/);
|
|
265
|
+
if (o) {
|
|
266
|
+
const [, c] = o;
|
|
267
|
+
r = c;
|
|
264
268
|
}
|
|
265
269
|
}
|
|
266
270
|
const n = this.currentNode.closest(".ins-product-td"), s = this.api.getDocumentModifier();
|
|
267
|
-
n && s.modifyHtml(n).setAttribute("data-number", r), this.currentNode.querySelectorAll("[data-number]").forEach((
|
|
268
|
-
const
|
|
269
|
-
s.modifyHtml(
|
|
270
|
-
}), s.apply(new
|
|
271
|
+
n && s.modifyHtml(n).setAttribute("data-number", r), this.currentNode.querySelectorAll("[data-number]").forEach((o) => {
|
|
272
|
+
const c = o;
|
|
273
|
+
s.modifyHtml(c).setAttribute("data-number", r);
|
|
274
|
+
}), s.apply(new u("Updated data-number attribute"));
|
|
271
275
|
}
|
|
272
276
|
_reFillTemplate() {
|
|
273
277
|
const e = this._getTemplateData();
|
|
@@ -277,14 +281,14 @@ class j extends L {
|
|
|
277
281
|
var n;
|
|
278
282
|
if (!this.currentNode)
|
|
279
283
|
return;
|
|
280
|
-
const e = (n = this.currentNode) == null ? void 0 : n.querySelector(`[esd-extension-block-id="${
|
|
284
|
+
const e = (n = this.currentNode) == null ? void 0 : n.querySelector(`[esd-extension-block-id="${m.NAME}"]`);
|
|
281
285
|
if (!e)
|
|
282
286
|
return;
|
|
283
287
|
const t = e.querySelector("p > a");
|
|
284
288
|
if (!t)
|
|
285
289
|
return;
|
|
286
290
|
const i = this.store.orientation === S.ORIENTATION.HORIZONTAL, r = this.store.nameTrimming;
|
|
287
|
-
this.api.getDocumentModifier().modifyHtml(t).setStyle("overflow", "hidden").setStyle("white-space", r ? "nowrap" : "normal").setStyle("text-overflow", r ? "ellipsis" : "unset").setStyle("max-width", i ? "130px" : "520px").setStyle("width", i ? "130px" : "520px").apply(new
|
|
291
|
+
this.api.getDocumentModifier().modifyHtml(t).setStyle("overflow", "hidden").setStyle("white-space", r ? "nowrap" : "normal").setStyle("text-overflow", r ? "ellipsis" : "unset").setStyle("max-width", i ? "130px" : "520px").setStyle("width", i ? "130px" : "520px").apply(new u("Recalculated trimming after orientation change"));
|
|
288
292
|
}
|
|
289
293
|
_getParagraphFromBlock(e) {
|
|
290
294
|
return e.querySelector("p");
|
|
@@ -301,8 +305,8 @@ class j extends L {
|
|
|
301
305
|
} else {
|
|
302
306
|
const n = i.match(/([^0-9.,\s]+)/);
|
|
303
307
|
if (n && n[1]) {
|
|
304
|
-
const s = n[1].trim(),
|
|
305
|
-
r = i.replace(
|
|
308
|
+
const s = n[1].trim(), l = new RegExp(`\\s*${this._escapeRegex(s)}\\s*`);
|
|
309
|
+
r = i.replace(l, "").trim();
|
|
306
310
|
}
|
|
307
311
|
}
|
|
308
312
|
return r;
|
|
@@ -316,6 +320,6 @@ class j extends L {
|
|
|
316
320
|
}
|
|
317
321
|
}
|
|
318
322
|
export {
|
|
319
|
-
|
|
320
|
-
|
|
323
|
+
$ as CONTROL_BLOCK_ID,
|
|
324
|
+
K as ItemsBlockControl
|
|
321
325
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
var c = /* @__PURE__ */ ((i) => (i.BUTTON = "items-block-button", i.IMAGE = "items-block-image", i.ORIGINAL_PRICE = "items-block-original-price", i.PRICE = "items-block-price", i.QUANTITY = "items-block-quantity", i.NAME = "items-block-name", i))(c || {}),
|
|
1
|
+
var c = /* @__PURE__ */ ((i) => (i.BUTTON = "items-block-button", i.IMAGE = "items-block-image", i.ORIGINAL_PRICE = "items-block-original-price", i.PRICE = "items-block-price", i.QUANTITY = "items-block-quantity", i.NAME = "items-block-name", i))(c || {}), _ = /* @__PURE__ */ ((i) => (i.BUTTON_ALIGN = "items-block-button-align-control", i.BUTTON_BORDER = "items-block-button-border-control", i.BUTTON_BORDER_RADIUS = "items-block-button-border-radius-control", i.BUTTON_COLOR = "items-block-button-color-control", i.BUTTON_FIT_TO_CONTENT = "items-block-button-fit-to-content-control", i.BUTTON_FONT_FAMILY = "items-block-button-font-family-control", i.BUTTON_MARGINS = "items-block-button-margins-control", i.BUTTON_PADDINGS = "items-block-button-paddings-control", i.BUTTON_TEXT = "items-block-button-text-control", i.BUTTON_TEXT_SIZE = "items-block-button-text-size-control", i.BUTTON_TEXT_STYLE_AND_FONT_COLOR = "items-block-button-text-style-and-font-color-control", i.BUTTON_LINK = "items-block-button-link-control", i.IMAGE_SIZE = "items-block-image-size-control", i.IMAGE_MARGINS = "items-block-image-margins-control", i.IMAGE_LINK = "items-block-image-link-control", i.ORIGINAL_PRICE_ALIGN = "items-block-original-price-align-control", i.ORIGINAL_PRICE_COLOR = "items-block-original-price-color-control", i.ORIGINAL_PRICE_SIZE = "items-block-original-price-size-control", i.ORIGINAL_PRICE_STYLE = "items-block-original-price-style-control", i.ORIGINAL_PRICE_FONT_FAMILY = "items-block-original-price-font-family-control", i.ORIGINAL_PRICE_BACKGROUND = "items-block-original-price-background-control", i.ORIGINAL_PRICE_PADDINGS = "items-block-original-price-paddings-control", i.PRICE_ALIGN = "items-block-price-align-control", i.PRICE_COLOR = "items-block-price-color-control", i.PRICE_SIZE = "items-block-price-size-control", i.PRICE_STYLE = "items-block-price-style-control", i.PRICE_FONT_FAMILY = "items-block-price-font-family-control", i.PRICE_BACKGROUND = "items-block-price-background-control", i.PRICE_PADDINGS = "items-block-price-paddings-control", i.PRICE_HIDE_DISCOUNT = "items-block-price-hide-discount-control", i.PRICE_FORMATTED_PRICE = "items-block-price-formatted-price-control", i.PRICE_SINGLE_PRICE = "items-block-price-single-price-control", i.PRICE_CURRENCY_SYMBOL = "items-block-price-currency-symbol-control", i.PRICE_CURRENCY_LOCATION = "items-block-price-currency-location-control", i.PRICE_ORIENTATION = "items-block-price-orientation-control", i.NAME_ALIGN = "items-block-name-align-control", i.NAME_COLOR = "items-block-name-color-control", i.NAME_SIZE = "items-block-name-size-control", i.NAME_STYLE = "items-block-name-style-control", i.NAME_FONT_FAMILY = "items-block-name-font-family-control", i.NAME_BACKGROUND = "items-block-name-background-control", i.NAME_TRIMMING = "items-block-name-trimming-control", i.NAME_PADDINGS = "items-block-name-paddings-control", i.QUANTITY_ALIGN = "items-block-quantity-align-control", i.QUANTITY_COLOR = "items-block-quantity-color-control", i.QUANTITY_FONT_FAMILY = "items-block-quantity-font-family-control", i.QUANTITY_PADDINGS = "items-block-quantity-paddings-control", i.QUANTITY_SIZE = "items-block-quantity-size-control", i.QUANTITY_STYLE = "items-block-quantity-style-control", i))(_ || {});
|
|
2
2
|
export {
|
|
3
|
-
|
|
3
|
+
_ as ItemsBlockControlId,
|
|
4
4
|
c as ItemsBlockId
|
|
5
5
|
};
|
|
@@ -1,31 +1,6 @@
|
|
|
1
1
|
import _ from "../../../../node_modules/lodash-es/flatMap.js";
|
|
2
|
-
import
|
|
3
|
-
const
|
|
4
|
-
TYPE: "data-type",
|
|
5
|
-
ITEMS_INDEX_SELECT_CONTROL_VALUE: "data-cart_items_select_control_value",
|
|
6
|
-
ORIENTATION: "data-card_orientation_control_value",
|
|
7
|
-
PRODUCT_NAME_TRIMMING: "data-product_name_trimming",
|
|
8
|
-
PRODUCT_PRICE_HIDE_DISCOUNT: "data-product_price_hide_discount",
|
|
9
|
-
PRODUCT_PRICE_FORMATTED: "data-product_price_formatted",
|
|
10
|
-
PRODUCT_PRICE_CURRENCY_SYMBOL: "data-product_price_currency_symbol",
|
|
11
|
-
PRODUCT_PRICE_CURRENCY_LOCATION: "data-product_price_currency_location",
|
|
12
|
-
PRODUCT_ORIGINAL_PRICE_CONTROL_ORIENTATION: "data-product_original_price_control_orientation",
|
|
13
|
-
PRODUCT_BUTTON_LINK: "data-product_button_link",
|
|
14
|
-
PRODUCT_IMAGE_LINK: "data-product_image_link",
|
|
15
|
-
PRODUCT_NAME_CONTROL_VALUE: "data-product_name_control_value",
|
|
16
|
-
PRODUCT_QUANTITY_CONTROL_VALUE: "data-product_quantity_control_value",
|
|
17
|
-
PRODUCT_PRICE_CONTROL_VALUE: "data-product_price_control_value",
|
|
18
|
-
BLOCK_INSTANCE_ID: "data-block-instance-id",
|
|
19
|
-
NAME_CONTROL_ENABLED: "data-product_name_control_enabled",
|
|
20
|
-
QUANTITY_CONTROL_ENABLED: "data-product_quantity_control_enabled",
|
|
21
|
-
PRICE_CONTROL_OPENED: "data-product_price_control_opened",
|
|
22
|
-
PRODUCT_IMAGE_VISIBLE: "data-product_image_visible",
|
|
23
|
-
PRODUCT_NAME_VISIBLE: "data-product_name_visible",
|
|
24
|
-
PRODUCT_QUANTITY_VISIBLE: "data-product_quantity_visible",
|
|
25
|
-
PRODUCT_PRICE_VISIBLE: "data-product_price_visible",
|
|
26
|
-
PRODUCT_ORIGINAL_PRICE_VISIBLE: "data-product_original_price_visible",
|
|
27
|
-
PRODUCT_BUTTON_VISIBLE: "data-product_button_visible"
|
|
28
|
-
}, t = { PAIRS_FOR_EXTENSION: {
|
|
2
|
+
import a from "../../../../node_modules/lodash-es/range.js";
|
|
3
|
+
const T = '<td align="center" class="ins-product-td items-block items-block-v2">', E = { PAIRS_FOR_EXTENSION: {
|
|
29
4
|
imageSrc: {
|
|
30
5
|
CART_ITEMS: {
|
|
31
6
|
ATTR: "ins_apr_img",
|
|
@@ -132,25 +107,37 @@ const o = '<td align="center" class="ins-product-td items-block items-block-v2">
|
|
|
132
107
|
CART_ITEMS: {
|
|
133
108
|
PRICE: "ins_apr_price",
|
|
134
109
|
PRICE_FORMATTED: "ins_apr_formattedprice",
|
|
110
|
+
SINGLE_PRICE: "ins_apr_single_price",
|
|
111
|
+
SINGLE_PRICE_FORMATTED: "ins_apr_single_formattedprice",
|
|
135
112
|
CURRENCY: "ins_apr_productcurrency",
|
|
136
113
|
DEFAULT_PRICE: "1100.00",
|
|
137
114
|
DEFAULT_PRICE_FORMATTED: "1,100.00",
|
|
115
|
+
DEFAULT_SINGLE_PRICE: "366.67",
|
|
116
|
+
DEFAULT_SINGLE_PRICE_FORMATTED: "366.67",
|
|
138
117
|
DEFAULT_CURRENCY: "USD"
|
|
139
118
|
},
|
|
140
119
|
BROWSED_ITEMS: {
|
|
141
120
|
PRICE: "browsed_item_price",
|
|
142
121
|
PRICE_FORMATTED: "browsed_item_formattedprice",
|
|
122
|
+
SINGLE_PRICE: "browsed_item_single_price",
|
|
123
|
+
SINGLE_PRICE_FORMATTED: "browsed_item_single_formattedprice",
|
|
143
124
|
CURRENCY: "browsed_item_productcurrency",
|
|
144
125
|
DEFAULT_PRICE: "1249.99",
|
|
145
126
|
DEFAULT_PRICE_FORMATTED: "1,249.99",
|
|
127
|
+
DEFAULT_SINGLE_PRICE: "178.57",
|
|
128
|
+
DEFAULT_SINGLE_PRICE_FORMATTED: "178.57",
|
|
146
129
|
DEFAULT_CURRENCY: "USD"
|
|
147
130
|
},
|
|
148
131
|
PURCHASED_ITEMS: {
|
|
149
132
|
PRICE: "purchased_item_price",
|
|
150
133
|
PRICE_FORMATTED: "purchased_item_formattedprice",
|
|
134
|
+
SINGLE_PRICE: "purchased_item_single_price",
|
|
135
|
+
SINGLE_PRICE_FORMATTED: "purchased_item_single_formattedprice",
|
|
151
136
|
CURRENCY: "purchased_item_productcurrency",
|
|
152
137
|
DEFAULT_PRICE: "1490.49",
|
|
153
138
|
DEFAULT_PRICE_FORMATTED: "1,490.49",
|
|
139
|
+
DEFAULT_SINGLE_PRICE: "149.05",
|
|
140
|
+
DEFAULT_SINGLE_PRICE_FORMATTED: "149.05",
|
|
154
141
|
DEFAULT_CURRENCY: "USD"
|
|
155
142
|
}
|
|
156
143
|
},
|
|
@@ -158,25 +145,37 @@ const o = '<td align="center" class="ins-product-td items-block items-block-v2">
|
|
|
158
145
|
CART_ITEMS: {
|
|
159
146
|
PRICE: "ins_apr_originalprice",
|
|
160
147
|
PRICE_FORMATTED: "ins_apr_originalformattedprice",
|
|
148
|
+
SINGLE_PRICE: "ins_apr_single_originalprice",
|
|
149
|
+
SINGLE_PRICE_FORMATTED: "ins_apr_single_originalformattedprice",
|
|
161
150
|
CURRENCY: "ins_apr_productcurrency",
|
|
162
151
|
DEFAULT_PRICE: "1600.00",
|
|
163
152
|
DEFAULT_PRICE_FORMATTED: "1,600.00",
|
|
153
|
+
DEFAULT_SINGLE_PRICE: "533.33",
|
|
154
|
+
DEFAULT_SINGLE_PRICE_FORMATTED: "533.33",
|
|
164
155
|
DEFAULT_CURRENCY: "USD"
|
|
165
156
|
},
|
|
166
157
|
BROWSED_ITEMS: {
|
|
167
158
|
PRICE: "browsed_item_originalprice",
|
|
168
159
|
PRICE_FORMATTED: "browsed_item_originalformattedprice",
|
|
160
|
+
SINGLE_PRICE: "browsed_item_single_originalprice",
|
|
161
|
+
SINGLE_PRICE_FORMATTED: "browsed_item_single_originalformattedprice",
|
|
169
162
|
CURRENCY: "browsed_item_productcurrency",
|
|
170
163
|
DEFAULT_PRICE: "2049.99",
|
|
171
164
|
DEFAULT_PRICE_FORMATTED: "2,049.99",
|
|
165
|
+
DEFAULT_SINGLE_PRICE: "292.86",
|
|
166
|
+
DEFAULT_SINGLE_PRICE_FORMATTED: "292.86",
|
|
172
167
|
DEFAULT_CURRENCY: "USD"
|
|
173
168
|
},
|
|
174
169
|
PURCHASED_ITEMS: {
|
|
175
170
|
PRICE: "purchased_item_originalprice",
|
|
176
171
|
PRICE_FORMATTED: "purchased_item_originalformattedprice",
|
|
172
|
+
SINGLE_PRICE: "purchased_item_single_originalprice",
|
|
173
|
+
SINGLE_PRICE_FORMATTED: "purchased_item_single_originalformattedprice",
|
|
177
174
|
CURRENCY: "purchased_item_productcurrency",
|
|
178
175
|
DEFAULT_PRICE: "1890.49",
|
|
179
176
|
DEFAULT_PRICE_FORMATTED: "1,890.49",
|
|
177
|
+
DEFAULT_SINGLE_PRICE: "189.05",
|
|
178
|
+
DEFAULT_SINGLE_PRICE_FORMATTED: "189.05",
|
|
180
179
|
DEFAULT_CURRENCY: "USD"
|
|
181
180
|
}
|
|
182
181
|
},
|
|
@@ -212,27 +211,27 @@ const o = '<td align="center" class="ins-product-td items-block items-block-v2">
|
|
|
212
211
|
}
|
|
213
212
|
}
|
|
214
213
|
} };
|
|
215
|
-
function m(e,
|
|
216
|
-
return
|
|
214
|
+
function m(e, s = 8) {
|
|
215
|
+
return a(1, s + 1).map((i) => `${e}_${i}`);
|
|
217
216
|
}
|
|
218
|
-
function
|
|
219
|
-
const { PAIRS_FOR_EXTENSION: e } =
|
|
220
|
-
return
|
|
217
|
+
function t() {
|
|
218
|
+
const { PAIRS_FOR_EXTENSION: e } = E, s = [];
|
|
219
|
+
return s.push(
|
|
221
220
|
e.imageSrc.CART_ITEMS.ATTR,
|
|
222
221
|
e.imageSrc.BROWSED_ITEMS.ATTR,
|
|
223
222
|
e.imageSrc.PURCHASED_ITEMS.ATTR
|
|
224
|
-
),
|
|
223
|
+
), s.push(
|
|
225
224
|
e.name.CART_ITEMS.ATTR,
|
|
226
225
|
e.name.CART_ITEMS.HREF,
|
|
227
226
|
e.name.BROWSED_ITEMS.ATTR,
|
|
228
227
|
e.name.BROWSED_ITEMS.HREF,
|
|
229
228
|
e.name.PURCHASED_ITEMS.ATTR,
|
|
230
229
|
e.name.PURCHASED_ITEMS.HREF
|
|
231
|
-
),
|
|
230
|
+
), s.push(
|
|
232
231
|
e.quantity.CART_ITEMS.ATTR,
|
|
233
232
|
e.quantity.BROWSED_ITEMS.ATTR,
|
|
234
233
|
e.quantity.PURCHASED_ITEMS.ATTR
|
|
235
|
-
),
|
|
234
|
+
), s.push(
|
|
236
235
|
e.price.CART_ITEMS.PRICE,
|
|
237
236
|
e.price.CART_ITEMS.PRICE_FORMATTED,
|
|
238
237
|
e.price.CART_ITEMS.CURRENCY,
|
|
@@ -242,7 +241,7 @@ function r() {
|
|
|
242
241
|
e.price.PURCHASED_ITEMS.PRICE,
|
|
243
242
|
e.price.PURCHASED_ITEMS.PRICE_FORMATTED,
|
|
244
243
|
e.price.PURCHASED_ITEMS.CURRENCY
|
|
245
|
-
),
|
|
244
|
+
), s.push(
|
|
246
245
|
e.originalPrice.CART_ITEMS.PRICE,
|
|
247
246
|
e.originalPrice.CART_ITEMS.PRICE_FORMATTED,
|
|
248
247
|
e.originalPrice.CART_ITEMS.CURRENCY,
|
|
@@ -252,23 +251,22 @@ function r() {
|
|
|
252
251
|
e.originalPrice.PURCHASED_ITEMS.PRICE,
|
|
253
252
|
e.originalPrice.PURCHASED_ITEMS.PRICE_FORMATTED,
|
|
254
253
|
e.originalPrice.PURCHASED_ITEMS.CURRENCY
|
|
255
|
-
),
|
|
254
|
+
), s.push(
|
|
256
255
|
e.button.CART_ITEMS.HREF,
|
|
257
256
|
e.button.BROWSED_ITEMS.HREF,
|
|
258
257
|
e.button.PURCHASED_ITEMS.HREF
|
|
259
|
-
),
|
|
258
|
+
), s.push(
|
|
260
259
|
e.itemLink.CART_ITEMS.HREF,
|
|
261
260
|
e.itemLink.BROWSED_ITEMS.HREF,
|
|
262
261
|
e.itemLink.PURCHASED_ITEMS.HREF
|
|
263
|
-
),
|
|
262
|
+
), s;
|
|
264
263
|
}
|
|
265
|
-
const
|
|
266
|
-
|
|
264
|
+
const o = _(
|
|
265
|
+
t(),
|
|
267
266
|
(e) => m(e)
|
|
268
267
|
);
|
|
269
268
|
export {
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
o as templateFirstLine
|
|
269
|
+
o as itemsBlockDynamicVariables,
|
|
270
|
+
E as productPairs,
|
|
271
|
+
T as templateFirstLine
|
|
274
272
|
};
|
|
@@ -35,7 +35,8 @@ const e = {
|
|
|
35
35
|
productPriceVisible: "1",
|
|
36
36
|
productOriginalPriceVisible: "1",
|
|
37
37
|
productButtonVisible: "1",
|
|
38
|
-
productImageWidth: "70"
|
|
38
|
+
productImageWidth: "70",
|
|
39
|
+
productImageHeight: "70"
|
|
39
40
|
}, o = {
|
|
40
41
|
[e.ITEMS_TYPE.CART_ITEMS]: [
|
|
41
42
|
{ text: "Abandoned Cart Item (1)", value: "{{Abandoned Cart Item (1) Url}}" },
|
|
@@ -10,11 +10,12 @@ import { PriceCurrencySymbolControl as g } from "./controls/price/currencySymbol
|
|
|
10
10
|
import { PriceFormattedPriceControl as f } from "./controls/price/formattedPrice.js";
|
|
11
11
|
import { PriceHideDiscountControl as p } from "./controls/price/hideDiscount.js";
|
|
12
12
|
import { PriceOrientationControl as y } from "./controls/price/priceOrientation.js";
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import k from "./
|
|
16
|
-
import
|
|
17
|
-
|
|
13
|
+
import { PriceSinglePriceControl as u } from "./controls/price/singlePrice.js";
|
|
14
|
+
import { ItemsBlockControl as P } from "./controls/settingsControl.js";
|
|
15
|
+
import { ItemsIconsRegistry as k } from "./iconsRegistry.js";
|
|
16
|
+
import I from "./items.css.js";
|
|
17
|
+
import { SettingsPanel as b } from "./settingsPanel.js";
|
|
18
|
+
const j = new a().addBlock(i).withSettingsPanelRegistry(b).addControl(P).addControl(e).addControl(r.align).addControl(r.color).addControl(r.size).addControl(r.style).addControl(r.fontFamily).addControl(r.background).addControl(r.paddings).addControl(s).addControl(n.align).addControl(n.color).addControl(n.fontFamily).addControl(n.paddings).addControl(n.size).addControl(n.style).addControl(t.align).addControl(t.color).addControl(t.size).addControl(t.style).addControl(t.fontFamily).addControl(t.background).addControl(t.paddings).addControl(d.align).addControl(d.color).addControl(d.size).addControl(d.style).addControl(d.fontFamily).addControl(d.background).addControl(d.paddings).addControl(p).addControl(f).addControl(u).addControl(g).addControl(c).addControl(y).addControl(m).addControl(l.size).addControl(l.margins).addControl(C).addControl(o.align).addControl(o.border).addControl(o.borderRadius).addControl(o.color).addControl(o.fontFamily).addControl(o.margins).addControl(o.paddings).addControl(o.text).addControl(o.textSize).addControl(o.textStyleAndFontColor).addControl(o.fitToContent).addStyles(I).withIconsRegistry(k).build();
|
|
18
19
|
export {
|
|
19
|
-
|
|
20
|
+
j as default
|
|
20
21
|
};
|