@a4ui/core 0.32.0 → 0.34.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.
Files changed (63) hide show
  1. package/dist/charts/BarList.d.ts +33 -0
  2. package/dist/charts/CategoryBar.d.ts +23 -0
  3. package/dist/charts/StatusTracker.d.ts +27 -0
  4. package/dist/charts/index.d.ts +3 -0
  5. package/dist/charts.js +446 -316
  6. package/dist/elements.css +278 -0
  7. package/dist/full.css +278 -0
  8. package/dist/index.d.ts +25 -1
  9. package/dist/index.js +6423 -4195
  10. package/dist/ui/AudioWaveform.d.ts +22 -0
  11. package/dist/ui/Callout.d.ts +27 -0
  12. package/dist/ui/Confetti.d.ts +46 -0
  13. package/dist/ui/CouponField.d.ts +33 -0
  14. package/dist/ui/CursorTrail.d.ts +25 -0
  15. package/dist/ui/DiffViewer.d.ts +33 -0
  16. package/dist/ui/FollowingPointer.d.ts +24 -0
  17. package/dist/ui/GanttChart.d.ts +37 -0
  18. package/dist/ui/Globe.d.ts +44 -0
  19. package/dist/ui/Kanban.d.ts +49 -0
  20. package/dist/ui/Lamp.d.ts +22 -0
  21. package/dist/ui/Lightbox.d.ts +41 -0
  22. package/dist/ui/ModelPicker.d.ts +38 -0
  23. package/dist/ui/OnboardingChecklist.d.ts +51 -0
  24. package/dist/ui/PivotTable.d.ts +37 -0
  25. package/dist/ui/ReasoningTrace.d.ts +28 -0
  26. package/dist/ui/SheetSnap.d.ts +28 -0
  27. package/dist/ui/Snippet.d.ts +19 -0
  28. package/dist/ui/SuggestionChips.d.ts +25 -0
  29. package/dist/ui/ToolCallTimeline.d.ts +34 -0
  30. package/dist/ui/TreeTable.d.ts +52 -0
  31. package/dist/ui/UsageMeter.d.ts +26 -0
  32. package/dist/ui/VideoPlayerShell.d.ts +19 -0
  33. package/dist/ui/WorldMap.d.ts +36 -0
  34. package/package.json +1 -1
  35. package/src/charts/BarList.tsx +83 -0
  36. package/src/charts/CategoryBar.tsx +95 -0
  37. package/src/charts/StatusTracker.tsx +81 -0
  38. package/src/charts/index.ts +3 -0
  39. package/src/index.ts +48 -1
  40. package/src/ui/AudioWaveform.tsx +190 -0
  41. package/src/ui/Callout.tsx +66 -0
  42. package/src/ui/Confetti.tsx +131 -0
  43. package/src/ui/CouponField.tsx +120 -0
  44. package/src/ui/CursorTrail.tsx +88 -0
  45. package/src/ui/DiffViewer.tsx +166 -0
  46. package/src/ui/FollowingPointer.tsx +112 -0
  47. package/src/ui/GanttChart.tsx +283 -0
  48. package/src/ui/Globe.tsx +317 -0
  49. package/src/ui/Kanban.tsx +250 -0
  50. package/src/ui/Lamp.tsx +88 -0
  51. package/src/ui/Lightbox.tsx +261 -0
  52. package/src/ui/ModelPicker.tsx +119 -0
  53. package/src/ui/OnboardingChecklist.tsx +163 -0
  54. package/src/ui/PivotTable.tsx +0 -0
  55. package/src/ui/ReasoningTrace.tsx +83 -0
  56. package/src/ui/SheetSnap.tsx +264 -0
  57. package/src/ui/Snippet.tsx +64 -0
  58. package/src/ui/SuggestionChips.tsx +65 -0
  59. package/src/ui/ToolCallTimeline.tsx +137 -0
  60. package/src/ui/TreeTable.tsx +172 -0
  61. package/src/ui/UsageMeter.tsx +71 -0
  62. package/src/ui/VideoPlayerShell.tsx +282 -0
  63. package/src/ui/WorldMap.tsx +191 -0
