@glitchr/transparent 1.0.49 → 1.0.50

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@glitchr/transparent",
3
- "version": "1.0.49",
3
+ "version": "1.0.50",
4
4
  "description": "Transparent SPA Application",
5
5
  "main": "src/index.js",
6
6
  "access": "public",
@@ -547,7 +547,10 @@
547
547
  return null;
548
548
  }
549
549
 
550
- if(!form.checkValidity()) return null;
550
+ if(!$(el).hasClass("skip-validation") && !form.checkValidity()) {
551
+ console.error("Invalid form submission.", el);
552
+ return null;
553
+ }
551
554
 
552
555
  var pat = /^https?:\/\//i;
553
556
  if (pat.test(href)) return [method, new URL(href), form];
@@ -589,7 +592,10 @@
589
592
  return null;
590
593
  }
591
594
 
592
- if(!form.checkValidity()) return null;
595
+ if(!$(el).hasClass("skip-validation") && !form.checkValidity()) {
596
+ console.error("Invalid form submission.", el);
597
+ return null;
598
+ }
593
599
 
594
600
  var pat = /^https?:\/\//i;
595
601
  if (pat.test(href)) return ["POST", new URL(pathname), form];