agentleFS
IntelliHelperIntelliHelper/agent-skills/skills/add-component/SKILL.md

add-component

Skill1 starsChanged 2 months agoMITView on GitHub

Install IntelliHelper UI components into a project correctly: init components.json, resolve dependencies, run CLI add (web slugs or @native/<name> for Expo), verify imports, and audit. Use when the user wants to add, install, scaffold, update, or diff IntelliHelper/shadcn-style or React Native components, fix missing components.json, or wire the registry. Triggers: "add button", "add @native/button", "install dialog", "npx @intellihelper/cli", "init components.json", "update components", "registry add", "expo components".

7 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

8 rules. 0 are common, 2 are distinctive, and 6 are very specific to this project.

  • 0

    Common

    Most of the 7 edited versions we read keep these.

  • 2

    Distinctive

    This author's own choices. Worth a look.

  • 6

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Always prefer -y / non-interactive flags in agent shells so prompts do not hang.

    line 40
  2. Distinctive:

    Default config highlights (web):

    line 42
  3. Very specific:

    Ensure tsconfig path aliases match components.json.

    line 52
  4. Very specific:

    Use registry slugs — web: button, dialog, glass-bar.

    line 69
  5. Very specific:

    If the project is Expo/RN, do not pass unprefixed names unless init --native was used.

    line 71
  6. Very specific:

    Never blindly overwrite user-customized files without checking diff / modified state.

    line 119
  7. Distinctive:

    After install, import from local paths:

    line 138
  8. Very specific:

    Do not import from @intelli/ui or @intelli/ui-native in consumer apps — those are monorepo-internal.

    line 145

“Common” is measured: kept by at least 6 in 10 of the 7 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Add IntelliHelper components

Goal: leave the project with installed, compiling, correctly imported components — not just a pasted snippet.

Decision tree

components.json missing?
  YES → init first (non-interactive)
  NO  → read config (MCP get_project_config)

Know exact component names?
  YES → get_component → get_add_command → CLI add
  NO  → search_components / list_components → then install

1. Project config

MCP: get_project_config

CLI:

npx @intellihelper/cli@latest init -y

Always prefer -y / non-interactive flags in agent shells so prompts do not hang.

Default config highlights (web):

  • Style: intelli-glass
  • Registry: https://ui.intellihelper.in/r
  • UI alias: @/components/ui
  • Utils alias: @/lib/utils
  • CSS: app/globals.css (adjust if project uses src/app)

Expo / React Native: still init -y is fine. Native files always land in components/ui/native/ when you add @native/<name>. Use init --native -y only for Expo-only repos where unprefixed names should mean native.

Ensure tsconfig path aliases match components.json.

2. Discover names

MCP:

search_components { "query": "dialog" }
list_components { "category": "forms" }

CLI:

npx @intellihelper/cli@latest list

Use registry slugs — web: button, dialog, glass-bar. Native: @native/button, @native/dialog. Not React display names alone.

If the project is Expo/RN, do not pass unprefixed names unless init --native was used.

3. Read API before coding

MCP:

get_component { "name": "button" }
get_component { "name": "@native/button" }
get_component { "names": ["dialog", "button"] }
get_component_examples { "name": "dialog" }   # web only

Extract: exports, variants, sizes, shapes, npm + registry deps. Web: "use client". Native: onPress / style / ThemeProvider.

4. Install (source of truth)

MCP: get_add_command with { "components": ["button", "dialog"] } or { "components": ["@native/button"] }
Then run the returned command in the project shell.

CLI direct:

npx @intellihelper/cli@latest add button dialog card -y
npx @intellihelper/cli@latest add @native/button @native/card -y
npx @intellihelper/cli@latest add button @native/card -y   # mixed, no overwrite

Useful flags:

FlagPurpose
-y, --yesSkip confirmations (agent default)
-o, --overwriteOverwrite local files
--dry-runPreview only

The CLI resolves registry dependencies (e.g. utils) and installs npm dependencies.

5. Update / diff

npx @intellihelper/cli@latest update -y
npx @intellihelper/cli@latest update button --skip-modified
npx @intellihelper/cli@latest diff button
npx @intellihelper/cli@latest diff @native/button
npx @intellihelper/cli@latest list --installed

Never blindly overwrite user-customized files without checking diff / modified state.

6. Audit

MCP: get_audit_checklist

Verify at minimum:

  • components.json present; aliases match tsconfig
  • Imports use UI alias (@/components/ui/... or @/components/ui/native/...)
  • Named/default imports match exports
  • Registry + npm deps installed (native pulls native-theme, native-utils, siblings)
  • Web: theme/token CSS loaded. Native: root wrapped in ThemeProvider
  • Chrome vs content variants chosen deliberately
  • Web client components marked "use client" when needed
  • No TS/lint (or Metro) errors

7. Compose

After install, import from local paths:

import { Button } from "@/components/ui/button"
import { Button } from "@/components/ui/native/button"

Do not import from @intelli/ui or @intelli/ui-native in consumer apps — those are monorepo-internal.

For layout recipes, use skill compose-ui. For glass rules, use skill liquid-glass.

Failure modes & fixes

SymptomFix
Interactive CLI hangingRe-run with -y
Module not found @/lib/utilsadd utils / re-init aliases
Wrong import pathRead components.json aliases
Missing glass stylesCheck global CSS / theme setup in docs
Props TypeScript errorsRe-run get_component; stop inventing props
MCP tools missingPlugin trust/MCP enable, or CLI fallback
Web button in Expo / Metro className errorsRe-install with @native/button; import @/components/ui/native/button

Docs

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.