npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

themestudio

v0.0.7

Published

Zero-config visual theme studio for shadcn/ui + Next.js

Readme

ThemeStudio 🎨 Zero-config visual theme studio for React & Next.js with shadcn/ui support. Transform your app's look in real-time — no config files, no rebuilds, no hassle. https://www.npmjs.com/package/themestudio https://opensource.org/licenses/MIT ✨ Features 🌗 Theme Toggle — Switch between Light, Dark, and System modes instantly 🎨 Live Color Picker — Change your primary brand color with a visual picker ⚡ Color Scale Generator — Generate full shadcn-compatible color scales from a single hex color 💾 Export / Import — Save, share, and load themes as JSON 🔌 shadcn/ui Native — Auto-detects and overrides shadcn CSS variables at runtime 🚀 Zero Config — Install, add one component, done 📦 Framework Agnostic — Works with React 18+, Next.js App Router & Pages Router 📦 Installation bash npm install themestudio

or

yarn add themestudio

or

pnpm add themestudio Peer Dependencies bash npm install react react-dom 🚀 Quick Start Next.js (App Router) Add to your root layout: tsx // app/layout.tsx import { ThemeStudio } from 'themestudio';

export default function RootLayout({ children }: { children: React.ReactNode }) { return ( {/* ← Floating widget appears */} {children} ); } React (Vite, CRA, etc.) tsx // App.tsx import { ThemeStudio } from 'themestudio';

function App() { return ( <> </> ); } That's it. No configuration required. 🎉 🖼️ What You Get A floating palette button appears at the bottom-right of your app. Click it to open: Table Tab What It Does Theme Toggle Light / Dark / System mode Colors Live hex color picker for your primary brand color Generate Pick one color → auto-generate a full 11-step shadcn scale Export Copy theme JSON to clipboard or import a shared theme 🔌 shadcn/ui Integration ThemeStudio automatically detects shadcn/ui and overrides these CSS variables at runtime: css --primary --primary-foreground --ring --radius --background --foreground /* ... and more */ Your shadcn components will instantly reflect color and theme changes — no rebuild needed. 📤 Export & Import Themes Export Click "Copy Theme JSON" in the Export tab to get: JSON { "name": "Ocean Blue", "mode": "light", "colors": { "primary": "#0066cc", "radius": "0.5rem" }, "generatedScale": { "50": "#f0f9ff", "100": "#e0f2fe", "500": "#0ea5e9", "900": "#0c4a6e" } } Import Paste any theme JSON into the Import textarea and click "Import Theme". 🧪 Programmatic API Want to build your own UI? Use our hooks and utilities directly: tsx import { useTheme, useColorScale, generateScaleFromColor } from 'themestudio';

function MyCustomPanel() { const { config, setMode, setPrimaryColor } = useTheme(); const scale = useColorScale('#ff5722');

return ( Current mode: {config.mode} Primary: {config.colors.primary} <button onClick={() => setMode('dark')}>Go Dark <button onClick={() => setPrimaryColor('#ff5722')}>Set Orange ); } Available Exports Table Export Type Description ThemeStudio Component The floating widget (default export) useTheme Hook Theme state, mode, and color controls useColorScale Hook Generate 11-step color scales from a hex color generateScaleFromColor Function OKLCH-based color scale generator getForegroundColor Function Auto-pick accessible foreground for a background injectCSSVars Function Inject CSS custom properties at runtime detectShadcn Function Detect if shadcn/ui is present saveTheme / loadTheme Function localStorage persistence exportTheme / importTheme Function JSON serialization 🎨 How Color Generation Works We use OKLCH color space (via culori) to generate perceptually uniform color scales: You pick a base color (e.g., #0066cc) We convert it to OKLCH We interpolate lightness and chroma across 11 steps (50 → 950) We map those steps to shadcn-compatible CSS variables Result: A professional color system that looks great in both light and dark modes. ⚙️ Next.js Config (Optional) If you see module resolution issues with local/symlinked packages, add this to next.config.ts: TypeScript import type { NextConfig } from 'next';

const nextConfig: NextConfig = { transpilePackages: ['themestudio'], };

export default nextConfig; 🧩 Requirements React ^18.0.0 || ^19.0.0 React DOM ^18.0.0 || ^19.0.0 TypeScript (optional but recommended) 📁 File Structure plain themeStudio/ ├── dist/ │ ├── index.js # CJS build │ ├── index.mjs # ESM build │ └── index.d.ts # TypeScript declarations ├── src/ │ ├── components/ # React components (Widget, Tabs, etc.) │ ├── hooks/ # useTheme, useColorScale │ ├── utils/ # Color math, CSS vars, storage │ └── types/ # TypeScript interfaces ├── package.json └── README.md 🤝 Contributing Contributions are welcome! Please open an issue or pull request on GitHub. 📄 License MIT © ThemeStudio 💬 Questions? Does it work with Tailwind CSS v4? — Yes, it overrides CSS variables that Tailwind reads. Does it work with Pages Router? — Yes, import in your _app.tsx. Can I hide the widget in production? — Yes, conditionally render it: {process.env.NODE_ENV === 'development' && } Does it support custom color variables? — The full shadcn variable map is coming in v1.1. Currently supports primary, ring, radius, and theme mode.