@financial-times/n-conversion-forms 41.3.1 → 42.0.0

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 (113) hide show
  1. package/.storybook/preview-body.html +3 -0
  2. package/.storybook/preview.js +2 -2
  3. package/.toolkitstate/ci.json +3 -3
  4. package/.toolkitstate/install.json +1 -1
  5. package/components/__snapshots__/accept-terms.spec.js.snap +107 -150
  6. package/components/__snapshots__/b2c-partnership-confirmation.spec.js.snap +36 -72
  7. package/components/__snapshots__/confirmation.spec.js.snap +71 -127
  8. package/components/__snapshots__/continue-reading.spec.js.snap +3 -3
  9. package/components/__snapshots__/customer-care.spec.js.snap +16 -24
  10. package/components/__snapshots__/debug.spec.js.snap +13 -7
  11. package/components/__snapshots__/deferred-billing-terms.spec.js.snap +12 -18
  12. package/components/__snapshots__/error-page.spec.js.snap +12 -18
  13. package/components/__snapshots__/fieldset.spec.js.snap +1 -1
  14. package/components/__snapshots__/ft-edit-registration-confirmation.spec.js.snap +5 -5
  15. package/components/__snapshots__/graduation-date.spec.js.snap +4 -6
  16. package/components/__snapshots__/industry.spec.js.snap +8 -706
  17. package/components/__snapshots__/licence-confirmation.spec.js.snap +17 -28
  18. package/components/__snapshots__/licence-header.spec.js.snap +1 -1
  19. package/components/__snapshots__/licence-sign-in.spec.js.snap +1 -1
  20. package/components/__snapshots__/loader.spec.js.snap +1 -1
  21. package/components/__snapshots__/package-change.spec.js.snap +16 -11
  22. package/components/__snapshots__/payment-term.spec.js.snap +40 -60
  23. package/components/__snapshots__/position.spec.js.snap +8 -262
  24. package/components/__snapshots__/registration-confirmation.spec.js.snap +9 -7
  25. package/components/__snapshots__/responsibility.spec.js.snap +8 -442
  26. package/components/__snapshots__/submit.spec.js.snap +6 -6
  27. package/components/accept-terms-business.jsx +2 -3
  28. package/components/accept-terms-business.spec.jsx +3 -1
  29. package/components/accept-terms-privacy-policy.jsx +2 -5
  30. package/components/accept-terms-privacy-policy.spec.js +1 -1
  31. package/components/accept-terms-subscription.jsx +7 -12
  32. package/components/accept-terms-subscription.spec.js +1 -1
  33. package/components/accept-terms.jsx +12 -20
  34. package/components/b2c-partnership-confirmation.jsx +3 -5
  35. package/components/confirmation.jsx +5 -9
  36. package/components/confirmation.stories.js +4 -6
  37. package/components/continue-reading.jsx +1 -1
  38. package/components/customer-care.jsx +4 -4
  39. package/components/debug.jsx +12 -12
  40. package/components/deferred-billing-terms.jsx +3 -6
  41. package/components/error-page.jsx +4 -4
  42. package/components/fieldset.jsx +1 -1
  43. package/components/ft-edit-registration-confirmation.jsx +2 -2
  44. package/components/graduation-date.jsx +2 -4
  45. package/components/index.js +0 -1
  46. package/components/industry.jsx +1 -3
  47. package/components/industry.spec.js +7 -2
  48. package/components/licence-confirmation.jsx +2 -3
  49. package/components/licence-confirmation.stories.js +1 -1
  50. package/components/licence-sign-in.jsx +1 -1
  51. package/components/loader.jsx +4 -1
  52. package/components/package-change.jsx +4 -5
  53. package/components/payment-term.jsx +3 -5
  54. package/components/position.jsx +1 -2
  55. package/components/position.spec.js +7 -2
  56. package/components/proceed-with-payment-link.jsx +8 -2
  57. package/components/proceed-with-payment-link.stories.js +1 -1
  58. package/components/registration-confirmation.jsx +5 -3
  59. package/components/responsibility.jsx +1 -2
  60. package/components/responsibility.spec.js +7 -2
  61. package/components/submit.jsx +1 -1
  62. package/components/subscription-confirmation-with-payment-link.jsx +1 -1
  63. package/dist/accept-terms-business.jsx +2 -3
  64. package/dist/accept-terms-business.spec.jsx +1 -1
  65. package/dist/accept-terms-privacy-policy.jsx +2 -5
  66. package/dist/accept-terms-subscription.jsx +7 -12
  67. package/dist/accept-terms.jsx +10 -20
  68. package/dist/b2c-partnership-confirmation.jsx +5 -7
  69. package/dist/confirmation.jsx +4 -7
  70. package/dist/continue-reading.jsx +1 -1
  71. package/dist/customer-care.jsx +3 -4
  72. package/dist/debug.jsx +6 -6
  73. package/dist/deferred-billing-terms.jsx +3 -6
  74. package/dist/error-page.jsx +3 -4
  75. package/dist/fieldset.jsx +1 -1
  76. package/dist/ft-edit-registration-confirmation.jsx +2 -2
  77. package/dist/graduation-date.jsx +6 -4
  78. package/dist/index.js +0 -7
  79. package/dist/industry.jsx +1 -3
  80. package/dist/licence-confirmation.jsx +3 -4
  81. package/dist/licence-sign-in.jsx +1 -1
  82. package/dist/loader.jsx +1 -1
  83. package/dist/package-change.jsx +5 -4
  84. package/dist/payment-term.jsx +6 -4
  85. package/dist/position.jsx +1 -2
  86. package/dist/proceed-with-payment-link.jsx +2 -2
  87. package/dist/registration-confirmation.jsx +7 -5
  88. package/dist/responsibility.jsx +1 -2
  89. package/dist/submit.jsx +1 -1
  90. package/dist/subscription-confirmation-with-payment-link.jsx +1 -1
  91. package/main.scss +132 -167
  92. package/package.json +3 -6
  93. package/styles/_shared.scss +125 -100
  94. package/styles/accept-terms.scss +6 -5
  95. package/styles/banner.scss +66 -60
  96. package/styles/confirmation.scss +50 -55
  97. package/styles/continue-reading.scss +56 -39
  98. package/styles/error.scss +1 -1
  99. package/styles/forms-additional-field-information.scss +8 -4
  100. package/styles/ft-edit-registration-confirmation.scss +228 -224
  101. package/styles/loader.scss +40 -45
  102. package/styles/package-change.scss +1 -4
  103. package/styles/payment-term.scss +108 -89
  104. package/styles/payment-type.scss +117 -112
  105. package/styles/proceed-with-payment-link.scss +32 -18
  106. package/styles/subscription-confirmation-with-payment-link.scss +64 -24
  107. package/components/__snapshots__/google-sign-in.spec.js.snap +0 -13
  108. package/components/google-sign-in.jsx +0 -21
  109. package/components/google-sign-in.spec.js +0 -14
  110. package/components/google-sign-in.stories.js +0 -13
  111. package/dist/google-sign-in.jsx +0 -24
  112. package/helpers/demographics.js +0 -606
  113. package/styles/google-sign-in.scss +0 -26
