@office-kit/pptx 0.24.0 → 0.25.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/CHANGELOG.md +23 -0
- package/README.md +4 -3
- package/dist/{api-BNwRBemN.js → api-DQMkljVK.js} +746 -281
- package/dist/api-DQMkljVK.js.map +1 -0
- package/dist/{index-WCK8v0WT.d.ts → index-DVqlSlMs.d.ts} +86 -22
- package/dist/index.d.ts +2 -2
- package/dist/index.js +2 -2
- package/dist/node.d.ts +2 -2
- package/dist/node.js +2 -2
- package/package.json +1 -1
- package/dist/api-BNwRBemN.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,28 @@
|
|
|
1
1
|
# @office-kit/pptx
|
|
2
2
|
|
|
3
|
+
## 0.25.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- e46d45b: `compactPackage` now removes every part that cannot be reached from the package root (`/_rels/.rels`) through internal relationships, not only `/ppt/media/` parts. This drops the charts, embedded workbooks, notes slides and tags that `removeSlide` leaves behind, so the saved file no longer carries a removed slide's chart data. Any other part nothing points at, such as custom data added without a relationship, is removed too. If the root relationships do not reach `/ppt/presentation.xml`, nothing is removed. `getOrphanMediaPartNames` follows the same rule, so media used only by an unreachable part now counts as orphaned. In the editor, copied slides and shapes no longer carry the other slides' notes, charts and workbooks.
|
|
8
|
+
- 2bcceca: New `setChartData(chart, { kind?, categories?, series? })` replaces the data of a bar, column, line, area, pie or doughnut chart. When the kind and the set of series names stay the same, it rewrites only the cached values and their ranges in the chart part, so formatting from another app (colors, number formats, layout, extensions) is kept; changing the kind or the series builds the chart again through `setChartSpec`, carrying over its title, axis titles, legend and series colors. The embedded workbook is rewritten either way. It throws when `categories` or `series` is empty, when a series does not have one value per category, and on charts of other kinds; a date category axis takes its categories as date serial numbers.
|
|
9
|
+
|
|
10
|
+
### Patch Changes
|
|
11
|
+
|
|
12
|
+
- 3293e4a: Charts now write their axis tick marks even when none are authored. An absent `<c:majorTickMark>` / `<c:minorTickMark>` means `cross` in the schema, so some apps drew ticks crossing every axis. The defaults written are: value axes (including a scatter / bubble chart's horizontal axis and the secondary value axis) major `out`, minor `none`; the category axis major `none` on bar and column charts and `out` on the others, minor `none`; the series (depth) axis of 3-D and surface charts major `out`, minor `none`. Authored `*TickMark` fields are written as before. Reading such a chart back now reports these tick marks.
|
|
13
|
+
- 3293e4a: Fixed two problems with `ChartSeries.pointDataLabels`. A per-point label with literal `text` lost its `textStyle` (color, bold, size, font), because apps ignore a label's `<c:txPr>` once it carries its own text; the style is now also written into the label's rich text. And setting `pointDataLabels` without the series-level `dataLabels` threw at build time even though the types allow it; the other points of the series now keep the chart-level `dataLabels` (or show no label when there are none), so a per-point override no longer hides the labels of its neighbours. That fallback is written as the series' own labels, so reading such a chart back reports it as the series' `dataLabels`, and a later change to the chart-level `dataLabels` no longer reaches that series.
|
|
14
|
+
- a27d7f1: Fixed: loading a `.pptx` with many parts took time quadratic in the part count, because each part's content type was found by scanning every `<Override>` in `[Content_Types].xml` and each part lookup scanned every part. A package with 30,000 parts and overrides took about 7 seconds to load; it now takes about a quarter of a second.
|
|
15
|
+
- a27d7f1: Fixed: a small `.pptx` whose ZIP entries understate their decompressed size could block `loadPresentation` for seconds or minutes. The load now throws as soon as an entry outgrows its declared size, so decompression work is bounded by the uncompressed sizes recorded in the archive's central directory (plus at most about 17 MB per load).
|
|
16
|
+
|
|
17
|
+
`loadPresentation` also now throws on malformed archives it used to read silently: an entry whose data is shorter than declared, an entry declaring more data than its compressed bytes could possibly hold, a stored entry whose two sizes differ, two entries with the same name, and offsets or sizes that point outside the file. Errors for corrupt compressed data now start with `invalid ZIP:` and name the entry.
|
|
18
|
+
|
|
19
|
+
## 0.24.1
|
|
20
|
+
|
|
21
|
+
### Patch Changes
|
|
22
|
+
|
|
23
|
+
- 44afe47: Fixed: `getCoreProperties` returned `null`, and `setCoreProperties` added a second core-properties part and relationship, for packages that store core properties somewhere other than `/docProps/core.xml` (e.g. `package/services/metadata/core-properties/….psmdcp`) (#457). Core and extended properties are now found through the package's root relationships, as OPC specifies, so `getExtendedProperties` / `setExtendedProperties` also work when `app.xml` lives elsewhere. A `/docProps/core.xml` part that no relationship points at is no longer read as the core properties, and a core-properties relationship whose target escapes the package root (`../…`) now throws instead of being ignored.
|
|
24
|
+
- 5de41e0: Fixed: `duplicateSlide`, `addSlideImage` and other edits could save XML with an unbound `r:` (or other) prefix when the template declared that prefix on individual elements instead of the part root, so the saved file failed to load (#456). The writer now declares any prefix a new element or attribute uses that is not already in scope.
|
|
25
|
+
|
|
3
26
|
## 0.24.0
|
|
4
27
|
|
|
5
28
|
### Minor Changes
|
package/README.md
CHANGED
|
@@ -332,9 +332,10 @@ and a next-actions table. Use labelled sample data where needed.
|
|
|
332
332
|
The [skill](skill/SKILL.md) creates a TSX project, starts the interactive preview,
|
|
333
333
|
checks the source and exports an editable PPTX. Ask for changes in the same
|
|
334
334
|
conversation; the preview updates as the agent edits TSX. It plans the storyline for
|
|
335
|
-
either a talk or a deck people read and decide from,
|
|
336
|
-
Japanese wording before delivery
|
|
337
|
-
[
|
|
335
|
+
either a talk or a deck people read and decide from, applies type, color, chart and
|
|
336
|
+
table rules, and checks the headlines and Japanese wording before delivery
|
|
337
|
+
([talk](skill/references/story-talk.md), [document](skill/references/story-document.md),
|
|
338
|
+
[design](skill/references/design.md), [review](skill/references/review.md)).
|
|
338
339
|
You need Node.js 22.18+
|
|
339
340
|
and Git alongside Claude Code. See the
|
|
340
341
|
[authoring guide](https://office-kit.github.io/pptx/docs/authoring) for template
|