kemet-ui 1.1.0 → 1.2.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.
@@ -43,10 +43,10 @@ export class FormSubmitController {
43
43
  if (!disabled && typeof name === 'string' && typeof value !== 'undefined') {
44
44
  if (Array.isArray(value)) {
45
45
  value.forEach((val) => {
46
- event.formData.append(name, val.toString());
46
+ event.formData?.append(name, val.toString());
47
47
  });
48
48
  } else {
49
- event.formData.append(name, value.toString());
49
+ event.formData?.append(name, value.toString());
50
50
  }
51
51
  }
52
52
  }
@@ -55,6 +55,8 @@ export class FormSubmitController {
55
55
  const disabled = this.options.disabled(this.host);
56
56
  const checkValidity = this.options.checkValidity;
57
57
 
58
+ this.form = this.options.form(this.host);
59
+
58
60
  if (this.form && !this.form.noValidate && !disabled && !checkValidity(this.host)) {
59
61
  event.preventDefault();
60
62
  event.stopImmediatePropagation();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kemet-ui",
3
- "version": "1.1.0",
3
+ "version": "1.2.0",
4
4
  "description": "A flexible and designless blueprint system for UIs.",
5
5
  "main": "index.js",
6
6
  "watch": {