@gtivr4/a1-design-system-react 0.1.0 → 0.2.3

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 (108) hide show
  1. package/package.json +1 -1
  2. package/src/color-scheme.css +586 -24
  3. package/src/components/accordion/Accordion.jsx +80 -0
  4. package/src/components/accordion/accordion.css +118 -0
  5. package/src/components/banner/Banner.jsx +66 -0
  6. package/src/components/banner/banner.css +205 -0
  7. package/src/components/bleed/Bleed.jsx +27 -0
  8. package/src/components/bleed/bleed.css +5 -0
  9. package/src/components/blockquote/Blockquote.jsx +40 -0
  10. package/src/components/blockquote/blockquote.css +166 -0
  11. package/src/components/breadcrumb/Breadcrumb.jsx +82 -0
  12. package/src/components/breadcrumb/breadcrumb.css +133 -0
  13. package/src/components/button/button.css +42 -12
  14. package/src/components/button-container/ButtonContainer.jsx +20 -1
  15. package/src/components/button-container/button-container.css +19 -1
  16. package/src/components/calendar/Calendar.jsx +383 -0
  17. package/src/components/calendar/calendar.css +225 -0
  18. package/src/components/card/Card.jsx +50 -12
  19. package/src/components/card/card.css +178 -14
  20. package/src/components/checkbox-group/CheckboxGroup.jsx +120 -0
  21. package/src/components/checkbox-group/checkbox-group.css +304 -0
  22. package/src/components/cluster/Cluster.jsx +52 -0
  23. package/src/components/cluster/cluster.css +9 -0
  24. package/src/components/code/Code.jsx +135 -0
  25. package/src/components/code/code.css +60 -0
  26. package/src/components/data-table/DataTable.jsx +721 -0
  27. package/src/components/data-table/DataTableFilters.jsx +339 -0
  28. package/src/components/data-table/data-table-filters.css +259 -0
  29. package/src/components/data-table/data-table.css +425 -0
  30. package/src/components/dialog/Dialog.jsx +45 -2
  31. package/src/components/dialog/dialog.css +13 -4
  32. package/src/components/divider/Divider.jsx +64 -0
  33. package/src/components/divider/divider.css +170 -0
  34. package/src/components/field/CreditCardField.jsx +131 -0
  35. package/src/components/field/DateField.jsx +11 -0
  36. package/src/components/field/NumberField.jsx +11 -0
  37. package/src/components/field/PhoneField.jsx +107 -0
  38. package/src/components/field/SelectField.jsx +86 -0
  39. package/src/components/field/TextField.jsx +83 -0
  40. package/src/components/field/TextareaField.jsx +147 -0
  41. package/src/components/field/TimeField.jsx +11 -0
  42. package/src/components/field/ZipField.jsx +114 -0
  43. package/src/components/field/credit-card.css +30 -0
  44. package/src/components/field/field.css +380 -0
  45. package/src/components/field/textarea-field.css +185 -0
  46. package/src/components/field-row/FieldRow.jsx +23 -0
  47. package/src/components/field-row/field-row.css +51 -0
  48. package/src/components/fieldset/Fieldset.jsx +49 -0
  49. package/src/components/fieldset/fieldset.css +75 -0
  50. package/src/components/figure/Figure.jsx +63 -0
  51. package/src/components/figure/figure.css +97 -0
  52. package/src/components/grid/Grid.jsx +36 -2
  53. package/src/components/grid/grid.css +129 -4
  54. package/src/components/heading/Heading.jsx +41 -1
  55. package/src/components/heading/heading.css +65 -4
  56. package/src/components/icon/icon.css +1 -0
  57. package/src/components/icon-button/icon-button.css +1 -0
  58. package/src/components/inline/inline.css +51 -0
  59. package/src/components/inline-editable/InlineEditable.jsx +77 -0
  60. package/src/components/inline-editable/inline-editable.css +47 -0
  61. package/src/components/inset/Inset.jsx +27 -0
  62. package/src/components/inset/inset.css +6 -0
  63. package/src/components/labels/Labels.jsx +5 -5
  64. package/src/components/link/Link.jsx +2 -3
  65. package/src/components/link/link.css +30 -1
  66. package/src/components/list/List.jsx +92 -0
  67. package/src/components/list/list.css +178 -0
  68. package/src/components/menu/Menu.jsx +243 -10
  69. package/src/components/menu/menu.css +157 -17
  70. package/src/components/message/Message.jsx +25 -50
  71. package/src/components/message/message.css +50 -33
  72. package/src/components/notification/Notification.jsx +1 -1
  73. package/src/components/page-layout/PageLayout.jsx +16 -1
  74. package/src/components/page-layout/page-layout.css +97 -4
  75. package/src/components/page-nav/PageNav.jsx +110 -0
  76. package/src/components/page-nav/page-nav.css +167 -0
  77. package/src/components/paragraph/Paragraph.jsx +35 -2
  78. package/src/components/paragraph/paragraph.css +38 -1
  79. package/src/components/radio-group/RadioGroup.jsx +121 -0
  80. package/src/components/radio-group/radio-group.css +268 -0
  81. package/src/components/section/Section.jsx +108 -0
  82. package/src/components/section/section.css +280 -0
  83. package/src/components/segmented-control/SegmentedControl.jsx +4 -0
  84. package/src/components/segmented-control/segmented.css +13 -0
  85. package/src/components/side-nav/SideNav.jsx +29 -9
  86. package/src/components/side-nav/scrim.css +1 -1
  87. package/src/components/side-nav/side-nav.css +70 -32
  88. package/src/components/snackbar/Snackbar.jsx +56 -0
  89. package/src/components/snackbar/snackbar.css +113 -0
  90. package/src/components/spacer/Spacer.jsx +36 -0
  91. package/src/components/spacer/spacer.css +44 -0
  92. package/src/components/stack/Stack.jsx +100 -0
  93. package/src/components/stack/stack.css +37 -0
  94. package/src/components/switch/Switch.jsx +114 -0
  95. package/src/components/switch/switch.css +276 -0
  96. package/src/components/system-banner/SystemBanner.jsx +57 -0
  97. package/src/components/system-banner/system-banner.css +118 -0
  98. package/src/components/tabs/Tabs.jsx +96 -28
  99. package/src/components/tabs/tabs.css +352 -15
  100. package/src/components/token-select/TokenSelect.jsx +159 -0
  101. package/src/components/token-select/token-select.css +110 -0
  102. package/src/components/top-header/TopHeader.jsx +641 -0
  103. package/src/components/top-header/top-header.css +337 -0
  104. package/src/illustrations/ComponentThumbnails.jsx +227 -0
  105. package/src/index.js +41 -5
  106. package/src/themes.css +256 -5
  107. package/src/utilities/spacing.css +8 -0
  108. package/src/utilities/sr-only.css +16 -0
