Skip to content

Commit cc7fcbc

Browse files
chore(release): version packages
1 parent 652f804 commit cc7fcbc

6 files changed

Lines changed: 63 additions & 57 deletions

File tree

.changeset/applyedits-layout-instantiation.md

Lines changed: 0 additions & 24 deletions
This file was deleted.

.changeset/render-and-font-transparency.md

Lines changed: 0 additions & 31 deletions
This file was deleted.

packages/slidewise/CHANGELOG.md

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,58 @@
11
# @textcortex/slidewise
22

3+
## 1.21.0
4+
5+
### Minor Changes
6+
7+
- 652f804: feat(pptx): layout-instantiation in `applyEdits` (lossless scale-with-variety)
8+
9+
`applyEdits` now supports `source: { layoutId, fills? }` in a `PlannedSlide`
10+
instantiating a fresh slide from one of the template's **own** layouts inside
11+
the lossless byte-patch path. Because the layout is already a part of `source`,
12+
the new slide binds to `ppt/slideLayouts/<layoutId>.xml` (inheriting theme /
13+
master / background chrome) while every other part stays byte-identical. This
14+
unlocks lossless **and** scale-with-variety in one deck: clone slides where you
15+
want the exact thing, instantiate from layouts where you want variety.
16+
17+
Each layout placeholder is materialised as an addressable, positioned element
18+
with a deterministic id — `layoutSlotElementId(layoutId, key)` (exported) where
19+
`key` is the `placeholderKey` / `summarizeLayouts` slot key. Text/`obj` slots
20+
are populated from `fills` and editable via `setText`; picture slots become a
21+
`<p:pic>` with a transparent placeholder blip so `setImage` can repoint them;
22+
chart/table/other slots expose their geometry so the host fills them with
23+
`addChart` / `addDiagram`. Placeholder geometry is read EMU-native from the
24+
layout (falling back to the matching master slot), so it stays correct without a
25+
canvas-px round-trip. An unresolvable `layoutId` is surfaced via `onWarning` and
26+
the slide is skipped rather than shipped wrong.
27+
28+
- 652f804: feat(render): headless `renderDeckToImages` + `deck.fontUsage` font transparency
29+
30+
**Headless render-to-image (visual-QA loop).** New browser-free renderer that
31+
draws **what the editor draws** — native charts (`buildChartOption` + ECharts
32+
SSR), diagrams (`layoutDiagram`), text/shapes/images/backgrounds in z-order —
33+
_not_ the OOXML raster fallbacks. No Playwright/Chromium/DOM.
34+
35+
- `renderDeckToSvg(deck, opts?)` → one composed SVG per slide (ECharts is
36+
loaded on demand, so it never bloats the editor bundle).
37+
- `renderDeckToImages(deck, opts?)` / `renderSlideToImage(deck, i, opts?)` /
38+
`renderPptxToImages(bytes, opts?)` → raster bytes. Rasterisation is an
39+
injected hook (`opts.rasterizeSvg`, e.g. `@resvg/resvg-js`); when omitted the
40+
default tries a dynamic `@resvg/resvg-js` import and throws a clear error if
41+
it isn't installed — so there's no hard native dependency.
42+
- `opts`: `slides` (1-based subset), `dpi` (canvas scales by `dpi/96`),
43+
`format`, `maxWidth` (thumbnail cap). Deterministic (no animation).
44+
45+
Enables the host's render → fresh-eyes inspect → targeted `applyEdits` fix →
46+
re-render cycle, rendering a final `applyEdits` output directly.
47+
48+
**Font transparency.** `parsePptx` now stamps `deck.fontUsage:
49+
{ family, embedded }[]` — every font family the deck's text uses, flagged
50+
whether the source PPTX actually **embeds** it (`<p:embeddedFontLst>` → a real
51+
`ppt/fonts/*` part) or merely **references** it (system-fallback risk on
52+
viewers that don't ship the brand font). Hosts use it to warn at generation
53+
time ("missing fonts for some ppts"). It's a read-only diagnostic, distinct from
54+
`deck.fonts` (the embeddable payloads).
55+
356
## 1.20.0
457

558
### Minor Changes

packages/slidewise/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@textcortex/slidewise",
3-
"version": "1.20.0",
3+
"version": "1.21.0",
44
"description": "Embeddable React PPTX editor.",
55
"license": "MIT",
66
"type": "module",

website/CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
# website
22

3+
## 0.0.35
4+
5+
### Patch Changes
6+
7+
- Updated dependencies [652f804]
8+
- Updated dependencies [652f804]
9+
- @textcortex/slidewise@1.21.0
10+
311
## 0.0.34
412

513
### Patch Changes

website/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "website",
3-
"version": "0.0.34",
3+
"version": "0.0.35",
44
"private": true,
55
"type": "module",
66
"scripts": {

0 commit comments

Comments
 (0)