Skip to content

Latest commit

Β 

History

41 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

VibeKit

VibeKit

About VibeKit

VibeKit is a theme-design toolkit that lets you craft and share UI tokens β€” colors, typography, and spacing β€” with a live preview, accessibility validation, and four export formats: CSS variables, Tailwind config, W3C Design Tokens JSON, and SCSS variables. Themes get a public shareable preview page and a direct CSS endpoint you can <link> into any frontend.

Built around a five-color brand identity, a custom design language, and a clean editor with a top tab strip + 65/35 workspace split.

Project Origins

VibeKit emerged from the Girls Develop It: Fearless UX: Unleash Your Creative Potential workshop, where I applied the "vibe-coding" methodology I had learned from Piyush Acharya at Git Merge 2025.

Built in collaboration with Krystina Bradley, who contributed invaluable user-empathy research, journey mapping, and prototyping expertise. The technical implementation was developed with AI pair-programming, showcasing modern AI-assisted development workflows.

Visual Identity

VibeKit has its own designed brand system β€” five vibrant colors (sun, flame, hot pink, violet, azure), a custom wave-mark logo, Plus Jakarta Sans for UI and JetBrains Mono for code. See docs/brand-system.md for the full reference: color jobs, logo rules, typography hierarchy, voice, and design decisions.

Features

🎨 Colors

  • 10 semantic tokens organized as Neutrals (Light Β· Mid Β· Dark), Brand (Primary Β· Secondary Β· Tertiary), and Status (Success Β· Warning Β· Caution Β· Danger)
  • HEX-only for consistency
  • Automatic naming of every color via The Color API
  • Palette generator β€” pick a base color, choose a scheme (Monochromatic, Analogous, Complementary, Triadic), and optionally derive Neutrals and Status colors from it. Derived neutrals pull toward white and near-black with a subtle brand tint, so they're usable out of the box.

πŸ”€ Typography

  • Two-font system β€” pick a Header font and a Paragraph font independently from Google Fonts
  • Per-font controls for weight, italic, line-height, and letter-spacing
  • Modular type scale β€” set a base size (12-18px) and a scale ratio (Minor 2nd through Perfect 5th) to mathematically derive h1-h6
  • Live preview in the FontPicker, plus full application across the live preview canvas

πŸ”„ Spacing

  • Border radius slider (0-25px) with one-click impact across every rounded element in your theme

πŸ–ΌοΈ Brand

  • Logo upload (PNG, JPG, SVG, WebP) β€” stored in Cloudflare R2 with a public URL
  • Theme description (max 200 chars) β€” surfaces on the saved themes list and the public preview page

β™Ώ Contrast Checker (WCAG)

  • 12 meaningful color pairings validated against WCAG AA / AAA standards
  • At-a-glance pass/fail with the exact contrast ratio in JetBrains Mono
  • Responsive grid β€” 2-col on narrow screens, up to 4-col on wide

πŸš€ Live Preview

  • Web app mockup β€” full browser-framed dashboard with top nav, sidebar, metric cards, and a status table using your theme tokens
  • Mobile app mockup β€” phone-framed finance home screen with a themed balance card, secondary/tertiary stat tiles, recent activity, and a primary-colored bottom nav indicator
  • View toggle β€” Both / Web / Mobile, responsive (stacks vertically below 1180px viewport)
  • Updates as you edit β€” every color, font, weight, line-height, letter-spacing, and border-radius change is reflected instantly

πŸ“¦ Multi-format Exports

In-app Export panel and on the public preview page, with one-click copy:

  • CSS variables β€” :root { --color-primary: ...; } for any project
  • Tailwind config β€” theme.extend snippet ready to paste into tailwind.config.js
  • W3C Design Tokens JSON β€” the emerging standard, consumable by Style Dictionary, Figma Tokens, etc.
  • SCSS variables β€” $color-primary: ...; for Sass projects

Plus a direct CSS URL at /themes/{id}/css that you can <link> straight into a page.

πŸ’Ύ Saved Themes

  • Full CRUD β€” save, load, duplicate, delete, with relative timestamps ("2 days ago")
  • Type-to-confirm delete pattern (GitHub-style) β€” no passwords, no secrets, hard to mis-click
  • Public preview page at /themes/{id}/preview with hero, mockups, color tokens, type scale, components, and all four export formats with copy buttons