@@ -0,0 +1,337 @@
1
+ /* ═══════════════════════════════════════════════════════════════════════════
2
+ TopHeader
3
+ ═══════════════════════════════════════════════════════════════════════════ */
4
+
5
+ /* ── Shell ───────────────────────────────────────────────────────────────── */
6
+
7
+ .a1-top-header {
8
+ box-sizing: border-box;
9
+ position: sticky;
10
+ top: 0;
11
+ z-index: var(--component-top-header-z-index);
12
+ display: flex;
13
+ align-items: stretch;
14
+ height: var(--component-top-header-height);
15
+ padding-inline: var(--component-top-header-padding-inline);
16
+ background: var(--semantic-color-surface-page);
17
+ border-bottom: var(--component-top-header-border-width) solid var(--semantic-color-border-subtle);
18
+ }
19
+
20
+ /* ── Hamburger (hidden on desktop) ───────────────────────────────────────── */
21
+
22
+ .a1-top-header__hamburger {
23
+ display: none;
24
+ align-items: center;
25
+ justify-content: center;
26
+ align-self: center;
27
+ width: 36px;
28
+ height: 36px;
29
+ padding: 0;
30
+ margin-inline-end: var(--base-spacing-4);
31
+ background: transparent;
32
+ border: none;
33
+ border-radius: var(--base-radius-md);
34
+ color: var(--semantic-color-text-default);
35
+ cursor: pointer;
36
+ font-size: 24px;
37
+ flex-shrink: 0;
38
+ transition: background var(--semantic-motion-duration-fast) var(--semantic-motion-easing-standard);
39
+ }
40
+
41
+ .a1-top-header__hamburger:hover {
42
+ background: var(--semantic-color-surface-raised);
43
+ }
44
+
45
+ .a1-top-header__hamburger:focus-visible {
46
+ outline: 2px solid var(--semantic-color-action-background);
47
+ outline-offset: 1px;
48
+ }
49
+
50
+ /* ── Logo ────────────────────────────────────────────────────────────────── */
51
+
52
+ .a1-top-header__logo {
53
+ display: flex;
54
+ align-items: center;
55
+ flex-shrink: 0;
56
+ text-decoration: none;
57
+ color: var(--semantic-color-text-default);
58
+ font-family: var(--component-paragraph-font-family);
59
+ font-size: var(--semantic-font-size-heading-sm);
60
+ font-weight: var(--semantic-font-weight-display);
61
+ letter-spacing: -0.015em;
62
+ line-height: 1;
63
+ padding-inline-end: var(--base-spacing-16);
64
+ }
65
+
66
+ .a1-top-header__logo img,
67
+ .a1-top-header__logo svg {
68
+ display: block;
69
+ height: 28px;
70
+ width: auto;
71
+ }
72
+
73
+ /* ── Desktop nav ─────────────────────────────────────────────────────────── */
74
+
75
+ .a1-top-header__nav {
76
+ display: flex;
77
+ align-items: stretch;
78
+ min-width: 0;
79
+ }
80
+
81
+ .a1-top-header__nav-list {
82
+ display: flex;
83
+ align-items: stretch;
84
+ gap: var(--base-spacing-2);
85
+ list-style: none;
86
+ margin: 0;
87
+ padding: 0;
88
+ }
89
+
90
+ .a1-top-header__nav-item {
91
+ position: relative;
92
+ display: flex;
93
+ align-items: stretch;
94
+ }
95
+
96
+ .a1-top-header__nav-item--split {
97
+ gap: 0;
98
+ }
99
+
100
+ .a1-top-header__nav-link {
101
+ display: inline-flex;
102
+ align-items: center;
103
+ gap: var(--base-spacing-6);
104
+ padding-inline: var(--base-spacing-12);
105
+ color: var(--semantic-color-text-muted);
106
+ font-family: var(--component-paragraph-font-family);
107
+ font-size: var(--semantic-font-size-body-sm);
108
+ font-weight: 500;
109
+ text-decoration: none;
110
+ white-space: nowrap;
111
+ background: transparent;
112
+ border: none;
113
+ border-bottom: 2px solid transparent;
114
+ cursor: pointer;
115
+ transition:
116
+ color var(--semantic-motion-duration-fast) var(--semantic-motion-easing-standard),
117
+ background var(--semantic-motion-duration-fast) var(--semantic-motion-easing-standard);
118
+ }
119
+
120
+ .a1-top-header__nav-link:hover {
121
+ color: var(--semantic-color-text-default);
122
+ background: var(--semantic-color-surface-panel);
123
+ }
124
+
125
+ .a1-top-header__nav-link:active,
126
+ .a1-top-header__nav-link[aria-expanded="true"],
127
+ .a1-top-header__nav-item--split:has(.a1-top-header__nav-submenu-trigger[aria-expanded="true"]) > .a1-top-header__nav-link {
128
+ color: var(--semantic-color-text-default);
129
+ background: var(--semantic-color-surface-raised);
130
+ }
131
+
132
+ .a1-top-header__nav-link:focus-visible {
133
+ outline: 2px solid var(--semantic-color-action-background);
134
+ outline-offset: -2px;
135
+ }
136
+
137
+ .a1-top-header__nav-link--active {
138
+ color: var(--semantic-color-text-default);
139
+ border-bottom-color: var(--semantic-color-action-background);
140
+ }
141
+
142
+ .a1-top-header__nav-item--split > .a1-top-header__nav-link:first-child {
143
+ padding-inline-end: var(--base-spacing-8);
144
+ }
145
+
146
+ .a1-top-header__nav-submenu-trigger {
147
+ padding-inline: var(--base-spacing-8);
148
+ }
149
+
150
+ .a1-top-header__nav-submenu-trigger .a1-top-header__nav-chevron {
151
+ margin-inline-start: 0;
152
+ }
153
+
154
+ /* icon-only: square-ish click target, no text gap */
155
+ .a1-top-header__nav-link--icon-only {
156
+ padding-inline: var(--base-spacing-12);
157
+ }
158
+
159
+ .a1-top-header__nav-link-icon {
160
+ font-size: 20px;
161
+ flex-shrink: 0;
162
+ }
163
+
164
+ .a1-top-header__nav-chevron {
165
+ font-size: 18px;
166
+ flex-shrink: 0;
167
+ margin-inline-start: calc(var(--base-spacing-4) * -1);
168
+ transition: transform var(--semantic-motion-duration-fast) var(--semantic-motion-easing-standard);
169
+ }
170
+
171
+ [aria-expanded="true"] > .a1-top-header__nav-chevron {
172
+ transform: rotate(180deg);
173
+ }
174
+
175
+ /* ── Nested nav flyouts ───────────────────────────────────────────────────── */
176
+
177
+ .a1-menu--with-flyouts {
178
+ overflow: visible;
179
+ }
180
+
181
+ .a1-top-header__flyout-wrap {
182
+ position: relative;
183
+ }
184
+
185
+ .a1-top-header__flyout-trigger {
186
+ color: var(--semantic-color-text-default);
187
+ }
188
+
189
+ .a1-top-header__flyout-label {
190
+ overflow-wrap: anywhere;
191
+ }
192
+
193
+ .a1-top-header__flyout-trigger:hover,
194
+ .a1-top-header__flyout-wrap:focus-within > .a1-top-header__flyout-trigger,
195
+ .a1-top-header__flyout-wrap:hover > .a1-top-header__flyout-trigger {
196
+ background: var(--semantic-color-surface-raised);
197
+ }
198
+
199
+ .a1-top-header__flyout-trigger:active,
200
+ .a1-top-header__flyout-trigger[aria-expanded="true"] {
201
+ background: color-mix(in srgb, var(--semantic-color-surface-raised), var(--semantic-color-text-default) 8%);
202
+ }
203
+
204
+ .a1-top-header__flyout-trigger:focus-visible {
205
+ background: var(--semantic-color-surface-raised);
206
+ outline: var(--component-menu-item-focus-ring-width) solid var(--semantic-color-text-accent);
207
+ outline-offset: var(--component-menu-item-focus-ring-offset);
208
+ }
209
+
210
+ .a1-top-header__flyout-icon {
211
+ color: var(--semantic-color-text-muted);
212
+ }
213
+
214
+ .a1-top-header__flyout-chevron {
215
+ margin-inline-start: auto;
216
+ flex-shrink: 0;
217
+ font-size: var(--semantic-font-size-body-md);
218
+ color: var(--semantic-color-text-muted);
219
+ }
220
+
221
+ .a1-top-header__flyout-menu {
222
+ position: absolute;
223
+ z-index: calc(var(--component-menu-z-index, 1000) + 1);
224
+ inset-block-start: calc(var(--base-spacing-8) * -1);
225
+ inset-inline-start: 100%;
226
+ inset-inline-end: auto;
227
+ box-sizing: border-box;
228
+ min-inline-size: var(--component-menu-width);
229
+ max-inline-size: calc(100dvw - (var(--component-menu-viewport-offset) * 2));
230
+ max-block-size: var(
231
+ --a1-top-header-flyout-max-block-size,
232
+ calc(100dvh - var(--component-menu-viewport-offset))
233
+ );
234
+ overflow-x: hidden;
235
+ overflow-y: auto;
236
+ overscroll-behavior: contain;
237
+ padding: var(--base-spacing-8);
238
+ border: var(--component-menu-border-width) solid var(--semantic-color-border-subtle);
239
+ border-radius: var(--base-radius-lg);
240
+ background: var(--semantic-color-surface-panel);
241
+ box-shadow: var(--semantic-shadow-lg);
242
+ }
243
+
244
+ .a1-top-header__flyout-menu[data-placement="start"] {
245
+ inset-inline-start: auto;
246
+ inset-inline-end: 100%;
247
+ }
248
+
249
+ /* ── Right-side end zone ──────────────────────────────────────────────────── */
250
+
251
+ .a1-top-header__end {
252
+ display: flex;
253
+ align-items: center;
254
+ gap: var(--base-spacing-4);
255
+ margin-inline-start: auto;
256
+ padding-inline-start: var(--base-spacing-8);
257
+ flex-shrink: 0;
258
+ }
259
+
260
+ /* ── Action button + badge ────────────────────────────────────────────────── */
261
+
262
+ .a1-top-header__action {
263
+ position: relative;
264
+ }
265
+
266
+ .a1-top-header__action-badge-wrap {
267
+ position: relative;
268
+ }
269
+
270
+ .a1-top-header__action-badge-wrap::after {
271
+ content: attr(data-count);
272
+ position: absolute;
273
+ top: 3px;
274
+ right: 3px;
275
+ min-width: 16px;
276
+ height: 16px;
277
+ padding: 0 var(--base-spacing-4);
278
+ background: var(--semantic-color-status-error-background);
279
+ color: var(--semantic-color-status-error-foreground);
280
+ border-radius: 8px;
281
+ font-family: var(--component-paragraph-font-family);
282
+ font-size: 10px;
283
+ font-weight: 700;
284
+ line-height: 16px;
285
+ text-align: center;
286
+ pointer-events: none;
287
+ }
288
+
289
+ /* Action menus use the DS Menu component — no custom dropdown CSS needed. */
290
+
291
+ /* ── Identity header (non-interactive) inside action menus ───────────────── */
292
+
293
+ .a1-top-header__menu-identity {
294
+ display: flex;
295
+ flex-direction: column;
296
+ gap: var(--base-spacing-2);
297
+ padding: var(--base-spacing-4) var(--base-spacing-8);
298
+ }
299
+
300
+ .a1-top-header__menu-identity-name {
301
+ font-family: var(--component-paragraph-font-family);
302
+ font-size: var(--semantic-font-size-body-sm);
303
+ font-weight: 600;
304
+ color: var(--semantic-color-text-default);
305
+ line-height: 1.3;
306
+ }
307
+
308
+ .a1-top-header__menu-identity-desc {
309
+ font-family: var(--component-paragraph-font-family);
310
+ font-size: var(--semantic-font-size-body-xs);
311
+ color: var(--semantic-color-text-muted);
312
+ line-height: 1.4;
313
+ }
314
+
315
+ /* Mobile drawer uses the DS SideNav component — no custom drawer CSS needed. */
316
+
317
+ /* ── Login button in end zone ─────────────────────────────────────────────── */
318
+
319
+ .a1-top-header__login {
320
+ margin-inline-start: var(--base-spacing-4);
321
+ }
322
+
323
+ /* ── Responsive ──────────────────────────────────────────────────────────── */
324
+
325
+ @media (max-width: 768px) {
326
+ .a1-top-header {
327
+ padding-inline: var(--base-spacing-16);
328
+ }
329
+
330
+ .a1-top-header__hamburger {
331
+ display: flex;
332
+ }
333
+
334
+ .a1-top-header__nav {
335
+ display: none;
336
+ }
337
+ }
@@ -0,0 +1,227 @@
1
+ import React from "react";
2
+
3
+ const svgProps = {
4
+ viewBox: "0 0 80 56",
5
+ xmlns: "http://www.w3.org/2000/svg",
6
+ "aria-hidden": "true",
7
+ focusable: "false",
8
+ };
9
+
10
+ export function AlertThumbnail(props) {
11
+ return (
12
+ <svg {...svgProps} {...props}>
13
+ <rect x="4" y="8" width="72" height="40" rx="3" stroke="#94A3B8" strokeWidth="1.5" fill="none" />
14
+ <rect x="4" y="8" width="5" height="40" fill="#94A3B8" rx="1" />
15
+ <circle cx="20" cy="28" r="4" fill="#94A3B8" />
16
+ <rect x="30" y="21" width="42" height="4" rx="2" fill="#CBD5E1" />
17
+ <rect x="30" y="29" width="34" height="4" rx="2" fill="#CBD5E1" />
18
+ </svg>
19
+ );
20
+ }
21
+
22
+ export function BannerThumbnail(props) {
23
+ return (
24
+ <svg {...svgProps} {...props}>
25
+ <rect x="0" y="0" width="80" height="16" fill="#94A3B8" />
26
+ <rect x="8" y="5" width="36" height="5" rx="2" fill="white" opacity="0.6" />
27
+ <rect x="4" y="26" width="72" height="4" rx="2" fill="#CBD5E1" />
28
+ <rect x="4" y="34" width="60" height="4" rx="2" fill="#CBD5E1" />
29
+ <rect x="4" y="42" width="48" height="4" rx="2" fill="#CBD5E1" />
30
+ </svg>
31
+ );
32
+ }
33
+
34
+ export function ButtonThumbnail(props) {
35
+ return (
36
+ <svg {...svgProps} {...props}>
37
+ <rect x="16" y="18" width="48" height="20" rx="3" fill="#94A3B8" />
38
+ <rect x="22" y="24" width="36" height="5" rx="2" fill="white" opacity="0.65" />
39
+ </svg>
40
+ );
41
+ }
42
+
43
+ export function CardThumbnail(props) {
44
+ return (
45
+ <svg {...svgProps} {...props}>
46
+ <rect x="4" y="4" width="72" height="48" rx="3" stroke="#CBD5E1" strokeWidth="1.5" fill="none" />
47
+ <rect x="10" y="12" width="44" height="6" rx="2" fill="#94A3B8" />
48
+ <rect x="10" y="24" width="60" height="4" rx="2" fill="#CBD5E1" />
49
+ <rect x="10" y="32" width="52" height="4" rx="2" fill="#CBD5E1" />
50
+ <rect x="10" y="40" width="40" height="4" rx="2" fill="#CBD5E1" />
51
+ </svg>
52
+ );
53
+ }
54
+
55
+ export function ChecklistThumbnail(props) {
56
+ return (
57
+ <svg {...svgProps} {...props}>
58
+ <rect x="4" y="8" width="10" height="10" rx="2" stroke="#94A3B8" strokeWidth="1.5" fill="none" />
59
+ <path d="M6 13 L9 16 L14 10" stroke="#94A3B8" strokeWidth="1.5" fill="none" strokeLinecap="round" strokeLinejoin="round" />
60
+ <rect x="20" y="11" width="52" height="4" rx="2" fill="#CBD5E1" />
61
+ <rect x="4" y="24" width="10" height="10" rx="2" stroke="#94A3B8" strokeWidth="1.5" fill="none" />
62
+ <path d="M6 29 L9 32 L14 26" stroke="#94A3B8" strokeWidth="1.5" fill="none" strokeLinecap="round" strokeLinejoin="round" />
63
+ <rect x="20" y="27" width="44" height="4" rx="2" fill="#CBD5E1" />
64
+ <rect x="4" y="40" width="10" height="10" rx="2" stroke="#CBD5E1" strokeWidth="1.5" fill="none" />
65
+ <rect x="20" y="43" width="56" height="4" rx="2" fill="#CBD5E1" />
66
+ </svg>
67
+ );
68
+ }
69
+
70
+ export function DetailsThumbnail(props) {
71
+ return (
72
+ <svg {...svgProps} {...props}>
73
+ <path d="M4 14 L12 18 L4 22 Z" fill="#94A3B8" />
74
+ <rect x="16" y="13" width="48" height="6" rx="2" fill="#94A3B8" opacity="0.7" />
75
+ <line x1="14" y1="26" x2="76" y2="26" stroke="#CBD5E1" strokeWidth="1" />
76
+ <rect x="14" y="30" width="58" height="4" rx="2" fill="#CBD5E1" />
77
+ <rect x="14" y="38" width="52" height="4" rx="2" fill="#CBD5E1" />
78
+ <rect x="14" y="46" width="44" height="4" rx="2" fill="#CBD5E1" />
79
+ </svg>
80
+ );
81
+ }
82
+
83
+ export function FormThumbnail(props) {
84
+ return (
85
+ <svg {...svgProps} {...props}>
86
+ <rect x="4" y="4" width="28" height="3" rx="1.5" fill="#94A3B8" />
87
+ <rect x="4" y="10" width="72" height="10" rx="2" stroke="#94A3B8" strokeWidth="1" fill="none" />
88
+ <rect x="4" y="26" width="24" height="3" rx="1.5" fill="#94A3B8" />
89
+ <rect x="4" y="32" width="72" height="10" rx="2" stroke="#94A3B8" strokeWidth="1" fill="none" />
90
+ <rect x="52" y="46" width="24" height="8" rx="2" fill="#94A3B8" />
91
+ <rect x="56" y="48" width="16" height="4" rx="2" fill="white" opacity="0.65" />
92
+ </svg>
93
+ );
94
+ }
95
+
96
+ export function HeadingThumbnail(props) {
97
+ return (
98
+ <svg {...svgProps} {...props}>
99
+ <rect x="4" y="8" width="52" height="9" rx="2" fill="#94A3B8" />
100
+ <rect x="4" y="24" width="72" height="4" rx="2" fill="#CBD5E1" />
101
+ <rect x="4" y="32" width="64" height="4" rx="2" fill="#CBD5E1" />
102
+ <rect x="4" y="40" width="52" height="4" rx="2" fill="#CBD5E1" />
103
+ </svg>
104
+ );
105
+ }
106
+
107
+ export function ImageThumbnail(props) {
108
+ return (
109
+ <svg {...svgProps} {...props}>
110
+ <rect x="4" y="4" width="72" height="48" rx="3" stroke="#CBD5E1" strokeWidth="1.5" fill="#F8FAFC" />
111
+ <circle cx="22" cy="18" r="6" fill="#CBD5E1" />
112
+ <path d="M4 48 L24 30 L40 40 L56 24 L76 40 L76 52 L4 52 Z" fill="#E2E8F0" />
113
+ </svg>
114
+ );
115
+ }
116
+
117
+ export function LinkThumbnail(props) {
118
+ return (
119
+ <svg {...svgProps} {...props}>
120
+ <rect x="4" y="22" width="52" height="5" rx="2" fill="#94A3B8" />
121
+ <line x1="4" y1="29" x2="56" y2="29" stroke="#94A3B8" strokeWidth="1" />
122
+ <path d="M62 24 L74 28 L62 32" stroke="#94A3B8" strokeWidth="1.5" fill="none" strokeLinecap="round" strokeLinejoin="round" />
123
+ <line x1="62" y1="28" x2="74" y2="28" stroke="#94A3B8" strokeWidth="1.5" strokeLinecap="round" />
124
+ </svg>
125
+ );
126
+ }
127
+
128
+ export function ListThumbnail(props) {
129
+ return (
130
+ <svg {...svgProps} {...props}>
131
+ <circle cx="10" cy="14" r="3" fill="#CBD5E1" />
132
+ <rect x="18" y="11" width="54" height="5" rx="2" fill="#CBD5E1" />
133
+ <circle cx="10" cy="28" r="3" fill="#CBD5E1" />
134
+ <rect x="18" y="25" width="48" height="5" rx="2" fill="#CBD5E1" />
135
+ <circle cx="10" cy="42" r="3" fill="#CBD5E1" />
136
+ <rect x="18" y="39" width="56" height="5" rx="2" fill="#CBD5E1" />
137
+ </svg>
138
+ );
139
+ }
140
+
141
+ export function ParagraphThumbnail(props) {
142
+ return (
143
+ <svg {...svgProps} {...props}>
144
+ <rect x="4" y="6" width="72" height="4" rx="2" fill="#CBD5E1" />
145
+ <rect x="4" y="14" width="68" height="4" rx="2" fill="#CBD5E1" />
146
+ <rect x="4" y="22" width="72" height="4" rx="2" fill="#CBD5E1" />
147
+ <rect x="4" y="30" width="56" height="4" rx="2" fill="#CBD5E1" />
148
+ <rect x="4" y="42" width="72" height="4" rx="2" fill="#CBD5E1" />
149
+ <rect x="4" y="50" width="44" height="4" rx="2" fill="#CBD5E1" />
150
+ </svg>
151
+ );
152
+ }
153
+
154
+ export function StatusThumbnail(props) {
155
+ return (
156
+ <svg {...svgProps} {...props}>
157
+ <rect x="20" y="20" width="40" height="16" rx="8" fill="#94A3B8" />
158
+ <rect x="26" y="25" width="28" height="5" rx="2" fill="white" opacity="0.65" />
159
+ </svg>
160
+ );
161
+ }
162
+
163
+ export function TableThumbnail(props) {
164
+ return (
165
+ <svg {...svgProps} {...props}>
166
+ <rect x="4" y="6" width="72" height="44" rx="2" stroke="#CBD5E1" strokeWidth="1" fill="none" />
167
+ <rect x="4" y="6" width="72" height="12" fill="#E2E8F0" rx="1" />
168
+ <line x1="30" y1="6" x2="30" y2="50" stroke="#CBD5E1" strokeWidth="1" />
169
+ <line x1="56" y1="6" x2="56" y2="50" stroke="#CBD5E1" strokeWidth="1" />
170
+ <line x1="4" y1="28" x2="76" y2="28" stroke="#CBD5E1" strokeWidth="1" />
171
+ <line x1="4" y1="39" x2="76" y2="39" stroke="#CBD5E1" strokeWidth="1" />
172
+ <rect x="8" y="9" width="18" height="5" rx="1" fill="#94A3B8" opacity="0.5" />
173
+ <rect x="34" y="9" width="16" height="5" rx="1" fill="#94A3B8" opacity="0.5" />
174
+ <rect x="60" y="9" width="12" height="5" rx="1" fill="#94A3B8" opacity="0.5" />
175
+ </svg>
176
+ );
177
+ }
178
+
179
+ export function TabsThumbnail(props) {
180
+ return (
181
+ <svg {...svgProps} {...props}>
182
+ <rect x="4" y="8" width="22" height="12" rx="2" fill="#94A3B8" />
183
+ <rect x="4" y="20" width="22" height="2" fill="#94A3B8" />
184
+ <rect x="28" y="8" width="20" height="12" rx="2" stroke="#CBD5E1" strokeWidth="1" fill="none" />
185
+ <rect x="50" y="8" width="20" height="12" rx="2" stroke="#CBD5E1" strokeWidth="1" fill="none" />
186
+ <rect x="4" y="28" width="72" height="4" rx="2" fill="#CBD5E1" />
187
+ <rect x="4" y="36" width="60" height="4" rx="2" fill="#CBD5E1" />
188
+ <rect x="4" y="44" width="48" height="4" rx="2" fill="#CBD5E1" />
189
+ </svg>
190
+ );
191
+ }
192
+
193
+ export function TimelineThumbnail(props) {
194
+ return (
195
+ <svg {...svgProps} {...props}>
196
+ <line x1="18" y1="6" x2="18" y2="50" stroke="#E2E8F0" strokeWidth="2" />
197
+ <circle cx="18" cy="14" r="5" fill="#94A3B8" />
198
+ <rect x="28" y="11" width="44" height="4" rx="2" fill="#CBD5E1" />
199
+ <rect x="28" y="18" width="32" height="3" rx="1.5" fill="#E2E8F0" />
200
+ <circle cx="18" cy="30" r="5" fill="#94A3B8" />
201
+ <rect x="28" y="27" width="40" height="4" rx="2" fill="#CBD5E1" />
202
+ <rect x="28" y="34" width="28" height="3" rx="1.5" fill="#E2E8F0" />
203
+ <circle cx="18" cy="46" r="5" stroke="#CBD5E1" strokeWidth="1.5" fill="none" />
204
+ <rect x="28" y="43" width="36" height="4" rx="2" fill="#E2E8F0" />
205
+ </svg>
206
+ );
207
+ }
208
+
209
+ export const componentThumbnailMap = {
210
+ Alert: AlertThumbnail,
211
+ Banner: BannerThumbnail,
212
+ Button: ButtonThumbnail,
213
+ Card: CardThumbnail,
214
+ Checklist: ChecklistThumbnail,
215
+ Details: DetailsThumbnail,
216
+ Form: FormThumbnail,
217
+ Heading: HeadingThumbnail,
218
+ Image: ImageThumbnail,
219
+ Link: LinkThumbnail,
220
+ List: ListThumbnail,
221
+ Paragraph: ParagraphThumbnail,
222
+ Status: StatusThumbnail,
223
+ "Status summary": StatusThumbnail,
224
+ Table: TableThumbnail,
225
+ Tabs: TabsThumbnail,
226
+ Timeline: TimelineThumbnail,
227
+ };
package/src/index.js CHANGED
@@ -1,20 +1,56 @@
1
+ export { Accordion } from "./components/accordion/Accordion.jsx";
2
+ export { Calendar } from "./components/calendar/Calendar.jsx";
3
+ export { PageNav } from "./components/page-nav/PageNav.jsx";
4
+ export { Blockquote } from "./components/blockquote/Blockquote.jsx";
5
+ export { Breadcrumb } from "./components/breadcrumb/Breadcrumb.jsx";
1
6
  export { Notification } from "./components/notification/Notification.jsx";
