Skip to content

Document Creator 0.4.6: Choose annotated or raw photos per image slot

Document Creator 0.4.6 adds an Include annotations toggle to each image slot in a template, and fixes a crash when sizing images.

The toggle is on by default, which keeps today’s behaviour. Turned off, it tells the host app to use the raw photo for that slot instead of one with drawn annotations flattened in. The module stores the setting and passes it on; preparing the right image is up to the host app.

Inserting an image could fail when its source height was unknown. The height now travels with each image, and when it is missing the module falls back to the configured or default height. Links that open in a new tab also gained rel="noopener noreferrer".

Full release notes: Document Creator 0.4.6

0.4.6 · 9 June 2026

Fixed

  • Image height arithmetic no longer divides by nil. GoogleDocsClient.build_media_items/1 now preserves the source height_px so scale_height/3 always has a denominator; previously a missing height could crash the inline image sizing path.
  • scale_height/3 hardened against nil source height. If the source height is missing, the function now falls back to the configured/default height instead of raising.
  • Image config lookup centralised. Both the inline and table-grid image paths read width/height config through the same helper, removing an atom-keyed fallback that mishandled explicit false for future boolean flags.

Changed

  • Dependencies refreshed. phoenix_kit 1.7.126 patch bump.

Internal

  • Added regression tests pinning the exact rendered height (450.0 PT) and ensuring build_media_items/1 carries height_px end-to-end.

Document Creator 0.4.6. Install or update: {:phoenix_kit_document_creator, "~> 0.4"}, then mix deps.get && mix phoenix_kit.update. Full history: CHANGELOG.