Logo Cloud Inline Wrap
A single wrapping row that keeps the label inline with editable trust logos, installed as a wired Payload block.
import type { Block } from 'payload'import { logoCloudFields } from '@/blocks/shared/logoCloudFields'export const LogoCloudInlineWrap: Block = { slug: 'logoCloudInlineWrap', interfaceName: 'LogoCloudInlineWrapBlock', fields: [ // Shared logo-cloud core (heading + logos). Edit the shared shape in // @/blocks/shared/logoCloudFields to update every logo-cloud variant. ...logoCloudFields, ], labels: { plural: 'Logo Cloud Inline Wrap Blocks', singular: 'Logo Cloud Inline Wrap', },}import React from 'react'import type { LogoCloudInlineWrapBlock as LogoCloudInlineWrapBlockData } from '@/payload-types'import { Media } from '@/components/Media'import { cn } from '@/utilities/ui'type Props = LogoCloudInlineWrapBlockData & { id?: string className?: string disableInnerContainer?: boolean}export const LogoCloudInlineWrapBlock: React.FC<Props> = ({ className, disableInnerContainer, heading, id, logos,}) => { return ( <section className={cn('container', className)} id={id ? `block-${id}` : undefined}> <div className="overflow-hidden rounded-frame border border-border/70 bg-card/35 px-6 py-10 sm:px-8 lg:px-12 lg:py-14"> <div className={cn('flex flex-wrap items-center gap-x-8 gap-y-4', { 'mx-auto max-w-5xl': !disableInnerContainer, })} > <p className="text-muted-foreground">{heading}</p> {logos && logos.length > 0 ? ( <div className="flex flex-wrap items-center gap-x-8 gap-y-4"> {logos.map((item, index) => { const logo = ( <Media resource={item.logo} imgClassName="h-6 w-auto object-contain" /> ) return ( <div className="flex items-center" key={item.id ?? `${item.name}-${index}`}> {item.href ? ( <a aria-label={item.name} href={item.href}> {logo} </a> ) : ( logo )} </div> ) })} </div> ) : null} </div> </div> </section> )}import type { Field } from 'payload'/** * Shared field core for the Logo Cloud kit family. * * Every logo-cloud variant (logo-cloud-grid, logo-cloud-hover, * logo-cloud-marquee, logo-cloud-inline, logo-cloud-inline-wrap, …) spreads * these fields first and then appends its own variant-specific shape (for * example the hover variant adds a CTA link group). Editing the shared * heading/logos shape here updates every installed logo-cloud block at once, * so the family never drifts field-by-field across a repo. * * Each logo is an editable Media upload plus an accessible name and an * optional link, so editors manage the wall of logos from the admin instead * of shipping hardcoded brand SVGs. * * Installed once per repo at `src/blocks/shared/logoCloudFields.ts`; re-running * `payload-components add logo-cloud-*` never overwrites a copy you have already edited. */export const logoCloudFields: Field[] = [ { name: 'heading', type: 'text', required: true, }, { name: 'logos', type: 'array', required: true, minRows: 2, maxRows: 12, admin: { initCollapsed: true, }, fields: [ { name: 'logo', type: 'upload', relationTo: 'media', required: true, }, { name: 'name', type: 'text', required: true, }, { name: 'href', type: 'text', }, ], },]Installation
npx payload-components add logo-cloud-inline-wrapCopy the files straight from the registry, then wire the Payload fragments by hand:
pnpm dlx shadcn@latest add https://www.payload-components.xyz/r/logo-cloud-inline-wrap.jsonWhat it installs
Copies 3 source files into your project:
src/blocks/shared/logoCloudFields.tssharedsrc/blocks/LogoCloudInlineWrap/config.tssrc/blocks/LogoCloudInlineWrap/Component.tsx
…and makes 4 edits to wire the block into your project:
| Registers the block | src/collections/Pages/index.ts |
| Maps the renderer | src/blocks/RenderBlocks.tsx |
| Regenerates types | src/payload-types.ts |
| Regenerates the admin import map | src/app/(payload)/admin/importMap.js |
logoCloudFields.ts is the shared field core for this family — every variant composes it. Editing it updates each installed block at once, and re-running an install never overwrites a copy you have changed.Re-running the install converges: it detects existing wiring, skips it, and records install state in .payload-components/state.json.
Content model
Both fields come from the shared logoCloudFields base shared across the Logo Cloud family.
Prop
Type
Each item in logos carries:
Prop
Type
Usage
LogoCloudInlineWrap block to its layout.RenderBlocks on the frontend, fully typed — no extra wiring.Requirements
- Target
- payload-website-starter
- Payload
- v3
- Next.js
- 15 / 16
- shadcn UI
- none
Your project must already expose components.json, src/payload.config.ts, src/blocks/RenderBlocks.tsx, src/collections/Pages/index.ts — the surfaces payload-components add patches. The CLI verifies this against the support matrix before touching anything.
In this family
logo-cloud-gridlogo-cloud-hoverlogo-cloud-marqueelogo-cloud-inlinelogo-cloud-inline-wrapcurrent