@@ -5,7 +5,8 @@ exports[`Debug renders with default props 1`] = `""`;
5
5
  exports[`Debug renders with isTest 1`] = `
6
6
  <div class="ncf__debug-panel">
7
7
  <span class="ncf__debug-environment">
8
- <a class="ncf__button ncf__button--debug ncf__button--inverse ncf__debug-button--test"
8
+ <a class="ncf__button ncf__button--debug o3-button o3-button--secondary ncf__debug-button--test"
9
+ data-o3-theme="inverse"
9
10
  onclick="setTestEnvironment('off');"
10
11
  >
11
12
  <strong>
@@ -153,7 +154,8 @@ exports[`Debug renders with links 1`] = `""`;
153
154
  exports[`Debug renders with showHelpers 1`] = `
154
155
  <div class="ncf__debug-panel">
155
156
  <span class="ncf__debug-environment">
156
- <a class="ncf__button ncf__button--debug ncf__button--inverse ncf__debug-button--production"
157
+ <a class="ncf__button ncf__button--debug o3-button o3-button--secondary ncf__debug-button--production"
158
+ data-o3-theme="inverse"
157
159
  onclick="setTestEnvironment('on');"
158
160
  >
159
161
  <strong>
@@ -162,26 +164,30 @@ exports[`Debug renders with showHelpers 1`] = `
162
164
  careful you are using the production API
163
165
  </a>
164
166
  </span>
165
- <span class="ncf__debug-helpers">
166
- <button class="ncf__button ncf__button--debug ncf__button--inverse"
167
+ <span class="ncf__debug-helpers o3-type-body-base">
168
+ <button class="ncf__button ncf__button--debug o3-button o3-button--secondary"
169
+ data-o3-theme="inverse"
167
170
  onclick="logout();"
168
171
  title="Logout and refresh"
169
172
  >
170
173
  Logout
171
174
  </button>
172
- <button class="ncf__button ncf__button--debug ncf__button--inverse"
175
+ <button class="ncf__button ncf__button--debug o3-button o3-button--secondary"
176
+ data-o3-theme="inverse"
173
177
  onclick="fillForm();"
174
178
  title="Fill form with debug data"
175
179
  >
176
180
  Fill
177
181
  </button>
178
- <button class="ncf__button ncf__button--debug ncf__button--inverse"
182
+ <button class="ncf__button ncf__button--debug o3-button o3-button--secondary"
183
+ data-o3-theme="inverse"
179
184
  onclick="fillForm(); submitForm();"
180
185
  title="Fill form with debug data and submit"
181
186
  >
182
187
  Fill &amp; Submit
183
188
  </button>
184
- <select class="ncf__button ncf__button--debug ncf__button--inverse ncf__button--max-width"
189
+ <select class="ncf__button ncf__button--debug o3-button o3-button--secondary ncf__button--max-width"
190
+ data-o3-theme="inverse"
185
191
  id="ncf-country"
186
192
  onchange="reloadWithSelectedCountry();"
187
193
  >
@@ -4,10 +4,9 @@ exports[`DeferredBillingTerms renders appropriately and checked 1`] = `""`;
4
4
 
5
5
  exports[`DeferredBillingTerms renders appropriately if a isDeferredBilling 1`] = `
