ionbase-ui 0.13.1 → 0.17.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (59) hide show
  1. package/README.md +62 -45
  2. package/dist/components/Popover.d.ts +47 -0
  3. package/dist/components/Popover.d.ts.map +1 -0
  4. package/dist/components/Popover.js +71 -0
  5. package/dist/components/Popover.js.map +1 -0
  6. package/dist/components/Toast.d.ts +57 -0
  7. package/dist/components/Toast.d.ts.map +1 -0
  8. package/dist/components/Toast.js +81 -0
  9. package/dist/components/Toast.js.map +1 -0
  10. package/dist/components/index.d.ts +4 -0
  11. package/dist/components/index.d.ts.map +1 -1
  12. package/dist/components/index.js +2 -0
  13. package/dist/components/index.js.map +1 -1
  14. package/dist/meta/Alert.json +248 -0
  15. package/dist/meta/Avatar.json +97 -0
  16. package/dist/meta/AvatarGroup.json +82 -0
  17. package/dist/meta/Badge.json +83 -0
  18. package/dist/meta/Button.json +518 -0
  19. package/dist/meta/Checkbox.json +113 -0
  20. package/dist/meta/Divider.json +30 -0
  21. package/dist/meta/FullCard.json +97 -0
  22. package/dist/meta/Header.json +91 -0
  23. package/dist/meta/Icon.json +35 -0
  24. package/dist/meta/Input.json +558 -0
  25. package/dist/meta/Link.json +239 -0
  26. package/dist/meta/Logo.json +46 -0
  27. package/dist/meta/LogoMark.json +41 -0
  28. package/dist/meta/Menu.json +50 -0
  29. package/dist/meta/MenuItem.json +75 -0
  30. package/dist/meta/Modal.json +241 -0
  31. package/dist/meta/NavItem.json +76 -0
  32. package/dist/meta/PhoneInput.json +472 -0
  33. package/dist/meta/Popover.json +124 -0
  34. package/dist/meta/Radio.json +104 -0
  35. package/dist/meta/RadioGroup.json +126 -0
  36. package/dist/meta/ScrollProgress.json +63 -0
  37. package/dist/meta/Select.json +195 -0
  38. package/dist/meta/TabItem.json +15 -0
  39. package/dist/meta/Table.json +135 -0
  40. package/dist/meta/TableBody.json +43 -0
  41. package/dist/meta/TableCell.json +105 -0
  42. package/dist/meta/TableHead.json +43 -0
  43. package/dist/meta/TableRow.json +56 -0
  44. package/dist/meta/Tabs.json +186 -0
  45. package/dist/meta/Toast.json +105 -0
  46. package/dist/meta/ToastProvider.json +75 -0
  47. package/dist/meta/Toggle.json +102 -0
  48. package/dist/meta/Tooltip.json +78 -0
  49. package/dist/meta/components.json +4757 -0
  50. package/dist/meta/index.json +479 -0
  51. package/dist/styles/index.css +2 -0
  52. package/dist/styles/popover.css +185 -0
  53. package/dist/styles/toast.css +216 -0
  54. package/dist/styles/tokens/base.css +26 -26
  55. package/dist/styles/tokens/theme-dark.css +11 -11
  56. package/dist/tokens/index.d.ts +9 -9
  57. package/dist/tokens/index.js +9 -9
  58. package/dist/tokens/index.js.map +1 -1
  59. package/package.json +12 -6