@@ -0,0 +1,22 @@
1
+ import { JSX } from 'solid-js';
2
+ export interface AudioWaveformProps {
3
+ src?: string;
4
+ peaks?: number[];
5
+ /** Bar row height in pixels. @default 64 */
6
+ height?: number;
7
+ class?: string;
8
+ }
9
+ /**
10
+ * Waveform of vertical bars driven by an optional hidden `<audio>` element.
11
+ * Pass `peaks` (numbers in `0..1`) for a real waveform, or omit it for a
12
+ * deterministic placeholder shape. The played portion (up to
13
+ * `currentTime / duration`) is highlighted; clicking a bar seeks there. With
14
+ * no `src`, playback is simulated on a timer for demo purposes.
15
+ *
16
+ * @example
17
+ * ```tsx
18
+ * <AudioWaveform src="/media/track.mp3" />
19
+ * <AudioWaveform peaks={[0.2, 0.8, 0.4, 0.9, 0.3]} height={48} />
20
+ * ```
21
+ */
22
+ export declare function AudioWaveform(props: AudioWaveformProps): JSX.Element;
@@ -0,0 +1,27 @@
1
+ import { JSX } from 'solid-js';
2
+ /** Semantic tone of a {@link Callout}; drives the accent border, tint, and default icon. */
3
+ export type CalloutTone = 'info' | 'success' | 'warning' | 'danger' | 'neutral';
4
+ export interface CalloutProps {
5
+ /** Visual/semantic tone. Defaults to `'info'`. */
6
+ tone?: 'info' | 'success' | 'warning' | 'danger' | 'neutral';
7
+ /** Optional bold heading shown above the body. */
8
+ title?: JSX.Element;
9
+ /** Overrides the tone's default icon. */
10
+ icon?: JSX.Element;
11
+ children: JSX.Element;
12
+ class?: string;
13
+ }
14
+ /**
15
+ * Inline highlighted block for embedding guidance/notes inside prose (docs,
16
+ * READMEs, long-form content) — a left accent border, a faint tone-tinted
17
+ * background, and an icon. Unlike {@link Alert} it isn't a dismissible
18
+ * notification; it's part of the content flow.
19
+ *
20
+ * @example
21
+ * ```tsx
22
+ * <Callout tone="warning" title="Before you continue">
23
+ * This action can't be undone once the migration starts.
24
+ * </Callout>
25
+ * ```
26
+ */
27
+ export declare function Callout(props: CalloutProps): JSX.Element;
@@ -0,0 +1,46 @@
1
+ import { JSX } from 'solid-js';
2
+ export interface ConfettiProps {
3
+ /** Bump this (e.g. a counter) to fire a burst. Mount does not count. */
4
+ trigger?: number;
5
+ /** Number of pieces per burst. @default 80 */
6
+ count?: number;
7
+ class?: string;
8
+ }
9
+ /**
10
+ * Fires one burst of confetti pieces from the bottom-center of `container`,
11
+ * flying up and outward in a fan, rotating, then falling with gravity and
12
+ * fading out — each piece removes itself once its animation finishes. Angle,
13
+ * speed, fall distance and spin are derived deterministically from each
14
+ * piece's index (Math.sin), so the same `count` always produces the same
15
+ * fan. `container` should be `position: relative` (or already positioned)
16
+ * with `overflow: hidden` so pieces don't affect layout. No-op under
17
+ * {@link motionReduced}. This is the primitive behind {@link Confetti}.
18
+ *
19
+ * @example
20
+ * ```ts
21
+ * fireConfetti(cardEl, { count: 120 })
22
+ * ```
23
+ */
24
+ export declare function fireConfetti(container: HTMLElement, opts?: {
25
+ count?: number;
26
+ }): void;
27
+ /**
28
+ * Absolutely-positioned confetti layer: fires a burst of colored pieces from
29
+ * the bottom-center whenever `trigger` changes (the initial mount does not
30
+ * fire one). Purely decorative — `pointer-events-none` and `aria-hidden`.
31
+ * Place it inside a `position: relative` container; pair with a `count`
32
+ * prop, or reach for {@link fireConfetti} directly to fire into an
33
+ * arbitrary element outside Solid's render tree.
34
+ *
35
+ * @example
36
+ * ```tsx
37
+ * const [bursts, setBursts] = createSignal(0)
38
+ * return (
39
+ * <div class="relative h-64">
40
+ * <Confetti trigger={bursts()} count={100} />
41
+ * <Button onClick={() => setBursts((n) => n + 1)}>Celebrate</Button>
42
+ * </div>
43
+ * )
44
+ * ```
45
+ */
46
+ export declare function Confetti(props: ConfettiProps): JSX.Element;
@@ -0,0 +1,33 @@
1
+ import { JSX } from 'solid-js';
2
+ export interface CouponFieldProps {
3
+ /** Validate/apply a coupon code. Resolve with `{ ok: false }` for a rejected
4
+ * code — do not throw for expected rejections, only for unexpected failures. */
5
+ onApply: (code: string) => Promise<{
6
+ ok: boolean;
7
+ message?: string;
8
+ discount?: string;
9
+ }>;
10
+ placeholder?: string;
11
+ class?: string;
12
+ }
13
+ /**
14
+ * Coupon/promo code input with an "Apply" button. Tracks explicit
15
+ * idle/loading/success/error state: loading shows a spinner and disables the
16
+ * input, success shows the applied discount with a way to remove it and try
17
+ * another code, error shows the failure message inline and lets the user retry.
18
+ * Rejections are read from the resolved `{ ok: false }` result, not caught
19
+ * exceptions — an unexpected throw from `onApply` propagates uncaught.
20
+ *
21
+ * @example
22
+ * ```tsx
23
+ * <CouponField
24
+ * onApply={async (code) => {
25
+ * const res = await api.applyCoupon(code)
26
+ * return res.valid
27
+ * ? { ok: true, discount: '-$10' }
28
+ * : { ok: false, message: 'That code has expired.' }
29
+ * }}
30
+ * />
31
+ * ```
32
+ */
33
+ export declare function CouponField(props: CouponFieldProps): JSX.Element;
@@ -0,0 +1,25 @@
1
+ import { JSX } from 'solid-js';
2
+ export interface CursorTrailProps {
3
+ /** Blob tone. @default 'primary' */
4
+ color?: 'primary' | 'accent';
5
+ /** Blob diameter in px. @default 24 */
6
+ size?: number;
7
+ class?: string;
8
+ }
9
+ /**
10
+ * Layer that spawns a soft, blurred blob at the cursor position on every
11
+ * throttled `pointermove` over its parent, scaling down and fading out as
12
+ * it removes itself — leaving a trail. Must sit inside a `position:
13
+ * relative` parent (the layer listens on `parentElement`, since it is
14
+ * itself `pointer-events-none`). Purely decorative — `pointer-events-none`
15
+ * and `aria-hidden`. No-op under {@link motionReduced}; listeners are
16
+ * cleaned up on unmount.
17
+ *
18
+ * @example
19
+ * ```tsx
20
+ * <div class="relative h-48 rounded-lg border">
21
+ * <CursorTrail color="accent" size={32} />
22
+ * </div>
23
+ * ```
24
+ */
25
+ export declare function CursorTrail(props: CursorTrailProps): JSX.Element;
@@ -0,0 +1,33 @@
1
+ import { JSX } from 'solid-js';
2
+ /** A single rendered row of a diff. */
3
+ export interface DiffLine {
4
+ type: 'add' | 'remove' | 'context';
5
+ content: string;
6
+ /** Line number in the old file. Present for `'remove'` and `'context'` rows. */
7
+ oldNum?: number;
8
+ /** Line number in the new file. Present for `'add'` and `'context'` rows. */
9
+ newNum?: number;
10
+ }
11
+ export interface DiffViewerProps {
12
+ /** Unified diff text (as produced by `git diff`/`diff -u`). Ignored if `lines` is set. */
13
+ diff?: string;
14
+ /** Pre-parsed diff rows. Takes precedence over `diff`. */
15
+ lines?: DiffLine[];
16
+ /** Header label. If omitted, inferred from the `+++`/`---` headers of `diff`, when present. */
17
+ filename?: string;
18
+ class?: string;
19
+ }
20
+ /**
21
+ * Read-only diff block: renders added/removed/context lines with a line-number
22
+ * gutter and a +/-/space marker. Accepts either a raw unified-diff string
23
+ * (parsed internally) or pre-parsed {@link DiffLine} rows.
24
+ *
25
+ * @example
26
+ * ```tsx
27
+ * <DiffViewer
28
+ * filename="src/lib/cn.ts"
29
+ * diff={`@@ -1,3 +1,3 @@\n-export const cn = (a) => a\n+export const cn = (a, b) => a + b\n context line`}
30
+ * />
31
+ * ```
32
+ */
33
+ export declare function DiffViewer(props: DiffViewerProps): JSX.Element;
@@ -0,0 +1,24 @@
1
+ import { JSX } from 'solid-js';
2
+ export interface FollowingPointerProps {
3
+ label?: JSX.Element;
4
+ /** Tone of the custom cursor + label chip. @default 'primary' */
5
+ color?: 'primary' | 'accent';
6
+ children: JSX.Element;
7
+ class?: string;
8
+ }
9
+ /**
10
+ * Wraps `children` in a `relative` container that hides the native cursor
11
+ * and renders a custom pointer — a small arrow glyph plus a rounded label
12
+ * chip in the given tone — that follows the mouse within the container.
13
+ * Hidden until the pointer enters, hidden again on leave. Under
14
+ * {@link motionReduced}, the native cursor is kept and nothing custom is
15
+ * rendered. Listeners are cleaned up on unmount.
16
+ *
17
+ * @example
18
+ * ```tsx
19
+ * <FollowingPointer label="Alex" color="accent">
20
+ * <div class="grid h-48 place-items-center rounded-lg border">Hover me</div>
21
+ * </FollowingPointer>
22
+ * ```
23
+ */
24
+ export declare function FollowingPointer(props: FollowingPointerProps): JSX.Element;
@@ -0,0 +1,37 @@
1
+ import { JSX } from 'solid-js';
2
+ /** A single bar rendered by {@link GanttChart}. */
3
+ export interface GanttTask {
4
+ id: string;
5
+ name: string;
6
+ /** ISO date, `'YYYY-MM-DD'`. */
7
+ start: string;
8
+ /** ISO date, `'YYYY-MM-DD'`. */
9
+ end: string;
10
+ /** Ids of tasks that must finish before this one starts; drawn as elbow connectors. */
11
+ dependencies?: string[];
12
+ /** Bar color. Defaults to `'primary'`. */
13
+ tone?: 'primary' | 'accent';
14
+ }
15
+ export interface GanttChartProps {
16
+ tasks: GanttTask[];
17
+ class?: string;
18
+ }
19
+ /**
20
+ * Read-only Gantt chart: a header row of date ticks over a proportional time
21
+ * axis, one row per task with a colored bar spanning `start`–`end`, elbow
22
+ * connectors for `dependencies`, and a "today" marker when today falls
23
+ * within the overall range. Horizontal scroll kicks in when the range is
24
+ * wide relative to the container.
25
+ *
26
+ * @example
27
+ * ```tsx
28
+ * <GanttChart
29
+ * tasks={[
30
+ * { id: 'design', name: 'Design', start: '2026-01-05', end: '2026-01-16', tone: 'accent' },
31
+ * { id: 'build', name: 'Build', start: '2026-01-19', end: '2026-02-06', dependencies: ['design'] },
32
+ * { id: 'launch', name: 'Launch', start: '2026-02-09', end: '2026-02-10', dependencies: ['build'] },
33
+ * ]}
34
+ * />
35
+ * ```
36
+ */
37
+ export declare function GanttChart(props: GanttChartProps): JSX.Element;
@@ -0,0 +1,44 @@
1
+ import { JSX } from 'solid-js';
2
+ export interface GlobeMarker {
3
+ lat: number;
4
+ lng: number;
5
+ label?: string;
6
+ }
7
+ export interface GlobeArc {
8
+ /** [lat, lng] */
9
+ from: [number, number];
10
+ /** [lat, lng] */
11
+ to: [number, number];
12
+ }
13
+ export interface GlobeProps {
14
+ markers?: GlobeMarker[];
15
+ arcs?: GlobeArc[];
16
+ /** Canvas size in CSS px (square). @default 400 */
17
+ size?: number;
18
+ /** Spin automatically. @default true (ignored under reduced motion). */
19
+ autoRotate?: boolean;
20
+ class?: string;
21
+ }
22
+ /**
23
+ * A dotted 3D globe drawn on `<canvas>` with plain Canvas 2D (no three.js,
24
+ * no WebGL): dots come from a deterministic Fibonacci-sphere distribution,
25
+ * rotate around the Y axis, and project orthographically with depth-scaled
26
+ * alpha/size. `markers` render as brighter glowing dots (title = label);
27
+ * `arcs` draw as outward-bulging curves between two front-facing markers,
28
+ * with a small traveling highlight. Auto-rotates unless `autoRotate={false}`;
29
+ * drag with the pointer to spin manually. Renders a single static frame
30
+ * under `motionReduced()` (no auto-rotation; drag still works).
31
+ *
32
+ * @example
33
+ * ```tsx
34
+ * <Globe
35
+ * size={360}
36
+ * markers={[
37
+ * { lat: 40.7, lng: -74.0, label: 'New York' },
38
+ * { lat: 35.7, lng: 139.7, label: 'Tokyo' },
39
+ * ]}
40
+ * arcs={[{ from: [40.7, -74.0], to: [35.7, 139.7] }]}
41
+ * />
42
+ * ```
43
+ */
44
+ export declare function Globe(props: GlobeProps): JSX.Element;
@@ -0,0 +1,49 @@
1
+ import { JSX } from 'solid-js';
2
+ /** A single card on a {@link Kanban} board. */
3
+ export interface KanbanCard {
4
+ /** Stable unique id (used for drag tracking + list keying). */
5
+ id: string;
6
+ /** Card body — usually a title/label. */
7
+ title: JSX.Element;
8
+ /** Optional trailing badge (e.g. priority, assignee initials). */
9
+ badge?: JSX.Element;
10
+ }
11
+ /** A column of a {@link Kanban} board. */
12
+ export interface KanbanColumn {
13
+ /** Stable unique id. */
14
+ id: string;
15
+ /** Column heading. */
16
+ title: string;
17
+ /** Cards in the column, top to bottom. */
18
+ cards: KanbanCard[];
19
+ /** Optional WIP limit — the count badge switches to a warning tone past it. */
20
+ limit?: number;
21
+ }
22
+ export interface KanbanProps {
23
+ /** Columns, in display order left to right. */
24
+ columns: KanbanColumn[];
25
+ /** Called with the full new columns array after any drag (reorder or move). */
26
+ onChange?: (columns: KanbanColumn[]) => void;
27
+ class?: string;
28
+ }
29
+ /**
30
+ * Horizontal Kanban board: glass column panels holding vertical lists of
31
+ * draggable cards. Drag a card by its grip handle to reorder it within a
32
+ * column or drop it into another column — a dashed placeholder marks the
33
+ * drop slot and a floating clone follows the pointer, the same pointer-events
34
+ * idiom as {@link Sortable} extended to track which column's list the
35
+ * pointer is currently over. Works controlled (pass `columns` sourced from
36
+ * your own state + `onChange` to write it back) or uncontrolled (pass
37
+ * `columns` once and just read the final layout from `onChange`).
38
+ *
39
+ * @example
40
+ * ```tsx
41
+ * const [columns, setColumns] = createSignal<KanbanColumn[]>([
42
+ * { id: 'todo', title: 'To do', cards: [{ id: '1', title: 'Write spec' }] },
43
+ * { id: 'doing', title: 'Doing', cards: [], limit: 2 },
44
+ * { id: 'done', title: 'Done', cards: [] },
45
+ * ])
46
+ * <Kanban columns={columns()} onChange={setColumns} />
47
+ * ```
48
+ */
49
+ export declare function Kanban(props: KanbanProps): JSX.Element;
@@ -0,0 +1,22 @@
1
+ import { JSX } from 'solid-js';
2
+ export interface LampProps {
3
+ children?: JSX.Element;
4
+ class?: string;
5
+ }
6
+ /**
7
+ * Hero/section backdrop: a spotlight beam fanning down from the top center —
8
+ * two symmetric blurred gradient cones (`--primary` / `--accent`) plus a
9
+ * bright thin source line — over a dark base, with `children` centered in
10
+ * the illuminated area below. Grows/brightens in on mount via Motion
11
+ * (opacity + scale); static under {@link motionReduced}. Self-contained
12
+ * (`relative overflow-hidden`); size it with `class` (e.g. `min-h-[28rem]`).
13
+ *
14
+ * @example
15
+ * ```tsx
16
+ * <Lamp class="min-h-[28rem]">
17
+ * <h1 class="text-4xl font-semibold text-foreground">Build in the light</h1>
18
+ * <p class="mt-4 text-muted-foreground">A hero backdrop with a spotlight glow.</p>
19
+ * </Lamp>
20
+ * ```
21
+ */
22
+ export declare function Lamp(props: LampProps): JSX.Element;
@@ -0,0 +1,41 @@
1
+ import { JSX } from 'solid-js';
2
+ /** One image in a {@link Lightbox}. */
3
+ export interface LightboxImage {
4
+ src: string;
5
+ alt?: string;
6
+ /** Smaller image used in the thumbnail grid/strip; falls back to `src`. */
7
+ thumb?: string;
8
+ }
9
+ export interface LightboxProps {
10
+ images: LightboxImage[];
11
+ /** Controlled overlay open state. When set, wins over internal state — pair with `onOpenChange`. */
12
+ open?: boolean;
13
+ /** Controlled active image index (clamped to the images array). When set, wins over internal state — pair with `onIndexChange`. */
14
+ index?: number;
15
+ onOpenChange?: (open: boolean) => void;
16
+ onIndexChange?: (index: number) => void;
17
+ /** Show the thumbnail strip at the bottom of the overlay. @default true */
18
+ showThumbnails?: boolean;
19
+ class?: string;
20
+ }
21
+ /**
22
+ * Responsive thumbnail grid (`thumb || src`) that opens into a full-screen
23
+ * viewer on click: the active image centered, prev/next chevrons, a close
24
+ * button, an alt-text caption, a zoom toggle, and (by default) a thumbnail
25
+ * strip with the active image highlighted. Navigate with the arrow keys or
26
+ * Escape, click the backdrop to close. Works controlled
27
+ * (`open`/`index` + `onOpenChange`/`onIndexChange`) or uncontrolled. Body
28
+ * scroll locks while open, like `Modal`; the zoom transition is skipped
29
+ * under `prefers-reduced-motion` but stays fully functional.
30
+ *
31
+ * @example
32
+ * ```tsx
33
+ * <Lightbox
34
+ * images={[
35
+ * { src: '/photos/1-full.jpg', thumb: '/photos/1-thumb.jpg', alt: 'Sunset over the bay' },
36
+ * { src: '/photos/2-full.jpg', thumb: '/photos/2-thumb.jpg', alt: 'Mountain trail' },
37
+ * ]}
38
+ * />
39
+ * ```
40
+ */
41
+ export declare function Lightbox(props: LightboxProps): JSX.Element;
@@ -0,0 +1,38 @@
1
+ import { JSX } from 'solid-js';
2
+ /** A single selectable model in a {@link ModelPicker} menu. */
3
+ export interface ModelOption {
4
+ id: string;
5
+ name: string;
6
+ icon?: JSX.Element;
7
+ description?: string;
8
+ badge?: JSX.Element;
9
+ }
10
+ export interface ModelPickerProps {
11
+ models: ModelOption[];
12
+ /** Controlled selected model id. Omit and use `defaultValue` for uncontrolled use. */
13
+ value?: string;
14
+ /** Initial selected model id when uncontrolled. Ignored if `value` is passed. */
15
+ defaultValue?: string;
16
+ onChange?: (id: string) => void;
17
+ class?: string;
18
+ }
19
+ /**
20
+ * Dropdown trigger showing the selected model's icon + name + a chevron; the
21
+ * menu lists every model with icon, name, description, and optional badge,
22
+ * checkmarking the current selection. Controlled via `value`/`onChange` or
23
+ * uncontrolled via `defaultValue`, and fully keyboard-navigable (arrow keys,
24
+ * typeahead, Escape) via Kobalte's `DropdownMenu`.
25
+ *
26
+ * @example
27
+ * ```tsx
28
+ * <ModelPicker
29
+ * models={[
30
+ * { id: 'sonnet', name: 'Claude Sonnet', description: 'Balanced speed and quality' },
31
+ * { id: 'opus', name: 'Claude Opus', description: 'Most capable', badge: <Badge tone="info">New</Badge> },
32
+ * ]}
33
+ * defaultValue="sonnet"
34
+ * onChange={(id) => console.log('selected', id)}
35
+ * />
36
+ * ```
37
+ */
38
+ export declare function ModelPicker(props: ModelPickerProps): JSX.Element;
@@ -0,0 +1,51 @@
1
+ import { JSX } from 'solid-js';
2
+ /** A single step in an {@link OnboardingChecklist}. */
3
+ export interface OnboardingStep {
4
+ /** Stable identifier, used as the toggle key and `For` item key. */
5
+ id: string;
6
+ title: JSX.Element;
7
+ /** Optional detail shown when the step is expanded. */
8
+ description?: JSX.Element;
9
+ /** Whether the step is complete. */
10
+ done?: boolean;
11
+ /** Optional call-to-action rendered alongside the description. */
12
+ action?: {
13
+ label: string;
14
+ onClick: () => void;
15
+ };
16
+ }
17
+ export interface OnboardingChecklistProps {
18
+ steps: OnboardingStep[];
19
+ /** Called with the step id and its next `done` state when the indicator is toggled. */
20
+ onToggle?: (id: string, done: boolean) => void;
21
+ /** Heading shown above the progress summary. Defaults to `'Getting started'`. */
22
+ title?: JSX.Element;
23
+ class?: string;
24
+ }
25
+ /**
26
+ * Card-shaped onboarding/setup checklist: a header with a completion ring and
27
+ * "{done} of {total} complete" summary, followed by expandable steps. Each
28
+ * step has a clickable check indicator (toggles `done` via `onToggle`), a
29
+ * title, and an optional description + CTA revealed on expand. Completion is
30
+ * controlled by the caller; expansion is local UI state (one step open at a time).
31
+ *
32
+ * @example
33
+ * ```tsx
34
+ * const [steps, setSteps] = createSignal<OnboardingStep[]>([
35
+ * { id: 'profile', title: 'Complete your profile', done: true },
36
+ * {
37
+ * id: 'invite',
38
+ * title: 'Invite a teammate',
39
+ * description: 'Collaborate faster by adding at least one teammate.',
40
+ * action: { label: 'Invite', onClick: () => openInviteDialog() },
41
+ * },
42
+ * ])
43
+ * <OnboardingChecklist
44
+ * steps={steps()}
45
+ * onToggle={(id, done) =>
46
+ * setSteps((prev) => prev.map((s) => (s.id === id ? { ...s, done } : s)))
47
+ * }
48
+ * />
49
+ * ```
50
+ */
51
+ export declare function OnboardingChecklist(props: OnboardingChecklistProps): JSX.Element;
@@ -0,0 +1,37 @@
1
+ import { JSX } from 'solid-js';
2
+ /** A single record fed into {@link PivotTable}. */
3
+ export interface PivotDatum {
4
+ [key: string]: string | number;
5
+ }
6
+ export interface PivotTableProps {
7
+ data: PivotDatum[];
8
+ /** Field whose unique values become row headers. */
9
+ rowField: string;
10
+ /** Field whose unique values become column headers. */
11
+ columnField: string;
12
+ /** Numeric field aggregated into each cell. */
13
+ valueField: string;
14
+ /** Aggregation applied per (row, column) bucket. Defaults to 'sum'. */
15
+ aggregate?: 'sum' | 'count' | 'avg';
16
+ class?: string;
17
+ }
18
+ /**
19
+ * Cross-tab table: crosses the unique values of `rowField` and `columnField`,
20
+ * aggregating `valueField` into each cell (default `'sum'`), plus row/column
21
+ * totals.
22
+ *
23
+ * @example
24
+ * ```tsx
25
+ * <PivotTable
26
+ * data={[
27
+ * { region: 'West', product: 'Widget', revenue: 100 },
28
+ * { region: 'West', product: 'Gadget', revenue: 50 },
29
+ * { region: 'East', product: 'Widget', revenue: 75 },
30
+ * ]}
31
+ * rowField="region"
32
+ * columnField="product"
33
+ * valueField="revenue"
34
+ * />
35
+ * ```
36
+ */
37
+ export declare function PivotTable(props: PivotTableProps): JSX.Element;
@@ -0,0 +1,28 @@
1
+ import { JSX } from 'solid-js';
2
+ export interface ReasoningTraceProps {
3
+ /** Reasoning body content; takes precedence over `text` when both are given. */
4
+ children?: JSX.Element;
5
+ /** Plain-text reasoning body, rendered with preserved whitespace. */
6
+ text?: string;
7
+ /** Header label. Defaults to `'Reasoning'`. */
8
+ label?: JSX.Element;
9
+ /** Whether the panel starts expanded. Defaults to `false`. */
10
+ defaultOpen?: boolean;
11
+ /** Show a pulsing dot in the header to indicate reasoning is still streaming. */
12
+ streaming?: boolean;
13
+ class?: string;
14
+ }
15
+ /**
16
+ * Collapsible panel for surfacing a model's intermediate "thinking"/reasoning
17
+ * trace. The header is a toggle button (brain icon + label + rotating
18
+ * chevron, plus a pulsing dot while `streaming`); the body is a muted,
19
+ * smaller-text block showing `text` or `children` with whitespace preserved.
20
+ * Collapsed by default unless `defaultOpen`. Height/opacity transition,
21
+ * instant under reduced motion.
22
+ *
23
+ * @example
24
+ * ```tsx
25
+ * <ReasoningTrace streaming text={reasoningSoFar()} />
26
+ * ```
27
+ */
28
+ export declare function ReasoningTrace(props: ReasoningTraceProps): JSX.Element;
@@ -0,0 +1,28 @@
1
+ import { JSX } from 'solid-js';
2
+ export interface SheetSnapProps {
3
+ open: boolean;
4
+ onOpenChange: (open: boolean) => void;
5
+ /** Fractions of viewport height, ascending, e.g. `[0.4, 0.9]`. @default [0.5, 0.9] */
6
+ snapPoints?: number[];
7
+ /** Index into `snapPoints` to open at. @default 0 */
8
+ defaultSnap?: number;
9
+ children: JSX.Element;
10
+ class?: string;
11
+ }
12
+ /**
13
+ * A draggable bottom sheet that rests at one of several height "snap points"
14
+ * (fractions of viewport height) instead of just open/closed. Drag the handle
15
+ * to resize with the finger; releasing snaps to the nearest point, biased by
16
+ * flick velocity (a fast swipe jumps a level), and a hard downward flick/drag
17
+ * past the lowest point dismisses. Falls back to an instant show/hide at
18
+ * `defaultSnap` — no drag physics — under reduced motion.
19
+ *
20
+ * @example
21
+ * ```tsx
22
+ * const [open, setOpen] = createSignal(false)
23
+ * <SheetSnap open={open()} onOpenChange={setOpen} snapPoints={[0.4, 0.9]}>
24
+ * <p>Sheet content…</p>
25
+ * </SheetSnap>
26
+ * ```
27
+ */
28
+ export declare function SheetSnap(props: SheetSnapProps): JSX.Element;
@@ -0,0 +1,19 @@
1
+ import { JSX } from 'solid-js';
2
+ export interface SnippetProps {
3
+ /** Source text to display and copy. */
4
+ code: string;
5
+ /** Optional language tag shown as a small badge, e.g. `'tsx'`. Informational only, no highlighting. */
6
+ language?: string;
7
+ class?: string;
8
+ }
9
+ /**
10
+ * Single inline code block (mono, bordered, scrollable) with a copy button
11
+ * that morphs into a checkmark for 1.5s after copying. For one code sample —
12
+ * use {@link CodeTabs} instead when you need several tabs/languages.
13
+ *
14
+ * @example
15
+ * ```tsx
16
+ * <Snippet language="bash" code="pnpm add @a4ui/core" />
17
+ * ```
18
+ */
19
+ export declare function Snippet(props: SnippetProps): JSX.Element;
@@ -0,0 +1,25 @@
1
+ import { JSX } from 'solid-js';
2
+ export interface SuggestionChipsProps {
3
+ suggestions: string[];
4
+ onSelect?: (s: string) => void;
5
+ onDismiss?: (s: string) => void;
6
+ class?: string;
7
+ }
8
+ /**
9
+ * Wrapping row of pill chips, e.g. AI-suggested follow-up prompts. Clicking a
10
+ * chip calls `onSelect`; if `onDismiss` is passed, each chip also shows a
11
+ * small "x" that removes it without triggering `onSelect`. The select and
12
+ * dismiss controls are real sibling `<button>`s (not nested — a `<button>`
13
+ * can't validly contain another interactive element), so both are reachable
14
+ * and operable independently via Tab/Enter/Space with no extra ARIA wiring.
15
+ *
16
+ * @example
17
+ * ```tsx
18
+ * <SuggestionChips
19
+ * suggestions={['Summarize this', 'Explain like I\'m 5', 'Write tests']}
20
+ * onSelect={(s) => sendMessage(s)}
21
+ * onDismiss={(s) => setSuggestions((prev) => prev.filter((x) => x !== s))}
22
+ * />
23
+ * ```
24
+ */
25
+ export declare function SuggestionChips(props: SuggestionChipsProps): JSX.Element;