wickes-css2 2.117.0-develop.3 → 2.117.0-gift-cards.1

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 (102) hide show
  1. package/Readme.md +0 -1
  2. package/build/css/category-main.css +1 -1
  3. package/build/css/components/checkout-payment-details-v2.css +1 -1
  4. package/build/css/homepage-main.css +1 -1
  5. package/build/css/kitchen-plp-main.css +1 -1
  6. package/build/css/main.css +1 -1
  7. package/build/css/my-account-main-v2.css +1 -1
  8. package/build/css/my-account-main.css +1 -1
  9. package/build/css/pages/checkout-new.css +1 -1
  10. package/build/css/pages/checkout.css +1 -1
  11. package/build/css/pages/page_my-order.css +1 -1
  12. package/build/css/pages/page_wismo-details.css +1 -1
  13. package/build/css/pdp-main-before-combine.css +1 -1
  14. package/build/css/pdp-main-critical.css +1 -1
  15. package/build/css/pdp-main-non-critical.css +1 -1
  16. package/build/css/pdp-main.css +1 -1
  17. package/build/css/plp-main.css +1 -1
  18. package/build/css/store-locator-main.css +1 -1
  19. package/build/img/payment/checkout/giftcard.svg +28 -0
  20. package/build/img/payment/footer/giftcard.svg +28 -0
  21. package/build/js/account-members.min.js +1 -1
  22. package/build/js/add-project-list-id.min.js +1 -1
  23. package/build/js/address-book.min.js +1 -1
  24. package/build/js/basket.min.js +2 -2
  25. package/build/js/bundle.min.js +1 -1
  26. package/build/js/change-password.min.js +1 -1
  27. package/build/js/checkout.min.js +2 -2
  28. package/build/js/emulation.min.js +424 -82
  29. package/build/js/general.bundle.min.js +1 -1
  30. package/build/js/gift-cards.min.js +1 -1
  31. package/build/js/merged-checkout.min.js +2 -2
  32. package/build/js/page/bloomreach-widget/bloomreach-widget-core.js +1 -3
  33. package/build/js/page/checkout-payment-details.js +114 -10
  34. package/build/js/page/components/gift-cards.js +524 -115
  35. package/build/js/page/components/postcode-lookup/postcode-lookup-api.js +56 -0
  36. package/build/js/page/components/postcode-lookup/postcode-lookup-render.js +98 -0
  37. package/build/js/page/components/postcode-lookup/postcode-lookup-validation.js +81 -0
  38. package/build/js/page/components/postcode-lookup.js +503 -0
  39. package/build/js/page/ripple/bulk-add.js +2 -2
  40. package/build/js/page/ripple/thumb-gallery.js +14 -8
  41. package/build/js/page/utils/address-utils.js +32 -0
  42. package/build/js/page/utils/validation.js +54 -1
  43. package/build/js/pdp.bundle.min.js +2 -2
  44. package/build/js/personal-details.min.js +1 -1
  45. package/build/js/plp.bundle.min.js +1 -1
  46. package/build/js/postcode-checker.min.js +1 -1
  47. package/build/js/project-list.min.js +57 -2
  48. package/build/js/quiz.min.js +1 -1
  49. package/build/js/track-my-order.min.js +1 -1
  50. package/package.json +5 -1
  51. package/src/components/checkout-payment-details-v2.hbs +1 -0
  52. package/src/components/checkout_order-summary-new.hbs +6 -0
  53. package/src/components/checkout_payment-new.hbs +35 -8
  54. package/src/components/gift-cards.hbs +8 -15
  55. package/src/components/order-address.hbs +28 -0
  56. package/src/components/payments.hbs +7 -6
  57. package/src/components/postcode-lookup-v2.hbs +85 -0
  58. package/src/components/wismo-giftcard-payment-item.hbs +29 -0
  59. package/src/components/wismo-payment.hbs +10 -0
  60. package/src/data/data_checkout-giftcards.json +7 -0
  61. package/src/data/data_delivery-address-v2.json +4 -0
  62. package/src/data/data_payments-checkout.json +4 -0
  63. package/src/data/data_postcode-lookup.json +200 -0
  64. package/src/data/data_wismo.json +46 -1
  65. package/src/data/footer_menu.json +4 -0
  66. package/src/elements/input.hbs +3 -1
  67. package/src/img/payment/checkout/giftcard.svg +28 -0
  68. package/src/img/payment/footer/giftcard.svg +28 -0
  69. package/src/js/components/general/footer.js +63 -56
  70. package/src/js/emulation/checkout-payment-details.js +2 -0
  71. package/src/js/emulation/gift-cards.js +22 -0
  72. package/src/js/emulation/mock.js +21 -20
  73. package/src/js/emulation/postcode-checker.js +1 -1
  74. package/src/js/emulation/postcode-lookup.js +122 -0
  75. package/src/js/page/bloomreach-widget/bloomreach-widget-core.js +1 -3
  76. package/src/js/page/checkout-payment-details.js +114 -10
  77. package/src/js/page/components/gift-cards.js +524 -115
  78. package/src/js/page/components/postcode-lookup/postcode-lookup-api.js +56 -0
  79. package/src/js/page/components/postcode-lookup/postcode-lookup-render.js +98 -0
  80. package/src/js/page/components/postcode-lookup/postcode-lookup-validation.js +81 -0
  81. package/src/js/page/components/postcode-lookup.js +503 -0
  82. package/src/js/page/ripple/bulk-add.js +2 -2
  83. package/src/js/page/ripple/thumb-gallery.js +14 -8
  84. package/src/js/page/utils/address-utils.js +32 -0
  85. package/src/js/page/utils/validation.js +54 -1
  86. package/src/page_checkout_confirmation-gift-card-split-payment.html +339 -0
  87. package/src/page_checkout_confirmation-gift-card.html +339 -0
  88. package/src/page_my_account_payment_info_gift_cards.html +96 -0
  89. package/src/page_my_account_payment_info_gift_cards_split_payment.html +96 -0
  90. package/src/page_product-details-billie.html +2 -0
  91. package/src/page_product-details-clearpay.html +1 -0
  92. package/src/scss/common/_CTAs.scss +4 -0
  93. package/src/scss/components/_gift-cards.scss +66 -9
  94. package/src/scss/components/_payments-checkout.scss +2 -2
  95. package/src/scss/components/_payments-v2.scss +5 -7
  96. package/src/scss/components/_postcode-lookup-v2.scss +164 -0
  97. package/src/scss/components/checkout-payment-details-v2.scss +1 -0
  98. package/src/scss/helpers/_CTAs.scss +26 -0
  99. package/src/scss/helpers/_variables.scss +2 -0
  100. package/src/scss/pages/_checkout-confirmation-new.scss +96 -3
  101. package/src/scss/pages/page_wismo-details.scss +29 -0
  102. package/src/sitemap.html +24 -0
@@ -0,0 +1,200 @@
1
+ {
2
+ "postcode-lookup": {
3
+ "autocompleteResponse": {
4
+ "result": {
5
+ "hits": [
6
+ {
7
+ "id": "paf_5692124",
8
+ "suggestion": "Lo Lo, 129 Enbrook Valley, Folkestone, CT20",
9
+ "udprn": 5692124,
10
+ "urls": {
11
+ "udprn": "/v1/udprn/5692124"
12
+ }
13
+ },
14
+ {
15
+ "id": "paf_15567850",
16
+ "suggestion": "Lo Lo Nails, 8 South Mall, London, N9",
17
+ "udprn": 15567850,
18
+ "urls": {
19
+ "udprn": "/v1/udprn/15567850"
20
+ }
21
+ },
22
+ {
23
+ "id": "paf_51482484",
24
+ "suggestion": "1 Lo Grove, Wakefield, WF1",
25
+ "udprn": 51482484,
26
+ "urls": {
27
+ "udprn": "/v1/udprn/51482484"
28
+ }
29
+ },
30
+ {
31
+ "id": "paf_51482485",
32
+ "suggestion": "2 Lo Grove, Wakefield, WF1",
33
+ "udprn": 51482485,
34
+ "urls": {
35
+ "udprn": "/v1/udprn/51482485"
36
+ }
37
+ },
38
+ {
39
+ "id": "paf_51482486",
40
+ "suggestion": "3 Lo Grove, Wakefield, WF1",
41
+ "udprn": 51482486,
42
+ "urls": {
43
+ "udprn": "/v1/udprn/51482486"
44
+ }
45
+ },
46
+ {
47
+ "id": "paf_51482487",
48
+ "suggestion": "4 Lo Grove, Wakefield, WF1",
49
+ "udprn": 51482487,
50
+ "urls": {
51
+ "udprn": "/v1/udprn/51482487"
52
+ }
53
+ },
54
+ {
55
+ "id": "paf_52933093",
56
+ "suggestion": "5 Lo Grove, Wakefield, WF1",
57
+ "udprn": 52933093,
58
+ "urls": {
59
+ "udprn": "/v1/udprn/52933093"
60
+ }
61
+ },
62
+ {
63
+ "id": "paf_5859369",
64
+ "suggestion": "High Lo, Dalehouse Lane, Kenilworth, CV8",
65
+ "udprn": 5859369,
66
+ "urls": {
67
+ "udprn": "/v1/udprn/5859369"
68
+ }
69
+ },
70
+ {
71
+ "id": "paf_24383125",
72
+ "suggestion": "Kwai Lo, Winterhay Lane, Ilminster, TA19",
73
+ "udprn": 24383125,
74
+ "urls": {
75
+ "udprn": "/v1/udprn/24383125"
76
+ }
77
+ },
78
+ {
79
+ "id": "paf_18377899",
80
+ "suggestion": "Lo Dore, Park Road, Kilmacolm, PA13",
81
+ "udprn": 18377899,
82
+ "urls": {
83
+ "udprn": "/v1/udprn/18377899"
84
+ }
85
+ }
86
+ ]
87
+ },
88
+ "code": 2000,
89
+ "message": "Success"
90
+ },
91
+ "addresses": {
92
+ "paf_5692124": {
93
+ "postcode": "CT20 3NE",
94
+ "postcode_inward": "3NE",
95
+ "postcode_outward": "CT20",
96
+ "post_town": "Folkestone",
97
+ "dependant_locality": "",
98
+ "double_dependant_locality": "",
99
+ "thoroughfare": "Enbrook Valley",
100
+ "dependant_thoroughfare": "",
101
+ "building_number": "129",
102
+ "building_name": "",
103
+ "sub_building_name": "",
104
+ "po_box": "",
105
+ "department_name": "",
106
+ "organisation_name": "Lo Lo",
107
+ "udprn": 5692124,
108
+ "postcode_type": "S",
109
+ "su_organisation_indicator": "Y",
110
+ "delivery_point_suffix": "1T",
111
+ "line_1": "Lo Lo",
112
+ "line_2": "129 Enbrook Valley",
113
+ "line_3": "",
114
+ "premise": "129",
115
+ "longitude": 1.1460375,
116
+ "latitude": 51.0818226,
117
+ "eastings": 620445,
118
+ "northings": 136097,
119
+ "country": "England",
120
+ "traditional_county": "Kent",
121
+ "administrative_county": "Kent",
122
+ "postal_county": "Kent",
123
+ "county": "Kent",
124
+ "district": "Folkestone and Hythe",
125
+ "ward": "Sandgate & West Folkestone",
126
+ "uprn": "50027401",
127
+ "id": "paf_5692124",
128
+ "country_iso": "GBR",
129
+ "country_iso_2": "GB",
130
+ "county_code": "",
131
+ "language": "en",
132
+ "umprn": "",
133
+ "dataset": "paf"
134
+ },
135
+ "paf_15567850": {
136
+ "line_1": "Lo Lo Nails",
137
+ "line_2": "8 South Mall",
138
+ "line_3": "Edmonton Green Shopping Centre",
139
+ "post_town": "London",
140
+ "postcode": "N9 0TN"
141
+ },
142
+ "paf_51482484": {
143
+ "line_1": "1 Lo Grove",
144
+ "line_2": "",
145
+ "line_3": "",
146
+ "post_town": "Wakefield",
147
+ "postcode": "WF1 4HA"
148
+ },
149
+ "paf_51482485": {
150
+ "line_1": "2 Lo Grove",
151
+ "line_2": "",
152
+ "line_3": "",
153
+ "post_town": "Wakefield",
154
+ "postcode": "WF1 4HA"
155
+ },
156
+ "paf_51482486": {
157
+ "line_1": "3 Lo Grove",
158
+ "line_2": "",
159
+ "line_3": "",
160
+ "post_town": "Wakefield",
161
+ "postcode": "WF1 4HA"
162
+ },
163
+ "paf_51482487": {
164
+ "line_1": "4 Lo Grove",
165
+ "line_2": "",
166
+ "line_3": "",
167
+ "post_town": "Wakefield",
168
+ "postcode": "WF1 4HA"
169
+ },
170
+ "paf_52933093": {
171
+ "line_1": "5 Lo Grove",
172
+ "line_2": "",
173
+ "line_3": "",
174
+ "post_town": "Wakefield",
175
+ "postcode": "WF1 4HA"
176
+ },
177
+ "paf_5859369": {
178
+ "line_1": "High Lo",
179
+ "line_2": "Dalehouse Lane",
180
+ "line_3": "",
181
+ "post_town": "Kenilworth",
182
+ "postcode": "CV8 2EB"
183
+ },
184
+ "paf_24383125": {
185
+ "line_1": "Kwai Lo",
186
+ "line_2": "Winterhay Lane",
187
+ "line_3": "",
188
+ "post_town": "Ilminster",
189
+ "postcode": "TA19 9PH"
190
+ },
191
+ "paf_18377899": {
192
+ "line_1": "Lo Dore",
193
+ "line_2": "Park Road",
194
+ "line_3": "",
195
+ "post_town": "Kilmacolm",
196
+ "postcode": "PA13 4EE"
197
+ }
198
+ }
199
+ }
200
+ }
@@ -122,7 +122,7 @@
122
122
  },
