@lotics/ui 27.16.0 → 27.17.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/docs/catalog.md +4 -1
- package/package.json +1 -1
- package/src/composer.tsx +6 -0
package/docs/catalog.md
CHANGED
|
@@ -1490,7 +1490,10 @@ source (`src/<module>.tsx`/`.ts`) is the API reference.
|
|
|
1490
1490
|
|
|
1491
1491
|
- **`composer`** — `Composer`: the adaptive command/chat composer — a compact pill that
|
|
1492
1492
|
expands for long text + attachments (`pills` + attachment slots, controlled or
|
|
1493
|
-
uncontrolled `value`, `onSend`/`onStop`, `sendDisabled` override).
|
|
1493
|
+
uncontrolled `value`, `onSend`/`onStop`, `sendDisabled` override). The field's accessible
|
|
1494
|
+
name is `accessibilityLabel ?? placeholder`: the placeholder is DRAWN as an overlay (so a
|
|
1495
|
+
long hint stays one ellipsized line instead of wrapping inside the pill) and therefore
|
|
1496
|
+
names nothing by itself — pass one or the other, or the field is announced unlabelled.
|
|
1494
1497
|
- **`agent_run`** — `AgentRun` + `resolveToolMeta` + `AgentToolCall` + `AgentToolOutput` (the
|
|
1495
1498
|
`renderToolOutput` call shape — `{ toolName, input, output }`): the live streaming work feed.
|
|
1496
1499
|
Its prop is the agent message's ai-sdk `parts` (`UIMessagePart[]` — text, reasoning, and tool
|
package/package.json
CHANGED
package/src/composer.tsx
CHANGED
|
@@ -34,6 +34,10 @@ export interface ComposerProps {
|
|
|
34
34
|
/** Override the default "block on empty text" send-disable (e.g. allow send with attachments only). */
|
|
35
35
|
sendDisabled?: boolean;
|
|
36
36
|
placeholder?: string;
|
|
37
|
+
/** Accessible name for the text field. Defaults to `placeholder`, which is
|
|
38
|
+
* drawn as an overlay rather than set on the input (see below) and so names
|
|
39
|
+
* nothing on its own — without one the field is announced unlabelled. */
|
|
40
|
+
accessibilityLabel?: string;
|
|
37
41
|
autoFocus?: boolean;
|
|
38
42
|
testID?: string;
|
|
39
43
|
/** Control text externally; omit to let the composer manage its own state. */
|
|
@@ -71,6 +75,7 @@ export function Composer(props: ComposerProps) {
|
|
|
71
75
|
disabled,
|
|
72
76
|
sendDisabled,
|
|
73
77
|
placeholder,
|
|
78
|
+
accessibilityLabel,
|
|
74
79
|
autoFocus,
|
|
75
80
|
testID,
|
|
76
81
|
textInputProps,
|
|
@@ -196,6 +201,7 @@ export function Composer(props: ComposerProps) {
|
|
|
196
201
|
value={text}
|
|
197
202
|
onFocus={() => setFocused(true)}
|
|
198
203
|
onBlur={() => setFocused(false)}
|
|
204
|
+
aria-label={accessibilityLabel ?? placeholder}
|
|
199
205
|
multiline
|
|
200
206
|
scrollEnabled={expanded && scrollEnabled}
|
|
201
207
|
onContentSizeChange={onContentSizeChange}
|