@arcfusionz/arc-primitive-ui 0.2.13 → 0.2.15

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.
@@ -1,6 +1,6 @@
1
1
  import { cn } from "../../lib/cn.js";
2
2
  import { forwardRef, useId } from "react";
3
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
3
+ import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
4
4
  import { useRender } from "@base-ui/react/use-render";
5
5
  //#region src/components/AILoader/AILoader.tsx
6
6
  const rootClasses = "relative inline-flex shrink-0 items-center justify-center align-middle select-none";
@@ -58,7 +58,7 @@ const AILoader = forwardRef(({ state = "default", size = "md", tone = "brand", t
58
58
  role: processing ? "status" : "img",
59
59
  "aria-label": processing ? hasText ? label : void 0 : accessibleLabel,
60
60
  className: cn(rootClasses, toneClasses[tone], hasText && gapClasses[size], className),
61
- children: /* @__PURE__ */ jsxs(Fragment, { children: [
61
+ children: /* @__PURE__ */ jsxs(Fragment$1, { children: [
62
62
  /* @__PURE__ */ jsxs("svg", {
63
63
  viewBox: "0 0 24 24",
64
64
  fill: "none",
@@ -1,6 +1,6 @@
1
1
  import { cn } from "../../lib/cn.js";
2
2
  import { forwardRef } from "react";
3
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
3
+ import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
4
4
  import { useRender } from "@base-ui/react/use-render";
5
5
  import { Button } from "@base-ui/react/button";
6
6
  //#region src/components/Alert/Alert.tsx
@@ -163,7 +163,7 @@ const Alert = forwardRef(({ variant = "neutral", appearance = "soft", title, ico
163
163
  variant,
164
164
  appearance
165
165
  }), className),
166
- children: /* @__PURE__ */ jsxs(Fragment, { children: [
166
+ children: /* @__PURE__ */ jsxs(Fragment$1, { children: [
167
167
  resolvedIcon != null && typeof resolvedIcon !== "boolean" && /* @__PURE__ */ jsx("span", {
168
168
  "aria-hidden": "true",
169
169
  className: cn(iconSlotClasses, !solid && iconColorClasses[variant]),
@@ -1,6 +1,6 @@
1
1
  import { cn } from "../../lib/cn.js";
2
2
  import { Children, createContext, forwardRef, useContext, useMemo } from "react";
3
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
3
+ import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
4
4
  import { useRender } from "@base-ui/react/use-render";
5
5
  import { Avatar } from "@base-ui/react/avatar";
6
6
  //#region src/components/Avatar/Avatar.tsx
@@ -110,7 +110,7 @@ const Avatar$1 = forwardRef(({ size, shape, src, alt, name, fallback, fallbackDe
110
110
  shape: resolvedShape
111
111
  }), group != null && "ring-2 ring-background", className),
112
112
  ...rest,
113
- children: [useShorthand && /* @__PURE__ */ jsxs(Fragment, { children: [src != null && /* @__PURE__ */ jsx(AvatarImage, {
113
+ children: [useShorthand && /* @__PURE__ */ jsxs(Fragment$1, { children: [src != null && /* @__PURE__ */ jsx(AvatarImage, {
114
114
  src,
115
115
  alt: alt ?? ""
116
116
  }), /* @__PURE__ */ jsx(AvatarFallback, {
@@ -165,7 +165,7 @@ const AvatarBadge = forwardRef(({ label, render, className, children, ...rest },
165
165
  ref,
166
166
  props: {
167
167
  className: cn("absolute end-0 bottom-0 block rounded-full bg-success ring-2 ring-background", badgeSizeClasses[size], className),
168
- children: /* @__PURE__ */ jsxs(Fragment, { children: [label != null && /* @__PURE__ */ jsx("span", {
168
+ children: /* @__PURE__ */ jsxs(Fragment$1, { children: [label != null && /* @__PURE__ */ jsx("span", {
169
169
  className: "sr-only",
170
170
  children: label
171
171
  }), children] }),
@@ -202,7 +202,7 @@ const AvatarGroup = forwardRef(({ size = "md", shape = "circle", max, total, ren
202
202
  ref,
203
203
  props: {
204
204
  className: cn("flex items-center", groupSpacingClasses[size], className),
205
- children: /* @__PURE__ */ jsxs(Fragment, { children: [visible, surplus > 0 && /* @__PURE__ */ jsx(Avatar$1, { children: `+${surplus}` })] }),
205
+ children: /* @__PURE__ */ jsxs(Fragment$1, { children: [visible, surplus > 0 && /* @__PURE__ */ jsx(Avatar$1, { children: `+${surplus}` })] }),
206
206
  ...rest
207
207
  }
208
208
  });
@@ -1,6 +1,6 @@
1
1
  import { cn } from "../../lib/cn.js";
2
2
  import { forwardRef } from "react";
3
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
3
+ import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
4
4
  import { useRender } from "@base-ui/react/use-render";
5
5
  import { Button } from "@base-ui/react/button";
6
6
  //#region src/components/Badge/Badge.tsx
@@ -88,7 +88,7 @@ const Badge = forwardRef(({ variant = "neutral", appearance = "soft", size = "md
88
88
  size,
89
89
  pill
90
90
  }), className),
91
- children: /* @__PURE__ */ jsxs(Fragment, { children: [
91
+ children: /* @__PURE__ */ jsxs(Fragment$1, { children: [
92
92
  dot && /* @__PURE__ */ jsx("span", {
93
93
  "aria-hidden": "true",
94
94
  className: "size-1.5 shrink-0 rounded-full bg-current"
@@ -1,6 +1,6 @@
1
1
  import { cn } from "../../lib/cn.js";
2
2
  import { forwardRef, useRef } from "react";
3
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
3
+ import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
4
4
  import { Button } from "@base-ui/react/button";
5
5
  //#region src/components/Button/Button.tsx
6
6
  const baseClasses = "relative inline-flex items-center justify-center whitespace-nowrap select-none rounded-md font-sans font-semibold transition-colors duration-150 cursor-pointer focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-ring [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 disabled:pointer-events-none disabled:opacity-50 data-disabled:pointer-events-none data-disabled:opacity-50";
@@ -128,7 +128,7 @@ const Button$1 = forwardRef(({ variant = "primary", size = "md", fullWidth = fal
128
128
  if (event.detail === 0 && rippleContainerRef.current && !prefersReducedMotion()) spawnRipple(rippleContainerRef.current);
129
129
  onClick?.(event);
130
130
  };
131
- const content = /* @__PURE__ */ jsxs(Fragment, { children: [
131
+ const content = /* @__PURE__ */ jsxs(Fragment$1, { children: [
132
132
  startIcon != null && /* @__PURE__ */ jsx("span", {
133
133
  "aria-hidden": "true",
134
134
  className: "inline-flex items-center",
@@ -161,7 +161,7 @@ const Button$1 = forwardRef(({ variant = "primary", size = "md", fullWidth = fal
161
161
  ref: rippleContainerRef,
162
162
  "aria-hidden": "true",
163
163
  className: "pointer-events-none absolute inset-0 overflow-hidden rounded-[inherit] [contain:strict]"
164
- }), loading ? loadingText != null ? /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(Spinner, {}), loadingText] }) : /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsxs("span", {
164
+ }), loading ? loadingText != null ? /* @__PURE__ */ jsxs(Fragment$1, { children: [/* @__PURE__ */ jsx(Spinner, {}), loadingText] }) : /* @__PURE__ */ jsxs(Fragment$1, { children: [/* @__PURE__ */ jsxs("span", {
165
165
  className: "absolute inset-0 flex items-center justify-center",
166
166
  children: [/* @__PURE__ */ jsx(Spinner, {}), /* @__PURE__ */ jsx("span", {
167
167
  className: "sr-only",
@@ -1,6 +1,6 @@
1
1
  import { cn } from "../../lib/cn.js";
2
2
  import { forwardRef, useEffect, useMemo, useRef, useState } from "react";
3
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
3
+ import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
4
4
  import { useRender } from "@base-ui/react/use-render";
5
5
  import { mergeProps } from "@base-ui/react/merge-props";
6
6
  //#region src/components/Calendar/Calendar.tsx
@@ -441,7 +441,7 @@ const Calendar = forwardRef((props, forwardedRef) => {
441
441
  role: "group",
442
442
  "aria-label": ariaLabel,
443
443
  className: cn("inline-flex flex-col p-3 font-sans", className),
444
- children: /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx("span", {
444
+ children: /* @__PURE__ */ jsxs(Fragment$1, { children: [/* @__PURE__ */ jsx("span", {
445
445
  role: "status",
446
446
  className: "sr-only",
447
447
  children: announcement
@@ -1,7 +1,7 @@
1
1
  import { cn } from "../../lib/cn.js";
2
2
  import { highlightSqlLines } from "./sqlHighlight.js";
3
3
  import { forwardRef, useCallback, useEffect, useId, useMemo, useRef, useState } from "react";
4
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
4
+ import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
5
5
  import { useRender } from "@base-ui/react/use-render";
6
6
  //#region src/components/CodeBlock/CodeBlock.tsx
7
7
  const containerClasses = "relative overflow-hidden rounded-md border border-slate-800 bg-code font-code text-sm text-code-foreground";
@@ -134,7 +134,7 @@ const CodeBlock = forwardRef(({ code, children, language, filename, showLineNumb
134
134
  copiedLabel,
135
135
  floating: !hasHeader
136
136
  }) : null;
137
- const content = /* @__PURE__ */ jsxs(Fragment, { children: [hasHeader && /* @__PURE__ */ jsxs("div", {
137
+ const content = /* @__PURE__ */ jsxs(Fragment$1, { children: [hasHeader && /* @__PURE__ */ jsxs("div", {
138
138
  className: "flex items-center justify-between gap-3 border-b border-slate-800 bg-slate-950 px-4 py-2",
139
139
  children: [/* @__PURE__ */ jsx("div", {
140
140
  className: "flex min-w-0 items-center gap-2",
@@ -1,7 +1,7 @@
1
1
  import { cn } from "../../lib/cn.js";
2
2
  import { FieldContext } from "./FieldContext.js";
3
3
  import { forwardRef, useContext, useMemo } from "react";
4
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
4
+ import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
5
5
  import { Field } from "@base-ui/react/field";
6
6
  import { useController, useFormContext } from "react-hook-form";
7
7
  //#region src/components/Field/Field.tsx
@@ -212,7 +212,7 @@ const FieldError = forwardRef(({ className, children, match, ...rest }, ref) =>
212
212
  match: resolvedMatch,
213
213
  className: cn(errorClasses, className),
214
214
  ...rest,
215
- children: content != null ? /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(ErrorIcon, {}), /* @__PURE__ */ jsx("span", {
215
+ children: content != null ? /* @__PURE__ */ jsxs(Fragment$1, { children: [/* @__PURE__ */ jsx(ErrorIcon, {}), /* @__PURE__ */ jsx("span", {
216
216
  className: "min-w-0",
217
217
  children: content
218
218
  })] }) : void 0
@@ -0,0 +1,225 @@
1
+ import { ButtonProps } from "../Button/Button.js";
2
+ import "../Button/index.js";
3
+ import { ComponentPropsWithoutRef, ReactNode } from "react";
4
+ import { useRender } from "@base-ui/react/use-render";
5
+ //#region src/components/FileUpload/FileUpload.d.ts
6
+ /** Built-in reasons a file is rejected. `validate` may add more of these. */
7
+ type FileUploadRejectionCode = "file-invalid-type" | "file-too-small" | "file-too-large" | "too-many-files";
8
+ /** A file that failed validation, with every reason it failed. */
9
+ interface FileUploadRejection {
10
+ file: File;
11
+ errors: FileUploadRejectionCode[];
12
+ }
13
+ /** Per-file lifecycle the consumer drives while uploading. */
14
+ type FileUploadItemStatus = "idle" | "uploading" | "success" | "error";
15
+ /**
16
+ * Layout of the default `FileUploadDropzone` content. `default` is the full
17
+ * illustrated prompt; `compact` is a slim single row; `auto` shows `default`
18
+ * while empty and switches to `compact` once files are selected.
19
+ */
20
+ type FileUploadDropzoneVariant = "default" | "compact" | "auto";
21
+ /** State exposed on the root element as `data-*` and to the `render` callback. */
22
+ interface FileUploadRenderState extends Record<string, unknown> {
23
+ /** A file is being dragged over the dropzone. */
24
+ dragging: boolean;
25
+ /** The upload is disabled. */
26
+ disabled: boolean;
27
+ /** The upload is marked invalid. */
28
+ invalid: boolean;
29
+ /** No files are selected. */
30
+ empty: boolean;
31
+ /** The selection has reached `maxFiles` (multiple mode only). */
32
+ atMax: boolean;
33
+ }
34
+ /** `1023 B`, `1.5 KB`, `12 MB` — a compact, locale-neutral size readout. */
35
+ declare function formatFileSize(bytes: number): string;
36
+ /** Public view of the upload's state and controls, for custom compositions. */
37
+ interface FileUploadHandle {
38
+ /** The currently selected files. */
39
+ files: File[];
40
+ /** Number of selected files. */
41
+ fileCount: number;
42
+ /** A file is being dragged over the dropzone. */
43
+ isDragging: boolean;
44
+ /** The upload is disabled. */
45
+ disabled: boolean;
46
+ /** The upload is marked invalid. */
47
+ invalid: boolean;
48
+ /** Effective file cap (multiple mode only); `undefined` when unlimited or single. */
49
+ maxFiles?: number;
50
+ /** Slots left before `maxFiles`; `undefined` when there is no cap. */
51
+ remainingFiles?: number;
52
+ /** The selection has reached `maxFiles`. */
53
+ isAtMaxFiles: boolean;
54
+ /** Open the native file picker. */
55
+ open: () => void;
56
+ /** Remove one file from the selection. */
57
+ remove: (file: File) => void;
58
+ /** Clear the whole selection. */
59
+ clear: () => void;
60
+ }
61
+ /**
62
+ * Read the enclosing `FileUpload`'s state and controls — for building custom
63
+ * pieces the flat parts don't cover (a file counter, an "Upload all" button, a
64
+ * dropzone that hides once a file is chosen). Must be called under `FileUpload`.
65
+ */
66
+ declare function useFileUpload(): FileUploadHandle;
67
+ interface FileUploadProps extends Omit<ComponentPropsWithoutRef<"div">, "className" | "onChange" | "defaultValue" | "children"> {
68
+ /** Accepted types as the native `accept` string, e.g. `"image/*,.pdf"`. Enforced client-side too, so dropped files are gated the same as picked ones. */
69
+ accept?: string;
70
+ /** Allow selecting more than one file. When `false` (default) a new selection replaces the current one. */
71
+ multiple?: boolean;
72
+ /** Cap the number of files kept (only applies when `multiple`). Extra files are rejected with `too-many-files`. */
73
+ maxFiles?: number;
74
+ /** Reject files larger than this many bytes with `file-too-large`. */
75
+ maxSize?: number;
76
+ /** Reject files smaller than this many bytes with `file-too-small`. */
77
+ minSize?: number;
78
+ /** Extra validation run after the built-in checks; return the codes a file fails, or `null` to accept it. */
79
+ validate?: (file: File) => FileUploadRejectionCode[] | null;
80
+ /** Enable drag-and-drop onto the dropzone. Defaults to `true`. */
81
+ allowDrop?: boolean;
82
+ /** Prevent a file dropped outside the dropzone from navigating the browser. Defaults to `true`. */
83
+ preventDocumentDrop?: boolean;
84
+ /** Let the user pick a whole directory (`webkitdirectory`; Chromium/WebKit only). */
85
+ directory?: boolean;
86
+ /** Open the device camera on mobile instead of the file browser. */
87
+ capture?: "user" | "environment";
88
+ /** Controlled list of selected files. Pair with `onValueChange`. */
89
+ value?: File[];
90
+ /** Initial selection for the uncontrolled case. */
91
+ defaultValue?: File[];
92
+ /** Called whenever the selection changes (accepted files added, or a file removed). */
93
+ onValueChange?: (files: File[]) => void;
94
+ /** Called with the files newly accepted in a selection or drop. */
95
+ onAccept?: (files: File[]) => void;
96
+ /** Called with the files rejected in a selection or drop and why. */
97
+ onReject?: (rejections: FileUploadRejection[]) => void;
98
+ /** Disable the whole control. Inherited from a surrounding `Field` when unset. */
99
+ disabled?: boolean;
100
+ /** Mark the control invalid (destructive styling). Inherited from a surrounding `Field` when unset. */
101
+ invalid?: boolean;
102
+ /** Convey the field is required. Inherited from a surrounding `Field` when unset. */
103
+ required?: boolean;
104
+ /** `name` for the hidden input so the selection submits with a native form. */
105
+ name?: string;
106
+ /** Accessible name for the hidden file input. */
107
+ inputLabel?: string;
108
+ /** Replace the rendered root `div` or inspect `{ dragging, disabled, invalid, empty }`. */
109
+ render?: useRender.RenderProp<FileUploadRenderState>;
110
+ /** Compose the pieces: `FileUploadDropzone`, `FileUploadList`, `FileUploadTrigger`. */
111
+ children?: ReactNode;
112
+ className?: string;
113
+ }
114
+ /**
115
+ * Drag-and-drop / browse file selection built on a native input. Owns the
116
+ * selected-file list, drag interaction, and client-side validation (`accept`,
117
+ * `maxSize`/`minSize`, `maxFiles`, custom `validate`); the actual upload stays
118
+ * with the consumer, reflected per file through `FileUploadItem`. The empty
119
+ * dropzone is a `SystemState` (`upload` / `upload-error`).
120
+ *
121
+ * Accessibility: the input is visually hidden and the `FileUploadTrigger`
122
+ * button is the focusable, keyboard-operable control (drag-and-drop is a
123
+ * pointer enhancement). Announce added or rejected files yourself — the
124
+ * component is not a live region. Inside a `Field` it inherits
125
+ * `disabled`/`invalid`/`required`.
126
+ */
127
+ declare const FileUpload: import("react").ForwardRefExoticComponent<FileUploadProps & import("react").RefAttributes<HTMLDivElement>>;
128
+ interface FileUploadDropzoneVariantsOptions {
129
+ className?: string;
130
+ }
131
+ /**
132
+ * Class list for an element styled as the dashed drop area — for building a
133
+ * bespoke dropzone while keeping the brand's border, hover, and drag/invalid
134
+ * looks. The drag state hooks are `data-dragging` / `data-invalid` /
135
+ * `data-disabled`.
136
+ */
137
+ declare function fileUploadDropzoneVariants({ className }?: FileUploadDropzoneVariantsOptions): string;
138
+ interface FileUploadDropzoneProps extends Omit<ComponentPropsWithoutRef<"div">, "className"> {
139
+ /**
140
+ * Default-content layout: `default` (full illustrated prompt), `compact`
141
+ * (slim single row), or `auto` (full while empty, compact once files are
142
+ * selected). Ignored when `children` are provided.
143
+ */
144
+ variant?: FileUploadDropzoneVariant;
145
+ /**
146
+ * Show how many more files can be added, derived from the upload's
147
+ * `maxFiles` (multiple mode). Renders nothing when there is no cap. Ignored
148
+ * when `children` are provided.
149
+ */
150
+ showRemaining?: boolean;
151
+ /** Replace the default prompt + `FileUploadTrigger`. */
152
+ children?: ReactNode;
153
+ className?: string;
154
+ }
155
+ /**
156
+ * The dashed drop area. Clicking anywhere in it opens the picker (a pointer
157
+ * convenience); the `FileUploadTrigger` inside is the focusable control for
158
+ * keyboard and assistive tech. With no `children` it renders the default
159
+ * prompt for `variant` — a `SystemState` (`upload`, or `upload-error` when
160
+ * invalid) for `default`, a slim row for `compact`, switching automatically
161
+ * for `auto`. State hooks: `data-dragging`, `data-empty`, `data-at-max`,
162
+ * `data-invalid`, `data-disabled`. At `maxFiles` the browse control is
163
+ * disabled and clicks no longer open the picker. Consumer drag handlers are
164
+ * composed with the internal ones, not replaced.
165
+ */
166
+ declare const FileUploadDropzone: import("react").ForwardRefExoticComponent<FileUploadDropzoneProps & import("react").RefAttributes<HTMLDivElement>>;
167
+ type FileUploadTriggerProps = ButtonProps;
168
+ /**
169
+ * Button that opens the file picker. Rendered inside `FileUploadDropzone` by
170
+ * default; use it on its own for a compact "attach a file" control with no drop
171
+ * area. Defaults to the `outline` variant and an upload-icon + "Browse files"
172
+ * label. A custom label opts into an icon via `startIcon`; pass
173
+ * `startIcon={null}` to remove the default one. Inherits the upload's
174
+ * `disabled` state.
175
+ */
176
+ declare const FileUploadTrigger: import("react").ForwardRefExoticComponent<ButtonProps & import("react").RefAttributes<HTMLButtonElement>>;
177
+ interface FileUploadListProps extends Omit<ComponentPropsWithoutRef<"ul">, "className" | "children"> {
178
+ /**
179
+ * Omit to auto-render a `FileUploadItem` per selected file. Pass a function
180
+ * `(file, index) => ReactNode` to render items with your own upload
181
+ * `status`/`progress`, or pass elements to render them verbatim.
182
+ */
183
+ children?: ReactNode | ((file: File, index: number) => ReactNode);
184
+ className?: string;
185
+ }
186
+ /**
187
+ * Container for the selected files. `role="list"` is set explicitly so the
188
+ * list semantics survive the `flex` reset in Safari/VoiceOver. Renders nothing
189
+ * while empty in the default (auto or render-prop) mode.
190
+ */
191
+ declare const FileUploadList: import("react").ForwardRefExoticComponent<FileUploadListProps & import("react").RefAttributes<HTMLUListElement>>;
192
+ interface FileUploadItemProps extends Omit<ComponentPropsWithoutRef<"li">, "className" | "children"> {
193
+ /** The file this row represents (name, size, and type come from it). */
194
+ file: File;
195
+ /** Upload lifecycle you drive: `uploading` shows a progress bar; `success`/`error` show a status label. */
196
+ status?: FileUploadItemStatus;
197
+ /** Completion 0–100 while `status="uploading"`. Omit for an indeterminate bar. */
198
+ progress?: number;
199
+ /** Detailed message shown while `status="error"`, in place of the size. */
200
+ error?: ReactNode;
201
+ /** Short visible + announced status label. Defaults per `status` ("Uploading", "Uploaded", "Failed"); pass to override the copy. */
202
+ statusLabel?: ReactNode;
203
+ /** Show the remove button. Defaults to `true`. */
204
+ removable?: boolean;
205
+ /** Remove handler. Defaults to removing this file from the selection. */
206
+ onRemove?: () => void;
207
+ /** Accessible name for the remove button. Defaults to `Remove {file name}`. */
208
+ removeLabel?: string;
209
+ /** URL of a preview image (e.g. a server-side thumbnail). The primitive owns the dimensions, radius, `object-fit`, decorative attributes, and drag prevention — you supply only the URL. Falls back to a file icon when omitted, non-image, or the image fails to load. */
210
+ previewSrc?: string;
211
+ /** Replace the entire row body. */
212
+ children?: ReactNode;
213
+ className?: string;
214
+ }
215
+ /**
216
+ * One selected file: a thumbnail (auto-generated for images, or from
217
+ * `previewSrc`) with a file-icon fallback, the name, and — depending on
218
+ * `status` — its size, an upload progress bar, or an error message, plus a
219
+ * visible status label and a remove button. `status`/`progress`/`error` are
220
+ * consumer-driven so the row reflects real upload state; the component shows
221
+ * failures but does not itself retry.
222
+ */
223
+ declare const FileUploadItem: import("react").ForwardRefExoticComponent<FileUploadItemProps & import("react").RefAttributes<HTMLLIElement>>;
224
+ //#endregion
225
+ export { FileUpload, FileUploadDropzone, FileUploadDropzoneProps, FileUploadDropzoneVariant, FileUploadDropzoneVariantsOptions, FileUploadHandle, FileUploadItem, FileUploadItemProps, FileUploadItemStatus, FileUploadList, FileUploadListProps, FileUploadProps, FileUploadRejection, FileUploadRejectionCode, FileUploadRenderState, FileUploadTrigger, FileUploadTriggerProps, fileUploadDropzoneVariants, formatFileSize, useFileUpload };
@@ -0,0 +1,608 @@
1
+ import { cn } from "../../lib/cn.js";
2
+ import { Button } from "../Button/Button.js";
3
+ import { FieldContext } from "../Field/FieldContext.js";
4
+ import { Progress } from "../Progress/Progress.js";
5
+ import { SystemState } from "../SystemState/SystemState.js";
6
+ import { Fragment, createContext, forwardRef, useContext, useEffect, useId, useRef, useState } from "react";
7
+ import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
8
+ import { useRender } from "@base-ui/react/use-render";
9
+ //#region src/components/FileUpload/FileUpload.tsx
10
+ /** `1023 B`, `1.5 KB`, `12 MB` — a compact, locale-neutral size readout. */
11
+ function formatFileSize(bytes) {
12
+ if (!Number.isFinite(bytes) || bytes < 0) return "";
13
+ if (bytes < 1024) return `${bytes} B`;
14
+ const units = [
15
+ "KB",
16
+ "MB",
17
+ "GB",
18
+ "TB"
19
+ ];
20
+ let value = bytes / 1024;
21
+ let unit = 0;
22
+ while (value >= 1024 && unit < units.length - 1) {
23
+ value /= 1024;
24
+ unit += 1;
25
+ }
26
+ return `${value < 10 ? value.toFixed(1) : Math.round(value)} ${units[unit]}`;
27
+ }
28
+ function matchesAccept(file, accept) {
29
+ if (!accept) return true;
30
+ const tokens = accept.split(",").map((token) => token.trim().toLowerCase()).filter(Boolean);
31
+ if (tokens.length === 0) return true;
32
+ const name = file.name.toLowerCase();
33
+ const mime = file.type.toLowerCase();
34
+ return tokens.some((token) => {
35
+ if (token.startsWith(".")) return name.endsWith(token);
36
+ if (token.endsWith("/*")) return mime.startsWith(token.slice(0, -1));
37
+ return mime === token;
38
+ });
39
+ }
40
+ function fileKey(file) {
41
+ return `${file.name}:${file.size}:${file.lastModified}`;
42
+ }
43
+ function canUseObjectUrl() {
44
+ return typeof URL !== "undefined" && typeof URL.createObjectURL === "function" && typeof URL.revokeObjectURL === "function";
45
+ }
46
+ const FileUploadContext = createContext(null);
47
+ function useFileUploadContext(part) {
48
+ const context = useContext(FileUploadContext);
49
+ if (context == null) throw new Error(`${part} must be rendered inside <FileUpload>.`);
50
+ return context;
51
+ }
52
+ /**
53
+ * Read the enclosing `FileUpload`'s state and controls — for building custom
54
+ * pieces the flat parts don't cover (a file counter, an "Upload all" button, a
55
+ * dropzone that hides once a file is chosen). Must be called under `FileUpload`.
56
+ */
57
+ function useFileUpload() {
58
+ const context = useFileUploadContext("useFileUpload");
59
+ return {
60
+ files: context.files,
61
+ fileCount: context.fileCount,
62
+ isDragging: context.isDragging,
63
+ disabled: context.disabled,
64
+ invalid: context.invalid,
65
+ maxFiles: context.maxFiles,
66
+ remainingFiles: context.remainingFiles,
67
+ isAtMaxFiles: context.isAtMaxFiles,
68
+ open: context.openPicker,
69
+ remove: context.removeFile,
70
+ clear: context.clear
71
+ };
72
+ }
73
+ const rootClasses = "flex w-full flex-col gap-3";
74
+ const stateAttributesMapping = {
75
+ dragging: (value) => value ? { "data-dragging": "" } : null,
76
+ disabled: (value) => value ? { "data-disabled": "" } : null,
77
+ invalid: (value) => value ? { "data-invalid": "" } : null,
78
+ empty: (value) => value ? { "data-empty": "" } : null,
79
+ atMax: (value) => value ? { "data-at-max": "" } : null
80
+ };
81
+ /**
82
+ * Drag-and-drop / browse file selection built on a native input. Owns the
83
+ * selected-file list, drag interaction, and client-side validation (`accept`,
84
+ * `maxSize`/`minSize`, `maxFiles`, custom `validate`); the actual upload stays
85
+ * with the consumer, reflected per file through `FileUploadItem`. The empty
86
+ * dropzone is a `SystemState` (`upload` / `upload-error`).
87
+ *
88
+ * Accessibility: the input is visually hidden and the `FileUploadTrigger`
89
+ * button is the focusable, keyboard-operable control (drag-and-drop is a
90
+ * pointer enhancement). Announce added or rejected files yourself — the
91
+ * component is not a live region. Inside a `Field` it inherits
92
+ * `disabled`/`invalid`/`required`.
93
+ */
94
+ const FileUpload = forwardRef(({ accept, multiple = false, maxFiles, maxSize, minSize, validate, allowDrop = true, preventDocumentDrop = true, directory = false, capture, value, defaultValue, onValueChange, onAccept, onReject, disabled, invalid, required, name, inputLabel, render, className, children, ...rest }, ref) => {
95
+ const fieldContext = useContext(FieldContext);
96
+ const resolvedDisabled = disabled ?? fieldContext?.control?.disabled ?? false;
97
+ const resolvedInvalid = invalid ?? fieldContext?.invalid ?? false;
98
+ const resolvedRequired = required ?? fieldContext?.required ?? false;
99
+ const inputId = `${useId()}-file-input`;
100
+ const inputRef = useRef(null);
101
+ const rootRef = useRef(null);
102
+ const dragDepth = useRef(0);
103
+ const isControlled = value !== void 0;
104
+ const [internalFiles, setInternalFiles] = useState(defaultValue ?? []);
105
+ const files = isControlled ? value : internalFiles;
106
+ const [isDragging, setIsDragging] = useState(false);
107
+ const fileCount = files.length;
108
+ const effectiveMaxFiles = multiple ? maxFiles : void 0;
109
+ const isAtMaxFiles = effectiveMaxFiles != null && fileCount >= effectiveMaxFiles;
110
+ const remainingFiles = effectiveMaxFiles != null ? Math.max(0, effectiveMaxFiles - fileCount) : void 0;
111
+ const syncInputFiles = (list) => {
112
+ const input = inputRef.current;
113
+ if (!input || typeof DataTransfer === "undefined") return;
114
+ try {
115
+ const transfer = new DataTransfer();
116
+ for (const file of list) transfer.items.add(file);
117
+ input.files = transfer.files;
118
+ } catch {}
119
+ };
120
+ useEffect(() => {
121
+ syncInputFiles(files);
122
+ }, [files]);
123
+ const commit = (next) => {
124
+ if (!isControlled) setInternalFiles(next);
125
+ onValueChange?.(next);
126
+ };
127
+ const getRejectionCodes = (file, projectedCount) => {
128
+ const codes = [];
129
+ if (!matchesAccept(file, accept)) codes.push("file-invalid-type");
130
+ if (typeof minSize === "number" && file.size < minSize) codes.push("file-too-small");
131
+ if (typeof maxSize === "number" && file.size > maxSize) codes.push("file-too-large");
132
+ if (projectedCount >= (multiple ? maxFiles ?? Infinity : 1)) codes.push("too-many-files");
133
+ const custom = validate?.(file);
134
+ if (custom) {
135
+ for (const code of custom) if (!codes.includes(code)) codes.push(code);
136
+ }
137
+ return codes;
138
+ };
139
+ const processIncoming = (incoming) => {
140
+ const kept = [...multiple ? files : []];
141
+ const accepted = [];
142
+ const rejections = [];
143
+ for (const file of incoming) {
144
+ if (kept.some((existing) => fileKey(existing) === fileKey(file))) continue;
145
+ const codes = getRejectionCodes(file, kept.length);
146
+ if (codes.length > 0) rejections.push({
147
+ file,
148
+ errors: codes
149
+ });
150
+ else {
151
+ kept.push(file);
152
+ accepted.push(file);
153
+ }
154
+ }
155
+ const next = multiple ? kept : accepted.length > 0 ? [accepted[0]] : files;
156
+ if (accepted.length > 0) onAccept?.(accepted);
157
+ if (rejections.length > 0) onReject?.(rejections);
158
+ if (next.length !== files.length || next.some((file, index) => file !== files[index])) commit(next);
159
+ syncInputFiles(next);
160
+ };
161
+ const openPicker = () => {
162
+ if (resolvedDisabled) return;
163
+ inputRef.current?.click();
164
+ };
165
+ const removeFile = (file) => {
166
+ commit(files.filter((existing) => fileKey(existing) !== fileKey(file)));
167
+ };
168
+ const clear = () => commit([]);
169
+ const dropHasFiles = (event) => Array.from(event.dataTransfer?.types ?? []).includes("Files");
170
+ const onDragEnter = (event) => {
171
+ if (resolvedDisabled || !allowDrop || !dropHasFiles(event)) return;
172
+ event.preventDefault();
173
+ dragDepth.current += 1;
174
+ setIsDragging(true);
175
+ };
176
+ const onDragOver = (event) => {
177
+ if (resolvedDisabled || !allowDrop || !dropHasFiles(event)) return;
178
+ event.preventDefault();
179
+ event.dataTransfer.dropEffect = "copy";
180
+ };
181
+ const onDragLeave = (event) => {
182
+ if (resolvedDisabled || !allowDrop) return;
183
+ event.preventDefault();
184
+ dragDepth.current = Math.max(0, dragDepth.current - 1);
185
+ if (dragDepth.current === 0) setIsDragging(false);
186
+ };
187
+ const onDrop = (event) => {
188
+ if (resolvedDisabled || !allowDrop) return;
189
+ event.preventDefault();
190
+ dragDepth.current = 0;
191
+ setIsDragging(false);
192
+ const dropped = Array.from(event.dataTransfer?.files ?? []);
193
+ if (dropped.length > 0) processIncoming(dropped);
194
+ };
195
+ useEffect(() => {
196
+ if (!preventDocumentDrop || !allowDrop || typeof document === "undefined") return;
197
+ const isOutside = (event) => {
198
+ const root = rootRef.current;
199
+ return !root || !(event.target instanceof Node) || !root.contains(event.target);
200
+ };
201
+ const prevent = (event) => {
202
+ if (isOutside(event)) event.preventDefault();
203
+ };
204
+ document.addEventListener("dragover", prevent);
205
+ document.addEventListener("drop", prevent);
206
+ return () => {
207
+ document.removeEventListener("dragover", prevent);
208
+ document.removeEventListener("drop", prevent);
209
+ };
210
+ }, [preventDocumentDrop, allowDrop]);
211
+ const contextValue = {
212
+ files,
213
+ fileCount,
214
+ disabled: resolvedDisabled,
215
+ invalid: resolvedInvalid,
216
+ multiple,
217
+ maxFiles: effectiveMaxFiles,
218
+ remainingFiles,
219
+ isAtMaxFiles,
220
+ isEmpty: fileCount === 0,
221
+ isDragging,
222
+ inputId,
223
+ openPicker,
224
+ removeFile,
225
+ clear,
226
+ dropzoneListeners: {
227
+ onDragEnter,
228
+ onDragOver,
229
+ onDragLeave,
230
+ onDrop
231
+ }
232
+ };
233
+ return useRender({
234
+ defaultTagName: "div",
235
+ render,
236
+ ref: [ref, rootRef],
237
+ state: {
238
+ dragging: isDragging,
239
+ disabled: resolvedDisabled,
240
+ invalid: resolvedInvalid,
241
+ empty: fileCount === 0,
242
+ atMax: isAtMaxFiles
243
+ },
244
+ stateAttributesMapping,
245
+ props: {
246
+ className: cn(rootClasses, className),
247
+ children: /* @__PURE__ */ jsxs(FileUploadContext.Provider, {
248
+ value: contextValue,
249
+ children: [/* @__PURE__ */ jsx("input", {
250
+ ref: inputRef,
251
+ id: inputId,
252
+ type: "file",
253
+ accept,
254
+ multiple,
255
+ capture,
256
+ disabled: resolvedDisabled || void 0,
257
+ required: resolvedRequired || void 0,
258
+ name,
259
+ "aria-label": inputLabel ?? (multiple ? "Upload files" : "Upload file"),
260
+ "aria-invalid": resolvedInvalid || void 0,
261
+ tabIndex: -1,
262
+ className: "sr-only",
263
+ onChange: (event) => {
264
+ const list = event.target.files;
265
+ if (list && list.length > 0) processIncoming(Array.from(list));
266
+ },
267
+ ...directory ? { webkitdirectory: "" } : null
268
+ }), children]
269
+ }),
270
+ ...rest
271
+ }
272
+ });
273
+ });
274
+ FileUpload.displayName = "FileUpload";
275
+ const dropzoneClasses = "relative flex w-full flex-col items-center justify-center rounded-md border-2 border-dashed border-border bg-transparent cursor-pointer transition-colors duration-150 hover:border-slate-300 hover:bg-surface has-[:focus-visible]:border-primary has-[:focus-visible]:bg-primary-50 data-dragging:border-primary data-dragging:bg-primary-50 data-invalid:border-destructive data-at-max:cursor-default data-at-max:hover:border-border data-at-max:hover:bg-transparent data-disabled:cursor-default data-disabled:opacity-50 data-disabled:hover:border-border data-disabled:hover:bg-transparent";
276
+ const dropzoneCompactClasses = "flex-row items-center gap-3 px-4 py-3 text-start";
277
+ /**
278
+ * Class list for an element styled as the dashed drop area — for building a
279
+ * bespoke dropzone while keeping the brand's border, hover, and drag/invalid
280
+ * looks. The drag state hooks are `data-dragging` / `data-invalid` /
281
+ * `data-disabled`.
282
+ */
283
+ function fileUploadDropzoneVariants({ className } = {}) {
284
+ return cn(dropzoneClasses, className);
285
+ }
286
+ /**
287
+ * The dashed drop area. Clicking anywhere in it opens the picker (a pointer
288
+ * convenience); the `FileUploadTrigger` inside is the focusable control for
289
+ * keyboard and assistive tech. With no `children` it renders the default
290
+ * prompt for `variant` — a `SystemState` (`upload`, or `upload-error` when
291
+ * invalid) for `default`, a slim row for `compact`, switching automatically
292
+ * for `auto`. State hooks: `data-dragging`, `data-empty`, `data-at-max`,
293
+ * `data-invalid`, `data-disabled`. At `maxFiles` the browse control is
294
+ * disabled and clicks no longer open the picker. Consumer drag handlers are
295
+ * composed with the internal ones, not replaced.
296
+ */
297
+ const FileUploadDropzone = forwardRef(({ variant = "default", showRemaining = false, children, className, onClick, onDragEnter, onDragOver, onDragLeave, onDrop, ...rest }, ref) => {
298
+ const context = useFileUploadContext("FileUploadDropzone");
299
+ const listeners = context.dropzoneListeners;
300
+ const resolvedVariant = variant === "auto" ? context.isEmpty ? "default" : "compact" : variant;
301
+ const remaining = showRemaining && context.maxFiles != null ? /* @__PURE__ */ jsx("span", {
302
+ className: "font-sans text-xs text-muted-foreground",
303
+ children: context.isAtMaxFiles ? `Maximum of ${context.maxFiles} files reached` : `${context.remainingFiles} of ${context.maxFiles} files remaining`
304
+ }) : null;
305
+ return /* @__PURE__ */ jsx("div", {
306
+ ref,
307
+ "data-dragging": context.isDragging ? "" : void 0,
308
+ "data-empty": context.isEmpty ? "" : void 0,
309
+ "data-at-max": context.isAtMaxFiles ? "" : void 0,
310
+ "data-invalid": context.invalid ? "" : void 0,
311
+ "data-disabled": context.disabled ? "" : void 0,
312
+ className: fileUploadDropzoneVariants({ className: cn(resolvedVariant === "compact" && dropzoneCompactClasses, className) }),
313
+ onClick: (event) => {
314
+ onClick?.(event);
315
+ if (event.defaultPrevented || context.disabled || context.isAtMaxFiles) return;
316
+ context.openPicker();
317
+ },
318
+ onDragEnter: (event) => {
319
+ onDragEnter?.(event);
320
+ listeners.onDragEnter(event);
321
+ },
322
+ onDragOver: (event) => {
323
+ onDragOver?.(event);
324
+ listeners.onDragOver(event);
325
+ },
326
+ onDragLeave: (event) => {
327
+ onDragLeave?.(event);
328
+ listeners.onDragLeave(event);
329
+ },
330
+ onDrop: (event) => {
331
+ onDrop?.(event);
332
+ listeners.onDrop(event);
333
+ },
334
+ ...rest,
335
+ children: children ?? (resolvedVariant === "compact" ? /* @__PURE__ */ jsxs(Fragment$1, { children: [
336
+ /* @__PURE__ */ jsx(UploadIcon, {
337
+ className: "size-5 shrink-0 text-muted-foreground",
338
+ "aria-hidden": "true"
339
+ }),
340
+ /* @__PURE__ */ jsxs("div", {
341
+ className: "flex min-w-0 flex-1 flex-col",
342
+ children: [/* @__PURE__ */ jsx("span", {
343
+ className: "font-sans text-sm font-medium text-foreground",
344
+ children: context.isAtMaxFiles ? "Maximum files reached" : "Drag and drop or browse"
345
+ }), remaining]
346
+ }),
347
+ /* @__PURE__ */ jsx(FileUploadTrigger, {
348
+ size: "sm",
349
+ startIcon: null,
350
+ disabled: context.isAtMaxFiles || void 0
351
+ })
352
+ ] }) : /* @__PURE__ */ jsx(SystemState, {
353
+ variant: context.invalid ? "upload-error" : "upload",
354
+ bg: "transparent",
355
+ action: /* @__PURE__ */ jsxs("div", {
356
+ className: "flex flex-col items-center gap-2",
357
+ children: [/* @__PURE__ */ jsx(FileUploadTrigger, { disabled: context.isAtMaxFiles || void 0 }), remaining]
358
+ })
359
+ }))
360
+ });
361
+ });
362
+ FileUploadDropzone.displayName = "FileUploadDropzone";
363
+ /**
364
+ * Button that opens the file picker. Rendered inside `FileUploadDropzone` by
365
+ * default; use it on its own for a compact "attach a file" control with no drop
366
+ * area. Defaults to the `outline` variant and an upload-icon + "Browse files"
367
+ * label. A custom label opts into an icon via `startIcon`; pass
368
+ * `startIcon={null}` to remove the default one. Inherits the upload's
369
+ * `disabled` state.
370
+ */
371
+ const FileUploadTrigger = forwardRef(({ variant = "outline", disabled, onClick, startIcon, children, ...rest }, ref) => {
372
+ const context = useFileUploadContext("FileUploadTrigger");
373
+ const resolvedStartIcon = startIcon !== void 0 ? startIcon : children == null ? /* @__PURE__ */ jsx(UploadIcon, {}) : void 0;
374
+ return /* @__PURE__ */ jsx(Button, {
375
+ ref,
376
+ type: "button",
377
+ variant,
378
+ disabled: disabled ?? context.disabled,
379
+ startIcon: resolvedStartIcon,
380
+ onClick: (event) => {
381
+ event.stopPropagation();
382
+ onClick?.(event);
383
+ if (!event.defaultPrevented) context.openPicker();
384
+ },
385
+ ...rest,
386
+ children: children ?? "Browse files"
387
+ });
388
+ });
389
+ FileUploadTrigger.displayName = "FileUploadTrigger";
390
+ const listClasses = "flex w-full flex-col gap-2";
391
+ /**
392
+ * Container for the selected files. `role="list"` is set explicitly so the
393
+ * list semantics survive the `flex` reset in Safari/VoiceOver. Renders nothing
394
+ * while empty in the default (auto or render-prop) mode.
395
+ */
396
+ const FileUploadList = forwardRef(({ children, className, ...rest }, ref) => {
397
+ const context = useFileUploadContext("FileUploadList");
398
+ const isRenderProp = typeof children === "function";
399
+ if ((children == null || isRenderProp) && context.files.length === 0) return null;
400
+ return /* @__PURE__ */ jsx("ul", {
401
+ ref,
402
+ role: "list",
403
+ className: cn(listClasses, className),
404
+ ...rest,
405
+ children: isRenderProp ? context.files.map((file, index) => /* @__PURE__ */ jsx(Fragment, { children: children(file, index) }, `${fileKey(file)}-${index}`)) : children ?? context.files.map((file, index) => /* @__PURE__ */ jsx(FileUploadItem, { file }, `${fileKey(file)}-${index}`))
406
+ });
407
+ });
408
+ FileUploadList.displayName = "FileUploadList";
409
+ const itemClasses = "flex items-center gap-3 rounded-md border border-border bg-background px-3 py-2.5 data-[status=error]:border-destructive";
410
+ const itemNameClasses = "truncate font-sans text-sm font-medium text-foreground";
411
+ const itemMetaClasses = "font-sans text-xs text-muted-foreground";
412
+ const itemErrorClasses = "font-sans text-xs font-medium text-error-700";
413
+ const itemStatusLabels = {
414
+ idle: "",
415
+ uploading: "Uploading",
416
+ success: "Uploaded",
417
+ error: "Failed"
418
+ };
419
+ const itemStatusColors = {
420
+ idle: "text-muted-foreground",
421
+ uploading: "text-muted-foreground",
422
+ success: "text-success-700",
423
+ error: "text-error-700"
424
+ };
425
+ /**
426
+ * One selected file: a thumbnail (auto-generated for images, or from
427
+ * `previewSrc`) with a file-icon fallback, the name, and — depending on
428
+ * `status` — its size, an upload progress bar, or an error message, plus a
429
+ * visible status label and a remove button. `status`/`progress`/`error` are
430
+ * consumer-driven so the row reflects real upload state; the component shows
431
+ * failures but does not itself retry.
432
+ */
433
+ const FileUploadItem = forwardRef(({ file, status = "idle", progress, error, statusLabel, removable = true, onRemove, removeLabel, previewSrc, children, className, ...rest }, ref) => {
434
+ const context = useFileUploadContext("FileUploadItem");
435
+ const handleRemove = onRemove ?? (() => context.removeFile(file));
436
+ const resolvedStatusLabel = statusLabel !== void 0 ? statusLabel : itemStatusLabels[status] || null;
437
+ const showStatusLabel = status !== "idle" && resolvedStatusLabel != null;
438
+ return /* @__PURE__ */ jsx("li", {
439
+ ref,
440
+ "data-status": status,
441
+ className: cn(itemClasses, className),
442
+ ...rest,
443
+ children: children ?? /* @__PURE__ */ jsxs(Fragment$1, { children: [
444
+ /* @__PURE__ */ jsx("span", {
445
+ className: "shrink-0",
446
+ children: /* @__PURE__ */ jsx(FileUploadThumbnail, {
447
+ file,
448
+ src: previewSrc
449
+ })
450
+ }),
451
+ /* @__PURE__ */ jsxs("div", {
452
+ className: "flex min-w-0 flex-1 flex-col gap-1",
453
+ children: [/* @__PURE__ */ jsxs("div", {
454
+ className: "flex items-center gap-2",
455
+ children: [/* @__PURE__ */ jsx("span", {
456
+ className: itemNameClasses,
457
+ children: file.name
458
+ }), showStatusLabel && /* @__PURE__ */ jsxs("span", {
459
+ className: cn("ms-auto inline-flex shrink-0 items-center gap-1 font-sans text-xs font-medium", itemStatusColors[status]),
460
+ children: [
461
+ status === "success" && /* @__PURE__ */ jsx(CheckCircleIcon, {
462
+ className: "size-3.5",
463
+ "aria-hidden": "true"
464
+ }),
465
+ status === "error" && /* @__PURE__ */ jsx(AlertCircleIcon, {
466
+ className: "size-3.5",
467
+ "aria-hidden": "true"
468
+ }),
469
+ resolvedStatusLabel
470
+ ]
471
+ })]
472
+ }), status === "uploading" ? /* @__PURE__ */ jsx(Progress, {
473
+ size: "sm",
474
+ value: progress ?? null,
475
+ "aria-label": `Uploading ${file.name}`
476
+ }) : status === "error" ? /* @__PURE__ */ jsx("span", {
477
+ className: itemErrorClasses,
478
+ children: error ?? "Upload failed"
479
+ }) : /* @__PURE__ */ jsx("span", {
480
+ className: itemMetaClasses,
481
+ children: formatFileSize(file.size)
482
+ })]
483
+ }),
484
+ removable && /* @__PURE__ */ jsx(Button, {
485
+ iconOnly: true,
486
+ size: "sm",
487
+ variant: "ghost",
488
+ type: "button",
489
+ "aria-label": removeLabel ?? `Remove ${file.name}`,
490
+ disabled: context.disabled,
491
+ onClick: handleRemove,
492
+ className: "shrink-0 self-start",
493
+ children: /* @__PURE__ */ jsx(XIcon, {})
494
+ })
495
+ ] })
496
+ });
497
+ });
498
+ FileUploadItem.displayName = "FileUploadItem";
499
+ const thumbnailImageClasses = "size-10 rounded-md object-cover";
500
+ const thumbnailFallbackClasses = "flex size-10 items-center justify-center rounded-md bg-muted text-muted-foreground";
501
+ function FileUploadThumbnail({ file, src }) {
502
+ const [autoUrl, setAutoUrl] = useState(null);
503
+ const [failed, setFailed] = useState(false);
504
+ useEffect(() => {
505
+ setFailed(false);
506
+ if (src != null || !file.type.startsWith("image/") || !canUseObjectUrl()) {
507
+ setAutoUrl(null);
508
+ return;
509
+ }
510
+ const objectUrl = URL.createObjectURL(file);
511
+ setAutoUrl(objectUrl);
512
+ return () => URL.revokeObjectURL(objectUrl);
513
+ }, [file, src]);
514
+ const resolvedSrc = src ?? autoUrl;
515
+ if (resolvedSrc != null && !failed) return /* @__PURE__ */ jsx("img", {
516
+ src: resolvedSrc,
517
+ alt: "",
518
+ "aria-hidden": "true",
519
+ className: thumbnailImageClasses,
520
+ draggable: false,
521
+ onError: () => setFailed(true)
522
+ });
523
+ return /* @__PURE__ */ jsx("span", {
524
+ className: thumbnailFallbackClasses,
525
+ children: /* @__PURE__ */ jsx(FileIcon, {
526
+ className: "size-5",
527
+ "aria-hidden": "true"
528
+ })
529
+ });
530
+ }
531
+ function UploadIcon(props) {
532
+ return /* @__PURE__ */ jsxs("svg", {
533
+ viewBox: "0 0 24 24",
534
+ fill: "none",
535
+ stroke: "currentColor",
536
+ strokeWidth: 2,
537
+ strokeLinecap: "round",
538
+ strokeLinejoin: "round",
539
+ ...props,
540
+ children: [
541
+ /* @__PURE__ */ jsx("path", { d: "M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" }),
542
+ /* @__PURE__ */ jsx("path", { d: "m17 8-5-5-5 5" }),
543
+ /* @__PURE__ */ jsx("path", { d: "M12 3v12" })
544
+ ]
545
+ });
546
+ }
547
+ function FileIcon(props) {
548
+ return /* @__PURE__ */ jsxs("svg", {
549
+ viewBox: "0 0 24 24",
550
+ fill: "none",
551
+ stroke: "currentColor",
552
+ strokeWidth: 2,
553
+ strokeLinecap: "round",
554
+ strokeLinejoin: "round",
555
+ ...props,
556
+ children: [/* @__PURE__ */ jsx("path", { d: "M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7z" }), /* @__PURE__ */ jsx("path", { d: "M14 2v4a2 2 0 0 0 2 2h4" })]
557
+ });
558
+ }
559
+ function XIcon(props) {
560
+ return /* @__PURE__ */ jsx("svg", {
561
+ viewBox: "0 0 24 24",
562
+ fill: "none",
563
+ stroke: "currentColor",
564
+ strokeWidth: 2,
565
+ strokeLinecap: "round",
566
+ strokeLinejoin: "round",
567
+ ...props,
568
+ children: /* @__PURE__ */ jsx("path", { d: "M18 6 6 18M6 6l12 12" })
569
+ });
570
+ }
571
+ function CheckCircleIcon(props) {
572
+ return /* @__PURE__ */ jsxs("svg", {
573
+ viewBox: "0 0 24 24",
574
+ fill: "none",
575
+ stroke: "currentColor",
576
+ strokeWidth: 2,
577
+ strokeLinecap: "round",
578
+ strokeLinejoin: "round",
579
+ ...props,
580
+ children: [/* @__PURE__ */ jsx("circle", {
581
+ cx: "12",
582
+ cy: "12",
583
+ r: "10"
584
+ }), /* @__PURE__ */ jsx("path", { d: "m9 12 2 2 4-4" })]
585
+ });
586
+ }
587
+ function AlertCircleIcon(props) {
588
+ return /* @__PURE__ */ jsxs("svg", {
589
+ viewBox: "0 0 24 24",
590
+ fill: "none",
591
+ stroke: "currentColor",
592
+ strokeWidth: 2,
593
+ strokeLinecap: "round",
594
+ strokeLinejoin: "round",
595
+ ...props,
596
+ children: [
597
+ /* @__PURE__ */ jsx("circle", {
598
+ cx: "12",
599
+ cy: "12",
600
+ r: "10"
601
+ }),
602
+ /* @__PURE__ */ jsx("path", { d: "M12 8v4" }),
603
+ /* @__PURE__ */ jsx("path", { d: "M12 16h.01" })
604
+ ]
605
+ });
606
+ }
607
+ //#endregion
608
+ export { FileUpload, FileUploadDropzone, FileUploadItem, FileUploadList, FileUploadTrigger, fileUploadDropzoneVariants, formatFileSize, useFileUpload };
@@ -0,0 +1,2 @@
1
+ import { FileUpload, FileUploadDropzone, FileUploadDropzoneProps, FileUploadDropzoneVariant, FileUploadDropzoneVariantsOptions, FileUploadHandle, FileUploadItem, FileUploadItemProps, FileUploadItemStatus, FileUploadList, FileUploadListProps, FileUploadProps, FileUploadRejection, FileUploadRejectionCode, FileUploadRenderState, FileUploadTrigger, FileUploadTriggerProps, fileUploadDropzoneVariants, formatFileSize, useFileUpload } from "./FileUpload.js";
2
+ export { FileUpload, FileUploadDropzone, type FileUploadDropzoneProps, type FileUploadDropzoneVariant, type FileUploadDropzoneVariantsOptions, type FileUploadHandle, FileUploadItem, type FileUploadItemProps, type FileUploadItemStatus, FileUploadList, type FileUploadListProps, type FileUploadProps, type FileUploadRejection, type FileUploadRejectionCode, type FileUploadRenderState, FileUploadTrigger, type FileUploadTriggerProps, fileUploadDropzoneVariants, formatFileSize, useFileUpload };
@@ -0,0 +1,2 @@
1
+ import { FileUpload, FileUploadDropzone, FileUploadItem, FileUploadList, FileUploadTrigger, fileUploadDropzoneVariants, formatFileSize, useFileUpload } from "./FileUpload.js";
2
+ export { FileUpload, FileUploadDropzone, FileUploadItem, FileUploadList, FileUploadTrigger, fileUploadDropzoneVariants, formatFileSize, useFileUpload };
@@ -1,6 +1,6 @@
1
1
  import { cn } from "../../lib/cn.js";
2
2
  import { createContext, forwardRef, useContext, useEffect, useMemo, useState } from "react";
3
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
3
+ import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
4
4
  import { useRender } from "@base-ui/react/use-render";
5
5
  //#region src/components/Stepper/Stepper.tsx
6
6
  function CheckIcon(props) {
@@ -272,7 +272,7 @@ const StepperIndicator = forwardRef(({ children, render, className, ...rest }, r
272
272
  props: {
273
273
  ...stepStateAttributes(item, orientation),
274
274
  ...rest,
275
- children: /* @__PURE__ */ jsxs(Fragment, { children: [children ?? glyph, statusLabel != null && /* @__PURE__ */ jsx("span", {
275
+ children: /* @__PURE__ */ jsxs(Fragment$1, { children: [children ?? glyph, statusLabel != null && /* @__PURE__ */ jsx("span", {
276
276
  className: "sr-only",
277
277
  children: statusLabel
278
278
  })] }),
@@ -1,6 +1,6 @@
1
1
  import { cn } from "../../lib/cn.js";
2
2
  import { forwardRef, useId } from "react";
3
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
3
+ import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
4
4
  import { Switch } from "@base-ui/react/switch";
5
5
  //#region src/components/Switch/Switch.tsx
6
6
  const trackClasses = "inline-flex shrink-0 cursor-pointer select-none items-center rounded-full border border-border bg-muted p-px transition-colors duration-150 hover:border-slate-300 hover:bg-slate-200 data-checked:border-primary data-checked:bg-primary hover:data-checked:border-primary-700 hover:data-checked:bg-primary-700 focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-ring aria-invalid:border-destructive data-invalid:border-destructive aria-invalid:focus-visible:outline-destructive data-invalid:focus-visible:outline-destructive data-readonly:cursor-default disabled:pointer-events-none disabled:opacity-50 data-disabled:pointer-events-none data-disabled:opacity-50";
@@ -74,7 +74,7 @@ const Switch$1 = forwardRef(({ size = "md", label, description, labelPosition =
74
74
  className: cn("inline-flex max-w-full flex-col gap-1 font-sans", "has-data-disabled:pointer-events-none has-data-disabled:opacity-50"),
75
75
  children: [hasLabel ? /* @__PURE__ */ jsx("label", {
76
76
  className: cn("inline-flex cursor-pointer items-start gap-2", "has-data-readonly:cursor-default", labelPosition === "start" && "justify-between"),
77
- children: labelPosition === "start" ? /* @__PURE__ */ jsxs(Fragment, { children: [labelText, control] }) : /* @__PURE__ */ jsxs(Fragment, { children: [control, labelText] })
77
+ children: labelPosition === "start" ? /* @__PURE__ */ jsxs(Fragment$1, { children: [labelText, control] }) : /* @__PURE__ */ jsxs(Fragment$1, { children: [control, labelText] })
78
78
  }) : control, description != null && /* @__PURE__ */ jsx("span", {
79
79
  id: descriptionId,
80
80
  className: cn("text-muted-foreground", descriptionTextClasses[size], labelPosition === "end" && descriptionIndentClasses[size]),
@@ -1,7 +1,7 @@
1
1
  import { ComponentPropsWithoutRef, ReactNode } from "react";
2
2
  import { useRender } from "@base-ui/react/use-render";
3
3
  //#region src/components/SystemState/SystemState.d.ts
4
- type SystemStateVariant = "first-use" | "empty" | "no-results" | "completed" | "setup-required" | "sign-in-required" | "access-denied" | "feature-locked" | "unsupported" | "not-found" | "resource-unavailable" | "conflict" | "offline" | "network-error" | "timeout" | "rate-limited" | "maintenance" | "service-unavailable" | "server-error";
4
+ type SystemStateVariant = "first-use" | "empty" | "no-results" | "completed" | "upload" | "upload-error" | "setup-required" | "sign-in-required" | "access-denied" | "feature-locked" | "unsupported" | "not-found" | "resource-unavailable" | "conflict" | "offline" | "network-error" | "timeout" | "rate-limited" | "maintenance" | "service-unavailable" | "server-error";
5
5
  type SystemStateScope = "inline" | "full";
6
6
  type SystemStateBackground = "transparent" | "background" | "surface" | "muted";
7
7
  type SystemStateTitleLevel = 1 | 2 | 3 | 4 | 5 | 6;
@@ -62,8 +62,9 @@ interface SystemStateProps extends Omit<ComponentPropsWithoutRef<"div">, "classN
62
62
  className?: string;
63
63
  }
64
64
  /**
65
- * Communicates a non-ideal or milestone state — empty, error, restricted, or
66
- * completed — with a brand illustration, copy, and optional recovery actions.
65
+ * Communicates a non-ideal or milestone state — empty, error, restricted,
66
+ * completed, or a file-upload prompt — with a brand illustration, copy, and
67
+ * optional recovery actions.
67
68
  */
68
69
  declare const SystemState: import("react").ForwardRefExoticComponent<SystemStateProps & import("react").RefAttributes<HTMLDivElement>>;
69
70
  //#endregion
@@ -1,6 +1,6 @@
1
1
  import { cn } from "../../lib/cn.js";
2
2
  import { forwardRef } from "react";
3
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
3
+ import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
4
4
  import { useRender } from "@base-ui/react/use-render";
5
5
  import accessDeniedImage from "../../assets/system-states/access-denied.png";
6
6
  import completedImage from "../../assets/system-states/completed.png";
@@ -32,6 +32,16 @@ const variantDefaults = {
32
32
  title: "All done",
33
33
  description: "Everything here is taken care of. Nice work."
34
34
  },
35
+ upload: {
36
+ image: firstUseImage,
37
+ title: "Drag and drop files here",
38
+ description: "or browse to choose files from your device."
39
+ },
40
+ "upload-error": {
41
+ image: setupRequiredImage,
42
+ title: "Upload failed",
43
+ description: "Something went wrong while uploading. Check your files and try again."
44
+ },
35
45
  "setup-required": {
36
46
  image: setupRequiredImage,
37
47
  title: "Finish setting up",
@@ -132,8 +142,9 @@ const descriptionClasses = {
132
142
  full: "font-sans text-base text-muted-foreground"
133
143
  };
134
144
  /**
135
- * Communicates a non-ideal or milestone state — empty, error, restricted, or
136
- * completed — with a brand illustration, copy, and optional recovery actions.
145
+ * Communicates a non-ideal or milestone state — empty, error, restricted,
146
+ * completed, or a file-upload prompt — with a brand illustration, copy, and
147
+ * optional recovery actions.
137
148
  */
138
149
  const SystemState = forwardRef(({ variant, title, description, action, secondaryAction, scope = "inline", bg = "transparent", titleLevel, render, className, ...rest }, ref) => {
139
150
  const defaults = variantDefaults[variant];
@@ -153,7 +164,7 @@ const SystemState = forwardRef(({ variant, title, description, action, secondary
153
164
  },
154
165
  props: {
155
166
  className: cn(rootClasses, scopeClasses[scope], backgroundClasses[bg], className),
156
- children: /* @__PURE__ */ jsxs(Fragment, { children: [
167
+ children: /* @__PURE__ */ jsxs(Fragment$1, { children: [
157
168
  /* @__PURE__ */ jsx("img", {
158
169
  src: defaults.image,
159
170
  alt: "",
package/dist/index.d.ts CHANGED
@@ -46,6 +46,8 @@ import { FieldControlProps, useFieldControl } from "./components/Field/FieldCont
46
46
  import "./components/Field/index.js";
47
47
  import { Fieldset, FieldsetDescription, FieldsetDescriptionProps, FieldsetLegend, FieldsetLegendProps, FieldsetLegendVariant, FieldsetProps } from "./components/Fieldset/Fieldset.js";
48
48
  import "./components/Fieldset/index.js";
49
+ import { FileUpload, FileUploadDropzone, FileUploadDropzoneProps, FileUploadDropzoneVariant, FileUploadDropzoneVariantsOptions, FileUploadHandle, FileUploadItem, FileUploadItemProps, FileUploadItemStatus, FileUploadList, FileUploadListProps, FileUploadProps, FileUploadRejection, FileUploadRejectionCode, FileUploadRenderState, FileUploadTrigger, FileUploadTriggerProps, fileUploadDropzoneVariants, formatFileSize, useFileUpload } from "./components/FileUpload/FileUpload.js";
50
+ import "./components/FileUpload/index.js";
49
51
  import { Form, FormProps } from "./components/Form/Form.js";
50
52
  import "./components/Form/index.js";
51
53
  import { Input, InputGroup, InputGroupAddon, InputGroupAddonProps, InputGroupProps, InputProps, InputSize, InputVariantsOptions, inputVariants } from "./components/Input/Input.js";
@@ -80,4 +82,4 @@ import "./components/Tooltip/index.js";
80
82
  import { Typography, TypographyProps, TypographyVariant, TypographyVariantsOptions, typographyVariants } from "./components/Typography/Typography.js";
81
83
  import "./components/Typography/index.js";
82
84
  import { cn } from "./lib/cn.js";
83
- export { AILoader, type AILoaderProps, type AILoaderRenderState, type AILoaderSize, type AILoaderState, type AILoaderTone, Accordion, type AccordionChevronPosition, AccordionHeader, type AccordionHeaderProps, AccordionItem, type AccordionItemProps, AccordionPanel, type AccordionPanelProps, type AccordionProps, type AccordionSize, AccordionTrigger, type AccordionTriggerProps, type AccordionVariant, Alert, type AlertAppearance, AlertDialog, AlertDialogAction, type AlertDialogActionProps, AlertDialogCancel, type AlertDialogCancelProps, AlertDialogDescription, type AlertDialogDescriptionProps, AlertDialogFooter, type AlertDialogFooterProps, AlertDialogHeader, type AlertDialogHeaderProps, AlertDialogPopup, type AlertDialogPopupProps, type AlertDialogPopupVariantsOptions, type AlertDialogProps, type AlertDialogScrollBehavior, type AlertDialogSize, AlertDialogTitle, type AlertDialogTitleProps, AlertDialogTrigger, type AlertDialogTriggerProps, type AlertProps, type AlertVariant, type AlertVariantsOptions, Avatar, AvatarBadge, type AvatarBadgeProps, AvatarFallback, type AvatarFallbackProps, AvatarGroup, type AvatarGroupProps, AvatarImage, type AvatarImageProps, type AvatarProps, type AvatarShape, type AvatarSize, type AvatarVariantsOptions, Badge, type BadgeAppearance, type BadgeProps, type BadgeSize, type BadgeVariant, type BadgeVariantsOptions, Box, type BoxBackground, type BoxPadding, type BoxProps, type BoxRadius, type BoxShadow, type BoxVariantsOptions, Breadcrumb, BreadcrumbEllipsis, type BreadcrumbEllipsisProps, BreadcrumbItem, type BreadcrumbItemProps, BreadcrumbLink, type BreadcrumbLinkProps, type BreadcrumbLinkVariantsOptions, BreadcrumbList, type BreadcrumbListProps, BreadcrumbPage, type BreadcrumbPageProps, type BreadcrumbProps, BreadcrumbSeparator, type BreadcrumbSeparatorProps, Button, type ButtonProps, type ButtonSize, type ButtonVariant, type ButtonVariantsOptions, Calendar, type CalendarDateRange, type CalendarMode, type CalendarProps, type CalendarState, Checkbox, CheckboxGroup, type CheckboxGroupProps, type CheckboxProps, type CheckboxSize, type CheckboxVariantsOptions, CodeBlock, type CodeBlockProps, type CodeBlockVariantsOptions, Combobox, type ComboboxAlign, ComboboxChip, type ComboboxChipProps, ComboboxChipRemove, type ComboboxChipRemoveProps, ComboboxChips, type ComboboxChipsProps, ComboboxClear, type ComboboxClearProps, ComboboxCollection, type ComboboxCollectionProps, ComboboxGroup, ComboboxGroupLabel, type ComboboxGroupLabelProps, type ComboboxGroupProps, ComboboxInput, ComboboxInputGroup, type ComboboxInputGroupProps, type ComboboxInputGroupVariantsOptions, type ComboboxInputProps, ComboboxItem, type ComboboxItemProps, ComboboxLabel, type ComboboxLabelProps, ComboboxPopup, type ComboboxPopupProps, type ComboboxProps, ComboboxSeparator, type ComboboxSeparatorProps, type ComboboxSize, ComboboxTrigger, type ComboboxTriggerProps, type ComboboxTriggerSize, type ComboboxTriggerVariant, ComboboxValue, type ComboboxValueProps, ContextMenu, type ContextMenuAlign, ContextMenuCheckboxItem, type ContextMenuCheckboxItemProps, ContextMenuGroup, ContextMenuGroupLabel, type ContextMenuGroupLabelProps, type ContextMenuGroupProps, ContextMenuItem, type ContextMenuItemProps, type ContextMenuItemVariant, ContextMenuLinkItem, type ContextMenuLinkItemProps, ContextMenuPopup, type ContextMenuPopupProps, type ContextMenuProps, ContextMenuRadioGroup, type ContextMenuRadioGroupProps, ContextMenuRadioItem, type ContextMenuRadioItemProps, ContextMenuSeparator, type ContextMenuSeparatorProps, ContextMenuShortcut, type ContextMenuShortcutProps, type ContextMenuSide, ContextMenuSubmenuRoot, type ContextMenuSubmenuRootProps, ContextMenuSubmenuTrigger, type ContextMenuSubmenuTriggerProps, ContextMenuTrigger, type ContextMenuTriggerProps, DatePicker, type DatePickerCalendarProps, type DatePickerPopupProps, type DatePickerProps, type DatePickerSize, type DatePickerVariant, type DatePickerVariantsOptions, DateRangePicker, type DateRangePickerCalendarProps, type DateRangePickerPopupProps, type DateRangePickerProps, type DateRangePickerSize, type DateRangePickerVariant, type DateRangePickerVariantsOptions, Dialog, DialogClose, type DialogCloseProps, DialogDescription, type DialogDescriptionProps, DialogFooter, type DialogFooterProps, DialogHeader, type DialogHeaderProps, DialogPopup, type DialogPopupProps, type DialogPopupVariantsOptions, type DialogProps, type DialogScrollBehavior, type DialogSize, DialogTitle, type DialogTitleProps, DialogTrigger, type DialogTriggerProps, Divider, type DividerLabelPosition, type DividerOrientation, type DividerProps, type DividerVariant, type DividerVariantsOptions, Drawer, DrawerClose, type DrawerCloseProps, DrawerDescription, type DrawerDescriptionProps, DrawerFooter, type DrawerFooterProps, DrawerHeader, type DrawerHeaderProps, DrawerIndent, DrawerIndentBackground, type DrawerIndentBackgroundProps, type DrawerIndentProps, DrawerPopup, type DrawerPopupProps, type DrawerPopupVariantsOptions, type DrawerProps, DrawerProvider, type DrawerSide, type DrawerSize, DrawerSwipeArea, type DrawerSwipeAreaProps, DrawerTitle, type DrawerTitleProps, DrawerTrigger, type DrawerTriggerProps, DrawerVirtualKeyboardProvider, Field, type FieldControlProps, FieldDescription, type FieldDescriptionProps, FieldError, type FieldErrorProps, FieldItem, type FieldItemProps, FieldLabel, type FieldLabelProps, type FieldLabelVariantsOptions, type FieldOrientation, type FieldProps, FieldValidity, type FieldValidityProps, Fieldset, FieldsetDescription, type FieldsetDescriptionProps, FieldsetLegend, type FieldsetLegendProps, type FieldsetLegendVariant, type FieldsetProps, Form, type FormProps, Input, InputGroup, InputGroupAddon, type InputGroupAddonProps, type InputGroupProps, type InputProps, type InputSize, type InputVariantsOptions, Menu, type MenuAlign, MenuCheckboxItem, type MenuCheckboxItemProps, MenuGroup, MenuGroupLabel, type MenuGroupLabelProps, type MenuGroupProps, type MenuHandle, MenuItem, type MenuItemProps, type MenuItemVariant, type MenuItemVariantsOptions, MenuLinkItem, type MenuLinkItemProps, MenuPopup, type MenuPopupProps, type MenuProps, MenuRadioGroup, type MenuRadioGroupProps, MenuRadioItem, type MenuRadioItemProps, MenuSeparator, type MenuSeparatorProps, MenuShortcut, type MenuShortcutProps, type MenuSide, MenuSubmenuRoot, type MenuSubmenuRootProps, MenuSubmenuTrigger, type MenuSubmenuTriggerProps, MenuTrigger, type MenuTriggerProps, Meter, type MeterIndicatorVariantsOptions, type MeterProps, type MeterSize, type MeterTrackVariantsOptions, type MeterVariant, Popover, type PopoverAlign, PopoverClose, type PopoverCloseProps, PopoverDescription, type PopoverDescriptionProps, type PopoverHandle, PopoverPopup, type PopoverPopupProps, type PopoverPopupVariantsOptions, type PopoverProps, type PopoverSide, PopoverTitle, type PopoverTitleProps, PopoverTrigger, type PopoverTriggerProps, Progress, type ProgressIndicatorVariantsOptions, type ProgressProps, type ProgressSize, type ProgressTrackVariantsOptions, type ProgressVariant, Radio, RadioGroup, type RadioGroupProps, type RadioProps, type RadioSize, type RadioVariantsOptions, Select, type SelectAlign, SelectGroup, SelectGroupLabel, type SelectGroupLabelProps, type SelectGroupProps, SelectItem, type SelectItemProps, SelectLabel, type SelectLabelProps, SelectPopup, type SelectPopupProps, type SelectProps, SelectSeparator, type SelectSeparatorProps, SelectTrigger, type SelectTriggerProps, type SelectTriggerSize, type SelectTriggerVariant, type SelectTriggerVariantsOptions, SelectValue, type SelectValueProps, Skeleton, type SkeletonAnimation, type SkeletonProps, type SkeletonRenderState, type SkeletonVariant, type SkeletonVariantsOptions, Stepper, StepperDescription, type StepperDescriptionProps, StepperIndicator, type StepperIndicatorProps, StepperItem, type StepperItemProps, type StepperOrientation, type StepperProps, StepperSeparator, type StepperSeparatorProps, type StepperSize, StepperTitle, type StepperTitleProps, StepperTrigger, type StepperTriggerProps, type StepperTriggerVariantsOptions, Switch, type SwitchLabelPosition, type SwitchProps, type SwitchSize, type SwitchVariantsOptions, SystemState, type SystemStateBackground, type SystemStateProps, type SystemStateRenderState, type SystemStateScope, type SystemStateTitleLevel, type SystemStateVariant, Table, TableBody, type TableBodyProps, TableCaption, type TableCaptionProps, type TableCaptionRenderState, type TableCaptionSide, TableCell, type TableCellProps, TableContainer, type TableContainerProps, type TableContainerRenderState, type TableContainerVariant, TableFooter, type TableFooterProps, TableHead, type TableHeadProps, TableHeader, type TableHeaderProps, type TableLayout, type TableProps, type TableRenderState, TableRow, type TableRowProps, type TableRowRenderState, type TableSize, Tabs, type TabsIndicatorPosition, TabsList, type TabsListProps, type TabsListVariantsOptions, TabsPanel, type TabsPanelProps, type TabsProps, type TabsSize, TabsTab, type TabsTabProps, type TabsTabVariantsOptions, type TabsVariant, Timeline, TimelineConnector, type TimelineConnectorProps, TimelineContent, type TimelineContentProps, TimelineDescription, type TimelineDescriptionProps, TimelineIndicator, type TimelineIndicatorAppearance, type TimelineIndicatorProps, type TimelineIndicatorVariant, TimelineItem, type TimelineItemProps, type TimelineProps, TimelineSeparator, type TimelineSeparatorProps, type TimelineSeparatorVariant, type TimelineSize, TimelineTime, type TimelineTimeProps, TimelineTitle, type TimelineTitleProps, type ToastData, type ToastManager, type ToastObject, type ToastOptions, type ToastPosition, type ToastPromiseOptions, type ToastType, type ToastUpdateOptions, Toaster, type ToasterProps, Toggle, ToggleGroup, type ToggleGroupProps, type ToggleProps, type ToggleSize, type ToggleVariant, type ToggleVariantsOptions, Tooltip, type TooltipAlign, type TooltipHandle, TooltipPopup, type TooltipPopupProps, type TooltipPopupVariantsOptions, type TooltipProps, TooltipProvider, type TooltipProviderProps, type TooltipSide, TooltipTrigger, type TooltipTriggerProps, Typography, type TypographyProps, type TypographyVariant, type TypographyVariantsOptions, alertDialogPopupVariants, alertVariants, avatarVariants, badgeVariants, boxVariants, breadcrumbLinkVariants, buttonVariants, checkboxVariants, cn, codeBlockVariants, comboboxInputGroupVariants, createAlertDialogHandle, createDrawerHandle, createMenuHandle, createPopoverHandle, createToastManager, createTooltipHandle, datePickerVariants, dateRangePickerVariants, dialogPopupVariants, dividerVariants, drawerPopupVariants, fieldLabelVariants, inputVariants, menuItemVariants, meterIndicatorVariants, meterTrackVariants, popoverPopupVariants, progressIndicatorVariants, progressTrackVariants, radioVariants, selectTriggerVariants, skeletonVariants, stepperTriggerVariants, switchVariants, tabsListVariants, tabsTabVariants, toast, toggleVariants, tooltipPopupVariants, typographyVariants, useComboboxFilter, useComboboxFilteredItems, useFieldControl };
85
+ export { AILoader, type AILoaderProps, type AILoaderRenderState, type AILoaderSize, type AILoaderState, type AILoaderTone, Accordion, type AccordionChevronPosition, AccordionHeader, type AccordionHeaderProps, AccordionItem, type AccordionItemProps, AccordionPanel, type AccordionPanelProps, type AccordionProps, type AccordionSize, AccordionTrigger, type AccordionTriggerProps, type AccordionVariant, Alert, type AlertAppearance, AlertDialog, AlertDialogAction, type AlertDialogActionProps, AlertDialogCancel, type AlertDialogCancelProps, AlertDialogDescription, type AlertDialogDescriptionProps, AlertDialogFooter, type AlertDialogFooterProps, AlertDialogHeader, type AlertDialogHeaderProps, AlertDialogPopup, type AlertDialogPopupProps, type AlertDialogPopupVariantsOptions, type AlertDialogProps, type AlertDialogScrollBehavior, type AlertDialogSize, AlertDialogTitle, type AlertDialogTitleProps, AlertDialogTrigger, type AlertDialogTriggerProps, type AlertProps, type AlertVariant, type AlertVariantsOptions, Avatar, AvatarBadge, type AvatarBadgeProps, AvatarFallback, type AvatarFallbackProps, AvatarGroup, type AvatarGroupProps, AvatarImage, type AvatarImageProps, type AvatarProps, type AvatarShape, type AvatarSize, type AvatarVariantsOptions, Badge, type BadgeAppearance, type BadgeProps, type BadgeSize, type BadgeVariant, type BadgeVariantsOptions, Box, type BoxBackground, type BoxPadding, type BoxProps, type BoxRadius, type BoxShadow, type BoxVariantsOptions, Breadcrumb, BreadcrumbEllipsis, type BreadcrumbEllipsisProps, BreadcrumbItem, type BreadcrumbItemProps, BreadcrumbLink, type BreadcrumbLinkProps, type BreadcrumbLinkVariantsOptions, BreadcrumbList, type BreadcrumbListProps, BreadcrumbPage, type BreadcrumbPageProps, type BreadcrumbProps, BreadcrumbSeparator, type BreadcrumbSeparatorProps, Button, type ButtonProps, type ButtonSize, type ButtonVariant, type ButtonVariantsOptions, Calendar, type CalendarDateRange, type CalendarMode, type CalendarProps, type CalendarState, Checkbox, CheckboxGroup, type CheckboxGroupProps, type CheckboxProps, type CheckboxSize, type CheckboxVariantsOptions, CodeBlock, type CodeBlockProps, type CodeBlockVariantsOptions, Combobox, type ComboboxAlign, ComboboxChip, type ComboboxChipProps, ComboboxChipRemove, type ComboboxChipRemoveProps, ComboboxChips, type ComboboxChipsProps, ComboboxClear, type ComboboxClearProps, ComboboxCollection, type ComboboxCollectionProps, ComboboxGroup, ComboboxGroupLabel, type ComboboxGroupLabelProps, type ComboboxGroupProps, ComboboxInput, ComboboxInputGroup, type ComboboxInputGroupProps, type ComboboxInputGroupVariantsOptions, type ComboboxInputProps, ComboboxItem, type ComboboxItemProps, ComboboxLabel, type ComboboxLabelProps, ComboboxPopup, type ComboboxPopupProps, type ComboboxProps, ComboboxSeparator, type ComboboxSeparatorProps, type ComboboxSize, ComboboxTrigger, type ComboboxTriggerProps, type ComboboxTriggerSize, type ComboboxTriggerVariant, ComboboxValue, type ComboboxValueProps, ContextMenu, type ContextMenuAlign, ContextMenuCheckboxItem, type ContextMenuCheckboxItemProps, ContextMenuGroup, ContextMenuGroupLabel, type ContextMenuGroupLabelProps, type ContextMenuGroupProps, ContextMenuItem, type ContextMenuItemProps, type ContextMenuItemVariant, ContextMenuLinkItem, type ContextMenuLinkItemProps, ContextMenuPopup, type ContextMenuPopupProps, type ContextMenuProps, ContextMenuRadioGroup, type ContextMenuRadioGroupProps, ContextMenuRadioItem, type ContextMenuRadioItemProps, ContextMenuSeparator, type ContextMenuSeparatorProps, ContextMenuShortcut, type ContextMenuShortcutProps, type ContextMenuSide, ContextMenuSubmenuRoot, type ContextMenuSubmenuRootProps, ContextMenuSubmenuTrigger, type ContextMenuSubmenuTriggerProps, ContextMenuTrigger, type ContextMenuTriggerProps, DatePicker, type DatePickerCalendarProps, type DatePickerPopupProps, type DatePickerProps, type DatePickerSize, type DatePickerVariant, type DatePickerVariantsOptions, DateRangePicker, type DateRangePickerCalendarProps, type DateRangePickerPopupProps, type DateRangePickerProps, type DateRangePickerSize, type DateRangePickerVariant, type DateRangePickerVariantsOptions, Dialog, DialogClose, type DialogCloseProps, DialogDescription, type DialogDescriptionProps, DialogFooter, type DialogFooterProps, DialogHeader, type DialogHeaderProps, DialogPopup, type DialogPopupProps, type DialogPopupVariantsOptions, type DialogProps, type DialogScrollBehavior, type DialogSize, DialogTitle, type DialogTitleProps, DialogTrigger, type DialogTriggerProps, Divider, type DividerLabelPosition, type DividerOrientation, type DividerProps, type DividerVariant, type DividerVariantsOptions, Drawer, DrawerClose, type DrawerCloseProps, DrawerDescription, type DrawerDescriptionProps, DrawerFooter, type DrawerFooterProps, DrawerHeader, type DrawerHeaderProps, DrawerIndent, DrawerIndentBackground, type DrawerIndentBackgroundProps, type DrawerIndentProps, DrawerPopup, type DrawerPopupProps, type DrawerPopupVariantsOptions, type DrawerProps, DrawerProvider, type DrawerSide, type DrawerSize, DrawerSwipeArea, type DrawerSwipeAreaProps, DrawerTitle, type DrawerTitleProps, DrawerTrigger, type DrawerTriggerProps, DrawerVirtualKeyboardProvider, Field, type FieldControlProps, FieldDescription, type FieldDescriptionProps, FieldError, type FieldErrorProps, FieldItem, type FieldItemProps, FieldLabel, type FieldLabelProps, type FieldLabelVariantsOptions, type FieldOrientation, type FieldProps, FieldValidity, type FieldValidityProps, Fieldset, FieldsetDescription, type FieldsetDescriptionProps, FieldsetLegend, type FieldsetLegendProps, type FieldsetLegendVariant, type FieldsetProps, FileUpload, FileUploadDropzone, type FileUploadDropzoneProps, type FileUploadDropzoneVariant, type FileUploadDropzoneVariantsOptions, type FileUploadHandle, FileUploadItem, type FileUploadItemProps, type FileUploadItemStatus, FileUploadList, type FileUploadListProps, type FileUploadProps, type FileUploadRejection, type FileUploadRejectionCode, type FileUploadRenderState, FileUploadTrigger, type FileUploadTriggerProps, Form, type FormProps, Input, InputGroup, InputGroupAddon, type InputGroupAddonProps, type InputGroupProps, type InputProps, type InputSize, type InputVariantsOptions, Menu, type MenuAlign, MenuCheckboxItem, type MenuCheckboxItemProps, MenuGroup, MenuGroupLabel, type MenuGroupLabelProps, type MenuGroupProps, type MenuHandle, MenuItem, type MenuItemProps, type MenuItemVariant, type MenuItemVariantsOptions, MenuLinkItem, type MenuLinkItemProps, MenuPopup, type MenuPopupProps, type MenuProps, MenuRadioGroup, type MenuRadioGroupProps, MenuRadioItem, type MenuRadioItemProps, MenuSeparator, type MenuSeparatorProps, MenuShortcut, type MenuShortcutProps, type MenuSide, MenuSubmenuRoot, type MenuSubmenuRootProps, MenuSubmenuTrigger, type MenuSubmenuTriggerProps, MenuTrigger, type MenuTriggerProps, Meter, type MeterIndicatorVariantsOptions, type MeterProps, type MeterSize, type MeterTrackVariantsOptions, type MeterVariant, Popover, type PopoverAlign, PopoverClose, type PopoverCloseProps, PopoverDescription, type PopoverDescriptionProps, type PopoverHandle, PopoverPopup, type PopoverPopupProps, type PopoverPopupVariantsOptions, type PopoverProps, type PopoverSide, PopoverTitle, type PopoverTitleProps, PopoverTrigger, type PopoverTriggerProps, Progress, type ProgressIndicatorVariantsOptions, type ProgressProps, type ProgressSize, type ProgressTrackVariantsOptions, type ProgressVariant, Radio, RadioGroup, type RadioGroupProps, type RadioProps, type RadioSize, type RadioVariantsOptions, Select, type SelectAlign, SelectGroup, SelectGroupLabel, type SelectGroupLabelProps, type SelectGroupProps, SelectItem, type SelectItemProps, SelectLabel, type SelectLabelProps, SelectPopup, type SelectPopupProps, type SelectProps, SelectSeparator, type SelectSeparatorProps, SelectTrigger, type SelectTriggerProps, type SelectTriggerSize, type SelectTriggerVariant, type SelectTriggerVariantsOptions, SelectValue, type SelectValueProps, Skeleton, type SkeletonAnimation, type SkeletonProps, type SkeletonRenderState, type SkeletonVariant, type SkeletonVariantsOptions, Stepper, StepperDescription, type StepperDescriptionProps, StepperIndicator, type StepperIndicatorProps, StepperItem, type StepperItemProps, type StepperOrientation, type StepperProps, StepperSeparator, type StepperSeparatorProps, type StepperSize, StepperTitle, type StepperTitleProps, StepperTrigger, type StepperTriggerProps, type StepperTriggerVariantsOptions, Switch, type SwitchLabelPosition, type SwitchProps, type SwitchSize, type SwitchVariantsOptions, SystemState, type SystemStateBackground, type SystemStateProps, type SystemStateRenderState, type SystemStateScope, type SystemStateTitleLevel, type SystemStateVariant, Table, TableBody, type TableBodyProps, TableCaption, type TableCaptionProps, type TableCaptionRenderState, type TableCaptionSide, TableCell, type TableCellProps, TableContainer, type TableContainerProps, type TableContainerRenderState, type TableContainerVariant, TableFooter, type TableFooterProps, TableHead, type TableHeadProps, TableHeader, type TableHeaderProps, type TableLayout, type TableProps, type TableRenderState, TableRow, type TableRowProps, type TableRowRenderState, type TableSize, Tabs, type TabsIndicatorPosition, TabsList, type TabsListProps, type TabsListVariantsOptions, TabsPanel, type TabsPanelProps, type TabsProps, type TabsSize, TabsTab, type TabsTabProps, type TabsTabVariantsOptions, type TabsVariant, Timeline, TimelineConnector, type TimelineConnectorProps, TimelineContent, type TimelineContentProps, TimelineDescription, type TimelineDescriptionProps, TimelineIndicator, type TimelineIndicatorAppearance, type TimelineIndicatorProps, type TimelineIndicatorVariant, TimelineItem, type TimelineItemProps, type TimelineProps, TimelineSeparator, type TimelineSeparatorProps, type TimelineSeparatorVariant, type TimelineSize, TimelineTime, type TimelineTimeProps, TimelineTitle, type TimelineTitleProps, type ToastData, type ToastManager, type ToastObject, type ToastOptions, type ToastPosition, type ToastPromiseOptions, type ToastType, type ToastUpdateOptions, Toaster, type ToasterProps, Toggle, ToggleGroup, type ToggleGroupProps, type ToggleProps, type ToggleSize, type ToggleVariant, type ToggleVariantsOptions, Tooltip, type TooltipAlign, type TooltipHandle, TooltipPopup, type TooltipPopupProps, type TooltipPopupVariantsOptions, type TooltipProps, TooltipProvider, type TooltipProviderProps, type TooltipSide, TooltipTrigger, type TooltipTriggerProps, Typography, type TypographyProps, type TypographyVariant, type TypographyVariantsOptions, alertDialogPopupVariants, alertVariants, avatarVariants, badgeVariants, boxVariants, breadcrumbLinkVariants, buttonVariants, checkboxVariants, cn, codeBlockVariants, comboboxInputGroupVariants, createAlertDialogHandle, createDrawerHandle, createMenuHandle, createPopoverHandle, createToastManager, createTooltipHandle, datePickerVariants, dateRangePickerVariants, dialogPopupVariants, dividerVariants, drawerPopupVariants, fieldLabelVariants, fileUploadDropzoneVariants, formatFileSize, inputVariants, menuItemVariants, meterIndicatorVariants, meterTrackVariants, popoverPopupVariants, progressIndicatorVariants, progressTrackVariants, radioVariants, selectTriggerVariants, skeletonVariants, stepperTriggerVariants, switchVariants, tabsListVariants, tabsTabVariants, toast, toggleVariants, tooltipPopupVariants, typographyVariants, useComboboxFilter, useComboboxFilteredItems, useFieldControl, useFileUpload };
package/dist/index.js CHANGED
@@ -25,14 +25,15 @@ import { Divider, dividerVariants } from "./components/Divider/Divider.js";
25
25
  import { Drawer, DrawerClose, DrawerDescription, DrawerFooter, DrawerHeader, DrawerIndent, DrawerIndentBackground, DrawerPopup, DrawerProvider, DrawerSwipeArea, DrawerTitle, DrawerTrigger, DrawerVirtualKeyboardProvider, createDrawerHandle, drawerPopupVariants } from "./components/Drawer/Drawer.js";
26
26
  import { Field, FieldDescription, FieldError, FieldItem, FieldLabel, FieldValidity, fieldLabelVariants } from "./components/Field/Field.js";
27
27
  import { Fieldset, FieldsetDescription, FieldsetLegend } from "./components/Fieldset/Fieldset.js";
28
+ import { Progress, progressIndicatorVariants, progressTrackVariants } from "./components/Progress/Progress.js";
29
+ import { SystemState } from "./components/SystemState/SystemState.js";
30
+ import { FileUpload, FileUploadDropzone, FileUploadItem, FileUploadList, FileUploadTrigger, fileUploadDropzoneVariants, formatFileSize, useFileUpload } from "./components/FileUpload/FileUpload.js";
28
31
  import { Form } from "./components/Form/Form.js";
29
32
  import { Meter, meterIndicatorVariants, meterTrackVariants } from "./components/Meter/Meter.js";
30
- import { Progress, progressIndicatorVariants, progressTrackVariants } from "./components/Progress/Progress.js";
31
33
  import { Radio, RadioGroup, radioVariants } from "./components/Radio/Radio.js";
32
34
  import { Skeleton, skeletonVariants } from "./components/Skeleton/Skeleton.js";
33
35
  import { Stepper, StepperDescription, StepperIndicator, StepperItem, StepperSeparator, StepperTitle, StepperTrigger, stepperTriggerVariants } from "./components/Stepper/Stepper.js";
34
36
  import { Switch, switchVariants } from "./components/Switch/Switch.js";
35
- import { SystemState } from "./components/SystemState/SystemState.js";
36
37
  import { Table, TableBody, TableCaption, TableCell, TableContainer, TableFooter, TableHead, TableHeader, TableRow } from "./components/Table/Table.js";
37
38
  import { Tabs, TabsList, TabsPanel, TabsTab, tabsListVariants, tabsTabVariants } from "./components/Tabs/Tabs.js";
38
39
  import { Timeline, TimelineConnector, TimelineContent, TimelineDescription, TimelineIndicator, TimelineItem, TimelineSeparator, TimelineTime, TimelineTitle } from "./components/Timeline/Timeline.js";
@@ -40,4 +41,4 @@ import { Toaster, createToastManager, toast } from "./components/Toast/Toast.js"
40
41
  import { Toggle, ToggleGroup, toggleVariants } from "./components/Toggle/Toggle.js";
41
42
  import { Tooltip, TooltipPopup, TooltipProvider, TooltipTrigger, createTooltipHandle, tooltipPopupVariants } from "./components/Tooltip/Tooltip.js";
42
43
  import { Typography, typographyVariants } from "./components/Typography/Typography.js";
43
- export { AILoader, Accordion, AccordionHeader, AccordionItem, AccordionPanel, AccordionTrigger, Alert, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogPopup, AlertDialogTitle, AlertDialogTrigger, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarImage, Badge, Box, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button, Calendar, Checkbox, CheckboxGroup, CodeBlock, Combobox, ComboboxChip, ComboboxChipRemove, ComboboxChips, ComboboxClear, ComboboxCollection, ComboboxGroup, ComboboxGroupLabel, ComboboxInput, ComboboxInputGroup, ComboboxItem, ComboboxLabel, ComboboxPopup, ComboboxSeparator, ComboboxTrigger, ComboboxValue, ContextMenu, ContextMenuCheckboxItem, ContextMenuGroup, ContextMenuGroupLabel, ContextMenuItem, ContextMenuLinkItem, ContextMenuPopup, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSubmenuRoot, ContextMenuSubmenuTrigger, ContextMenuTrigger, DatePicker, DateRangePicker, Dialog, DialogClose, DialogDescription, DialogFooter, DialogHeader, DialogPopup, DialogTitle, DialogTrigger, Divider, Drawer, DrawerClose, DrawerDescription, DrawerFooter, DrawerHeader, DrawerIndent, DrawerIndentBackground, DrawerPopup, DrawerProvider, DrawerSwipeArea, DrawerTitle, DrawerTrigger, DrawerVirtualKeyboardProvider, Field, FieldDescription, FieldError, FieldItem, FieldLabel, FieldValidity, Fieldset, FieldsetDescription, FieldsetLegend, Form, Input, InputGroup, InputGroupAddon, Menu, MenuCheckboxItem, MenuGroup, MenuGroupLabel, MenuItem, MenuLinkItem, MenuPopup, MenuRadioGroup, MenuRadioItem, MenuSeparator, MenuShortcut, MenuSubmenuRoot, MenuSubmenuTrigger, MenuTrigger, Meter, Popover, PopoverClose, PopoverDescription, PopoverPopup, PopoverTitle, PopoverTrigger, Progress, Radio, RadioGroup, Select, SelectGroup, SelectGroupLabel, SelectItem, SelectLabel, SelectPopup, SelectSeparator, SelectTrigger, SelectValue, Skeleton, Stepper, StepperDescription, StepperIndicator, StepperItem, StepperSeparator, StepperTitle, StepperTrigger, Switch, SystemState, Table, TableBody, TableCaption, TableCell, TableContainer, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsList, TabsPanel, TabsTab, Timeline, TimelineConnector, TimelineContent, TimelineDescription, TimelineIndicator, TimelineItem, TimelineSeparator, TimelineTime, TimelineTitle, Toaster, Toggle, ToggleGroup, Tooltip, TooltipPopup, TooltipProvider, TooltipTrigger, Typography, alertDialogPopupVariants, alertVariants, avatarVariants, badgeVariants, boxVariants, breadcrumbLinkVariants, buttonVariants, checkboxVariants, cn, codeBlockVariants, comboboxInputGroupVariants, createAlertDialogHandle, createDrawerHandle, createMenuHandle, createPopoverHandle, createToastManager, createTooltipHandle, datePickerVariants, dateRangePickerVariants, dialogPopupVariants, dividerVariants, drawerPopupVariants, fieldLabelVariants, inputVariants, menuItemVariants, meterIndicatorVariants, meterTrackVariants, popoverPopupVariants, progressIndicatorVariants, progressTrackVariants, radioVariants, selectTriggerVariants, skeletonVariants, stepperTriggerVariants, switchVariants, tabsListVariants, tabsTabVariants, toast, toggleVariants, tooltipPopupVariants, typographyVariants, useComboboxFilter, useComboboxFilteredItems, useFieldControl };
44
+ export { AILoader, Accordion, AccordionHeader, AccordionItem, AccordionPanel, AccordionTrigger, Alert, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogPopup, AlertDialogTitle, AlertDialogTrigger, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarImage, Badge, Box, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button, Calendar, Checkbox, CheckboxGroup, CodeBlock, Combobox, ComboboxChip, ComboboxChipRemove, ComboboxChips, ComboboxClear, ComboboxCollection, ComboboxGroup, ComboboxGroupLabel, ComboboxInput, ComboboxInputGroup, ComboboxItem, ComboboxLabel, ComboboxPopup, ComboboxSeparator, ComboboxTrigger, ComboboxValue, ContextMenu, ContextMenuCheckboxItem, ContextMenuGroup, ContextMenuGroupLabel, ContextMenuItem, ContextMenuLinkItem, ContextMenuPopup, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSubmenuRoot, ContextMenuSubmenuTrigger, ContextMenuTrigger, DatePicker, DateRangePicker, Dialog, DialogClose, DialogDescription, DialogFooter, DialogHeader, DialogPopup, DialogTitle, DialogTrigger, Divider, Drawer, DrawerClose, DrawerDescription, DrawerFooter, DrawerHeader, DrawerIndent, DrawerIndentBackground, DrawerPopup, DrawerProvider, DrawerSwipeArea, DrawerTitle, DrawerTrigger, DrawerVirtualKeyboardProvider, Field, FieldDescription, FieldError, FieldItem, FieldLabel, FieldValidity, Fieldset, FieldsetDescription, FieldsetLegend, FileUpload, FileUploadDropzone, FileUploadItem, FileUploadList, FileUploadTrigger, Form, Input, InputGroup, InputGroupAddon, Menu, MenuCheckboxItem, MenuGroup, MenuGroupLabel, MenuItem, MenuLinkItem, MenuPopup, MenuRadioGroup, MenuRadioItem, MenuSeparator, MenuShortcut, MenuSubmenuRoot, MenuSubmenuTrigger, MenuTrigger, Meter, Popover, PopoverClose, PopoverDescription, PopoverPopup, PopoverTitle, PopoverTrigger, Progress, Radio, RadioGroup, Select, SelectGroup, SelectGroupLabel, SelectItem, SelectLabel, SelectPopup, SelectSeparator, SelectTrigger, SelectValue, Skeleton, Stepper, StepperDescription, StepperIndicator, StepperItem, StepperSeparator, StepperTitle, StepperTrigger, Switch, SystemState, Table, TableBody, TableCaption, TableCell, TableContainer, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsList, TabsPanel, TabsTab, Timeline, TimelineConnector, TimelineContent, TimelineDescription, TimelineIndicator, TimelineItem, TimelineSeparator, TimelineTime, TimelineTitle, Toaster, Toggle, ToggleGroup, Tooltip, TooltipPopup, TooltipProvider, TooltipTrigger, Typography, alertDialogPopupVariants, alertVariants, avatarVariants, badgeVariants, boxVariants, breadcrumbLinkVariants, buttonVariants, checkboxVariants, cn, codeBlockVariants, comboboxInputGroupVariants, createAlertDialogHandle, createDrawerHandle, createMenuHandle, createPopoverHandle, createToastManager, createTooltipHandle, datePickerVariants, dateRangePickerVariants, dialogPopupVariants, dividerVariants, drawerPopupVariants, fieldLabelVariants, fileUploadDropzoneVariants, formatFileSize, inputVariants, menuItemVariants, meterIndicatorVariants, meterTrackVariants, popoverPopupVariants, progressIndicatorVariants, progressTrackVariants, radioVariants, selectTriggerVariants, skeletonVariants, stepperTriggerVariants, switchVariants, tabsListVariants, tabsTabVariants, toast, toggleVariants, tooltipPopupVariants, typographyVariants, useComboboxFilter, useComboboxFilteredItems, useFieldControl, useFileUpload };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arcfusionz/arc-primitive-ui",
3
- "version": "0.2.13",
3
+ "version": "0.2.15",
4
4
  "description": "ArcFusion primitive UI components",
5
5
  "license": "MIT",
6
6
  "type": "module",