6
6
  <p class="o-forms-input o-forms-input--checkbox">
7
- <span class="ncf__paragraph">
7
+ <span class="ncf__paragraph o3-type-body-base">
8
8
  I confirm I am 16 years or older and have read and agree to the
9
- <a class="ncf__link--external"
10
- href="https://help.ft.com/legal-privacy/terms-and-conditions/"
9
+ <a href="https://help.ft.com/legal-privacy/terms-and-conditions/"
11
10
  title="FT Legal Terms and Conditions help page"
12
11
  target="_blank"
13
12
  rel="noopener noreferrer"
@@ -29,10 +28,9 @@ exports[`DeferredBillingTerms renders appropriately if a isDeferredBilling 1`] =
29
28
  </span>
30
29
  </p>
31
30
  <p class="o-forms-input o-forms-input--checkbox">
32
- <span class="ncf__paragraph">
31
+ <span class="ncf__paragraph o3-type-body-base">
33
32
  Find out more about our cancellation policy in our
34
- <a class="ncf__link--external"
35
- href="https://help.ft.com/legal-privacy/terms-and-conditions/"
33
+ <a href="https://help.ft.com/legal-privacy/terms-and-conditions/"
36
34
  title="FT Legal Terms and Conditions help page"
37
35
  target="_blank"
38
36
  rel="noopener noreferrer"
@@ -44,10 +42,9 @@ exports[`DeferredBillingTerms renders appropriately if a isDeferredBilling 1`] =
44
42
  </span>
45
43
  </p>
46
44
  <p class="o-forms-input o-forms-input--checkbox">
47
- <span class="ncf__paragraph">
45
+ <span class="ncf__paragraph o3-type-body-base">
48
46
  Please note that if you fail to make payment for your Deferred Billing Plan within the due date your subscription will be automatically cancelled.
49
- <a class="ncf__link--external"
50
- href="https://help.ft.com/legal-privacy/terms-and-conditions/"
47
+ <a href="https://help.ft.com/legal-privacy/terms-and-conditions/"
51
48
  title="FT Legal Terms and Conditions help page"
52
49
  target="_blank"
53
50
  rel="noopener noreferrer"
