Skip to content

Bump pptx-svg from 0.5.10 to 0.6.2#14

Open
dependabot[bot] wants to merge 1 commit into
mainfrom
dependabot/npm_and_yarn/pptx-svg-0.6.2
Open

Bump pptx-svg from 0.5.10 to 0.6.2#14
dependabot[bot] wants to merge 1 commit into
mainfrom
dependabot/npm_and_yarn/pptx-svg-0.6.2

Conversation

@dependabot

@dependabot dependabot Bot commented on behalf of github Jun 30, 2026

Copy link
Copy Markdown

Bumps pptx-svg from 0.5.10 to 0.6.2.

Changelog

Sourced from pptx-svg's changelog.

0.6.2

Bug Fixes

  • flipH / flipV now applied when rendering (#55) — a shape's <a:xfrm flipH="1"/> / flipV="1" was dropped during rendering: only the rotate() part of the transform was emitted, so shapes and their (mirrored) text rendered un-flipped vs. PowerPoint. The renderer now emits a negative-scale mirror (scale(-1,1) / scale(1,-1)) about the shape center for autoshape geometry (rect, ellipse, preset/custom geom), images, picture borders and text, composed with any rotation as rotate(...) <mirror> (OOXML applies flip in the unrotated frame, then rotates). Group shapes (p:grpSp) are likewise mirrored about their center. Lines/connectors were already correct (they encode flip by swapping endpoints) and are unchanged.

0.6.1

Features

  • SmartArt diagram rendering — a bare p:graphicFrame whose graphicData uri is .../diagram (SmartArt) now renders its cached drawing instead of showing nothing. (Previously, SmartArt only rendered when wrapped in mc:AlternateContent — via the mc:Fallback shape group; a bare graphicFrame fell through to an empty shape.) The graphicFrame's dgm:relIds/@r:dm is followed to the diagram data part, then dsp:dataModelExt/@relId to the cached drawing (ppt/drawings/drawingN.xml); its dsp: shapes (which map 1:1 onto p: shapes — geometry, fills, line, effects, dsp:style/fontRef, text) are parsed into a group via parse_diagram_drawing. Cached drawings often omit run colors, so the text color is derived from the diagram colors part (dgm:txLinClrLst/dgm:txClrLst/dgm:txEffectClrLst) and applied to runs lacking an explicit color (parse_diagram_text_color + apply_diagram_text_color); text-bearing nodes with an unset <a:bodyPr/> anchor default to vertical center (SmartArt's default). The raw graphicFrame is preserved in ole_xml for round-trip export.

    • Known limitations vs. the SmartArt spec: (1) rendering uses the cached drawing only — the layout/algorithm engine (diagramLayout) is not run, so a SmartArt without a cached drawing part renders empty; (2) the color transform is applied as a single uniform text color (no per-node fillClrLst/linClrLst/txClrLst cycling — node fills/lines are taken as baked into the cached drawing); (3) the data model (dgm:dataModel pt/cxn lists) is not used for re-layout/editing — the diagram is treated as a static group.
  • Date / slide-number field placeholdersdt / sldNum placeholders backed by an <a:fld> field now render the live value instead of the cached literal: the slide-number field always shows the actual slide index (previously it showed the stale cached <a:t>, e.g. "1" on every slide), and the date field is filled with the current date. The date source is configurable via the new PptxRendererOptions.currentDate (Date | string | () => Date | string; default toLocaleDateString()) so output can be made deterministic for snapshot tests / exports. Footer (ftr) placeholders keep their own text, inheriting the layout/master text only when empty. New FFI current_date.

    • Note: header/footer text uses the master/template font (commonly Calibri); when that font is not installed, the browser/host substitutes a wider fallback (Helvetica/Arial), so footer text that fits on one line in PowerPoint may wrap. This is a font-metrics limitation, not a layout bug.
  • Underline color round-trip (R1) — underline color (<a:uFill> / <a:uLn>) is now parsed into the new TextRun.underline_color field, round-tripped via data-ooxml-underline-color, and serialized back to <a:uFill>, so it survives export. (The underline style value u="dbl"/wavy/… was already preserved.)

    • Visual limitation: underline style (double/dotted/wavy) and color are not drawn — browsers ignore text-decoration-style / text-decoration-color on SVG <text> entirely (verified in Chromium via presentation attribute, CSS property, and CSS shorthand). Rendering them requires drawing the underline as explicit <line>/<path> geometry (needs per-run box layout); tracked in TODO R1. The plain underline / strikethrough line still renders via the text-decoration presentation attribute.
    • Fixes a latent SVG-parser bug where color_or_none read the un-prefixed attribute name, so outline-color / 3D extrusion+contour colors / blip duotone colors were silently dropped on the SVG→model round-trip; they now round-trip correctly.

0.6.0

Direct-manipulation editing release: completes the E6 editing roadmap (P1–P6) — Undo/Redo history, inline text editing, z-order, atomic multi-shape transform, cross-slide copy/paste, and table editing — plus an interactive browser demo (web/editing.html) exercising all of them.

