element-internals-polyfill
Advanced tools
Comparing version 0.0.6 to 0.0.7
@@ -5,2 +5,9 @@ # Changelog | ||
### [0.0.7](https://github.com/calebdwilliams/element-internals-polyfill/compare/v0.0.6...v0.0.7) (2020-04-16) | ||
### Features | ||
* **polyfill:** now fires invalid and valid events ([1e05937](https://github.com/calebdwilliams/element-internals-polyfill/commit/1e0593702c6c8a56cda40a6936d654d91b1176ce)) | ||
### [0.0.6](https://github.com/calebdwilliams/element-internals-polyfill/compare/v0.0.5...v0.0.6) (2020-04-14) | ||
@@ -7,0 +14,0 @@ |
@@ -9,2 +9,3 @@ (function () { | ||
const validationMessageMap = new WeakMap(); | ||
const formsMap = new WeakMap(); | ||
@@ -71,2 +72,4 @@ const observerConfig = { attributes: true }; | ||
}); | ||
formsMap.set(form, { ref, internals }); | ||
} | ||
@@ -152,2 +155,9 @@ }; | ||
const validity = validityMap.get(this); | ||
const ref = refMap.get(this); | ||
const validityEvent = new Event(validity.valid, { | ||
bubbles: false, | ||
cancelable: true, | ||
composed: false | ||
}); | ||
ref.dispatchEvent(validityEvent); | ||
return validity.valid; | ||
@@ -173,3 +183,3 @@ } | ||
reportValidity() { | ||
// TODO: Figure out how to polyfill this | ||
return this.checkValidity(); | ||
} | ||
@@ -176,0 +186,0 @@ |
{ | ||
"name": "element-internals-polyfill", | ||
"version": "0.0.6", | ||
"version": "0.0.7", | ||
"description": "A polyfill for the element internals specification", | ||
@@ -5,0 +5,0 @@ "main": "/dist/element-internals.js", |
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
No README
QualityPackage does not have a README. This may indicate a failed publish or a low quality package.
Found 1 instance in 1 package
11461
4
213
0
3