7
+ export { Snackbar } from "./components/snackbar/Snackbar.jsx";
8
+ export { Bleed } from "./components/bleed/Bleed.jsx";
2
9
  export { IconButton } from "./components/icon-button/IconButton.jsx";
3
- export { Button } from "./components/button/Button.jsx";
4
- export { ButtonContainer } from "./components/button-container/ButtonContainer.jsx";
10
+ export { Button } from "./components/button/Button.jsx";export { ButtonContainer } from "./components/button-container/ButtonContainer.jsx";
5
11
  export { Card } from "./components/card/Card.jsx";
12
+ export { Cluster } from "./components/cluster/Cluster.jsx";
13
+ export { Code } from "./components/code/Code.jsx";
6
14
  export { Dialog } from "./components/dialog/Dialog.jsx";
7
- export { Heading } from "./components/heading/Heading.jsx";
15
+ export { Divider } from "./components/divider/Divider.jsx";
16
+ export { InlineEditable } from "./components/inline-editable/InlineEditable.jsx";
17
+ export { Heading, HeadingMark } from "./components/heading/Heading.jsx";
18
+ export { List, ListItem } from "./components/list/List.jsx";
19
+ export { Inset } from "./components/inset/Inset.jsx";
8
20
  export { Icon } from "./components/icon/Icon.jsx";
