Skip to content
Get Kosh Pro

Field notes / 01

A small beginning.

Start with one changing value. Give it a little continuity. Build from there.

Four components install free, under the MIT license.

Flow Number, Delta Chip, Live Spark and Fill Ring install from this site’s registry, with the motion core they need. Their source and license are in a public repository. Streak Heatmap, Morph Bars, Activity Feed and Story Card are Kosh Pro: they install the same way, with a license key, and the MIT license does not cover them.

01

Bring it into your app.

Kosh installs with the shadcn CLI, as source files you own. These commands make a fresh Next.js app with the default @/* alias. In an existing app, run only the last line.

PowerShell / new app
Set-Location $env:TEMP
npx create-next-app@latest kosh-consumer --ts --tailwind --app --src-dir --use-pnpm --import-alias "@/*" --yes
Set-Location kosh-consumer
npx shadcn@latest init -d

Merge this registry entry into the app’s components.json. Dependencies use the @kosh namespace even when you install the first item by URL.

components.json / merge
{ "registries": { "@kosh": "https://kosh-hazel.vercel.app/r/{name}.json" } }
PowerShell / your app
npx shadcn@latest add https://kosh-hazel.vercel.app/r/motion-core.json
npx shadcn@latest add https://kosh-hazel.vercel.app/r/flow-number.json
npx shadcn@latest add https://kosh-hazel.vercel.app/r/fill-ring.json

Delta Chip and Live Spark install the same way: replace the last name with delta-chip or live-spark. Fill Ring and Delta Chip bring Flow Number with them.

Tested with shadcn 4.23.0 against this site: the install places these files under src/kosh and a fresh app typechecks. A production build of that app is still to be verified.

Read or build the source

The free items live in a public repository, file for file as the registry ships them. Clone it to read the code or to host the registry yourself: pnpm registry:build writes the same JSON files this site serves to public/r.

PowerShell / new folder
git clone https://github.com/richabh-exe/kosh-ui.git
Set-Location kosh-ui
pnpm install
pnpm typecheck
pnpm registry:build

No API keys, accounts, or external data services are needed.

02

Find your way around.

Your app and the public repository share one layout under src/kosh. Start with the component source when you want to understand or change its behavior.

src/kosh/<name>/One folder per component: its source and its styles.
src/kosh/motion/Provider, preferences, tokens, and shared motion utilities.
registry.jsonIn the repository: the registry manifest. It lists only the free items, each served at /r/<name>.json.
03

Set the foundation once.

Kosh’s root layout already includes the provider, and its global stylesheet already imports these files. This is the setup to preserve when adapting the app.

Global CSS
/* src/app/globals.css */
@import "tailwindcss";
@import "../kosh/motion/tokens.css";
@import "../kosh/motion/motion.css";
@import "../kosh/motion/motion-switch.css";
Root layout / simplified
import "./globals.css";
import type { ReactNode } from "react";
import { KoshProvider, MotionScript } from "@/kosh/motion";

export default function RootLayout({ children }: { children: ReactNode }) {
  return (
    <html lang="en" suppressHydrationWarning>
      <head><MotionScript /></head>
      <body>
        <KoshProvider motion="auto">
          {children}
        </KoshProvider>
      </body>
    </html>
  );
}

MotionScript applies the stored preference before the first paint. KoshProvider resolves app, visitor, and system preferences. The component’s own stylesheet is imported by its source file.

The layout snippet shows the wiring; keep your framework’s existing types, metadata, and font configuration. The @/ alias in this repository points to src/.

04

Let the data do the talking.

Pass the current value through data. Update that value with React state. The component handles the transition from the previous value.

React / TypeScript
"use client";

import { useState } from "react";
import { FlowNumber } from "@/kosh/flow-number/flow-number";

export default function SessionCount() {
  const [sessions, setSessions] = useState(128);
  return (
    <div>
      <FlowNumber data={sessions} />
      <button type="button" onClick={() => setSessions(n => n + 1)}>
        Log a session
      </button>
    </div>
  );
}
Keep exploringUnderstand the motion.