@hirobius/design-system 0.19.0 → 0.20.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 (144) hide show
  1. package/CONSUMING.md +9 -6
  2. package/DESIGN.md +7 -5
  3. package/README.md +14 -11
  4. package/codemods/hds-prefix.mjs +231 -0
  5. package/codemods/jsx-fold.mjs +515 -0
  6. package/codemods/not-found-pattern.mjs +71 -0
  7. package/codemods/patterns-subpath.mjs +242 -81
  8. package/codemods/patterns-subpath.names.json +41 -15
  9. package/codemods/removed-0.20.json +194 -0
  10. package/codemods/tile-grid.mjs +283 -0
  11. package/codemods/unrewritable.mjs +291 -0
  12. package/dist/chunks/DemoStateContext-Cz5TmrYu.js +32 -0
  13. package/dist/chunks/empty-state-BBqhCx0S.js +1217 -0
  14. package/dist/chunks/{form-BvNNnJ0t.js → form-COP3vK9_.js} +29 -27
  15. package/dist/contexts.js +157 -78
  16. package/dist/form.js +1 -1
  17. package/dist/hirobius-ui.js +1826 -5503
  18. package/dist/manifest.js +12 -13
  19. package/dist/patterns.js +820 -561
  20. package/dist/styles.css +1 -1
  21. package/dist/tokens.css +1 -1
  22. package/dist/tokens.js +29 -8
  23. package/dist/types/src/app/components/avatar-group.d.ts +1 -2
  24. package/dist/types/src/app/components/badge.d.ts +8 -3
  25. package/dist/types/src/app/components/blockquote.d.ts +1 -2
  26. package/dist/types/src/app/components/box-sx.d.ts +110 -13
  27. package/dist/types/src/app/components/box.d.ts +6 -3
  28. package/dist/types/src/app/components/breadcrumb.d.ts +0 -5
  29. package/dist/types/src/app/components/button.d.ts +33 -4
  30. package/dist/types/src/app/components/card.d.ts +7 -8
  31. package/dist/types/src/app/components/combobox.d.ts +47 -11
  32. package/dist/types/src/app/components/container.d.ts +2 -2
  33. package/dist/types/src/app/components/data-table-section.d.ts +1 -1
  34. package/dist/types/src/app/components/dialog.d.ts +7 -1
  35. package/dist/types/src/app/components/disclosure.d.ts +1 -5
  36. package/dist/types/src/app/components/field.d.ts +1 -2
  37. package/dist/types/src/app/components/grid.d.ts +10 -6
  38. package/dist/types/src/app/components/hds-tooltip.d.ts +12 -2
  39. package/dist/types/src/app/components/inline-code.d.ts +1 -2
  40. package/dist/types/src/app/components/input.d.ts +8 -5
  41. package/dist/types/src/app/components/kbd.d.ts +1 -2
  42. package/dist/types/src/app/components/metadata-list.d.ts +1 -2
  43. package/dist/types/src/app/components/page-header.d.ts +0 -2
  44. package/dist/types/src/app/components/popover.d.ts +8 -0
  45. package/dist/types/src/app/components/progress.d.ts +33 -6
  46. package/dist/types/src/app/components/segmented-control.d.ts +2 -26
  47. package/dist/types/src/app/components/select.d.ts +10 -1
  48. package/dist/types/src/app/components/skeleton.d.ts +2 -3
  49. package/dist/types/src/app/components/spinner.d.ts +1 -2
  50. package/dist/types/src/app/components/stack.d.ts +4 -1
  51. package/dist/types/src/app/components/stat.d.ts +1 -2
  52. package/dist/types/src/app/components/status-dot.d.ts +18 -4
  53. package/dist/types/src/app/components/status-list-item.d.ts +1 -2
  54. package/dist/types/src/app/components/surface.d.ts +2 -3
  55. package/dist/types/src/app/components/switcher.d.ts +1 -1
  56. package/dist/types/src/app/components/table.d.ts +1 -15
  57. package/dist/types/src/app/components/tag.d.ts +0 -6
  58. package/dist/types/src/app/components/text.d.ts +1 -2
  59. package/dist/types/src/app/components/textarea.d.ts +1 -2
  60. package/dist/types/src/app/components/toast.d.ts +1 -2
  61. package/dist/types/src/app/components/tooltip.d.ts +1 -1
  62. package/dist/types/src/app/context/DemoStateContext.d.ts +1 -1
  63. package/dist/types/src/app/context/RouterContext.d.ts +5 -5
  64. package/dist/types/src/app/data/manifest-types.d.ts +6 -5
  65. package/dist/types/src/app/design-system/generated-token-refs.d.ts +8 -0
  66. package/dist/types/src/app/design-system/generated-token-values.d.ts +1 -0
  67. package/dist/types/src/app/design-system/tokens.d.ts +22 -3
  68. package/dist/types/src/icons.d.ts +1 -1
  69. package/dist/types/src/index.d.ts +33 -124
  70. package/dist/types/src/patterns.d.ts +20 -25
  71. package/dist/variables.css +6 -0
  72. package/docs/CONSUMING.md +21 -13
  73. package/hirobius.tokens.json +48 -15
  74. package/llms.txt +19 -20
  75. package/package.json +18 -22
  76. package/public/hds-manifest.json +2400 -6488
  77. package/public/llms/components.txt +41 -423
  78. package/public/llms/layout.txt +4 -4
  79. package/public/llms-full.txt +67 -448
  80. package/public/llms.txt +19 -20
  81. package/src/app/data/component-api.json +1379 -3271
  82. package/dist/chunks/LanguageContext-CH_bwzCq.js +0 -83
  83. package/dist/chunks/TokenDisplayContext-evZi_214.js +0 -18
  84. package/dist/chunks/activity-feed-DIMeUJpW.js +0 -21950
  85. package/dist/types/src/app/components/activity-feed.d.ts +0 -73
  86. package/dist/types/src/app/components/app-shell.d.ts +0 -40
  87. package/dist/types/src/app/components/aspect-ratio.d.ts +0 -25
  88. package/dist/types/src/app/components/bleed.d.ts +0 -39
  89. package/dist/types/src/app/components/button-group.d.ts +0 -22
  90. package/dist/types/src/app/components/calendar.d.ts +0 -22
  91. package/dist/types/src/app/components/carousel.d.ts +0 -26
  92. package/dist/types/src/app/components/center.d.ts +0 -36
  93. package/dist/types/src/app/components/cinematic-link.d.ts +0 -18
  94. package/dist/types/src/app/components/circular-progress.d.ts +0 -28
  95. package/dist/types/src/app/components/cluster.d.ts +0 -39
  96. package/dist/types/src/app/components/command-palette.d.ts +0 -46
  97. package/dist/types/src/app/components/component-instance-matrix.d.ts +0 -27
  98. package/dist/types/src/app/components/context-menu.d.ts +0 -78
  99. package/dist/types/src/app/components/cover.d.ts +0 -43
  100. package/dist/types/src/app/components/date-input.d.ts +0 -31
  101. package/dist/types/src/app/components/date-range-input.d.ts +0 -34
  102. package/dist/types/src/app/components/date-time-input.d.ts +0 -30
  103. package/dist/types/src/app/components/doc-link-card.d.ts +0 -32
  104. package/dist/types/src/app/components/error-boundary.d.ts +0 -25
  105. package/dist/types/src/app/components/file-input.d.ts +0 -30
  106. package/dist/types/src/app/components/foundation-swatch.d.ts +0 -45
  107. package/dist/types/src/app/components/frame.d.ts +0 -38
  108. package/dist/types/src/app/components/heading-stack.d.ts +0 -52
  109. package/dist/types/src/app/components/history-card.d.ts +0 -12
  110. package/dist/types/src/app/components/hover-card.d.ts +0 -46
  111. package/dist/types/src/app/components/icon-button.d.ts +0 -22
  112. package/dist/types/src/app/components/image-lightbox.d.ts +0 -14
  113. package/dist/types/src/app/components/input-group.d.ts +0 -23
  114. package/dist/types/src/app/components/multi-selector.d.ts +0 -40
  115. package/dist/types/src/app/components/nav-group.d.ts +0 -29
  116. package/dist/types/src/app/components/nav-item.d.ts +0 -33
  117. package/dist/types/src/app/components/not-found-pattern.d.ts +0 -1
  118. package/dist/types/src/app/components/overflow-list.d.ts +0 -21
  119. package/dist/types/src/app/components/selectable-card.d.ts +0 -29
  120. package/dist/types/src/app/components/side-nav.d.ts +0 -23
  121. package/dist/types/src/app/components/sketch.d.ts +0 -19
  122. package/dist/types/src/app/components/stacked-card-rail.d.ts +0 -32
  123. package/dist/types/src/app/components/stepper-field.d.ts +0 -12
  124. package/dist/types/src/app/components/stepper.d.ts +0 -33
  125. package/dist/types/src/app/components/text-lockup.d.ts +0 -38
  126. package/dist/types/src/app/components/tile-grid.d.ts +0 -17
  127. package/dist/types/src/app/components/time-input.d.ts +0 -24
  128. package/dist/types/src/app/components/toggle-button.d.ts +0 -32
  129. package/dist/types/src/app/components/token.d.ts +0 -90
  130. package/dist/types/src/app/components/tokenUtils.d.ts +0 -38
  131. package/dist/types/src/app/components/tokenizer.d.ts +0 -24
  132. package/dist/types/src/app/components/toolbar.d.ts +0 -36
  133. package/dist/types/src/app/components/top-nav.d.ts +0 -23
  134. package/dist/types/src/app/components/tree-list.d.ts +0 -30
  135. package/dist/types/src/app/data/nav-model.d.ts +0 -39
  136. package/dist/types/src/app/hooks/useFocusVisible.d.ts +0 -9
  137. package/dist/types/src/app/layouts/CaseStudyLayout.d.ts +0 -20
  138. package/dist/types/src/app/layouts/DocLayout.d.ts +0 -14
  139. package/dist/types/src/app/layouts/EmbeddedDocLayoutContext.d.ts +0 -6
  140. package/dist/types/src/app/layouts/HdsDocsShell.d.ts +0 -72
  141. package/dist/types/src/app/layouts/HdsSystemDocLayout.d.ts +0 -14
  142. package/dist/types/src/app/lib/hds-search.d.ts +0 -45
  143. package/dist/types/src/app/lib/nav-active.d.ts +0 -16
  144. package/dist/types/src/app/lib/navLevels.d.ts +0 -4