9
21
  export { Link } from "./components/link/Link.jsx";
10
22
  export { Paragraph } from "./components/paragraph/Paragraph.jsx";
11
- export { MessageBanner, MessageBadge, MessageEmptyState } from "./components/message/Message.jsx";
23
+ export { Banner } from "./components/banner/Banner.jsx";
24
+ export { Fieldset } from "./components/fieldset/Fieldset.jsx";
25
+ export { FieldRow } from "./components/field-row/FieldRow.jsx";
26
+ export { TextField } from "./components/field/TextField.jsx";
27
+ export { SelectField } from "./components/field/SelectField.jsx";
28
+ export { DateField } from "./components/field/DateField.jsx";
29
+ export { PhoneField } from "./components/field/PhoneField.jsx";
30
+ export { ZipField, ZIP_MASKS } from "./components/field/ZipField.jsx";
31
+ export { CreditCardField } from "./components/field/CreditCardField.jsx";
32
+ export { NumberField } from "./components/field/NumberField.jsx";
33
+ export { TimeField } from "./components/field/TimeField.jsx";
34
+ export { TextareaField } from "./components/field/TextareaField.jsx";
35
+ export { CheckboxGroup } from "./components/checkbox-group/CheckboxGroup.jsx";
36
+ export { RadioGroup } from "./components/radio-group/RadioGroup.jsx";
37
+ export { Switch } from "./components/switch/Switch.jsx";
38
+ export { MessageBadge, MessageEmptyState } from "./components/message/Message.jsx";
39
+
12
40
  export { Pagination } from "./components/pagination/Pagination.jsx";
