@devalok/shilp-sutra 0.48.0 → 0.49.1
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/BREAKING.json +32 -0
- package/MIGRATION.md +891 -881
- package/dist/_chunks/badge-group.js +52 -65
- package/dist/_chunks/badge-group.js.map +1 -1
- package/dist/_chunks/block-shell.js +1 -1
- package/dist/_chunks/chart-container.js +1 -1
- package/dist/_chunks/chat.js +4 -4
- package/dist/_chunks/chat.js.map +1 -1
- package/dist/_chunks/colors.js +2 -2
- package/dist/_chunks/document-preview.js +4 -4
- package/dist/_chunks/emoji-suggestion.js +5 -5
- package/dist/_chunks/emoji-suggestion.js.map +1 -1
- package/dist/_chunks/emoji.js +1 -1
- package/dist/_chunks/field-state.js +8 -0
- package/dist/_chunks/field-state.js.map +1 -0
- package/dist/_chunks/grid-lines.js +1 -1
- package/dist/_chunks/image-preview.js +7 -7
- package/dist/_chunks/keybinding.js +1 -1
- package/dist/_chunks/link-context.js +1 -1
- package/dist/_chunks/mention-suggestion.js +2 -2
- package/dist/_chunks/mention.js +1 -1
- package/dist/_chunks/motion-provider.js +1 -1
- package/dist/_chunks/normalize-icon.js +1 -1
- package/dist/_chunks/oauth-button.js +2 -2
- package/dist/_chunks/popover.js +55 -52
- package/dist/_chunks/popover.js.map +1 -1
- package/dist/_chunks/primitives.js +155 -155
- package/dist/_chunks/primitives.js.map +1 -1
- package/dist/_chunks/shared.js +5 -5
- package/dist/_chunks/success.js +4 -4
- package/dist/_chunks/tiptap.js +8 -8
- package/dist/_chunks/tooltip.js +1 -1
- package/dist/_chunks/tree-view.js +2 -2
- package/dist/_chunks/use-calendar.js +2 -2
- package/dist/_chunks/use-calendar.js.map +1 -1
- package/dist/_chunks/use-controllable-open.js +15 -0
- package/dist/_chunks/use-controllable-open.js.map +1 -0
- package/dist/_chunks/vendor-client.js +1 -1
- package/dist/_chunks/vendor-utils.js +1 -1
- package/dist/ai/block-renderer.js +7 -7
- package/dist/ai/blocks/error.js +1 -1
- package/dist/ai/blocks/index.js +2 -2
- package/dist/ai/blocks/text.js +1 -1
- package/dist/ai/command-bar.js +6 -6
- package/dist/ai/conversation.js +2 -2
- package/dist/ai/index.js +3 -3
- package/dist/composed/avatar-group.js +1 -1
- package/dist/composed/bulk-action-bar.js +1 -1
- package/dist/composed/command-palette.js +9 -9
- package/dist/composed/command-palette.js.map +1 -1
- package/dist/composed/confirm-dialog.js +3 -3
- package/dist/composed/confirm-dialog.js.map +1 -1
- package/dist/composed/content-card.js +1 -1
- package/dist/composed/date-picker/index.js +13 -13
- package/dist/composed/date-picker/index.js.map +1 -1
- package/dist/composed/emoji-picker.js +4 -4
- package/dist/composed/empty-state.js +1 -1
- package/dist/composed/error-boundary.js +1 -1
- package/dist/composed/error-boundary.js.map +1 -1
- package/dist/composed/extensions/emoji-node.js +1 -1
- package/dist/composed/extensions/emoji-suggestion.js +1 -1
- package/dist/composed/file-preview.js +14 -14
- package/dist/composed/filter-bar.js +1 -1
- package/dist/composed/index.d.ts +3 -1
- package/dist/composed/index.d.ts.map +1 -1
- package/dist/composed/index.js +4 -3
- package/dist/composed/loading-skeleton.js +15 -15
- package/dist/composed/loading-skeleton.js.map +1 -1
- package/dist/composed/multi-select-popover.js +3 -3
- package/dist/composed/page-header.d.ts.map +1 -1
- package/dist/composed/page-header.js +32 -45
- package/dist/composed/page-header.js.map +1 -1
- package/dist/composed/page-skeletons.js +19 -19
- package/dist/composed/page-skeletons.js.map +1 -1
- package/dist/composed/priority-indicator.js +1 -1
- package/dist/composed/responsive-modal.d.ts +39 -0
- package/dist/composed/responsive-modal.d.ts.map +1 -0
- package/dist/composed/responsive-modal.js +212 -0
- package/dist/composed/responsive-modal.js.map +1 -0
- package/dist/composed/rich-chat-input.js +445 -445
- package/dist/composed/rich-chat-input.js.map +1 -1
- package/dist/composed/rich-text-editor.js +29 -29
- package/dist/composed/rich-text-editor.js.map +1 -1
- package/dist/composed/schedule-view.d.ts +1 -1
- package/dist/composed/schedule-view.d.ts.map +1 -1
- package/dist/composed/schedule-view.js +48 -54
- package/dist/composed/schedule-view.js.map +1 -1
- package/dist/composed/status-badge.d.ts +13 -11
- package/dist/composed/status-badge.d.ts.map +1 -1
- package/dist/composed/status-badge.js +54 -130
- package/dist/composed/status-badge.js.map +1 -1
- package/dist/motion/index.js +2 -2
- package/dist/shell/bottom-navbar.js +3 -3
- package/dist/shell/bottom-navbar.js.map +1 -1
- package/dist/shell/index.js +2 -2
- package/dist/shell/link-context.js +2 -2
- package/dist/shell/notification-center.js +3 -3
- package/dist/shell/sidebar.js +2 -2
- package/dist/shell/top-bar.js +2 -2
- package/dist/shell/top-bar.js.map +1 -1
- package/dist/tokens/semantic.css +8 -1
- package/dist/ui/accordion.js +11 -11
- package/dist/ui/alert-dialog.js +34 -34
- package/dist/ui/alert.js +1 -1
- package/dist/ui/aspect-ratio.js +1 -1
- package/dist/ui/autocomplete.js +7 -7
- package/dist/ui/avatar.d.ts.map +1 -1
- package/dist/ui/avatar.js +84 -79
- package/dist/ui/avatar.js.map +1 -1
- package/dist/ui/badge-group.js +1 -1
- package/dist/ui/badge.d.ts.map +1 -1
- package/dist/ui/badge.js +1 -1
- package/dist/ui/banner.js +1 -1
- package/dist/ui/breadcrumb.d.ts +0 -1
- package/dist/ui/breadcrumb.d.ts.map +1 -1
- package/dist/ui/breadcrumb.js +58 -35
- package/dist/ui/breadcrumb.js.map +1 -1
- package/dist/ui/button.js +3 -3
- package/dist/ui/card.js +1 -1
- package/dist/ui/charts/area-chart.js +6 -6
- package/dist/ui/charts/bar-chart.js +6 -6
- package/dist/ui/charts/chart-container.js +1 -1
- package/dist/ui/charts/gauge-chart.js +2 -2
- package/dist/ui/charts/index.js +2 -2
- package/dist/ui/charts/line-chart.js +6 -6
- package/dist/ui/charts/pie-chart.js +5 -5
- package/dist/ui/charts/radar-chart.js +5 -5
- package/dist/ui/charts/sparkline.js +2 -2
- package/dist/ui/chat/index.js +2 -2
- package/dist/ui/checkbox.d.ts +4 -2
- package/dist/ui/checkbox.d.ts.map +1 -1
- package/dist/ui/checkbox.js +33 -28
- package/dist/ui/checkbox.js.map +1 -1
- package/dist/ui/collapsible.js +5 -5
- package/dist/ui/color-input.js +4 -4
- package/dist/ui/combobox.d.ts +3 -0
- package/dist/ui/combobox.d.ts.map +1 -1
- package/dist/ui/combobox.js +137 -132
- package/dist/ui/combobox.js.map +1 -1
- package/dist/ui/context-menu.js +32 -32
- package/dist/ui/dialog.d.ts.map +1 -1
- package/dist/ui/dialog.js +49 -46
- package/dist/ui/dialog.js.map +1 -1
- package/dist/ui/dot.d.ts +38 -0
- package/dist/ui/dot.d.ts.map +1 -0
- package/dist/ui/dot.js +92 -0
- package/dist/ui/dot.js.map +1 -0
- package/dist/ui/dropdown-menu.d.ts.map +1 -1
- package/dist/ui/dropdown-menu.js +81 -76
- package/dist/ui/dropdown-menu.js.map +1 -1
- package/dist/ui/hover-card.js +6 -6
- package/dist/ui/icon-button.js +1 -1
- package/dist/ui/index.d.ts +3 -2
- package/dist/ui/index.d.ts.map +1 -1
- package/dist/ui/index.js +67 -67
- package/dist/ui/index.js.map +1 -1
- package/dist/ui/input-otp.js +1 -1
- package/dist/ui/input-otp.js.map +1 -1
- package/dist/ui/input.d.ts +4 -2
- package/dist/ui/input.d.ts.map +1 -1
- package/dist/ui/input.js +39 -38
- package/dist/ui/input.js.map +1 -1
- package/dist/ui/label.js +1 -1
- package/dist/ui/lib/field-state.d.ts +21 -0
- package/dist/ui/lib/field-state.d.ts.map +1 -0
- package/dist/ui/lib/use-controllable-open.d.ts +32 -0
- package/dist/ui/lib/use-controllable-open.d.ts.map +1 -0
- package/dist/ui/lib/utils.js +4 -4
- package/dist/ui/link.js +1 -1
- package/dist/ui/menubar.js +53 -53
- package/dist/ui/navigation-menu.js +27 -27
- package/dist/ui/number-input.d.ts +4 -2
- package/dist/ui/number-input.d.ts.map +1 -1
- package/dist/ui/number-input.js +52 -51
- package/dist/ui/number-input.js.map +1 -1
- package/dist/ui/oauth-button/index.js +2 -2
- package/dist/ui/pagination.js +1 -1
- package/dist/ui/popover.d.ts.map +1 -1
- package/dist/ui/popover.js +2 -2
- package/dist/ui/progress.d.ts +66 -42
- package/dist/ui/progress.d.ts.map +1 -1
- package/dist/ui/progress.js +144 -40
- package/dist/ui/progress.js.map +1 -1
- package/dist/ui/radio.d.ts +6 -2
- package/dist/ui/radio.d.ts.map +1 -1
- package/dist/ui/radio.js +44 -33
- package/dist/ui/radio.js.map +1 -1
- package/dist/ui/segmented-control.js +1 -1
- package/dist/ui/select.d.ts +1 -1
- package/dist/ui/select.d.ts.map +1 -1
- package/dist/ui/select.js +56 -55
- package/dist/ui/select.js.map +1 -1
- package/dist/ui/separator.js +2 -2
- package/dist/ui/separator.js.map +1 -1
- package/dist/ui/sheet.d.ts.map +1 -1
- package/dist/ui/sheet.js +56 -53
- package/dist/ui/sheet.js.map +1 -1
- package/dist/ui/sidebar.js +6 -6
- package/dist/ui/sidebar.js.map +1 -1
- package/dist/ui/skeleton.js +1 -1
- package/dist/ui/slider.js +8 -8
- package/dist/ui/slider.js.map +1 -1
- package/dist/ui/split-button.js +3 -3
- package/dist/ui/stat-card.d.ts.map +1 -1
- package/dist/ui/stat-card.js +123 -126
- package/dist/ui/stat-card.js.map +1 -1
- package/dist/ui/stat-flash.js +1 -1
- package/dist/ui/stepper.js +1 -1
- package/dist/ui/surface.js +2 -2
- package/dist/ui/switch.d.ts +3 -1
- package/dist/ui/switch.d.ts.map +1 -1
- package/dist/ui/switch.js +32 -27
- package/dist/ui/switch.js.map +1 -1
- package/dist/ui/table-row-link.js +1 -1
- package/dist/ui/tabs.js +13 -13
- package/dist/ui/text.js +1 -1
- package/dist/ui/textarea.d.ts +3 -3
- package/dist/ui/textarea.d.ts.map +1 -1
- package/dist/ui/textarea.js +19 -18
- package/dist/ui/textarea.js.map +1 -1
- package/dist/ui/toast.js +2 -2
- package/dist/ui/toast.js.map +1 -1
- package/dist/ui/toggle-group.js +1 -1
- package/dist/ui/toggle.js +2 -2
- package/dist/ui/tooltip.d.ts.map +1 -1
- package/dist/ui/tooltip.js +37 -34
- package/dist/ui/tooltip.js.map +1 -1
- package/dist/ui/tree-view/index.js +2 -2
- package/docs/components/ai/ai-command-provider.md +46 -0
- package/docs/components/ai/block-renderer.md +59 -0
- package/docs/components/ai/command-bar.md +78 -0
- package/docs/components/ai/conversation.md +59 -0
- package/docs/components/ai/devadoot-icon.md +41 -0
- package/docs/components/composed/page-header.md +1 -1
- package/docs/components/composed/responsive-modal.md +66 -0
- package/docs/components/composed/schedule-view.md +6 -2
- package/docs/components/ui/breadcrumb.md +1 -1
- package/docs/components/ui/checkbox.md +4 -1
- package/docs/components/ui/combobox.md +4 -0
- package/docs/components/ui/dot.md +61 -0
- package/docs/components/ui/progress.md +54 -16
- package/docs/components/ui/radio.md +6 -2
- package/docs/components/ui/select.md +9 -5
- package/docs/components/ui/switch.md +4 -1
- package/docs/components/ui/table.md +2 -1
- package/llms.txt +11 -3
- package/make-kit/components/form.md +2 -2
- package/make-kit/components/icon.md +2 -2
- package/make-kit/components/overview.md +2 -2
- package/make-kit/components/select.md +1 -1
- package/make-kit/components/table.md +1 -1
- package/mcp-manifest.json +2656 -1068
- package/mcp-manifest.schema.json +18 -0
- package/package.json +11 -6
- package/skill/SKILL.md +1 -1
- package/skill/references/components.md +11 -3
- package/dist/ui/status-dot.d.ts +0 -27
- package/dist/ui/status-dot.d.ts.map +0 -1
- package/dist/ui/status-dot.js +0 -68
- package/dist/ui/status-dot.js.map +0 -1
- package/docs/components/ui/status-dot.md +0 -35
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
# Dot
|
|
2
|
+
|
|
3
|
+
- Import: @devalok/shilp-sutra/ui/dot
|
|
4
|
+
- Server-safe: No
|
|
5
|
+
- Category: ui
|
|
6
|
+
|
|
7
|
+
A small semantic status/indicator dot — the low-level primitive behind status
|
|
8
|
+
pills, presence indicators, legend swatches, and `StatusDot`. Intent-coloured,
|
|
9
|
+
sized, optionally pulsing, filled or ring.
|
|
10
|
+
|
|
11
|
+
## Props
|
|
12
|
+
color: "accent" | "success" | "warning" | "error" | "info" | "neutral" | "current" (intent colour; `current` inherits text colour)
|
|
13
|
+
size: "xs" | "sm" | "md" | "lg"
|
|
14
|
+
variant: "filled" | "ring" | "off" (`off` = faint fill + light border, i.e. inactive)
|
|
15
|
+
withBorder: boolean (contrast ring so the dot stays visible on busy/coloured backgrounds)
|
|
16
|
+
pulse: boolean (animate a pulsing ripple; ignored for `off`)
|
|
17
|
+
pulseSpeed: "slow" | "normal" | "fast" (pulse tempo)
|
|
18
|
+
label: ReactNode (inline text; makes the dot an announced status)
|
|
19
|
+
labelPosition: "start" | "end" (which side the label sits on)
|
|
20
|
+
labelClassName: string
|
|
21
|
+
|
|
22
|
+
## Defaults
|
|
23
|
+
color: "neutral"
|
|
24
|
+
size: "md"
|
|
25
|
+
variant: "filled"
|
|
26
|
+
withBorder: false
|
|
27
|
+
pulse: false
|
|
28
|
+
pulseSpeed: "normal"
|
|
29
|
+
labelPosition: "end"
|
|
30
|
+
|
|
31
|
+
## Example
|
|
32
|
+
```jsx
|
|
33
|
+
<Dot color="success" /> {/* bare, decorative */}
|
|
34
|
+
<Dot color="error" pulse pulseSpeed="fast" label="Recording" /> {/* pulsing + announced */}
|
|
35
|
+
<Dot color="neutral" variant="off" label="Offline" /> {/* inactive: faint fill + light border */}
|
|
36
|
+
<Dot color="success" withBorder /> {/* contrast ring for busy backgrounds */}
|
|
37
|
+
<Dot color="accent" label="3 online" labelPosition="start" /> {/* label before the dot */}
|
|
38
|
+
<Dot color="neutral" variant="ring" size="lg" /> {/* hollow ring */}
|
|
39
|
+
|
|
40
|
+
// As leading content in a pill:
|
|
41
|
+
<Badge variant="soft" color="warning" startIcon={<Dot color="warning" size="sm" />}>
|
|
42
|
+
Pending
|
|
43
|
+
</Badge>
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
## Composability
|
|
47
|
+
- **Decorative vs announced.** A bare `<Dot>` is `aria-hidden` (the surrounding element carries meaning — e.g. a Badge's text). Pass a `label` (or `aria-label`) to make it a `role="status"` announced indicator.
|
|
48
|
+
- **Intent colour, shared vocabulary.** `color` uses the same intent names as the rest of the system (`accent/success/warning/error/info/neutral`), so a Dot next to a Badge/Button of the same intent matches.
|
|
49
|
+
- **`pulse` = "live".** Off by default (static status). Turn it on for active/attention states (recording, live, connecting) — a pulsing dot reads as "happening now", so leave it off for settled statuses.
|
|
50
|
+
- **Powers the higher-level pieces.** `StatusBadge` composes `<Badge>` + `<Dot>`; use `Dot` directly anywhere you need a coloured indicator without a pill.
|
|
51
|
+
- **Three treatments:** `filled` (active), `ring` (hollow outline), `off` (faint same-tone fill + light border — present but inactive/disabled).
|
|
52
|
+
- **`withBorder`** adds a contrast ring (`ring-2 ring-surface-raised`) so the dot reads on avatars, images, or coloured fills — the pattern Avatar's status dot uses.
|
|
53
|
+
- **`pulseSpeed`** (slow/normal/fast) tunes the pulse tempo — fast for urgent (recording), slow for ambient (syncing).
|
|
54
|
+
|
|
55
|
+
## Gotchas
|
|
56
|
+
- A bare dot is decorative by design — if a dot is the *only* signal (no adjacent text), give it a `label` or `aria-label` so it's announced.
|
|
57
|
+
- `pulse` respects `prefers-reduced-motion` (the ripple is disabled).
|
|
58
|
+
|
|
59
|
+
## Changes
|
|
60
|
+
### v0.49.0
|
|
61
|
+
- **Added** Initial release. Extracted as the shared primitive behind `StatusDot`, `StatusBadge`, and `Badge`'s dot. Colours `accent/success/warning/error/info/neutral/current`; sizes `xs–lg`; variants `filled/ring/off`; `withBorder` contrast ring; `pulse` + `pulseSpeed`; `label` + `labelPosition`.
|
|
@@ -4,38 +4,76 @@
|
|
|
4
4
|
- Server-safe: No
|
|
5
5
|
- Category: ui
|
|
6
6
|
|
|
7
|
+
A linear progress bar. Use the smart all-in-one `<Progress value={70} />` for the
|
|
8
|
+
common cases, or the compound parts (`Progress.Root` / `Track` / `Indicator` /
|
|
9
|
+
`Segment` / `Label` / `Value`) for full layout control and multi-segment bars.
|
|
10
|
+
|
|
7
11
|
## Props
|
|
8
|
-
value: number (0
|
|
12
|
+
value: number | null (0–max) — omit or null for an indeterminate bar
|
|
13
|
+
max: number (scale maximum, default 100)
|
|
9
14
|
size: "sm" | "md" | "lg" (track height)
|
|
10
|
-
color: "
|
|
11
|
-
autoColor: boolean (auto-
|
|
12
|
-
|
|
13
|
-
|
|
15
|
+
color: "accent" | "success" | "warning" | "error" (indicator color)
|
|
16
|
+
autoColor: boolean (auto-shift color by value: 0-59=accent, 60-84=warning, 85-100=success, >100=error)
|
|
17
|
+
label: ReactNode (descriptive label rendered before the bar; names the bar for a11y)
|
|
18
|
+
showValue: boolean (shows the "{n}%" readout after the bar)
|
|
19
|
+
segments: { value: number; color?: "accent" | "success" | "warning" | "error" }[] (multi-segment bar; overrides the single indicator)
|
|
20
|
+
trackClassName: string (class for the Track element)
|
|
21
|
+
indicatorClassName: string (class for the single Indicator; ignored when segments set)
|
|
22
|
+
|
|
23
|
+
## Compound Components
|
|
24
|
+
Progress (smart all-in-one — value/size/color/label/showValue/autoColor/segments)
|
|
25
|
+
Progress.Root (layout container + context; owns value/max/size)
|
|
26
|
+
Progress.Label (descriptive label; give it id + point Track's aria-labelledby at it)
|
|
27
|
+
Progress.Track (the aria progressbar + track visual; holds Indicator or Segments)
|
|
28
|
+
Progress.Indicator (single fill; color, or auto-color by value)
|
|
29
|
+
Progress.Segment (one slice of a multi-segment bar — value + color)
|
|
30
|
+
Progress.Value (the "{n}%" readout; custom via children or a `format` fn)
|
|
14
31
|
|
|
15
32
|
## Defaults
|
|
16
33
|
size: "md"
|
|
17
|
-
color: "
|
|
34
|
+
color: "accent"
|
|
35
|
+
max: 100
|
|
18
36
|
|
|
19
37
|
## Example
|
|
20
38
|
```jsx
|
|
21
|
-
|
|
22
|
-
<Progress
|
|
39
|
+
// Simple:
|
|
40
|
+
<Progress value={75} color="success" showValue />
|
|
41
|
+
<Progress size="sm" /> {/* indeterminate */}
|
|
42
|
+
<Progress value={80} autoColor showValue /> {/* color follows value */}
|
|
43
|
+
|
|
44
|
+
// Multi-segment (Mantine-style):
|
|
45
|
+
<Progress segments={[{ value: 40, color: 'success' }, { value: 30, color: 'warning' }]} />
|
|
46
|
+
|
|
47
|
+
// Compound — full control:
|
|
48
|
+
<Progress.Root value={62} size="lg">
|
|
49
|
+
<Progress.Label id="storage-lbl">Storage</Progress.Label>
|
|
50
|
+
<Progress.Track aria-labelledby="storage-lbl">
|
|
51
|
+
<Progress.Indicator color="warning" />
|
|
52
|
+
</Progress.Track>
|
|
53
|
+
<Progress.Value format={(pct) => `${pct}% of 50 GB`} />
|
|
54
|
+
</Progress.Root>
|
|
23
55
|
```
|
|
24
56
|
|
|
25
57
|
## Composability
|
|
26
|
-
- **
|
|
27
|
-
- **
|
|
28
|
-
- **
|
|
29
|
-
- **
|
|
30
|
-
- **
|
|
58
|
+
- **Two APIs, one component.** The smart `<Progress>` composes the parts for you; reach for the compound parts when you need a custom layout (label above the bar, value inside, multiple bars) or multi-segment fills. Structure follows Ark UI / Chakra; `Progress.Segment` follows Mantine.
|
|
59
|
+
- **`Progress.Track` is the accessible progressbar** (role=progressbar, aria-valuenow/min/max from `Root`'s value). Give it a name via `aria-label`, or a `Progress.Label` + matching `aria-labelledby`. The smart form wires this from the `label` prop / a passed `aria-label` automatically.
|
|
60
|
+
- **autoColor semantic signal:** maps value thresholds to color (0–59 accent · 60–84 warning · 85–100 success · >100 error) — storage meters, budget trackers, goal progress. Pass an explicit `color` to opt out.
|
|
61
|
+
- **Segments** render side-by-side, each `value` as a % of `max`; the Track's aria value still reflects `Root`'s `value`.
|
|
62
|
+
- **Indeterminate:** omit `value` (or pass `null`) for the continuous sweep. Motion-reduced users get a static bar.
|
|
63
|
+
- **Progress vs ProgressRing:** Progress is linear; `ProgressRing` is circular (with multi-ring stacked variants).
|
|
31
64
|
|
|
32
65
|
## Gotchas
|
|
33
|
-
- Omit value (or pass
|
|
34
|
-
-
|
|
66
|
+
- Omit `value` (or pass `null`) for indeterminate.
|
|
67
|
+
- Pass an explicit `color` to override `autoColor`.
|
|
68
|
+
- Compound `Progress.Track` needs a name — an `aria-label`, or a `Progress.Label` whose `id` the Track's `aria-labelledby` points to. A Track with neither is an unnamed progressbar (axe will flag it).
|
|
69
|
+
- `Progress.Indicator` / `Segment` / `Value` throw if rendered outside `Progress.Root`.
|
|
35
70
|
|
|
36
71
|
## Changes
|
|
72
|
+
### v0.49.0
|
|
73
|
+
- **BREAKING** Progress redesigned as a compound component. Renamed `showLabel` → `showValue`. The `color` neutral value `"default"` → `"accent"` (the type is now `"accent" | "success" | "warning" | "error"`). Added compound parts (`Progress.Root/Track/Indicator/Segment/Label/Value`), a `label` prop, a `max` prop, a `segments` prop (multi-segment bars), and `trackClassName`. Migrate `showLabel` → `showValue` and `color="default"` → `color="accent"` (or drop it — accent is the default).
|
|
74
|
+
|
|
37
75
|
### v0.29.0
|
|
38
|
-
- **Added** `autoColor` prop — automatically shifts indicator color based on value thresholds
|
|
76
|
+
- **Added** `autoColor` prop — automatically shifts indicator color based on value thresholds
|
|
39
77
|
|
|
40
78
|
### v0.1.0
|
|
41
79
|
- **Added** Initial release with `size`, `color`, `indeterminate` variants and optional label slot
|
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
disabled: boolean (propagates to all items)
|
|
13
13
|
orientation: "horizontal" | "vertical"
|
|
14
14
|
name: string (form name for all items)
|
|
15
|
+
state: "default" | "error" | "warning" | "success" (validation; sets aria-invalid on the group + tints item borders. Inherited from FormField when omitted)
|
|
15
16
|
|
|
16
17
|
### RadioGroupItem
|
|
17
18
|
value: string (REQUIRED — what's selected when this item is checked)
|
|
@@ -44,14 +45,17 @@
|
|
|
44
45
|
- **RadioGroup propagates** `disabled` to every RadioGroupItem; items can opt back in with `disabled={false}` for granular control (rare).
|
|
45
46
|
- **Labels:** RadioGroupItem has no intrinsic label — pair each with `<Label htmlFor="x" />` + `<RadioGroupItem id="x" value="..." />`. Screen readers announce the group label (from FormField or aria-labelledby on RadioGroup) plus each item's label.
|
|
46
47
|
- **Form libraries:** RadioGroup works with react-hook-form via Controller (onValueChange maps to field.onChange). The `name` prop puts a hidden form input per item for native form serialization.
|
|
47
|
-
- **FormField integration:** RadioGroup
|
|
48
|
+
- **FormField integration:** RadioGroup now consumes FormField state (or set `state` explicitly). It sets `aria-invalid` on the group and tints each item's border to match — unified with the other form controls via the shared `FieldState` type. An explicit `state` prop wins over FormField context.
|
|
48
49
|
|
|
49
50
|
## Gotchas
|
|
50
51
|
- Each RadioGroupItem needs a unique `value` prop
|
|
51
52
|
- Pair each item with a Label for accessibility
|
|
52
|
-
- RadioGroup
|
|
53
|
+
- RadioGroup inherits FormField state; pass `state` explicitly to override
|
|
53
54
|
|
|
54
55
|
## Changes
|
|
56
|
+
### v0.49.0
|
|
57
|
+
- **Added** `state` prop on RadioGroup (`FieldState = "default" | "error" | "warning" | "success"`) — unified field-state API. Sets `aria-invalid` + tints item borders, and now inherits from `FormField` context.
|
|
58
|
+
|
|
55
59
|
### v0.4.2
|
|
56
60
|
- **Added** `RadioGroupProps`, `RadioGroupItemProps` type exports
|
|
57
61
|
|
|
@@ -7,12 +7,12 @@
|
|
|
7
7
|
## Props
|
|
8
8
|
### SelectTrigger
|
|
9
9
|
variant: "default" | "outline" | "ghost"
|
|
10
|
-
|
|
10
|
+
state: "default" | "error" | "warning" | "success" (validation; sets aria-invalid when error. Inherited from FormField when omitted)
|
|
11
11
|
size: "xs" | "sm" | "md" | "lg"
|
|
12
12
|
|
|
13
13
|
## Compound Components
|
|
14
14
|
Select (root — value, onValueChange, defaultValue)
|
|
15
|
-
SelectTrigger (variant/
|
|
15
|
+
SelectTrigger (variant/state/size go HERE, not on Select root)
|
|
16
16
|
SelectValue (placeholder)
|
|
17
17
|
SelectContent
|
|
18
18
|
SelectGroup (optional grouping)
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
SelectSeparator
|
|
22
22
|
|
|
23
23
|
## Defaults
|
|
24
|
-
SelectTrigger variant="default",
|
|
24
|
+
SelectTrigger variant="default", state="default", size="md"
|
|
25
25
|
|
|
26
26
|
## Example
|
|
27
27
|
```jsx
|
|
@@ -38,10 +38,10 @@
|
|
|
38
38
|
|
|
39
39
|
## Composability
|
|
40
40
|
- **Radix Select** underneath — `value`/`onValueChange`/`defaultValue`/`open`/`onOpenChange` standard state.
|
|
41
|
-
- **Styling props live on SelectTrigger, not Select root.** The Select root owns value/state; the Trigger owns appearance (variant/
|
|
41
|
+
- **Styling props live on SelectTrigger, not Select root.** The Select root owns value/state; the Trigger owns appearance (variant/state/size). Setting `<Select size="lg">` silently does nothing — TypeScript won't catch it.
|
|
42
42
|
- **SelectItem requires `value`** — unique within the Select. Labels are the children of SelectItem.
|
|
43
43
|
- **SelectGroup + SelectLabel:** Organize options into sections with a non-interactive section heading.
|
|
44
|
-
- **FormField integration:** Set `
|
|
44
|
+
- **FormField integration:** Set `state="error"` on SelectTrigger for error visuals, or omit it inside a `<FormField state="error">` — SelectTrigger now inherits the field state from context (explicit `state` prop wins). Unified with Input/Textarea/Checkbox/Radio/Switch/Combobox via the shared `FieldState` type.
|
|
45
45
|
- **Portal + z-popover (1400):** content portals to body, stacks above Dialog/Sheet/other overlays.
|
|
46
46
|
- **Select vs Combobox vs Autocomplete:** Select = short fixed list, click-to-open, no typeahead. Combobox = searchable, forced selection. Autocomplete = searchable, free text. Pick by list size and search need.
|
|
47
47
|
|
|
@@ -50,6 +50,10 @@
|
|
|
50
50
|
- `<Select size="lg">` is silently ignored (no TypeScript error)
|
|
51
51
|
|
|
52
52
|
## Changes
|
|
53
|
+
### v0.49.0
|
|
54
|
+
- **BREAKING** Renamed the SelectTrigger `color` prop → `state` (unified field-state API across all form controls; type `FieldState = "default" | "error" | "warning" | "success"`). Migrate `<SelectTrigger color="error">` → `<SelectTrigger state="error">`.
|
|
55
|
+
- **Added** SelectTrigger now inherits validation state from `FormField` context (was manual-only before).
|
|
56
|
+
|
|
53
57
|
### v0.31.0
|
|
54
58
|
- **Added** `variant` prop on SelectTrigger: `default | outline | ghost`
|
|
55
59
|
- **Added** `color` prop on SelectTrigger: `default | error | success | warning`. Sets `aria-invalid` when error.
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
## Props
|
|
8
8
|
checked: boolean
|
|
9
9
|
onCheckedChange: (checked: boolean) => void
|
|
10
|
-
|
|
10
|
+
state: "default" | "error" | "warning" | "success" (validation border/checked-track tint; error sets aria-invalid. Inherited from FormField when omitted. Distinct from `color`, the ON-track tint)
|
|
11
11
|
disabled: boolean
|
|
12
12
|
size: "sm" | "md" | "lg"
|
|
13
13
|
color: "accent" | "success" | "warning"
|
|
@@ -35,6 +35,9 @@
|
|
|
35
35
|
- Switch does NOT auto-consume FormField — pass `error` explicitly inside a FormField
|
|
36
36
|
|
|
37
37
|
## Changes
|
|
38
|
+
### v0.49.0
|
|
39
|
+
- **BREAKING** Removed the `error: boolean` prop; use `state` (`FieldState = "default" | "error" | "warning" | "success"`). Migrate `<Switch error />` → `<Switch state="error" />`. Gains `warning`/`success` and inherits from `FormField`. (`color` is unchanged — it's the ON-track tint, not validation.)
|
|
40
|
+
|
|
38
41
|
### v0.29.0
|
|
39
42
|
- **Added** `size` prop: `"sm"` (18px track) | `"md"` (24px, default) | `"lg"` (28px track)
|
|
40
43
|
- **Added** `color` prop: `"accent"` (default) | `"success"` | `"warning"` for checked-state color
|
|
@@ -16,7 +16,8 @@
|
|
|
16
16
|
Reveal is opacity-based: buttons stay in the tab order permanently, appear on row hover AND :focus-within, and are always visible on touch (pointer-coarse). Give the column a visually-hidden header.
|
|
17
17
|
|
|
18
18
|
### TableRowLink (separate import: ui/table-row-link — client component)
|
|
19
|
-
href: string (required)
|
|
19
|
+
href: string (required)
|
|
20
|
+
stretch: boolean (default: true)
|
|
20
21
|
A real anchor placed in the row's primary cell (`<TableCell className="relative">`), stretched across the row via a pseudo-element — cmd/ctrl+click, middle-click, and context menu work, unlike onClick-on-row. Keyboard focus draws a row-level ring. Other interactive elements in the row need `className="relative z-[1]"`. `stretch={false}` = title-only link (keeps row text selectable).
|
|
21
22
|
|
|
22
23
|
## Compound Components
|
package/llms.txt
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @devalok/shilp-sutra
|
|
2
2
|
|
|
3
|
-
> Radix UI + Tailwind 4 (CSS-first) + CVA design system for Devalok apps, v0.
|
|
3
|
+
> Radix UI + Tailwind 4 (CSS-first) + CVA design system for Devalok apps, v0.49.1.
|
|
4
4
|
> Built on the same primitives as shadcn/ui but with DIFFERENT prop APIs — never guess from shadcn knowledge; verify every prop.
|
|
5
5
|
> This file is a ROUTER: it tells you what exists and where to get details. Do not look for prop tables here — fetch them per component (MCP tool or per-component doc file below).
|
|
6
6
|
|
|
@@ -65,6 +65,7 @@ Format: `[name](doc path): summary`. Import paths follow `@devalok/shilp-sutra/<
|
|
|
65
65
|
- [data-table-toolbar](docs/components/ui/data-table-toolbar.md)
|
|
66
66
|
- [devalok-grain](docs/components/ui/devalok-grain.md)
|
|
67
67
|
- [dialog](docs/components/ui/dialog.md)
|
|
68
|
+
- [dot](docs/components/ui/dot.md): A small semantic status/indicator dot — the low-level primitive behind status pills, presence indicators, legend swatches, and `StatusDot`
|
|
68
69
|
- [dropdown-menu](docs/components/ui/dropdown-menu.md)
|
|
69
70
|
- [file-upload](docs/components/ui/file-upload.md)
|
|
70
71
|
- [form](docs/components/ui/form.md)
|
|
@@ -83,7 +84,7 @@ Format: `[name](doc path): summary`. Import paths follow `@devalok/shilp-sutra/<
|
|
|
83
84
|
- [oauth-button](docs/components/ui/oauth-button.md)
|
|
84
85
|
- [pagination](docs/components/ui/pagination.md)
|
|
85
86
|
- [popover](docs/components/ui/popover.md)
|
|
86
|
-
- [progress](docs/components/ui/progress.md)
|
|
87
|
+
- [progress](docs/components/ui/progress.md): A linear progress bar
|
|
87
88
|
- [progress-ring](docs/components/ui/progress-ring.md)
|
|
88
89
|
- [radio](docs/components/ui/radio.md)
|
|
89
90
|
- [search-input](docs/components/ui/search-input.md)
|
|
@@ -98,7 +99,6 @@ Format: `[name](doc path): summary`. Import paths follow `@devalok/shilp-sutra/<
|
|
|
98
99
|
- [stack](docs/components/ui/stack.md)
|
|
99
100
|
- [stat-card](docs/components/ui/stat-card.md)
|
|
100
101
|
- [stat-flash](docs/components/ui/stat-flash.md)
|
|
101
|
-
- [status-dot](docs/components/ui/status-dot.md)
|
|
102
102
|
- [stepper](docs/components/ui/stepper.md)
|
|
103
103
|
- [surface](docs/components/ui/surface.md): The low-level elevated container primitive
|
|
104
104
|
- [switch](docs/components/ui/switch.md)
|
|
@@ -141,6 +141,7 @@ Format: `[name](doc path): summary`. Import paths follow `@devalok/shilp-sutra/<
|
|
|
141
141
|
- [page-header](docs/components/composed/page-header.md)
|
|
142
142
|
- [page-skeletons](docs/components/composed/page-skeletons.md): Exports: DashboardSkeleton, ProjectListSkeleton, TaskDetailSkeleton
|
|
143
143
|
- [priority-indicator](docs/components/composed/priority-indicator.md)
|
|
144
|
+
- [responsive-modal](docs/components/composed/responsive-modal.md)
|
|
144
145
|
- [rich-chat-input](docs/components/composed/rich-chat-input.md): Compact rich text chat input for unified human+AI workspaces
|
|
145
146
|
- [rich-text-editor](docs/components/composed/rich-text-editor.md): Exports: RichTextEditor, RichTextViewer
|
|
146
147
|
- [schedule-view](docs/components/composed/schedule-view.md)
|
|
@@ -157,6 +158,13 @@ Format: `[name](doc path): summary`. Import paths follow `@devalok/shilp-sutra/<
|
|
|
157
158
|
- [sidebar](docs/components/shell/sidebar.md)
|
|
158
159
|
- [top-bar](docs/components/shell/top-bar.md)
|
|
159
160
|
|
|
161
|
+
### ai
|
|
162
|
+
- [ai-command-provider](docs/components/ai/ai-command-provider.md): Context provider for the AI command system
|
|
163
|
+
- [block-renderer](docs/components/ai/block-renderer.md): Renders an ordered list of typed AI "blocks" — the structured chunks an assistant/ server emits instead of plain text
|
|
164
|
+
- [command-bar](docs/components/ai/command-bar.md): A unified AI command input with three layout variants
|
|
165
|
+
- [conversation](docs/components/ai/conversation.md): A scrollable AI conversation thread: user + assistant turns, streaming processing steps, an agent header, and structured content blocks (rendered via BlockRenderer) with confirm/cancel/undo action support
|
|
166
|
+
- [devadoot-icon](docs/components/ai/devadoot-icon.md): The animated Devalok chakra glyph — the visual identity for the AI command system
|
|
167
|
+
|
|
160
168
|
## Tokens
|
|
161
169
|
|
|
162
170
|
Categories: color, spacing (`ds-01`…), typography (`text-ds-*`), radius (`rounded-ds-*`), shadow (`shadow-raised`/`shadow-overlay`/…), motion, z-layers. Full reference: `get_tokens(category)` via MCP, or the `tokens` object in `mcp-manifest.json`.
|
|
@@ -69,7 +69,7 @@ Use inside a custom control to consume FormField context.
|
|
|
69
69
|
|
|
70
70
|
| Control | Manual wiring needed |
|
|
71
71
|
|---|---|
|
|
72
|
-
| `<Select>` / `<SelectTrigger>` | Set `
|
|
72
|
+
| `<Select>` / `<SelectTrigger>` | Set `state="error"` on `SelectTrigger` from your validation state. |
|
|
73
73
|
| `<Checkbox>`, `<Radio>`, `<Switch>` | Pair `<Label htmlFor>` manually. State is visual on the control. |
|
|
74
74
|
|
|
75
75
|
## Examples
|
|
@@ -134,7 +134,7 @@ The Input receives `aria-describedby` (linked to FormHelperText), `aria-invalid=
|
|
|
134
134
|
<FormField state={errors.role ? 'error' : 'helper'}>
|
|
135
135
|
<Label htmlFor="role">Role</Label>
|
|
136
136
|
<Select>
|
|
137
|
-
<SelectTrigger id="role"
|
|
137
|
+
<SelectTrigger id="role" state={errors.role ? 'error' : 'default'}>
|
|
138
138
|
<SelectValue placeholder="Choose a role" />
|
|
139
139
|
</SelectTrigger>
|
|
140
140
|
<SelectContent>
|
|
@@ -14,7 +14,7 @@ For the broader icon system (which icons exist, how to register custom ones, the
|
|
|
14
14
|
- Any inline SVG icon — inside Button slots, IconButton, Badge slots, table cells, list rows.
|
|
15
15
|
- Need an interactive icon button? Use `<IconButton>`, not Icon wrapped in `<button>`.
|
|
16
16
|
- Need a static cluster of related icons? Use `<IconGroup>`.
|
|
17
|
-
- Need a status indicator? Use `<
|
|
17
|
+
- Need a status indicator? Use `<Dot>` or `<Badge dot>` — they're optimized for that.
|
|
18
18
|
|
|
19
19
|
Tabler-only. Don't mix icon libraries — see `foundations/icons.md` for the rationale.
|
|
20
20
|
|
|
@@ -129,7 +129,7 @@ Input's IconProvider sets size by input size: `xs` / `sm` input → `sm` icon, `
|
|
|
129
129
|
</Stack>
|
|
130
130
|
```
|
|
131
131
|
|
|
132
|
-
For most status displays prefer `<
|
|
132
|
+
For most status displays prefer `<Dot>` — purpose-built. Use this pattern only when you need a specific icon shape.
|
|
133
133
|
|
|
134
134
|
## Composability
|
|
135
135
|
|
|
@@ -77,7 +77,7 @@ Permanent inline message?
|
|
|
77
77
|
Status of an item?
|
|
78
78
|
→ <Badge> — pill label (status / tag)
|
|
79
79
|
→ <StatusBadge> — colored dot + label (discriminated union: status="online"/"away"/...)
|
|
80
|
-
→ <
|
|
80
|
+
→ <Dot> — just the colored status/indicator dot
|
|
81
81
|
|
|
82
82
|
Temporary notification?
|
|
83
83
|
→ toast.success / error / warning / info (imperative) — must have <Toaster /> mounted
|
|
@@ -256,7 +256,7 @@ Code?
|
|
|
256
256
|
| Skeleton | `/ui/skeleton` |
|
|
257
257
|
| Badge | `/ui/badge` |
|
|
258
258
|
| StatusBadge | `/composed/status-badge` |
|
|
259
|
-
|
|
|
259
|
+
| Dot | `/ui/dot` |
|
|
260
260
|
| EmptyState | `/composed/empty-state` |
|
|
261
261
|
|
|
262
262
|
### Layout
|
|
@@ -98,7 +98,7 @@ Styling lives on the **Trigger**, not on `Select` root. Setting `<Select size="l
|
|
|
98
98
|
<FormField state={errors.role ? 'error' : 'helper'}>
|
|
99
99
|
<Label htmlFor="role">Role</Label>
|
|
100
100
|
<Select value={role} onValueChange={setRole}>
|
|
101
|
-
<SelectTrigger id="role"
|
|
101
|
+
<SelectTrigger id="role" state={errors.role ? 'error' : 'default'}>
|
|
102
102
|
<SelectValue placeholder="Choose a role" />
|
|
103
103
|
</SelectTrigger>
|
|
104
104
|
<SelectContent>
|
|
@@ -233,7 +233,7 @@ Table + Badge (server-safe via Badge.Group context — verify per use) + Avatar
|
|
|
233
233
|
|
|
234
234
|
- **Server-safe:** Table and its sub-components are pure HTML semantic wrappers. No state, no context. Use in RSC trees without `'use client'`.
|
|
235
235
|
- **TableHead scope:** Headers automatically get `scope="col"` for screen-reader navigation. Don't override it.
|
|
236
|
-
- **Composes with primitives:** Drop `<Badge>`, `<Avatar>`, `<IconButton>`, `<
|
|
236
|
+
- **Composes with primitives:** Drop `<Badge>`, `<Avatar>`, `<IconButton>`, `<Dot>` inside cells. Check each component's server-safety if you need RSC compatibility.
|
|
237
237
|
- **TableCaption:** Renders as HTML `<caption>` — screen readers announce it before content. Use it for any non-trivial table.
|
|
238
238
|
|
|
239
239
|
See `foundations/typography.md` for the body / label variants inside cells, `foundations/surfaces.md` for table-in-card surface guidance.
|