ionbase-ui 0.24.0 → 0.25.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/dist/components/AgentActivity.d.ts +41 -0
- package/dist/components/AgentActivity.d.ts.map +1 -0
- package/dist/components/AgentActivity.js +84 -0
- package/dist/components/AgentActivity.js.map +1 -0
- package/dist/components/Citation.d.ts +51 -0
- package/dist/components/Citation.d.ts.map +1 -0
- package/dist/components/Citation.js +41 -0
- package/dist/components/Citation.js.map +1 -0
- package/dist/components/ConfidenceIndicator.d.ts +37 -0
- package/dist/components/ConfidenceIndicator.d.ts.map +1 -0
- package/dist/components/ConfidenceIndicator.js +41 -0
- package/dist/components/ConfidenceIndicator.js.map +1 -0
- package/dist/components/StreamingText.d.ts +47 -0
- package/dist/components/StreamingText.d.ts.map +1 -0
- package/dist/components/StreamingText.js +44 -0
- package/dist/components/StreamingText.js.map +1 -0
- package/dist/components/index.d.ts +8 -0
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/index.js +4 -0
- package/dist/components/index.js.map +1 -1
- package/dist/figma-descriptions.json +29 -29
- package/dist/figma-map.json +1 -1
- package/dist/meta/AgentActivity.json +103 -0
- package/dist/meta/AgentActivityStep.json +117 -0
- package/dist/meta/Citation.json +101 -0
- package/dist/meta/CitationList.json +94 -0
- package/dist/meta/CitationListItem.json +88 -0
- package/dist/meta/ConfidenceIndicator.json +115 -0
- package/dist/meta/Input.json +2 -2
- package/dist/meta/PhoneInput.json +2 -2
- package/dist/meta/StreamingText.json +99 -0
- package/dist/meta/components.json +722 -5
- package/dist/meta/contrast.json +240 -0
- package/dist/meta/index.json +64 -1
- package/dist/meta/patterns/index.json +1 -1
- package/dist/styles/agent-activity.css +95 -0
- package/dist/styles/citation.css +93 -0
- package/dist/styles/confidence-indicator.css +97 -0
- package/dist/styles/index.css +4 -0
- package/dist/styles/streaming-text.css +56 -0
- package/llms.txt +2 -2
- package/package.json +1 -1
|
@@ -1,11 +1,231 @@
|
|
|
1
1
|
{
|
|
2
2
|
"package": "ionbase-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.25.0",
|
|
4
4
|
"generated": "by scripts/build-meta.mjs — do not edit; intent lives in meta/*.json",
|
|
5
5
|
"hooks": [
|
|
6
6
|
"useToast"
|
|
7
7
|
],
|
|
8
8
|
"components": {
|
|
9
|
+
"AgentActivity": {
|
|
10
|
+
"name": "AgentActivity",
|
|
11
|
+
"source": "src/components/AgentActivity.tsx",
|
|
12
|
+
"propsType": "AgentActivityProps",
|
|
13
|
+
"description": "AgentActivity — what the agent is doing, in plain language.\n\nAn ordered list, because the steps happened in an order and a screen reader\nshould say \"3 of 7\". Not a log viewer: this is the account a person reads to\ndecide whether to let the run continue, so the text belongs in their\nlanguage — \"Searched the invoice archive\", not `searchIndex(q, {limit:50})`.\n\nSTATUS IS NEVER CARRIED BY THE ICON ALONE. Every step renders its status as\ntext as well as a glyph. The glyphs differ in shape rather than only in\ncolour, so the list survives greyscale, colour blindness and forced-colours\nmode — WCAG 1.4.1, which a row of coloured dots fails outright.\n\nONE POLITE ANNOUNCEMENT PER STEP, not one per render. The active step's text\nis announced when it changes, so a user who is not watching still knows where\nthe run has got to. Watching the DOM instead would re-announce on every\nunrelated update, which is the failure mode that makes people turn logs off.",
|
|
14
|
+
"import": "import { AgentActivity } from 'ionbase-ui';",
|
|
15
|
+
"status": "stable",
|
|
16
|
+
"summary": "An ordered, plain-language log of what the agent is doing. Status is text and shape, never colour alone.",
|
|
17
|
+
"useWhen": [
|
|
18
|
+
"a run takes long enough that the user needs to know where it has got to",
|
|
19
|
+
"a person will decide whether to let it continue — which means they need to read what it did"
|
|
20
|
+
],
|
|
21
|
+
"useInstead": [
|
|
22
|
+
{
|
|
23
|
+
"when": "the output is prose rather than steps",
|
|
24
|
+
"use": "StreamingText"
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
"when": "you need a decision, not a report",
|
|
28
|
+
"use": "ApprovalGate"
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
"when": "it is one finished outcome",
|
|
32
|
+
"use": "Alert"
|
|
33
|
+
}
|
|
34
|
+
],
|
|
35
|
+
"composition": {
|
|
36
|
+
"order": [
|
|
37
|
+
"AgentActivity",
|
|
38
|
+
"AgentActivityStep"
|
|
39
|
+
],
|
|
40
|
+
"note": "An <ol>, so a screen reader can say \"3 of 7\" and the order is structural rather than typed into each row.",
|
|
41
|
+
"example": "<AgentActivity><AgentActivityStep status=\"done\">Searched the invoice archive</AgentActivityStep><AgentActivityStep status=\"active\">Reading 12 matches</AgentActivityStep></AgentActivity>"
|
|
42
|
+
},
|
|
43
|
+
"a11y": {
|
|
44
|
+
"role": "list",
|
|
45
|
+
"guarantees": [
|
|
46
|
+
"every step renders its status as visually hidden text as well as a glyph, and the glyphs differ in shape rather than only in colour — a row of coloured dots fails WCAG 1.4.1 outright",
|
|
47
|
+
"the active step is announced once, when it changes, in a polite live region",
|
|
48
|
+
"the active step's spinner stops under `prefers-reduced-motion`"
|
|
49
|
+
],
|
|
50
|
+
"requires": [
|
|
51
|
+
"step text in the user's language — \"Searched the invoice archive\", not a function signature",
|
|
52
|
+
"`announceActive={false}` when several logs are on screen, or they narrate over each other"
|
|
53
|
+
],
|
|
54
|
+
"notes": [
|
|
55
|
+
"The active step is read out of the children rather than taken as a prop. Two sources for one fact is how they come to disagree."
|
|
56
|
+
]
|
|
57
|
+
},
|
|
58
|
+
"antiPatterns": [
|
|
59
|
+
{
|
|
60
|
+
"dont": "raw tool calls or JSON as the step label",
|
|
61
|
+
"why": "this is the account a person reads to decide whether to let the run continue"
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
"dont": "more than one step with `status=\"active\"`",
|
|
65
|
+
"why": "the announcement names one thing, and two claims about what is happening now cannot both be true"
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
"dont": "several announcing logs on one screen",
|
|
69
|
+
"do": "`announceActive={false}` on all but one",
|
|
70
|
+
"why": "they interrupt each other and the user turns the whole thing off"
|
|
71
|
+
}
|
|
72
|
+
],
|
|
73
|
+
"stylesheet": "src/styles/agent-activity.css",
|
|
74
|
+
"tokens": [
|
|
75
|
+
"--font-family-sans",
|
|
76
|
+
"--icon-error",
|
|
77
|
+
"--icon-primary",
|
|
78
|
+
"--icon-size-sm",
|
|
79
|
+
"--icon-success",
|
|
80
|
+
"--icon-tertiary",
|
|
81
|
+
"--spacing-2",
|
|
82
|
+
"--spacing-8",
|
|
83
|
+
"--text-default",
|
|
84
|
+
"--text-error",
|
|
85
|
+
"--text-secondary",
|
|
86
|
+
"--text-tertiary",
|
|
87
|
+
"--type-body-sm",
|
|
88
|
+
"--type-body-sm-line-height",
|
|
89
|
+
"--type-caption",
|
|
90
|
+
"--type-caption-line-height"
|
|
91
|
+
],
|
|
92
|
+
"props": {
|
|
93
|
+
"children": {
|
|
94
|
+
"type": "React.ReactNode",
|
|
95
|
+
"required": false,
|
|
96
|
+
"origin": "own"
|
|
97
|
+
},
|
|
98
|
+
"announceActive": {
|
|
99
|
+
"type": "boolean | undefined",
|
|
100
|
+
"required": false,
|
|
101
|
+
"origin": "own",
|
|
102
|
+
"description": "Announce the step that just became active, once, in a polite live region.\n\nOn by default because the whole point of an activity log is knowing what\nthe agent is doing without watching it. Turn it off when several logs are\non screen at once, or they narrate over each other."
|
|
103
|
+
}
|
|
104
|
+
},
|
|
105
|
+
"propCounts": {
|
|
106
|
+
"own": 2,
|
|
107
|
+
"aria": 0,
|
|
108
|
+
"dom": 277,
|
|
109
|
+
"other": 0
|
|
110
|
+
}
|
|
111
|
+
},
|
|
112
|
+
"AgentActivityStep": {
|
|
113
|
+
"name": "AgentActivityStep",
|
|
114
|
+
"source": "src/components/AgentActivity.tsx",
|
|
115
|
+
"propsType": "AgentActivityStepProps",
|
|
116
|
+
"import": "import { AgentActivityStep } from 'ionbase-ui';",
|
|
117
|
+
"status": "stable",
|
|
118
|
+
"summary": "One step in an activity log: what happened, in the user's language, with a status carried by shape and text.",
|
|
119
|
+
"useWhen": [
|
|
120
|
+
"a child of AgentActivity — it is not usable elsewhere"
|
|
121
|
+
],
|
|
122
|
+
"useInstead": [
|
|
123
|
+
{
|
|
124
|
+
"when": "it is a row in a dropdown",
|
|
125
|
+
"use": "MenuItem"
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
"when": "it is a data row",
|
|
129
|
+
"use": "TableRow"
|
|
130
|
+
}
|
|
131
|
+
],
|
|
132
|
+
"variants": {
|
|
133
|
+
"status": {
|
|
134
|
+
"pending": {
|
|
135
|
+
"use": "the default — queued, not started"
|
|
136
|
+
},
|
|
137
|
+
"active": {
|
|
138
|
+
"use": "happening now. Only one step should carry it"
|
|
139
|
+
},
|
|
140
|
+
"done": {
|
|
141
|
+
"use": "finished successfully"
|
|
142
|
+
},
|
|
143
|
+
"failed": {
|
|
144
|
+
"use": "did not finish. Say why in `detail`"
|
|
145
|
+
},
|
|
146
|
+
"skipped": {
|
|
147
|
+
"use": "deliberately not run — a branch not taken, a cached result"
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
},
|
|
151
|
+
"slots": {
|
|
152
|
+
"children": {
|
|
153
|
+
"accepts": "text",
|
|
154
|
+
"note": "the step in plain language"
|
|
155
|
+
},
|
|
156
|
+
"detail": {
|
|
157
|
+
"accepts": "text",
|
|
158
|
+
"note": "the result, a count, a tool name — whatever makes the step checkable"
|
|
159
|
+
}
|
|
160
|
+
},
|
|
161
|
+
"a11y": {
|
|
162
|
+
"guarantees": [
|
|
163
|
+
"the status name is rendered as visually hidden text, so it is never carried by the glyph's colour alone",
|
|
164
|
+
"each status has a differently shaped glyph, which survives greyscale and forced-colours mode"
|
|
165
|
+
]
|
|
166
|
+
},
|
|
167
|
+
"antiPatterns": [
|
|
168
|
+
{
|
|
169
|
+
"dont": "`failed` with no `detail`",
|
|
170
|
+
"why": "a failure the reader cannot diagnose is just a red mark"
|
|
171
|
+
},
|
|
172
|
+
{
|
|
173
|
+
"dont": "using it outside AgentActivity",
|
|
174
|
+
"why": "it renders an <li>, which is only valid inside a list"
|
|
175
|
+
}
|
|
176
|
+
],
|
|
177
|
+
"stylesheet": "src/styles/agent-activity.css",
|
|
178
|
+
"tokens": [
|
|
179
|
+
"--font-family-sans",
|
|
180
|
+
"--icon-error",
|
|
181
|
+
"--icon-primary",
|
|
182
|
+
"--icon-size-sm",
|
|
183
|
+
"--icon-success",
|
|
184
|
+
"--icon-tertiary",
|
|
185
|
+
"--spacing-2",
|
|
186
|
+
"--spacing-8",
|
|
187
|
+
"--text-default",
|
|
188
|
+
"--text-error",
|
|
189
|
+
"--text-secondary",
|
|
190
|
+
"--text-tertiary",
|
|
191
|
+
"--type-body-sm",
|
|
192
|
+
"--type-body-sm-line-height",
|
|
193
|
+
"--type-caption",
|
|
194
|
+
"--type-caption-line-height"
|
|
195
|
+
],
|
|
196
|
+
"props": {
|
|
197
|
+
"children": {
|
|
198
|
+
"type": "React.ReactNode",
|
|
199
|
+
"required": false,
|
|
200
|
+
"origin": "own",
|
|
201
|
+
"description": "What the agent did, in the user's language. Not a function name."
|
|
202
|
+
},
|
|
203
|
+
"status": {
|
|
204
|
+
"type": "AgentActivityStatus | undefined",
|
|
205
|
+
"required": false,
|
|
206
|
+
"origin": "own",
|
|
207
|
+
"values": [
|
|
208
|
+
"pending",
|
|
209
|
+
"active",
|
|
210
|
+
"done",
|
|
211
|
+
"failed",
|
|
212
|
+
"skipped"
|
|
213
|
+
]
|
|
214
|
+
},
|
|
215
|
+
"detail": {
|
|
216
|
+
"type": "React.ReactNode",
|
|
217
|
+
"required": false,
|
|
218
|
+
"origin": "own",
|
|
219
|
+
"description": "The result, a tool name, a count — whatever makes the step checkable."
|
|
220
|
+
}
|
|
221
|
+
},
|
|
222
|
+
"propCounts": {
|
|
223
|
+
"own": 3,
|
|
224
|
+
"aria": 0,
|
|
225
|
+
"dom": 278,
|
|
226
|
+
"other": 0
|
|
227
|
+
}
|
|
228
|
+
},
|
|
9
229
|
"AgentStop": {
|
|
10
230
|
"name": "AgentStop",
|
|
11
231
|
"source": "src/components/AgentStop.tsx",
|
|
@@ -1836,6 +2056,404 @@
|
|
|
1836
2056
|
"other": 0
|
|
1837
2057
|
}
|
|
1838
2058
|
},
|
|
2059
|
+
"Citation": {
|
|
2060
|
+
"name": "Citation",
|
|
2061
|
+
"source": "src/components/Citation.tsx",
|
|
2062
|
+
"propsType": "CitationProps",
|
|
2063
|
+
"description": "Citation — the inline marker.\n\nTHE MARKER IS NOT THE NAME. Rendered naively, a superscript \"1\" announces as\n\"link, 1\", which tells a screen-reader user nothing about whether to follow\nit. The visible marker stays a number; the accessible name is\n\"Source 1: <source>\". The number is for the sighted reader's eye and the\nsentence is for everyone.\n\nNOT A TOOLTIP. A tooltip cannot be reached on touch and closes on the way to\nit; attribution has to survive both. It is a real link, or a real\nnon-interactive marker when there is nowhere to go.\n\nWITHOUT `href` IT IS NOT A LINK. A citation to a phone call or an internal\ndocument has no address, and rendering a dead anchor for it puts an\nunfollowable link in the page's link list. It becomes a plain marked-up\nreference instead.",
|
|
2064
|
+
"import": "import { Citation } from 'ionbase-ui';",
|
|
2065
|
+
"status": "stable",
|
|
2066
|
+
"summary": "The inline source marker. The visible number is for the eye; the accessible name is the sentence.",
|
|
2067
|
+
"useWhen": [
|
|
2068
|
+
"a claim in generated text is drawn from a specific source the reader can check",
|
|
2069
|
+
"attribution has to survive being read aloud, on touch, and in a links list"
|
|
2070
|
+
],
|
|
2071
|
+
"useInstead": [
|
|
2072
|
+
{
|
|
2073
|
+
"when": "the source needs a full row with a passage",
|
|
2074
|
+
"use": "CitationListItem"
|
|
2075
|
+
},
|
|
2076
|
+
{
|
|
2077
|
+
"when": "it is an ordinary link in prose",
|
|
2078
|
+
"use": "Link"
|
|
2079
|
+
},
|
|
2080
|
+
{
|
|
2081
|
+
"when": "you were about to put the source in a hover-only hint",
|
|
2082
|
+
"use": "Popover",
|
|
2083
|
+
"why": "a tooltip cannot be reached on touch and closes on the way to it"
|
|
2084
|
+
}
|
|
2085
|
+
],
|
|
2086
|
+
"a11y": {
|
|
2087
|
+
"role": "link when `href` is set, note otherwise",
|
|
2088
|
+
"guarantees": [
|
|
2089
|
+
"the accessible name is \"Source <index>: <source>\", never the bare number — a superscript 1 announces as \"link, 1\", which tells a screen-reader user nothing about whether to follow it",
|
|
2090
|
+
"without `href` it renders a marker rather than a dead anchor, so an unfollowable link never enters the page's link list"
|
|
2091
|
+
],
|
|
2092
|
+
"requires": [
|
|
2093
|
+
"`source` naming what is being cited",
|
|
2094
|
+
"an `index` matching the footer row, if there is one"
|
|
2095
|
+
]
|
|
2096
|
+
},
|
|
2097
|
+
"antiPatterns": [
|
|
2098
|
+
{
|
|
2099
|
+
"dont": "a bare superscript number with no accessible name",
|
|
2100
|
+
"why": "\"link, 1\" is not attribution"
|
|
2101
|
+
},
|
|
2102
|
+
{
|
|
2103
|
+
"dont": "an empty `href` for a source with no address",
|
|
2104
|
+
"do": "omit `href`",
|
|
2105
|
+
"why": "a dead anchor is announced as a link and goes nowhere"
|
|
2106
|
+
},
|
|
2107
|
+
{
|
|
2108
|
+
"dont": "putting the source only in a tooltip",
|
|
2109
|
+
"why": "undiscoverable on touch, and gone before it can be read"
|
|
2110
|
+
}
|
|
2111
|
+
],
|
|
2112
|
+
"stylesheet": "src/styles/citation.css",
|
|
2113
|
+
"tokens": [
|
|
2114
|
+
"--border-focus",
|
|
2115
|
+
"--border-width-thick",
|
|
2116
|
+
"--font-family-sans",
|
|
2117
|
+
"--font-weight-medium",
|
|
2118
|
+
"--font-weight-semibold",
|
|
2119
|
+
"--radius-xs",
|
|
2120
|
+
"--spacing-16",
|
|
2121
|
+
"--spacing-2",
|
|
2122
|
+
"--spacing-4",
|
|
2123
|
+
"--spacing-8",
|
|
2124
|
+
"--surface-primary-subtle",
|
|
2125
|
+
"--surface-primary-subtle-hover",
|
|
2126
|
+
"--text-link",
|
|
2127
|
+
"--text-tertiary",
|
|
2128
|
+
"--type-body-sm",
|
|
2129
|
+
"--type-body-sm-line-height",
|
|
2130
|
+
"--type-caption",
|
|
2131
|
+
"--type-caption-line-height"
|
|
2132
|
+
],
|
|
2133
|
+
"props": {
|
|
2134
|
+
"index": {
|
|
2135
|
+
"type": "string | number",
|
|
2136
|
+
"required": true,
|
|
2137
|
+
"origin": "own",
|
|
2138
|
+
"description": "The marker shown inline — usually a number matching the footer list."
|
|
2139
|
+
},
|
|
2140
|
+
"source": {
|
|
2141
|
+
"type": "string",
|
|
2142
|
+
"required": true,
|
|
2143
|
+
"origin": "own",
|
|
2144
|
+
"description": "What is being cited. Required: it is the link's accessible name, and a\ncitation a reader cannot identify without following it is not attribution."
|
|
2145
|
+
},
|
|
2146
|
+
"href": {
|
|
2147
|
+
"type": "string | undefined",
|
|
2148
|
+
"required": false,
|
|
2149
|
+
"origin": "own",
|
|
2150
|
+
"description": "Where it goes. Omit for a source with no address — a document, a call."
|
|
2151
|
+
}
|
|
2152
|
+
},
|
|
2153
|
+
"propCounts": {
|
|
2154
|
+
"own": 3,
|
|
2155
|
+
"aria": 0,
|
|
2156
|
+
"dom": 284,
|
|
2157
|
+
"other": 0
|
|
2158
|
+
}
|
|
2159
|
+
},
|
|
2160
|
+
"CitationList": {
|
|
2161
|
+
"name": "CitationList",
|
|
2162
|
+
"source": "src/components/Citation.tsx",
|
|
2163
|
+
"propsType": "CitationListProps",
|
|
2164
|
+
"description": "The footer list. An `<ol>` so the numbering is structural rather than typed\ninto each row, and so a screen reader can say how many sources there are\nbefore the reader commits to hearing them.",
|
|
2165
|
+
"import": "import { CitationList } from 'ionbase-ui';",
|
|
2166
|
+
"status": "stable",
|
|
2167
|
+
"summary": "The footer list of sources, as an ordered list so the count and order are structural.",
|
|
2168
|
+
"useWhen": [
|
|
2169
|
+
"several claims cite sources and the reader should be able to see them all at once"
|
|
2170
|
+
],
|
|
2171
|
+
"useInstead": [
|
|
2172
|
+
{
|
|
2173
|
+
"when": "there is one source and it belongs in the sentence",
|
|
2174
|
+
"use": "Link"
|
|
2175
|
+
},
|
|
2176
|
+
{
|
|
2177
|
+
"when": "it is tabular data with more than a source per row",
|
|
2178
|
+
"use": "Table"
|
|
2179
|
+
}
|
|
2180
|
+
],
|
|
2181
|
+
"composition": {
|
|
2182
|
+
"order": [
|
|
2183
|
+
"CitationList",
|
|
2184
|
+
"CitationListItem"
|
|
2185
|
+
],
|
|
2186
|
+
"example": "<CitationList><CitationListItem index={1} source=\"Q3 filing\" href=\"/q3\">Revenue rose 4%.</CitationListItem></CitationList>"
|
|
2187
|
+
},
|
|
2188
|
+
"slots": {
|
|
2189
|
+
"label": {
|
|
2190
|
+
"accepts": "text",
|
|
2191
|
+
"note": "rendered as plain text, not a heading element — it should not enter the document outline as a section"
|
|
2192
|
+
},
|
|
2193
|
+
"children": {
|
|
2194
|
+
"accepts": "CitationListItem"
|
|
2195
|
+
}
|
|
2196
|
+
},
|
|
2197
|
+
"a11y": {
|
|
2198
|
+
"guarantees": [
|
|
2199
|
+
"an <ol>, so a screen reader can say how many sources there are before the reader commits to hearing them",
|
|
2200
|
+
"list markers are hidden in CSS while the semantics stay, because the visible number must match the inline Citation's exactly"
|
|
2201
|
+
]
|
|
2202
|
+
},
|
|
2203
|
+
"antiPatterns": [
|
|
2204
|
+
{
|
|
2205
|
+
"dont": "a <div> stack of sources",
|
|
2206
|
+
"why": "the count and the ordering are the useful part, and only a list carries them"
|
|
2207
|
+
},
|
|
2208
|
+
{
|
|
2209
|
+
"dont": "numbers that disagree with the inline markers",
|
|
2210
|
+
"why": "the marker is a promise about where to look"
|
|
2211
|
+
}
|
|
2212
|
+
],
|
|
2213
|
+
"stylesheet": "src/styles/citation.css",
|
|
2214
|
+
"tokens": [
|
|
2215
|
+
"--border-focus",
|
|
2216
|
+
"--border-width-thick",
|
|
2217
|
+
"--font-family-sans",
|
|
2218
|
+
"--font-weight-medium",
|
|
2219
|
+
"--font-weight-semibold",
|
|
2220
|
+
"--radius-xs",
|
|
2221
|
+
"--spacing-16",
|
|
2222
|
+
"--spacing-2",
|
|
2223
|
+
"--spacing-4",
|
|
2224
|
+
"--spacing-8",
|
|
2225
|
+
"--surface-primary-subtle",
|
|
2226
|
+
"--surface-primary-subtle-hover",
|
|
2227
|
+
"--text-link",
|
|
2228
|
+
"--text-tertiary",
|
|
2229
|
+
"--type-body-sm",
|
|
2230
|
+
"--type-body-sm-line-height",
|
|
2231
|
+
"--type-caption",
|
|
2232
|
+
"--type-caption-line-height"
|
|
2233
|
+
],
|
|
2234
|
+
"props": {
|
|
2235
|
+
"children": {
|
|
2236
|
+
"type": "React.ReactNode",
|
|
2237
|
+
"required": false,
|
|
2238
|
+
"origin": "own"
|
|
2239
|
+
},
|
|
2240
|
+
"label": {
|
|
2241
|
+
"type": "React.ReactNode",
|
|
2242
|
+
"required": false,
|
|
2243
|
+
"origin": "own",
|
|
2244
|
+
"description": "Heading above the list. Rendered as plain text, not a heading element."
|
|
2245
|
+
}
|
|
2246
|
+
},
|
|
2247
|
+
"propCounts": {
|
|
2248
|
+
"own": 2,
|
|
2249
|
+
"aria": 0,
|
|
2250
|
+
"dom": 280,
|
|
2251
|
+
"other": 0
|
|
2252
|
+
}
|
|
2253
|
+
},
|
|
2254
|
+
"CitationListItem": {
|
|
2255
|
+
"name": "CitationListItem",
|
|
2256
|
+
"source": "src/components/Citation.tsx",
|
|
2257
|
+
"propsType": "CitationListItemProps",
|
|
2258
|
+
"import": "import { CitationListItem } from 'ionbase-ui';",
|
|
2259
|
+
"status": "stable",
|
|
2260
|
+
"summary": "One source row: its number, what it is, and the passage it supports.",
|
|
2261
|
+
"useWhen": [
|
|
2262
|
+
"a child of CitationList"
|
|
2263
|
+
],
|
|
2264
|
+
"useInstead": [
|
|
2265
|
+
{
|
|
2266
|
+
"when": "it is the inline marker in the prose",
|
|
2267
|
+
"use": "Citation"
|
|
2268
|
+
}
|
|
2269
|
+
],
|
|
2270
|
+
"slots": {
|
|
2271
|
+
"children": {
|
|
2272
|
+
"accepts": "text",
|
|
2273
|
+
"note": "the quoted or summarised passage this source supports"
|
|
2274
|
+
}
|
|
2275
|
+
},
|
|
2276
|
+
"a11y": {
|
|
2277
|
+
"guarantees": [
|
|
2278
|
+
"the visible number is `aria-hidden`; the row is named by its source text, which is what a reader needs to hear",
|
|
2279
|
+
"without `href` the source renders as text rather than a dead link"
|
|
2280
|
+
],
|
|
2281
|
+
"requires": [
|
|
2282
|
+
"`source` naming what is being cited"
|
|
2283
|
+
]
|
|
2284
|
+
},
|
|
2285
|
+
"antiPatterns": [
|
|
2286
|
+
{
|
|
2287
|
+
"dont": "a bare URL as the `source`",
|
|
2288
|
+
"why": "a screen reader spells it out character by character, and it names nothing"
|
|
2289
|
+
}
|
|
2290
|
+
],
|
|
2291
|
+
"stylesheet": "src/styles/citation.css",
|
|
2292
|
+
"tokens": [
|
|
2293
|
+
"--border-focus",
|
|
2294
|
+
"--border-width-thick",
|
|
2295
|
+
"--font-family-sans",
|
|
2296
|
+
"--font-weight-medium",
|
|
2297
|
+
"--font-weight-semibold",
|
|
2298
|
+
"--radius-xs",
|
|
2299
|
+
"--spacing-16",
|
|
2300
|
+
"--spacing-2",
|
|
2301
|
+
"--spacing-4",
|
|
2302
|
+
"--spacing-8",
|
|
2303
|
+
"--surface-primary-subtle",
|
|
2304
|
+
"--surface-primary-subtle-hover",
|
|
2305
|
+
"--text-link",
|
|
2306
|
+
"--text-tertiary",
|
|
2307
|
+
"--type-body-sm",
|
|
2308
|
+
"--type-body-sm-line-height",
|
|
2309
|
+
"--type-caption",
|
|
2310
|
+
"--type-caption-line-height"
|
|
2311
|
+
],
|
|
2312
|
+
"props": {
|
|
2313
|
+
"index": {
|
|
2314
|
+
"type": "string | number",
|
|
2315
|
+
"required": true,
|
|
2316
|
+
"origin": "own"
|
|
2317
|
+
},
|
|
2318
|
+
"source": {
|
|
2319
|
+
"type": "string",
|
|
2320
|
+
"required": true,
|
|
2321
|
+
"origin": "own"
|
|
2322
|
+
},
|
|
2323
|
+
"href": {
|
|
2324
|
+
"type": "string | undefined",
|
|
2325
|
+
"required": false,
|
|
2326
|
+
"origin": "own"
|
|
2327
|
+
},
|
|
2328
|
+
"children": {
|
|
2329
|
+
"type": "React.ReactNode",
|
|
2330
|
+
"required": false,
|
|
2331
|
+
"origin": "own",
|
|
2332
|
+
"description": "The quoted or summarised passage this citation supports."
|
|
2333
|
+
}
|
|
2334
|
+
},
|
|
2335
|
+
"propCounts": {
|
|
2336
|
+
"own": 4,
|
|
2337
|
+
"aria": 0,
|
|
2338
|
+
"dom": 278,
|
|
2339
|
+
"other": 0
|
|
2340
|
+
}
|
|
2341
|
+
},
|
|
2342
|
+
"ConfidenceIndicator": {
|
|
2343
|
+
"name": "ConfidenceIndicator",
|
|
2344
|
+
"source": "src/components/ConfidenceIndicator.tsx",
|
|
2345
|
+
"propsType": "ConfidenceIndicatorProps",
|
|
2346
|
+
"description": "ConfidenceIndicator — how much to trust the thing next to it.\n\nTHERE IS NO PERCENTAGE PROP, AND THERE WILL NOT BE ONE\n\n\"87% confident\" reads as a measurement. Almost nowhere is it one: it is\nusually a softmax score, a heuristic, or a number a model produced about\nitself — none of which are calibrated probabilities, and all of which invite\na reader to treat two digits of precision as real. Three levels cannot\noverclaim in that way.\n\n`basis` IS REQUIRED FOR THE SAME REASON. A level with nothing behind it is\ndecoration that changes behaviour: people act on \"high confidence\" whether or\nnot anything justifies it. Making the justification a required prop is the\nonly enforcement available here, and it is a type error rather than a policy\n— which is the strongest kind this system can offer.\n\nIt renders as text plus a three-bar meter, never the meter alone. The bars\ndiffer in filled COUNT, not only in colour, so the reading survives greyscale\nand forced-colours mode.",
|
|
2347
|
+
"import": "import { ConfidenceIndicator } from 'ionbase-ui';",
|
|
2348
|
+
"status": "stable",
|
|
2349
|
+
"summary": "How much to trust the thing next to it — three levels with a required basis, never a percentage.",
|
|
2350
|
+
"useWhen": [
|
|
2351
|
+
"a generated answer varies in reliability and the reader should weigh it",
|
|
2352
|
+
"you can say what the confidence rests on"
|
|
2353
|
+
],
|
|
2354
|
+
"useInstead": [
|
|
2355
|
+
{
|
|
2356
|
+
"when": "the answer is wrong or missing rather than uncertain",
|
|
2357
|
+
"use": "Alert"
|
|
2358
|
+
},
|
|
2359
|
+
{
|
|
2360
|
+
"when": "you want to show where the claim came from",
|
|
2361
|
+
"use": "Citation",
|
|
2362
|
+
"why": "a source is stronger than a confidence level, and often what the reader actually wanted"
|
|
2363
|
+
},
|
|
2364
|
+
{
|
|
2365
|
+
"when": "it is a status rather than a reliability",
|
|
2366
|
+
"use": "Badge"
|
|
2367
|
+
}
|
|
2368
|
+
],
|
|
2369
|
+
"variants": {
|
|
2370
|
+
"level": {
|
|
2371
|
+
"low": {
|
|
2372
|
+
"use": "thin or conflicting evidence. One bar, warning colour"
|
|
2373
|
+
},
|
|
2374
|
+
"medium": {
|
|
2375
|
+
"use": "reasonable support with real gaps. Two bars"
|
|
2376
|
+
},
|
|
2377
|
+
"high": {
|
|
2378
|
+
"use": "corroborated, and you can say by what. Three bars"
|
|
2379
|
+
}
|
|
2380
|
+
}
|
|
2381
|
+
},
|
|
2382
|
+
"a11y": {
|
|
2383
|
+
"guarantees": [
|
|
2384
|
+
"the level is spelled out in text, so it never depends on the meter",
|
|
2385
|
+
"the meter differs in filled COUNT rather than only in colour, and in forced-colours mode filled bars are solid while empty ones are outlined"
|
|
2386
|
+
],
|
|
2387
|
+
"requires": [
|
|
2388
|
+
"`basis` — a type error if omitted, and the reason this component exists rather than a coloured dot"
|
|
2389
|
+
]
|
|
2390
|
+
},
|
|
2391
|
+
"antiPatterns": [
|
|
2392
|
+
{
|
|
2393
|
+
"dont": "asking for a percentage prop",
|
|
2394
|
+
"why": "\"87% confident\" reads as a measurement and almost never is one — usually a softmax score or a model's claim about itself, neither of which is a calibrated probability. Three levels cannot overclaim that way"
|
|
2395
|
+
},
|
|
2396
|
+
{
|
|
2397
|
+
"dont": "a vague basis like \"model output\"",
|
|
2398
|
+
"why": "it satisfies the type and defeats the purpose — say \"3 of 4 sources agree\" or \"single unverified source\""
|
|
2399
|
+
},
|
|
2400
|
+
{
|
|
2401
|
+
"dont": "high confidence on every response",
|
|
2402
|
+
"why": "an indicator that never varies is decoration that still changes behaviour"
|
|
2403
|
+
}
|
|
2404
|
+
],
|
|
2405
|
+
"stylesheet": "src/styles/confidence-indicator.css",
|
|
2406
|
+
"tokens": [
|
|
2407
|
+
"--border-width-default",
|
|
2408
|
+
"--font-family-sans",
|
|
2409
|
+
"--font-weight-medium",
|
|
2410
|
+
"--icon-information",
|
|
2411
|
+
"--icon-success",
|
|
2412
|
+
"--icon-tertiary",
|
|
2413
|
+
"--icon-warning",
|
|
2414
|
+
"--radius-2xs",
|
|
2415
|
+
"--spacing-12",
|
|
2416
|
+
"--spacing-16",
|
|
2417
|
+
"--spacing-2",
|
|
2418
|
+
"--spacing-4",
|
|
2419
|
+
"--spacing-8",
|
|
2420
|
+
"--text-default",
|
|
2421
|
+
"--text-secondary",
|
|
2422
|
+
"--text-tertiary",
|
|
2423
|
+
"--type-caption",
|
|
2424
|
+
"--type-caption-line-height"
|
|
2425
|
+
],
|
|
2426
|
+
"props": {
|
|
2427
|
+
"level": {
|
|
2428
|
+
"type": "ConfidenceLevel",
|
|
2429
|
+
"required": true,
|
|
2430
|
+
"origin": "own",
|
|
2431
|
+
"values": [
|
|
2432
|
+
"low",
|
|
2433
|
+
"medium",
|
|
2434
|
+
"high"
|
|
2435
|
+
]
|
|
2436
|
+
},
|
|
2437
|
+
"basis": {
|
|
2438
|
+
"type": "string",
|
|
2439
|
+
"required": true,
|
|
2440
|
+
"origin": "own",
|
|
2441
|
+
"description": "What the level is based on. REQUIRED, and the reason this component exists\nrather than a coloured dot: a confidence with no stated basis is a number\nthe reader has no way to weigh. \"3 of 4 sources agree\", \"no matching\nrecords found\", \"single unverified source\"."
|
|
2442
|
+
},
|
|
2443
|
+
"label": {
|
|
2444
|
+
"type": "string | undefined",
|
|
2445
|
+
"required": false,
|
|
2446
|
+
"origin": "own",
|
|
2447
|
+
"description": "Override the level's word. Keep it a word, not a percentage."
|
|
2448
|
+
}
|
|
2449
|
+
},
|
|
2450
|
+
"propCounts": {
|
|
2451
|
+
"own": 3,
|
|
2452
|
+
"aria": 0,
|
|
2453
|
+
"dom": 277,
|
|
2454
|
+
"other": 0
|
|
2455
|
+
}
|
|
2456
|
+
},
|
|
1839
2457
|
"Divider": {
|
|
1840
2458
|
"name": "Divider",
|
|
1841
2459
|
"source": "src/components/Divider.tsx",
|
|
@@ -2552,13 +3170,13 @@
|
|
|
2552
3170
|
"description": "Identifies the element (or elements) whose contents or presence are controlled by the current\nelement."
|
|
2553
3171
|
},
|
|
2554
3172
|
"enterKeyHint": {
|
|
2555
|
-
"type": "\"
|
|
3173
|
+
"type": "\"done\" | \"enter\" | \"go\" | \"next\" | \"previous\" | \"search\" | \"send\" | undefined",
|
|
2556
3174
|
"required": false,
|
|
2557
3175
|
"origin": "aria",
|
|
2558
3176
|
"description": "An enumerated attribute that defines what action label or icon to preset for the enter key on\nvirtual keyboards. See\n[MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/enterkeyhint).",
|
|
2559
3177
|
"values": [
|
|
2560
|
-
"enter",
|
|
2561
3178
|
"done",
|
|
3179
|
+
"enter",
|
|
2562
3180
|
"go",
|
|
2563
3181
|
"next",
|
|
2564
3182
|
"previous",
|
|
@@ -4149,13 +4767,13 @@
|
|
|
4149
4767
|
"description": "Class names for the control box (`.ion-input`). Always lands here —\nnever on the form-field wrapper. Use `wrapperClassName` for that."
|
|
4150
4768
|
},
|
|
4151
4769
|
"enterKeyHint": {
|
|
4152
|
-
"type": "\"
|
|
4770
|
+
"type": "\"done\" | \"enter\" | \"go\" | \"next\" | \"previous\" | \"search\" | \"send\" | undefined",
|
|
4153
4771
|
"required": false,
|
|
4154
4772
|
"origin": "aria",
|
|
4155
4773
|
"description": "An enumerated attribute that defines what action label or icon to preset for the enter key on\nvirtual keyboards. See\n[MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/enterkeyhint).",
|
|
4156
4774
|
"values": [
|
|
4157
|
-
"enter",
|
|
4158
4775
|
"done",
|
|
4776
|
+
"enter",
|
|
4159
4777
|
"go",
|
|
4160
4778
|
"next",
|
|
4161
4779
|
"previous",
|
|
@@ -5394,6 +6012,105 @@
|
|
|
5394
6012
|
"other": 0
|
|
5395
6013
|
}
|
|
5396
6014
|
},
|
|
6015
|
+
"StreamingText": {
|
|
6016
|
+
"name": "StreamingText",
|
|
6017
|
+
"source": "src/components/StreamingText.tsx",
|
|
6018
|
+
"propsType": "StreamingTextProps",
|
|
6019
|
+
"description": "StreamingText — model output arriving a token at a time.\n\nIT IS NOT A LIVE REGION, AND THAT IS THE WHOLE DESIGN\n\nThe obvious implementation — `aria-live=\"polite\"` on the container — is the\none that makes a screen reader unusable. Every token mutation queues an\nannouncement, so the user hears the answer re-read, stuttered, dozens of\ntimes, and cannot get ahead of it. `aria-live=\"off\"` is not an oversight\nhere; it is the accessible choice.\n\nWhat it does instead: `aria-busy` while streaming, so assistive tech knows\nthe region is unsettled and can wait. The text is ordinary readable content\nthroughout — a screen-reader user navigates into it whenever they want,\nexactly like sighted users reading ahead of the cursor.\n\nANNOUNCING COMPLETION IS THE CALLER'S CALL, not this component's. Some\nsurfaces want \"response complete\"; a chat with ten turns on screen does not\nwant ten of them. Render your own `role=\"status\"` when you want it.\n\nTHE HEIGHT IS RESERVED, NOT ANIMATED. `minLines` holds space in `lh` units so\nthe content below stays still. A container that grows token by token drags\nthe whole page, which is worse for someone using magnification than the wait.\n\nThe cursor is CSS and `aria-hidden`. It stops blinking under\n`prefers-reduced-motion` — a blinking element is a WCAG 2.3.1 concern and a\ngenuine problem for some vestibular and attention conditions.",
|
|
6020
|
+
"import": "import { StreamingText } from 'ionbase-ui';",
|
|
6021
|
+
"status": "stable",
|
|
6022
|
+
"summary": "Model output arriving a token at a time, in a container that does not move. Deliberately not a live region.",
|
|
6023
|
+
"useWhen": [
|
|
6024
|
+
"rendering a response that streams in rather than arriving whole",
|
|
6025
|
+
"the reader should be able to start reading before generation finishes"
|
|
6026
|
+
],
|
|
6027
|
+
"useInstead": [
|
|
6028
|
+
{
|
|
6029
|
+
"when": "the text is already complete",
|
|
6030
|
+
"use": "Alert",
|
|
6031
|
+
"why": "nothing about this component helps once there is nothing left to arrive"
|
|
6032
|
+
},
|
|
6033
|
+
{
|
|
6034
|
+
"when": "you are showing progress through steps rather than producing text",
|
|
6035
|
+
"use": "AgentActivity"
|
|
6036
|
+
}
|
|
6037
|
+
],
|
|
6038
|
+
"a11y": {
|
|
6039
|
+
"role": "region when `label` is set, none otherwise",
|
|
6040
|
+
"guarantees": [
|
|
6041
|
+
"`aria-live=\"off\"`, deliberately — a polite live region re-announces the whole answer on every token, which makes a streaming response unusable with a screen reader",
|
|
6042
|
+
"`aria-busy` while streaming, so assistive tech knows the region is unsettled",
|
|
6043
|
+
"the text stays ordinary readable content throughout, so a screen-reader user can read ahead exactly as a sighted user does",
|
|
6044
|
+
"the cursor is `aria-hidden`, is a styled box rather than a text character, and stops blinking under `prefers-reduced-motion` (WCAG 2.3.1)"
|
|
6045
|
+
],
|
|
6046
|
+
"requires": [
|
|
6047
|
+
"announcing completion yourself, with your own `role=\"status\"`, if the surface wants it — a chat with ten turns on screen does not want ten announcements",
|
|
6048
|
+
"`label` when the region needs a name of its own"
|
|
6049
|
+
]
|
|
6050
|
+
},
|
|
6051
|
+
"antiPatterns": [
|
|
6052
|
+
{
|
|
6053
|
+
"dont": "wrapping it in `aria-live=\"polite\"`",
|
|
6054
|
+
"why": "every token queues an announcement; the user hears the answer stuttered dozens of times and cannot get ahead of it"
|
|
6055
|
+
},
|
|
6056
|
+
{
|
|
6057
|
+
"dont": "letting the container grow token by token with no reserved height",
|
|
6058
|
+
"do": "`minLines`",
|
|
6059
|
+
"why": "the content below climbs the screen while someone is reading it, which is worse under magnification than the wait"
|
|
6060
|
+
},
|
|
6061
|
+
{
|
|
6062
|
+
"dont": "a text-character cursor like ▌",
|
|
6063
|
+
"why": "some screen readers read it aloud even inside an aria-hidden span"
|
|
6064
|
+
}
|
|
6065
|
+
],
|
|
6066
|
+
"stylesheet": "src/styles/streaming-text.css",
|
|
6067
|
+
"tokens": [
|
|
6068
|
+
"--font-family-sans",
|
|
6069
|
+
"--ion-streaming-min-lines",
|
|
6070
|
+
"--text-default",
|
|
6071
|
+
"--text-tertiary",
|
|
6072
|
+
"--type-body",
|
|
6073
|
+
"--type-body-line-height"
|
|
6074
|
+
],
|
|
6075
|
+
"props": {
|
|
6076
|
+
"children": {
|
|
6077
|
+
"type": "React.ReactNode",
|
|
6078
|
+
"required": false,
|
|
6079
|
+
"origin": "own",
|
|
6080
|
+
"description": "The text so far. Re-render with more of it; this component appends nothing."
|
|
6081
|
+
},
|
|
6082
|
+
"isStreaming": {
|
|
6083
|
+
"type": "boolean | undefined",
|
|
6084
|
+
"required": false,
|
|
6085
|
+
"origin": "own",
|
|
6086
|
+
"description": "More is still arriving. Shows the cursor and marks the region busy."
|
|
6087
|
+
},
|
|
6088
|
+
"minLines": {
|
|
6089
|
+
"type": "number | undefined",
|
|
6090
|
+
"required": false,
|
|
6091
|
+
"origin": "own",
|
|
6092
|
+
"description": "Rows of height to hold while the text is short, so the page below does not\nclimb the screen as tokens arrive. Costs blank space at the start and buys\na layout that does not move under a reader."
|
|
6093
|
+
},
|
|
6094
|
+
"label": {
|
|
6095
|
+
"type": "string | undefined",
|
|
6096
|
+
"required": false,
|
|
6097
|
+
"origin": "own",
|
|
6098
|
+
"description": "Accessible name for the region."
|
|
6099
|
+
},
|
|
6100
|
+
"hideCursor": {
|
|
6101
|
+
"type": "boolean | undefined",
|
|
6102
|
+
"required": false,
|
|
6103
|
+
"origin": "own",
|
|
6104
|
+
"description": "Hide the trailing cursor. The text still marks itself busy."
|
|
6105
|
+
}
|
|
6106
|
+
},
|
|
6107
|
+
"propCounts": {
|
|
6108
|
+
"own": 5,
|
|
6109
|
+
"aria": 0,
|
|
6110
|
+
"dom": 277,
|
|
6111
|
+
"other": 0
|
|
6112
|
+
}
|
|
6113
|
+
},
|
|
5397
6114
|
"TabItem": {
|
|
5398
6115
|
"name": "TabItem",
|
|
5399
6116
|
"source": "../../node_modules/.pnpm/react-stately@3.48.0_react@19.2.8/node_modules/react-stately/dist/types/src/collections/Item.d.ts",
|