@valiify/dashboard-ui 0.1.0-alpha.1

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 (61) hide show
  1. package/CHANGELOG.md +104 -0
  2. package/LICENSE +21 -0
  3. package/README.md +373 -0
  4. package/dist/index.css +3743 -0
  5. package/package.json +82 -0
  6. package/src/base/index.css +21 -0
  7. package/src/components/ICON-SYSTEM.md +425 -0
  8. package/src/components/_template.css +109 -0
  9. package/src/components/alert.css +156 -0
  10. package/src/components/avatar.css +87 -0
  11. package/src/components/breadcrumbs.css +158 -0
  12. package/src/components/button.css +177 -0
  13. package/src/components/card.css +63 -0
  14. package/src/components/checkbox.css +181 -0
  15. package/src/components/chip.css +234 -0
  16. package/src/components/data-row.css +142 -0
  17. package/src/components/divider.css +143 -0
  18. package/src/components/dropdown-field.css +185 -0
  19. package/src/components/dropdown-menu.css +80 -0
  20. package/src/components/field-verification.css +156 -0
  21. package/src/components/filter-segment.css +163 -0
  22. package/src/components/icon-button.css +83 -0
  23. package/src/components/icon.css +145 -0
  24. package/src/components/index.css +47 -0
  25. package/src/components/input.css +180 -0
  26. package/src/components/link.css +183 -0
  27. package/src/components/loading-indicator.css +184 -0
  28. package/src/components/loading-inline.css +75 -0
  29. package/src/components/menu-item.css +138 -0
  30. package/src/components/modal.css +203 -0
  31. package/src/components/navigation-rail.css +558 -0
  32. package/src/components/pagination-item.css +196 -0
  33. package/src/components/pagination.css +108 -0
  34. package/src/components/pill.css +108 -0
  35. package/src/components/progress-bar.css +157 -0
  36. package/src/components/radio-select.css +97 -0
  37. package/src/components/section-marker.css +96 -0
  38. package/src/components/segment-selector.css +78 -0
  39. package/src/components/sensitive-data.css +77 -0
  40. package/src/components/skeleton.css +184 -0
  41. package/src/components/step.css +106 -0
  42. package/src/components/stepper.css +93 -0
  43. package/src/components/switch.css +99 -0
  44. package/src/components/tabs.css +213 -0
  45. package/src/components/tag.css +133 -0
  46. package/src/components/text-button.css +170 -0
  47. package/src/components/textarea.css +156 -0
  48. package/src/components/toast.css +182 -0
  49. package/src/components/tooltip.css +70 -0
  50. package/src/fonts.css +23 -0
  51. package/src/icons/README.md +297 -0
  52. package/src/icons/custom/help.svg +3 -0
  53. package/src/icons/custom/valiify-logo.svg +6 -0
  54. package/src/icons/icon-list.txt +2036 -0
  55. package/src/icons/sprite.svg +12223 -0
  56. package/src/index.css +35 -0
  57. package/src/library.css +34 -0
  58. package/src/themes/valiify.css +319 -0
  59. package/src/utilities/index.css +35 -0
  60. package/types/components.d.ts +630 -0
  61. package/types/index.d.ts +15 -0
