pptx-templates 0.2.0 → 0.2.1
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 +19 -1
- package/dist/helper/generate/generate-pptxgenjs.d.ts +1 -1
- package/dist/helper/generate/generate-pptxgenjs.js +1 -1
- package/dist/helper/generate/generate-pptxgenjs.js.map +1 -1
- package/dist/interfaces/ipptxgenjs-slide.d.ts +1 -1
- package/dist/types/types.d.ts +1 -1
- package/dist/vendor/pptxgenjs/LICENSE +21 -0
- package/dist/vendor/pptxgenjs/README.md +12 -0
- package/dist/vendor/pptxgenjs/index.d.ts +2679 -0
- package/dist/vendor/pptxgenjs/index.js +7370 -0
- package/package.json +2 -4
package/CHANGELOG.md
CHANGED
|
@@ -6,6 +6,23 @@ semver, with the pre-1.0 convention that **breaking changes bump the minor**.
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [0.2.1] - 2026-11-07
|
|
10
|
+
|
|
11
|
+
### Security
|
|
12
|
+
|
|
13
|
+
- Bundle PptxGenJS 4.0.1 (`src/vendor/pptxgenjs/`, unmodified, MIT) instead of
|
|
14
|
+
depending on the `pptxgenjs` package. Its manifest declares `image-size
|
|
15
|
+
^1.2.1`, which is affected by CVE-2025-71329 and CVE-2025-71330 (infinite
|
|
16
|
+
loops in the JXL/HEIF and ICNS parsers). The PptxGenJS bundle never loads
|
|
17
|
+
`image-size`, but the declared dependency could not be overridden by
|
|
18
|
+
consumers of this package. `pptx-templates` no longer installs it.
|
|
19
|
+
|
|
20
|
+
### Changed
|
|
21
|
+
|
|
22
|
+
- `pptxgenjs` is no longer a dependency; `slide.generate()` works as before.
|
|
23
|
+
To update the bundled copy, replace `index.js` and `index.d.ts` in
|
|
24
|
+
`src/vendor/pptxgenjs/`.
|
|
25
|
+
|
|
9
26
|
## [0.2.0] - 2026-11-07
|
|
10
27
|
|
|
11
28
|
### Added
|
|
@@ -108,7 +125,8 @@ for that history.
|
|
|
108
125
|
into one `.png` part. The fallback now gets the same placeholder PNG that
|
|
109
126
|
pptxgenjs 3.12 wrote.
|
|
110
127
|
|
|
111
|
-
[Unreleased]: https://github.com/DaBorsten/pptx-templates/compare/v0.2.
|
|
128
|
+
[Unreleased]: https://github.com/DaBorsten/pptx-templates/compare/v0.2.1...HEAD
|
|
129
|
+
[0.2.1]: https://github.com/DaBorsten/pptx-templates/compare/v0.2.0...v0.2.1
|
|
112
130
|
[0.2.0]: https://github.com/DaBorsten/pptx-templates/compare/v0.1.3...v0.2.0
|
|
113
131
|
[0.1.3]: https://github.com/DaBorsten/pptx-templates/compare/v0.1.2...v0.1.3
|
|
114
132
|
[0.1.2]: https://github.com/DaBorsten/pptx-templates/compare/v0.1.1...v0.1.2
|
|
@@ -13,7 +13,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
13
13
|
};
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
15
|
const crypto_1 = require("crypto");
|
|
16
|
-
const pptxgenjs_1 = __importDefault(require("pptxgenjs"));
|
|
16
|
+
const pptxgenjs_1 = __importDefault(require("../../vendor/pptxgenjs"));
|
|
17
17
|
const pptxgenjs_compat_1 = require("../../extensions/pptxgenjs-compat");
|
|
18
18
|
/**
|
|
19
19
|
* Using pptxGenJs on an automizer ISlide will create a temporary pptx template
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"generate-pptxgenjs.js","sourceRoot":"","sources":["../../../src/helper/generate/generate-pptxgenjs.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,mCAAoC;AACpC,
|
|
1
|
+
{"version":3,"file":"generate-pptxgenjs.js","sourceRoot":"","sources":["../../../src/helper/generate/generate-pptxgenjs.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,mCAAoC;AACpC,uEAA+C;AAW/C,wEAAuE;AAEvE;;;GAGG;AACH,MAAqB,iBAAiB;IAOpC,YAAY,SAAoB,EAAE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,WAAW,CAAC,SAAS,CACtB,CAAC;YACJ,CAAC,CAAC,CAAC;QACL,CAAC,CAAC,CAAC;IACL,CAAC;IAsED,kBAAkB;QAChB,OAAO,IAAI,CAAC,SAAS,CAAC,QAAQ,EAAE,CAAC;IACnC,CAAC;IAEK,OAAO;;YACX,8BAA8B;YAC9B,oEAAoE;YACpE,IAAI;QACN,CAAC;KAAA;CACF;AAjKD,oCAiKC"}
|
package/dist/types/types.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { ElementSubtype, ElementType } from '../enums/element-type';
|
|
|
2
2
|
import { ElementInfo, RelationshipAttribute, SlideInfo, TemplateInfo, XmlDocument, XmlElement } from './xml-types';
|
|
3
3
|
import IArchive, { ArchiveMode } from '../interfaces/iarchive';
|
|
4
4
|
import { ContentTypeExtension } from '../enums/content-type-map';
|
|
5
|
-
import type PptxGenJS from 'pptxgenjs';
|
|
5
|
+
import type PptxGenJS from '../vendor/pptxgenjs';
|
|
6
6
|
import { ILogger, Verbosity } from '../helper/logger';
|
|
7
7
|
import { IPptxGenJSSlide } from '../interfaces/ipptxgenjs-slide';
|
|
8
8
|
import { ShapeActionMode } from '../interfaces/ishape-action';
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
The MIT License (MIT)
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2015-2022 Brent Ely
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
# Vendored PptxGenJS 4.0.1
|
|
2
|
+
|
|
3
|
+
Unmodified copy of `dist/pptxgen.cjs.js` (-> `index.js`) and `types/index.d.ts`
|
|
4
|
+
from `pptxgenjs@4.0.1` (MIT, see `LICENSE`), https://github.com/gitbrent/PptxGenJS
|
|
5
|
+
|
|
6
|
+
Why: the npm package declares `image-size ^1.2.1`, which has two unpatched
|
|
7
|
+
advisories (CVE-2025-71329, CVE-2025-71330). The published bundle never loads
|
|
8
|
+
`image-size` (upstream issues #1473, #1474, #1529). Vendoring removes that
|
|
9
|
+
declared dependency from `pptx-templates`. Only `jszip` is needed at runtime.
|
|
10
|
+
|
|
11
|
+
No code changes were made. To update: copy the same two files from a newer
|
|
12
|
+
`pptxgenjs` release and re-run the test suite.
|