13
41
  export { SegmentedControl } from "./components/segmented-control/SegmentedControl.jsx";
14
42
  export { Tabs, TabList, Tab, TabPanel } from "./components/tabs/Tabs.jsx";
15
43
  export { Grid, GridItem } from "./components/grid/Grid.jsx";
16
44
  export { Inverse } from "./components/inverse/Inverse.jsx";
45
+ export { Section } from "./components/section/Section.jsx";
46
+ export { Stack } from "./components/stack/Stack.jsx";
17
47
  export { PageLayout } from "./components/page-layout/PageLayout.jsx";
18
48
  export { LabelsProvider, useLabel } from "./components/labels/Labels.jsx";
19
- export { Menu, MenuSection } from "./components/menu/Menu.jsx";
49
+ export { Menu, MenuSection, MenuItem } from "./components/menu/Menu.jsx";
20
50
  export { SideNav, SideNavItem, SideNavGroup } from "./components/side-nav/SideNav.jsx";
51
+ export { TokenSelect } from "./components/token-select/TokenSelect.jsx";
52
+ export { TopHeader } from "./components/top-header/TopHeader.jsx";
53
+ export { DataTable } from "./components/data-table/DataTable.jsx";
54
+ export { DataTableFilters } from "./components/data-table/DataTableFilters.jsx";
55
+ export { Figure } from "./components/figure/Figure.jsx";
56
+ export { Spacer } from "./components/spacer/Spacer.jsx";