Features

  • Table editing (E6.6)updateTableCellText(slideIdx, shapeIdx, row, col, text) sets a cell's text (inheriting the cell's existing first-run formatting), and addTableRow / deleteTableRow / addTableColumn(.., afterCol?, widthEmu?) / deleteTableColumn insert/remove rows and columns (at least one row/column must remain). All undoable. New TableCell::empty() constructor + Wasm exports. v1 limitation: merged cells (gridSpan/rowSpan/hMerge/vMerge) are not span-adjusted on row/column changes — editing the structure of a merged table may corrupt it. This completes the E6 direct-manipulation editing roadmap (P1–P6).

  • Cross-slide shape copy/paste (E6.5)getShapeSpec(slideIdx, shapeIdx) extracts a shape as a portable, self-contained JSON spec (its OOXML fragment + any referenced images inlined as base64), and insertShapeSpec(slideIdx, spec, dxEmu?, dyEmu?) pastes it onto another slide, re-adding the media to the package and re-linking image relationships to fresh rIds on the target slide. Survives a clipboard round-trip; undoable. New Wasm exports get_shape_ooxml / add_shape_from_ooxml; serialize_shape made public and a new parse_shapes_xml parser added. New base64ToBytes util. v1 limitation: charts (serialized out-of-band) and external OLE/SmartArt parts are not copyable; image media only is re-linked.

  • Atomic multi-shape transform (E6.4)updateShapesTransform(slideIdx, items) applies new transforms (EMU; rot in 1/60000 deg) to several shapes in one call. Every shapeIdx is validated before any change is applied, so an invalid index leaves the slide untouched (no partial application), and the whole batch is a single undo step. Returns "OK:<count>". New Wasm export update_shapes_transform.

    • History fix: a failed/no-op updateShapesTransform no longer leaves a phantom undo step — a new guarded-checkpoint path (commitCheckpoint) captures the pre-edit snapshot but only commits it to the undo stack when the (atomic) operation succeeds.
  • Z-order operations (E6.3)bringToFront(slideIdx, shapeIdx) / sendToBack(...) / bringForward(...) / sendBackward(...) on PptxRenderer reorder a shape within its container (slide or group). z-order equals shape-array order (later = front-most), so these move the shape to the end / start / one step within the array. Each returns "OK:<newShapeIdx>" (the index changes when reordered, so the caller can re-select) and is undoable (integrated with the history). New Wasm exports bring_to_front / send_to_back / bring_forward / send_backward.

  • Inline text editing primitives (E6.2) — three new PptxRenderer methods to support a PowerPoint/Google-Slides–style direct-typing experience (double-click to edit, IME input) via a contentEditable overlay:

    • getTextLayout(slideIdx, shapeIdx) → JSON text geometry in EMU: box + lines → run boxes → per-character boxes (for drawing carets / selection rectangles). Reuses the renderer's wrap_paragraph and a newly shared autofit solver, so line and run counts always match the rendered SVG. v1 targets horizontal LTR text (left/center/right/justify); vertical/warp/math/multi-column bodies return only the bounding box.
    • hitTestText(slideIdx, shapeIdx, xEmu, yEmu) → JSON { paraIdx, runIdx, charOffset, paraOffset } mapping a click point to a caret insertion position.
    • replaceTextRange(slideIdx, shapeIdx, startPara, startChar, endPara, endChar, newText) → replace a text range (paragraph-level offsets), preserving the formatting of boundary runs (runs split/merge as needed). \n in newText splits into paragraphs; a range spanning paragraphs merges them. Undoable (integrated with the history below).
    • New TS types exported: TextLayout, TextLine, TextRunBox, GlyphBox, TextHit (and HistoryResult).
  • New Wasm exports get_text_layout / hit_test_text / replace_text_range.

Refactor

  • solve_text_autofit extracted from render_text (the normAutofit shrink loop) and shared with the new build_text_layout, so the geometry API uses identical font scaling. Render output is unchanged (verified by the existing renderer/Node suites).
  • De-duplicated per-run font resolution — the identical fs_raw/ff fallback logic in wrap_paragraph, measure_line_width, and build_text_layout is now shared helpers run_fs_px / run_font_face in renderer_text.mbt. Magic numbers named: default_run_fs_hundredths (18pt fallback), no_wrap_width_px (layout sentinel). Removed the unused slide_idx parameter from resolve_slide_data.
  • Inline text editing exports moved to src/main/main_text_edit.mbt (from main_edit.mbt) for cohesion. A new "Refactoring checklist" was added to CLAUDE.md.

... (truncated)

Commits
  • 8e50cbe Merge pull request #56 from t-ujiie-g/release/0_6_2
  • 94a7ebc release: v0.6.2
  • 87a1e83 Merge pull request #54 from t-ujiie-g/release/0_6_1
  • b6888e2 release: v0.6.1
  • 672a9f7 Merge pull request #53 from t-ujiie-g/feature/text_refactor
  • 65bba2c feat: add underline color support and round-trip functionality for text runs
  • cc0f2a3 Merge pull request #52 from t-ujiie-g/feature/date_slide_number
  • 9a65173 feat: add support for live date and slide number placeholders in presentations
  • 1c30326 Merge pull request #51 from t-ujiie-g/feature/smartart_rendering
  • 0183b45 feat: implement SmartArt diagram rendering and parsing for cached drawings
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [pptx-svg](https://github.com/t-ujiie-g/pptx-svg) from 0.5.10 to 0.6.2.
- [Changelog](https://github.com/t-ujiie-g/pptx-svg/blob/main/CHANGELOG.md)
- [Commits](t-ujiie-g/pptx-svg@v0.5.10...v0.6.2)

---
updated-dependencies:
- dependency-name: pptx-svg
  dependency-version: 0.6.2
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot Bot added dependencies Pull requests that update a dependency file javascript Pull requests that update javascript code labels Jun 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file javascript Pull requests that update javascript code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants