Shade new component

A checklist for adding or editing Shade components and patterns in Storybook. It covers file names, exports, imports, component variants, required states, and companion stories.

In plain words
What is it for?
Use it when working in `apps/shade/src/components` or adding a Shade primitive, component, recipe, pattern, or token gallery.
Why use it?
It catches missing files, inconsistent naming, undocumented states, and components that do not follow the existing Shade structure.

Skill for Claude CodeCodex

▶ Let an AI Agent Loose on Postgres, Safely: Claude Code + Ghost Julien Simon · about TryGhost/Ghost · on YouTube →
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/tryghost/ghost/shade-new-component
Any agent
npx skills add TryGhost/Ghost --skill shade-new-component
Clone the repo
git clone --depth 1 https://github.com/TryGhost/Ghost

Made for: Claude Code, Codex.

Per session 47 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,146 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00047 $0.01146
Opus 5 $0.00023 $0.00573
Sonnet 5 $0.00009 $0.00229
Haiku 4.5 $0.00005 $0.00115

Measured 2d ago against content hash da66a256389d, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

Shade new component scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.agents/skills/shade-new-component/SKILL.md · 118 lines

How it starts

The opening of the file, as written. The whole thing — 118 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Shade — new component / pattern checklist

Before marking a Shade component or pattern done, this checklist must pass.

Files and naming

  • File: kebab-case (dropdown-menu.tsx) — matches ShadCN CLI output. Don't rename for casing.
  • Exported identifier: PascalCase (DropdownMenu).
  • Hooks, functions, variables: camelCase.
  • Sibling <name>.stories.tsx is required (same folder).
  • Inside Shade itself, import via the @/ alias (@/lib/utils, @/components/ui/input-surface).

Storybook title prefix

Layer Title
Primitive Primitives / <Name>
Component Components / <Name>
Recipe Recipes / <Name>
Pattern Patterns / <Name>
Token gallery Tokens / <Topic>

Required on every story file:

  • tags: ['autodocs']
  • parameters.docs.description.component — short one-line summary
  • Per-story parameters.docs.description.story — one-liner explaining when to use that variant
  • One story per important variant/state. Many small focused stories > one prose-heavy story.

Component shape

import * as React from 'react';
import {cva, type VariantProps} from 'class-variance-authority';
import {cn} from '@/lib/utils';

const thingVariants = cva('base-classes-here', {
    variants: {
        variant: {default: '...', destructive: '...'},
        size: {default: '...', sm: '...'}
    },
    defaultVariants: {variant: 'default', size: 'default'}
});

export interface ThingProps
    extends React.HTMLAttributes<HTMLDivElement>,
    VariantProps<typeof thingVariants> {}

const Thing = React.forwardRef<HTMLDivElement, ThingProps>(
    ({className, variant, size, ...props}, ref) => (
        <div
            ref={ref}
            className={cn(thingVariants({variant, size, className}))}
            {...props}
        />
    )
);
Thing.displayName = 'Thing';

export {Thing, thingVariants};

Hard requirements:

  • className forwarded and merged via cn() — never overwritten, never dropped. Applies to every component that renders DOM.
  • Visual/interactive props only (variant, size, loading). No workflow props (isMembersPage, layoutMode) — those mean you actually need a Pattern wrapper.
  • Multi-region components expose compound subcomponents (.Title, .Actions, .Body) — not a prop bag.

Read the full file on GitHub · 118 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 118 lines · 47 tokens per session scan A da66a256389d

Subscribe to this mod's changes

Shade new component is a skill published in the GitHub repository TryGhost/Ghost (55,095 stars, last pushed yesterday), licensed MIT. It adds 47 tokens to every session and 1,146 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.