wickes-css2 2.112.0-develop.4 → 2.112.0-develop.6
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/build/css/category-main.css +1 -1
- package/build/css/components/global-search.css +1 -1
- package/build/css/homepage-main.css +1 -1
- package/build/css/kitchen-plp-main.css +1 -1
- package/build/css/main.css +1 -1
- package/build/css/my-account-main-v2.css +1 -1
- package/build/css/my-account-main.css +1 -1
- package/build/css/pages/page_product-details-critical.css +1 -1
- package/build/css/pages/page_product-details.css +1 -1
- package/build/css/pdp-main-before-combine.css +1 -1
- package/build/css/pdp-main-critical.css +1 -1
- package/build/css/pdp-main-non-critical.css +1 -1
- package/build/css/pdp-main.css +1 -1
- package/build/css/plp-main.css +1 -1
- package/build/css/store-locator-main.css +1 -1
- package/build/js/basket.min.js +1 -1
- package/build/js/emulation.min.js +330 -30
- package/build/js/page/basket-v2.js +29 -20
- package/package.json +1 -1
- package/src/components/my-account/order.hbs +6 -1
- package/src/components/order-item.hbs +7 -7
- package/src/components/potential-promotion.hbs +4 -4
- package/src/components/price-badges.hbs +12 -0
- package/src/components/price-block-v2.hbs +3 -12
- package/src/components/share-list-modal-without-social-icons.hbs +2 -2
- package/src/components/share-list-modal.hbs +7 -3
- package/src/data/data_shopping-cart-v2.json +46 -2
- package/src/data/data_shopping-cart-with-energy.json +26 -2
- package/src/data/my-account/data_my-order.json +8 -0
- package/src/js/emulation/basket-data.js +312 -0
- package/src/js/emulation/shopping-list.js +40 -49
- package/src/js/page/basket-v2.js +29 -20
- package/src/page_track-my-order-result.html +1 -0
- package/src/scss/components/_tradepro-discount-banner.scss +10 -14
- package/src/scss/components/global-search.scss +0 -6
- package/src/scss/pages/page_product-details-critical.scss +7 -0
- package/src/scss/pages/page_product-details.scss +7 -0
package/src/js/page/basket-v2.js
CHANGED
|
@@ -277,13 +277,14 @@ Wick.BasketPage = {
|
|
|
277
277
|
if (isSwitchVat) {
|
|
278
278
|
const itemTotalIncVat = context.find(Wick.BasketPage.el.itemTotalIncVat);
|
|
279
279
|
const itemTotalExcVat = context.find(Wick.BasketPage.el.itemTotalExcVat);
|
|
280
|
-
const totalPrice = data.entry.
|
|
281
|
-
const totalPriceExcVat =
|
|
280
|
+
const totalPrice = data.entry.displayItemTotalWithoutDiscount.formattedValue;
|
|
281
|
+
const totalPriceExcVat =
|
|
282
|
+
data.entry.displayItemTotalWithoutDiscountExclusiveVat.formattedValue;
|
|
282
283
|
itemTotalIncVat.text(totalPrice);
|
|
283
284
|
itemTotalExcVat.text(totalPriceExcVat);
|
|
284
285
|
} else {
|
|
285
286
|
const totalValue = context.find(Wick.BasketPage.el.itemTotal);
|
|
286
|
-
const totalPrice = data.entry.
|
|
287
|
+
const totalPrice = data.entry.displayItemTotalWithoutDiscount.formattedValue;
|
|
287
288
|
totalValue.text(totalPrice);
|
|
288
289
|
}
|
|
289
290
|
}
|
|
@@ -798,20 +799,20 @@ Wick.BasketPage = {
|
|
|
798
799
|
<div class="order-item__price-title">Item price:</div>
|
|
799
800
|
<div class="order-item__price-value">
|
|
800
801
|
${
|
|
801
|
-
currentItem.
|
|
802
|
+
currentItem.displayBasePrice.value === 0
|
|
802
803
|
? '<span class="order-item__value">FREE</span>'
|
|
803
804
|
: Wick.VatToggle.isToggleVatAvailable()
|
|
804
805
|
? `
|
|
805
806
|
<div class="including-vat"><!--
|
|
806
|
-
--><span class="order-item__value">${currentItem.
|
|
807
|
+
--><span class="order-item__value">${currentItem.displayBasePrice.formattedValue}</span><!--
|
|
807
808
|
--><div class="price-vat">Inc.VAT</div>
|
|
808
809
|
</div>
|
|
809
810
|
<div class="excluding-vat"><!--
|
|
810
|
-
--><span class="order-item__value">${currentItem.
|
|
811
|
+
--><span class="order-item__value">${currentItem.displayBasePriceExclusiveVat.formattedValue}</span><!--
|
|
811
812
|
--><div class="price-vat">Exc.VAT</div>
|
|
812
813
|
</div>
|
|
813
814
|
`
|
|
814
|
-
: `<span class="order-item__value">${currentItem.
|
|
815
|
+
: `<span class="order-item__value">${currentItem.displayBasePrice.formattedValue}</span>`
|
|
815
816
|
}
|
|
816
817
|
</div>
|
|
817
818
|
</div>
|
|
@@ -820,20 +821,20 @@ Wick.BasketPage = {
|
|
|
820
821
|
<div class="order-item__total-title">Item total:</div>
|
|
821
822
|
<div class="order-item__total-value">
|
|
822
823
|
${
|
|
823
|
-
currentItem.
|
|
824
|
+
currentItem.displayItemTotalWithoutDiscount.value === 0
|
|
824
825
|
? '<span class="order-item__value">FREE</span>'
|
|
825
826
|
: Wick.VatToggle.isToggleVatAvailable()
|
|
826
827
|
? `
|
|
827
828
|
<div class="including-vat"><!--
|
|
828
|
-
--><span class="order-item__value">${currentItem.
|
|
829
|
+
--><span class="order-item__value">${currentItem.displayItemTotalWithoutDiscount.formattedValue}</span><!--
|
|
829
830
|
--><div class="price-vat">Inc.VAT</div><!--
|
|
830
831
|
--></div>
|
|
831
832
|
<div class="excluding-vat"><!--
|
|
832
|
-
--><span class="order-item__value">${currentItem.
|
|
833
|
+
--><span class="order-item__value">${currentItem.displayItemTotalWithoutDiscountExclusiveVat.formattedValue}</span><!--
|
|
833
834
|
--><div class="price-vat">Exc.VAT</div>
|
|
834
835
|
</div>
|
|
835
836
|
`
|
|
836
|
-
: `<span class="order-item__value">${currentItem.
|
|
837
|
+
: `<span class="order-item__value">${currentItem.displayItemTotalWithoutDiscount.formattedValue}</span>`
|
|
837
838
|
}
|
|
838
839
|
</div>
|
|
839
840
|
</div>
|
|
@@ -929,7 +930,7 @@ Wick.BasketPage = {
|
|
|
929
930
|
data.appliedProductPromotions &&
|
|
930
931
|
data.appliedProductPromotions.forEach((entry) => {
|
|
931
932
|
entry.consumedEntries.forEach((promo) => {
|
|
932
|
-
if (promo.orderEntryNumber === item.entryNumber && entry.
|
|
933
|
+
if (promo.orderEntryNumber === item.entryNumber && entry.displayDescription) {
|
|
933
934
|
if (arr.length) {
|
|
934
935
|
let duplicate = arr.every((el) => {
|
|
935
936
|
return el !== Wick.BasketPage.buildPromotion(entry);
|
|
@@ -1115,15 +1116,19 @@ Wick.BasketPage = {
|
|
|
1115
1116
|
const arr = [];
|
|
1116
1117
|
if (data.potentialOrderPromotions && data.potentialOrderPromotions.length) {
|
|
1117
1118
|
data.potentialOrderPromotions.forEach((promo) => {
|
|
1118
|
-
!promo.
|
|
1119
|
+
!promo.displayDescription ||
|
|
1119
1120
|
arr.push(`
|
|
1120
1121
|
<div class="p-promotion">
|
|
1121
1122
|
<div class="p-promotion__icon">
|
|
1122
1123
|
<i class="icon fas fa-gift"></i>
|
|
1123
1124
|
</div>
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1125
|
+
${
|
|
1126
|
+
Wick.VatToggle.isToggleVatAvailable() &&
|
|
1127
|
+
promo.displayDescriptionExclusiveVat
|
|
1128
|
+
? `<div class="p-promotion__description including-vat">${promo.displayDescription}</div>
|
|
1129
|
+
<div class="p-promotion__description excluding-vat d-none">${promo.displayDescriptionExclusiveVat}</div>`
|
|
1130
|
+
: `<div class="p-promotion__description">${promo.displayDescription}</div>`
|
|
1131
|
+
}
|
|
1127
1132
|
<div class="p-promotion__close">
|
|
1128
1133
|
<i class="icon fas fa-times"></i>
|
|
1129
1134
|
</div>
|
|
@@ -1134,15 +1139,19 @@ Wick.BasketPage = {
|
|
|
1134
1139
|
|
|
1135
1140
|
if (data.appliedOrderPromotions && data.appliedOrderPromotions.length) {
|
|
1136
1141
|
data.appliedOrderPromotions.forEach((promo) => {
|
|
1137
|
-
!promo.
|
|
1142
|
+
!promo.displayDescription ||
|
|
1138
1143
|
arr.push(`
|
|
1139
1144
|
<div class="p-promotion">
|
|
1140
1145
|
<div class="p-promotion__icon">
|
|
1141
1146
|
<i class="icon fas fa-gift"></i>
|
|
1142
1147
|
</div>
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1148
|
+
${
|
|
1149
|
+
Wick.VatToggle.isToggleVatAvailable() &&
|
|
1150
|
+
promo.displayDescriptionExclusiveVat
|
|
1151
|
+
? `<div class="p-promotion__description including-vat">${promo.displayDescription}</div>
|
|
1152
|
+
<div class="p-promotion__description excluding-vat d-none">${promo.displayDescriptionExclusiveVat}</div>`
|
|
1153
|
+
: `<div class="p-promotion__description">${promo.displayDescription}</div>`
|
|
1154
|
+
}
|
|
1146
1155
|
<div class="p-promotion__close">
|
|
1147
1156
|
<i class="icon fas fa-times"></i>
|
|
1148
1157
|
</div>
|
|
@@ -3,6 +3,8 @@
|
|
|
3
3
|
z-index: $offer-banner;
|
|
4
4
|
width: 100%;
|
|
5
5
|
background-color: $blue;
|
|
6
|
+
font-size: 12px;
|
|
7
|
+
line-height: 1.375rem;
|
|
6
8
|
color: $white;
|
|
7
9
|
|
|
8
10
|
&.stuck {
|
|
@@ -55,23 +57,17 @@
|
|
|
55
57
|
}
|
|
56
58
|
}
|
|
57
59
|
|
|
58
|
-
|
|
60
|
+
@include media-breakpoint-up(md) {
|
|
59
61
|
.tradepro-discount-banner {
|
|
60
|
-
|
|
61
|
-
top: 0;
|
|
62
|
-
left: 0;
|
|
63
|
-
right: 0;
|
|
62
|
+
font-size: 14px;
|
|
64
63
|
}
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
@media screen and (max-width: 370px) {
|
|
68
|
-
.tradepro-discount-banner {
|
|
69
|
-
&__content {
|
|
70
|
-
padding: 4px 20px 4px 10px;
|
|
71
|
-
}
|
|
72
64
|
|
|
73
|
-
|
|
74
|
-
|
|
65
|
+
.global-search {
|
|
66
|
+
.tradepro-discount-banner {
|
|
67
|
+
position: absolute;
|
|
68
|
+
top: 0;
|
|
69
|
+
left: 0;
|
|
70
|
+
right: 0;
|
|
75
71
|
}
|
|
76
72
|
}
|
|
77
73
|
}
|
|
@@ -180,8 +180,15 @@ $gray: #ccc;
|
|
|
180
180
|
text-transform: none;
|
|
181
181
|
}
|
|
182
182
|
|
|
183
|
+
&__badges-wrapper {
|
|
184
|
+
margin: -20px -20px -10px;
|
|
185
|
+
display: flex;
|
|
186
|
+
justify-content: flex-end;
|
|
187
|
+
}
|
|
188
|
+
|
|
183
189
|
&__badges {
|
|
184
190
|
@include badges;
|
|
191
|
+
position: relative;
|
|
185
192
|
}
|
|
186
193
|
|
|
187
194
|
&__badge {
|
|
@@ -207,8 +207,15 @@
|
|
|
207
207
|
text-transform: none;
|
|
208
208
|
}
|
|
209
209
|
|
|
210
|
+
&__badges-wrapper {
|
|
211
|
+
margin: -20px -20px -10px;
|
|
212
|
+
display: flex;
|
|
213
|
+
justify-content: flex-end;
|
|
214
|
+
}
|
|
215
|
+
|
|
210
216
|
&__badges {
|
|
211
217
|
@include badges;
|
|
218
|
+
position: relative;
|
|
212
219
|
}
|
|
213
220
|
|
|
214
221
|
&__badge {
|