@@ -1,73 +0,0 @@
1
- /**
2
- * ActivityFeed — chronological system event log.
3
- * @category Display
4
- * @tier pattern
5
- * @doc-exempt: internal portfolio and systems timeline pattern; no standalone component doc page
6
- *
7
- * Renders a list of activity events using white space as the sole separator.
8
- * No dividers, no borders between items. 48px gap (space.12) creates the
9
- * visual grouping between events; 16px gap inside each item structures the
10
- * content hierarchy.
11
- *
12
- * Typography mapping:
13
- * title → heading3 (24px/1.25)
14
- * description → body (16px/1.5)
15
- * timestamp → technical (12px/1.0 mono)
16
- * category → ui (14px/1.5)
17
- */
18
- import type { ReactNode } from 'react';
19
- /**
20
- * @deprecated Use `ActivityTone` instead — values are renamed to match the
21
- * fixed HDS tone vocabulary (`neutral | danger | success | warning | info`,
22
- * see docs/architecture/variant-contract.md). `'error'` remains supported
23
- * here as a back-compat alias for `'danger'`; new code should use `tone`.
24
- *
25
- * @removeIn 1.0.0 — CHANGELOG 0.13.0 already states `status`/`ActivityStatus`
26
- * go in a future major. Dropping a prop is breaking, so 1.0.0 is the first
27
- * version that can carry it.
28
- */
29
- export type ActivityStatus = 'success' | 'error' | 'warning' | 'info' | 'neutral';
30
- /** @public */
31
- export type ActivityTone = 'neutral' | 'danger' | 'success' | 'warning' | 'info';
32
- export interface ActivityEvent {
33
- id: string;
34
- title: string;
35
- description: string;
36
- timestamp: string;
37
- category: string;
38
- icon: ReactNode;
39
- /**
40
- * Semantic tone for this event's icon and category color.
41
- * `neutral | danger | success | warning | info`. Supersedes `status`.
42
- */
43
- tone?: ActivityTone;
44
- /**
45
- * @deprecated Use `tone` instead. Retained for back-compat; `'error'`
46
- * resolves to the `danger` tone.
47
- *
48
- * @removeIn 1.0.0 — paired with ActivityStatus above; both go together.
49
- */
50
- status?: ActivityStatus;
51
- action?: {
52
- label: string;
53
- onClick?: () => void;
54
- };
55
- /** Optional structured metadata rendered between description and action.
56
- * Reserved for compact metadata clusters like AgentTag (assignee,
57
- * tier, cost). Keeps description as prose; meta is for chips/tags. */
58
- meta?: ReactNode;
59
- }
60
- export interface ActivityFeedProps {
61
- events: ActivityEvent[];
62
- }
63
- declare const activityToneVariants: (props?: ({
64
- tone?: "success" | "danger" | "warning" | "info" | "neutral" | null | undefined;
65
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
66
- declare const activityAvatarVariants: (props?: import("class-variance-authority/dist/types").ClassProp | undefined) => string;
67
- /** @internal — demo placeholder data; supply your own ActivityEvent[] via the events prop. */
68
- export declare const defaultActivityEvents: ActivityEvent[];
69
- /**
70
- */
71
- export declare function ActivityFeed({ events }: ActivityFeedProps): import("react/jsx-runtime").JSX.Element;
72
- /** @internal — CVA variant helpers; compose via ActivityFeed/ActivityEvent props instead. */
73
- export { activityToneVariants, activityAvatarVariants };
@@ -1,40 +0,0 @@
1
- /**
2
- * AppShell — application layout scaffold with semantic header, sidebar, and main regions, built for dashboards and admin surfaces.
3
- * @category Layout
4
- * @tier template
5
- * @public
6
- *
7
- * Composes a full-height page frame from three optional/required regions: an
8
- * optional top `header` (spans full width), an optional left `sidebar` (fixed
9
- * width via `sidebarWidth`), and required `children` rendered in `<main>`.
10
- * Regions map to native landmark elements (`<header>`, `<aside>`, `<main>`)
11
- * so assistive tech gets banner/complementary/main roles for free.
12
- *
13
- * Usage:
14
- * <AppShell header={<TopBar />} sidebar={<NavRail />}>
15
- * <PageContent />
16
- * </AppShell>
17
- */
18
- import * as React from 'react';
19
- import { type VariantProps } from 'class-variance-authority';
20
- declare const appShellVariants: (props?: ({
21
- sidebarWidth?: "sm" | "md" | "lg" | null | undefined;
22
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
23
- type AppShellVariantProps = VariantProps<typeof appShellVariants>;
24
- /** @public */
25
- export interface AppShellProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'children'> {
26
- /** Optional top region, rendered full-width above the sidebar/main row. */
27
- header?: React.ReactNode;
28
- /** Optional left region, rendered as a fixed-width `<aside>` beside main. */
29
- sidebar?: React.ReactNode;
30
- /** Main content, rendered inside `<main>`. */
31
- children: React.ReactNode;
32
- /** Sidebar width token: sm (224px) / md (256px) / lg (288px). Defaults to 'md'. */
33
- sidebarWidth?: NonNullable<AppShellVariantProps['sidebarWidth']>;
34
- }
35
- /**
36
- * Renders a header/sidebar/main application frame, e.g. `<AppShell sidebar={<Nav />}>...</AppShell>`.
37
- */
38
- export declare const AppShell: React.ForwardRefExoticComponent<AppShellProps & React.RefAttributes<HTMLDivElement>>;
39
- /** @internal — CVA variant helper; compose via AppShell props instead. */
40
- export { appShellVariants };
@@ -1,25 +0,0 @@
1
- /**
2
- * AspectRatio — constrains its child to a fixed width:height ratio.
3
- * @category Layout
4
- * @tier primitive
5
- *
6
- * Thin token-free wrapper over Radix AspectRatio (@radix-ui/react-aspect-ratio),
7
- * which holds a responsive aspect box via the padding-bottom technique so media
8
- * (images, video, embeds, map tiles) never causes layout shift while loading.
9
- *
10
- * <AspectRatio ratio={16 / 9}>
11
- * <img src="…" alt="…" className="h-full w-full object-cover" />
12
- * </AspectRatio>
13
- */
14
- import * as React from 'react';
15
- import * as AspectRatioPrimitive from '@radix-ui/react-aspect-ratio';
16
- /** @public */
17
- export interface AspectRatioProps extends React.ComponentPropsWithoutRef<typeof AspectRatioPrimitive.Root> {
18
- /** Desired width-to-height ratio, e.g. `16 / 9`. Defaults to `1` (square). */
19
- ratio?: number;
20
- }
21
- /**
22
- * Locks its single child to the given width-to-height `ratio` so media reserves
23
- * its box up front and never causes layout shift while it loads.
24
- */
25
- export declare const AspectRatio: React.ForwardRefExoticComponent<AspectRatioProps & React.RefAttributes<HTMLDivElement>>;
@@ -1,39 +0,0 @@
1
- /**
2
- * Bleed — controlled negative-margin full-bleed within a padded container.
3
- * @category Layout
4
- * @tier primitive
5
- * @ai-intent Solves "this one child needs to visually escape its parent's
6
- * padding" (a full-width image inside a padded card, a divider that should
7
- * touch both edges) with a single tokenized negative-margin wrapper, so
8
- * agents stop hand-rolling `margin: -24px` guesses that drift from the
9
- * parent's actual padding token.
10
- * @ai-rules Reach for this named layout intent before Box/sx. amount MUST
11
- * use a semantic space step, never raw px, and MUST match the ancestor
12
- * padding it is meant to cancel out. Do NOT use Bleed to fake extra spacing
13
- * — its only job is canceling a specific known padding value on a specific
14
- * axis.
15
- *
16
- * Every Layout reference: https://every-layout.dev/layouts/the-stack/ (bleed
17
- * is the inverse of a padded Center/Container — HDS names it separately
18
- * since "every-layout" itself does not ship a dedicated Bleed recipe).
19
- */
20
- import React from 'react';
21
- type LayoutGap = 'tight' | 'normal' | 'inset' | 'spacious';
22
- type BleedAxis = 'x' | 'y' | 'both';
23
- export interface BleedProps {
24
- /** Bleed content. */
25
- children: React.ReactNode;
26
- /** Semantic space step to negate. Defaults to 'normal'. */
27
- amount?: LayoutGap;
28
- /** Which axis the negative margin applies to. Defaults to 'x'. */
29
- axis?: BleedAxis;
30
- /** Escape hatch: only use when tokenized props cannot express the required wrapper class. */
31
- className?: string;
32
- /** Escape hatch: only use for narrow layout adjustments that do not belong in the primitive API. */
33
- style?: React.CSSProperties;
34
- /** Element rendered as the outer wrapper. Defaults to 'div'. */
35
- as?: React.ElementType;
36
- }
37
- /** @public */
38
- export declare const Bleed: React.ForwardRefExoticComponent<BleedProps & React.RefAttributes<HTMLDivElement>>;
39
- export {};
@@ -1,22 +0,0 @@
1
- /**
2
- * ButtonGroup — attaches Button children into one segmented control.
3
- * @category Actions
4
- * @tier primitive
5
- * @usage Attach related Buttons into one segmented row or column that reads as a single control.
6
- * @whenNot Buttons that are unrelated, or choosing one of several views.
7
- * @useInstead SegmentedControl choosing one of several views
8
- * @useInstead Stack loosely spaced buttons
9
- */
10
- import * as React from 'react';
11
- import { type VariantProps } from 'class-variance-authority';
12
- declare const buttonGroupVariants: (props?: ({
13
- orientation?: "horizontal" | "vertical" | null | undefined;
14
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
15
- type ButtonGroupVariantProps = VariantProps<typeof buttonGroupVariants>;
16
- /** @public */
17
- export interface ButtonGroupProps extends React.HTMLAttributes<HTMLDivElement>, ButtonGroupVariantProps {
18
- }
19
- /** Groups Button (or button-like) children into a single attached segment. */
20
- export declare const ButtonGroup: React.ForwardRefExoticComponent<ButtonGroupProps & React.RefAttributes<HTMLDivElement>>;
21
- /** @internal — CVA variant helper; compose via ButtonGroup props instead. */
22
- export { buttonGroupVariants };
@@ -1,22 +0,0 @@
1
- /**
2
- * Calendar — month calendar / date picker, HDS-skinned over react-day-picker.
3
- * @category Inputs
4
- * @tier primitive
5
- * @public
6
- *
7
- * A thin token-skin over react-day-picker's DayPicker (ADR-020). Passes through
8
- * every DayPicker prop — `mode` ('single' | 'range' | 'multiple'), `selected`,
9
- * `onSelect`, `disabled`, `month`, min/max, locale — and applies the HDS role
10
- * tokens via `classNames` so the grid matches the rest of the system. Correct
11
- * grid ARIA and keyboard navigation come from the underlying library.
12
- *
13
- * <Calendar mode="single" selected={date} onSelect={setDate} />
14
- */
15
- import * as React from 'react';
16
- import { DayPicker } from 'react-day-picker';
17
- /** @public */
18
- export type CalendarProps = React.ComponentProps<typeof DayPicker>;
19
- /**
20
- * Renders an accessible month grid; compose it inside a Popover for the date inputs.
21
- */
22
- export declare function Calendar({ className, classNames, showOutsideDays, ...props }: CalendarProps): import("react/jsx-runtime").JSX.Element;
@@ -1,26 +0,0 @@
1
- /**
2
- * Carousel — a horizontally-scrollable, scroll-snap track of slides with
3
- * Prev/Next affordances, implemented natively on top of CSS scroll-snap.
4
- * @category Display
5
- * @tier pattern
6
- * @public
7
- */
8
- import * as React from 'react';
9
- declare const carouselControlVariants: (props?: ({
10
- variant?: "next" | "prev" | null | undefined;
11
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
12
- /** @public */
13
- export interface CarouselProps extends React.HTMLAttributes<HTMLDivElement> {
14
- /** Slides rendered inside the scroll-snap track. */
15
- children: React.ReactNode;
16
- /** Accessible name for the carousel region. Defaults to 'Carousel'. */
17
- ariaLabel?: string;
18
- /** Show the Prev/Next scroll affordance buttons. Defaults to true. */
19
- showControls?: boolean;
20
- }
21
- /**
22
- * Renders children as a snap-scrolling track with Prev/Next scroll buttons.
23
- */
24
- export declare const Carousel: React.ForwardRefExoticComponent<CarouselProps & React.RefAttributes<HTMLElement>>;
25
- /** @internal — CVA variant helper; compose via Carousel instead. */
26
- export { carouselControlVariants };
@@ -1,36 +0,0 @@
1
- /**
2
- * Center — max-width column, auto-centered horizontally.
3
- * @category Layout
4
- * @tier primitive
5
- * @ai-intent Solves the "centered prose/content column" problem — a
6
- * max-width box with auto horizontal margins and, optionally, matching
7
- * horizontal gutters — so agents stop hand-rolling `marginInline: auto` plus
8
- * an ad hoc max-width value.
9
- * @ai-rules Reach for this named layout intent before Box/sx. maxWidth MUST
10
- * use the semantic width scale ('content' | 'max'), never a raw px value.
11
- * gutter, when set, MUST use a semantic space step, never raw px. Do NOT use
12
- * Center for full-bleed page shells — use Container. Do NOT use Center when
13
- * you need the deprecated Container padding prop — gutter replaces it.
14
- *
15
- * Every Layout reference: https://every-layout.dev/layouts/center/
16
- */
17
- import React from 'react';
18
- type CenterMaxWidth = 'content' | 'max';
19
- type LayoutGap = 'tight' | 'normal' | 'inset' | 'spacious';
20
- export interface CenterProps {
21
- /** Center content. */
22
- children: React.ReactNode;
23
- /** Max width: 'content' (760px prose) | 'max' (1200px full layouts). Defaults to 'content'. */
24
- maxWidth?: CenterMaxWidth;
25
- /** Optional matching horizontal gutter (padding-inline) from the semantic space scale. */
26
- gutter?: LayoutGap;
27
- /** Escape hatch: only use when tokenized props cannot express the required wrapper class. */
28
- className?: string;
29
- /** Escape hatch: only use for narrow layout adjustments that do not belong in the primitive API. */
30
- style?: React.CSSProperties;
31
- /** Element rendered as the outer wrapper. Defaults to 'div'. */
32
- as?: React.ElementType;
33
- }
34
- /** @public */
35
- export declare const Center: React.ForwardRefExoticComponent<CenterProps & React.RefAttributes<HTMLDivElement>>;
36
- export {};
@@ -1,18 +0,0 @@
1
- /**
2
- * CinematicLink - cinematic editorial link treatment for portfolio surfaces.
3
- * @category Branding
4
- * @tier primitive
5
- */
6
- import React from 'react';
7
- export interface CinematicLinkProps extends Omit<React.AnchorHTMLAttributes<HTMLAnchorElement>, 'children'> {
8
- href: string;
9
- children: string;
10
- }
11
- /**
12
- * CinematicLink - cinematic editorial link treatment for portfolio surfaces.
13
- *
14
- * @public
15
- * @deprecated CinematicLink is an HDS docs/lab internal (editorial link treatment for portfolio/case-study specimen surfaces), not a consumer-facing HDS surface. It will be retiered to `utility` (dropped from the published barrel) at the named major.
16
- * @removeIn 1.0.0
17
- */
18
- export declare function CinematicLink({ href, children, style, className, ...rest }: CinematicLinkProps): import("react/jsx-runtime").JSX.Element;
@@ -1,28 +0,0 @@
1
- /**
2
- * CircularProgress — an SVG ring showing determinate or indeterminate progress.
3
- * @category Feedback
4
- * @tier primitive
5
- */
6
- import * as React from 'react';
7
- import { type VariantProps } from 'class-variance-authority';
8
- declare const circularProgressVariants: (props?: ({
9
- tone?: "success" | "danger" | "warning" | "info" | "neutral" | null | undefined;
10
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
11
- type CircularProgressVariantProps = VariantProps<typeof circularProgressVariants>;
12
- /** @public */
13
- export interface CircularProgressProps extends React.HTMLAttributes<HTMLSpanElement>, CircularProgressVariantProps {
14
- /** Current value. Ignored (and the ring animates) when `indeterminate`. */
15
- value?: number;
16
- /** Upper bound for `value`. Defaults to 100. */
17
- max?: number;
18
- /** Ring diameter preset. Defaults to `md`. */
19
- size?: 'sm' | 'md' | 'lg';
20
- /** Show a continuous spinner instead of a measured arc. */
21
- indeterminate?: boolean;
22
- /** Accessible name for the progress indicator. */
23
- label?: string;
24
- }
25
- /** A circular progress ring; pass `value`/`max` or set `indeterminate`. */
26
- export declare const CircularProgress: React.ForwardRefExoticComponent<CircularProgressProps & React.RefAttributes<HTMLSpanElement>>;
27
- /** @internal — CVA variant helper; compose via CircularProgress props instead. */
28
- export { circularProgressVariants };
@@ -1,39 +0,0 @@
1
- /**
2
- * Cluster — wrapping horizontal group with even gaps.
3
- * @category Layout
4
- * @tier primitive
5
- * @ai-intent Solves the "row of same-ish things that wraps gracefully" problem
6
- * (tag rows, button groups, chip lists, filter pills) with a single flex-wrap
7
- * wrapper and a tokenized gap in both axes, so agents stop hand-rolling
8
- * `flexWrap` + `gap` + alignment combinations inline.
9
- * @ai-rules Reach for this named layout intent before Box/sx. Use Cluster for
10
- * horizontal groups that should wrap as a unit. Spacing MUST use semantic
11
- * steps, never raw px. Do NOT use Cluster for a strict single-line row — use
12
- * Stack with `direction="row"` when wrapping is never desired. Do NOT use
13
- * Cluster for two-dimensional grid layouts — use Grid.
14
- *
15
- * Every Layout reference: https://every-layout.dev/layouts/cluster/
16
- */
17
- import React from 'react';
18
- type LayoutGap = 'tight' | 'normal' | 'inset' | 'spacious';
19
- type ClusterAlign = 'start' | 'center' | 'end' | 'stretch';
20
- type ClusterJustify = 'start' | 'center' | 'end' | 'space-between';
21
- export interface ClusterProps {
22
- /** Cluster content — items that wrap as a unit. */
23
- children: React.ReactNode;
24
- /** Gap token applied to both axes (row and column). Defaults to 'tight'. */
25
- gap?: LayoutGap;
26
- /** Cross-axis alignment of items within a wrapped row. Defaults to 'center'. */
27
- align?: ClusterAlign;
28
- /** Main-axis distribution. Defaults to 'start'. */
29
- justify?: ClusterJustify;
30
- /** Escape hatch: only use when tokenized props cannot express the required wrapper class. */
31
- className?: string;
32
- /** Escape hatch: only use for narrow layout adjustments that do not belong in the primitive API. */
33
- style?: React.CSSProperties;
34
- /** Element rendered as the outer wrapper. Defaults to 'div'. */
35
- as?: React.ElementType;
36
- }
37
- /** @public */
38
- export declare const Cluster: React.ForwardRefExoticComponent<ClusterProps & React.RefAttributes<HTMLDivElement>>;
39
- export {};
@@ -1,46 +0,0 @@
1
- /**
2
- * CommandPalette — Cmd-K / Ctrl-K fuzzy-search over the HDS manifest.
3
- * @category Overlays
4
- * @tier primitive
5
- * @public
6
- *
7
- * Built on Dialog (8s-7 / Radix) with a custom listbox + input. NO new
8
- * npm deps — search is a hand-rolled subsequence + token-Levenshtein scorer
9
- * (think micro-fzf). Indexes four corpora from `virtual:hds-manifest`:
10
- *
11
- * 1. componentSpecs — non-hidden, non-docExempt entries (primitive / pattern / template)
12
- * 2. utilities — non-hidden entries (utility tier)
13
- * 3. role tokens — `role.*` entries from manifest.tokens.role
14
- * 4. section anchors — curated /hds foundation + tokens pages
15
- *
16
- * Each row carries a tier chip + brief description. Enter (or click)
17
- * navigates via React Router; Esc closes. ↑/↓ wraps. Cmd-K / Ctrl-K
18
- * toggles open from anywhere in the doc shell.
19
- *
20
- * Result rows sanitize free-text: HMAC-style tokens (long hex / signed
21
- * URL fragments that may leak from upstream description fields) are
22
- * stripped before render.
23
- */
24
- import * as React from 'react';
25
- declare const cmdkRowVariants: (props?: ({
26
- active?: boolean | null | undefined;
27
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
28
- declare const cmdkKindBadgeVariants: (props?: ({
29
- active?: boolean | null | undefined;
30
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
31
- declare const cmdkDescriptionVariants: (props?: ({
32
- active?: boolean | null | undefined;
33
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
34
- export interface CommandPaletteProps {
35
- /** Optional className for the trigger button. */
36
- className?: string;
37
- }
38
- /**
39
- * Mountable trigger + dialog. Drop into header slot; component manages its
40
- * own open state and Cmd-K / Ctrl-K global keybinding.
41
- */
42
- export declare const CommandPalette: React.ForwardRefExoticComponent<CommandPaletteProps & React.RefAttributes<HTMLInputElement>> & {
43
- displayName: string;
44
- };
45
- /** @internal — CVA variant helpers; compose via CommandPalette instead. */
46
- export { cmdkRowVariants, cmdkKindBadgeVariants, cmdkDescriptionVariants };
@@ -1,27 +0,0 @@
1
- /**
2
- * ComponentInstanceMatrix — responsive specimen matrix for variant and state parity.
3
- *
4
- * @category Utilities
5
- * @tier primitive
6
- * @doc-exempt: specimen matrix helper used by docs pages, not a consumer-facing HDS surface.
7
- */
8
- import React from 'react';
9
- /**
10
- * ComponentInstanceMatrix — responsive specimen matrix for variant and state parity.
11
- *
12
- * @public
13
- * @deprecated ComponentInstanceMatrix is an HDS docs/lab internal (specimen matrix helper for the component doc pages), not a consumer-facing HDS surface. It will be retiered to `utility` (dropped from the published barrel) at the named major.
14
- * @removeIn 1.0.0
15
- */
16
- export declare function ComponentInstanceMatrix({ componentName, dimensionX, dimensionY, title, isMobile: _isMobile, rowLabelWidth: _rowLabelWidth, rowLabelTone, freezeRowState, renderInstance, }: {
17
- componentName: string;
18
- dimensionX: string;
19
- dimensionY: string;
20
- title?: string;
21
- isMobile: boolean;
22
- rowLabelWidth?: number;
23
- rowLabelTone?: 'primary' | 'secondary';
24
- /** Wrap each row's rendered instance in FreezeState so the visual state is frozen. */
25
- freezeRowState?: boolean;
26
- renderInstance: (rowKey: string, columnKey: string) => React.ReactNode;
27
- }): import("react/jsx-runtime").JSX.Element | null;
@@ -1,78 +0,0 @@
1
- /**
2
- * ContextMenu — right-click context menu on Radix ContextMenu.
3
- * @category Overlays
4
- * @tier primitive
5
- * @usage Offer actions for an item on right-click, or the equivalent keyboard gesture.
6
- * @whenNot The only way to reach an action, or actions from a visible trigger.
7
- * @useInstead Menu actions from a visible trigger
8
- * @slot trigger The area that opens the menu on right-click (ContextMenu.Trigger).
9
- * @slot content The popup holding the items (ContextMenu.Content).
10
- * @keyboard ArrowDown/ArrowUp Moves the highlight and stops at the first and last item.
11
- * @keyboard End Jumps to the last item.
12
- * @keyboard Character Highlights the next item that starts with the typed letter.
13
- * @keyboard Enter Selects the highlighted item and closes the menu.
14
- * @keyboard Escape Closes the menu without leaving focus inside the removed content.
15
- * @keyboard Tab Does not leave the open menu.
16
- * @doc-exempt: no Overlays doc page yet — add demo when the overlays page is created
17
- *
18
- * Radix ContextMenu (@radix-ui/react-context-menu) themed with the same overlay
19
- * role tokens as Menu, so the dropdown and the right-click menu are visually
20
- * identical. Provides roving focus, type-ahead, checkbox/radio items, submenus,
21
- * cursor-anchored positioning, and portal mounting out of the box.
22
- *
23
- * <ContextMenu>
24
- * <ContextMenu.Trigger>Right-click me</ContextMenu.Trigger>
25
- * <ContextMenu.Content>
26
- * <ContextMenu.Item onSelect={…}>Cut</ContextMenu.Item>
27
- * <ContextMenu.Separator />
28
- * <ContextMenu.Item disabled>Paste</ContextMenu.Item>
29
- * </ContextMenu.Content>
30
- * </ContextMenu>
31
- */
32
- import * as React from 'react';
33
- import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
34
- declare const ContextMenuTrigger: React.ForwardRefExoticComponent<ContextMenuPrimitive.ContextMenuTriggerProps & React.RefAttributes<HTMLSpanElement>>;
35
- declare const ContextMenuGroup: React.ForwardRefExoticComponent<ContextMenuPrimitive.ContextMenuGroupProps & React.RefAttributes<HTMLDivElement>>;
36
- declare const ContextMenuRadioGroup: React.ForwardRefExoticComponent<ContextMenuPrimitive.ContextMenuRadioGroupProps & React.RefAttributes<HTMLDivElement>>;
37
- declare const ContextMenuSub: React.FC<ContextMenuPrimitive.ContextMenuSubProps>;
38
- declare const ContextMenuContent: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
39
- /**
40
- * Element to portal into. Defaults to the nearest `data-hds` scope, so the
41
- * overlay inherits its theme; pass `null` to use `document.body`.
42
- */
43
- container?: HTMLElement | null;
44
- } & React.RefAttributes<HTMLDivElement>>;
45
- declare const ContextMenuItem: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
46
- declare const ContextMenuCheckboxItem: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuCheckboxItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
47
- declare const ContextMenuRadioItem: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuRadioItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
48
- declare const ContextMenuLabel: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuLabelProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
49
- declare const ContextMenuSeparator: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
50
- declare const ContextMenuSubTrigger: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuSubTriggerProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
51
- declare const ContextMenuSubContent: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuSubContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
52
- /**
53
- * Element to portal into. Defaults to the nearest `data-hds` scope, so the
54
- * overlay inherits its theme; pass `null` to use `document.body`.
55
- */
56
- container?: HTMLElement | null;
57
- } & React.RefAttributes<HTMLDivElement>>;
58
- interface ContextMenuComponent extends React.FC<React.ComponentProps<typeof ContextMenuPrimitive.Root>> {
59
- Trigger: typeof ContextMenuTrigger;
60
- Content: typeof ContextMenuContent;
61
- Item: typeof ContextMenuItem;
62
- CheckboxItem: typeof ContextMenuCheckboxItem;
63
- RadioGroup: typeof ContextMenuRadioGroup;
64
- RadioItem: typeof ContextMenuRadioItem;
65
- Label: typeof ContextMenuLabel;
66
- Separator: typeof ContextMenuSeparator;
67
- Group: typeof ContextMenuGroup;
68
- Sub: typeof ContextMenuSub;
69
- SubTrigger: typeof ContextMenuSubTrigger;
70
- SubContent: typeof ContextMenuSubContent;
71
- }
72
- /**
73
- * ContextMenu root + parts. Wrap the right-clickable area in
74
- * `ContextMenu.Trigger`. Controlled via `onOpenChange`.
75
- * @public
76
- */
77
- export declare const ContextMenu: ContextMenuComponent;
78
- export {};
@@ -1,43 +0,0 @@
1
- /**
2
- * Cover — vertical shell with an auto-centered main region.
3
- * @category Layout
4
- * @tier primitive
5
- * @ai-intent Solves the "full-height section with an optional header, a
6
- * centered hero/main region that absorbs the remaining space, and an
7
- * optional footer" problem via the flex auto-margin centering technique, so
8
- * agents stop hand-rolling `position: absolute` centering or a fixed 50vh
9
- * split.
10
- * @ai-rules Reach for this named layout intent before Box/sx. gap MUST use a
11
- * semantic space step, never raw px. minHeight is a CSS length dimension
12
- * (not spacing) — defaults to '100svh' (small viewport height, safe against
13
- * mobile browser chrome). Pass minHeight="100vh" explicitly if you need the
14
- * classic viewport unit for a target that predates svh support. Do NOT use
15
- * Cover for ordinary page content flow — use Stack.
16
- *
17
- * Every Layout reference: https://every-layout.dev/layouts/cover/
18
- */
19
- import React from 'react';
20
- type LayoutGap = 'tight' | 'normal' | 'inset' | 'spacious';
21
- export interface CoverProps {
22
- /** The centered main region — takes the remaining space via auto margins. Also available as `centerSlot`. */
23
- children?: React.ReactNode;
24
- /** Alias for `children` — the centered main region. If both are set, `centerSlot` wins. */
25
- centerSlot?: React.ReactNode;
26
- /** Optional content pinned to the top. */
27
- header?: React.ReactNode;
28
- /** Optional content pinned to the bottom. */
29
- footer?: React.ReactNode;
30
- /** Minimum block size of the cover (CSS length). Defaults to '100svh'. */
31
- minHeight?: string;
32
- /** Gap enforced between header/main/footer, in addition to the auto-margin centering. Defaults to 'normal'. */
33
- gap?: LayoutGap;
34
- /** Escape hatch: only use when tokenized props cannot express the required wrapper class. */
35
- className?: string;
36
- /** Escape hatch: only use for narrow layout adjustments that do not belong in the primitive API. */
37
- style?: React.CSSProperties;
38
- /** Element rendered as the outer wrapper. Defaults to 'div'. */
39
- as?: React.ElementType;
40
- }
41
- /** @public */
42
- export declare const Cover: React.ForwardRefExoticComponent<CoverProps & React.RefAttributes<HTMLDivElement>>;
43
- export {};
@@ -1,31 +0,0 @@
1
- /**
2
- * DateInput — single-date text field with a calendar popover picker, so
3
- * typing a date and picking one from a grid read as one input rather than
4
- * two disconnected controls glued together by a consuming app.
5
- * @category Inputs
6
- * @tier pattern
7
- * @public
8
- *
9
- * Composes the HDS Popover (trigger = calendar icon button) with Calendar
10
- * for the grid, and date-fns for parse/format of the free-typed text. The
11
- * text field and the picker stay in sync in both directions.
12
- *
13
- * <DateInput value={date} onChange={setDate} />
14
- */
15
- import * as React from 'react';
16
- /** @public */
17
- export interface DateInputProps {
18
- /** Currently selected date, or undefined when empty. */
19
- value?: Date;
20
- /** Fired with the next date, or undefined when the field is cleared/invalid. */
21
- onChange?: (date: Date | undefined) => void;
22
- /** date-fns format string used to display and parse the text value. */
23
- displayFormat?: string;
24
- /** Placeholder shown when the field is empty; defaults to the display format. */
25
- placeholder?: string;
26
- disabled?: boolean;
27
- id?: string;
28
- 'aria-label'?: string;
29
- }
30
- /** Text field + calendar popover for picking a single date. */
31
- export declare const DateInput: React.ForwardRefExoticComponent<DateInputProps & React.RefAttributes<HTMLInputElement>>;
@@ -1,34 +0,0 @@
1
- /**
2
- * DateRangeInput — date-range field composing the existing Popover with
3
- * Calendar in range mode, so picking a start/end date reads as one overlay
4
- * pattern with Combobox and Menu rather than a bespoke widget.
5
- * @category Inputs
6
- * @tier pattern
7
- * @public
8
- *
9
- * No new primitive — built entirely on the HDS Popover + Calendar. The
10
- * trigger reads like a secondary input, showing a placeholder or the
11
- * formatted `from – to` range; the content is a two-month range calendar.
12
- *
13
- * <DateRangeInput value={range} onChange={setRange} />
14
- */
15
- import * as React from 'react';
16
- import type { DateRange } from 'react-day-picker';
17
- /** @public */
18
- export interface DateRangeInputProps {
19
- /** Currently selected range. */
20
- value?: DateRange;
21
- /** Fired with the next range whenever the calendar selection changes. */
22
- onChange?: (range: DateRange | undefined) => void;
23
- /** date-fns format string used to render the selected range on the trigger. */
24
- displayFormat?: string;
25
- /** Trigger text when nothing is selected. */
26
- placeholder?: string;
27
- disabled?: boolean;
28
- /** Number of months rendered side by side in the calendar. */
29
- numberOfMonths?: number;
30
- id?: string;
31
- 'aria-label'?: string;
32
- }
33
- /** @public */
34
- export declare const DateRangeInput: React.ForwardRefExoticComponent<DateRangeInputProps & React.RefAttributes<HTMLButtonElement>>;