Comparing version 0.3.0-beta.14 to 0.3.0-beta.15
# Changelog | ||
## 0.3.0-beta.15 - 2025-01-01 | ||
- Reverted to the original `pdfkit` package, moving away from `@foliojs-fork` | ||
- Update pdfkit to 0.16.0 | ||
- Fixed a potential issue in the minimized library when detecting the orientation of JPEG images | ||
## 0.3.0-beta.14 - 2024-12-23 | ||
@@ -4,0 +10,0 @@ |
@@ -7,15 +7,15 @@ "use strict"; | ||
'data/Courier.afm': { | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Courier.afm', 'utf8'), | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Courier.afm', 'utf8'), | ||
encoding: 'utf8' | ||
}, | ||
'data/Courier-Bold.afm': { | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Courier-Bold.afm', 'utf8'), | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Courier-Bold.afm', 'utf8'), | ||
encoding: 'utf8' | ||
}, | ||
'data/Courier-Oblique.afm': { | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Courier-Oblique.afm', 'utf8'), | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Courier-Oblique.afm', 'utf8'), | ||
encoding: 'utf8' | ||
}, | ||
'data/Courier-BoldOblique.afm': { | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Courier-BoldOblique.afm', 'utf8'), | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Courier-BoldOblique.afm', 'utf8'), | ||
encoding: 'utf8' | ||
@@ -22,0 +22,0 @@ } |
@@ -7,15 +7,15 @@ "use strict"; | ||
'data/Helvetica.afm': { | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Helvetica.afm', 'utf8'), | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Helvetica.afm', 'utf8'), | ||
encoding: 'utf8' | ||
}, | ||
'data/Helvetica-Bold.afm': { | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Helvetica-Bold.afm', 'utf8'), | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Helvetica-Bold.afm', 'utf8'), | ||
encoding: 'utf8' | ||
}, | ||
'data/Helvetica-Oblique.afm': { | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Helvetica-Oblique.afm', 'utf8'), | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Helvetica-Oblique.afm', 'utf8'), | ||
encoding: 'utf8' | ||
}, | ||
'data/Helvetica-BoldOblique.afm': { | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Helvetica-BoldOblique.afm', 'utf8'), | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Helvetica-BoldOblique.afm', 'utf8'), | ||
encoding: 'utf8' | ||
@@ -22,0 +22,0 @@ } |
@@ -7,3 +7,3 @@ "use strict"; | ||
'data/Symbol.afm': { | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Symbol.afm', 'utf8'), | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Symbol.afm', 'utf8'), | ||
encoding: 'utf8' | ||
@@ -10,0 +10,0 @@ } |
@@ -7,15 +7,15 @@ "use strict"; | ||
'data/Times-Roman.afm': { | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Times-Roman.afm', 'utf8'), | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Times-Roman.afm', 'utf8'), | ||
encoding: 'utf8' | ||
}, | ||
'data/Times-Bold.afm': { | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Times-Bold.afm', 'utf8'), | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Times-Bold.afm', 'utf8'), | ||
encoding: 'utf8' | ||
}, | ||
'data/Times-Italic.afm': { | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Times-Italic.afm', 'utf8'), | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Times-Italic.afm', 'utf8'), | ||
encoding: 'utf8' | ||
}, | ||
'data/Times-BoldItalic.afm': { | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Times-BoldItalic.afm', 'utf8'), | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Times-BoldItalic.afm', 'utf8'), | ||
encoding: 'utf8' | ||
@@ -22,0 +22,0 @@ } |
@@ -7,3 +7,3 @@ "use strict"; | ||
'data/ZapfDingbats.afm': { | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/ZapfDingbats.afm', 'utf8'), | ||
data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/ZapfDingbats.afm', 'utf8'), | ||
encoding: 'utf8' | ||
@@ -10,0 +10,0 @@ } |
@@ -120,10 +120,9 @@ "use strict"; | ||
}; | ||
if (image.constructor.name === 'JPEG') { | ||
// If EXIF orientation calls for it, swap width and height | ||
if (image.orientation > 4) { | ||
imageSize = { | ||
width: image.height, | ||
height: image.width | ||
}; | ||
} | ||
// If EXIF orientation calls for it, swap width and height | ||
if (image.orientation > 4) { | ||
imageSize = { | ||
width: image.height, | ||
height: image.width | ||
}; | ||
} | ||
@@ -130,0 +129,0 @@ this.measureImageWithDimensions(node, imageSize); |
@@ -5,3 +5,3 @@ "use strict"; | ||
exports.default = void 0; | ||
var _pdfkit = _interopRequireDefault(require("@foliojs-fork/pdfkit")); | ||
var _pdfkit = _interopRequireDefault(require("pdfkit")); | ||
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; } | ||
@@ -8,0 +8,0 @@ const typeName = (bold, italics) => { |
@@ -5,3 +5,3 @@ "use strict"; | ||
exports.default = void 0; | ||
var _linebreak = _interopRequireDefault(require("@foliojs-fork/linebreak")); | ||
var _linebreak = _interopRequireDefault(require("linebreak")); | ||
var _variableType = require("./helpers/variableType"); | ||
@@ -8,0 +8,0 @@ var _StyleContextStack = _interopRequireDefault(require("./StyleContextStack")); |
{ | ||
"name": "pdfmake", | ||
"version": "0.3.0-beta.14", | ||
"version": "0.3.0-beta.15", | ||
"description": "Client/server side PDF printing in pure JavaScript", | ||
@@ -12,13 +12,12 @@ "main": "js/index.js", | ||
"dependencies": { | ||
"@foliojs-fork/linebreak": "^1.1.2", | ||
"@foliojs-fork/pdfkit": "^0.15.2", | ||
"iconv-lite": "^0.6.3", | ||
"linebreak": "^1.1.0", | ||
"pdfkit": "^0.16.0", | ||
"xmldoc": "^1.3.0" | ||
}, | ||
"devDependencies": { | ||
"@babel/cli": "^7.25.9", | ||
"@babel/cli": "^7.26.4", | ||
"@babel/core": "^7.26.0", | ||
"@babel/plugin-transform-modules-commonjs": "^7.25.9", | ||
"@babel/plugin-transform-modules-commonjs": "^7.26.3", | ||
"@babel/preset-env": "^7.26.0", | ||
"@eslint/js": "^9.14.0", | ||
"@eslint/js": "^9.17.0", | ||
"assert": "^2.1.0", | ||
@@ -29,9 +28,9 @@ "babel-loader": "^9.2.1", | ||
"buffer": "6.0.3", | ||
"core-js": "3.19.0", | ||
"eslint": "^9.14.0", | ||
"eslint-plugin-jsdoc": "^50.4.3", | ||
"core-js": "3.39.0", | ||
"eslint": "^9.17.0", | ||
"eslint-plugin-jsdoc": "^50.6.1", | ||
"expose-loader": "^5.0.0", | ||
"file-saver": "^2.0.5", | ||
"globals": "^15.11.0", | ||
"mocha": "^10.8.2", | ||
"globals": "^15.14.0", | ||
"mocha": "^11.0.1", | ||
"npm-run-all": "^4.1.5", | ||
@@ -46,7 +45,7 @@ "process": "^0.11.10", | ||
"svg-to-pdfkit": "^0.1.8", | ||
"terser-webpack-plugin": "^5.3.10", | ||
"terser-webpack-plugin": "^5.3.11", | ||
"transform-loader": "^0.2.4", | ||
"util": "^0.12.5", | ||
"webpack": "^5.96.1", | ||
"webpack-cli": "^5.1.4" | ||
"webpack": "^5.97.1", | ||
"webpack-cli": "^6.0.1" | ||
}, | ||
@@ -53,0 +52,0 @@ "engines": { |
@@ -5,6 +5,6 @@ var fs = require('fs'); | ||
vfs: { | ||
'data/Courier.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Courier.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Courier-Bold.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Courier-Bold.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Courier-Oblique.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Courier-Oblique.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Courier-BoldOblique.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Courier-BoldOblique.afm', 'utf8'), encoding: 'utf8' } | ||
'data/Courier.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Courier.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Courier-Bold.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Courier-Bold.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Courier-Oblique.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Courier-Oblique.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Courier-BoldOblique.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Courier-BoldOblique.afm', 'utf8'), encoding: 'utf8' } | ||
}, | ||
@@ -11,0 +11,0 @@ fonts: { |
@@ -5,6 +5,6 @@ var fs = require('fs'); | ||
vfs: { | ||
'data/Helvetica.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Helvetica.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Helvetica-Bold.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Helvetica-Bold.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Helvetica-Oblique.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Helvetica-Oblique.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Helvetica-BoldOblique.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Helvetica-BoldOblique.afm', 'utf8'), encoding: 'utf8' } | ||
'data/Helvetica.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Helvetica.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Helvetica-Bold.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Helvetica-Bold.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Helvetica-Oblique.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Helvetica-Oblique.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Helvetica-BoldOblique.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Helvetica-BoldOblique.afm', 'utf8'), encoding: 'utf8' } | ||
}, | ||
@@ -11,0 +11,0 @@ fonts: { |
@@ -5,3 +5,3 @@ var fs = require('fs'); | ||
vfs: { | ||
'data/Symbol.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Symbol.afm', 'utf8'), encoding: 'utf8' } | ||
'data/Symbol.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Symbol.afm', 'utf8'), encoding: 'utf8' } | ||
}, | ||
@@ -8,0 +8,0 @@ fonts: { |
@@ -5,6 +5,6 @@ var fs = require('fs'); | ||
vfs: { | ||
'data/Times-Roman.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Times-Roman.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Times-Bold.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Times-Bold.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Times-Italic.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Times-Italic.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Times-BoldItalic.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/Times-BoldItalic.afm', 'utf8'), encoding: 'utf8' } | ||
'data/Times-Roman.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Times-Roman.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Times-Bold.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Times-Bold.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Times-Italic.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Times-Italic.afm', 'utf8'), encoding: 'utf8' }, | ||
'data/Times-BoldItalic.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/Times-BoldItalic.afm', 'utf8'), encoding: 'utf8' } | ||
}, | ||
@@ -11,0 +11,0 @@ fonts: { |
@@ -5,3 +5,3 @@ var fs = require('fs'); | ||
vfs: { | ||
'data/ZapfDingbats.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/@foliojs-fork/pdfkit/js/data/ZapfDingbats.afm', 'utf8'), encoding: 'utf8' } | ||
'data/ZapfDingbats.afm': { data: fs.readFileSync(__dirname + '/../../../node_modules/pdfkit/js/data/ZapfDingbats.afm', 'utf8'), encoding: 'utf8' } | ||
}, | ||
@@ -8,0 +8,0 @@ fonts: { |
@@ -134,7 +134,5 @@ import TextInlines from './TextInlines'; | ||
if (image.constructor.name === 'JPEG') { | ||
// If EXIF orientation calls for it, swap width and height | ||
if (image.orientation > 4) { | ||
imageSize = { width: image.height, height: image.width }; | ||
} | ||
// If EXIF orientation calls for it, swap width and height | ||
if (image.orientation > 4) { | ||
imageSize = { width: image.height, height: image.width }; | ||
} | ||
@@ -141,0 +139,0 @@ |
@@ -1,2 +0,2 @@ | ||
import PDFKit from '@foliojs-fork/pdfkit'; | ||
import PDFKit from 'pdfkit'; | ||
@@ -3,0 +3,0 @@ const typeName = (bold, italics) => { |
@@ -1,2 +0,2 @@ | ||
import LineBreaker from '@foliojs-fork/linebreak'; | ||
import LineBreaker from 'linebreak'; | ||
import { isObject } from './helpers/variableType'; | ||
@@ -3,0 +3,0 @@ import StyleContextStack from './StyleContextStack'; |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
3
13802226
91347
+ Addedlinebreak@^1.1.0
+ Addedpdfkit@^0.16.0
+ Added@swc/helpers@0.5.15(transitive)
+ Addedbase64-js@0.0.81.5.1(transitive)
+ Addedclone@2.1.2(transitive)
+ Addedfast-deep-equal@3.1.3(transitive)
+ Addedfontkit@2.0.4(transitive)
+ Addedlinebreak@1.1.0(transitive)
+ Addedpdfkit@0.16.0(transitive)
+ Addedrestructure@3.0.2(transitive)
+ Addedtslib@2.8.1(transitive)
- Removed@foliojs-fork/linebreak@^1.1.2
- Removed@foliojs-fork/pdfkit@^0.15.2
- Removediconv-lite@^0.6.3
- Removed@foliojs-fork/fontkit@1.9.2(transitive)
- Removed@foliojs-fork/linebreak@1.1.2(transitive)
- Removed@foliojs-fork/pdfkit@0.15.3(transitive)
- Removed@foliojs-fork/restructure@2.0.2(transitive)
- Removedbase64-js@1.3.1(transitive)
- Removedcall-bind@1.0.8(transitive)
- Removedcall-bind-apply-helpers@1.0.1(transitive)
- Removedcall-bound@1.0.3(transitive)
- Removedclone@1.0.4(transitive)
- Removeddeep-equal@1.1.2(transitive)
- Removeddefine-data-property@1.1.4(transitive)
- Removeddefine-properties@1.2.1(transitive)
- Removeddunder-proto@1.0.1(transitive)
- Removedes-define-property@1.0.1(transitive)
- Removedes-errors@1.3.0(transitive)
- Removedes-object-atoms@1.1.1(transitive)
- Removedfunction-bind@1.1.2(transitive)
- Removedfunctions-have-names@1.2.3(transitive)
- Removedget-intrinsic@1.2.7(transitive)
- Removedget-proto@1.0.1(transitive)
- Removedgopd@1.2.0(transitive)
- Removedhas-property-descriptors@1.0.2(transitive)
- Removedhas-symbols@1.1.0(transitive)
- Removedhas-tostringtag@1.0.2(transitive)
- Removedhasown@2.0.2(transitive)
- Removediconv-lite@0.6.3(transitive)
- Removedis-arguments@1.2.0(transitive)
- Removedis-date-object@1.1.0(transitive)
- Removedis-regex@1.2.1(transitive)
- Removedmath-intrinsics@1.1.0(transitive)
- Removedobject-is@1.1.6(transitive)
- Removedobject-keys@1.1.1(transitive)
- Removedregexp.prototype.flags@1.5.4(transitive)
- Removedsafer-buffer@2.1.2(transitive)
- Removedset-function-length@1.2.2(transitive)
- Removedset-function-name@2.0.2(transitive)