Skip to content

v1.3.0

Latest

Choose a tag to compare

@kadamwhite kadamwhite released this 07 Sep 17:09
12f8dd4

1.3.0

What's Changed

Added

  • Introduced map_inner_blocks() helper: replace each inner block via a callback while keeping innerContent placeholders in sync. The callback may return blocks and literal HTML strings. Pattern resolution, transformations, and Template placeholder replacement all use it. (#22)

Fixed

  • Literal HTML between inner blocks (e.g. an <hr> separator or raw markup) is no longer discarded when a sibling is removed by a _delete transformation or when a nested pattern reference is resolved. (#22)
  • Freeform blocks between a resolved pattern's top-level blocks are now kept as literal innerContent chunks instead of being dropped. (#17 & #22, thanks @saarnilauri)
  • core/table blocks converted from legacy markup no longer fail block validation. Presentational attributes (valign, bgcolor, border, cellpadding, cellspacing) are stripped and hasFixedLayout is set explicitly to match what core/table saves. (#20)
  • replace_text() no longer corrupts blocks whose wrapper is a void element such as core/separator. Those blocks are left unchanged. (#18, thanks @saarnilauri)

Changed

  • rebuild_inner_content() is now a fallback for blocks whose placeholders don't line up with their children. Its core/cover early return, which left stale placeholders in place, is removed. (#22)
  • When rebuilding block wrapper markup, attribute names outside [a-zA-Z0-9:_.-] are dropped rather than re-emitted verbatim. No effect on standard block markup. (#18)

New Contributors

Full Changelog: v1.2.0...v1.3.0