{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "logo-wall",
  "title": "Logo Wall",
  "description": "Logos you have permission to show, in three decisions: a quiet row, a plate for each, or a marquee for more than fit. Includes dashed placeholders to build with until you have them.",
  "dependencies": [
    "lucide-react",
    "motion"
  ],
  "registryDependencies": [
    "utils",
    "https://miseui.junsu4621.workers.dev/r/icon-button.json",
    "https://miseui.junsu4621.workers.dev/r/marquee.json"
  ],
  "files": [
    {
      "path": "registry/miseui/blocks/logo-wall.tsx",
      "content": "import { cn } from \"@/registry/miseui/lib/utils\"\nimport { LogoWallMarquee, type LogoWallMarqueeProps } from \"./logo-wall-marquee\"\nimport { DEFAULT_TITLE, LogoMark, LogoPlaceholder, LogoWallLine, ROOT_CLASS, placeholderLogos, type LogoWallCopyProps, type LogoWallLogo } from \"./logo-wall-parts\"\n\ntype LogoWallVariant = \"row\" | \"grid\" | \"marquee\"\n\ninterface LogoWallProps extends LogoWallMarqueeProps {\n  /** `row` a quiet line for a few logos, `grid` a plate for each when the list itself is the point, `marquee` more logos than fit, moving. Anything else is `row`. */\n  variant?: LogoWallVariant\n}\n\nfunction LogoWallRow({ logos, title = DEFAULT_TITLE, titleQuiet, monochrome = true, className, ...props }: LogoWallCopyProps) {\n  if (logos.length === 0) return null\n  return (\n    <section data-slot=\"logo-wall\" data-variant=\"row\" className={cn(ROOT_CLASS, \"bg-background\", className)} {...props}>\n      <div className=\"mx-auto flex w-full max-w-6xl flex-col items-center gap-6 px-4 py-12 @2xl:px-8\">\n        <LogoWallLine title={title} quiet={titleQuiet} className=\"text-center\" />\n        <ul className=\"flex flex-wrap items-center justify-center gap-x-8 gap-y-4 @3xl:gap-x-12\">\n          {logos.map((logo) => (\n            <li key={logo.name} className=\"flex min-w-0 items-center\">\n              <LogoMark logo={logo} monochrome={monochrome} />\n            </li>\n          ))}\n        </ul>\n      </div>\n    </section>\n  )\n}\n\nfunction LogoWallGrid({ logos, title = DEFAULT_TITLE, titleQuiet, monochrome = true, className, ...props }: LogoWallCopyProps) {\n  if (logos.length === 0) return null\n  return (\n    <section data-slot=\"logo-wall\" data-variant=\"grid\" className={cn(ROOT_CLASS, \"bg-muted dark:bg-background\", className)} {...props}>\n      <div className=\"mx-auto flex w-full max-w-6xl flex-col gap-8 px-4 py-12 @2xl:px-8 @2xl:py-16\">\n        {title ? (\n          <h2 className=\"max-w-2xl text-title text-3xl text-balance @2xl:text-4xl\">\n            {title} {titleQuiet ? <span className=\"text-muted-foreground\">{titleQuiet}</span> : null}\n          </h2>\n        ) : null}\n        {/* Flex and not grid: a last row that does not fill stays centred, with no hole at the end. */}\n        <ul className=\"flex flex-wrap justify-center gap-2\">\n          {logos.map((logo) => (\n            <li key={logo.name} className=\"flex h-24 w-[calc(50%-4px)] min-w-0 items-center justify-center rounded-2xl border bg-background p-4 dark:bg-card @2xl:w-[calc(25%-6px)]\">\n              <LogoMark logo={logo} monochrome={monochrome} />\n            </li>\n          ))}\n        </ul>\n      </div>\n    </section>\n  )\n}\n\nfunction LogoWall({ variant, duration, ...props }: LogoWallProps) {\n  switch (variant) {\n    case \"grid\":\n      return <LogoWallGrid {...props} />\n    case \"marquee\":\n      return <LogoWallMarquee duration={duration} {...props} />\n    default:\n      return <LogoWallRow {...props} />\n  }\n}\n\nexport { LogoPlaceholder, LogoWall, placeholderLogos, type LogoWallLogo, type LogoWallProps, type LogoWallVariant }\n",
      "type": "registry:component"
    },
    {
      "path": "registry/miseui/blocks/logo-wall-parts.tsx",
      "content": "import type * as React from \"react\"\nimport { Diamond, Hexagon, Octagon, Pentagon, Square, Triangle } from \"lucide-react\"\nimport { cn } from \"@/registry/miseui/lib/utils\"\n\ninterface LogoWallLogo {\n  /** The accessible name. Required, because a logo says nothing to a screen reader on its own. */\n  name: string\n  /** A transparent PNG or an SVG. */\n  src?: string\n  /** Your own mark, such as an inline SVG, instead of `src`. Without either, the name is set as a wordmark. */\n  mark?: React.ReactNode\n  /** Makes the logo a link, such as to a case study. */\n  href?: string\n}\n\ninterface LogoWallCopyProps extends Omit<React.ComponentProps<\"section\">, \"title\"> {\n  /** Only logos you have permission to show. An empty list renders nothing. */\n  logos: readonly LogoWallLogo[]\n  /** Null removes the line. */\n  title?: string | null\n  /** Continues the title, one tone quieter. */\n  titleQuiet?: string\n  /** Paints each `src` image as one flat colour, so unrelated logos sit together in both themes. Turn it off for logos on a solid background, which would become a block. */\n  monochrome?: boolean\n}\n\nconst DEFAULT_TITLE = \"Used by teams like yours.\"\nconst ROOT_CLASS = \"@container flex w-full flex-col justify-center\"\n\n/** One flat colour from any logo. It needs a transparent background. */\nconst MONOCHROME_CLASS = \"opacity-60 brightness-0 dark:invert\"\n\nconst PLACEHOLDER_SHAPES = [Square, Triangle, Hexagon, Diamond, Pentagon, Octagon] as const\n\n/** Dashed and numbered: nobody can mistake this for a customer, and an unfinished page cannot quietly claim one. */\nfunction LogoPlaceholder({ index }: { index: number }) {\n  const Shape = PLACEHOLDER_SHAPES[index % PLACEHOLDER_SHAPES.length] ?? Square\n  return (\n    <span data-slot=\"logo-wall-placeholder\" className=\"inline-flex h-10 items-center gap-2 rounded-lg border border-dashed border-foreground/25 px-3 text-[13px] whitespace-nowrap text-muted-foreground\">\n      <Shape aria-hidden=\"true\" className=\"size-4\" />\n      Logo {index + 1}\n    </span>\n  )\n}\n\n/** Marks to build the page with until you have real logos and permission to show them. */\nfunction placeholderLogos(count = 8): readonly LogoWallLogo[] {\n  return Array.from({ length: count }, (_, index) => ({ name: `Placeholder logo ${index + 1}`, mark: <LogoPlaceholder index={index} /> }))\n}\n\nfunction LogoContent({ logo, monochrome }: { logo: LogoWallLogo; monochrome: boolean }) {\n  if (logo.mark) {\n    return (\n      <span role=\"img\" aria-label={logo.name} className=\"inline-flex items-center\">\n        {logo.mark}\n      </span>\n    )\n  }\n  if (logo.src) {\n    return <img src={logo.src} alt={logo.name} loading=\"lazy\" decoding=\"async\" className={cn(\"h-8 w-auto max-w-36 object-contain\", monochrome && MONOCHROME_CLASS)} />\n  }\n  return <span className=\"text-base font-semibold tracking-tight whitespace-nowrap text-muted-foreground\">{logo.name}</span>\n}\n\nfunction LogoMark({ logo, monochrome }: { logo: LogoWallLogo; monochrome: boolean }) {\n  if (!logo.href) return <LogoContent logo={logo} monochrome={monochrome} />\n  return (\n    <a\n      href={logo.href}\n      className=\"inline-flex min-h-10 min-w-10 items-center justify-center rounded-sm outline-none transition-opacity duration-(--duration-fast) ease-(--ease-mise) hover:opacity-70 focus-visible:ring-[3px] focus-visible:ring-ring/50\"\n    >\n      <LogoContent logo={logo} monochrome={monochrome} />\n    </a>\n  )\n}\n\n/** The size of a caption: logos are supporting evidence, and the page has its own headline. */\nfunction LogoWallLine({ title, quiet, className }: { title: string | null; quiet?: string; className?: string }) {\n  if (!title) return null\n  return (\n    <h2 className={cn(\"text-[15px] leading-relaxed font-medium text-pretty\", className)}>\n      {title} {quiet ? <span className=\"font-normal text-muted-foreground\">{quiet}</span> : null}\n    </h2>\n  )\n}\n\nexport { DEFAULT_TITLE, LogoMark, LogoPlaceholder, LogoWallLine, ROOT_CLASS, placeholderLogos, type LogoWallCopyProps, type LogoWallLogo }\n",
      "type": "registry:component"
    },
    {
      "path": "registry/miseui/blocks/logo-wall-marquee.tsx",
      "content": "import { useState } from \"react\"\nimport { useReducedMotion } from \"motion/react\"\nimport { Pause, Play } from \"lucide-react\"\nimport { cn } from \"@/registry/miseui/lib/utils\"\nimport { IconButton } from \"@/registry/miseui/ui/icon-button\"\nimport { Marquee, MarqueeItem } from \"@/registry/miseui/ui/marquee\"\nimport { DEFAULT_TITLE, LogoMark, LogoWallLine, ROOT_CLASS, type LogoWallCopyProps } from \"./logo-wall-parts\"\n\ninterface LogoWallMarqueeProps extends LogoWallCopyProps {\n  /** Seconds for one full pass. A longer list needs more, to keep the same speed. */\n  duration?: number\n}\n\nfunction LogoWallMarquee({ logos, title = DEFAULT_TITLE, titleQuiet, monochrome = true, duration, className, ...props }: LogoWallMarqueeProps) {\n  const reduceMotion = useReducedMotion() ?? false\n  const [paused, setPaused] = useState(false)\n  if (logos.length === 0) return null\n  return (\n    <section data-slot=\"logo-wall\" data-variant=\"marquee\" className={cn(ROOT_CLASS, \"bg-background\", className)} {...props}>\n      <div className=\"mx-auto flex w-full max-w-6xl min-w-0 flex-col gap-4 px-4 py-12 @2xl:px-8\">\n        <div className=\"flex min-h-10 items-center justify-between gap-4\">\n          <LogoWallLine title={title} quiet={titleQuiet} className=\"min-w-0\" />\n          {/* Anything that moves for more than five seconds needs a way to stop it, and hover does not exist on touch. */}\n          {reduceMotion ? null : (\n            <IconButton variant=\"ghost\" size=\"sm\" label={paused ? \"Play logos\" : \"Pause logos\"} onClick={() => setPaused((current) => !current)} className=\"ml-auto pointer-coarse:size-10\">\n              {paused ? <Play /> : <Pause />}\n            </IconButton>\n          )}\n        </div>\n        <Marquee variant=\"fade\" role=\"group\" aria-label={title ?? \"Logos\"} duration={duration} paused={paused}>\n          {logos.map((logo) => (\n            <MarqueeItem key={logo.name}>\n              <LogoMark logo={logo} monochrome={monochrome} />\n            </MarqueeItem>\n          ))}\n        </Marquee>\n      </div>\n    </section>\n  )\n}\n\nexport { LogoWallMarquee, type LogoWallMarqueeProps }\n",
      "type": "registry:component"
    }
  ],
  "categories": [
    "blocks"
  ],
  "type": "registry:block"
}