Skip to content

feat(kumo): add CloudflareLogo and PoweredByCloudflare components#30

Open
mattrothenberg wants to merge 6 commits intocloudflare:mainfrom
mattrothenberg:feat/cloudflare-logo
Open

feat(kumo): add CloudflareLogo and PoweredByCloudflare components#30
mattrothenberg wants to merge 6 commits intocloudflare:mainfrom
mattrothenberg:feat/cloudflare-logo

Conversation

@mattrothenberg
Copy link
Contributor

@mattrothenberg mattrothenberg commented Feb 7, 2026

⚠️ SPECULATIVE PR

This is a speculative PR to gather feedback on the API design and implementation approach.


Summary

  • Add CloudflareLogo component with glyph and full logo variants
  • Add PoweredByCloudflare badge component for footer attribution
  • Export SVG path data and brand colors for custom implementations
Screenshot 2026-02-07 at 8 03 30 AM Screenshot 2026-02-07 at 8 03 34 AM Screenshot 2026-02-07 at 8 03 38 AM Screenshot 2026-02-07 at 8 04 27 AM Screenshot 2026-02-07 at 8 03 44 AM

Components

CloudflareLogo

<CloudflareLogo className="w-36" />
<CloudflareLogo variant="glyph" className="w-12" />
<CloudflareLogo color="white" /> {/* for dark backgrounds */}
<CloudflareLogo color="black" /> {/* monochrome */}

Props:

  • variant: "full" (default) | "glyph" - Full logo with wordmark or cloud icon only
  • color: "color" (default) | "black" | "white" - Color scheme

PoweredByCloudflare

<PoweredByCloudflare />
<PoweredByCloudflare color="white" /> {/* for dark backgrounds */}

A badge-style link component for "Powered by Cloudflare" attribution.

Exported Constants

For custom implementations, the component exports:

  • Brand colors: CLOUDFLARE_ORANGE, CLOUDFLARE_YELLOW, CLOUDFLARE_TEXT_GRAY
  • SVG paths: CLOUDFLARE_GLYPH_ORANGE_PATH, CLOUDFLARE_GLYPH_YELLOW_PATH, etc.
  • ViewBoxes: CLOUDFLARE_GLYPH_VIEWBOX, CLOUDFLARE_FULL_LOGO_VIEWBOX

Dark Mode

The wordmark text color respects dark mode via text-kumo-default. The cloud glyph maintains brand colors when color="color".

- Add CloudflareLogo component with glyph and full logo variants
- Support color schemes: brand colors, black, white
- Export SVG path data and brand colors for custom implementations
- Add documentation page with demos including brand assets dropdown menu
@threepointone
Copy link

- PoweredByCloudflare: less rounded (rounded-lg), tighter padding,
  asymmetric pl/pr for optical centering
- PoweredByCloudflare white variant: dark badge background so white
  logo/text is readable
- Color variant demos: remove redundant color name labels
- Docs code example: add missing black variant

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@stritt
Copy link
Collaborator

stritt commented Feb 8, 2026

hey matt made some styling tweaks here, should be good to go now!

The black variant needs a white background so the black logo remains
visible in dark mode (mirrors the approach used for the white variant).
- Add generateCloudflareLogoSvg() for generating SVG markup strings
- Make internal constants private (no longer exported)
- Fix lint: replace neutral-* tokens with bg-black/bg-white + ring opacity variants
- Update docs to show new SVG generation API
@mattrothenberg
Copy link
Contributor Author

mattrothenberg commented Feb 8, 2026

@stritt Awesome! Made some changes to your PoweredByCloudflare styling to fix a lint failure. Feel free to roll back if I've misunderstood.

The issue was that neutral-* tokens are blocked by our no-primitive-colors lint rule.

I tweaked:

  • bg-neutral-900bg-black
  • ring-neutral-700ring-white/20
  • ring-neutral-300ring-black/20

As such the black and white variants are intentionally NOT theme-responsive. If someone picks color="white", they get a white logo on a dark background regardless of whether the app is in light or dark mode. Same for color="black" - always black logo on light background. This makes sense because the logo color is fixed, so the background needs to be fixed too.

The color="color" variant (default) still uses semantic tokens and responds to theme normally.

Let me know if you had a different vision for this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants