pdfkit 0.17.2 → 0.19.0

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/.yarnrc.yml ADDED
@@ -0,0 +1,3 @@
1
+ yarnPath: .yarn/releases/yarn-4.10.3.cjs
2
+
3
+ nodeLinker: node-modules
package/CHANGELOG.md CHANGED
@@ -1,134 +1,163 @@
1
- ## pdfkit changelog
2
-
3
- ### Unreleased
4
-
5
- ### [v0.17.2] - 2025-08-30
6
-
7
- - Fix rendering lists that spans across pages
8
-
9
- ### [v0.17.1] - 2025-05-02
10
-
11
- - Fix null values in table cells rendering as `[object Object]`
12
- - Fix further LineWrapper precision issues
13
- - Optmize standard font handling. Less code, less memory usage
14
-
15
- ### [v0.17.0] - 2025-04-12
16
-
17
- - Fix precision rounding issues in LineWrapper
18
- - Fix fonts without a postscriptName
19
- - Add support for dynamic sizing
20
- - Add support for rotatable text
21
- - Fix page cascade options when text overflows
22
- - Add table generation
23
- - Fix y position when using `image()` without x and y coordinates
24
- - Improve Prettier configuration
25
-
26
- ### [v0.16.0] - 2024-12-29
27
-
28
- - Update fontkit to 2.0
29
- - Update linebreak to 1.1
30
- - Add support for spot colors
31
- - Add support to scale text horizontally
32
- - Add an option to keep the indentation after a new line starts and allow to indent a whole paragraph/text element
33
- - Add `Name` property for set custom icon for `note()`
34
- - Fix sets tab order to "Structure" when a document is tagged
35
- - Fix font cache collision for fonts with missing postscript name or bad TTF metadata or identical metadata for different fonts
36
- - Fix for embedding fonts into PDF (font name must not contain spaces)
37
- - Fix measuring text when OpenType features are passed in to .text()
38
-
39
- ### [v0.15.2] - 2024-12-15
40
-
41
- - Fix index not counting when rendering ordered lists (#1517)
42
- - Fix PDF/A3 compliance of attachments
43
- - Fix CIDSet generation only for PDF/A1 subset
44
- - Fix missing acroform font dictionary
45
- - Fix modify time comparison check equality embedded files
46
-
47
- ### [v0.15.1] - 2024-10-30
48
-
49
- - Fix browserify transform sRGB_IEC61966_2_1.icc file
50
- - Fix time comparison check equality embedded files
51
-
52
- ### [v0.15.0] - 2024-03-23
53
-
54
- - Add subset for PDF/UA
55
- - Fix for line breaks in list items (#1486)
56
- - Fix for soft hyphen not being replaced by visible hyphen if necessary (#457)
57
- - Optimize output files by ignoring identity transforms
58
- - Fix for Acroforms - setting an option to false will still apply the flag (#1495)
59
- - Fix for text extraction in PDFium-based viewers due to invalid ToUnicodeMap (#1498)
60
- - Remove deprecated `write` method
61
- - Drop support for Node.js < 18 and for browsers released before 2020
62
-
63
- ### [v0.14.0] - 2023-11-09
64
-
65
- - Add support for PDF/A-1b, PDF/A-1a, PDF/A-2b, PDF/A-2a, PDF/A-3b, PDF/A-3a
66
- - Update crypto-js to v4.2.0 (properly fix security issue)
67
-
68
- - Add support for EXIF orientation on JPEG images (#626 and #1353)
69
-
70
- ### [v0.13.0] - 2021-10-24
71
-
72
- - Add tiling pattern support
73
-
74
- ### [v0.12.3] - 2021-08-01
75
-
76
- - Remove examples from published package
77
-
78
- ### [v0.12.2] - 2021-08-01
79
-
80
- - Fix for PDF accessibility check. (#1265)
81
- - Allow applying 'underline' and 'strike' text styling together on a text
82
- - Allow to specify the AcroForm text fontSize
83
- - Update crypto-js to v4.0 (properly fix security issue)
84
-
85
- ### [v0.12.1] - 2021-04-10
86
-
87
- - Update crypto-js to v3.3 (fix security issue)
88
- - Update fontkit to 1.8.1
89
-
90
- ### [v0.12.0] - 2021-04-04
91
-
92
- - Add support for Embedded Files and File Attachment Annotations
93
- - Accessibility support
94
- - Replace integration tests by visual regression tests
95
- - Fix access permissions in PDF version 1.7ext3
96
- - Fix Buffer() is deprecation warning
97
- - Add `forms.md` to generate documentation files
98
- - Fix "@" in FontName
99
-
100
- ### [v0.11.0] - 2019-12-03
101
-
102
- - Fix infinite loop when an individual character is bigger than the width of the text.
103
- - Fix infinite loop when text is positioned after page right margin
104
- - Allow links in continued text to be stopped by setting link to null
105
- - Add support to interlaced PNG files
106
- - Do not emit \_interopDefault helper in commonjs build
107
- - Fix gradient with multiple stops (#1045)
108
- - Set link annotation flag to print by default
109
- - Add support for AcroForms
110
- - Drop support for (uncommon) cid less fonts on standalone build (reduces bundle size)
111
-
112
- ### [v0.10.0] - 2019-06-06
113
-
114
- - Fix links to pages within the document
115
- - Add support for named destinations
116
- - Throw errors when `dash(...)` is passed invalid lengths
117
- - Remove PDFDocument#output method
118
- - Add standalone build (js/pdfkit.standalone.js)
119
-
120
- ### [v0.9.1] - 2019-04-30
121
-
122
- - Fix setting printing permission
123
- - Fix corruption of string objects in browser
124
- - Add option to set default font
125
- - Remove call to fontkit.openSync
126
- - Add standalone virtual file system implementation
127
- - Add option (fontLayoutCache) to disable font layout cache
128
-
129
- ### [v0.9.0] - 2019-01-28
130
-
131
- - Convert to code base from coffescript to ES6+
132
- - Fix loading grayscale / transparent PNG files
133
- - Reduce number of calls to async functions
134
- - Implement encryption / access control
1
+ ## pdfkit changelog
2
+
3
+ ### Unreleased
4
+
5
+ ### [v0.19.0] - 2026-06-07
6
+
7
+ - Bump node version requirement to 20+
8
+ - Bump minimum supported browsers to Firefox 115, iOS/Safari 16
9
+ - Fix text with input x as null
10
+ - Add opacity option to `doc.image()` to control image transparency
11
+ - Fix corrupted PDF when mixing standard and embedded fonts that share postscript name
12
+ - Fix PDF/UA compliance issues in kitchen-sink-accessible example
13
+ - Add bbox and placement options to PDFStructureElement for PDF/UA compliance
14
+ - Extend `roundedRect` with `borderRadius` as number for all corners or per-corner array (CSS order)
15
+ - Fix accessibility: scope in TH element
16
+ - Fix PDF Name escaping for spot colors with spaces ([#1644](https://github.com/foliojs/pdfkit/issues/1644))
17
+
18
+ ### [v0.18.0] - 2026-03-14
19
+
20
+ - Fix garbled text copying in Chrome/Edge for PDFs with >256 unique characters (#1659)
21
+ - Fix Link accessibility issues
22
+ - Fix Table Accessibility Issue: Operator CS/cs not allowed in this current state
23
+ - Fix Interlaced PNG with indexed transparency rendered incorrectly
24
+ - Fix SVG path parser incorrectly handle arc flags without separators
25
+ - Add pageLayout option to control how pages are displayed in PDF viewers
26
+ - Preserve existing PageMode instead of overwriting when adding outlines
27
+ - Add userUnit option for custom page units (PDF 1.6)
28
+ - Support outlines that jump to specific page positions with custom zoom level
29
+ - Add robust handling of null byte padding in JPEG images
30
+ - Replace outdated jpeg-exif with minimal implementation
31
+ - Replace outdated crypto-js with maintained small alternatives
32
+ - Fix issue with indentation with `indentAllLines: true` when a new page is created
33
+
34
+ ### [v0.17.2] - 2025-08-30
35
+
36
+ - Fix rendering lists that spans across pages
37
+
38
+ ### [v0.17.1] - 2025-05-02
39
+
40
+ - Fix null values in table cells rendering as `[object Object]`
41
+ - Fix further LineWrapper precision issues
42
+ - Optmize standard font handling. Less code, less memory usage
43
+
44
+ ### [v0.17.0] - 2025-04-12
45
+
46
+ - Fix precision rounding issues in LineWrapper
47
+ - Fix fonts without a postscriptName
48
+ - Add support for dynamic sizing
49
+ - Add support for rotatable text
50
+ - Fix page cascade options when text overflows
51
+ - Add table generation
52
+ - Fix y position when using `image()` without x and y coordinates
53
+ - Improve Prettier configuration
54
+
55
+ ### [v0.16.0] - 2024-12-29
56
+
57
+ - Update fontkit to 2.0
58
+ - Update linebreak to 1.1
59
+ - Add support for spot colors
60
+ - Add support to scale text horizontally
61
+ - Add an option to keep the indentation after a new line starts and allow to indent a whole paragraph/text element
62
+ - Add `Name` property for set custom icon for `note()`
63
+ - Fix sets tab order to "Structure" when a document is tagged
64
+ - Fix font cache collision for fonts with missing postscript name or bad TTF metadata or identical metadata for different fonts
65
+ - Fix for embedding fonts into PDF (font name must not contain spaces)
66
+ - Fix measuring text when OpenType features are passed in to .text()
67
+
68
+ ### [v0.15.2] - 2024-12-15
69
+
70
+ - Fix index not counting when rendering ordered lists (#1517)
71
+ - Fix PDF/A3 compliance of attachments
72
+ - Fix CIDSet generation only for PDF/A1 subset
73
+ - Fix missing acroform font dictionary
74
+ - Fix modify time comparison check equality embedded files
75
+
76
+ ### [v0.15.1] - 2024-10-30
77
+
78
+ - Fix browserify transform sRGB_IEC61966_2_1.icc file
79
+ - Fix time comparison check equality embedded files
80
+
81
+ ### [v0.15.0] - 2024-03-23
82
+
83
+ - Add subset for PDF/UA
84
+ - Fix for line breaks in list items (#1486)
85
+ - Fix for soft hyphen not being replaced by visible hyphen if necessary (#457)
86
+ - Optimize output files by ignoring identity transforms
87
+ - Fix for Acroforms - setting an option to false will still apply the flag (#1495)
88
+ - Fix for text extraction in PDFium-based viewers due to invalid ToUnicodeMap (#1498)
89
+ - Remove deprecated `write` method
90
+ - Drop support for Node.js < 18 and for browsers released before 2020
91
+
92
+ ### [v0.14.0] - 2023-11-09
93
+
94
+ - Add support for PDF/A-1b, PDF/A-1a, PDF/A-2b, PDF/A-2a, PDF/A-3b, PDF/A-3a
95
+ - Update crypto-js to v4.2.0 (properly fix security issue)
96
+
97
+ - Add support for EXIF orientation on JPEG images (#626 and #1353)
98
+
99
+ ### [v0.13.0] - 2021-10-24
100
+
101
+ - Add tiling pattern support
102
+
103
+ ### [v0.12.3] - 2021-08-01
104
+
105
+ - Remove examples from published package
106
+
107
+ ### [v0.12.2] - 2021-08-01
108
+
109
+ - Fix for PDF accessibility check. (#1265)
110
+ - Allow applying 'underline' and 'strike' text styling together on a text
111
+ - Allow to specify the AcroForm text fontSize
112
+ - Update crypto-js to v4.0 (properly fix security issue)
113
+
114
+ ### [v0.12.1] - 2021-04-10
115
+
116
+ - Update crypto-js to v3.3 (fix security issue)
117
+ - Update fontkit to 1.8.1
118
+
119
+ ### [v0.12.0] - 2021-04-04
120
+
121
+ - Add support for Embedded Files and File Attachment Annotations
122
+ - Accessibility support
123
+ - Replace integration tests by visual regression tests
124
+ - Fix access permissions in PDF version 1.7ext3
125
+ - Fix Buffer() is deprecation warning
126
+ - Add `forms.md` to generate documentation files
127
+ - Fix "@" in FontName
128
+
129
+ ### [v0.11.0] - 2019-12-03
130
+
131
+ - Fix infinite loop when an individual character is bigger than the width of the text.
132
+ - Fix infinite loop when text is positioned after page right margin
133
+ - Allow links in continued text to be stopped by setting link to null
134
+ - Add support to interlaced PNG files
135
+ - Do not emit \_interopDefault helper in commonjs build
136
+ - Fix gradient with multiple stops (#1045)
137
+ - Set link annotation flag to print by default
138
+ - Add support for AcroForms
139
+ - Drop support for (uncommon) cid less fonts on standalone build (reduces bundle size)
140
+
141
+ ### [v0.10.0] - 2019-06-06
142
+
143
+ - Fix links to pages within the document
144
+ - Add support for named destinations
145
+ - Throw errors when `dash(...)` is passed invalid lengths
146
+ - Remove PDFDocument#output method
147
+ - Add standalone build (js/pdfkit.standalone.js)
148
+
149
+ ### [v0.9.1] - 2019-04-30
150
+
151
+ - Fix setting printing permission
152
+ - Fix corruption of string objects in browser
153
+ - Add option to set default font
154
+ - Remove call to fontkit.openSync
155
+ - Add standalone virtual file system implementation
156
+ - Add option (fontLayoutCache) to disable font layout cache
157
+
158
+ ### [v0.9.0] - 2019-01-28
159
+
160
+ - Convert to code base from coffescript to ES6+
161
+ - Fix loading grayscale / transparent PNG files
162
+ - Reduce number of calls to async functions
163
+ - Implement encryption / access control
package/LICENSE CHANGED
@@ -1,8 +1,8 @@
1
- MIT LICENSE
2
- Copyright (c) 2014 Devon Govett
3
-
4
- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
5
-
6
- The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
7
-
1
+ MIT LICENSE
2
+ Copyright (c) 2014 Devon Govett
3
+
4
+ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
5
+
6
+ The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
7
+
8
8
  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.