Repository navigation
Conversation
Each of the 79 block configs now sets admin.images.thumbnail, so every
tile in the Blocks Drawer shows a schematic of the block's layout under
its family heading. Editors can tell Pricing Cards from Pricing Split
without reading the labels.
The picture is an SVG data URI exported from the block's own
~/src/blocks/<Name>/thumbnail.ts as { alt: '', url }. That keeps it text
only: no public/ file, no request to payload-components.xyz, and nothing
to fetch. The alt text is empty because the drawer prints the block's
label under the picture.
The SVGs are generated, never hand-drawn:
- tools/payload-components/block-thumbnail-recipes.ts describes each
block's demo twin as a short recipe of layout primitives
(block-thumbnails.ts)
- `pnpm thumbnails:build` renders the recipes to a 3:2 canvas
- tests/int/blocks-drawer-thumbnails.int.spec.ts fails while a committed
thumbnail.ts differs from its recipe, and checks that each picture is
offline, 3:2 and small
admin.images arrived in Payload 3.79.0, and older Payload 3 Block types
reject it (TS2353). The Payload 3 floor therefore moves from 3.25.0 to
3.79.0:
- support-matrix.json minimumVersions.payload
- every manifest's peer range is now ^3.79.0 || ^4.0.0-0
- doctor and the docs follow
Gating admin.images at install time was rejected. Direct shadcn installs
would still fail to compile, and diff, update and the baselines would
need a second source transform.
`new` and the component template ship a thumbnail.ts too. `new` copies
the nearest sibling's recipe (or the template recipe for a new family)
and prints a step to redraw it.
Block manifests get a minor bump with a changelog line and fresh install
baselines. Also updated:
- the site catalog projection, the hero-basic landing ledgers, and the
three blog figures that excerpt HeroBasic's config
- the blog cover's roomy code density now stops at five lines, since
hero-basic's six-line registry item overflowed its card
- the docs Code tab lists the generated thumbnail.ts last
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Important Review skippedToo many files! This PR contains 273 files, which is 173 over the limit of 100. To get a review, reduce the PR to 100 files or fewer by splitting it into smaller PRs or changing its base branch. Upgrade to a paid plan to raise the limit. This review couldn't start because sufficient usage credits or metered capacity aren't available. Add credits or update usage-based reviews in the billing tab, then retry.
|
The landing install frame lists hero-basic's new thumbnail.ts, so the page is 30px taller, and the hero badge now reads REV 0.3.0. Minted by the visual-baselines workflow (frontend, changed) on this branch, run 42806876623. The blog-visual mint found nothing to change. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Every block in Payload's admin Blocks Drawer ("Add Layout") now shows a picture of its layout under its family heading. An editor can tell Pricing Cards from Pricing Split without reading the labels. This is the follow-up #654 deferred.
admin.images.thumbnailfrom a new~/src/blocks/<Name>/thumbnail.ts. That file exports{ alt: '', url }, whereurlis an SVGdata:URI.public/and the editor's browser makes no request to payload-components.xyz.altstraight to the<img>, so a missing alt would make screen readers announce the data URI.tools/payload-components/block-thumbnail-recipes.tsdescribes each block's demo twin as a short recipe of layout primitives (headline bars, copy bars, pills, cards, media) fromblock-thumbnails.ts.pnpm thumbnails:buildrenders the recipes on a 3:2 canvas. A taller layout gets a wider canvas rather than a squashed one.<img>cannot read the admin theme. Payload's own placeholder picture is fixed-colour too.tests/int/blocks-drawer-thumbnails.int.spec.ts, fails if:thumbnail.tsdiffers from what its recipe renders;thumbnail.ts, andpayload-components newwrites one.newcopies the nearest sibling's recipe (the template's for a new family) into the recipes file and prints a step to redraw it.admin.images.iconis not set, because these are Pages layout blocks, not Lexical blocks.Breaking: Payload 3 minimum version is now 3.79.0
admin.imageswas added to Payload'sBlocktype in 3.79.0 (2026-03-04). Older Payload 3 types reject it with TS2353, sonext buildwould fail. To handle that:support-matrix.jsonsetspayloadMajorSupport["3"].minimumVersions.payloadto"3.79.0".peerDependencies.payload: "^3.79.0 || ^4.0.0-0", andnewscaffolds the same range.doctor, the docs Requirements line ("v3 (3.79 or newer)"), the installation and registry docs, the README and AGENTS.md all follow.Who loses support: projects on Payload 3.25–3.78. They can upgrade Payload within 3.x, or stay on payload-components 2.x. As with #654 → 2.0.0, the next CLI release that includes this should be a major (3.0.0), with a Breaking section in its release notes.
We considered keeping 3.25 and having
addstripadmin.imagesbelow 3.79, recorded in install state the way--localizedis. We rejected it for two reasons: directshadcn addinstalls would still ship source that fails to compile, anddiff,updateand the install baselines would all need a second source transform. The full reasoning is inpayload-components/README.md→ "Admin Blocks Drawer".Versioning and generated files
thumbnail.tsin itsfiles; the registry items list it too.registry:snapshotappended 79 new install baselines. No existing baseline changed.updateon an install recorded at the previous version now also writesthumbnail.ts. The update specs pin that.src/lib/site.tsnow say "copied 4 block source files", andthumbnail.tsappears in the frame and the wiring ledger.thumbnail.tslast.Verification
Local, macOS, on this branch rebased onto
main(2.0.0):pnpm lint,pnpm format:check,pnpm i18n:check,pnpm exec tsc --noEmit,pnpm test:registry: all exit 0pnpm run test:int: exit 0 (884 passed, 1 skipped)pnpm test:fresh --scenario website --keep-tempexited 0 with 26 blocks covering every family. It used a fresh[email protected]website project on SQLite and ranadd,generate:types,tsc --noEmit,next build, and a start-and-render check. The blocks were hero-basic, hero-split, hero-video, hero-aurora, feature-grid-basic, feature-bento, feature-steps, pricing-cards, pricing-split, faq-accordion, faq-grid, call-to-action-centered, call-to-action-signup, contact-form-basic, testimonials-grid, testimonials-rating, logo-cloud-grid, stats-grid, team-grid, content-showcase, content-quote, integration-orbit, comparator-grid, embed-basic, collection-query and footer-columns.alt="", in both the light and the dark theme. The starter's own five blocks keep Payload's grey placeholder below the divider. The screenshots were shared in the session.pnpm buildwere not run locally; CI covers them.Notes
landing-home-*changes because the install frame gained a file row, andblog-article-*may change because the what-is-a-payload-cms-block figure changed. They are minted with thevisual-baselinesworkflow; they can't be produced locally..webpfiles were not regenerated. They were already older than this change (last refreshed in PinZheng(release): promote dev to main #334).🤖 Generated with Claude Code