@joralvmel/cosmos-core 0.1.0 → 0.3.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/catalog.d.ts +3 -3
- package/dist/catalog.d.ts.map +1 -1
- package/dist/catalog.js +15 -3
- package/dist/catalog.js.map +1 -1
- package/dist/codegen.d.ts +10 -0
- package/dist/codegen.d.ts.map +1 -1
- package/dist/codegen.js +259 -29
- package/dist/codegen.js.map +1 -1
- package/dist/contract.d.ts +33 -4
- package/dist/contract.d.ts.map +1 -1
- package/dist/contract.js +2 -2
- package/dist/contract.js.map +1 -1
- package/dist/headless/listbox.d.ts +9 -0
- package/dist/headless/listbox.d.ts.map +1 -0
- package/dist/headless/listbox.js +107 -0
- package/dist/headless/listbox.js.map +1 -0
- package/dist/headless/text-field.d.ts +25 -0
- package/dist/headless/text-field.d.ts.map +1 -0
- package/dist/headless/text-field.js +12 -0
- package/dist/headless/text-field.js.map +1 -0
- package/dist/index.d.ts +702 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +23 -1
- package/dist/index.js.map +1 -1
- package/dist/markdown.d.ts.map +1 -1
- package/dist/markdown.js +24 -5
- package/dist/markdown.js.map +1 -1
- package/dist/specs/icon-button.d.ts +136 -0
- package/dist/specs/icon-button.d.ts.map +1 -0
- package/dist/specs/icon-button.js +119 -0
- package/dist/specs/icon-button.js.map +1 -0
- package/dist/specs/icon-button.scenarios.d.ts +28 -0
- package/dist/specs/icon-button.scenarios.d.ts.map +1 -0
- package/dist/specs/icon-button.scenarios.js +95 -0
- package/dist/specs/icon-button.scenarios.js.map +1 -0
- package/dist/specs/icon.d.ts +66 -0
- package/dist/specs/icon.d.ts.map +1 -0
- package/dist/specs/icon.js +58 -0
- package/dist/specs/icon.js.map +1 -0
- package/dist/specs/icon.scenarios.d.ts +19 -0
- package/dist/specs/icon.scenarios.d.ts.map +1 -0
- package/dist/specs/icon.scenarios.js +25 -0
- package/dist/specs/icon.scenarios.js.map +1 -0
- package/dist/specs/listbox.d.ts +162 -0
- package/dist/specs/listbox.d.ts.map +1 -0
- package/dist/specs/listbox.js +144 -0
- package/dist/specs/listbox.js.map +1 -0
- package/dist/specs/listbox.scenarios.d.ts +37 -0
- package/dist/specs/listbox.scenarios.d.ts.map +1 -0
- package/dist/specs/listbox.scenarios.js +110 -0
- package/dist/specs/listbox.scenarios.js.map +1 -0
- package/dist/specs/popover.d.ts +213 -0
- package/dist/specs/popover.d.ts.map +1 -0
- package/dist/specs/popover.js +181 -0
- package/dist/specs/popover.js.map +1 -0
- package/dist/specs/popover.scenarios.d.ts +77 -0
- package/dist/specs/popover.scenarios.d.ts.map +1 -0
- package/dist/specs/popover.scenarios.js +368 -0
- package/dist/specs/popover.scenarios.js.map +1 -0
- package/dist/specs/text-field.d.ts +246 -0
- package/dist/specs/text-field.d.ts.map +1 -0
- package/dist/specs/text-field.js +229 -0
- package/dist/specs/text-field.js.map +1 -0
- package/dist/specs/text-field.scenarios.d.ts +49 -0
- package/dist/specs/text-field.scenarios.d.ts.map +1 -0
- package/dist/specs/text-field.scenarios.js +88 -0
- package/dist/specs/text-field.scenarios.js.map +1 -0
- package/llms.md +292 -0
- package/package.json +1 -1
|
@@ -0,0 +1,368 @@
|
|
|
1
|
+
const opening = { open: true, reason: 'trigger', canceled: false };
|
|
2
|
+
const closing = (reason, canceled = false) => ({
|
|
3
|
+
open: false,
|
|
4
|
+
reason,
|
|
5
|
+
canceled,
|
|
6
|
+
});
|
|
7
|
+
/**
|
|
8
|
+
* Shared normative cases, not a platform implementation. Drivers use a first focusable
|
|
9
|
+
* panel child unless the fixture opts out. "panel" includes the panel or a descendant;
|
|
10
|
+
* "panel-first" specifically asserts the initial-focus target. For outside presses on
|
|
11
|
+
* a nonfocusable target, the fixture preserves focus so lack of restoration is observable.
|
|
12
|
+
* Native Escape cases exercise React Native Web; hardware Escape is not supported on Android
|
|
13
|
+
* or iOS. Back cases are native Android cases; native drivers must run them in Android mode.
|
|
14
|
+
*/
|
|
15
|
+
export const popoverScenarios = [
|
|
16
|
+
...[false, true].map((cancel) => ({
|
|
17
|
+
name: `close button ${cancel ? 'respects cancellation' : 'closes autonomous state'}`,
|
|
18
|
+
props: { defaultOpen: true, closable: true },
|
|
19
|
+
actions: [{ type: 'close-button', cancel }],
|
|
20
|
+
expected: {
|
|
21
|
+
open: cancel,
|
|
22
|
+
openAfterEachAction: [cancel],
|
|
23
|
+
changes: [closing('close-button', cancel)],
|
|
24
|
+
focus: 'trigger',
|
|
25
|
+
outsidePresses: 0,
|
|
26
|
+
},
|
|
27
|
+
})),
|
|
28
|
+
{
|
|
29
|
+
name: 'closed by default without a proposal',
|
|
30
|
+
props: {},
|
|
31
|
+
actions: [],
|
|
32
|
+
expected: {
|
|
33
|
+
open: false,
|
|
34
|
+
openAfterEachAction: [],
|
|
35
|
+
changes: [],
|
|
36
|
+
focus: 'trigger',
|
|
37
|
+
outsidePresses: 0,
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
...['pointer', 'touch', 'keyboard'].map((source) => ({
|
|
41
|
+
name: `${source} trigger toggles autonomous state once per activation`,
|
|
42
|
+
props: {},
|
|
43
|
+
actions: [
|
|
44
|
+
{ type: 'trigger', source },
|
|
45
|
+
{ type: 'trigger', source },
|
|
46
|
+
],
|
|
47
|
+
expected: {
|
|
48
|
+
open: false,
|
|
49
|
+
openAfterEachAction: [true, false],
|
|
50
|
+
changes: [opening, closing('trigger')],
|
|
51
|
+
focus: 'trigger',
|
|
52
|
+
outsidePresses: 0,
|
|
53
|
+
},
|
|
54
|
+
...(source === 'keyboard' ? { platforms: ['web', 'react', 'angular'] } : {}),
|
|
55
|
+
})),
|
|
56
|
+
{
|
|
57
|
+
name: 'defaultOpen initializes autonomous state but later defaults do not reset it',
|
|
58
|
+
props: { defaultOpen: true },
|
|
59
|
+
actions: [{ type: 'set-default', defaultOpen: false }],
|
|
60
|
+
expected: {
|
|
61
|
+
open: true,
|
|
62
|
+
openAfterEachAction: [true],
|
|
63
|
+
changes: [],
|
|
64
|
+
focus: 'trigger',
|
|
65
|
+
outsidePresses: 0,
|
|
66
|
+
},
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
name: 'controlled false overrides defaultOpen and refuses repeated open proposals',
|
|
70
|
+
props: { open: false, defaultOpen: true, initialFocus: true },
|
|
71
|
+
actions: [
|
|
72
|
+
{ type: 'trigger', source: 'pointer' },
|
|
73
|
+
{ type: 'trigger', source: 'pointer' },
|
|
74
|
+
],
|
|
75
|
+
expected: {
|
|
76
|
+
open: false,
|
|
77
|
+
openAfterEachAction: [false, false],
|
|
78
|
+
changes: [opening, opening],
|
|
79
|
+
focus: 'trigger',
|
|
80
|
+
outsidePresses: 0,
|
|
81
|
+
},
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
name: 'controlled acceptance waits for sync and prop updates emit no proposals',
|
|
85
|
+
props: { open: false, initialFocus: true },
|
|
86
|
+
actions: [
|
|
87
|
+
{ type: 'trigger', source: 'pointer' },
|
|
88
|
+
{ type: 'sync', open: true },
|
|
89
|
+
{ type: 'action' },
|
|
90
|
+
{ type: 'sync', open: false },
|
|
91
|
+
],
|
|
92
|
+
expected: {
|
|
93
|
+
open: false,
|
|
94
|
+
openAfterEachAction: [false, true, true, false],
|
|
95
|
+
changes: [opening, closing('action')],
|
|
96
|
+
focus: 'trigger',
|
|
97
|
+
outsidePresses: 0,
|
|
98
|
+
},
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
name: 'unsolicited controlled opening applies without a proposal',
|
|
102
|
+
props: { open: false, initialFocus: true },
|
|
103
|
+
actions: [{ type: 'sync', open: true }],
|
|
104
|
+
expected: {
|
|
105
|
+
open: true,
|
|
106
|
+
openAfterEachAction: [true],
|
|
107
|
+
changes: [],
|
|
108
|
+
focus: 'panel-first',
|
|
109
|
+
outsidePresses: 0,
|
|
110
|
+
},
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
name: 'controlled close proposals leave the panel and its focus unchanged',
|
|
114
|
+
props: { open: true, initialFocus: true },
|
|
115
|
+
actions: [{ type: 'action' }, { type: 'escape' }],
|
|
116
|
+
expected: {
|
|
117
|
+
open: true,
|
|
118
|
+
openAfterEachAction: [true, true],
|
|
119
|
+
changes: [closing('action'), closing('escape')],
|
|
120
|
+
focus: 'panel-first',
|
|
121
|
+
outsidePresses: 0,
|
|
122
|
+
},
|
|
123
|
+
},
|
|
124
|
+
...['trigger', 'escape', 'outside', 'action', 'back'].flatMap((reason) => [false, true].map(canceled => ({
|
|
125
|
+
name: `${reason} close ${canceled ? 'can be canceled' : 'commits autonomously'}`,
|
|
126
|
+
props: { defaultOpen: true, initialFocus: true },
|
|
127
|
+
actions: reason === 'trigger'
|
|
128
|
+
? [
|
|
129
|
+
{ type: 'focus', target: 'trigger' },
|
|
130
|
+
{ type: 'trigger', source: 'pointer', cancel: canceled },
|
|
131
|
+
]
|
|
132
|
+
: [
|
|
133
|
+
reason === 'outside'
|
|
134
|
+
? { type: 'outside', focusable: true, cancel: canceled }
|
|
135
|
+
: { type: reason, cancel: canceled },
|
|
136
|
+
],
|
|
137
|
+
expected: {
|
|
138
|
+
open: canceled,
|
|
139
|
+
openAfterEachAction: reason === 'trigger' ? [true, canceled] : [canceled],
|
|
140
|
+
changes: [closing(reason, canceled)],
|
|
141
|
+
focus: reason === 'outside'
|
|
142
|
+
? 'outside'
|
|
143
|
+
: reason !== 'trigger' && canceled
|
|
144
|
+
? 'panel-first'
|
|
145
|
+
: 'trigger',
|
|
146
|
+
outsidePresses: reason === 'outside' ? 1 : 0,
|
|
147
|
+
},
|
|
148
|
+
...(reason === 'back' ? { platforms: ['native'] } : {}),
|
|
149
|
+
}))),
|
|
150
|
+
{
|
|
151
|
+
name: 'controlled action cancellation is visible to the owner without committing',
|
|
152
|
+
props: { open: true, initialFocus: true },
|
|
153
|
+
actions: [{ type: 'action', cancel: true }],
|
|
154
|
+
expected: {
|
|
155
|
+
open: true,
|
|
156
|
+
openAfterEachAction: [true],
|
|
157
|
+
changes: [closing('action', true)],
|
|
158
|
+
focus: 'panel-first',
|
|
159
|
+
outsidePresses: 0,
|
|
160
|
+
},
|
|
161
|
+
},
|
|
162
|
+
{
|
|
163
|
+
name: 'disabled dismissal policies do not suppress explicit panel actions',
|
|
164
|
+
props: { defaultOpen: true, closeOnEscape: false, closeOnOutsidePress: false },
|
|
165
|
+
actions: [{ type: 'escape' }, { type: 'outside', focusable: true }, { type: 'action' }],
|
|
166
|
+
expected: {
|
|
167
|
+
open: false,
|
|
168
|
+
openAfterEachAction: [true, true, false],
|
|
169
|
+
changes: [closing('action')],
|
|
170
|
+
focus: 'outside',
|
|
171
|
+
outsidePresses: 1,
|
|
172
|
+
},
|
|
173
|
+
},
|
|
174
|
+
{
|
|
175
|
+
name: 'disabling Escape still permits outside dismissal',
|
|
176
|
+
props: { defaultOpen: true, closeOnEscape: false },
|
|
177
|
+
actions: [{ type: 'escape' }, { type: 'outside', focusable: true }],
|
|
178
|
+
expected: {
|
|
179
|
+
open: false,
|
|
180
|
+
openAfterEachAction: [true, false],
|
|
181
|
+
changes: [closing('outside')],
|
|
182
|
+
focus: 'outside',
|
|
183
|
+
outsidePresses: 1,
|
|
184
|
+
},
|
|
185
|
+
},
|
|
186
|
+
{
|
|
187
|
+
name: 'disabling outside dismissal still permits Escape',
|
|
188
|
+
props: { defaultOpen: true, closeOnOutsidePress: false },
|
|
189
|
+
actions: [{ type: 'outside', focusable: true }, { type: 'escape' }],
|
|
190
|
+
expected: {
|
|
191
|
+
open: false,
|
|
192
|
+
openAfterEachAction: [true, false],
|
|
193
|
+
changes: [closing('escape')],
|
|
194
|
+
focus: 'outside',
|
|
195
|
+
outsidePresses: 1,
|
|
196
|
+
},
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
name: 'Android Back is independent of Escape and outside dismissal policies',
|
|
200
|
+
props: { defaultOpen: true, closeOnEscape: false, closeOnOutsidePress: false },
|
|
201
|
+
actions: [{ type: 'back' }],
|
|
202
|
+
expected: {
|
|
203
|
+
open: false,
|
|
204
|
+
openAfterEachAction: [false],
|
|
205
|
+
changes: [closing('back')],
|
|
206
|
+
focus: 'trigger',
|
|
207
|
+
outsidePresses: 0,
|
|
208
|
+
},
|
|
209
|
+
platforms: ['native'],
|
|
210
|
+
},
|
|
211
|
+
{
|
|
212
|
+
name: 'a child-handled Escape is ignored',
|
|
213
|
+
props: { defaultOpen: true },
|
|
214
|
+
actions: [{ type: 'escape', handled: true }],
|
|
215
|
+
expected: {
|
|
216
|
+
open: true,
|
|
217
|
+
openAfterEachAction: [true],
|
|
218
|
+
changes: [],
|
|
219
|
+
focus: 'trigger',
|
|
220
|
+
outsidePresses: 0,
|
|
221
|
+
},
|
|
222
|
+
platforms: ['web', 'react', 'angular'],
|
|
223
|
+
},
|
|
224
|
+
{
|
|
225
|
+
name: 'dismissals and action requests while closed emit nothing',
|
|
226
|
+
props: {},
|
|
227
|
+
actions: [{ type: 'escape' }, { type: 'action' }, { type: 'outside', focusable: true }],
|
|
228
|
+
expected: {
|
|
229
|
+
open: false,
|
|
230
|
+
openAfterEachAction: [false, false, false],
|
|
231
|
+
changes: [],
|
|
232
|
+
focus: 'outside',
|
|
233
|
+
outsidePresses: 1,
|
|
234
|
+
},
|
|
235
|
+
},
|
|
236
|
+
{
|
|
237
|
+
name: 'initial focus falls back to the panel without focusable descendants',
|
|
238
|
+
props: { initialFocus: true },
|
|
239
|
+
fixture: { panelHasFocusableContent: false },
|
|
240
|
+
actions: [{ type: 'trigger', source: 'pointer' }],
|
|
241
|
+
expected: {
|
|
242
|
+
open: true,
|
|
243
|
+
openAfterEachAction: [true],
|
|
244
|
+
changes: [opening],
|
|
245
|
+
focus: 'panel',
|
|
246
|
+
outsidePresses: 0,
|
|
247
|
+
},
|
|
248
|
+
},
|
|
249
|
+
{
|
|
250
|
+
name: 'outside closure never restores even if its target cannot take focus',
|
|
251
|
+
props: { defaultOpen: true, initialFocus: true },
|
|
252
|
+
actions: [{ type: 'outside', focusable: false }],
|
|
253
|
+
expected: {
|
|
254
|
+
open: false,
|
|
255
|
+
openAfterEachAction: [false],
|
|
256
|
+
changes: [closing('outside')],
|
|
257
|
+
focus: 'unmanaged',
|
|
258
|
+
outsidePresses: 1,
|
|
259
|
+
},
|
|
260
|
+
},
|
|
261
|
+
{
|
|
262
|
+
name: 'an outside controlled proposal still delivers the outside interaction',
|
|
263
|
+
props: { open: true, initialFocus: true },
|
|
264
|
+
actions: [{ type: 'outside', focusable: true }],
|
|
265
|
+
expected: {
|
|
266
|
+
open: true,
|
|
267
|
+
openAfterEachAction: [true],
|
|
268
|
+
changes: [closing('outside')],
|
|
269
|
+
focus: 'outside',
|
|
270
|
+
outsidePresses: 1,
|
|
271
|
+
},
|
|
272
|
+
},
|
|
273
|
+
{
|
|
274
|
+
name: 'restoration can be disabled',
|
|
275
|
+
props: { defaultOpen: true, initialFocus: true, restoreFocus: false },
|
|
276
|
+
actions: [{ type: 'action' }],
|
|
277
|
+
expected: {
|
|
278
|
+
open: false,
|
|
279
|
+
openAfterEachAction: [false],
|
|
280
|
+
changes: [closing('action')],
|
|
281
|
+
focus: 'unmanaged',
|
|
282
|
+
outsidePresses: 0,
|
|
283
|
+
},
|
|
284
|
+
},
|
|
285
|
+
{
|
|
286
|
+
name: 'restoration does not steal focus moved outside before owner acceptance',
|
|
287
|
+
props: { open: true, initialFocus: true },
|
|
288
|
+
actions: [
|
|
289
|
+
{ type: 'escape' },
|
|
290
|
+
{ type: 'focus', target: 'outside' },
|
|
291
|
+
{ type: 'sync', open: false },
|
|
292
|
+
],
|
|
293
|
+
expected: {
|
|
294
|
+
open: false,
|
|
295
|
+
openAfterEachAction: [true, true, false],
|
|
296
|
+
changes: [closing('escape')],
|
|
297
|
+
focus: 'outside',
|
|
298
|
+
outsidePresses: 0,
|
|
299
|
+
},
|
|
300
|
+
},
|
|
301
|
+
{
|
|
302
|
+
name: 'an unsolicited controlled close does not restore focus',
|
|
303
|
+
props: { open: true, initialFocus: true },
|
|
304
|
+
actions: [{ type: 'sync', open: false }],
|
|
305
|
+
expected: {
|
|
306
|
+
open: false,
|
|
307
|
+
openAfterEachAction: [false],
|
|
308
|
+
changes: [],
|
|
309
|
+
focus: 'unmanaged',
|
|
310
|
+
outsidePresses: 0,
|
|
311
|
+
},
|
|
312
|
+
},
|
|
313
|
+
{
|
|
314
|
+
name: 'the latest close reason supersedes an earlier controlled proposal',
|
|
315
|
+
props: { open: true, initialFocus: true },
|
|
316
|
+
actions: [
|
|
317
|
+
{ type: 'escape' },
|
|
318
|
+
{ type: 'outside', focusable: false },
|
|
319
|
+
{ type: 'sync', open: false },
|
|
320
|
+
],
|
|
321
|
+
expected: {
|
|
322
|
+
open: false,
|
|
323
|
+
openAfterEachAction: [true, true, false],
|
|
324
|
+
changes: [closing('escape'), closing('outside')],
|
|
325
|
+
focus: 'unmanaged',
|
|
326
|
+
outsidePresses: 1,
|
|
327
|
+
},
|
|
328
|
+
},
|
|
329
|
+
{
|
|
330
|
+
name: 'a canceled proposal clears any earlier restoration intent',
|
|
331
|
+
props: { open: true, initialFocus: true },
|
|
332
|
+
actions: [{ type: 'escape' }, { type: 'action', cancel: true }, { type: 'sync', open: false }],
|
|
333
|
+
expected: {
|
|
334
|
+
open: false,
|
|
335
|
+
openAfterEachAction: [true, true, false],
|
|
336
|
+
changes: [closing('escape'), closing('action', true)],
|
|
337
|
+
focus: 'unmanaged',
|
|
338
|
+
outsidePresses: 0,
|
|
339
|
+
},
|
|
340
|
+
},
|
|
341
|
+
{
|
|
342
|
+
name: 'restoration requires a usable trigger',
|
|
343
|
+
props: { defaultOpen: true, initialFocus: true },
|
|
344
|
+
fixture: { triggerFocusable: false },
|
|
345
|
+
actions: [{ type: 'action' }],
|
|
346
|
+
expected: {
|
|
347
|
+
open: false,
|
|
348
|
+
openAfterEachAction: [false],
|
|
349
|
+
changes: [closing('action')],
|
|
350
|
+
focus: 'unmanaged',
|
|
351
|
+
outsidePresses: 0,
|
|
352
|
+
},
|
|
353
|
+
},
|
|
354
|
+
{
|
|
355
|
+
name: 'focus leaving the panel alone does not dismiss',
|
|
356
|
+
props: { defaultOpen: true },
|
|
357
|
+
actions: [{ type: 'focus', target: 'outside' }],
|
|
358
|
+
expected: {
|
|
359
|
+
open: true,
|
|
360
|
+
openAfterEachAction: [true],
|
|
361
|
+
changes: [],
|
|
362
|
+
focus: 'outside',
|
|
363
|
+
outsidePresses: 0,
|
|
364
|
+
},
|
|
365
|
+
},
|
|
366
|
+
];
|
|
367
|
+
export const popoverScenariosFor = (platform) => popoverScenarios.filter(scenario => !scenario.platforms || scenario.platforms.includes(platform));
|
|
368
|
+
//# sourceMappingURL=popover.scenarios.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"popover.scenarios.js","sourceRoot":"","sources":["../../src/specs/popover.scenarios.ts"],"names":[],"mappings":"AA4CA,MAAM,OAAO,GAAG,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,QAAQ,EAAE,KAAK,EAAW,CAAC;AAC5E,MAAM,OAAO,GAAG,CAAC,MAA0B,EAAE,QAAQ,GAAG,KAAK,EAA4B,EAAE,CAAC,CAAC;IAC3F,IAAI,EAAE,KAAK;IACX,MAAM;IACN,QAAQ;CACT,CAAC,CAAC;AAEH;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAA+B;IAC1D,GAAI,CAAC,KAAK,EAAE,IAAI,CAAW,CAAC,GAAG,CAC7B,CAAC,MAAM,EAAmB,EAAE,CAAC,CAAC;QAC5B,IAAI,EAAE,gBAAgB,MAAM,CAAC,CAAC,CAAC,uBAAuB,CAAC,CAAC,CAAC,yBAAyB,EAAE;QACpF,KAAK,EAAE,EAAE,WAAW,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE;QAC5C,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,cAAc,EAAE,MAAM,EAAE,CAAC;QAC3C,QAAQ,EAAE;YACR,IAAI,EAAE,MA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YACrD,KAAK,EAAE,WAAW;YAClB,cAAc,EAAE,CAAC;SAClB;KACF;IACD;QACE,IAAI,EAAE,uCAAuC;QAC7C,KAAK,EAAE,EAAE,WAAW,EAAE,IAAI,EAAE,YAAY,EAAE,IAAI,EAAE;QAChD,OAAO,EAAE,EAAE,gBAAgB,EAAE,KAAK,EAAE;QACpC,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC;QAC7B,QAAQ,EAAE;YACR,IAAI,EAAE,KAAK;YACX,mBAAmB,EAAE,CAAC,KAAK,CAAC;YAC5B,OAAO,EAAE,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC;YAC5B,KAAK,EAAE,WAAW;YAClB,cAAc,EAAE,CAAC;SAClB;KACF;IACD;QACE,IAAI,EAAE,gDAAgD;QACtD,KAAK,EAAE,EAAE,WAAW,EAAE,IAAI,EAAE;QAC5B,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,CAAC;QAC/C,QAAQ,EAAE;YACR,IAAI,EAAE,IAAI;YACV,mBAAmB,EAAE,CAAC,IAAI,CAAC;YAC3B,OAAO,EAAE,EAAE;YACX,KAAK,EAAE,SAAS;YAChB,cAAc,EAAE,CAAC;SAClB;KACF;CACF,CAAC;AAEF,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,QAAkB,EAAE,EAAE,CACxD,gBAAgB,CAAC,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,QAAQ,CAAC,SAAS,IAAI,QAAQ,CAAC,SAAS,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1,246 @@
|
|
|
1
|
+
/** Value proposed when the user edits or clears a text field. */
|
|
2
|
+
export interface TextFieldChangeDetail {
|
|
3
|
+
value: string;
|
|
4
|
+
}
|
|
5
|
+
/** Current value when the user invokes the field's submit action. */
|
|
6
|
+
export interface TextFieldSubmitDetail {
|
|
7
|
+
value: string;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Single-line text entry with an accessible label and native form semantics on the web.
|
|
11
|
+
* The editable value follows the controlled/autonomous ownership rules in ADR 0003.
|
|
12
|
+
*/
|
|
13
|
+
export declare const textFieldContract: {
|
|
14
|
+
readonly name: "text-field";
|
|
15
|
+
readonly tag: "cosm-text-field";
|
|
16
|
+
readonly description: "Accepts a single line of text with an accessible label, optional help and error text, and native form validation on the web.";
|
|
17
|
+
readonly role: "textbox";
|
|
18
|
+
readonly pattern: "https://html.spec.whatwg.org/multipage/input.html";
|
|
19
|
+
readonly props: {
|
|
20
|
+
readonly label: {
|
|
21
|
+
readonly type: "string";
|
|
22
|
+
readonly required: true;
|
|
23
|
+
readonly description: "Accessible name for the editable control. It is rendered above the control unless visually hidden.";
|
|
24
|
+
};
|
|
25
|
+
readonly labelHidden: {
|
|
26
|
+
readonly type: "boolean";
|
|
27
|
+
readonly default: false;
|
|
28
|
+
readonly reflect: true;
|
|
29
|
+
readonly description: "Visually hides the label while keeping it available to assistive technology.";
|
|
30
|
+
};
|
|
31
|
+
readonly value: {
|
|
32
|
+
readonly type: "string";
|
|
33
|
+
readonly description: "Current text. When bound, edits are proposals and the component waits for the owner to supply the accepted value.";
|
|
34
|
+
};
|
|
35
|
+
readonly defaultValue: {
|
|
36
|
+
readonly type: "string";
|
|
37
|
+
readonly default: "";
|
|
38
|
+
readonly description: "Initial value for autonomous use. Web form reset restores this value; it does not control subsequent edits.";
|
|
39
|
+
};
|
|
40
|
+
readonly type: {
|
|
41
|
+
readonly type: "enum";
|
|
42
|
+
readonly values: readonly ["text", "email", "password", "tel", "url", "search"];
|
|
43
|
+
readonly default: "text";
|
|
44
|
+
readonly reflect: true;
|
|
45
|
+
readonly description: "Single-line input type. Native maps it to supported keyboard, autofill and secure-entry behavior.";
|
|
46
|
+
};
|
|
47
|
+
readonly variant: {
|
|
48
|
+
readonly type: "enum";
|
|
49
|
+
readonly values: readonly ["outlined", "filled"];
|
|
50
|
+
readonly default: "outlined";
|
|
51
|
+
readonly reflect: true;
|
|
52
|
+
readonly description: "Visual treatment of the editable control.";
|
|
53
|
+
};
|
|
54
|
+
readonly size: {
|
|
55
|
+
readonly type: "union";
|
|
56
|
+
readonly variants: readonly [{
|
|
57
|
+
readonly type: "enum";
|
|
58
|
+
readonly values: readonly ["sm", "md", "lg"];
|
|
59
|
+
}, {
|
|
60
|
+
readonly type: "number";
|
|
61
|
+
}];
|
|
62
|
+
readonly default: "md";
|
|
63
|
+
readonly reflect: true;
|
|
64
|
+
readonly description: "Semantic size or a positive finite minimum editable-control height in CSS pixels on web and logical units on native.";
|
|
65
|
+
};
|
|
66
|
+
readonly placeholder: {
|
|
67
|
+
readonly type: "string";
|
|
68
|
+
readonly description: "Short input hint; it never replaces the accessible label.";
|
|
69
|
+
};
|
|
70
|
+
readonly helpText: {
|
|
71
|
+
readonly type: "string";
|
|
72
|
+
readonly description: "Optional supporting text associated with the editable control.";
|
|
73
|
+
};
|
|
74
|
+
readonly error: {
|
|
75
|
+
readonly type: "string";
|
|
76
|
+
readonly description: "Optional externally supplied error text associated with the editable control.";
|
|
77
|
+
};
|
|
78
|
+
readonly invalid: {
|
|
79
|
+
readonly type: "boolean";
|
|
80
|
+
readonly default: false;
|
|
81
|
+
readonly reflect: true;
|
|
82
|
+
readonly description: "External invalid state, independent of browser constraints or consumer business validation.";
|
|
83
|
+
};
|
|
84
|
+
readonly required: {
|
|
85
|
+
readonly type: "boolean";
|
|
86
|
+
readonly default: false;
|
|
87
|
+
readonly reflect: true;
|
|
88
|
+
readonly description: "Exposes required semantics. On web, participates in native HTML constraint validation.";
|
|
89
|
+
};
|
|
90
|
+
readonly disabled: {
|
|
91
|
+
readonly type: "boolean";
|
|
92
|
+
readonly default: false;
|
|
93
|
+
readonly reflect: true;
|
|
94
|
+
readonly description: "Disables editing and interaction. On web, follows disabled fieldsets and excludes the value from form submission.";
|
|
95
|
+
};
|
|
96
|
+
readonly readOnly: {
|
|
97
|
+
readonly type: "boolean";
|
|
98
|
+
readonly default: false;
|
|
99
|
+
readonly reflect: true;
|
|
100
|
+
readonly description: "Prevents editing while remaining focusable and form-submittable on web; distinct from disabled.";
|
|
101
|
+
};
|
|
102
|
+
readonly minLength: {
|
|
103
|
+
readonly type: "number";
|
|
104
|
+
readonly description: "Minimum number of characters. Web uses native HTML validity; native business validation remains the consumer’s responsibility.";
|
|
105
|
+
};
|
|
106
|
+
readonly maxLength: {
|
|
107
|
+
readonly type: "number";
|
|
108
|
+
readonly description: "Maximum number of characters. Web uses native HTML validity and native applies supported input limits.";
|
|
109
|
+
};
|
|
110
|
+
readonly pattern: {
|
|
111
|
+
readonly type: "string";
|
|
112
|
+
readonly platforms: readonly ["web", "react", "angular"];
|
|
113
|
+
readonly description: "Web-only HTML pattern constraint. Native does not emulate HTML regular-expression validation.";
|
|
114
|
+
};
|
|
115
|
+
readonly name: {
|
|
116
|
+
readonly type: "string";
|
|
117
|
+
readonly reflect: true;
|
|
118
|
+
readonly platforms: readonly ["web", "react", "angular"];
|
|
119
|
+
readonly description: "Form field name on web. React Native has no HTML form association or name-based submission.";
|
|
120
|
+
};
|
|
121
|
+
readonly autoComplete: {
|
|
122
|
+
readonly type: "string";
|
|
123
|
+
readonly description: "Consumer-provided completion/autofill hint, mapped to attributes supported by each platform.";
|
|
124
|
+
};
|
|
125
|
+
readonly inputMode: {
|
|
126
|
+
readonly type: "union";
|
|
127
|
+
readonly variants: readonly [{
|
|
128
|
+
readonly type: "enum";
|
|
129
|
+
readonly values: readonly ["none", "text", "decimal", "numeric", "tel", "search", "email", "url"];
|
|
130
|
+
}];
|
|
131
|
+
readonly description: "Input or keyboard hint (none, text, decimal, numeric, tel, search, email or url); it does not add numeric or multiline field behavior.";
|
|
132
|
+
};
|
|
133
|
+
readonly startIcon: {
|
|
134
|
+
readonly type: "reference";
|
|
135
|
+
readonly reference: "IconDefinition";
|
|
136
|
+
readonly options: readonly ["search", "house", "heart", "star"];
|
|
137
|
+
readonly example: "search";
|
|
138
|
+
readonly description: "Optional structured decorative icon before the editable text.";
|
|
139
|
+
};
|
|
140
|
+
readonly endIcon: {
|
|
141
|
+
readonly type: "reference";
|
|
142
|
+
readonly reference: "IconDefinition";
|
|
143
|
+
readonly options: readonly ["search", "house", "heart", "star"];
|
|
144
|
+
readonly example: "search";
|
|
145
|
+
readonly description: "Optional structured decorative icon after the editable text.";
|
|
146
|
+
};
|
|
147
|
+
readonly iconFocusScope: {
|
|
148
|
+
readonly type: "enum";
|
|
149
|
+
readonly values: readonly ["control", "input"];
|
|
150
|
+
readonly default: "control";
|
|
151
|
+
readonly reflect: true;
|
|
152
|
+
readonly description: "When configured icon focus colors apply: control includes the input and clear/reveal buttons; input includes only the editable input. Does not change icons without a focus-color override.";
|
|
153
|
+
};
|
|
154
|
+
readonly prefix: {
|
|
155
|
+
readonly type: "string";
|
|
156
|
+
readonly description: "Optional non-interactive text decoration before the editable text.";
|
|
157
|
+
};
|
|
158
|
+
readonly suffix: {
|
|
159
|
+
readonly type: "string";
|
|
160
|
+
readonly description: "Optional non-interactive text decoration after the editable text.";
|
|
161
|
+
};
|
|
162
|
+
readonly clearable: {
|
|
163
|
+
readonly type: "boolean";
|
|
164
|
+
readonly default: false;
|
|
165
|
+
readonly reflect: true;
|
|
166
|
+
readonly description: "Shows a clear action for non-empty editable fields. Supply clearLabel when enabled.";
|
|
167
|
+
};
|
|
168
|
+
readonly clearLabel: {
|
|
169
|
+
readonly type: "string";
|
|
170
|
+
readonly description: "Consumer-supplied localized accessible name for the clear action.";
|
|
171
|
+
};
|
|
172
|
+
readonly passwordReveal: {
|
|
173
|
+
readonly type: "boolean";
|
|
174
|
+
readonly default: false;
|
|
175
|
+
readonly reflect: true;
|
|
176
|
+
readonly description: "Opts into a reveal action for password fields. Supply both revealPasswordLabel and hidePasswordLabel when enabled.";
|
|
177
|
+
};
|
|
178
|
+
readonly revealPasswordLabel: {
|
|
179
|
+
readonly type: "string";
|
|
180
|
+
readonly description: "Consumer-supplied localized accessible name while the password is concealed.";
|
|
181
|
+
};
|
|
182
|
+
readonly hidePasswordLabel: {
|
|
183
|
+
readonly type: "string";
|
|
184
|
+
readonly description: "Consumer-supplied localized accessible name while the password is revealed.";
|
|
185
|
+
};
|
|
186
|
+
};
|
|
187
|
+
readonly events: {
|
|
188
|
+
readonly change: {
|
|
189
|
+
readonly description: "Proposes the current text after each user edit, including clear; this is not a blur/commit event.";
|
|
190
|
+
readonly detail: "TextFieldChangeDetail";
|
|
191
|
+
readonly names: {
|
|
192
|
+
readonly dom: "cosm-change";
|
|
193
|
+
readonly react: "onChange";
|
|
194
|
+
readonly angular: "valueChange";
|
|
195
|
+
readonly native: "onValueChange";
|
|
196
|
+
};
|
|
197
|
+
};
|
|
198
|
+
readonly submit: {
|
|
199
|
+
readonly description: "Reports the current text when the user invokes the field submit action (Enter/return).";
|
|
200
|
+
readonly detail: "TextFieldSubmitDetail";
|
|
201
|
+
readonly names: {
|
|
202
|
+
readonly dom: "cosm-submit";
|
|
203
|
+
readonly react: "onSubmit";
|
|
204
|
+
readonly angular: "submit";
|
|
205
|
+
readonly native: "onSubmitEditing";
|
|
206
|
+
};
|
|
207
|
+
};
|
|
208
|
+
};
|
|
209
|
+
readonly states: readonly [{
|
|
210
|
+
readonly prop: "value";
|
|
211
|
+
readonly event: "change";
|
|
212
|
+
readonly defaultProp: "defaultValue";
|
|
213
|
+
}];
|
|
214
|
+
readonly slots: {};
|
|
215
|
+
readonly parts: {
|
|
216
|
+
readonly label: "Accessible label above the control.";
|
|
217
|
+
readonly control: "Visual control containing the editable input and decorations.";
|
|
218
|
+
readonly input: "The single-line editable input.";
|
|
219
|
+
readonly start: "Start icon or prefix decoration.";
|
|
220
|
+
readonly end: "End icon, suffix decoration or clear/reveal action.";
|
|
221
|
+
readonly help: "Supporting text associated with the editable input.";
|
|
222
|
+
readonly error: "External or native-validity error text associated with the editable input.";
|
|
223
|
+
readonly 'clear-button': "Optional accessible clear action.";
|
|
224
|
+
readonly 'reveal-button': "Optional accessible password visibility action.";
|
|
225
|
+
};
|
|
226
|
+
readonly cssProperties: {
|
|
227
|
+
readonly '--cosm-text-field-background': "Editable control background.";
|
|
228
|
+
readonly '--cosm-text-field-color': "Editable and decoration text color.";
|
|
229
|
+
readonly '--cosm-text-field-placeholder': "Placeholder text color.";
|
|
230
|
+
readonly '--cosm-text-field-border': "Editable control boundary color.";
|
|
231
|
+
readonly '--cosm-text-field-focus': "Visible focus indicator color.";
|
|
232
|
+
readonly '--cosm-text-field-radius': "Editable control corner radius.";
|
|
233
|
+
readonly '--cosm-text-field-start-icon-color': "Start icon color, independent of text and affixes.";
|
|
234
|
+
readonly '--cosm-text-field-start-icon-focus-color': "Start icon color within iconFocusScope; falls back to its normal color.";
|
|
235
|
+
readonly '--cosm-text-field-end-icon-color': "End icon color, independent of text and affixes.";
|
|
236
|
+
readonly '--cosm-text-field-end-icon-focus-color': "End icon color within iconFocusScope; falls back to its normal color.";
|
|
237
|
+
};
|
|
238
|
+
readonly keyboard: readonly [{
|
|
239
|
+
readonly keys: readonly ["Tab", "Shift+Tab"];
|
|
240
|
+
readonly action: "Moves focus to or from the enabled editable control.";
|
|
241
|
+
}, {
|
|
242
|
+
readonly keys: readonly ["Enter"];
|
|
243
|
+
readonly action: "Invokes the submit action; web form behavior remains native.";
|
|
244
|
+
}];
|
|
245
|
+
};
|
|
246
|
+
//# sourceMappingURL=text-field.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"text-field.d.ts","sourceRoot":"","sources":["../../src/specs/text-field.ts"],"names":[],"mappings":"AAEA,iEAAiE;AACjE,MAAM,WAAW,qBAAqB;IACpC,KAAK,EAAE,MAAM,CAAC;CACf;AAED,qEAAqE;AACrE,MAAM,WAAW,qBAAqB;IACpC,KAAK,EAAE,MAAM,CAAC;CACf;AAED;;;GAGG;AACH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAqP5B,CAAC"}
|