import * as React from 'react'; import React__default, { PropsWithChildren, ReactElement, ReactNode, ChangeEvent, SVGProps, ChangeEventHandler, InputHTMLAttributes, TextareaHTMLAttributes, Component, ErrorInfo, JSX } from 'react'; import * as zustand_traditional from 'zustand/traditional'; import * as zustand from 'zustand'; import { UseBoundStore, StoreApi } from 'zustand'; import * as react_jsx_runtime from 'react/jsx-runtime'; import * as zustand_middleware from 'zustand/middleware'; import { DropzoneOptions } from 'react-dropzone'; import { LanguageFn } from 'highlight.js'; type Variant$1 = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'body' | 'subtitle' | 'button'; type WeightAlias = 'regular' | 'medium' | 'semibold' | 'bold'; interface FluidSize { min: string; max: string; vwFrom: number; vwTo: number; } type Breakpoint = 'xs' | 'sm' | 'md' | 'lg' | 'xl'; type ThemeMode = 'light' | 'dark'; type Density = 'tight' | 'standard' | 'comfortable'; interface Theme { colors: Record; /** Human-readable names for color tokens */ colorNames: Record; /** Returns a CSS length for the given number of spacing units */ spacing: (units: number) => string; /** Base unit used by the spacing helper */ spacingUnit: string; /** Returns a CSS length for border radii using a relative base */ radius: (units: number) => string; /** Base unit used by the radius helper */ radiusUnit: string; /** Returns a CSS length for strokes/borders using a relative base */ stroke: (units: number) => string; /** Base unit used by the stroke helper */ strokeUnit: string; /** * Motion and animation tokens: common durations, easing curves, * and a small set of tuned values for reusable interactions. */ motion: { /** Canonical durations to keep motion consistent across components */ duration: { /** e.g. micro feedback, tap highlights */ xshort: string; /** e.g. tooltip fade, small nudge */ short: string; /** e.g. color or small position transitions */ medium: string; /** e.g. base UI enters/exits (snackbars, toasts) */ base: string; /** e.g. larger layout shifts or content settles */ long: string; /** e.g. exaggerated distances or elastic UI sweeps */ xlong: string; }; /** Named cubic-bezier curves for consistent feel */ easing: { /** Crisp ease-out; good general-purpose settle */ standard: string; /** Slightly punchier ease for emphasized motion */ emphasized: string; /** Gentle overshoot for micro pulses */ overshoot: string; /** Pass-throughs for convenience */ linear: string; ease: string; }; /** Default hover interaction tokens */ hover: { duration: string; easing: string; }; /** Tuned values for tab/underline-style follow animations */ underline: { stretch: { baseMs: number; distanceCoef: number; minMs: number; maxMs: number; }; settle: { baseMs: number; distanceCoef: number; minMs: number; maxMs: number; }; }; }; breakpoints: Record; /** Fixed sizes per breakpoint for semantic text variants */ typography: Record>; /** Optional fluid sizes compiled to clamp(); falls back to breakpoint sizes */ typographyFluid?: Partial>; /** Optional unitless line-height per variant */ lineHeight?: Partial>; /** Optional letter-spacing per variant (px/em) */ letterSpacing?: Partial>; /** Optional allowed weights per variant (either list or min/max range) */ weights?: Partial>; /** Aliases for common weights */ weightAliases?: Partial>; /** * Optional per-family defaults for line-height and letter-spacing. * Use either a base value (applies to all variants mapped to that family) * or a per-variant map for fine control. */ typographyFamilies?: Partial>; letterSpacing?: string | number | Partial>; }>>; fonts: { heading: string; body: string; mono: string; button: string; }; /** Default optical sizing behavior for variable fonts */ fontOpticalSizing?: 'auto' | 'none'; } interface ThemeStore { mode: ThemeMode; theme: Theme; /** Cumulative user patches; re-applied on top of the base on every mode change */ overlay: Partial; density: Density; setMode: (m: ThemeMode) => void; toggleMode: () => void; setTheme: (patch: Partial) => void; /** Clear all setTheme customisations and return to the built-in theme */ resetTheme: () => void; setDensity: (d: Density) => void; } declare const useTheme: zustand_traditional.UseBoundStoreWithEqualityFn>; interface Presettable { /** One or many style-preset names registered via `definePreset()` */ preset?: string | string[]; } /** Numeric values are mapped via theme.spacing(n); strings pass through. */ type Space = number | string; /** * A value that can vary by breakpoint. Either a single value applied at all * widths, or a partial breakpoint map (`{ xs, sm, md, lg, xl }`) whose entries * each apply from that breakpoint's `min-width` upward (mobile-first). * * Breakpoint maps compile to CSS `@media (min-width: …)` rules **inside the * `styled()` template** (via `utils/responsive`) — there is no JS resolution, * no `` dependency, and no first-paint reflow, so a responsive layout * is correct on the server's first paint. Keep breakpoint maps to enumerable * values; binding one to continuously-varying state (e.g. a slider) mints a * permanent CSS rule per value (see the engine's rule-cardinality tripwire). */ type Responsive = T | Partial>; /** Common spacing props shared across layout components. */ interface SpacingProps { /** Inter-child spacing as units or CSS length. */ gap?: Space; /** Container padding as units or CSS length. */ pad?: Space; /** * Zeros all layout spacing (pad, gap, and spacing-margins) where supported and * cascades to spacing-aware descendants. Does not touch control insets, * structural geometry, border-radius, glyph sizes, or alignment. `compact={false}` * opts a subtree back out of an inherited compact. */ compact?: boolean; /** Density override for the spacing scale; defaults from nearest Surface. */ density?: 'tight' | 'standard' | 'comfortable'; } /** Sx prop: inline CSS with support for CSS custom properties (e.g. --valet-*) */ type Sx = React__default.CSSProperties & { [key: `--${string}`]: string | number; }; /** * Semantic colour intent shared by every intent-driven component * (Button, IconButton, Chip, Panel, AppBar). The seven named tokens map to * theme colours; the `(string & {})` member keeps the union open so a caller * can pass an arbitrary theme-token name or CSS colour while preserving * autocomplete on the canonical names. * * Canonical single source of truth (API-TYPES S12): the five components above * each declared this union verbatim — a copy-paste that drifts on edit. They * now alias this type instead. */ type Intent = 'default' | 'primary' | 'secondary' | 'success' | 'warning' | 'error' | 'info' | (string & {}); /** * Unified selection vocabulary shared by collection components (Table, List, * Tree) — API-TYPES S11, ruling Q11(a)/R12. Before this, each collection spoke * a different dialect: Table used `selectable: 'single' | 'multi'` with a * row-array `onSelectionChange`, List used a single `selected: T | null` + a * `getKey` identity, and Tree used `selected: string` ids. The three now share * one keyed vocabulary so the same name means the same thing everywhere. * * `K` is the **selection unit** each component exposes: * - Table — `K = T` (the row type; identity is keyed internally by `getItemKey`). * - List — `K = T` (the item type; selection is by reference, `getItemKey` standardizes reorder identity). * - Tree — `K = string` (the node id). * * Components adopt the subset they support and re-document the generic in their * own prop types. `selected`/`defaultSelected` are always **arrays** so the * single- and multiple-selection shapes share one type; a single-selection * component simply ignores all but the last entry. The pre-S11 per-component * names (Table's `selectable`/`rowKey`, etc.) were removed at 1.0; only this * canonical vocabulary remains. */ interface SelectionProps { /** * How many items may be selected at once. * - `'none'` — selection is disabled (the default for components that gate it). * - `'single'` — at most one item is selected. * - `'multiple'` — any number of items may be selected. * * Canonical replacement for the former per-component flags (e.g. Table's * removed `selectable`). */ selectionMode?: 'none' | 'single' | 'multiple'; /** Controlled selection as an array of selection units (`K`). */ selected?: K[]; /** Uncontrolled initial selection as an array of selection units (`K`). */ defaultSelected?: K[]; /** * Fired when the selection changes (user interaction only — never on mount * or on a derived prune that merely keeps the array in sync). Receives the * full next selection as an array of selection units. */ onSelectionChange?: (selected: K[]) => void; /** * Stable identity for each item — a property name or a function of the item * and its index. Canonical, cross-component replacement for Table's `rowKey` * and List's `getKey`. When omitted, components fall back to reference/index * identity exactly as before. */ getItemKey?: keyof K | ((item: K, index: number) => string | number); } /** * Base props shared by value field components (TextField, Checkbox, Select, Slider, Switch, etc.). * Attach these to ensure consistent behavior and documentation across fields. * * Note: `name` is optional here. Components that require a name can refine their * prop type with `& { name: string }` to enforce it at the component level. */ interface FieldBaseProps extends Presettable { /** * Field identifier used for FormControl binding and forwarded to the underlying control * when applicable. Components can require `name` locally if they depend on it. */ name?: string; /** Visual label rendered by the component or its wrapper. Accepts string or node. */ label?: React__default.ReactNode; /** Supplemental hint or validation content typically rendered under the control. */ helperText?: React__default.ReactNode; /** Marks the field invalid; components may adjust visuals and helper text color. */ error?: boolean; /** Stretches the field wrapper to occupy the full available width. */ fullWidth?: boolean; /** Inline styles (with CSS var support). */ sx?: Sx; } type AvatarSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl'; type AvatarVariant = 'plain' | 'outline'; interface AvatarProps extends Omit, 'style'>, Presettable { /** Image URL override. */ src?: string; /** Email used for Gravatar lookup when src missing. */ email?: string; /** Display name used to derive initials for offline fallback. */ name?: string; /** Size token controlling relative dimensions. */ size?: AvatarSize; /** Visual style variant. */ variant?: AvatarVariant; /** * Opt in to a third-party Gravatar lookup from `email` when no `src` * is given. Default `false`: src-less avatars render an offline * initials/placeholder fallback and make **no network request**. * * Privacy: enabling this discloses a reversible md5 of the email plus * the viewer's IP/UA to Automattic. Requires a non-empty `email`. */ gravatar?: boolean; /** Gravatar default-image style (`d` param) when `gravatar` is enabled. */ gravatarDefault?: string; /** * Force the offline fallback even when `gravatar` + `email` would * otherwise resolve a network avatar. Legacy escape hatch; with * `gravatar` defaulting to `false` the fallback is already the default. */ preferFallback?: boolean; /** Offline fallback strategy when showing a non-network avatar. */ fallback?: 'initials' | 'placeholder'; /** Inline styles (with CSS var support) */ sx?: Sx; } declare const Avatar: React__default.FC; type IconSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl'; interface IconProps extends Omit, 'style'>, Presettable { /** Iconify icon name, e.g. "mdi:home". */ icon?: string; /** * Custom SVG: * • **string** – passed through the {@link parseSvgString} allowlist * parser. Accepted forms: bare path `d`-data (`"M12 2L2 22h20z"`, * wrapped in a 24×24 viewBox) or ``-only markup, optionally * inside one `` wrapper. The result is rendered as real React * ``/`` elements — never via `innerHTML`. Anything outside * that grammar renders nothing and dev-warns. * • **ReactElement** – a full `` element you already trust. * * **BREAKING (Q6):** full-SVG strings (`` containing anything * other than ``, or any string with entities/comments/scripts) no * longer render here — they are an XSS vector through the old * `dangerouslySetInnerHTML` sink. For trusted full-SVG markup, pass a * ReactElement or use {@link IconProps.dangerouslySetSvg}. */ svg?: string | ReactElement>; /** * Escape hatch for **trusted** raw SVG markup. Reproduces the pre-0.35 * `svg` string behavior exactly: the markup is injected verbatim via * `dangerouslySetInnerHTML`, so it can execute scripts/event handlers and * load remote references. The name is the warning — only ever pass markup * you fully control (never model output or user input). For untrusted or * agent-generated markup use {@link IconProps.svg}, which is parsed. */ dangerouslySetSvg?: string; /** Icon size token or explicit CSS size. */ size?: IconSize | number | string; /** Explicit colour override; otherwise inherits `currentColor`. */ color?: string | undefined; /** Inline styles (with CSS var support) */ sx?: Sx; } declare const Icon: React__default.FC>; type Variant = Variant$1; interface TypographyOwnProps extends Presettable { variant?: Variant; italic?: boolean; weight?: number | WeightAlias; tracking?: number | 'tight' | 'normal' | 'loose'; leading?: number | 'tight' | 'normal' | 'loose'; optical?: 'auto' | number | 'none'; fluid?: boolean; centered?: boolean; noSelect?: boolean; fontSize?: string; scale?: number; autoSize?: boolean; color?: string; /** Choose a theme font family */ family?: 'heading' | 'body' | 'mono' | 'button'; fontFamily?: string; /** Control whitespace handling for multi-line/code text */ whitespace?: 'normal' | 'pre' | 'pre-wrap' | 'pre-line'; /** Inline styles (with CSS var support) */ sx?: Sx; } declare const Typography: PolymorphicComponent<"span", TypographyOwnProps>; interface ModalProps extends Omit, 'style' | 'title'>, Presettable { /** Controlled visiblity */ open?: boolean; /** Default for uncontrolled */ defaultOpen?: boolean; /** Callback fired when the user requests to close (backdrop / ESC) */ onClose?: () => void; /** Dialog semantics (default) or alertdialog semantics */ variant?: 'dialog' | 'alert'; /** Dialog title – used for aria-labelledby when provided */ title?: ReactNode; /** Main body content */ children?: ReactNode; /** Action buttons */ actions?: ReactNode; /** Container padding override */ pad?: Space; /** Compact removes container + internal paddings */ compact?: boolean; /** Disable closing via backdrop click */ disableBackdropClick?: boolean; /** Disable closing via ESC key */ disableEscapeKeyDown?: boolean; /** Max width when not fullWidth */ maxWidth?: number | string; /** Stretch to full viewport width minus gutter */ fullWidth?: boolean; /** Inline styles (with CSS var support). */ sx?: Sx; /** * Override the root component-identity marker (defaults to `'Modal'`). A * composite that roots on a Modal passes its own name so the DOM node * identifies as that component — the AI-proxy hook. */ 'data-valet-component'?: string; } declare const Modal: React__default.FC; interface ProgressBarProps extends Omit, 'style'>, Presettable { /** 0–100. Omit for indeterminate. */ value?: number; /** Secondary/buffer value for streaming. */ buffer?: number; /** Height of the bar (px, rem, etc.). */ height?: number | string | undefined; /** Override primary color. */ color?: string | undefined; /** Inline styles (supports CSS vars). */ sx?: Sx; } interface ProgressRingProps extends Omit, 'style'>, Presettable { /** 0–100. Omit for indeterminate. */ value?: number; /** Diameter (px, rem, etc.). */ size?: number | string | undefined; /** Stroke thickness (px, rem, etc.). */ thickness?: number | string | undefined; /** Override primary color. */ color?: string | undefined; /** Center content; if omitted, optionally show a percent label via `label`. */ children?: React__default.ReactNode; /** Label inside the ring center. true shows 0–100%; function formats it; or pass a node. */ label?: boolean | ((v: number) => React__default.ReactNode) | React__default.ReactNode; /** Auto-size ring to fit around child content (default true when children present and size not set). */ fitChild?: boolean; /** Extra clearance around child when auto-sizing (px). */ childClearance?: number; /** Inline styles (supports CSS vars). */ sx?: Sx; } declare const ProgressBar: React__default.ForwardRefExoticComponent>; declare const ProgressRing: React__default.ForwardRefExoticComponent>; interface VideoSource { src: string; type: 'video/mp4' | 'video/webm' | string; } interface VideoTrack { src: string; kind: 'subtitles' | 'captions' | 'chapters'; srclang: string; label: string; default?: boolean; } /** Props for the {@link Video} component. */ interface VideoProps extends Omit, 'style' | 'children' | 'onError' | 'onPlay' | 'onPause'>, Presettable { /** One or more video sources (MP4/WebM). */ sources: VideoSource[]; /** Poster image URL displayed before playback. */ poster?: string; /** Caption or subtitle tracks. */ tracks?: VideoTrack[]; /** Display native controls. Defaults to `true`. */ controls?: boolean; /** Autoplay when ready. Defaults to `true`. */ autoPlay?: boolean; /** Mute audio. Defaults to `true` for autoplay compliance. */ muted?: boolean; /** Loop video. */ loop?: boolean; /** CSS width value, e.g. `100%` or `640px`. A bare number is treated as px. */ width?: Space; /** CSS height value, e.g. `auto` or `360px`. A bare number is treated as px. */ height?: Space; /** Lazy load when in viewport. */ lazy?: boolean; /** Custom CSS object-fit. Defaults to `contain`. */ objectFit?: 'contain' | 'cover'; /** Playback callback. */ onPlay?(): void; /** Pause callback. */ onPause?(): void; /** Fires on each loop. */ onLoop?(): void; /** Error callback. */ onError?(e: ErrorEvent): void; /** Inline styles (with CSS var support) */ sx?: Sx; } declare const Video: React__default.FC; interface ImageProps extends Omit, 'width' | 'height' | 'style' | 'alt'>, Presettable { /** Image source URL */ src: string; /** Required alt text. Use empty string for decorative images. */ alt: string; /** * CSS width (number ⇒ px). When BOTH `width` and `height` are numeric they are * ALSO emitted as the native HTML width/height attributes, so the browser can * reserve layout space and avoid CLS. A string value (e.g. '50%', '20rem') is * CSS-only and does NOT set the intrinsic-size attributes. */ width?: number | string; /** CSS height (number ⇒ px). See {@link ImageProps.width} re: native attrs. */ height?: number | string; /** Object-fit value (maps to CSS object-fit) */ fit?: 'cover' | 'contain' | 'fill' | 'none' | 'scale-down'; /** Object-position value (e.g., 'center', 'top', '50% 25%') */ objectPosition?: string; /** * CSS aspect-ratio. A number is the literal width/height ratio — pass a real * ratio like `16 / 9` or `4 / 3` (NOT `16`, which is 16:1). Strings pass * through verbatim (e.g. '16 / 9'). */ aspectRatio?: number | string; /** * Corner radius. Number ⇒ `theme.radius(n)` (scales with density); string ⇒ * verbatim CSS. Rounds the image itself — no wrapper needed. (A parent with * `overflow: hidden` is still the way to CLIP overflowing/child content.) */ radius?: number | string; /** * Mark as a high-priority (above-the-fold / LCP) image: sets `loading='eager'` * and `fetchPriority='high'`. An explicit `loading`/`fetchPriority` still wins. * Default false (images load lazy + decode async). */ priority?: boolean; /** * Opt-in node rendered if the image fails to load (onError). When unset, a * failed image behaves exactly like a native `` — no wrapper, no state. * The caller sizes the fallback node. */ fallback?: React__default.ReactNode; /** Inline styles (with CSS var support) */ sx?: Sx; } declare const Image: React__default.ForwardRefExoticComponent>; type DividerOrientation = 'horizontal' | 'vertical'; interface DividerProps extends Omit, 'color' | 'style'>, Presettable, Pick { /** Orientation of the divider line. */ orientation?: DividerOrientation; /** Explicit color; defaults to theme text colour against background. */ lineColor?: string | undefined; /** Thickness of the line; number uses theme.stroke(n), string passes through. */ thickness?: number | string; /** Length along the main axis; number ⇒ px, string passes through. */ length?: number | string | undefined; /** Inline styles (with CSS var support) */ sx?: Sx; } declare const Divider: React__default.FC; /** Minimal API a GL program should implement to be driven by WebGLCanvas. */ type WebGLProgramLike = { /** Handle canvas resize in physical pixels and current DPR. */ resize: (width: number, height: number, dpr: number) => void; /** Advance internal state by `dt` seconds at absolute time `t` seconds. */ update: (dt: number, t: number) => void; /** Issue draw calls for the current frame. */ render: () => void; /** Free any GL resources and event handlers. */ dispose: () => void; /** * Optional: receive the absolute time `t` (seconds) each frame, in addition * to `update(dt, t)`. Convenience for programs that upload a `uTime` uniform * outside their physics step. */ setTime?: (t: number) => void; }; interface WebGLCanvasProps extends Omit, 'style' | 'children'>, Presettable { /** * Create a program bound to the provided WebGL2 context and canvas. Called * ONCE when the context is acquired; its identity is ref-latched, so an inline * arrow does NOT rebuild the program on parent re-render. To force a rebuild, * change the element `key`. Return `null` to signal a build failure (routes to * `onError` / `fallback`). */ create: (gl: WebGL2RenderingContext, canvas: HTMLCanvasElement) => WebGLProgramLike | null; /** WebGL context attributes. Read ONCE at context creation (ref-latched). */ contextAttributes?: WebGLContextAttributes; /** Clamp devicePixelRatio to avoid excessive fill-rate on hi-DPI screens. */ dprMax?: number; /** Global time scaling applied to dt and absolute time t. */ timeScale?: number; /** Optional clear color, defaults to transparent. Only sets clearColor, not clearing each frame. */ clearColor?: readonly [number, number, number, number]; /** If true, wrapper is absolutely positioned and fills its parent. */ asBackground?: boolean; /** * Called if the WebGL2 context cannot be created (unsupported) or `create()` * returns null. The canvas otherwise dead-ends blank with no signal. */ onError?: (err: unknown) => void; /** Rendered in place of the canvas when initialization fails (see `onError`). */ fallback?: React__default.ReactNode; /** Inline styles for the wrapper (supports CSS variables via Sx). */ sx?: Sx; /** Optional className for the inner canvas element. */ canvasClassName?: string; /** Optional canvas style override. */ canvasStyle?: React__default.CSSProperties; } /** * WebGLCanvas – A small, opinionated WebGL2 canvas host. * - Creates a WebGL2 context with provided attributes. * - Resizes the canvas to its parent using DPR-aware physical pixels. * - Drives a supplied program via requestAnimationFrame. * - Disposes cleanly on unmount (including an explicit context release). */ declare const WebGLCanvas: React__default.FC; type PropsOf = React.ComponentPropsWithRef; type PolymorphicRef = React.ComponentPropsWithRef['ref']; type MergeProps = Omit & B; type PolymorphicProps = MergeProps, OwnProps & { as?: E; }> & { ref?: PolymorphicRef; }; interface PolymorphicComponent { (props: PolymorphicProps): React.ReactElement | null; displayName?: string; } /** Grid box-alignment keyword (CSS grid uses bare start/end, not flex-start). */ type GridAlign = 'start' | 'center' | 'end' | 'stretch'; interface GridOwnProps extends Presettable, Pick { /** Equal-width column count → `repeat(N, minmax(0,1fr))`. Default 2. Responsive. * Ignored when `minColWidth` is set. */ columns?: Responsive; /** Inter-cell gap as units or CSS length. Default 2 units (card-grid gutter). Responsive. */ gap?: Responsive; /** Column-axis gap; overrides `gap` horizontally. Responsive. */ gapX?: Responsive; /** Row-axis gap; overrides `gap` vertically. Responsive. */ gapY?: Responsive; /** Container padding as units or CSS length. Default 1 unit. Responsive. */ pad?: Responsive; /** * Auto-responsive track width: lay out as many equal columns as fit, each at * least this wide — `repeat(auto-{fit|fill}, minmax(min(,100%),1fr))`. * Pure CSS, no breakpoints, no Surface. **Overrides `columns`.** A number is px. */ minColWidth?: number | string; /** With `minColWidth`: `'fill'` (default) keeps a stable column count (empty * trailing tracks); `'fit'` collapses empty tracks so the last row stretches. */ autoFlow?: 'fit' | 'fill'; /** Cross-axis (block) alignment of items in their cell (`align-items`). Default `stretch`. Responsive. */ align?: Responsive; /** Inline-axis alignment of items in their cell (`justify-items`). Default `stretch`. Responsive. */ justifyItems?: Responsive; /** Stretch children to fill their cell (width + height) so a grid of cards is * uniform without per-card `fullWidth`. Default `true`. (Renamed from * `normalizeRowHeights`.) */ equalize?: boolean; /** Inline styles (with CSS var support). */ sx?: Sx; /** Override the machine-readable component marker (composites self-identify). */ 'data-valet-component'?: string; } type GridProps = PolymorphicProps; declare const Grid: PolymorphicComponent<"div", GridOwnProps>; interface GridItemOwnProps extends Presettable { /** Column span — `grid-column: span N`. Responsive. */ span?: Responsive; /** Row span — `grid-row: span N`. Responsive. */ rowSpan?: Responsive; /** 1-based column line to start at — `grid-column-start`. Responsive. */ colStart?: Responsive; /** Inline styles (with CSS var support). */ sx?: Sx; /** Override the machine-readable component marker. */ 'data-valet-component'?: string; } type GridItemProps = PolymorphicProps; declare const GridItem: PolymorphicComponent<"div", GridItemOwnProps>; type StackDirection = 'row' | 'column' | 'row-reverse' | 'column-reverse'; type StackAlign = 'start' | 'center' | 'end' | 'stretch' | 'baseline'; type StackJustify = 'start' | 'center' | 'end' | 'between' | 'around' | 'evenly'; /** Overflow/scroll behavior. `auto-y` (default) is the legacy behavior. */ type StackScroll = 'auto-y' | 'x' | 'both' | 'visible'; interface StackOwnProps extends Presettable, Pick { /** Flex axis. Default `'column'`. Responsive. */ direction?: Responsive; /** Wrap children when they overflow the main axis. Default: `true` for rows, * `false` for columns. Scalar (not responsive). */ wrap?: boolean; /** Inter-child gap as units or CSS length. Default 1 unit. Responsive. */ gap?: Responsive; /** Column-axis gap; overrides `gap` horizontally. Responsive. */ gapX?: Responsive; /** Row-axis gap; overrides `gap` vertically. Responsive. */ gapY?: Responsive; /** Container padding as units or CSS length. Default 1 unit. Responsive. */ pad?: Responsive; /** Cross-axis item alignment (`align-items`). Defaults to the direction's * natural alignment: row → `center`, column → `stretch`. Responsive. */ align?: Responsive; /** Main-axis distribution (`justify-content`). Unset by default. Responsive. */ justify?: Responsive; /** Horizontal placement of the whole stack when it is not full width * (auto-margin anchor — distinct from `align`, which positions children). */ alignX?: 'left' | 'center' | 'right'; /** Node interleaved BETWEEN children (e.g. a ``). For a row stack, * pass a vertically-oriented divider. */ divider?: React__default.ReactNode; /** Overflow behavior. `'auto-y'` (default) keeps the legacy vertical-scroll. */ scroll?: StackScroll; /** Grow factor when the stack is itself a flex child. `true` → 1. */ grow?: boolean | number; /** Inline styles (with CSS var support). */ sx?: Sx; /** Override the machine-readable component marker (sugar/composites self-identify). */ 'data-valet-component'?: string; } type StackProps = PolymorphicProps; declare const Stack: PolymorphicComponent<"div", StackOwnProps>; /** Horizontal stack (`direction='row'`; align defaults to `center`). */ declare const HStack: PolymorphicComponent<"div", Omit>; /** Vertical stack (`direction='column'`). */ declare const VStack: PolymorphicComponent<"div", Omit>; /** Centers its children on both axes (overridable `align`/`justify`). */ declare const Center: PolymorphicComponent<"div", StackOwnProps>; /** Wrapping row with a consistent gap — tags, chips, button clusters. */ declare const Cluster: PolymorphicComponent<"div", Omit>; interface SpacerProps { /** Grow factor; how much free space this filler absorbs. Default 1. */ grow?: number; className?: string; style?: React__default.CSSProperties; } /** A flexible spacer that pushes siblings apart inside a Stack (any direction). */ declare const Spacer: React__default.FC; interface ChildMetrics { width: number; height: number; top: number; left: number; } interface SurfaceState { width: number; height: number; breakpoint: Breakpoint; hasScrollbar: boolean; element: HTMLDivElement | null; /** * Registry of child metrics keyed by registration id. The Map is * replaced wholesale on each batched commit, so subscribing to it * re-notifies for *any* child change — prefer the `cb` argument of * `registerChild` for per-element metrics. * @deprecated Kept for compatibility (do not remove — veto register); * slated to leave the public surface in a future major. */ children: Map; registerChild: (id: string, node: HTMLElement, cb?: (metrics: ChildMetrics) => void) => void; unregisterChild: (id: string) => void; } declare function useSurface(): SurfaceState; declare function useSurface(selector: (state: SurfaceState) => U, equality?: (a: U, b: U) => boolean): U; interface SurfaceProps extends Omit, 'style'>, Presettable { /** Fixed-position full-screen surface when true (default). */ fullscreen?: boolean; /** Optional density override for spacing scale */ density?: Density; /** * Zeros all layout spacing and cascades to descendants; opt out with * compact={false}. Independent of the density scale. */ compact?: boolean; /** * When true, block content visibility until fonts load (FOIT). * Defaults to false for immediate first paint using fallbacks. */ blockUntilFonts?: boolean; /** Inline styles (with CSS var support) */ sx?: Sx; } declare const Surface: React__default.FC; interface BoxOwnProps extends Presettable, Pick { background?: string | undefined; textColor?: string | undefined; /** Center inner content (layout inside the box) */ centerContent?: boolean; /** Stretch to 100% width of container when true */ fullWidth?: boolean; /** Horizontal placement of the box when not fullWidth */ alignX?: 'left' | 'right' | 'center'; /** Inline styles (with CSS var support) */ sx?: Sx; } declare const Box: PolymorphicComponent<"div", BoxOwnProps>; type PanelVariant = 'filled' | 'outlined'; interface PanelProps extends Omit, 'style'>, Presettable, Pick { /** Visual variant: filled | outlined */ variant?: PanelVariant; /** Semantic color intent; maps to theme tokens */ intent?: Intent; /** Explicit color override (theme token name or CSS color) */ color?: string | undefined; fullWidth?: boolean; /** Centre contents & propagate intent via CSS var */ centerContent?: boolean; /** Horizontal placement of the panel when not fullWidth */ alignX?: 'left' | 'right' | 'center'; /** * Opt out of row height normalization (when a parent Grid enables it). * Defaults to true (normalize). Set to false to keep intrinsic heights. */ normalizeRowHeights?: boolean; /** * Override the root component-identity marker (defaults to `'Panel'`). A * composite component that roots on a Panel passes its own name so the DOM * node identifies as that component — the "AI proxies as first-class users" * hook. Omit it and the Panel marks itself. */ 'data-valet-component'?: string; } /** Inline styles (with CSS var support) */ interface PanelProps { sx?: Sx; } declare const Panel: React__default.FC; type ButtonVariant = 'filled' | 'outlined' | 'plain'; type ButtonSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl'; /** * Behavior-only props. Element attributes (onClick, disabled, type, …) * deliberately do NOT live here — they flow from `PropsOf` inside * `PolymorphicProps`, so `