@financial-times/n-conversion-forms 37.2.0 → 37.2.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.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "branch": "",
3
3
  "repo": "n-conversion-forms",
4
- "version": "e6de5072ce6f5873fcf887ed859149b61ca0ed6b",
5
- "tag": "v37.2.0"
4
+ "version": "56f6ac0285fa7afa997c8bee965da17a69a9315d",
5
+ "tag": "v37.2.1"
6
6
  }
@@ -13,7 +13,7 @@ exports[`DeliveryStartDate renders with a custom date 1`] = `
13
13
  Start date
14
14
  </span>
15
15
  <span class="o-forms-title__prompt">
16
- The first print edition you will receive is: 5th November 2019
16
+ Earliest available delivery date: 5th November 2019
17
17
  </span>
18
18
  </span>
19
19
  <span class="o-forms-input o-forms-input--text">
@@ -29,6 +29,12 @@ exports[`DeliveryStartDate renders with a custom date 1`] = `
29
29
  Please select a valid start date
30
30
  </span>
31
31
  </span>
32
+ <p>
33
+ The first print edition you will receive is:
34
+ <strong class="js-start-date-text">
35
+ 5th November 2019
36
+ </strong>
37
+ </p>
32
38
  </label>
33
39
  `;
34
40
 
@@ -45,7 +51,7 @@ exports[`DeliveryStartDate renders with a custom input max value 1`] = `
45
51
  Start date
46
52
  </span>
47
53
  <span class="o-forms-title__prompt">
48
- The first print edition you will receive is: 2
54
+ Earliest available delivery date: 2
49
55
  </span>
50
56
  </span>
51
57
  <span class="o-forms-input o-forms-input--text">
@@ -61,6 +67,12 @@ exports[`DeliveryStartDate renders with a custom input max value 1`] = `
61
67
  Please select a valid start date
62
68
  </span>
63
69
  </span>
70
+ <p>
71
+ The first print edition you will receive is:
72
+ <strong class="js-start-date-text">
73
+ 2
74
+ </strong>
75
+ </p>
64
76
  </label>
65
77
  `;
66
78
 
@@ -77,7 +89,7 @@ exports[`DeliveryStartDate renders with a custom input min value 1`] = `
77
89
  Start date
78
90
  </span>
79
91
  <span class="o-forms-title__prompt">
80
- The first print edition you will receive is:
92
+ Earliest available delivery date:
81
93
  </span>
82
94
  </span>
83
95
  <span class="o-forms-input o-forms-input--text">
@@ -94,6 +106,11 @@ exports[`DeliveryStartDate renders with a custom input min value 1`] = `
94
106
  Please select a valid start date
95
107
  </span>
96
108
  </span>
109
+ <p>
110
+ The first print edition you will receive is:
111
+ <strong class="js-start-date-text">
112
+ </strong>
113
+ </p>
97
114
  </label>
98
115
  `;
99
116
 
@@ -110,7 +127,7 @@ exports[`DeliveryStartDate renders with a custom input value 1`] = `
110
127
  Start date
111
128
  </span>
112
129
  <span class="o-forms-title__prompt">
113
- The first print edition you will receive is:
130
+ Earliest available delivery date:
114
131
  </span>
115
132
  </span>
116
133
  <span class="o-forms-input o-forms-input--text">
@@ -126,6 +143,11 @@ exports[`DeliveryStartDate renders with a custom input value 1`] = `
126
143
  Please select a valid start date
127
144
  </span>
128
145
  </span>
146
+ <p>
147
+ The first print edition you will receive is:
148
+ <strong class="js-start-date-text">
149
+ </strong>
150
+ </p>
129
151
  </label>
130
152
  `;
131
153
 
@@ -142,7 +164,7 @@ exports[`DeliveryStartDate renders with a disabled input 1`] = `
142
164
  Start date
143
165
  </span>
144
166
  <span class="o-forms-title__prompt">
145
- The first print edition you will receive is:
167
+ Earliest available delivery date:
146
168
  </span>
147
169
  </span>
148
170
  <span class="o-forms-input o-forms-input--text">
@@ -159,6 +181,11 @@ exports[`DeliveryStartDate renders with a disabled input 1`] = `
159
181
  Please select a valid start date
160
182
  </span>
161
183
  </span>
184
+ <p>
185
+ The first print edition you will receive is:
186
+ <strong class="js-start-date-text">
187
+ </strong>
188
+ </p>
162
189
  </label>
163
190
  `;
164
191
 
@@ -175,7 +202,7 @@ exports[`DeliveryStartDate renders with an error 1`] = `
175
202
  Start date
176
203
  </span>
177
204
  <span class="o-forms-title__prompt">
178
- The first print edition you will receive is:
205
+ Earliest available delivery date:
179
206
  </span>
180
207
  </span>
181
208
  <span class="o-forms-input o-forms-input--text o-forms-input--invalid">
@@ -191,6 +218,11 @@ exports[`DeliveryStartDate renders with an error 1`] = `
191
218
  Please select a valid start date
192
219
  </span>
193
220
  </span>
221
+ <p>
222
+ The first print edition you will receive is:
223
+ <strong class="js-start-date-text">
224
+ </strong>
225
+ </p>
194
226
  </label>
195
227
  `;
