@stackforge-eu/factur-x 1.4.1 → 1.4.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
@@ -7,6 +7,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/).
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [1.4.2] — 2026-09-25
11
+
12
+ - **Fixed the embedded XML MIME type back to `text/xml`.** 1.2.1 switched the
13
+ `factur-x.xml` filespec `/Subtype` to `application/xml` (#7), but the
14
+ Factur-X specification requires `text/xml`, and the official FNFE-MPE
15
+ validator rejects anything else. PDFs generated with 1.2.1 through 1.4.1
16
+ should be regenerated. A test now pins the value (#19).
17
+
10
18
  ## [1.4.1] — 2026-09-14
11
19
 
12
20
  - **Added the rounding amount (BT-114).** A new optional `roundingAmount`
@@ -257,6 +265,7 @@ This element is not expected`. Reordered the three blocks in
257
265
  - Deno compatibility test suite
258
266
 
259
267
  [Unreleased]: https://github.com/StackForge-EU/factur-x/commits/main
268
+ [1.4.2]: https://github.com/StackForge-EU/factur-x/compare/v1.4.1...v1.4.2
260
269
  [1.4.1]: https://github.com/StackForge-EU/factur-x/compare/v1.4.0...v1.4.1
261
270
  [1.4.0]: https://github.com/StackForge-EU/factur-x/compare/v1.3.1...v1.4.0
262
271
  [1.3.1]: https://github.com/StackForge-EU/factur-x/compare/v1.3.0...v1.3.1
package/dist/index.cjs CHANGED
@@ -1442,7 +1442,8 @@ async function embedFacturX(options) {
1442
1442
  const xmlBytes = new TextEncoder().encode(xml);
1443
1443
  const afRel = resolveAfRelationship(profile, options.afRelationship);
1444
1444
  await pdfDoc.attach(xmlBytes, flavorConfig.attachmentFilename, {
1445
- mimeType: "application/xml",
1445
+ // Factur-X mandates text/xml on the filespec; the FNFE validator rejects application/xml.
1446
+ mimeType: "text/xml",
1446
1447
  afRelationship: afRel,
1447
1448
  description: "Factur-X Invoice"
1448
1449
  });
package/dist/index.js CHANGED
@@ -1412,7 +1412,8 @@ async function embedFacturX(options) {
1412
1412
  const xmlBytes = new TextEncoder().encode(xml);
1413
1413
  const afRel = resolveAfRelationship(profile, options.afRelationship);
1414
1414
  await pdfDoc.attach(xmlBytes, flavorConfig.attachmentFilename, {
1415
- mimeType: "application/xml",
1415
+ // Factur-X mandates text/xml on the filespec; the FNFE validator rejects application/xml.
1416
+ mimeType: "text/xml",
1416
1417
  afRelationship: afRel,
1417
1418
  description: "Factur-X Invoice"
1418
1419
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stackforge-eu/factur-x",
3
- "version": "1.4.1",
3
+ "version": "1.4.2",
4
4
  "type": "module",
5
5
  "description": "Embed Factur-X, ZUGFeRD, and XRechnung structured invoice XML into PDF/A-3 documents",
6
6
  "keywords": [