ionbase-ui 0.16.0 → 0.18.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.
Files changed (53) hide show
  1. package/README.md +71 -7
  2. package/dist/meta/Alert.json +269 -0
  3. package/dist/meta/Avatar.json +97 -0
  4. package/dist/meta/AvatarGroup.json +82 -0
  5. package/dist/meta/Badge.json +83 -0
  6. package/dist/meta/Button.json +556 -0
  7. package/dist/meta/Checkbox.json +113 -0
  8. package/dist/meta/Divider.json +30 -0
  9. package/dist/meta/FullCard.json +97 -0
  10. package/dist/meta/Header.json +91 -0
  11. package/dist/meta/Icon.json +35 -0
  12. package/dist/meta/Input.json +558 -0
  13. package/dist/meta/Link.json +239 -0
  14. package/dist/meta/Logo.json +46 -0
  15. package/dist/meta/LogoMark.json +41 -0
  16. package/dist/meta/Menu.json +50 -0
  17. package/dist/meta/MenuItem.json +75 -0
  18. package/dist/meta/Modal.json +241 -0
  19. package/dist/meta/NavItem.json +76 -0
  20. package/dist/meta/PhoneInput.json +472 -0
  21. package/dist/meta/Popover.json +124 -0
  22. package/dist/meta/Radio.json +104 -0
  23. package/dist/meta/RadioGroup.json +126 -0
  24. package/dist/meta/ScrollProgress.json +63 -0
  25. package/dist/meta/Select.json +195 -0
  26. package/dist/meta/TabItem.json +15 -0
  27. package/dist/meta/Table.json +135 -0
  28. package/dist/meta/TableBody.json +43 -0
  29. package/dist/meta/TableCell.json +105 -0
  30. package/dist/meta/TableHead.json +43 -0
  31. package/dist/meta/TableRow.json +56 -0
  32. package/dist/meta/Tabs.json +186 -0
  33. package/dist/meta/Toast.json +105 -0
  34. package/dist/meta/ToastProvider.json +75 -0
  35. package/dist/meta/Toggle.json +102 -0
  36. package/dist/meta/Tooltip.json +78 -0
  37. package/dist/meta/components.json +4816 -0
  38. package/dist/meta/contrast.json +3608 -0
  39. package/dist/meta/index.json +479 -0
  40. package/dist/styles/alert.css +10 -5
  41. package/dist/styles/tokens/base.css +25 -25
  42. package/dist/styles/tokens/theme-dark.css +11 -11
  43. package/dist/tokens/index.d.ts +8 -8
  44. package/dist/tokens/index.js +8 -8
  45. package/eslint-plugin/index.js +64 -0
  46. package/eslint-plugin/meta-data.js +66 -0
  47. package/eslint-plugin/rules/needs-accessible-name.js +88 -0
  48. package/eslint-plugin/rules/no-deprecated-props.js +74 -0
  49. package/eslint-plugin/rules/no-known-contrast-failure.js +75 -0
  50. package/eslint-plugin/rules/no-raw-style-values.js +107 -0
  51. package/eslint-plugin/rules/one-primary-action.js +128 -0
  52. package/package.json +33 -7
  53. package/stylelint-config.js +144 -0
