Block library: 15 blocks, registry, primitives, templates, manifest, eject

- @intecion/ipal-kit/blocks: libraryBlocks() opt-in, one builder per block, field
  builders, option merging, blockLibraryManifest, faqItemsFromLayout
- @intecion/ipal-kit/blocks/rsc: createBlockRegistry, the block components and UI
  primitives (token utilities only; next/image and next/link passed in)
- @intecion/ipal-kit/templates: 10 page templates as createSeeder data
- createSeeder: { $form: title } references
- ipal-blocks eject <block>
- tests: options, rendering and a11y per block, Payload + seeding, GraphQL, admin
  wording, schema snapshot (versioning), eject imports
- shorter admin labels: link "New tab", table of contents "Show contents"

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
Radosław Smoliński
2026-10-29 14:05:47 +01:00
co-authored by Claude Opus 5.5
parent 7918eaf6d4
commit 2d1cc0e77d
73 changed files with 5091 additions and 9 deletions
+1 -1
View File
@@ -86,7 +86,7 @@ const items = block.tableOfContents?.show ? extractHeadings(block.content) : []
(works without JS); in the browser the link of the section being read gets `aria-current="location"` and `classNames.linkActive`.
`classNames`: `nav`, `label`, `list`, `item`, `link`, `linkActive`; `offset` (default 0.3 of the screen height);
`data-ipal="toc"`, `data-level` on items.
- `buildTableOfContentsField({ name = 'tableOfContents' })` — a "Show table of contents" switch + a localized label (type `TableOfContentsSettings`).
- `buildTableOfContentsField({ name = 'tableOfContents' })` — a "Show contents" switch + a localized label (type `TableOfContentsSettings`).
A new field in a block = a migration (`pnpm payload migrate:create`).
## Click-to-enlarge images (lightbox, opt-in)