Skip to content

v1.3.0

Choose a tag to compare

@Klehm Klehm released this 05 Oct 12:57
· 102 commits to master since this release
b368df6

This release lets a host narrow the builder down to what its editors need, and fixes how routes are mounted on Symfony 7.4+. Everything is additive: existing pages render the same.

A narrower builder (klehm/content-blocks)

content_blocks.structure decides what editors can do to sections and columns:

  • sections: hidden — a blocks-only builder. No section in the UI: blocks stack in one full-width section, created by the server with the first block.
  • sections: fixed — a skeleton to fill. Sections stay selectable, but can't be added, moved, duplicated, deleted, pasted or inserted.
  • columns: false — removes the Columns and Layout panels.

The endpoints refuse what a mode rules out (409, reasons: ["structure"]), so it holds beyond the UI. To choose per area, alias BuilderStructureResolverInterface.

content_blocks.styling: false hides the free styling fields (spacing, background, alignment). Use { block: false } or { section: false } to hide them in one sidebar only. Section style presets stay available. This is UI-only: stored values still render and survive a save.

→ Builder structure

Import and Export, each on its own (klehm/content-blocks)

ContentAreaType gains enable_import and enable_export (enableImport / enableExport on a launcher you include directly), so you can keep Export and drop Import, or the reverse. Left at null, they follow enable_import_export, which keeps its meaning.

Fixed

  • On Symfony 7.4+, routes were mounted at the root (/upload, /area/{id}/publish…) instead of under their prefix, in all three packages. A new app's config/routes.yaml imports routing.controllers, which picked up the packages' controllers a second time. They are no longer autoconfigured. Nothing to change on your side.
  • doctrine/collections 3 is accepted. A fresh Symfony 8.1 app on PHP 8.4 no longer needs composer require -W.
  • The Flex recipes apply without allow-contrib. Flex no longer asks before each recipe, and no longer skips them on a non-interactive install.

Upgrading

No database migration. The three packages are tagged together.

composer update "klehm/content-blocks*"

Details in each package's changelog: core · kit · i18n