@@ -88,10 +85,9 @@ exports[`DeferredBillingTerms renders appropriately if all props are set to fals
88
85
 
89
86
  exports[`DeferredBillingTerms renders appropriately if all props are set to true - rendering of the component 1`] = `
90
87
  <p class="o-forms-input o-forms-input--checkbox o-forms-input--invalid">
91
- <span class="ncf__paragraph">
88
+ <span class="ncf__paragraph o3-type-body-base">
92
89
  I confirm I am 16 years or older and have read and agree to the
93
- <a class="ncf__link--external"
94
- href="https://help.ft.com/legal-privacy/terms-and-conditions/"
90
+ <a href="https://help.ft.com/legal-privacy/terms-and-conditions/"
95
91
  title="FT Legal Terms and Conditions help page"
96
92
  target="_blank"
97
93
  rel="noopener noreferrer"
@@ -113,10 +109,9 @@ exports[`DeferredBillingTerms renders appropriately if all props are set to true
113
109
  </span>
114
110
  </p>
115
111
  <p class="o-forms-input o-forms-input--checkbox o-forms-input--invalid">
116
- <span class="ncf__paragraph">
112
+ <span class="ncf__paragraph o3-type-body-base">
117
113
  Find out more about our cancellation policy in our
118
- <a class="ncf__link--external"
119
- href="https://help.ft.com/legal-privacy/terms-and-conditions/"
114
+ <a href="https://help.ft.com/legal-privacy/terms-and-conditions/"
120
115
  title="FT Legal Terms and Conditions help page"
121
116
  target="_blank"
122
117
  rel="noopener noreferrer"
@@ -128,10 +123,9 @@ exports[`DeferredBillingTerms renders appropriately if all props are set to true
128
123
  </span>
129
124
  </p>
130
125
  <p class="o-forms-input o-forms-input--checkbox o-forms-input--invalid">
131
- <span class="ncf__paragraph">
126
+ <span class="ncf__paragraph o3-type-body-base">
132
127
  Please note that if you fail to make payment for your Deferred Billing Plan within the due date your subscription will be automatically cancelled.
133
- <a class="ncf__link--external"
134
- href="https://help.ft.com/legal-privacy/terms-and-conditions/"
128
+ <a href="https://help.ft.com/legal-privacy/terms-and-conditions/"
135
129
  title="FT Legal Terms and Conditions help page"
136
130
  target="_blank"
137
131
  rel="noopener noreferrer"
@@ -17,21 +17,19 @@ exports[`ErrorPage renders with default props 1`] = `
17
17
  Children
18
18
  </div>
19
19
  </div>
20
- <div class="ncf__paragraph">
20
+ <div class="ncf__paragraph o3-type-body-base">
21
21
  <p>
22
22
  International Toll Free Number
23
23
  </p>
24
24
  <a id="error-international-number"
25
- class="ncf__header ncf__link"
25
+ class="ncf__header"
26
26
  href="tel:+80007056477"
27
27
  >
28
28
  + 800 0705 6477
29
29
  </a>
30
30
  </div>
31
- <div class="ncf__paragraph">
32
- <a class="ncf__link"
33
- href="https://help.ft.com/help/contact-us/"
34
- >
31
+ <div class="ncf__paragraph o3-type-body-base">
32
+ <a href="https://help.ft.com/help/contact-us/">
35
33
  Find a local phone number
36
34
  </a>
37
35
  </div>
@@ -55,21 +53,19 @@ exports[`ErrorPage renders with header 1`] = `
55
53
  Children
56
54
  </div>
57
55
  </div>
58
- <div class="ncf__paragraph">
56
+ <div class="ncf__paragraph o3-type-body-base">
59
57
  <p>
60
58
  International Toll Free Number
61
59
  </p>
62
60
  <a id="error-international-number"
63
- class="ncf__header ncf__link"
61
+ class="ncf__header"
64
62
  href="tel:+80007056477"
65
63
  >
66
64
  + 800 0705 6477
67
65
  </a>
68
66
  </div>
69
- <div class="ncf__paragraph">
70
- <a class="ncf__link"
71
- href="https://help.ft.com/help/contact-us/"
72
- >
67
+ <div class="ncf__paragraph o3-type-body-base">
68
+ <a href="https://help.ft.com/help/contact-us/">
73
69
  Find a local phone number
74
70
  </a>
75
71
  </div>
@@ -93,21 +89,19 @@ exports[`ErrorPage renders with message 1`] = `
93
89
  Children
94
90
  </div>
95
91
  </div>
96
- <div class="ncf__paragraph">
92
+ <div class="ncf__paragraph o3-type-body-base">
97
93
  <p>
98
94
  International Toll Free Number
99
95
  </p>
100
96
  <a id="error-international-number"
101
- class="ncf__header ncf__link"
97
+ class="ncf__header"
102
98
  href="tel:+80007056477"
103
99
  >
104
100
  + 800 0705 6477
105
101
  </a>
106
102
  </div>
107
- <div class="ncf__paragraph">
108
- <a class="ncf__link"
109
- href="https://help.ft.com/help/contact-us/"
110
- >
103
+ <div class="ncf__paragraph o3-type-body-base">
104
+ <a href="https://help.ft.com/help/contact-us/">
111
105
  Find a local phone number
112
106
  </a>
113
107
  </div>
@@ -57,7 +57,7 @@ exports[`Fieldset renders a custom legend 1`] = `
57
57
 
58
58
  exports[`Fieldset renders a custom legend which is visually hidden 1`] = `
59
59
  <fieldset class="ncf__fieldset">
60
- <legend class="ncf__legend o-normalise-visually-hidden">
60
+ <legend class="ncf__legend o3-visually-hidden">
61
61
  Customise your experience
62
62
  </legend>
63
63
  <div class="ncf__fields">
@@ -23,14 +23,14 @@ exports[`RegistrationConfirmation renders a continue reading button when an arti
23
23
  </div>
24
24
  <a href="/"
25
25
  target="_parent"
26
- class=" ncf__confirmation--finish ncf__button ncf__button--submit"
26
+ class=" ncf__confirmation--finish ncf__button o3-button o3-button--primary"
27
27
  data-trackable="register-finish-head-to-ft-edit-hub"
28
28
  >
29
29
  Explore FT Edit
30
30
  </a>
31
31
  <a href="https://www.ft.com/content/9141eee7-825a-41d7-913d-49e8c12e76db"
32
32
  target="_parent"
33
- class=" ncf__confirmation--finish-article-read ncf__button ncf__button--secondary reduce-bottom-spacing"
33
+ class=" ncf__confirmation--finish-article-read ncf__button o3-button o3-button--secondary reduce-bottom-spacing"
34
34
  data-trackable="register-finish-head-to-article"
35
35
  >
36
36
  Continue reading
@@ -61,7 +61,7 @@ exports[`RegistrationConfirmation renders an explore hub button always 1`] = `
61
61
  </div>
62
62
  <a href="http://thing-hub"
63
63
  target="_parent"
64
- class=" ncf__confirmation--finish ncf__button ncf__button--submit"
64
+ class=" ncf__confirmation--finish ncf__button o3-button o3-button--primary"
65
65
  data-trackable="register-finish-head-to-ft-edit-hub"
66
66
  >
67
67
  Explore FT Edit
@@ -92,7 +92,7 @@ exports[`RegistrationConfirmation renders with a custom email 1`] = `
92
92
  </div>
93
93
  <a href="/"
94
94
  target="_parent"
95
- class=" ncf__confirmation--finish ncf__button ncf__button--submit"
95
+ class=" ncf__confirmation--finish ncf__button o3-button o3-button--primary"
96
96
  data-trackable="register-finish-head-to-ft-edit-hub"
97
97
  >
98
98
  Explore FT Edit
@@ -123,7 +123,7 @@ exports[`RegistrationConfirmation renders with default props 1`] = `
123
123
  </div>
124
124
  <a href="/"
125
125
  target="_parent"
126
- class=" ncf__confirmation--finish ncf__button ncf__button--submit"
126
+ class=" ncf__confirmation--finish ncf__button o3-button o3-button--primary"
127
127
  data-trackable="register-finish-head-to-ft-edit-hub"
128
128
  >
129
129
  Explore FT Edit
@@ -108,10 +108,9 @@ exports[`GraduationDate renders with default props 1`] = `
108
108
  <div id="graduationDateCompliance"
109
109
  class="ncf__field ncf__gd-compliance"
110
110
  >
111
- <p>
111
+ <p class="o3-type-body-base">
112
112
  We use the information you provide, and may share it with your institution, for the purposes of administering your institution&#x27;s licence for
113
- <a class="ncf__link--external"
114
- href="https://ft.com/"
113
+ <a href="https://ft.com/"
115
114
  title="Financial Times"
116
115
  target="_blank"
117
116
  rel="noopener noreferrer"
@@ -119,10 +118,9 @@ exports[`GraduationDate renders with default props 1`] = `
119
118
  FT.com.
120
119
  </a>
121
120
  </p>
122
- <p>
121
+ <p class="o3-type-body-base">
123
122
  We may also use it to ensure our communications to you are more relevant. If you do not wish us to do so, you can amend your preferences at any time
124
- <a class="ncf__link--external"
125
- href="http://www.ft.com/myft/alerts/"
123
+ <a href="http://www.ft.com/myft/alerts/"
126
124
  title="Financial Times"
127
125
  target="_blank"
128
126
  rel="noopener noreferrer"