123
123
  {
124
124
  "name": "Payment details:",
125
- "value": "<div class='google-logo-img mt-1'><img src='img/googlepay.svg' alt='Google Pay'></div>",
125
+ "value": "<div class='google-logo-img mt-1 '><img src='img/googlepay.svg' alt='Google Pay'></div>",
126
126
  "additional-value": "Card: Visa 1234"
127
127
  },
128
128
  {
@@ -205,6 +205,51 @@
205
205
  }
206
206
  ]
207
207
  },
208
+ "wismo-order-payment-giftcard-split" : {
209
+ "items": [
210
+ {
211
+ "name": "Billing address:",
212
+ "value": "Mr John Smith<br>19 Colonial Way, Watford, WD24 4JL,<br>United Kingdom"
213
+ },
214
+ {
215
+ "name": "Delivery address:",
216
+ "value": "Mr John Smith <br>19 Colonial Way, Watford, WD24 4JL,<br> United Kingdom"
217
+ },
218
+ {
219
+ "name": "Payment details:",
220
+ "gift-cards": ["************92712", "************48610", "************17746"],
221
+ "card-info": {
222
+ "provider": "Visa",
223
+ "maskedPin": "12341******12345",
224
+ "expires": "Expires 06 / 28"
225
+ }
226
+ },
227
+ {
228
+ "name": "Voucher:",
229
+ "value": "-"
230
+ }
231
+ ]
232
+ },
233
+ "wismo-order-payment-giftcard" : {
234
+ "items": [
235
+ {
236
+ "name": "Order address:",
237
+ "value": "Mr John Smith<br>19 Colonial Way, Watford, WD24 4JL,<br>United Kingdom"
238
+ },
239
+ {
240
+ "name": "Delivery address:",
241
+ "value": "Mr John Smith <br>19 Colonial Way, Watford, WD24 4JL,<br> United Kingdom"
242
+ },
243
+ {
244
+ "name": "Payment details:",
245
+ "gift-cards": ["************92712", "************48610", "************17746"]
246
+ },
247
+ {
248
+ "name": "Voucher:",
249
+ "value": "-"
250
+ }
251
+ ]
252
+ },
208
253
  "wismo-order-transaction": {
209
254
  "orders": [
210
255
  {
@@ -187,6 +187,10 @@
187
187
  {
188
188
  "payment": "PayPal",
189
189
  "src": "./img/payment/footer/paypal.svg"
190
+ },
191
+ {
192
+ "payment": "Gift Card",
193
+ "src": "./img/payment/footer/giftcard.svg"
190
194
  }
191
195
  ]
192
196
  }
@@ -1,5 +1,5 @@
1
1
  {{#if textarea}}
2
- <textarea class="tbx {{#if textarea}}tbx_textarea{{/if}} {{#if error}}tbx_error{{/if}}" rows="{{textareaRows}}" cols="{{textareaCols}}" value="{{value}}" maxlength="{{maxlength}}" id="{{id}}" name="{{#if name}}{{name}}{{else}}{{id}}{{/if}}" {{#if disabled}}disabled{{/if}}></textarea>
2
+ <textarea class="tbx {{#if textarea}}tbx_textarea{{/if}} {{#if error}}tbx_error{{/if}}" rows="{{textareaRows}}" cols="{{textareaCols}}" value="{{value}}" maxlength="{{maxlength}}" id="{{id}}" name="{{#if name}}{{name}}{{else}}{{id}}{{/if}}" {{#if disabled}}disabled{{/if}}{{#if placeholder}} placeholder="{{placeholder}}"{{/if}}{{#if autocomplete}} autocomplete="{{autocomplete}}"{{/if}}{{#if dataAttr}} {{dataAttr}}{{/if}}></textarea>
3
3
  {{else if type}}
4
4
  <input
5
5
  type="{{type}}"
@@ -15,6 +15,7 @@
15
15
  {{#if maxlength}}maxlength="{{maxlength}}"{{/if}}
16
16
  {{#if inputmode}}inputmode="{{inputmode}}"{{/if}}
17
17
  {{#if autocomplete}}autocomplete="{{autocomplete}}"{{/if}}
18
+ {{#if dataAttr}}{{dataAttr}}{{/if}}
18
19
  >
19
20
  {{else}}
20
21
  <input
@@ -32,5 +33,6 @@
32
33
  {{#if maxlength}}maxlength="{{maxlength}}"{{/if}}
33
34
  {{#if inputmode}}inputmode="{{inputmode}}"{{/if}}
34
35
  {{#if autocomplete}}autocomplete="{{autocomplete}}"{{/if}}
36
+ {{#if dataAttr}}{{dataAttr}}{{/if}}
35
37
  >
36
38
  {{/if}}
@@ -0,0 +1,28 @@
1
+ <svg width="36" height="23" viewBox="0 0 36 23" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <g clip-path="url(#clip0_9103_110194)">
3
+ <rect width="36" height="22.5" rx="2.25" fill="white"/>
4
+ <path d="M31.875 19.5C29.625 19.125 27.375 15.75 27.375 15.75C27.375 15.75 25.5 18.75 23.25 19.5" stroke="#004587" stroke-width="1.35"/>
5
+ <path d="M22.3396 13.7778C23.0733 14.7513 24.6901 15.0189 26.4425 15.3385C26.4181 13.8977 26.0629 12.4876 25.3293 11.514C24.5957 10.5405 23.4966 10.1294 22.523 10.863C21.5495 11.5966 21.606 12.8042 22.3396 13.7778Z" fill="white" stroke="#004587" stroke-width="1.35"/>
6
+ <path d="M32.3733 13.7778C31.6396 14.7513 30.0228 15.0189 28.2703 15.3385C28.2948 13.8977 28.65 12.4876 29.3836 11.514C30.1172 10.5405 31.2163 10.1294 32.1899 10.863C33.1634 11.5966 33.1069 12.8042 32.3733 13.7778Z" fill="white" stroke="#004587" stroke-width="1.35"/>
7
+ <g clip-path="url(#clip1_9103_110194)">
8
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M2.25 0V9.15602L12.3866 11.2286L22.532 9.13257V0H2.25Z" fill="white"/>
9
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M2.92773 0.664062V8.61365L12.3876 10.5436L21.8607 8.61276V0.664062H2.92773Z" fill="#004587"/>
10
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M11.8332 5.78902C11.8267 5.56557 11.6264 5.40914 11.4047 5.40914C10.9115 5.40914 10.8341 5.82081 10.8341 6.18699C10.8341 6.52756 10.9838 6.87855 11.3563 6.87855C11.6619 6.87855 11.8167 6.70611 11.8583 6.42585H12.7143C12.6351 7.13387 12.0747 7.53996 11.3623 7.53996C10.5538 7.53996 9.95312 6.99672 9.95312 6.18699C9.95312 5.34674 10.4972 4.74609 11.3623 4.74609C12.0287 4.74609 12.6251 5.09351 12.686 5.78902H11.8332Z" fill="white"/>
11
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M12.8652 3.83203H13.7461V5.70404L14.5498 4.82462H15.5691L14.5857 5.82161L15.6932 7.46473H14.6312L13.9753 6.40141L13.7461 6.61964V7.46473H12.8652V3.83203Z" fill="white"/>
12
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M16.3009 6.35415C16.3162 6.71482 16.5282 6.95472 16.9022 6.95472C17.1135 6.95472 17.3203 6.85867 17.4044 6.66523H18.2271C18.0667 7.2766 17.491 7.53988 16.8903 7.53988C16.0166 7.53988 15.4199 7.02211 15.4199 6.13711C15.4199 5.32686 16.079 4.74609 16.8697 4.74609C17.8325 4.74609 18.3146 5.45947 18.2734 6.35415H16.3009ZM17.3928 5.87166C17.3778 5.57584 17.1651 5.33177 16.8697 5.33177C16.5594 5.33177 16.3526 5.55068 16.301 5.87166H17.3928Z" fill="white"/>
13
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M19.1879 6.59204C19.1879 6.72636 19.2428 6.82286 19.3324 6.88801C19.4145 6.94929 19.5336 6.98048 19.6585 6.98048C19.8295 6.98048 20.0734 6.91005 20.0734 6.69971C20.0734 6.49599 19.798 6.45675 19.6436 6.42071C19.0882 6.28297 18.3948 6.26592 18.3948 5.55634C18.3948 4.92099 19.0939 4.74609 19.6225 4.74609C20.2134 4.74609 20.8282 4.91504 20.86 5.60265H20.0463C20.0463 5.48933 20.0061 5.41889 19.9327 5.37154C19.8592 5.32679 19.7627 5.30482 19.6537 5.30482C19.5079 5.30482 19.276 5.32128 19.276 5.50489C19.276 5.75387 19.8658 5.79967 20.2703 5.88522C20.8122 5.99281 20.9534 6.37909 20.9534 6.59882C20.9534 7.30713 20.2703 7.53988 19.6638 7.53988C19.026 7.53988 18.3737 7.3323 18.3477 6.59204H19.1879Z" fill="white"/>
14
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M7.78099 7.46473H6.81584L6.30981 4.96222H6.29784L5.79173 7.46473H4.81408L3.81445 3.83203H4.77611L5.30124 6.48651H5.31011L5.85305 3.83203H6.75878L7.30308 6.48651H7.31323L7.83632 3.83203H8.79896L7.78099 7.46473Z" fill="white"/>
15
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M8.86499 4.49387H9.74677V3.83202H8.86499V4.49387ZM8.86499 7.46479H9.74677V4.82461H8.86499V7.46479Z" fill="white"/>
16
+ </g>
17
+ <path d="M27.375 0V16.125M27.375 22.5V16.125M27.375 16.125H35.625M27.375 16.125H0.75" stroke="#004587" stroke-width="1.35"/>
18
+ </g>
19
+ <rect x="0.375" y="0.375" width="35.25" height="21.75" rx="1.875" stroke="#CCCCCC" stroke-width="0.75"/>
20
+ <defs>
21
+ <clipPath id="clip0_9103_110194">
22
+ <rect width="36" height="22.5" rx="2.25" fill="white"/>
23
+ </clipPath>
24
+ <clipPath id="clip1_9103_110194">
25
+ <rect width="20.25" height="11.2277" fill="white" transform="translate(2.25)"/>
26
+ </clipPath>
27
+ </defs>
28
+ </svg>
@@ -0,0 +1,28 @@
1
+ <svg width="36" height="23" viewBox="0 0 36 23" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <g clip-path="url(#clip0_9103_110194)">
3
+ <rect width="36" height="22.5" rx="2.25" fill="white"/>
4
+ <path d="M31.875 19.5C29.625 19.125 27.375 15.75 27.375 15.75C27.375 15.75 25.5 18.75 23.25 19.5" stroke="#004587" stroke-width="1.35"/>
5
+ <path d="M22.3396 13.7778C23.0733 14.7513 24.6901 15.0189 26.4425 15.3385C26.4181 13.8977 26.0629 12.4876 25.3293 11.514C24.5957 10.5405 23.4966 10.1294 22.523 10.863C21.5495 11.5966 21.606 12.8042 22.3396 13.7778Z" fill="white" stroke="#004587" stroke-width="1.35"/>
6
+ <path d="M32.3733 13.7778C31.6396 14.7513 30.0228 15.0189 28.2703 15.3385C28.2948 13.8977 28.65 12.4876 29.3836 11.514C30.1172 10.5405 31.2163 10.1294 32.1899 10.863C33.1634 11.5966 33.1069 12.8042 32.3733 13.7778Z" fill="white" stroke="#004587" stroke-width="1.35"/>
7
+ <g clip-path="url(#clip1_9103_110194)">
8
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M2.25 0V9.15602L12.3866 11.2286L22.532 9.13257V0H2.25Z" fill="white"/>
9
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M2.92773 0.664062V8.61365L12.3876 10.5436L21.8607 8.61276V0.664062H2.92773Z" fill="#004587"/>
10
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M11.8332 5.78902C11.8267 5.56557 11.6264 5.40914 11.4047 5.40914C10.9115 5.40914 10.8341 5.82081 10.8341 6.18699C10.8341 6.52756 10.9838 6.87855 11.3563 6.87855C11.6619 6.87855 11.8167 6.70611 11.8583 6.42585H12.7143C12.6351 7.13387 12.0747 7.53996 11.3623 7.53996C10.5538 7.53996 9.95312 6.99672 9.95312 6.18699C9.95312 5.34674 10.4972 4.74609 11.3623 4.74609C12.0287 4.74609 12.6251 5.09351 12.686 5.78902H11.8332Z" fill="white"/>
11
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M12.8652 3.83203H13.7461V5.70404L14.5498 4.82462H15.5691L14.5857 5.82161L15.6932 7.46473H14.6312L13.9753 6.40141L13.7461 6.61964V7.46473H12.8652V3.83203Z" fill="white"/>
12
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M16.3009 6.35415C16.3162 6.71482 16.5282 6.95472 16.9022 6.95472C17.1135 6.95472 17.3203 6.85867 17.4044 6.66523H18.2271C18.0667 7.2766 17.491 7.53988 16.8903 7.53988C16.0166 7.53988 15.4199 7.02211 15.4199 6.13711C15.4199 5.32686 16.079 4.74609 16.8697 4.74609C17.8325 4.74609 18.3146 5.45947 18.2734 6.35415H16.3009ZM17.3928 5.87166C17.3778 5.57584 17.1651 5.33177 16.8697 5.33177C16.5594 5.33177 16.3526 5.55068 16.301 5.87166H17.3928Z" fill="white"/>
13
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M19.1879 6.59204C19.1879 6.72636 19.2428 6.82286 19.3324 6.88801C19.4145 6.94929 19.5336 6.98048 19.6585 6.98048C19.8295 6.98048 20.0734 6.91005 20.0734 6.69971C20.0734 6.49599 19.798 6.45675 19.6436 6.42071C19.0882 6.28297 18.3948 6.26592 18.3948 5.55634C18.3948 4.92099 19.0939 4.74609 19.6225 4.74609C20.2134 4.74609 20.8282 4.91504 20.86 5.60265H20.0463C20.0463 5.48933 20.0061 5.41889 19.9327 5.37154C19.8592 5.32679 19.7627 5.30482 19.6537 5.30482C19.5079 5.30482 19.276 5.32128 19.276 5.50489C19.276 5.75387 19.8658 5.79967 20.2703 5.88522C20.8122 5.99281 20.9534 6.37909 20.9534 6.59882C20.9534 7.30713 20.2703 7.53988 19.6638 7.53988C19.026 7.53988 18.3737 7.3323 18.3477 6.59204H19.1879Z" fill="white"/>
14
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M7.78099 7.46473H6.81584L6.30981 4.96222H6.29784L5.79173 7.46473H4.81408L3.81445 3.83203H4.77611L5.30124 6.48651H5.31011L5.85305 3.83203H6.75878L7.30308 6.48651H7.31323L7.83632 3.83203H8.79896L7.78099 7.46473Z" fill="white"/>
15
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M8.86499 4.49387H9.74677V3.83202H8.86499V4.49387ZM8.86499 7.46479H9.74677V4.82461H8.86499V7.46479Z" fill="white"/>
16
+ </g>
17
+ <path d="M27.375 0V16.125M27.375 22.5V16.125M27.375 16.125H35.625M27.375 16.125H0.75" stroke="#004587" stroke-width="1.35"/>
18
+ </g>
19
+ <rect x="0.375" y="0.375" width="35.25" height="21.75" rx="1.875" stroke="#CCCCCC" stroke-width="0.75"/>
20
+ <defs>
21
+ <clipPath id="clip0_9103_110194">
22
+ <rect width="36" height="22.5" rx="2.25" fill="white"/>
23
+ </clipPath>
24
+ <clipPath id="clip1_9103_110194">
25
+ <rect width="20.25" height="11.2277" fill="white" transform="translate(2.25)"/>
26
+ </clipPath>
27
+ </defs>
28
+ </svg>
@@ -1,67 +1,74 @@
1
1
  var Wick = Wick || {};
2
- Wick.Footer = (function(){
3
- let $accordion = $('.footer-menu__inner .accordion'),
4
- $accordionContent = $('.footer-menu__inner .accordion__content'),
5
- $paymentList = $('footer .payments__list'),
6
- $waysToPayList = $('footer .payways__list'),
7
- $paymentListCheckoutFooter = $('footer .payments-checkout__list'),
8
- $paymentListOrderSummery = $('.right-aside .footer-checkout .payments-checkout__list'),
9
- paymentSmallListClass = 'payments__list--small',
10
- waysToPaySmallListClass = 'payways__list--small',
11
- paymentCheckoutSmallListClass = 'payments-checkout__list--small',
12
- collapsedState = "accordion_collapsed",
13
- windowWidth = $(window).width();
2
+ Wick.Footer = (function () {
3
+ let $accordion = $('.footer-menu__inner .accordion'),
4
+ $accordionContent = $('.footer-menu__inner .accordion__content'),
5
+ $paymentList = $('footer .payments__list'),
6
+ $paymentListCheckoutFooter = $('footer .payments-checkout__list'),
7
+ $paymentListOrderSummery = $('.right-aside .footer-checkout .payments-checkout__list'),
8
+ paymentSmallListClass = 'payments__list--small',
9
+ paymentCheckoutSmallListClass = 'payments-checkout__list--small',
10
+ collapsedState = 'accordion_collapsed',
11
+ windowWidth = $(window).width();
14
12
 
15
- const elementClassAdjustments = [
16
- { $element: $paymentList, count: 6, className: paymentSmallListClass },
17
- { $element: $paymentListOrderSummery, count: 6, className: paymentCheckoutSmallListClass, isGreaterThan: true },
18
- { $element: $paymentListCheckoutFooter, count: 6, className: paymentCheckoutSmallListClass, isGreaterThan: false },
19
- { $element: $waysToPayList, count: 6, className: waysToPaySmallListClass, isGreaterThan: false, checkForWindowWidth: true }
20
- ];
13
+ const elementClassAdjustments = [
14
+ { $element: $paymentList, count: 6, className: paymentSmallListClass },
15
+ {
16
+ $element: $paymentListOrderSummery,
17
+ count: 6,
18
+ className: paymentCheckoutSmallListClass,
19
+ isGreaterThan: true,
20
+ },
21
+ {
22
+ $element: $paymentListCheckoutFooter,
23
+ count: 6,
24
+ className: paymentCheckoutSmallListClass,
25
+ isGreaterThan: false,
26
+ },
27
+ ];
21
28
 
22
- function accordionClickHandler() {
23
- if ($(this).find($accordionContent).is(':visible')) {
24
- $accordionContent.hide()
25
- $accordion.not($(this)).removeClass(collapsedState)
26
- $(this).find($accordionContent).show()
29
+ function accordionClickHandler() {
30
+ if ($(this).find($accordionContent).is(':visible')) {
31
+ $accordionContent.hide();
32
+ $accordion.not($(this)).removeClass(collapsedState);
33
+ $(this).find($accordionContent).show();
34
+ }
27
35
  }
28
- }
29
36
 
30
- function applyClassBasedOnChildrenCount($element, count, className, isGreaterThan = false, checkForWindowWidth = false) {
31
- let hasEnoughChildren = isGreaterThan ? $element.children().length > count : $element.children().length < count;
37
+ function applyClassBasedOnChildrenCount(
38
+ $element,
39
+ count,
40
+ className,
41
+ isGreaterThan = false,
42
+ checkForWindowWidth = false
43
+ ) {
44
+ let hasEnoughChildren = isGreaterThan
45
+ ? $element.children().length > count
46
+ : $element.children().length < count;
32
47
 
33
- if(checkForWindowWidth && windowWidth < 576) {
34
- if(hasEnoughChildren) {
35
- $element.addClass(className);
36
- }
37
- } else if (!checkForWindowWidth) {
38
- if(hasEnoughChildren) {
39
- $element.addClass(className);
40
- }
48
+ if (checkForWindowWidth && windowWidth < 576) {
49
+ if (hasEnoughChildren) {
50
+ $element.addClass(className);
51
+ }
52
+ } else if (!checkForWindowWidth) {
53
+ if (hasEnoughChildren) {
54
+ $element.addClass(className);
55
+ }
56
+ }
41
57
  }
42
- }
43
58
 
44
- function onWindowResize() {
45
- windowWidth = $(window).width();
59
+ function init() {
60
+ $accordion.click(accordionClickHandler);
46
61
 
47
- let isChildrenCountLessThanSix = $waysToPayList.children().length < 6;
48
-
49
- if(isChildrenCountLessThanSix && windowWidth > 576 ) {
50
- $waysToPayList.removeClass(waysToPaySmallListClass);
51
- } else if (isChildrenCountLessThanSix) {
52
- $waysToPayList.addClass(waysToPaySmallListClass);
62
+ elementClassAdjustments.forEach(function (item) {
63
+ applyClassBasedOnChildrenCount(
64
+ item.$element,
65
+ item.count,
66
+ item.className,
67
+ item.isGreaterThan,
68
+ item.checkForWindowWidth
69
+ );
70
+ });
53
71
  }
54
- }
55
-
56
- function init () {
57
- $accordion.click(accordionClickHandler);
58
-
59
- elementClassAdjustments.forEach(function(item) {
60
- applyClassBasedOnChildrenCount(item.$element, item.count, item.className, item.isGreaterThan, item.checkForWindowWidth);
61
- });
62
-
63
- $(window).resize(_.debounce(onWindowResize, 200));
64
- }
65
72
 
66
- init();
67
- })();
73
+ init();
74
+ })();
@@ -14,6 +14,8 @@ Wick.PaymentDetails = (function () {
14
14
  function bindEvents() {
15
15
  $btnEnterDetails.on('click', function (e) {
16
16
  e.preventDefault();
17
+ if ($(this).attr('data-mode') === 'giftcards') return;
18
+
17
19
  var $scope = $(this).closest('form');
18
20
  if (!$scope.length) $scope = $(this).closest('.billing-address');
19
21
  if (!$scope.length) $scope = $('.billing-address');
@@ -26,6 +26,14 @@ var Wick = Wick || {};
26
26
  const GIFT_CARDS_LIMIT = 3;
27
27
  const BASE_ORDER_TOTAL = 300.0;
28
28
 
29
+ const MOCK_DELIVERY_ADDRESS = {
30
+ '#order-first-name': 'John',
31
+ '#order-surname': 'Smith',
32
+ '#order-address-address-line-1': '129 Enbrook Valley',
33
+ '#order-address-town-city': 'Folkestone',
34
+ '#order-address-postcode': 'CT20 3NE',
35
+ };
36
+
29
37
  let PAY_ERROR_CODE;
30
38
 
31
39
  const mock = {
@@ -213,5 +221,19 @@ var Wick = Wick || {};
213
221
  });
214
222
  });
215
223
 
224
+ function initOrderAddressDeliveryMock() {
225
+ $('#chb-order-address-delivery').on('change', function () {
226
+ if (!this.checked) {
227
+ Wick.GiftCard.resetOrderAddress();
228
+ return;
229
+ }
230
+
231
+ Object.keys(MOCK_DELIVERY_ADDRESS).forEach((selector) => {
232
+ $(selector).val(MOCK_DELIVERY_ADDRESS[selector]).trigger('change');
233
+ });
234
+ });
235
+ }
236
+
216
237
  $(document).ready(initGiftCardMock);
238
+ $(document).ready(initOrderAddressDeliveryMock);
217
239
  })();
@@ -4039,28 +4039,29 @@ Wick.FEMock = {
4039
4039
 
4040
4040
  Wick.FEMock.dataBloomreach.similarProductsRecommendations = {
4041
4041
  ...Wick.FEMock.dataBloomreach.whyNotAddRecommendations,
4042
- recommendedProducts: Wick.FEMock.dataBloomreach.whyNotAddRecommendations.recommendedProducts.map(
4043
- function (recommendation, index) {
4044
- if (index !== 1) {
4045
- return recommendation;
4046
- }
4042
+ recommendedProducts:
4043
+ Wick.FEMock.dataBloomreach.whyNotAddRecommendations.recommendedProducts.map(
4044
+ function (recommendation, index) {
4045
+ if (index !== 1) {
4046
+ return recommendation;
4047
+ }
4047
4048
 
4048
- return {
4049
- ...recommendation,
4050
- baseProduct: {
4051
- ...recommendation.baseProduct,
4052
- displayPrice: {
4053
- ...recommendation.baseProduct.displayPrice,
4054
- wasPrice: 9.99,
4055
- },
4056
- displayPriceExclusiveVat: {
4057
- ...recommendation.baseProduct.displayPriceExclusiveVat,
4058
- wasPrice: 8.33,
4049
+ return {
4050
+ ...recommendation,
4051
+ baseProduct: {
4052
+ ...recommendation.baseProduct,
4053
+ displayPrice: {
4054
+ ...recommendation.baseProduct.displayPrice,
4055
+ wasPrice: 9.99,
4056
+ },
4057
+ displayPriceExclusiveVat: {
4058
+ ...recommendation.baseProduct.displayPriceExclusiveVat,
4059
+ wasPrice: 8.33,
4060
+ },
4059
4061
  },
4060
- },
4061
- };
4062
- }
4063
- ),
4062
+ };
4063
+ }
4064
+ ),
4064
4065
  widgetMetadata: {
4065
4066
  responseId: 'mock-similar-products-response',
4066
4067
  id: 'similar-products-12345',
@@ -8,4 +8,4 @@ function bindPostcodeCheckAvailabilityEvent() {
8
8
 
9
9
  $(document).ready(function () {
10
10
  bindPostcodeCheckAvailabilityEvent();
11
- });
11
+ });