196
228
 
@@ -207,7 +239,7 @@ exports[`DeliveryStartDate renders with appropriate start message when isAddress
207
239
  Start date
208
240
  </span>
209
241
  <span class="o-forms-title__prompt">
210
- The first print edition you will receive is:
242
+ Earliest available delivery date:
211
243
  </span>
212
244
  </span>
213
245
  <span class="o-forms-input o-forms-input--text">
@@ -244,7 +276,7 @@ exports[`DeliveryStartDate renders with country different than default 1`] = `
244
276
  Start date
245
277
  </span>
246
278
  <span class="o-forms-title__prompt">
247
- The first print edition you will receive is:
279
+ Earliest available delivery date:
248
280
  </span>
249
281
  </span>
250
282
  <span class="o-forms-input o-forms-input--text">
@@ -260,6 +292,11 @@ exports[`DeliveryStartDate renders with country different than default 1`] = `
260
292
  Please select a valid start date
261
293
  </span>
262
294
  </span>
295
+ <p>
296
+ The first print edition you will receive is:
297
+ <strong class="js-start-date-text">
298
+ </strong>
299
+ </p>
263
300
  </label>
264
301
  `;
265
302
 
@@ -276,7 +313,7 @@ exports[`DeliveryStartDate renders with default props 1`] = `
276
313
  Start date
277
314
  </span>
278
315
  <span class="o-forms-title__prompt">
279
- The first print edition you will receive is:
316
+ Earliest available delivery date:
280
317
  </span>
281
318
  </span>
282
319
  <span class="o-forms-input o-forms-input--text">
@@ -292,5 +329,10 @@ exports[`DeliveryStartDate renders with default props 1`] = `
292
329
  Please select a valid start date
293
330
  </span>
294
331
  </span>
332
+ <p>
333
+ The first print edition you will receive is:
334
+ <strong class="js-start-date-text">
335
+ </strong>
336
+ </p>
295
337
  </label>
296
338
  `;
@@ -30,6 +30,10 @@ export function DeliveryStartDate({
30
30
  defaultValue: value,
31
31
  };
32
32
 
33
+ const startMessage = isAddressUpdate
34
+ ? 'We’ll start delivering to this address from:'
35
+ : 'The first print edition you will receive is:';
36
+
33
37
  return (
34
38
  <label
35
39
  id="deliveryStartDateField"
@@ -42,7 +46,7 @@ export function DeliveryStartDate({
42
46
  Start date
43
47
  </span>
44
48
  <span className="o-forms-title__prompt">
45
- The first print edition you will receive is: {date}
49
+ Earliest available delivery date: {date}
46
50
  </span>
47
51
  </span>
48
52
 
@@ -53,12 +57,9 @@ export function DeliveryStartDate({
53
57
  </span>
54
58
  </span>
55
59
 
56
- {isAddressUpdate && (
57
- <p>
58
- We’ll start delivering to this address from:{' '}
59
- <strong className="js-start-date-text">{date}</strong>
60
- </p>
61
- )}
60
+ <p>
61
+ {startMessage} <strong className="js-start-date-text">{date}</strong>
62
+ </p>
62
63
  </label>
63
64
  );
64
65
  }
@@ -44,6 +44,7 @@ function DeliveryStartDate(_ref) {
44
44
  disabled: isDisabled,
45
45
  defaultValue: value
46
46
  });
47
+ var startMessage = isAddressUpdate ? 'We’ll start delivering to this address from:' : 'The first print edition you will receive is:';
47
48
  return /*#__PURE__*/_react["default"].createElement("label", {
48
49
  id: "deliveryStartDateField",
49
50
  className: "o-forms-field ncf__validation-error",
@@ -56,11 +57,11 @@ function DeliveryStartDate(_ref) {
56
57
  id: "start-date-picker-title-span"
57
58
  }, "Start date"), /*#__PURE__*/_react["default"].createElement("span", {
58
59
  className: "o-forms-title__prompt"
59
- }, "The first print edition you will receive is: ", date)), /*#__PURE__*/_react["default"].createElement("span", {
60
+ }, "Earliest available delivery date: ", date)), /*#__PURE__*/_react["default"].createElement("span", {
60
61
  className: inputWrapperClassNames
61
62
  }, /*#__PURE__*/_react["default"].createElement("input", inputProps), /*#__PURE__*/_react["default"].createElement("span", {
62
63
  className: "o-forms-input__error"
63
- }, "Please select a valid start date")), isAddressUpdate && /*#__PURE__*/_react["default"].createElement("p", null, "We\u2019ll start delivering to this address from:", ' ', /*#__PURE__*/_react["default"].createElement("strong", {
64
+ }, "Please select a valid start date")), /*#__PURE__*/_react["default"].createElement("p", null, startMessage, " ", /*#__PURE__*/_react["default"].createElement("strong", {
64
65
  className: "js-start-date-text"
65
66
  }, date)));
66
67
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@financial-times/n-conversion-forms",
3
- "version": "37.2.0",
3
+ "version": "37.2.1",
4
4
  "description": "Containing jsx components and styles for forms included on Accounts and Acquisition apps (next-signup, next-profile, next-retention, etc).",
5
5
  "main": "./dist/index.js",
6
6
  "scripts": {