@financial-times/n-conversion-forms 42.0.2 → 42.0.4

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,7 +1,7 @@
1
1
  {
2
2
  "branch": "",
3
3
  "repo": "n-conversion-forms",
4
- "version": "b5d133ad4cbdc7d2045172be22c9b0d14115a8f9",
5
- "tag": "v42.0.2",
6
- "buildNumber": "16198"
4
+ "version": "d04a41d57af1fc65b8d0766695ed10ac24e32622",
5
+ "tag": "v42.0.4",
6
+ "buildNumber": "16260"
7
7
  }
package/main.scss CHANGED
@@ -187,7 +187,8 @@
187
187
  }
188
188
 
189
189
  &__header {
190
- @include oTypographyHeading($level: 3);
190
+ font-size: var(--o3-font-size-3);
191
+ line-height: var(--o3-font-lineheight-3);
191
192
 
192
193
  &--confirmation {
193
194
  line-height: var(--o3-font-lineheight-3);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@financial-times/n-conversion-forms",
3
- "version": "42.0.2",
3
+ "version": "42.0.4",
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": {
@@ -1,6 +1,3 @@
1
- @import '@financial-times/o-colors/main';
2
- @import '@financial-times/o-buttons/main';
3
-
4
1
  .subscription-active-with-payment-link {
5
2
  background: var(--o3-color-palette-ft-grey);
6
3
  padding: var(--o3-spacing-s) var(--o3-spacing-s) var(--o3-spacing-m);
package/utils/submit.js CHANGED
@@ -7,22 +7,21 @@
7
7
  * submit.updateText('Pay with Apple Pay');
8
8
  */
9
9
 
10
- const SUBMIT_BUTTON_CLASS = '.ncf__button--submit';
11
-
12
10
  class Submit {
13
11
  /**
14
12
  * Initalise the submit utility
15
13
  * @param {Element} element Usually the window.document
14
+ * @param id
16
15
  * @throws If the document not passed
17
16
  * @throws When the submit element not found
18
17
  */
19
- constructor(element) {
18
+ constructor(element, id = 'submitButton') {
20
19
  if (!element) {
21
20
  throw new Error('Please supply a DOM element');
22
21
  }
23
22
 
24
23
  this.element = element;
25
- this.$submit = element.querySelector(SUBMIT_BUTTON_CLASS);
24
+ this.$submit = element.querySelector(`#${id}`);
26
25
 
27
26
  if (!this.$submit) {
28
27
  throw new Error('Please include the submit button partial on the page');