@cocreate/print 1.0.1 → 1.0.2

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/CHANGELOG.md CHANGED
@@ -1,3 +1,10 @@
1
+ ## [1.0.2](https://github.com/CoCreate-app/CoCreate-print/compare/v1.0.1...v1.0.2) (2024-12-14)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * dispatch printed event ([1acdb66](https://github.com/CoCreate-app/CoCreate-print/commit/1acdb66d9f7988fd5494a0f035c5227e1ba7d831))
7
+
1
8
  ## [1.0.1](https://github.com/CoCreate-app/CoCreate-print/compare/v1.0.0...v1.0.1) (2024-12-14)
2
9
 
3
10
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cocreate/print",
3
- "version": "1.0.1",
3
+ "version": "1.0.2",
4
4
  "description": "A simple print component in vanilla javascript. Easily configured using HTML5 data-attributes and/or JavaScript API.",
5
5
  "keywords": [
6
6
  "print",
package/src/index.js CHANGED
@@ -110,6 +110,12 @@ function print(elements) {
110
110
  // Remove iframe after printing
111
111
  iframe.parentNode.removeChild(iframe);
112
112
  };
113
+
114
+ document.dispatchEvent(
115
+ new CustomEvent("printed", {
116
+ detail: { content }
117
+ })
118
+ );
113
119
  }
114
120
 
115
121
  init();