@ciridae/ui 1.0.3 → 1.0.5
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/chat/conversation-source.d.ts +15 -1
- package/dist/chat/describe-tool-call.d.ts +3 -3
- package/dist/chat/describe-tool-call.js +3 -3
- package/dist/chat/message-text.js +2 -2
- package/dist/ciridae.css +16 -4
- package/dist/components/activity-feed.d.ts +1 -0
- package/dist/components/activity-feed.js +1 -0
- package/dist/components/app-frame.d.ts +13 -1
- package/dist/components/app-frame.js +45 -3
- package/dist/components/app-navigation.d.ts +28 -1
- package/dist/components/app-navigation.js +110 -14
- package/dist/components/badge.d.ts +29 -4
- package/dist/components/badge.js +134 -15
- package/dist/components/bulk-action-bar.js +3 -3
- package/dist/components/button.d.ts +10 -3
- package/dist/components/button.js +77 -44
- package/dist/components/calendar.js +44 -17
- package/dist/components/centered-page.js +2 -2
- package/dist/components/chart.d.ts +1 -1
- package/dist/components/chart.js +16 -11
- package/dist/components/chat-client-source.js +47 -6
- package/dist/components/chat-sheet-controller.d.ts +1 -0
- package/dist/components/chat-sheet-controller.js +1 -0
- package/dist/components/chat-sheet.d.ts +10 -2
- package/dist/components/chat-sheet.js +74 -37
- package/dist/components/chat.d.ts +90 -14
- package/dist/components/chat.js +401 -101
- package/dist/components/checkbox-item.d.ts +5 -2
- package/dist/components/checkbox-item.js +9 -5
- package/dist/components/chip.d.ts +5 -0
- package/dist/components/chip.js +27 -1
- package/dist/components/column-settings.js +1 -1
- package/dist/components/command-menu.d.ts +5 -1
- package/dist/components/command-menu.js +98 -32
- package/dist/components/command-palette.d.ts +6 -2
- package/dist/components/command-palette.js +20 -10
- package/dist/components/data-display.d.ts +35 -4
- package/dist/components/data-display.js +138 -19
- package/dist/components/data-grid.d.ts +14 -2
- package/dist/components/data-grid.js +61 -26
- package/dist/components/date-range-picker.js +9 -20
- package/dist/components/drawer.d.ts +5 -0
- package/dist/components/drawer.js +91 -54
- package/dist/components/editable-field.d.ts +17 -3
- package/dist/components/editable-field.js +57 -27
- package/dist/components/email-input.js +6 -5
- package/dist/components/environment-frame.d.ts +1 -1
- package/dist/components/environment-frame.js +37 -6
- package/dist/components/filter-bar.js +39 -28
- package/dist/components/form-controls.d.ts +9 -0
- package/dist/components/form-controls.js +46 -22
- package/dist/components/form-layout.d.ts +7 -3
- package/dist/components/form-layout.js +68 -23
- package/dist/components/glass-menu.d.ts +3 -0
- package/dist/components/glass-menu.js +63 -0
- package/dist/components/gradient-edge.d.ts +9 -0
- package/dist/components/gradient-edge.js +31 -0
- package/dist/components/input.d.ts +4 -2
- package/dist/components/input.js +26 -15
- package/dist/components/keycap.d.ts +9 -5
- package/dist/components/keycap.js +57 -19
- package/dist/components/lightbox.js +2 -1
- package/dist/components/locale.d.ts +10 -0
- package/dist/components/locale.js +18 -2
- package/dist/components/log-entry.d.ts +40 -0
- package/dist/components/log-entry.js +146 -0
- package/dist/components/mention-input.js +4 -3
- package/dist/components/menu.d.ts +6 -2
- package/dist/components/menu.js +34 -37
- package/dist/components/meter.d.ts +9 -1
- package/dist/components/meter.js +64 -6
- package/dist/components/navigation.d.ts +21 -4
- package/dist/components/navigation.js +84 -19
- package/dist/components/notification-tray.js +5 -4
- package/dist/components/overlays.d.ts +3 -1
- package/dist/components/overlays.js +69 -40
- package/dist/components/page-frame.js +1 -1
- package/dist/components/panel.d.ts +1 -1
- package/dist/components/panel.js +18 -12
- package/dist/components/radio-card.js +10 -9
- package/dist/components/record.d.ts +25 -1
- package/dist/components/record.js +147 -18
- package/dist/components/segmented-bar.d.ts +3 -1
- package/dist/components/segmented-bar.js +16 -6
- package/dist/components/select.d.ts +5 -2
- package/dist/components/select.js +103 -127
- package/dist/components/shell-skeleton.js +1 -1
- package/dist/components/shell.d.ts +2 -2
- package/dist/components/shell.js +43 -45
- package/dist/components/sidebar.d.ts +7 -2
- package/dist/components/sidebar.js +55 -27
- package/dist/components/single-line-text.d.ts +2 -0
- package/dist/components/single-line-text.js +16 -0
- package/dist/components/site-banner.d.ts +5 -2
- package/dist/components/site-banner.js +17 -6
- package/dist/components/skeleton.d.ts +7 -6
- package/dist/components/skeleton.js +28 -16
- package/dist/components/skeletons.d.ts +12 -0
- package/dist/components/skeletons.js +71 -8
- package/dist/components/stages.d.ts +78 -6
- package/dist/components/stages.js +512 -156
- package/dist/components/stat-card.d.ts +10 -2
- package/dist/components/stat-card.js +92 -37
- package/dist/components/status-banner.js +1 -1
- package/dist/components/tabs.js +26 -13
- package/dist/components/theme-toggle.d.ts +4 -0
- package/dist/components/theme-toggle.js +67 -0
- package/dist/components/toast.d.ts +9 -2
- package/dist/components/toast.js +78 -29
- package/dist/preset.js +291 -33
- package/dist/styled-system/styles.css +3107 -1039
- package/dist/styled-system/tokens/index.mjs +602 -22
- package/dist/styled-system/tokens/tokens.d.ts +11 -11
- package/dist/styled-system/types/prop-type.d.ts +2 -2
- package/dist/styles.css +16 -4
- package/dist/theme/color.d.ts +3 -0
- package/dist/theme/color.js +5 -0
- package/dist/theme/derive.d.ts +9 -2
- package/dist/theme/derive.js +72 -12
- package/dist/theme/palettes.d.ts +49 -6
- package/dist/theme/palettes.js +84 -15
- package/dist/theme/tokens.d.ts +3 -3
- package/dist/theme/tokens.js +108 -32
- package/package.json +9 -1
|
@@ -26,6 +26,12 @@ export type ChatComposerProps = Omit<ComponentProps<"div">, "onSubmit"> & {
|
|
|
26
26
|
* attach as a drop or the picker would. Rich text pasted with a picture of itself stays text.
|
|
27
27
|
*/
|
|
28
28
|
onPasteFiles?: (files: File[]) => void;
|
|
29
|
+
/**
|
|
30
|
+
* While the host takes dictation: the microphone's levels, drawn as a waveform beside the
|
|
31
|
+
* tools. The host owns the microphone and its controls, such as Cancel and Insert in `actions`,
|
|
32
|
+
* and writes what it heard into the text.
|
|
33
|
+
*/
|
|
34
|
+
dictation?: ChatDictation;
|
|
29
35
|
/**
|
|
30
36
|
* `page` is a chat page's wide card; `sheet` the field at the foot of the agent sheet; `feed`
|
|
31
37
|
* a comment field, which sends on Cmd/Ctrl+Enter rather than Enter.
|
|
@@ -41,21 +47,49 @@ export type ChatComposerProps = Omit<ComponentProps<"div">, "onSubmit"> & {
|
|
|
41
47
|
/** Props for the text field itself, such as a ref. */
|
|
42
48
|
inputProps?: Omit<ComponentProps<"div">, "children" | "defaultValue" | "onChange" | "onSubmit" | "placeholder">;
|
|
43
49
|
};
|
|
44
|
-
export declare function ChatComposer({ value, defaultValue, onValueChange, onSend, placeholder, ariaLabel: ownAriaLabel, tools, actions, submitLabel: ownSubmitLabel, sendDisabled, sendsWithoutText, attachments, onPasteFiles, variant, autoFocus, mentions, mentionMark, mentionsLabel, inputProps, className, ...props }: ChatComposerProps): import("react").JSX.Element;
|
|
50
|
+
export declare function ChatComposer({ value, defaultValue, onValueChange, onSend, placeholder, ariaLabel: ownAriaLabel, tools, actions, submitLabel: ownSubmitLabel, sendDisabled, sendsWithoutText, attachments, onPasteFiles, dictation, variant, autoFocus, mentions, mentionMark, mentionsLabel, inputProps, className, ...props }: ChatComposerProps): import("react").JSX.Element;
|
|
51
|
+
/** A tool for the sheet composer's bar, such as the paperclip: its icon alone. */
|
|
52
|
+
export declare function ChatComposerTool({ className, ...props }: Omit<ComponentProps<"button">, "aria-label"> & {
|
|
53
|
+
"aria-label": string;
|
|
54
|
+
}): import("react").JSX.Element;
|
|
55
|
+
/** The microphone's loudness while the host takes dictation, each level 0 to 1, newest last. */
|
|
56
|
+
export type ChatDictation = {
|
|
57
|
+
levels: readonly number[];
|
|
58
|
+
listening: boolean;
|
|
59
|
+
};
|
|
60
|
+
/**
|
|
61
|
+
* Dictation's waveform: a bar per level, each as tall as its level; flat while `listening` is
|
|
62
|
+
* off, such as while the host turns what it heard into text.
|
|
63
|
+
*/
|
|
64
|
+
export declare function ChatDictationWaveform({ levels, listening, className, ...props }: ComponentProps<"div"> & ChatDictation): import("react").JSX.Element;
|
|
45
65
|
export type ChatBubbleProps = ComponentProps<"div"> & {
|
|
46
66
|
side: "user" | "assistant";
|
|
47
67
|
/** Where the bubble sits in its run of messages from one side; see `listMessageGroupPositions`. */
|
|
48
68
|
groupPosition?: "single" | "first" | "middle" | "last";
|
|
49
69
|
};
|
|
50
|
-
/** A message bubble
|
|
70
|
+
/** A message bubble: the user's raised on the right, another author's filled on the left. */
|
|
51
71
|
export declare function ChatBubble({ side, groupPosition, className, ...props }: ChatBubbleProps): import("react").JSX.Element;
|
|
52
72
|
/** A centered line between bubbles: a finished tool call, a decision, something the page did. */
|
|
53
73
|
export declare function ChatSystemLine({ tone, className, ...props }: ComponentProps<"div"> & {
|
|
54
74
|
tone?: "muted" | "error";
|
|
55
75
|
}): import("react").JSX.Element;
|
|
56
|
-
/** Three pulsing dots: the assistant is typing. */
|
|
57
|
-
export declare function ChatTypingDots({ className, ...props }: ComponentProps<"span">): import("react").JSX.Element;
|
|
58
76
|
export declare function ChatAction({ className, ...props }: ComponentProps<"button">): import("react").JSX.Element;
|
|
77
|
+
export type ChatSourceCardProps = {
|
|
78
|
+
/** The source's name, such as "Vendor portal" or a rule's. */
|
|
79
|
+
label: ReactNode;
|
|
80
|
+
icon?: ReactNode;
|
|
81
|
+
/** What the source says that the reply relies on. */
|
|
82
|
+
children: ReactNode;
|
|
83
|
+
/** Under it, who entered it or when. */
|
|
84
|
+
meta?: ReactNode;
|
|
85
|
+
/** `yellow` marks a source the reply weighs, such as one of two rules in conflict. */
|
|
86
|
+
tone?: "neutral" | "yellow";
|
|
87
|
+
/** Makes the card a link to the source. */
|
|
88
|
+
href?: string;
|
|
89
|
+
className?: string;
|
|
90
|
+
};
|
|
91
|
+
/** A source cited in a reply, as a card of what it says under its name. */
|
|
92
|
+
export declare function ChatSourceCard({ label, icon, children, meta, tone, href, className, }: ChatSourceCardProps): import("react").JSX.Element;
|
|
59
93
|
/** Who wrote a message: drawn as the avatar beside its group and named in the group's footer. */
|
|
60
94
|
export type ChatAuthor = {
|
|
61
95
|
name: string;
|
|
@@ -75,16 +109,39 @@ export type ChatAttachment = {
|
|
|
75
109
|
url?: string | null;
|
|
76
110
|
mediaType?: string;
|
|
77
111
|
};
|
|
78
|
-
/**
|
|
112
|
+
/**
|
|
113
|
+
* A source a reply cites: a link in the row under it, linked when it has an `href`; with a
|
|
114
|
+
* `quote`, a `ChatSourceCard` of what it says.
|
|
115
|
+
*/
|
|
79
116
|
export type ChatSource = {
|
|
80
117
|
id: string;
|
|
81
118
|
label: ReactNode;
|
|
82
119
|
href?: string;
|
|
120
|
+
/** What the source says that the reply relies on, such as a value or a rule. */
|
|
121
|
+
quote?: ReactNode;
|
|
122
|
+
/** Leads the card's label, such as the source's kind as an icon. */
|
|
123
|
+
icon?: ReactNode;
|
|
124
|
+
/** Under the card's quote: who entered it, or when. */
|
|
125
|
+
meta?: ReactNode;
|
|
126
|
+
tone?: ChatSourceCardProps["tone"];
|
|
127
|
+
};
|
|
128
|
+
/** A step the agent took on its way to a reply: a thought, or a tool it called. */
|
|
129
|
+
export type ChatStep = {
|
|
130
|
+
id: string;
|
|
131
|
+
kind: "reasoning" | "tool";
|
|
132
|
+
/** What it did, as one line, such as "Search invoices". */
|
|
133
|
+
title: string;
|
|
134
|
+
/**
|
|
135
|
+
* More about it, such as the rest of the thought. Everyone reading the thread sees it, so never
|
|
136
|
+
* a tool call's raw arguments.
|
|
137
|
+
*/
|
|
138
|
+
detail?: string;
|
|
139
|
+
status: "running" | "completed" | "failed";
|
|
83
140
|
};
|
|
84
141
|
/**
|
|
85
|
-
* One entry of a thread: a message from either side, a centered line, the
|
|
86
|
-
* failure with its retry, or something of the caller's own, such as an
|
|
87
|
-
*
|
|
142
|
+
* One entry of a thread: a message from either side, a centered line, the agent at work, the
|
|
143
|
+
* steps it took, a failure with its retry, or something of the caller's own, such as an approval
|
|
144
|
+
* card, drawn by `renderCustom` in the side's flow.
|
|
88
145
|
*/
|
|
89
146
|
export type ChatThreadEntry<Custom = never> = {
|
|
90
147
|
id: string;
|
|
@@ -98,20 +155,32 @@ export type ChatThreadEntry<Custom = never> = {
|
|
|
98
155
|
attachments?: readonly ChatAttachment[];
|
|
99
156
|
/** Still on its way: the footer says Sending in place of the time. */
|
|
100
157
|
sending?: boolean;
|
|
101
|
-
/** What the reply cites
|
|
158
|
+
/** What the reply cites: links in a row under it, and the ones with a quote as cards. */
|
|
102
159
|
sources?: readonly ChatSource[];
|
|
103
|
-
/** Controls
|
|
160
|
+
/** Controls beside the message, shown while it is hovered or focused, such as Copy. */
|
|
104
161
|
actions?: ReactNode;
|
|
162
|
+
/** Buttons under the message for what it suggests doing, always shown. */
|
|
163
|
+
suggestedActions?: ReactNode;
|
|
164
|
+
/** A closing line under the message, such as what the reply read. */
|
|
165
|
+
footnote?: ReactNode;
|
|
105
166
|
} | {
|
|
106
167
|
kind: "line";
|
|
107
168
|
text: ReactNode;
|
|
108
169
|
tone?: "muted" | "error";
|
|
109
|
-
}
|
|
170
|
+
}
|
|
171
|
+
/** The agent at work before its reply: what it is doing, the locale's "Working" by default. */
|
|
172
|
+
| {
|
|
110
173
|
kind: "typing";
|
|
111
174
|
label?: ReactNode;
|
|
112
175
|
} | {
|
|
176
|
+
kind: "steps";
|
|
177
|
+
steps: readonly ChatStep[];
|
|
178
|
+
}
|
|
179
|
+
/** A reply that did not finish: `title` over why, and Try again under it. */
|
|
180
|
+
| {
|
|
113
181
|
kind: "failure";
|
|
114
|
-
|
|
182
|
+
title?: ReactNode;
|
|
183
|
+
message?: ReactNode;
|
|
115
184
|
onRetry: () => void;
|
|
116
185
|
} | {
|
|
117
186
|
kind: "custom";
|
|
@@ -126,8 +195,15 @@ export type ChatThreadProps<Custom = never> = {
|
|
|
126
195
|
renderCustom?: (data: Custom) => ReactNode;
|
|
127
196
|
/** How a footer writes the time; the time of day, dated once not today, otherwise. */
|
|
128
197
|
formatTime?: (at: number) => string;
|
|
129
|
-
/** `compact` trims the padding around the thread and between groups
|
|
198
|
+
/** `compact` trims the padding around the thread and between groups. */
|
|
130
199
|
density?: "comfortable" | "compact";
|
|
200
|
+
/**
|
|
201
|
+
* `bubble`, the default, draws every message in a bubble, the assistant's beside its author's
|
|
202
|
+
* avatar, with the author and time under each group. `plain` draws the assistant's replies as
|
|
203
|
+
* text on the sheet, the thread's full width, with no avatar and no author or time, as the
|
|
204
|
+
* agent sheet does.
|
|
205
|
+
*/
|
|
206
|
+
replyStyle?: "bubble" | "plain";
|
|
131
207
|
/** Draws a message's files as tiles over its bubble, rather than as names inside it. */
|
|
132
208
|
attachmentTiles?: boolean;
|
|
133
209
|
/** Heads each day's entries with its date, for a thread that runs over days. */
|
|
@@ -139,7 +215,7 @@ export type ChatThreadProps<Custom = never> = {
|
|
|
139
215
|
resolveAttachmentUrl?: ResolveFileUrl<ChatAttachment>;
|
|
140
216
|
className?: string;
|
|
141
217
|
};
|
|
142
|
-
export declare function ChatThread<Custom = never>({ entries, assistant, renderCustom, formatTime, density, attachmentTiles, dayLabels, resolveAttachmentUrl, className, }: ChatThreadProps<Custom>): import("react").JSX.Element;
|
|
218
|
+
export declare function ChatThread<Custom = never>({ entries, assistant, renderCustom, formatTime, density, replyStyle, attachmentTiles, dayLabels, resolveAttachmentUrl, className, }: ChatThreadProps<Custom>): import("react").JSX.Element;
|
|
143
219
|
export type ChatSuggestionsProps = {
|
|
144
220
|
suggestions: readonly string[];
|
|
145
221
|
onSelect: (suggestion: string) => void;
|