New:Introducing Socket Scanning for VS Code Marketplace Extensions.Learn more →
Get Started

@kreativekorna/justui

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install
Package was removed
Sorry, it seems this package was removed from the registry

@kreativekorna/justui

Shared design system for the just* app family — theme tokens, six built-in themes (GitHub, Espresso, Catppuccin Mocha, Gruvbox, Nord, Solarized), a no-flash boot script, and per-framework component adapters (Astro today; React/Vue next).

latest
npmnpm
Version
0.1.0
Version published
Maintainers
1
Created
Source

@kreativekorna/justui

Shared design system for the just* app family — theme tokens, six built-in themes (GitHub, Espresso, Catppuccin Mocha, Gruvbox, Nord, Solarized), a no-flash boot script, ready-made Astro components, and a Tailwind preset.

See STYLE_GUIDE.md for the full design spec.

Install

pnpm add @kreativekorna/justui

Peers your app needs separately:

pnpm add @fontsource-variable/geist @fontsource-variable/geist-mono tailwindcss

Quick start (Astro + Tailwind)

1. Tailwind preset

// tailwind.config.mjs
import justuiPreset from '@kreativekorna/justui/tailwind-preset';

export default {
  presets: [justuiPreset],
  content: [
    './src/**/*.{astro,html,js,ts,jsx,tsx,md,mdx}',
    // Include the package's components so Tailwind generates classes
    // used inside Button.astro / ThemeToggle.astro.
    './node_modules/@kreativekorna/justui/src/**/*.{astro,js,ts}',
  ],
};

2. Token fallback + Tailwind directives

/* src/styles/global.css */
@import "@kreativekorna/justui/tokens.css";

@tailwind base;
@tailwind components;
@tailwind utilities;

3. Boot the theme before first paint

---
// src/layouts/Layout.astro
import '@fontsource-variable/geist';
import '@fontsource-variable/geist-mono';
import '../styles/global.css';
---
<!doctype html>
<html lang="en">
  <head>
    <!-- Runs before <body> renders so the right palette paints first. -->
    <script>
      import { bootTheme } from '@kreativekorna/justui/boot';
      bootTheme({ keyPrefix: 'myapp' });
    </script>
  </head>
  <body><slot /></body>
</html>

4. Drop in the picker

---
import ThemeToggle from '@kreativekorna/justui/components/ThemeToggle.astro';
---
<ThemeToggle />

The floating button at bottom-right opens a panel with a mode toggle (light/dark) + all six themes. State persists to myapp.theme.id / myapp.theme.mode.

What's in the package

ExportPurpose
@kreativekorna/justuiBUILT_IN_THEMES, DEFAULT_THEME_ID, VAR_MAP, bootTheme
@kreativekorna/justui/bootJust bootTheme — small import if you only want this
@kreativekorna/justui/themesJust the theme catalog
@kreativekorna/justui/tokens.css:root fallback (Espresso dark)
@kreativekorna/justui/tailwind-presetTailwind config preset
@kreativekorna/justui/components/Button.astroPrimary / secondary button
@kreativekorna/justui/components/ThemeToggle.astroFloating theme picker

Per-app prefix

Each just* app should call bootTheme({ keyPrefix: '<appname>' }) so theme state doesn't collide on shared origins. The ThemeToggle reads the prefix from the global window.__JUSTUI__ that bootTheme() stamps, so the same component works in every app without per-app config.

If you want themes to be shared across apps on the same origin (so picking Gruvbox in one carries to the other), use the default keyPrefix: 'justui' everywhere.

License

MIT

Keywords

design-system

FAQs

Package last updated on 16 Jun 2026

Related posts