@aircall/blocks 0.5.1 → 0.7.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/README.md ADDED
@@ -0,0 +1,43 @@
1
+ # @aircall/blocks
2
+
3
+ Higher-level UI compositions built on **`@aircall/ds`** — page shells (`DashboardPage` /
4
+ `DashboardStandalonePage`), the form layer (`useForm` + the `Form*Field` TanStack Form
5
+ wrappers), empty states, and more.
6
+
7
+ ```bash
8
+ pnpm add @aircall/blocks @aircall/ds
9
+ ```
10
+
11
+ Import the precompiled CSS once from your entry (alongside `@aircall/ds`'s):
12
+
13
+ ```tsx
14
+ import '@aircall/ds/globals.css';
15
+ import '@aircall/blocks/globals.css';
16
+ ```
17
+
18
+ > Importing `@aircall/blocks` registers a `blocks` i18n namespace on `@aircall/ds`'s shared
19
+ > i18next instance. To make block strings follow the user's language, mount `DsI18nProvider`
20
+ > (from `@aircall/ds`) **under** your react-i18next provider, fed the active language. See
21
+ > the `@aircall/ds` README and the `aircall-ds/setup` skill for the full provider tree.
22
+
23
+ ## For AI agents — migrating off `@dashboard/library`?
24
+
25
+ This package ships **[TanStack Intent](https://tanstack.com/intent) migration skills** in
26
+ its `skills/` directory (published in the npm tarball): `aircall-blocks/migrate-dashboard`
27
+ (+ per-area recipes) for moving `@dashboard/library` screens to `@aircall/blocks` /
28
+ `@aircall/ds`, plus `aircall-blocks/setup`. Enable them (one-time, same as `@aircall/ds`):
29
+
30
+ ```bash
31
+ pnpm add @aircall/blocks@latest @aircall/ds@latest @aircall/react-icons@latest # react-icons >= 0.4.0
32
+ npx @tanstack/intent install # writes the discovery block into CLAUDE.md / AGENTS.md
33
+ # allowlist in package.json: { "intent": { "skills": ["@aircall/ds", "@aircall/blocks"] } }
34
+ ```
35
+
36
+ Then the agent loads guidance on demand:
37
+
38
+ ```bash
39
+ npx @tanstack/intent load "@aircall/blocks#aircall-blocks/migrate-dashboard"
40
+ ```
41
+
42
+ `aircall-blocks/setup` builds on `aircall-ds/setup`, so the DS providers, `globals.css`, and
43
+ jsdom test shims documented there apply here too.