modularload
Advanced tools
Comparing version 1.2.1 to 1.2.2
@@ -122,5 +122,10 @@ 'use strict'; | ||
if (target.matches('a')) { | ||
e.preventDefault(); | ||
this.reset(); | ||
this.getClickOptions(target); | ||
var href = target.getAttribute('href'); | ||
if (!href.startsWith('#') && !href.startsWith('mailto:') && !href.startsWith('tel:')) { | ||
e.preventDefault(); | ||
this.reset(); | ||
this.getClickOptions(target); | ||
} | ||
break; | ||
@@ -175,6 +180,2 @@ } | ||
if (href.startsWith('#')) { | ||
return; | ||
} | ||
this.setOptions(href, true); | ||
@@ -181,0 +182,0 @@ } |
@@ -120,5 +120,10 @@ function _classCallCheck(instance, Constructor) { | ||
if (target.matches('a')) { | ||
e.preventDefault(); | ||
this.reset(); | ||
this.getClickOptions(target); | ||
var href = target.getAttribute('href'); | ||
if (!href.startsWith('#') && !href.startsWith('mailto:') && !href.startsWith('tel:')) { | ||
e.preventDefault(); | ||
this.reset(); | ||
this.getClickOptions(target); | ||
} | ||
break; | ||
@@ -173,6 +178,2 @@ } | ||
if (href.startsWith('#')) { | ||
return; | ||
} | ||
this.setOptions(href, true); | ||
@@ -179,0 +180,0 @@ } |
{ | ||
"name": "modularload", | ||
"version": "1.2.1", | ||
"version": "1.2.2", | ||
"description": "Dead simple page transitions and lazy loading.", | ||
@@ -5,0 +5,0 @@ "repository": "modularorg/modularload", |
@@ -53,6 +53,11 @@ export default class { | ||
if (target.matches('a')) { | ||
e.preventDefault(); | ||
const href = target.getAttribute('href'); | ||
this.reset(); | ||
this.getClickOptions(target); | ||
if (!href.startsWith('#') && !href.startsWith('mailto:') && !href.startsWith('tel:')) { | ||
e.preventDefault(); | ||
this.reset(); | ||
this.getClickOptions(target); | ||
} | ||
break; | ||
@@ -104,6 +109,2 @@ } | ||
if (href.startsWith('#')) { | ||
return; | ||
} | ||
this.setOptions(href, true); | ||
@@ -110,0 +111,0 @@ } |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
47117