@@ -0,0 +1,556 @@
1
+ {
2
+ "name": "Button",
3
+ "source": "src/components/Button.tsx",
4
+ "propsType": "ButtonProps",
5
+ "import": "import { Button } from 'ionbase-ui';",
6
+ "status": "stable",
7
+ "summary": "Triggers an action in place. Never navigates.",
8
+ "useWhen": [
9
+ "the interaction performs an action — submit, save, delete, open a dialog",
10
+ "the result stays on the current page"
11
+ ],
12
+ "useInstead": [
13
+ {
14
+ "when": "it navigates to a URL or changes route",
15
+ "use": "Link",
16
+ "why": "Link renders an <a>. Middle-click, cmd-click, copy-link-address and 'open in new tab' all work on an anchor and none of them work on a button."
17
+ },
18
+ {
19
+ "when": "it toggles a persistent boolean setting",
20
+ "use": "Toggle",
21
+ "why": "a toggle announces its on/off state; a button announces only its name"
22
+ }
23
+ ],
24
+ "variants": {
25
+ "variant": {
26
+ "primary-brand": {
27
+ "use": "the single most important action in a view",
28
+ "limit": "one per view or dialog"
29
+ },
30
+ "primary-neutral": {
31
+ "use": "a primary action that should not carry brand colour"
32
+ },
33
+ "primary-soft": {
34
+ "use": "a primary action on a dense or already-colourful surface"
35
+ },
36
+ "secondary": {
37
+ "use": "supporting actions shown alongside a primary one"
38
+ },
39
+ "tertiary": {
40
+ "use": "low-emphasis actions — Cancel, Back, inline row actions"
41
+ },
42
+ "destructive": {
43
+ "use": "irreversible actions",
44
+ "requires": "a Modal confirmation before the action runs"
45
+ },
46
+ "success": {
47
+ "use": "confirms the end of a flow. Rarely the right answer — prefer primary-brand."
48
+ }
49
+ },
50
+ "size": {
51
+ "sm": {
52
+ "use": "table rows, toolbars, dense layouts"
53
+ },
54
+ "md": {
55
+ "use": "the default; forms and page-level actions"
56
+ },
57
+ "lg": {
58
+ "use": "prominent standalone actions"
59
+ },
60
+ "xl": {
61
+ "use": "marketing and empty-state calls to action"
62
+ }
63
+ }
64
+ },
65
+ "slots": {
66
+ "startIcon": {
67
+ "accepts": "Icon",
68
+ "note": "omit Icon's `label` — the Button's own text already names it, and a labelled icon is announced twice"
69
+ },
70
+ "endIcon": {
71
+ "accepts": "Icon",
72
+ "note": "same as startIcon"
73
+ }
74
+ },
75
+ "a11y": {
76
+ "role": "button",
77
+ "guarantees": [
78
+ "the focus ring appears for keyboard focus and not for a mouse click",
79
+ "hover does not latch on touch devices"
80
+ ],
81
+ "requires": [
82
+ "an accessible name — `children`, or `aria-label` when the button is icon-only"
83
+ ],
84
+ "knownIssues": [
85
+ {
86
+ "pairing": "--text-primary on --surface-primary-subtle-hover",
87
+ "mode": "Dark",
88
+ "ratio": 4.25,
89
+ "required": 4.5,
90
+ "sc": "1.4.3",
91
+ "states": [
92
+ "hover"
93
+ ],
94
+ "status": "known, not yet fixed",
95
+ "where": "Button variant=primary-soft, hover",
96
+ "appliesTo": {
97
+ "component": "Button",
98
+ "props": {
99
+ "variant": "primary-soft"
100
+ }
101
+ }
102
+ },
103
+ {
104
+ "pairing": "--text-primary on --surface-primary-tint",
105
+ "mode": "Dark",
106
+ "ratio": 4.25,
107
+ "required": 4.5,
108
+ "sc": "1.4.3",
109
+ "states": [
110
+ "pressed"
111
+ ],
112
+ "status": "known, not yet fixed",
113
+ "where": "Button variant=primary-soft, pressed",
114
+ "appliesTo": {
115
+ "component": "Button",
116
+ "props": {
117
+ "variant": "primary-soft"
118
+ }
119
+ }
120
+ }
121
+ ]
122
+ },
123
+ "antiPatterns": [
124
+ {
125
+ "dont": "<Button onPress={() => router.push('/settings')}>Settings</Button>",
126
+ "do": "<Link href=\"/settings\">Settings</Link>",
127
+ "why": "a button that navigates breaks middle-click, cmd-click and copy-link, and is announced as a button rather than a link"
128
+ },
129
+ {
130
+ "dont": "two variant=\"primary-brand\" buttons in the same dialog",
131
+ "do": "one primary-brand, the rest secondary or tertiary",
132
+ "why": "two primaries is the same as none — nothing indicates the expected action"
133
+ },
134
+ {
135
+ "dont": "<Button variant=\"destructive\" onPress={deleteAccount}>",
136
+ "do": "open a Modal first and put the destructive Button in its footer",
137
+ "why": "irreversible actions need a confirmation step"
138
+ },
139
+ {
140
+ "dont": "<Button><Icon as={Trash} /></Button>",
141
+ "do": "<Button aria-label=\"Delete\"><Icon as={Trash} /></Button>",
142
+ "why": "an icon-only button with no aria-label is announced as just 'button'"
143
+ },
144
+ {
145
+ "dont": "<Button onClick={...}>",
146
+ "do": "<Button onPress={...}>",
147
+ "why": "onPress is React Aria's unified pointer/keyboard/touch handler. onClick works but skips the touch and keyboard normalisation the rest of the system relies on."
148
+ }
149
+ ],
150
+ "deprecated": [
151
+ {
152
+ "prop": "disabled",
153
+ "replacement": "isDisabled",
154
+ "note": "still type-checks, so this will not fail loudly"
155
+ }
156
+ ],
157
+ "stylesheet": "src/styles/button.css",
158
+ "tokens": [
159
+ "--border-disabled",
160
+ "--border-error-strong",
161
+ "--border-inverse",
162
+ "--border-primary",
163
+ "--border-primary-strong",
164
+ "--border-primary-subtle",
165
+ "--border-strong",
166
+ "--border-stronger",
167
+ "--border-success-strong",
168
+ "--border-width-default",
169
+ "--font-family-sans",
170
+ "--font-weight-medium",
171
+ "--icon-size-lg",
172
+ "--icon-size-md",
173
+ "--icon-size-xs",
174
+ "--ion-button-elevation",
175
+ "--ion-button-font-size",
176
+ "--ion-button-gap",
177
+ "--ion-button-icon-size",
178
+ "--ion-button-inset-flush",
179
+ "--ion-button-inset-lifted",
180
+ "--ion-button-line-height",
181
+ "--ion-button-padding-x",
182
+ "--ion-button-pressed",
183
+ "--ion-button-raised",
184
+ "--ion-button-ring",
185
+ "--ion-button-size",
186
+ "--ion-duration-base",
187
+ "--ion-duration-fast",
188
+ "--ion-ease-out",
189
+ "--ion-shadow-focus-md",
190
+ "--ion-shadow-inset-flush-lg",
191
+ "--ion-shadow-inset-flush-sm",
192
+ "--ion-shadow-inset-flush-xs",
193
+ "--ion-shadow-inset-lifted-lg",
194
+ "--ion-shadow-inset-lifted-sm",
195
+ "--ion-shadow-inset-lifted-xs",
196
+ "--ion-shadow-none",
197
+ "--ion-shadow-raised-lifted-lg",
198
+ "--ion-shadow-raised-lifted-sm",
199
+ "--ion-shadow-raised-lifted-xs",
200
+ "--radius-md",
201
+ "--spacing-12",
202
+ "--spacing-16",
203
+ "--spacing-20",
204
+ "--spacing-24",
205
+ "--spacing-32",
206
+ "--spacing-40",
207
+ "--spacing-48",
208
+ "--spacing-56",
209
+ "--spacing-6",
210
+ "--spacing-8",
211
+ "--surface-default",
212
+ "--surface-disabled",
213
+ "--surface-error",
214
+ "--surface-error-hover",
215
+ "--surface-error-pressed",
216
+ "--surface-inverse",
217
+ "--surface-inverse-subtle",
218
+ "--surface-muted",
219
+ "--surface-page",
220
+ "--surface-primary",
221
+ "--surface-primary-hover",
222
+ "--surface-primary-pressed",
223
+ "--surface-primary-subtle",
224
+ "--surface-primary-subtle-hover",
225
+ "--surface-primary-tint",
226
+ "--surface-success",
227
+ "--surface-success-hover",
228
+ "--surface-success-pressed",
229
+ "--text-disabled",
230
+ "--text-on-color",
231
+ "--text-primary",
232
+ "--text-secondary",
233
+ "--type-body",
234
+ "--type-body-lg",
235
+ "--type-body-lg-line-height",
236
+ "--type-body-line-height",
237
+ "--type-body-md",
238
+ "--type-body-md-line-height",
239
+ "--type-body-sm",
240
+ "--type-body-sm-line-height"
241
+ ],
242
+ "props": {
243
+ "variant": {
244
+ "type": "\"success\" | \"primary-brand\" | \"primary-neutral\" | \"primary-soft\" | \"secondary\" | \"tertiary\" | \"destructive\" | undefined",
245
+ "required": false,
246
+ "origin": "own",
247
+ "description": "The visual style variant of the button.",
248
+ "values": [
249
+ "success",
250
+ "primary-brand",
251
+ "primary-neutral",
252
+ "primary-soft",
253
+ "secondary",
254
+ "tertiary",
255
+ "destructive"
256
+ ],
257
+ "default": "primary-brand"
258
+ },
259
+ "size": {
260
+ "type": "\"sm\" | \"md\" | \"lg\" | \"xl\" | undefined",
261
+ "required": false,
262
+ "origin": "own",
263
+ "description": "The size of the button.",
264
+ "values": [
265
+ "sm",
266
+ "md",
267
+ "lg",
268
+ "xl"
269
+ ],
270
+ "default": "md"
271
+ },
272
+ "startIcon": {
273
+ "type": "React.ReactNode",
274
+ "required": false,
275
+ "origin": "own",
276
+ "description": "Optional icon to render before the label."
277
+ },
278
+ "endIcon": {
279
+ "type": "React.ReactNode",
280
+ "required": false,
281
+ "origin": "own",
282
+ "description": "Optional icon to render after the label."
283
+ },
284
+ "className": {
285
+ "type": "string | undefined",
286
+ "required": false,
287
+ "origin": "own",
288
+ "description": "Additional CSS class names."
289
+ },
290
+ "children": {
291
+ "type": "React.ReactNode",
292
+ "required": false,
293
+ "origin": "own",
294
+ "description": "Children element to render inside the button."
295
+ },
296
+ "disabled": {
297
+ "type": "boolean | undefined",
298
+ "required": false,
299
+ "origin": "own",
300
+ "tags": {
301
+ "deprecated": "Use `isDisabled`. Accepted as an alias for one minor version."
302
+ }
303
+ },
304
+ "isDisabled": {
305
+ "type": "boolean | undefined",
306
+ "required": false,
307
+ "origin": "aria",
308
+ "description": "Whether the button is disabled."
309
+ },
310
+ "onPress": {
311
+ "type": "((e: PressEvent) => void) | undefined",
312
+ "required": false,
313
+ "origin": "aria",
314
+ "description": "Handler that is called when the press is released over the target."
315
+ },
316
+ "onPressStart": {
317
+ "type": "((e: PressEvent) => void) | undefined",
318
+ "required": false,
319
+ "origin": "aria",
320
+ "description": "Handler that is called when a press interaction starts."
321
+ },
322
+ "onPressEnd": {
323
+ "type": "((e: PressEvent) => void) | undefined",
324
+ "required": false,
325
+ "origin": "aria",
326
+ "description": "Handler that is called when a press interaction ends, either\nover the target or when the pointer leaves the target."
327
+ },
328
+ "onPressChange": {
329
+ "type": "((isPressed: boolean) => void) | undefined",
330
+ "required": false,
331
+ "origin": "aria",
332
+ "description": "Handler that is called when the press state changes."
333
+ },
334
+ "onPressUp": {
335
+ "type": "((e: PressEvent) => void) | undefined",
336
+ "required": false,
337
+ "origin": "aria",
338
+ "description": "Handler that is called when a press is released over the target, regardless of\nwhether it started on the target or not."
339
+ },
340
+ "onClick": {
341
+ "type": "((e: MouseEvent<FocusableElement>) => void) | undefined",
342
+ "required": false,
343
+ "origin": "aria",
344
+ "description": "**Not recommended – use `onPress` instead.** `onClick` is an alias for `onPress`\nprovided for compatibility with other libraries. `onPress` provides\nadditional event details for non-mouse interactions."
345
+ },
346
+ "autoFocus": {
347
+ "type": "boolean | undefined",
348
+ "required": false,
349
+ "origin": "aria",
350
+ "description": "Whether the element should receive focus on render."
351
+ },
352
+ "onFocus": {
353
+ "type": "((e: FocusEvent<Element, Element>) => void) | undefined",
354
+ "required": false,
355
+ "origin": "aria",
356
+ "description": "Handler that is called when the element receives focus."
357
+ },
358
+ "onBlur": {
359
+ "type": "((e: FocusEvent<Element, Element>) => void) | undefined",
360
+ "required": false,
361
+ "origin": "aria",
362
+ "description": "Handler that is called when the element loses focus."
363
+ },
364
+ "onFocusChange": {
365
+ "type": "((isFocused: boolean) => void) | undefined",
366
+ "required": false,
367
+ "origin": "aria",
368
+ "description": "Handler that is called when the element's focus status changes."
369
+ },
370
+ "onKeyDown": {
371
+ "type": "((e: KeyboardEvent) => void) | undefined",
372
+ "required": false,
373
+ "origin": "aria",
374
+ "description": "Handler that is called when a key is pressed."
375
+ },
376
+ "onKeyUp": {
377
+ "type": "((e: KeyboardEvent) => void) | undefined",
378
+ "required": false,
379
+ "origin": "aria",
380
+ "description": "Handler that is called when a key is released."
381
+ },
382
+ "href": {
383
+ "type": "string | undefined",
384
+ "required": false,
385
+ "origin": "aria",
386
+ "description": "A URL to link to if elementType=\"a\"."
387
+ },
388
+ "target": {
389
+ "type": "string | undefined",
390
+ "required": false,
391
+ "origin": "aria",
392
+ "description": "The target window for the link."
393
+ },
394
+ "rel": {
395
+ "type": "string | undefined",
396
+ "required": false,
397
+ "origin": "aria",
398
+ "description": "The relationship between the linked resource and the current page. See\n[MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/rel)."
399
+ },
400
+ "elementType": {
401
+ "type": "JSXElementConstructor<any> | \"button\" | undefined",
402
+ "required": false,
403
+ "origin": "aria",
404
+ "description": "The HTML element or React element used to render the button, e.g. 'div', 'a', or `RouterLink`.",
405
+ "tags": {
406
+ "default": "'button'"
407
+ }
408
+ },
409
+ "aria-disabled": {
410
+ "type": "boolean | \"true\" | \"false\" | undefined",
411
+ "required": false,
412
+ "origin": "aria",
413
+ "description": "Indicates whether the element is disabled to users of assistive technology."
414
+ },
415
+ "aria-expanded": {
416
+ "type": "boolean | \"true\" | \"false\" | undefined",
417
+ "required": false,
418
+ "origin": "aria",
419
+ "description": "Indicates whether the element, or another grouping element it controls, is currently expanded\nor collapsed."
420
+ },
421
+ "aria-haspopup": {
422
+ "type": "boolean | \"true\" | \"false\" | \"menu\" | \"listbox\" | \"tree\" | \"grid\" | \"dialog\" | undefined",
423
+ "required": false,
424
+ "origin": "aria",
425
+ "description": "Indicates the availability and type of interactive popup element, such as menu or dialog, that\ncan be triggered by an element."
426
+ },
427
+ "aria-controls": {
428
+ "type": "string | undefined",
429
+ "required": false,
430
+ "origin": "aria",
431
+ "description": "Identifies the element (or elements) whose contents or presence are controlled by the current\nelement."
432
+ },
433
+ "aria-pressed": {
434
+ "type": "boolean | \"true\" | \"false\" | \"mixed\" | undefined",
435
+ "required": false,
436
+ "origin": "aria",
437
+ "description": "Indicates the current \"pressed\" state of toggle buttons."
438
+ },
439
+ "aria-current": {
440
+ "type": "boolean | \"true\" | \"false\" | \"page\" | \"step\" | \"location\" | \"date\" | \"time\" | undefined",
441
+ "required": false,
442
+ "origin": "aria",
443
+ "description": "Indicates whether this element represents the current item within a container or set of related\nelements."
444
+ },
445
+ "type": {
446
+ "type": "\"button\" | \"submit\" | \"reset\" | undefined",
447
+ "required": false,
448
+ "origin": "aria",
449
+ "description": "The behavior of the button when used in an HTML form.",
450
+ "values": [
451
+ "button",
452
+ "submit",
453
+ "reset"
454
+ ],
455
+ "tags": {
456
+ "default": "'button'"
457
+ }
458
+ },
459
+ "preventFocusOnPress": {
460
+ "type": "boolean | undefined",
461
+ "required": false,
462
+ "origin": "aria",
463
+ "description": "Whether to prevent focus from moving to the button when pressing it.\n\nCaution, this can make the button inaccessible and should only be used when alternative\nkeyboard interaction is provided, such as ComboBox's MenuTrigger or a NumberField's\nincrement/decrement control."
464
+ },
465
+ "form": {
466
+ "type": "string | undefined",
467
+ "required": false,
468
+ "origin": "aria",
469
+ "description": "The `<form>` element to associate the button with.\nThe value of this attribute must be the id of a `<form>` in the same document.\nSee [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/button#form)."
470
+ },
471
+ "formAction": {
472
+ "type": "string | ((formData: FormData) => void | Promise<void>) | undefined",
473
+ "required": false,
474
+ "origin": "aria",
475
+ "description": "The URL that processes the information submitted by the button.\nOverrides the action attribute of the button's form owner."
476
+ },
477
+ "formEncType": {
478
+ "type": "string | undefined",
479
+ "required": false,
480
+ "origin": "aria",
481
+ "description": "Indicates how to encode the form data that is submitted."
482
+ },
483
+ "formMethod": {
484
+ "type": "string | undefined",
485
+ "required": false,
486
+ "origin": "aria",
487
+ "description": "Indicates the HTTP method used to submit the form."
488
+ },
489
+ "formNoValidate": {
490
+ "type": "boolean | undefined",
491
+ "required": false,
492
+ "origin": "aria",
493
+ "description": "Indicates that the form is not to be validated when it is submitted."
494
+ },
495
+ "formTarget": {
496
+ "type": "string | undefined",
497
+ "required": false,
498
+ "origin": "aria",
499
+ "description": "Overrides the target attribute of the button's form owner."
500
+ },
501
+ "name": {
502
+ "type": "string | undefined",
503
+ "required": false,
504
+ "origin": "aria",
505
+ "description": "Submitted as a pair with the button's value as part of the form data."
506
+ },
507
+ "value": {
508
+ "type": "string | undefined",
509
+ "required": false,
510
+ "origin": "aria",
511
+ "description": "The value associated with the button's name when it's submitted with the form data."
512
+ },
513
+ "excludeFromTabOrder": {
514
+ "type": "boolean | undefined",
515
+ "required": false,
516
+ "origin": "aria",
517
+ "description": "Whether to exclude the element from the sequential tab order. If true,\nthe element will not be focusable via the keyboard by tabbing. This should\nbe avoided except in rare scenarios where an alternative means of accessing\nthe element or its functionality via the keyboard is available."
518
+ },
519
+ "id": {
520
+ "type": "string | undefined",
521
+ "required": false,
522
+ "origin": "aria",
523
+ "description": "The element's unique identifier. See\n[MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/id)."
524
+ },
525
+ "aria-label": {
526
+ "type": "string | undefined",
527
+ "required": false,
528
+ "origin": "aria",
529
+ "description": "Defines a string value that labels the current element."
530
+ },
531
+ "aria-labelledby": {
532
+ "type": "string | undefined",
533
+ "required": false,
534
+ "origin": "aria",
535
+ "description": "Identifies the element (or elements) that labels the current element."
536
+ },
537
+ "aria-describedby": {
538
+ "type": "string | undefined",
539
+ "required": false,
540
+ "origin": "aria",
541
+ "description": "Identifies the element (or elements) that describes the object."
542
+ },
543
+ "aria-details": {
544
+ "type": "string | undefined",
545
+ "required": false,
546
+ "origin": "aria",
547
+ "description": "Identifies the element (or elements) that provide a detailed, extended description for the\nobject."
548
+ }
549
+ },
550
+ "propCounts": {
551
+ "own": 7,
552
+ "aria": 39,
553
+ "dom": 0,
554
+ "other": 0
555
+ }
556
+ }
@@ -0,0 +1,113 @@
1
+ {
2
+ "name": "Checkbox",
3
+ "source": "src/components/Checkbox.tsx",
4
+ "propsType": "CheckboxProps",
5
+ "description": "Checkbox wraps a native `<input type=\"checkbox\">` and hides it.\n\nThe native input is kept rather than replaced by a div with `role=checkbox`\nbecause it brings form association, the indeterminate property, label\nclicking, and correct announcement — none of which are free to reimplement,\nand all of which are easy to get subtly wrong.\n\n`indeterminate` is the reason for the effect below: HTML has no\n`indeterminate` attribute, only a DOM property, so React cannot set it\ndeclaratively and it must be written after every render.",
6
+ "import": "import { Checkbox } from 'ionbase-ui';",
7
+ "stylesheet": "src/styles/checkbox.css",
8
+ "tokens": [
9
+ "--border-disabled",
10
+ "--border-error-strong",
11
+ "--border-focus",
12
+ "--border-inverse",
13
+ "--border-primary-strong",
14
+ "--border-stronger",
15
+ "--border-width-default",
16
+ "--border-width-thick",
17
+ "--font-family-sans",
18
+ "--icon-disabled",
19
+ "--icon-on-color",
20
+ "--ion-checkbox-border",
21
+ "--ion-checkbox-fill",
22
+ "--ion-checkbox-font-size",
23
+ "--ion-checkbox-gap",
24
+ "--ion-checkbox-line-height",
25
+ "--ion-checkbox-mark",
26
+ "--ion-checkbox-radius",
27
+ "--ion-checkbox-raised",
28
+ "--ion-checkbox-size",
29
+ "--ion-duration-base",
30
+ "--ion-ease-out",
31
+ "--ion-shadow-raised-flush-lg",
32
+ "--ion-shadow-raised-flush-sm",
33
+ "--ion-shadow-raised-flush-xs",
34
+ "--radius-sm",
35
+ "--radius-xs",
36
+ "--spacing-12",
37
+ "--spacing-16",
38
+ "--spacing-20",
39
+ "--spacing-24",
40
+ "--spacing-4",
41
+ "--spacing-8",
42
+ "--surface-default",
43
+ "--surface-disabled",
44
+ "--surface-error",
45
+ "--surface-inverse",
46
+ "--surface-primary",
47
+ "--text-disabled",
48
+ "--text-secondary",
49
+ "--type-body",
50
+ "--type-body-line-height",
51
+ "--type-body-sm",
52
+ "--type-body-sm-line-height"
53
+ ],
54
+ "props": {
55
+ "size": {
56
+ "type": "CheckboxSize | undefined",
57
+ "required": false,
58
+ "origin": "own",
59
+ "description": "Matches the Figma `Size` variant: Small, Medium, Large.",
60
+ "values": [
61
+ "sm",
62
+ "md",
63
+ "lg"
64
+ ],
65
+ "default": "md"
66
+ },
67
+ "intent": {
68
+ "type": "CheckboxIntent | undefined",
69
+ "required": false,
70
+ "origin": "own",
71
+ "description": "Matches the Figma `Color` variant: Brand, Neutral, Danger.",
72
+ "values": [
73
+ "neutral",
74
+ "brand",
75
+ "danger"
76
+ ],
77
+ "default": "brand"
78
+ },
79
+ "isIndeterminate": {
80
+ "type": "boolean | undefined",
81
+ "required": false,
82
+ "origin": "own",
83
+ "description": "Figma's `Indeterminate` state. Not an HTML attribute — `indeterminate` is a\nDOM property only, so it has to be assigned after render.",
84
+ "default": false
85
+ },
86
+ "isDisabled": {
87
+ "type": "boolean | undefined",
88
+ "required": false,
89
+ "origin": "own",
90
+ "description": "Whether the checkbox is disabled."
91
+ },
92
+ "disabled": {
93
+ "type": "boolean | undefined",
94
+ "required": false,
95
+ "origin": "own",
96
+ "tags": {
97
+ "deprecated": "Use `isDisabled`. Accepted as an alias for one minor version."
98
+ }
99
+ },
100
+ "children": {
101
+ "type": "React.ReactNode",
102
+ "required": false,
103
+ "origin": "own",
104
+ "description": "Figma's `Show Label` + `Label`. Omit for a bare box."
105
+ }
106
+ },
107
+ "propCounts": {
108
+ "own": 6,
109
+ "aria": 0,
110
+ "dom": 304,
111
+ "other": 0
112
+ }
113
+ }