@nqlib/nqui 0.5.6 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/index.d.ts +3 -0
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/theme-appearance-menu.d.ts +9 -0
- package/dist/components/theme-appearance-menu.d.ts.map +1 -0
- package/dist/components/theme-toggle.d.ts +2 -0
- package/dist/components/theme-toggle.d.ts.map +1 -0
- package/dist/components/ui/checkbox.d.ts.map +1 -1
- package/dist/components/ui/toggle-group.d.ts.map +1 -1
- package/dist/elevation-debate.html +286 -0
- package/dist/nqui.cjs.js +15 -13
- package/dist/nqui.es.js +2742 -2637
- package/dist/styles.css +151 -255
- package/docs/components/README.md +2 -1
- package/docs/components/nqui-scroll-area.md +69 -0
- package/docs/nqui-skills/AGENT_PROMPT.md +190 -0
- package/docs/nqui-skills/COMPONENTS_INDEX.md +51 -1
- package/docs/nqui-skills/COMPOSITION.md +321 -0
- package/docs/nqui-skills/ELEVATION.md +154 -0
- package/docs/nqui-skills/EVAL.md +148 -0
- package/docs/nqui-skills/HUMAN_GUIDE.md +18 -0
- package/docs/nqui-skills/MIGRATION.md +133 -0
- package/docs/nqui-skills/MOTION.md +189 -0
- package/docs/nqui-skills/README.md +2 -0
- package/docs/nqui-skills/READ_BUDGET.md +60 -0
- package/docs/nqui-skills/RECIPES.md +735 -0
- package/docs/nqui-skills/SKILL.md +58 -1
- package/docs/nqui-skills/STATES.md +154 -0
- package/docs/nqui-skills/THEMING.md +203 -0
- package/docs/nqui-skills/WRITING.md +205 -0
- package/docs/nqui-skills/adapt/SKILL.md +5 -2
- package/docs/nqui-skills/animate/SKILL.md +5 -2
- package/docs/nqui-skills/audit/SKILL.md +5 -2
- package/docs/nqui-skills/bolder/SKILL.md +5 -2
- package/docs/nqui-skills/clarify/SKILL.md +5 -2
- package/docs/nqui-skills/colorize/SKILL.md +5 -2
- package/docs/nqui-skills/delight/SKILL.md +5 -4
- package/docs/nqui-skills/distill/SKILL.md +5 -2
- package/docs/nqui-skills/impeccable/SKILL.md +0 -16
- package/docs/nqui-skills/impeccable/reference/INDEX.md +26 -0
- package/docs/nqui-skills/layout/SKILL.md +5 -2
- package/docs/nqui-skills/nqui-components/SKILL.md +32 -9
- package/docs/nqui-skills/nqui-composition/SKILL.md +148 -0
- package/docs/nqui-skills/nqui-data-tables/SKILL.md +127 -0
- package/docs/nqui-skills/nqui-design-system/SKILL.md +22 -1
- package/docs/nqui-skills/nqui-install/SKILL.md +1 -0
- package/docs/nqui-skills/overdrive/SKILL.md +5 -2
- package/docs/nqui-skills/polish/SKILL.md +5 -4
- package/docs/nqui-skills/quieter/SKILL.md +5 -2
- package/docs/nqui-skills/shape/SKILL.md +5 -2
- package/docs/nqui-skills/typeset/SKILL.md +5 -2
- package/package.json +2 -1
- package/scripts/cli.js +2 -0
- package/scripts/install-claude-skills.js +109 -0
|
@@ -6,10 +6,12 @@ These files mirror the **nqui** Cursor skills. They live in the `@nqlib/nqui` pa
|
|
|
6
6
|
| Skill | Path |
|
|
7
7
|
| ----------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- |
|
|
8
8
|
| Hub (start here) | [SKILL.md](./SKILL.md) |
|
|
9
|
+
| **Composition (product UI, recipes vs catalog)** | [COMPOSITION.md](./COMPOSITION.md) |
|
|
9
10
|
| **Task → components (designers)** | [HUMAN_GUIDE.md](./HUMAN_GUIDE.md) |
|
|
10
11
|
| **Component doc routing (agents; read first; saves tokens)** | [COMPONENTS_INDEX.md](./COMPONENTS_INDEX.md) |
|
|
11
12
|
| Per-component markdown (copied by `init-skills` to `.cursor/.../components/`) | `docs/components/` in repo; `components/` under this folder after init |
|
|
12
13
|
| Components & layouts | [nqui-components/SKILL.md](./nqui-components/SKILL.md) |
|
|
14
|
+
| Data tables + ScrollArea (dashboard grids) | [nqui-data-tables/SKILL.md](./nqui-data-tables/SKILL.md) |
|
|
13
15
|
| Design system (sizing, Card + ScrollArea) | [nqui-design-system/SKILL.md](./nqui-design-system/SKILL.md) |
|
|
14
16
|
| shadcn-style usage rules | [nqui-shadcn/SKILL.md](./nqui-shadcn/SKILL.md) |
|
|
15
17
|
| Bundle size & peers | [nqui-bundle-size-best-practices/SKILL.md](./nqui-bundle-size-best-practices/SKILL.md) |
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: read-budget
|
|
3
|
+
description: Minimal-read routing for nqui agent tasks. Tells you which files to load (and which NOT to) for common tasks. Read this FIRST when the task is unclear — it will route you to ~1-3 files instead of bulk-reading the whole skills folder.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Read Budget — load only what you need
|
|
7
|
+
|
|
8
|
+
The skills folder has ~50 files totaling ~5000 lines. Bulk reading wastes context. Use this table to load 1–3 files per task.
|
|
9
|
+
|
|
10
|
+
## Routing
|
|
11
|
+
|
|
12
|
+
| Task | Read THIS | Then maybe | Do NOT read |
|
|
13
|
+
|------|-----------|------------|-------------|
|
|
14
|
+
| **Build a new view from scratch** | `SKILL.md` (Agent Build Protocol — 10 steps) → `nqui-composition/SKILL.md` (craft) → `COMPOSITION.md` (pattern) → `RECIPES.md` (combos) | `STATES.md` (state matrix), `WRITING.md` (copy), one `components/nqui-<name>.md` per component | MOTION.md unless you're adding animation, full component README |
|
|
15
|
+
| **"How do I compose X?"** (status, bulk action, toolbar, loading state) | `RECIPES.md` (one numbered recipe) | The component(s) the recipe names | nqui-composition (philosophy, not needed for combo lookup) |
|
|
16
|
+
| **Make UI feel more Apple / refined** | `nqui-composition/SKILL.md` (three principles + hierarchy rules) | `RECIPES.md` to replace busy combos | Refinement skills — fix the composition first |
|
|
17
|
+
| **Make sure I've covered all states** | `STATES.md` (audit checklist) | — | nqui-composition (covered separately) |
|
|
18
|
+
| **Write copy / labels / error messages / empty states** | `WRITING.md` | — | nqui-composition, components |
|
|
19
|
+
| **Add transitions or animations** | `MOTION.md` (timing scale + easing) | The specific component's doc if it has motion-related props | All refinement skills |
|
|
20
|
+
| **Layered UI / nested cards / "this needs more depth"** | `ELEVATION.md` (the 2+1 rule + decision tree) | `nqui-design-system/SKILL.md` for the token names | Refinement skills until depth is right |
|
|
21
|
+
| **Run pre-ship review** | `SKILL.md` 30-second Linear designer test → `STATES.md` audit → `WRITING.md` audit → `MOTION.md` audit | `/audit` for technical/accessibility check | Refinement skills until the audits pass |
|
|
22
|
+
| **Set up an AI agent to use nqui** | `AGENT_PROMPT.md` (paste into agent system prompt) | `SKILL.md` Agent Build Protocol | Skills folder — agent will discover via routing |
|
|
23
|
+
| **Customize brand color / radius / palette** | `THEMING.md` | `colors.css` for the actual token names | Refinement skills, recipes |
|
|
24
|
+
| **Verify a release before publishing** | `EVAL.md` (run the 12-prompt eval) | `MIGRATION.md` to note breaking changes | All other skills — eval drives the priority |
|
|
25
|
+
| **Update consumer app after upgrade** | `MIGRATION.md` (latest section) | `THEMING.md` if customizations need re-verification | — |
|
|
26
|
+
| **Build auth / login / signup / OAuth / OTP / SSO** | `RECIPES.md` recipes 16-22 | One component doc per Field used | `Dialog`-related docs (auth is page-level, not modal) |
|
|
27
|
+
| **Choose between similar components** (Select vs Combobox, Dialog vs Sheet) | `COMPONENTS_INDEX.md` (inline decision tables) | One winner doc | Other component docs, COMPOSITION.md |
|
|
28
|
+
| **Fix a specific component's behavior** | `components/nqui-<name>.md` (single file) | `nqui-design-system/SKILL.md` only if sizing/spacing | `impeccable/`, refinement skills |
|
|
29
|
+
| **Card + ScrollArea / flex height bug** | `components/nqui-scroll-area.md` §0 (symptom routing) | §1 if §0 doesn't match | Other §, COMPOSITION.md |
|
|
30
|
+
| **Data table with sticky header / paging** | `nqui-data-tables/SKILL.md` | `components/nqui-scroll-area.md` §0–§6 | `nqui-table.md` (different component) |
|
|
31
|
+
| **Form (login, settings, checkout)** | `nqui-shadcn/rules/forms.md` | `components/nqui-field.md`, `nqui-input.md` | COMPOSITION.md form recipe is enough alone |
|
|
32
|
+
| **Toolbar selection (mode, format)** | `nqui-components/SKILL.md` (ToggleGroup rules section only) | `components/nqui-toggle-group.md` | `nqui-radio-group.md` (wrong default) |
|
|
33
|
+
| **Audit / review existing UI** | `audit/SKILL.md` | One specific reference IF a finding needs depth (see `impeccable/reference/INDEX.md`) | Full `impeccable/SKILL.md` if `.impeccable.md` exists |
|
|
34
|
+
| **Apply a refinement** (`/layout`, `/colorize`, etc.) | The specific skill `SKILL.md` | `.impeccable.md` (project context, NOT the full impeccable skill) | Other refinement skills, full `impeccable/SKILL.md` |
|
|
35
|
+
| **Design philosophy / anti-patterns** | `impeccable/SKILL.md` (one time, then trust it's loaded) | `impeccable/reference/<topic>.md` for one specific topic | All reference files at once |
|
|
36
|
+
| **Install / setup / version migration** | `nqui-install/SKILL.md` OR `nqui-local-published-toggle/SKILL.md` | — | impeccable, components |
|
|
37
|
+
|
|
38
|
+
## Rules of thumb
|
|
39
|
+
|
|
40
|
+
1. **One-and-done lookups** (component prop, when-to-use): `COMPONENTS_INDEX.md` first, then ONE file. Stop.
|
|
41
|
+
2. **Build tasks**: `SKILL.md` Agent Build Protocol → never deviate from its step order.
|
|
42
|
+
3. **Don't reload `impeccable/SKILL.md`** if the conversation has already touched a design skill — its context persists.
|
|
43
|
+
4. **`reference/` subdirectories** require an index — see `impeccable/reference/INDEX.md`. Do NOT bulk-read references.
|
|
44
|
+
5. **`.impeccable.md` in project root** is the project's design context. Refinement skills should check it, not reload the full impeccable skill.
|
|
45
|
+
|
|
46
|
+
## File-size hints (for picking the cheapest read)
|
|
47
|
+
|
|
48
|
+
- Per-component docs: typically 15–70 lines. Largest: `nqui-scroll-area.md` (175), `nqui-combobox.md` (158).
|
|
49
|
+
- `impeccable/SKILL.md`: ~360 lines — expensive. Load once per conversation.
|
|
50
|
+
- `impeccable/reference/*`: 70–195 lines each. Use the index, never all.
|
|
51
|
+
- `COMPOSITION.md`: ~220 lines. Contains all named layout patterns + checklist.
|
|
52
|
+
- Refinement skill `SKILL.md` files: typically 100–150 lines.
|
|
53
|
+
|
|
54
|
+
## Token-saving anti-patterns
|
|
55
|
+
|
|
56
|
+
- ❌ Loading `components/README.md` (large index file) when `COMPONENTS_INDEX.md` answers the question
|
|
57
|
+
- ❌ Bulk-reading `impeccable/reference/*` to "be thorough"
|
|
58
|
+
- ❌ Re-invoking `/impeccable` mid-conversation when context is already loaded
|
|
59
|
+
- ❌ Reading multiple refinement skills before choosing one — pick based on description
|
|
60
|
+
- ❌ Reading all 65 component docs to "discover" what's available — use `COMPONENTS_INDEX.md` area tables
|