Add the official Logo.dev shadcn/ui component registry - #4
Merged
Conversation
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
Six installable items (logo, logo-avatar, brand-search, logo-wall, attribution, logo-lib) with sources in registry/new-york/, built JSON committed in r/, and CI enforcing typecheck/lint/test plus build-output sync. components/ui/ holds vendored shadcn primitives for typechecking only. MIT license added (repo previously had none). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Some shadcn Avatar variants (e.g. radix-nova) define their own string size variant, which intersected with our numeric size prop to never. Caught installing into a radix-nova consumer app. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
alexbaldwin
force-pushed
the
feat/shadcn-registry
branch
from
July 6, 2026 15:18
32c8f67 to
5d22570
Compare
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
Codex review (P2): brand-search.tsx imported ChevronsUpDownIcon from lucide-react, but the registry item never installed that package. A consumer whose project lacks lucide-react (e.g. initialized with a different icon library, or none) would get code that fails to compile. shadcn's own primitives import lucide directly because `shadcn init` always installs it, and its registry transform only rewrites an explicit <IconPlaceholder> element per the consumer's configured iconLibrary. Since this block uses exactly one decorative icon, inline it as a self-contained SVG instead: zero dependencies, works on any icon setup, nothing to declare in registry.json. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
- P1 (logo-dev.ts): reading process.env for the token broke TypeScript in
browser-only consumers without @types/node ("Cannot find name 'process'").
Add a minimal ambient `declare const process` so the file typechecks with
or without @types/node. Verified the literal process.env.NEXT_PUBLIC_*
access still gets inlined into Next.js client bundles.
- use-brand-search.ts: fix a stale-results race — the in-flight request is now
aborted in effect cleanup (not only when the next debounce fires) and state
updates are guarded on the controller, so an older query's response can't
overwrite the current results. Also fix endpoint query-string joining so a
custom endpoint with existing params (?tenant=acme) stays valid.
- logo.tsx: respect a decorative alt="" on the initials fallback tile
(aria-hidden instead of an announced role=img), and reset the errored flag
on the full request identity (fallback/format/theme/greyscale/size), so
changing any URL option retries the image instead of sticking on a fallback.
- logo-dev.ts: use index access instead of Array.at() in logoInitials for
broader TS lib-target portability.
Verified: typecheck, lint, 16 unit tests, registry build, a fresh Next.js
consumer install (logos render, dead-domain initials fallback, debounced
search), non-Node typecheck, and Next client-bundle token inlining.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
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.
What this is
This turns the public logo-api repo into the home of Logo.dev's open source components, starting with a shadcn/ui registry — the same model as firecrawl/firecrawl hosting everything open source in one repo.
Six installable items, all zero-npm-dependency (shadcn primitives resolve from ui.shadcn.com):
logodark:variant pair), monogram/initials/custom fallback chainlogo-avatarbrand-searchlogo-wallattributionrel="noopener"only — referrer stays intact)logo-libHow it's distributed
npx shadcn@latest add logo-dev/logo-api/logo(GitHub form, works on merge, pinnable to tag/SHA)npx shadcn@latest add https://www.logo.dev/r/logo.json(branded URL; marketing-site PR adds a/r/*rewrite to this repo's committedr/output — follow-up)@logodev/logoonce we're listed in shadcn's registry directory (follow-up PR to shadcn-ui/ui)Built JSON is committed in
r/and CI fails if it drifts from the sources (git diff --exit-code r/).components/ui/holds vendored primitives for typechecking only.Verification
fallback=404mapping, srcset shape, token precedence); typecheck + Biome (ultracite) clean@logodevnamespace; dep chain pulled button/command/popover/avatar + cross-item deps; imports rewritten to consumer aliases; env keys written to.env.local;tsc --noEmit+next buildcleanfallback=404→ onError), dark-mode class toggle swaps to dark logo variants, brand search fires exactly 1 request for 4 keystrokes (200ms debounce + abort) with logos per result, logo wall renders attribution with referrer intacthttps://www.logo.dev/r/*.json, so installs of dependent items resolve fully once the marketing rewrite deploys; the GitHub install form works for everything immediately after that.🤖 Generated with Claude Code