Skills recharts
install
source · Clone the upstream repo
git clone https://github.com/amanahmed2222/skills
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/amanahmed2222/skills "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/recharts" ~/.claude/skills/amanahmed2222-skills-recharts && rm -rf "$T"
manifest:
skills/recharts/SKILL.mdsource content
You build Recharts charts integrated with HeroUI v3 design tokens and Tailwind CSS v4. Infer the project's language variant (US/UK English) from existing commits, docs, and code, and match it in all output.
Read individual rule files in
rules/ for detailed patterns and code examples.
Rules Overview
| Rule | Impact | File |
|---|---|---|
| Container pattern | HIGH | |
| Theme integration | HIGH | |
| Custom components | HIGH | |
Workflow
Building a chart?
- Detect setup — Confirm
is inrecharts
. Check if HeroUI v3 is installed (package.json
or individual packages). Detect Tailwind CSS v4 (@heroui/react
).@tailwindcss/* - Read rules — Read all files in
to load the container pattern, theme token mapping, and custom component templates.rules/ - Fetch theme tokens — Check the current HeroUI theme variables to confirm token names available in the project.
- Generate component — Build the chart component applying all three rules: outer container wrapper, CSS variable colours, and custom tooltip/legend.
- Verify — Check the generated code against each rule. Confirm no hardcoded hex colours,
is wrapped correctly, and tooltip uses HeroUI classes.ResponsiveContainer
Reviewing existing charts?
- Scan — Glob for files importing from
. Read each file and check against every rule inrecharts
.rules/ - Report — List violations grouped by rule with file paths and line numbers.
- Fix — Apply corrections one violation at a time.
Quick Reminders
- Always add
as the first child inside every chart for screen reader support<AccessibilityLayer /> - Set
on chart elements when inside components that re-render frequently (tables, filters)isAnimationActive={false} - Recharts uses SVG — style with
andstroke
props, not CSSfillcolor - Export chart prop interfaces separately so consumers can extend them
- Use
withcartesianGrid
and theme-aware stroke colourstrokeDasharray="3 3" - Never set a fixed
onwidth
— it must always beResponsiveContainerwidth="100%"
Assumptions
- React + TypeScript project
- Recharts installed (
in dependencies)recharts - HeroUI v3 installed with Tailwind CSS v4
- CSS variables from HeroUI theme are available globally