@@ -0,0 +1,239 @@
1
+ {
2
+ "name": "Link",
3
+ "source": "src/components/Link.tsx",
4
+ "propsType": "LinkProps",
5
+ "description": "Link — Figma `Link` (774:1516).\n\nRenders an `<a>` when given an `href` and a `<button>` otherwise, the same\njudgment `NavItem` makes: the element follows what the caller is actually\nbuilding rather than a separate `as` prop. A link that does not navigate is\na button, and shipping one as an anchor breaks middle-click, \"open in new\ntab\" and the screen-reader announcement all at once.\n\nNO SIZE PROP, DELIBERATELY. A link is an inline element and inherits its\ntype from the text around it — `font-size: inherit` in the stylesheet, and\nicons sized in `em` so they scale with it. Figma has to draw its variants at\nsome concrete size (16/24, `type/body`), but that is one sample of an\ninheriting element, not a specification. Do not add a size ladder to match\nthe drawing.",
6
+ "import": "import { Link } from 'ionbase-ui';",
7
+ "stylesheet": "src/styles/link.css",
8
+ "tokens": [
9
+ "--border-width-thick",
10
+ "--ion-duration-base",
11
+ "--ion-ease-out",
12
+ "--radius-xs",
13
+ "--ring-focus",
14
+ "--spacing-4",
15
+ "--text-disabled",
16
+ "--text-link",
17
+ "--text-link-hover",
18
+ "--text-link-visited"
19
+ ],
20
+ "props": {
21
+ "variant": {
22
+ "type": "LinkVariant | undefined",
23
+ "required": false,
24
+ "origin": "own",
25
+ "description": "Matches the Figma `Type` variant.\n\n`inline` is for links inside body copy and is underlined in every state —\na link in a paragraph must not rely on colour alone (WCAG 1.4.1).\n`standalone` is for links that already read as interactive from their\nposition, and underlines on hover only.",
26
+ "values": [
27
+ "inline",
28
+ "standalone"
29
+ ],
30
+ "default": "inline"
31
+ },
32
+ "startIcon": {
33
+ "type": "React.ReactNode",
34
+ "required": false,
35
+ "origin": "own",
36
+ "description": "Optional icon before the label."
37
+ },
38
+ "endIcon": {
39
+ "type": "React.ReactNode",
40
+ "required": false,
41
+ "origin": "own",
42
+ "description": "Optional icon after the label — the external-link or arrow affordance."
43
+ },
44
+ "className": {
45
+ "type": "string | undefined",
46
+ "required": false,
47
+ "origin": "own"
48
+ },
49
+ "children": {
50
+ "type": "React.ReactNode",
51
+ "required": false,
52
+ "origin": "own"
53
+ },
54
+ "disabled": {
55
+ "type": "boolean | undefined",
56
+ "required": false,
57
+ "origin": "own",
58
+ "tags": {
59
+ "deprecated": "Use `isDisabled`. Accepted as an alias for one minor version."
60
+ }
61
+ },
62
+ "isDisabled": {
63
+ "type": "boolean | undefined",
64
+ "required": false,
65
+ "origin": "aria",
66
+ "description": "Whether the link is disabled."
67
+ },
68
+ "elementType": {
69
+ "type": "string | undefined",
70
+ "required": false,
71
+ "origin": "aria",
72
+ "description": "The HTML element used to render the link, e.g. 'a', or 'span'.",
73
+ "tags": {
74
+ "default": "'a'"
75
+ }
76
+ },
77
+ "onPress": {
78
+ "type": "((e: PressEvent) => void) | undefined",
79
+ "required": false,
80
+ "origin": "aria",
81
+ "description": "Handler that is called when the press is released over the target."
82
+ },
83
+ "onPressStart": {
84
+ "type": "((e: PressEvent) => void) | undefined",
85
+ "required": false,
86
+ "origin": "aria",
87
+ "description": "Handler that is called when a press interaction starts."
88
+ },
89
+ "onPressEnd": {
90
+ "type": "((e: PressEvent) => void) | undefined",
91
+ "required": false,
92
+ "origin": "aria",
93
+ "description": "Handler that is called when a press interaction ends, either\nover the target or when the pointer leaves the target."
94
+ },
95
+ "onPressChange": {
96
+ "type": "((isPressed: boolean) => void) | undefined",
97
+ "required": false,
98
+ "origin": "aria",
99
+ "description": "Handler that is called when the press state changes."
100
+ },
101
+ "onPressUp": {
102
+ "type": "((e: PressEvent) => void) | undefined",
103
+ "required": false,
104
+ "origin": "aria",
105
+ "description": "Handler that is called when a press is released over the target, regardless of\nwhether it started on the target or not."
106
+ },
107
+ "onClick": {
108
+ "type": "((e: MouseEvent<FocusableElement>) => void) | undefined",
109
+ "required": false,
110
+ "origin": "aria",
111
+ "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."
112
+ },
113
+ "autoFocus": {
114
+ "type": "boolean | undefined",
115
+ "required": false,
116
+ "origin": "aria",
117
+ "description": "Whether the element should receive focus on render."
118
+ },
119
+ "onFocus": {
120
+ "type": "((e: FocusEvent<Element, Element>) => void) | undefined",
121
+ "required": false,
122
+ "origin": "aria",
123
+ "description": "Handler that is called when the element receives focus."
124
+ },
125
+ "onBlur": {
126
+ "type": "((e: FocusEvent<Element, Element>) => void) | undefined",
127
+ "required": false,
128
+ "origin": "aria",
129
+ "description": "Handler that is called when the element loses focus."
130
+ },
131
+ "onFocusChange": {
132
+ "type": "((isFocused: boolean) => void) | undefined",
133
+ "required": false,
134
+ "origin": "aria",
135
+ "description": "Handler that is called when the element's focus status changes."
136
+ },
137
+ "onKeyDown": {
138
+ "type": "((e: KeyboardEvent) => void) | undefined",
139
+ "required": false,
140
+ "origin": "aria",
141
+ "description": "Handler that is called when a key is pressed."
142
+ },
143
+ "onKeyUp": {
144
+ "type": "((e: KeyboardEvent) => void) | undefined",
145
+ "required": false,
146
+ "origin": "aria",
147
+ "description": "Handler that is called when a key is released."
148
+ },
149
+ "href": {
150
+ "type": "string | undefined",
151
+ "required": false,
152
+ "origin": "aria",
153
+ "description": "A URL to link to. See [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#href)."
154
+ },
155
+ "hrefLang": {
156
+ "type": "string | undefined",
157
+ "required": false,
158
+ "origin": "aria",
159
+ "description": "Hints at the human language of the linked URL.\nSee[MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#hreflang)."
160
+ },
161
+ "target": {
162
+ "type": "HTMLAttributeAnchorTarget | undefined",
163
+ "required": false,
164
+ "origin": "aria",
165
+ "description": "The target window for the link. See\n[MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target)."
166
+ },
167
+ "rel": {
168
+ "type": "string | undefined",
169
+ "required": false,
170
+ "origin": "aria",
171
+ "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)."
172
+ },
173
+ "download": {
174
+ "type": "string | boolean | undefined",
175
+ "required": false,
176
+ "origin": "aria",
177
+ "description": "Causes the browser to download the linked URL. A string may be provided to suggest a file name.\nSee [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#download)."
178
+ },
179
+ "ping": {
180
+ "type": "string | undefined",
181
+ "required": false,
182
+ "origin": "aria",
183
+ "description": "A space-separated list of URLs to ping when the link is followed. See\n[MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#ping)."
184
+ },
185
+ "referrerPolicy": {
186
+ "type": "HTMLAttributeReferrerPolicy | undefined",
187
+ "required": false,
188
+ "origin": "aria",
189
+ "description": "How much of the referrer to send when following the link. See\n[MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#referrerpolicy).",
190
+ "values": [
191
+ "",
192
+ "origin",
193
+ "no-referrer",
194
+ "no-referrer-when-downgrade",
195
+ "origin-when-cross-origin",
196
+ "same-origin",
197
+ "strict-origin",
198
+ "strict-origin-when-cross-origin",
199
+ "unsafe-url"
200
+ ]
201
+ },
202
+ "routerOptions": {
203
+ "type": "undefined",
204
+ "required": false,
205
+ "origin": "aria",
206
+ "description": "Options for the configured client side router."
207
+ },
208
+ "aria-label": {
209
+ "type": "string | undefined",
210
+ "required": false,
211
+ "origin": "aria",
212
+ "description": "Defines a string value that labels the current element."
213
+ },
214
+ "aria-labelledby": {
215
+ "type": "string | undefined",
216
+ "required": false,
217
+ "origin": "aria",
218
+ "description": "Identifies the element (or elements) that labels the current element."
219
+ },
220
+ "aria-describedby": {
221
+ "type": "string | undefined",
222
+ "required": false,
223
+ "origin": "aria",
224
+ "description": "Identifies the element (or elements) that describes the object."
225
+ },
226
+ "aria-details": {
227
+ "type": "string | undefined",
228
+ "required": false,
229
+ "origin": "aria",
230
+ "description": "Identifies the element (or elements) that provide a detailed, extended description for the\nobject."
231
+ }
232
+ },
233
+ "propCounts": {
234
+ "own": 6,
235
+ "aria": 26,
236
+ "dom": 266,
237
+ "other": 0
238
+ }
239
+ }
@@ -0,0 +1,46 @@
1
+ {
2
+ "name": "Logo",
3
+ "source": "src/components/Logo.tsx",
4
+ "propsType": "LogoProps",
5
+ "description": "The full lockup: mark + wordmark, matching Figma's `Logo-Ionbase`\n(52:21369).\n\nFigma also has a `Property=Name` axis — wordmark only, no mark — but both\nof its variants currently render the placeholder text \"raza\" rather than\n\"IonBase\", in an unbound raw colour. That is leftover debug content, not a\nreal asset, so it is not implemented here. Reproducing it would ship a\nstranger's name into a design system; extending `LogoMark` alone already\ncovers \"no wordmark\" for the cases that are real.",
6
+ "import": "import { Logo } from 'ionbase-ui';",
7
+ "stylesheet": "src/styles/logo.css",
8
+ "tokens": [
9
+ "--font-family-sans",
10
+ "--font-weight-medium",
11
+ "--icon-default",
12
+ "--spacing-4",
13
+ "--spacing-8",
14
+ "--text-tertiary",
15
+ "--type-body",
16
+ "--type-body-line-height"
17
+ ],
18
+ "props": {
19
+ "size": {
20
+ "type": "LogoSize | undefined",
21
+ "required": false,
22
+ "origin": "own",
23
+ "description": "Matches Figma's `Size` variant: Small (24px mark) or Large (32px).",
24
+ "values": [
25
+ "sm",
26
+ "lg"
27
+ ]
28
+ },
29
+ "wordmark": {
30
+ "type": "LogoWordmark | undefined",
31
+ "required": false,
32
+ "origin": "own",
33
+ "description": "Matches Figma's `Type` variant. `vector` is the serif logotype Figma\ncalls \"Logo\" — what `Header` uses, immune to font substitution and\nvisually distinct from the sans-serif UI type everywhere else. `text` is\nwhat Figma calls \"Icon\": a live `Host Grotesk` run, real and selectable,\nat `text/tertiary` rather than the mark's `icon/default`.",
34
+ "values": [
35
+ "text",
36
+ "vector"
37
+ ]
38
+ }
39
+ },
40
+ "propCounts": {
41
+ "own": 2,
42
+ "aria": 0,
43
+ "dom": 278,
44
+ "other": 0
45
+ }
46
+ }
@@ -0,0 +1,41 @@
1
+ {
2
+ "name": "LogoMark",
3
+ "source": "src/components/Logo.tsx",
4
+ "propsType": "LogoMarkProps",
5
+ "description": "The bare icon glyph, no wordmark — what `Header` actually uses.\n\nColour comes from the `.ion-logo__mark` class (`icon/default`), not the SVG\nitself, so it themes the same way every other icon in the system does.",
6
+ "import": "import { LogoMark } from 'ionbase-ui';",
7
+ "stylesheet": "src/styles/logo.css",
8
+ "tokens": [
9
+ "--font-family-sans",
10
+ "--font-weight-medium",
11
+ "--icon-default",
12
+ "--spacing-4",
13
+ "--spacing-8",
14
+ "--text-tertiary",
15
+ "--type-body",
16
+ "--type-body-line-height"
17
+ ],
18
+ "props": {
19
+ "size": {
20
+ "type": "LogoSize | undefined",
21
+ "required": false,
22
+ "origin": "own",
23
+ "values": [
24
+ "sm",
25
+ "lg"
26
+ ]
27
+ },
28
+ "label": {
29
+ "type": "string | undefined",
30
+ "required": false,
31
+ "origin": "own",
32
+ "description": "Accessible name for the mark used standalone. Omit when it sits beside\na visible wordmark, which already carries the name."
33
+ }
34
+ },
35
+ "propCounts": {
36
+ "own": 2,
37
+ "aria": 0,
38
+ "dom": 487,
39
+ "other": 0
40
+ }
41
+ }
@@ -0,0 +1,50 @@
1
+ {
2
+ "name": "Menu",
3
+ "source": "src/components/Menu.tsx",
4
+ "propsType": "MenuProps",
5
+ "description": "Menu is the list surface, not a popover.\n\nFigma models the list alone — there is no trigger, anchor or open state in\nthe design — so this renders the surface and nothing else. Positioning it\nagainst a button is the caller's job until Figma has a component that says\nhow. Building a popover here would be inventing design, and it would be the\nhard half to unpick later.\n\n`role=\"menu\"` is deliberately NOT set. A real ARIA menu owes the user\nroving-tabindex arrow navigation, typeahead and focus containment; claiming\nthe role without them is worse for a screen-reader user than an honest list,\nbecause it promises interactions that are not there. When the popover exists,\nthe role comes with it.",
6
+ "import": "import { Menu } from 'ionbase-ui';",
7
+ "stylesheet": "src/styles/menu.css",
8
+ "tokens": [
9
+ "--border-focus",
10
+ "--border-subtle",
11
+ "--border-width-default",
12
+ "--border-width-thick",
13
+ "--font-family-sans",
14
+ "--font-weight-regular",
15
+ "--icon-default",
16
+ "--icon-disabled",
17
+ "--icon-primary",
18
+ "--icon-size-sm",
19
+ "--ion-duration-base",
20
+ "--ion-ease-out",
21
+ "--radius-sm",
22
+ "--radius-xl",
23
+ "--spacing-12",
24
+ "--spacing-2",
25
+ "--spacing-40",
26
+ "--spacing-6",
27
+ "--spacing-8",
28
+ "--surface-default",
29
+ "--surface-hover",
30
+ "--surface-primary-subtle",
31
+ "--text-disabled",
32
+ "--text-primary",
33
+ "--text-secondary",
34
+ "--type-body",
35
+ "--type-body-line-height"
36
+ ],
37
+ "props": {
38
+ "children": {
39
+ "type": "React.ReactNode",
40
+ "required": false,
41
+ "origin": "own"
42
+ }
43
+ },
44
+ "propCounts": {
45
+ "own": 1,
46
+ "aria": 0,
47
+ "dom": 277,
48
+ "other": 0
49
+ }
50
+ }
@@ -0,0 +1,75 @@
1
+ {
2
+ "name": "MenuItem",
3
+ "source": "src/components/Menu.tsx",
4
+ "propsType": "MenuItemProps",
5
+ "import": "import { MenuItem } from 'ionbase-ui';",
6
+ "stylesheet": "src/styles/menu.css",
7
+ "tokens": [
8
+ "--border-focus",
9
+ "--border-subtle",
10
+ "--border-width-default",
11
+ "--border-width-thick",
12
+ "--font-family-sans",
13
+ "--font-weight-regular",
14
+ "--icon-default",
15
+ "--icon-disabled",
16
+ "--icon-primary",
17
+ "--icon-size-sm",
18
+ "--ion-duration-base",
19
+ "--ion-ease-out",
20
+ "--radius-sm",
21
+ "--radius-xl",
22
+ "--spacing-12",
23
+ "--spacing-2",
24
+ "--spacing-40",
25
+ "--spacing-6",
26
+ "--spacing-8",
27
+ "--surface-default",
28
+ "--surface-hover",
29
+ "--surface-primary-subtle",
30
+ "--text-disabled",
31
+ "--text-primary",
32
+ "--text-secondary",
33
+ "--type-body",
34
+ "--type-body-line-height"
35
+ ],
36
+ "props": {
37
+ "isSelected": {
38
+ "type": "boolean | undefined",
39
+ "required": false,
40
+ "origin": "own",
41
+ "description": "Figma's `Selected` / `Selected-hover` states. Shows the trailing check."
42
+ },
43
+ "icon": {
44
+ "type": "React.ReactNode",
45
+ "required": false,
46
+ "origin": "own",
47
+ "description": "Figma's `Show Leading Icon` + `Leading Icon` swap."
48
+ },
49
+ "isDisabled": {
50
+ "type": "boolean | undefined",
51
+ "required": false,
52
+ "origin": "own",
53
+ "description": "Whether the item is disabled."
54
+ },
55
+ "disabled": {
56
+ "type": "boolean | undefined",
57
+ "required": false,
58
+ "origin": "own",
59
+ "tags": {
60
+ "deprecated": "Use `isDisabled`. Accepted as an alias for one minor version."
61
+ }
62
+ },
63
+ "children": {
64
+ "type": "React.ReactNode",
65
+ "required": false,
66
+ "origin": "own"
67
+ }
68
+ },
69
+ "propCounts": {
70
+ "own": 5,
71
+ "aria": 0,
72
+ "dom": 285,
73
+ "other": 0
74
+ }
75
+ }