πŸ“š In-app Docs

A /docs page covering the editor, the five tabs, the canvas, saving, exporting, and how to consume the tokens in your own project.

πŸ› οΈ Tech Stack

🌐 Frontend

  • ⚑ Vite β€” dev server and build tool
  • βš›οΈ React 18 + TypeScript
  • 🎨 Custom design system (.vk-* classes) β€” Plus Jakarta Sans, JetBrains Mono, cream-and-ink color language
  • 🐜 Ant Design β€” used selectively for the color picker and a few form controls; most UI is custom
  • πŸ›€οΈ React Router β€” / (editor) + /docs

☁️ Backend

  • πŸ”§ Cloudflare Workers β€” single-file Worker handling all routes
  • πŸ’Ύ D1 β€” SQLite at the edge for themes + uploads metadata
  • πŸ“¦ R2 β€” logo file storage
  • πŸ”¨ Wrangler 4 β€” Cloudflare dev toolkit

🌐 External APIs

Architecture

flowchart TB
  subgraph Frontend["Frontend (Vite + React + TS)"]
    direction TB
    F1[Topbar Β· theme name + Save]
    F2[Tab strip Β· Colors Β· Type Β· Spacing Β· Brand Β· Themes]
    F3[Live Preview Β· Web + Mobile mockups]
    F4[Contrast Checker Β· 12 WCAG pairs]
    F5[Export Panel Β· CSS Β· Tailwind Β· Tokens Β· SCSS]
    F6[Right rail Β· contextual controls]
  end

  subgraph Lib["Shared modules"]
    L1[lib/api.ts Β· single API client]
    L2[lib/color.ts Β· color math]
    L3[lib/theme.ts Β· exports + defaults]
    L4[hooks/useDynamicFonts]
    L5[hooks/useItalicStyle]
  end

  subgraph Worker["Cloudflare Worker"]
    W1[GET /themes]
    W2[POST /themes Β· save]
    W3[GET /themes/:id]
    W4[DELETE /themes/:id]
    W5[GET /themes/:id/css]
    W6[GET /themes/:id/preview Β· multi-format export page]
    W7[POST /uploads/logo]
    W8[GET /uploads/:id]
  end

  subgraph Storage["Cloudflare Storage"]
    S1[(D1 Β· themes table<br/>incl. description)]
    S2[(D1 Β· uploads table)]
    S3[R2 Β· vibekit-logos]
  end

  Frontend --> L1
  L1 -->|fetch| Worker
  W1 --> S1
  W2 --> S1
  W3 --> S1
  W4 --> S1
  W5 --> S1
  W6 --> S1
  W7 --> S2
  W7 -.->|file blob| S3
  W8 --> S2
Loading

Getting Started

# Frontend
cd frontend
npm install
npm run dev          # http://localhost:5173

# Worker (in another terminal)
cd api
npm install
npm run d1:migrate   # apply database migrations locally
npm run dev          # http://127.0.0.1:8787

# Deploy
npm run deploy                  # publish Worker to Cloudflare
npm run d1:migrate:remote       # apply migrations to production D1

Optional env vars in frontend/.env.local:

VITE_GF_API_KEY=...     # unlocks the full Google Fonts catalog (otherwise a curated list)
VITE_API_BASE=...       # override the API base URL

Future Opportunities

  • πŸŒ— Dark mode β€” second color set per theme, mode toggle in the editor, [data-theme="dark"] block in exports
  • 🎨 Color blindness simulation β€” Deuteranopia / Protanopia / Tritanopia preview alongside the contrast checker
  • πŸ“₯ Import from Coolors / hex list / Design Tokens JSON β€” reverse direction of the exports
  • 🎁 Starter templates β€” fork from curated themes (Editorial, SaaS, Playful, Bold, Mono)
  • ✏️ Custom font uploads β€” alternative to Google Fonts only
  • πŸ’¬ Per-theme comments for collaborative review
  • 🎨 Figma plugin for round-tripping tokens

Design Documentation

🎨 Figma Design Files

πŸ“‹ UX Research

🌈 Inspiration

License

This project is licensed under a View-Only License β€” see the LICENSE file for details.

About

Create, preview, and share brand typography & color tokens with a friendly contrast checker. Vite/React + Cloudflare Worker/D1.

Topics

Resources

Stars

2 stars

Watchers

0 watching

Forks

Contributors

Languages