@@ -0,0 +1,630 @@
1
+ /**
2
+ * Type-safe component class names for @valiify/dashboard-ui
3
+ *
4
+ * Use these types to get autocomplete and type checking for component classes.
5
+ *
6
+ * Example:
7
+ * import type { ButtonClass } from '@valiify/dashboard-ui/types';
8
+ * const buttonClasses: ButtonClass = 'btn btn-primary';
9
+ */
10
+
11
+ // Input component classes
12
+ export type InputSize = "input-sm" | "input-md" | "input-lg";
13
+ export type InputBgVariant = "input-bg-neutral";
14
+ export type InputState = "input-error" | "input-disabled";
15
+ export type InputPart =
16
+ | "input-container"
17
+ | "input-label"
18
+ | "input-help-button"
19
+ | "input-field"
20
+ | "input"
21
+ | "input-icon-left"
22
+ | "input-icon-right"
23
+ | "input-error-message";
24
+
25
+ export type InputClass = InputPart | InputSize | InputBgVariant | InputState;
26
+
27
+ // Card component classes
28
+ export type CardModifier = "card-compact" | "card-bordered" | "card-hover";
29
+ export type CardPart = "card-title" | "card-body";
30
+ export type CardClass = "card" | CardModifier | CardPart;
31
+
32
+ // RadioSelect component classes
33
+ export type RadioSelectPart = "radio-select-input" | "radio-select-label";
34
+ export type RadioSelectClass = "radio-select" | RadioSelectPart;
35
+
36
+ // Button component classes
37
+ // btn-critical is NOT in Figma's Button set (73:180) — it comes from Modal's
38
+ // destructive confirm button. See src/components/button.css.
39
+ export type ButtonVariant =
40
+ "btn-primary" | "btn-outline" | "btn-empty" | "btn-critical";
41
+ export type ButtonSize = "btn-sm" | "btn-lg";
42
+ export type ButtonClass = "btn" | ButtonVariant | ButtonSize;
43
+
44
+ // Chip component classes
45
+ export type ChipVariant =
46
+ | "chip-warning"
47
+ | "chip-critical"
48
+ | "chip-success"
49
+ | "chip-neutral"
50
+ | "chip-primary";
51
+ export type BadgeVariant =
52
+ | "badge-warning"
53
+ | "badge-critical"
54
+ | "badge-success"
55
+ | "badge-neutral"
56
+ | "badge-primary";
57
+ export type DotVariant =
58
+ | "dot-warning"
59
+ | "dot-critical"
60
+ | "dot-success"
61
+ | "dot-neutral"
62
+ | "dot-primary";
63
+ export type ChipPart = "chip-dot";
64
+ export type ChipState = "with-ring";
65
+ // Figma BG property. `yes` (filled) is the default, so it takes no class and
66
+ // only the opt-out is named — the same shape as Input/Textarea/DropdownField's
67
+ // `-bg-*` classes. There is no dot equivalent: BG is a no-op for a dot, whose
68
+ // BG=yes and BG=no variants render identically.
69
+ export type ChipBg = "chip-bg-no";
70
+ export type BadgeBg = "badge-bg-no";
71
+ // Figma Size property. SM is the default, so the bare classes stay SM.
72
+ export type ChipSize = "chip-sm" | "chip-md";
73
+ export type BadgeSize = "badge-sm" | "badge-md";
74
+ export type DotSize = "dot-sm" | "dot-md";
75
+ export type ChipClass =
76
+ | "chip"
77
+ | ChipVariant
78
+ | ChipPart
79
+ | ChipSize
80
+ | ChipBg
81
+ | "badge"
82
+ | BadgeVariant
83
+ | BadgeSize
84
+ | BadgeBg
85
+ | "dot"
86
+ | DotVariant
87
+ | DotSize
88
+ | ChipState;
89
+
90
+ // Switch component classes
91
+ export type SwitchPart = "switch-input";
92
+ export type SwitchClass = "switch" | SwitchPart;
93
+
94
+ // Icon component classes
95
+ export type IconSize =
96
+ | "icon-size-10"
97
+ | "icon-size-11"
98
+ | "icon-size-12"
99
+ | "icon-size-13"
100
+ | "icon-size-14"
101
+ | "icon-size-15"
102
+ | "icon-size-16"
103
+ | "icon-size-18"
104
+ | "icon-size-20"
105
+ | "icon-size-22"
106
+ | "icon-size-24";
107
+ export type IconState = "icon-ring";
108
+ export type IconClass = "icon" | IconSize | IconState;
109
+
110
+ // IconButton component classes
111
+ export type IconButtonSize =
112
+ "icon-button-xs" | "icon-button-md" | "icon-button-lg";
113
+ export type IconButtonClass = "icon-button" | IconButtonSize | "icon-ring";
114
+
115
+ // Textarea component classes
116
+ export type TextareaBgVariant = "textarea-bg-neutral";
117
+ export type TextareaState = "textarea-error" | "textarea-disabled";
118
+ export type TextareaPart =
119
+ | "textarea-container"
120
+ | "textarea-label"
121
+ | "textarea-field"
122
+ | "textarea"
123
+ | "textarea-error-message"
124
+ | "textarea-counter";
125
+
126
+ // No size type: Figma defines no Size property and height is consumer-driven.
127
+ export type TextareaClass = TextareaPart | TextareaBgVariant | TextareaState;
128
+
129
+ // MenuItem component classes
130
+ export type MenuItemSize = "menu-item-sm" | "menu-item-md" | "menu-item-lg";
131
+ export type MenuItemVariant = "menu-item-combined";
132
+ export type MenuItemPart =
133
+ | "menu-item"
134
+ | "menu-item-text"
135
+ | "menu-item-title"
136
+ | "menu-item-subtitle"
137
+ | "menu-item-right-text"
138
+ | "menu-item-badge";
139
+
140
+ export type MenuItemClass = MenuItemPart | MenuItemSize | MenuItemVariant;
141
+
142
+ // DropdownMenu component classes
143
+ export type DropdownMenuPart =
144
+ "dropdown-menu" | "dropdown-menu-divider" | "dropdown" | "dropdown-panel";
145
+
146
+ export type DropdownMenuClass = DropdownMenuPart;
147
+
148
+ // DropdownField component classes
149
+ export type DropdownFieldSize =
150
+ "dropdown-field-sm" | "dropdown-field-md" | "dropdown-field-lg";
151
+ export type DropdownFieldBgVariant = "dropdown-field-bg-neutral";
152
+ export type DropdownFieldState = "dropdown-field-error";
153
+ export type DropdownFieldPart =
154
+ | "dropdown-field-container"
155
+ | "dropdown-field-label"
156
+ | "dropdown-field"
157
+ | "dropdown-field-value"
158
+ | "dropdown-field-placeholder"
159
+ | "dropdown-field-icon"
160
+ | "dropdown-field-chevron"
161
+ | "dropdown-field-error-message";
162
+
163
+ export type DropdownFieldClass =
164
+ | DropdownFieldPart
165
+ | DropdownFieldSize
166
+ | DropdownFieldBgVariant
167
+ | DropdownFieldState;
168
+
169
+ // Avatar component classes
170
+ export type AvatarSize = "avatar-xs" | "avatar-sm" | "avatar-md" | "avatar-lg";
171
+ export type AvatarState = "avatar-disabled" | "with-ring";
172
+ export type AvatarClass = "avatar" | AvatarSize | AvatarState;
173
+
174
+ // Pill component classes
175
+ export type PillPart = "pill" | "pill-chevron";
176
+ export type PillState = "with-ring";
177
+ export type PillClass = PillPart | PillState;
178
+
179
+ // Tag component classes
180
+ export type TagSize = "tag-sm" | "tag-md";
181
+ export type TagPart = "tag" | "tag-count";
182
+ export type TagState = "with-ring";
183
+ export type TagClass = TagPart | TagSize | TagState;
184
+
185
+ // Tabs component classes
186
+ export type TabsType = "tab-underline" | "tab-chip" | "tab-segment";
187
+ export type TabsSize = "tab-sm";
188
+ export type TabsPart = "tabs" | "tab" | "tab-subtitle";
189
+ export type TabsState = "with-ring";
190
+ export type TabsClass = TabsPart | TabsType | TabsSize | TabsState;
191
+
192
+ // SegmentSelector component classes
193
+ export type SegmentSelectorClass =
194
+ | "segment-selector"
195
+ /** Equal-width segments. Not from Figma — its segments hug their labels. */
196
+ | "segment-selector-fill"
197
+ | "with-ring";
198
+
199
+ // Tooltip component classes
200
+ export type TooltipPart =
201
+ | "tooltip"
202
+ | "tooltip-title"
203
+ | "tooltip-content"
204
+ | "tooltip-divider"
205
+ | "tooltip-subtext";
206
+ export type TooltipClass = TooltipPart;
207
+
208
+ // Modal component classes
209
+ export type ModalAction =
210
+ "modal-destructive" | "modal-positive" | "modal-neutral";
211
+ export type ModalPart =
212
+ | "modal-header"
213
+ | "modal-title-group"
214
+ | "modal-icon"
215
+ | "modal-title"
216
+ | "modal-subtitles"
217
+ | "modal-subtitle"
218
+ | "modal-description"
219
+ | "modal-context"
220
+ | "modal-context-text"
221
+ | "modal-footer";
222
+ export type ModalClass = "modal" | ModalAction | ModalPart;
223
+
224
+ // TextButton component classes
225
+ // Text Button is NOT a .btn variant — different Figma component (679:21601),
226
+ // different type scale, and it hugs its text instead of having a fixed height.
227
+ export type TextButtonType =
228
+ "text-button-cell" | "text-button-text" | "text-button-primary";
229
+ export type TextButtonClass = "text-button" | TextButtonType | "with-ring";
230
+
231
+ // Toast component classes
232
+ // Style=Simple exists only for Type=info in Figma, so the type classes are
233
+ // inert on .toast-simple.
234
+ export type ToastType = "toast-success" | "toast-error" | "toast-info";
235
+ export type ToastStyle = "toast-simple";
236
+ export type ToastPart =
237
+ | "toast-header"
238
+ | "toast-main"
239
+ | "toast-icon"
240
+ | "toast-text"
241
+ | "toast-title"
242
+ | "toast-message"
243
+ | "toast-footer"
244
+ | "toast-timestamp";
245
+ export type ToastClass = "toast" | ToastType | ToastStyle | ToastPart;
246
+
247
+ // Alert component classes
248
+ // A type class is REQUIRED — .alert carries layout only and Figma's Type axis
249
+ // has no default. See src/components/alert.css.
250
+ export type AlertType =
251
+ | "alert-critical"
252
+ | "alert-warning"
253
+ | "alert-success"
254
+ | "alert-info"
255
+ | "alert-neutral";
256
+ export type AlertPart =
257
+ | "alert-body"
258
+ | "alert-icon"
259
+ | "alert-content"
260
+ | "alert-title"
261
+ | "alert-message";
262
+ export type AlertClass = "alert" | AlertType | AlertPart;
263
+
264
+ // SectionMarker component classes
265
+ // No "section-marker-na" — Figma's na variant draws nothing, so the class would
266
+ // carry no declarations. na is a bare .section-marker with no child.
267
+ export type SectionMarkerStatus =
268
+ | "section-marker-approve"
269
+ | "section-marker-mismatch"
270
+ | "section-marker-unverified";
271
+ export type SectionMarkerClass =
272
+ "section-marker" | SectionMarkerStatus | "section-marker-dot" | "with-ring";
273
+
274
+ // FieldVerification component classes
275
+ export type FieldVerificationState =
276
+ | "field-verification-verified"
277
+ | "field-verification-pending"
278
+ | "field-verification-none"
279
+ | "field-verification-mismatch";
280
+ export type FieldVerificationPart =
281
+ | "field-verification-icon"
282
+ | "field-verification-label"
283
+ | "field-verification-details"
284
+ | "field-verification-detail"
285
+ | "field-verification-action";
286
+ export type FieldVerificationClass =
287
+ | "field-verification"
288
+ | FieldVerificationState
289
+ | FieldVerificationPart
290
+ | "with-ring";
291
+
292
+ // PaginationItem component classes
293
+ // No "pagination-item-default" — default is the bare base class, matching
294
+ // Figma's default variant.
295
+ export type PaginationItemKind =
296
+ "pagination-item-active" | "pagination-item-ellipsis" | "pagination-item-nav";
297
+ export type PaginationItemClass = "pagination-item" | PaginationItemKind;
298
+
299
+ // Pagination component classes
300
+ // No "pagination-numbered" / "pagination-simple" — both Figma types share the
301
+ // same root and differ only in their children.
302
+ export type PaginationPart =
303
+ | "pagination-pages"
304
+ | "pagination-summary"
305
+ | "pagination-status"
306
+ | "pagination-status-current";
307
+ export type PaginationClass = "pagination" | PaginationPart;
308
+
309
+ // FilterSegment component classes
310
+ // Position is three separate yes/no booleans in Figma (First/Middle/Last) with
311
+ // exactly one ever set. Middle is the default, so it is the bare base class.
312
+ export type FilterSegmentPosition =
313
+ "filter-segment-first" | "filter-segment-last";
314
+ export type FilterSegmentSize = "filter-segment-md";
315
+ export type FilterSegmentClass =
316
+ | "filter-segment"
317
+ | FilterSegmentPosition
318
+ | FilterSegmentSize
319
+ | "filter-segments"
320
+ | "with-ring";
321
+
322
+ // Link component classes
323
+ // strong is the base. `link-inline` is NOT used with `.link` — it is a
324
+ // paragraph class whose anchors are styled as descendants.
325
+ export type LinkStyle =
326
+ "link-strong" | "link-quiet" | "link-monospace" | "link-critical";
327
+ export type LinkClass = "link" | LinkStyle | "link-inline";
328
+
329
+ // Divider component classes
330
+ // The three Figma types are structurally incompatible, so `-labeled` and
331
+ // `-metadata` are standalone container classes rather than modifiers — they do
332
+ // NOT take `.divider`, which is itself the simple type.
333
+ export type DividerPart =
334
+ | "divider-labeled"
335
+ | "divider-label"
336
+ | "divider-metadata"
337
+ | "divider-metadata-item"
338
+ | "divider-metadata-key"
339
+ | "divider-metadata-value"
340
+ | "divider-metadata-separator";
341
+ export type DividerClass = "divider" | DividerPart;
342
+
343
+ // LoadingIndicator component classes
344
+ // XS is the default, matching Figma's first variant — and the size Loading
345
+ // Inline embeds at every one of ITS sizes.
346
+ export type LoadingIndicatorSize =
347
+ "loading-indicator-sm" | "loading-indicator-md" | "loading-indicator-lg";
348
+ export type LoadingIndicatorClass =
349
+ | "loading-indicator"
350
+ | LoadingIndicatorSize
351
+ | "loading-indicator-dots"
352
+ | "loading-indicator-dot";
353
+
354
+ // LoadingInline component classes
355
+ export type LoadingInlineSize =
356
+ "loading-inline-sm" | "loading-inline-md" | "loading-inline-lg";
357
+ export type LoadingInlineClass = "loading-inline" | LoadingInlineSize;
358
+
359
+ // ProgressBar component classes
360
+ // Figma's variant axis is named "Has Legend" but actually swaps the COLOUR —
361
+ // both variants render a legend. Renamed here. See src/components/progress-bar.css.
362
+ export type ProgressBarScheme = "progress-bar-success";
363
+ export type ProgressBarPart =
364
+ | "progress-bar-header"
365
+ | "progress-bar-title"
366
+ | "progress-bar-value"
367
+ | "progress-bar-track"
368
+ | "progress-bar-fill"
369
+ | "progress-bar-legend"
370
+ | "progress-bar-legend-item"
371
+ | "progress-bar-legend-swatch"
372
+ | "progress-bar-legend-swatch-neutral"
373
+ | "progress-bar-legend-label";
374
+ export type ProgressBarClass =
375
+ "progress-bar" | ProgressBarScheme | ProgressBarPart;
376
+
377
+ // Step component classes
378
+ // Completed is Figma's default variant, so it is the bare base class.
379
+ export type StepState = "step-active" | "step-upcoming";
380
+ export type StepPart = "step-marker" | "step-label";
381
+ export type StepClass = "step" | StepState | StepPart;
382
+
383
+ // Stepper component classes
384
+ export type StepperPart =
385
+ | "stepper-title"
386
+ | "stepper-steps"
387
+ | "stepper-connector"
388
+ | "stepper-connector-complete";
389
+ export type StepperClass = "stepper" | StepperPart;
390
+
391
+ // Breadcrumbs component classes
392
+ // `-mono` carries TYPE ONLY and composes with `-current`, which supplies the
393
+ // colour. Separators are text characters, not icons.
394
+ export type BreadcrumbsPart =
395
+ | "breadcrumb"
396
+ | "breadcrumb-current"
397
+ | "breadcrumb-home"
398
+ | "breadcrumb-separator"
399
+ | "breadcrumb-separator-chevron"
400
+ | "breadcrumb-separator-dot";
401
+ export type BreadcrumbsClass = "breadcrumbs" | BreadcrumbsPart;
402
+
403
+ // SensitiveData component classes
404
+ export type SensitiveDataPart = "sensitive-data-value";
405
+ export type SensitiveDataClass = "sensitive-data" | SensitiveDataPart;
406
+
407
+ // DataRow component classes
408
+ export type DataRowPart =
409
+ | "data-row-field"
410
+ | "data-row-value"
411
+ /** Additive: stretches the Field Verification slot, like segment-selector-fill. */
412
+ | "data-row-status"
413
+ | "data-row-action";
414
+ export type DataRowClass = "data-row" | DataRowPart | "with-ring";
415
+
416
+ // Checkbox component classes
417
+ // The control is a native <input type="checkbox"> inside a real <label>; every
418
+ // state is native (:checked / :disabled), so there is no checked/disabled class.
419
+ export type CheckboxPart =
420
+ | "checkbox-control"
421
+ | "checkbox-input"
422
+ | "checkbox-check"
423
+ | "checkbox-label"
424
+ | "checkbox-subtitle";
425
+ export type CheckboxClass = "checkbox" | CheckboxPart | "with-ring";
426
+
427
+ // Skeleton component classes
428
+ // Skeleton component classes
429
+ // Both axes are required — neither has a default in Figma, and the dimensions
430
+ // are a 5x3 matrix rather than one box with three scales.
431
+ export type SkeletonShape =
432
+ | "skeleton-line"
433
+ | "skeleton-heading"
434
+ | "skeleton-circle"
435
+ | "skeleton-rectangle"
436
+ | "skeleton-button";
437
+ export type SkeletonSize = "skeleton-sm" | "skeleton-md" | "skeleton-lg";
438
+ export type SkeletonClass = "skeleton" | SkeletonShape | SkeletonSize;
439
+
440
+ // NavigationRail component classes
441
+ export type NavigationRailClass = "navigation-rail";
442
+
443
+ // Union of all component classes
444
+ export type ValiifyComponentClass =
445
+ | InputClass
446
+ | CardClass
447
+ | RadioSelectClass
448
+ | ButtonClass
449
+ | ChipClass
450
+ | SwitchClass
451
+ | IconClass
452
+ | IconButtonClass
453
+ | TextareaClass
454
+ | MenuItemClass
455
+ | DropdownMenuClass
456
+ | DropdownFieldClass
457
+ | AvatarClass
458
+ | PillClass
459
+ | TagClass
460
+ | TabsClass
461
+ | SegmentSelectorClass
462
+ | TooltipClass
463
+ | ModalClass
464
+ | TextButtonClass
465
+ | ToastClass
466
+ | AlertClass
467
+ | SectionMarkerClass
468
+ | FieldVerificationClass
469
+ | PaginationItemClass
470
+ | PaginationClass
471
+ | FilterSegmentClass
472
+ | LinkClass
473
+ | DividerClass
474
+ | LoadingIndicatorClass
475
+ | LoadingInlineClass
476
+ | ProgressBarClass
477
+ | StepClass
478
+ | StepperClass
479
+ | BreadcrumbsClass
480
+ | SensitiveDataClass
481
+ | DataRowClass
482
+ | CheckboxClass
483
+ | SkeletonClass
484
+ | NavigationRailClass;
485
+
486
+ // Helper type for combining classes
487
+ export type ComponentClassName = ValiifyComponentClass | string;
488
+
489
+ /**
490
+ * Component variants for programmatic use
491
+ */
492
+ export interface InputVariants {
493
+ type?: "text" | "email" | "password" | "number" | "url" | "search";
494
+ size?: "sm" | "md" | "lg";
495
+ bgVariant?: "white" | "neutral";
496
+ error?: boolean;
497
+ disabled?: boolean;
498
+ showLabel?: boolean;
499
+ showHelp?: boolean;
500
+ leftIcon?: boolean;
501
+ rightIcon?: boolean;
502
+ }
503
+
504
+ export interface CardVariants {
505
+ compact?: boolean;
506
+ bordered?: boolean;
507
+ hover?: boolean;
508
+ }
509
+
510
+ export interface RadioSelectVariants {
511
+ name: string;
512
+ checked?: boolean;
513
+ disabled?: boolean;
514
+ }
515
+
516
+ export interface ButtonVariants {
517
+ variant?: "primary" | "outline" | "empty";
518
+ size?: "sm" | "md" | "lg";
519
+ disabled?: boolean;
520
+ selected?: boolean;
521
+ }
522
+
523
+ export interface IconVariants {
524
+ size?: 10 | 11 | 12 | 13 | 14 | 15 | 16 | 18 | 20 | 22 | 24;
525
+ ring?: boolean;
526
+ }
527
+
528
+ export interface ChipVariants {
529
+ type?: "chip" | "badge" | "dot";
530
+ variant?: "warning" | "critical" | "success" | "neutral" | "primary";
531
+ size?: "sm" | "md";
532
+ /** Figma BG axis. Defaults to "yes" (filled). Ignored for type "dot". */
533
+ bg?: "yes" | "no";
534
+ withDot?: boolean;
535
+ withRing?: boolean;
536
+ }
537
+
538
+ export interface SwitchVariants {
539
+ checked?: boolean;
540
+ disabled?: boolean;
541
+ }
542
+
543
+ export interface TextareaVariants {
544
+ bgVariant?: "white" | "neutral";
545
+ error?: boolean;
546
+ disabled?: boolean;
547
+ showLabel?: boolean;
548
+ showHelp?: boolean;
549
+ showCounter?: boolean;
550
+ }
551
+
552
+ export interface MenuItemVariants {
553
+ size?: "sm" | "md" | "lg";
554
+ combined?: boolean;
555
+ selected?: boolean;
556
+ disabled?: boolean;
557
+ leftIcon?: boolean;
558
+ rightIcon?: boolean;
559
+ rightText?: boolean;
560
+ subtitle?: boolean;
561
+ avatar?: boolean;
562
+ badge?: boolean;
563
+ }
564
+
565
+ export interface TooltipVariants {
566
+ /** All parts are optional in markup; Figma models them as text properties. */
567
+ title?: boolean;
568
+ content?: boolean;
569
+ subtext?: boolean;
570
+ }
571
+
572
+ export interface TabsVariants {
573
+ type?: "underline" | "chip" | "segment";
574
+ /** sm exists for underline only. */
575
+ size?: "lg" | "sm";
576
+ /** aria-selected for a tablist, aria-checked for a radiogroup. */
577
+ active?: boolean;
578
+ disabled?: boolean;
579
+ subtitle?: boolean;
580
+ /** Reuses `.badge badge-neutral`. */
581
+ badge?: boolean;
582
+ }
583
+
584
+ export interface SegmentSelectorVariants {
585
+ /** Distribute segments equally. Not from Figma. */
586
+ fill?: boolean;
587
+ withRing?: boolean;
588
+ }
589
+
590
+ export interface TagVariants {
591
+ size?: "sm" | "md";
592
+ /** Selected — solid primary fill. */
593
+ active?: boolean;
594
+ disabled?: boolean;
595
+ withRing?: boolean;
596
+ /** Leading Avatar (`.avatar avatar-xs`). md only. */
597
+ avatar?: boolean;
598
+ /** Trailing count (`.tag-count`). md only. */
599
+ count?: boolean;
600
+ /** Trailing 5px dot (`.dot dot-warning`). Both sizes. */
601
+ statusDot?: boolean;
602
+ }
603
+
604
+ export interface PillVariants {
605
+ /** Adds the trailing chevron (Figma's Dropdown axis). */
606
+ dropdown?: boolean;
607
+ /** Menu open when dropdown is true, selected when it is not. */
608
+ active?: boolean;
609
+ disabled?: boolean;
610
+ withRing?: boolean;
611
+ }
612
+
613
+ export interface AvatarVariants {
614
+ size?: "xs" | "sm" | "md" | "lg";
615
+ disabled?: boolean;
616
+ withRing?: boolean;
617
+ }
618
+
619
+ export interface DropdownFieldVariants {
620
+ size?: "sm" | "md" | "lg";
621
+ bgVariant?: "white" | "neutral";
622
+ filled?: boolean;
623
+ error?: boolean;
624
+ disabled?: boolean;
625
+ open?: boolean;
626
+ showLabel?: boolean;
627
+ showHelp?: boolean;
628
+ leftIcon?: boolean;
629
+ avatar?: boolean;
630
+ }
@@ -0,0 +1,15 @@
1
+ /**
2
+ * Type definitions for @valiify/dashboard-ui
3
+ *
4
+ * This package is CSS-only — it ships no JavaScript runtime and no Tailwind
5
+ * plugin. These types exist purely to give editors autocomplete over the
6
+ * component class names.
7
+ *
8
+ * Usage:
9
+ * import type { ButtonClass } from '@valiify/dashboard-ui/types';
10
+ */
11
+
12
+ export * from "./components";
13
+
14
+ /** Allow `@import '@valiify/dashboard-ui'` in TS-checked CSS-in-JS setups. */
15
+ declare module "@valiify/dashboard-ui/index.css";