@alpic-ai/ui 0.0.0-staging.ff03b3f → 0.0.0-staging.g0538916

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (71) hide show
  1. package/dist/components/accordion-card.d.mts +1 -1
  2. package/dist/components/accordion.d.mts +1 -1
  3. package/dist/components/alert.d.mts +1 -1
  4. package/dist/components/attachment-tile.mjs +1 -1
  5. package/dist/components/avatar.d.mts +1 -1
  6. package/dist/components/breadcrumb.d.mts +1 -1
  7. package/dist/components/button.d.mts +1 -1
  8. package/dist/components/card.d.mts +1 -1
  9. package/dist/components/checkbox.d.mts +1 -1
  10. package/dist/components/collapsible.d.mts +1 -1
  11. package/dist/components/combobox.d.mts +3 -1
  12. package/dist/components/combobox.mjs +8 -5
  13. package/dist/components/command.d.mts +1 -1
  14. package/dist/components/copyable.d.mts +1 -1
  15. package/dist/components/copyable.mjs +1 -1
  16. package/dist/components/description-list.d.mts +1 -1
  17. package/dist/components/dialog.d.mts +1 -1
  18. package/dist/components/dropdown-menu.d.mts +1 -1
  19. package/dist/components/form.d.mts +37 -2
  20. package/dist/components/form.mjs +115 -5
  21. package/dist/components/github-button.d.mts +1 -1
  22. package/dist/components/input-group.d.mts +1 -1
  23. package/dist/components/input.d.mts +1 -1
  24. package/dist/components/input.mjs +1 -1
  25. package/dist/components/label.d.mts +1 -1
  26. package/dist/components/page-loader.d.mts +11 -0
  27. package/dist/components/page-loader.mjs +122 -0
  28. package/dist/components/pagination.d.mts +1 -1
  29. package/dist/components/popover.d.mts +1 -1
  30. package/dist/components/radio-group.d.mts +1 -1
  31. package/dist/components/scroll-area.d.mts +1 -1
  32. package/dist/components/select.d.mts +1 -1
  33. package/dist/components/separator.d.mts +1 -1
  34. package/dist/components/sheet.d.mts +1 -1
  35. package/dist/components/shimmer-text.d.mts +12 -0
  36. package/dist/components/shimmer-text.mjs +22 -0
  37. package/dist/components/sidebar.d.mts +1 -1
  38. package/dist/components/sidebar.mjs +2 -2
  39. package/dist/components/sonner.d.mts +1 -1
  40. package/dist/components/switch.d.mts +1 -1
  41. package/dist/components/table.d.mts +11 -2
  42. package/dist/components/table.mjs +4 -4
  43. package/dist/components/tabs.d.mts +1 -1
  44. package/dist/components/tabs.mjs +5 -5
  45. package/dist/components/task-progress.d.mts +27 -0
  46. package/dist/components/task-progress.mjs +66 -0
  47. package/dist/components/textarea.d.mts +1 -1
  48. package/dist/components/textarea.mjs +1 -1
  49. package/dist/components/toggle-group.d.mts +1 -1
  50. package/dist/components/toggle-group.mjs +1 -1
  51. package/dist/components/tooltip-icon-button.mjs +1 -1
  52. package/dist/components/tooltip.d.mts +1 -1
  53. package/dist/components/tooltip.mjs +1 -1
  54. package/dist/components/typography.d.mts +1 -1
  55. package/dist/components/wizard.d.mts +34 -0
  56. package/dist/components/wizard.mjs +46 -0
  57. package/package.json +12 -12
  58. package/src/components/combobox.tsx +9 -2
  59. package/src/components/form.tsx +164 -3
  60. package/src/components/page-loader.tsx +59 -0
  61. package/src/components/shimmer-text.tsx +23 -0
  62. package/src/components/table.tsx +17 -4
  63. package/src/components/tabs.tsx +4 -4
  64. package/src/components/task-progress.tsx +107 -0
  65. package/src/components/tooltip.tsx +1 -1
  66. package/src/components/wizard.tsx +69 -0
  67. package/src/stories/form.stories.tsx +64 -2
  68. package/src/stories/tabs.stories.tsx +4 -2
  69. package/src/stories/task-progress.stories.tsx +81 -0
  70. package/src/stories/wizard.stories.tsx +64 -0
  71. package/src/styles/tokens.css +20 -4
@@ -1,6 +1,6 @@
1
+ import * as React from "react";
1
2
  import * as AccordionPrimitive from "@radix-ui/react-accordion";
2
3
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
- import * as React from "react";
4
4
 
5
5
  //#region src/components/accordion-card.d.ts
6
6
  declare function AccordionCard({
@@ -1,6 +1,6 @@
1
+ import * as React from "react";
1
2
  import * as AccordionPrimitive from "@radix-ui/react-accordion";
2
3
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
- import * as React from "react";
4
4
 
5
5
  //#region src/components/accordion.d.ts
6
6
  declare function Accordion({
@@ -1,6 +1,6 @@
1
+ import * as React from "react";
1
2
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
3
  import { VariantProps } from "class-variance-authority";
3
- import * as React from "react";
4
4
  import * as _$class_variance_authority_types0 from "class-variance-authority/types";
5
5
 
6
6
  //#region src/components/alert.d.ts
@@ -1,9 +1,9 @@
1
1
  "use client";
2
2
  import { cn } from "../lib/cn.mjs";
3
3
  import { TooltipIconButton } from "./tooltip-icon-button.mjs";
4
+ import { useState } from "react";
4
5
  import { FileText, XIcon } from "lucide-react";
5
6
  import { jsx, jsxs } from "react/jsx-runtime";
6
- import { useState } from "react";
7
7
  //#region src/components/attachment-tile.tsx
8
8
  function AttachmentTile({ src, isImage, label, onRemove, onClick, className }) {
9
9
  const [hasError, setHasError] = useState(false);
@@ -1,6 +1,6 @@
1
+ import * as React from "react";
1
2
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
3
  import { VariantProps } from "class-variance-authority";
3
- import * as React from "react";
4
4
  import * as AvatarPrimitive from "@radix-ui/react-avatar";
5
5
  import * as _$class_variance_authority_types0 from "class-variance-authority/types";
6
6
 
@@ -1,5 +1,5 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import * as React from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/breadcrumb.d.ts
5
5
  declare function Breadcrumb({
@@ -1,6 +1,6 @@
1
+ import * as React from "react";
1
2
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
3
  import { VariantProps } from "class-variance-authority";
3
- import * as React from "react";
4
4
  import * as _$class_variance_authority_types0 from "class-variance-authority/types";
5
5
 
6
6
  //#region src/components/button.d.ts
@@ -1,5 +1,5 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import * as React from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/card.d.ts
5
5
  declare function Card({
@@ -1,5 +1,5 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import * as React from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
3
  import * as CheckboxPrimitive from "@radix-ui/react-checkbox";
4
4
 
5
5
  //#region src/components/checkbox.d.ts
@@ -1,5 +1,5 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import * as React from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
3
  import * as CollapsiblePrimitive from "@radix-ui/react-collapsible";
4
4
 
5
5
  //#region src/components/collapsible.d.ts
@@ -1,8 +1,8 @@
1
1
  import { PopoverContent } from "./popover.mjs";
2
2
  import { selectTriggerVariants } from "./select-trigger-variants.mjs";
3
+ import { ReactNode } from "react";
3
4
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
4
5
  import { VariantProps } from "class-variance-authority";
5
- import { ReactNode } from "react";
6
6
  import { Command } from "cmdk";
7
7
 
8
8
  //#region src/components/combobox.d.ts
@@ -11,6 +11,8 @@ interface ComboboxBaseProps {
11
11
  open?: boolean;
12
12
  defaultOpen?: boolean;
13
13
  onOpenChange?: (open: boolean) => void;
14
+ /** Resolves a selected value to a display label (e.g. for multi-select tags). Defaults to the value. */
15
+ getOptionLabel?: (value: string) => string;
14
16
  }
15
17
  interface ComboboxSingleProps extends ComboboxBaseProps {
16
18
  multiple?: false;
@@ -3,9 +3,9 @@ import { cn } from "../lib/cn.mjs";
3
3
  import { Popover, PopoverContent, PopoverTrigger } from "./popover.mjs";
4
4
  import { selectTriggerVariants } from "./select-trigger-variants.mjs";
5
5
  import { TagDismissible } from "./tag.mjs";
6
+ import { createContext, useCallback, useContext, useMemo, useState } from "react";
6
7
  import { CheckIcon, ChevronDownIcon, SearchIcon } from "lucide-react";
7
8
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
8
- import { createContext, useCallback, useContext, useMemo, useState } from "react";
9
9
  import { Command } from "cmdk";
10
10
  //#region src/components/combobox.tsx
11
11
  const ComboboxContext = createContext(null);
@@ -15,7 +15,7 @@ function useComboboxContext() {
15
15
  return context;
16
16
  }
17
17
  function Combobox(props) {
18
- const { children, multiple = false, open: controlledOpen, defaultOpen = false, onOpenChange: controlledOnOpenChange } = props;
18
+ const { children, multiple = false, open: controlledOpen, defaultOpen = false, onOpenChange: controlledOnOpenChange, getOptionLabel } = props;
19
19
  const [uncontrolledSingleValue, setUncontrolledSingleValue] = useState(!multiple ? props.defaultValue ?? null : null);
20
20
  const [uncontrolledMultiValue, setUncontrolledMultiValue] = useState(multiple ? props.defaultValue ?? [] : []);
21
21
  const [uncontrolledOpen, setUncontrolledOpen] = useState(defaultOpen);
@@ -77,7 +77,8 @@ function Combobox(props) {
77
77
  onDeselect,
78
78
  isSelected,
79
79
  open,
80
- onOpenChange
80
+ onOpenChange,
81
+ getOptionLabel
81
82
  }), [
82
83
  multiple,
83
84
  singleValue,
@@ -86,7 +87,8 @@ function Combobox(props) {
86
87
  onDeselect,
87
88
  isSelected,
88
89
  open,
89
- onOpenChange
90
+ onOpenChange,
91
+ getOptionLabel
90
92
  ]);
91
93
  return /* @__PURE__ */ jsx(ComboboxContext.Provider, {
92
94
  value: contextValue,
@@ -120,10 +122,11 @@ function ComboboxTrigger({ className, size, placeholder, children, ...props }) {
120
122
  });
121
123
  }
122
124
  function ComboboxTags({ values, onDeselect }) {
125
+ const { getOptionLabel } = useComboboxContext();
123
126
  return /* @__PURE__ */ jsx(Fragment, { children: values.map((tagValue) => /* @__PURE__ */ jsx(TagDismissible, {
124
127
  onClick: (event) => event.stopPropagation(),
125
128
  onDismiss: () => onDeselect(tagValue),
126
- children: tagValue
129
+ children: getOptionLabel ? getOptionLabel(tagValue) : tagValue
127
130
  }, tagValue)) });
128
131
  }
129
132
  function ComboboxContent({ className, children, filter, ...props }) {
@@ -1,5 +1,5 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import * as React from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
3
  import { Command as Command$1 } from "cmdk";
4
4
 
5
5
  //#region src/components/command.d.ts
@@ -1,5 +1,5 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import { ReactNode } from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/copyable.d.ts
5
5
  interface CopyableProps {
@@ -1,7 +1,7 @@
1
1
  "use client";
2
+ import { useCopyToClipboard } from "../hooks/use-copy-to-clipboard.mjs";
2
3
  import { cn } from "../lib/cn.mjs";
3
4
  import { Button } from "./button.mjs";
4
- import { useCopyToClipboard } from "../hooks/use-copy-to-clipboard.mjs";
5
5
  import { Check, Copy } from "lucide-react";
6
6
  import { jsx, jsxs } from "react/jsx-runtime";
7
7
  //#region src/components/copyable.tsx
@@ -1,5 +1,5 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import * as React from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/description-list.d.ts
5
5
  declare function DescriptionList({
@@ -1,7 +1,7 @@
1
1
  import { ButtonProps } from "./button.mjs";
2
+ import * as React from "react";
2
3
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
4
  import { VariantProps } from "class-variance-authority";
4
- import * as React from "react";
5
5
  import * as DialogPrimitive from "@radix-ui/react-dialog";
6
6
  import * as _$class_variance_authority_types0 from "class-variance-authority/types";
7
7
 
@@ -1,6 +1,6 @@
1
+ import * as React from "react";
1
2
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
3
  import { VariantProps } from "class-variance-authority";
3
- import * as React from "react";
4
4
  import * as DropdownMenuPrimitive from "@radix-ui/react-dropdown-menu";
5
5
  import * as _$class_variance_authority_types0 from "class-variance-authority/types";
6
6
 
@@ -1,8 +1,8 @@
1
1
  import { InputProps } from "./input.mjs";
2
2
  import { Label } from "./label.mjs";
3
3
  import { TextareaProps } from "./textarea.mjs";
4
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
5
4
  import * as React from "react";
5
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
6
6
  import { Slot } from "@radix-ui/react-slot";
7
7
  import * as _$react_hook_form0 from "react-hook-form";
8
8
  import { ControllerProps, FieldPath, FieldValues } from "react-hook-form";
@@ -115,5 +115,40 @@ declare function SelectField<TFieldValues extends FieldValues, TName extends Fie
115
115
  options,
116
116
  placeholder
117
117
  }: SelectFieldProps<TFieldValues, TName>): _$react_jsx_runtime0.JSX.Element;
118
+ interface RadioFieldProps<TFieldValues extends FieldValues, TName extends FieldPath<TFieldValues>> extends FormFieldBaseProps<TFieldValues, TName> {
119
+ options: SelectFieldOption[];
120
+ }
121
+ declare function RadioField<TFieldValues extends FieldValues, TName extends FieldPath<TFieldValues>>({
122
+ control,
123
+ name,
124
+ rules,
125
+ required,
126
+ label,
127
+ description,
128
+ tooltip,
129
+ options
130
+ }: RadioFieldProps<TFieldValues, TName>): _$react_jsx_runtime0.JSX.Element;
131
+ interface ChecklistFieldProps<TFieldValues extends FieldValues, TName extends FieldPath<TFieldValues>> extends FormFieldBaseProps<TFieldValues, TName> {
132
+ options: SelectFieldOption[];
133
+ }
134
+ declare function ChecklistField<TFieldValues extends FieldValues, TName extends FieldPath<TFieldValues>>({
135
+ control,
136
+ name,
137
+ rules,
138
+ required,
139
+ label,
140
+ description,
141
+ tooltip,
142
+ options
143
+ }: ChecklistFieldProps<TFieldValues, TName>): _$react_jsx_runtime0.JSX.Element;
144
+ interface CheckboxFieldProps<TFieldValues extends FieldValues, TName extends FieldPath<TFieldValues>> extends Omit<FormFieldBaseProps<TFieldValues, TName>, "required"> {}
145
+ declare function CheckboxField<TFieldValues extends FieldValues, TName extends FieldPath<TFieldValues>>({
146
+ control,
147
+ name,
148
+ rules,
149
+ label,
150
+ description,
151
+ tooltip
152
+ }: CheckboxFieldProps<TFieldValues, TName>): _$react_jsx_runtime0.JSX.Element;
118
153
  //#endregion
119
- export { Form, FormControl, FormDescription, FormField, FormFields, FormHeader, FormItem, FormLabel, FormMessage, InputField, SelectField, type SelectFieldOption, TextareaField, useFormField };
154
+ export { CheckboxField, ChecklistField, Form, FormControl, FormDescription, FormField, FormFields, FormHeader, FormItem, FormLabel, FormMessage, InputField, RadioField, SelectField, type SelectFieldOption, TextareaField, useFormField };
@@ -1,13 +1,15 @@
1
1
  "use client";
2
2
  import { cn } from "../lib/cn.mjs";
3
3
  import { Tooltip, TooltipContent, TooltipTrigger } from "./tooltip.mjs";
4
+ import { Checkbox } from "./checkbox.mjs";
4
5
  import { Label } from "./label.mjs";
5
6
  import { Input } from "./input.mjs";
7
+ import { RadioGroup, RadioGroupItem } from "./radio-group.mjs";
6
8
  import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from "./select.mjs";
7
9
  import { Textarea } from "./textarea.mjs";
10
+ import * as React from "react";
8
11
  import { Info } from "lucide-react";
9
12
  import { jsx, jsxs } from "react/jsx-runtime";
10
- import * as React from "react";
11
13
  import { Slot } from "@radix-ui/react-slot";
12
14
  import { Controller, FormProvider, useFormContext, useFormState } from "react-hook-form";
13
15
  //#region src/components/form.tsx
@@ -88,7 +90,7 @@ function FormDescription({ className, ...props }) {
88
90
  return /* @__PURE__ */ jsx("p", {
89
91
  "data-slot": "form-description",
90
92
  id: formDescriptionId,
91
- className: cn("text-muted-foreground text-sm", className),
93
+ className: cn("text-muted-foreground type-text-sm whitespace-pre-line", className),
92
94
  ...props
93
95
  });
94
96
  }
@@ -134,11 +136,11 @@ function InputField({ control, name, rules, required, label, description, toolti
134
136
  tooltip,
135
137
  children: label
136
138
  }),
139
+ description && /* @__PURE__ */ jsx(FormDescription, { children: description }),
137
140
  /* @__PURE__ */ jsx(FormControl, { children: /* @__PURE__ */ jsx(Input, {
138
141
  ...inputProps,
139
142
  ...field
140
143
  }) }),
141
- description && /* @__PURE__ */ jsx(FormDescription, { children: description }),
142
144
  /* @__PURE__ */ jsx(FormMessage, {})
143
145
  ] })
144
146
  });
@@ -154,11 +156,11 @@ function TextareaField({ control, name, rules, required, label, description, too
154
156
  tooltip,
155
157
  children: label
156
158
  }),
159
+ description && /* @__PURE__ */ jsx(FormDescription, { children: description }),
157
160
  /* @__PURE__ */ jsx(FormControl, { children: /* @__PURE__ */ jsx(Textarea, {
158
161
  ...textareaProps,
159
162
  ...field
160
163
  }) }),
161
- description && /* @__PURE__ */ jsx(FormDescription, { children: description }),
162
164
  /* @__PURE__ */ jsx(FormMessage, {})
163
165
  ] })
164
166
  });
@@ -174,6 +176,7 @@ function SelectField({ control, name, rules, required, label, description, toolt
174
176
  tooltip,
175
177
  children: label
176
178
  }),
179
+ description && /* @__PURE__ */ jsx(FormDescription, { children: description }),
177
180
  /* @__PURE__ */ jsxs(Select, {
178
181
  value: field.value,
179
182
  onValueChange: field.onChange,
@@ -183,10 +186,117 @@ function SelectField({ control, name, rules, required, label, description, toolt
183
186
  children: option.label
184
187
  }, option.value)) })]
185
188
  }),
189
+ /* @__PURE__ */ jsx(FormMessage, {})
190
+ ] })
191
+ });
192
+ }
193
+ function RadioField({ control, name, rules, required, label, description, tooltip, options }) {
194
+ return /* @__PURE__ */ jsx(FormField, {
195
+ control,
196
+ name,
197
+ rules,
198
+ render: ({ field }) => /* @__PURE__ */ jsxs(FormItem, { children: [
199
+ label && /* @__PURE__ */ jsx(FormLabel, {
200
+ required,
201
+ tooltip,
202
+ children: label
203
+ }),
186
204
  description && /* @__PURE__ */ jsx(FormDescription, { children: description }),
205
+ /* @__PURE__ */ jsx(FormControl, { children: /* @__PURE__ */ jsx(RadioGroup, {
206
+ value: field.value ?? "",
207
+ onValueChange: field.onChange,
208
+ onBlur: field.onBlur,
209
+ children: options.map((option) => {
210
+ const itemId = `${field.name}-${option.value}`;
211
+ return /* @__PURE__ */ jsxs("div", {
212
+ className: "flex items-center gap-2",
213
+ children: [/* @__PURE__ */ jsx(RadioGroupItem, {
214
+ id: itemId,
215
+ value: option.value,
216
+ disabled: option.disabled
217
+ }), /* @__PURE__ */ jsx(Label, {
218
+ htmlFor: itemId,
219
+ className: "type-text-sm font-normal",
220
+ children: option.label
221
+ })]
222
+ }, option.value);
223
+ })
224
+ }) }),
187
225
  /* @__PURE__ */ jsx(FormMessage, {})
188
226
  ] })
189
227
  });
190
228
  }
229
+ function ChecklistField({ control, name, rules, required, label, description, tooltip, options }) {
230
+ return /* @__PURE__ */ jsx(FormField, {
231
+ control,
232
+ name,
233
+ rules,
234
+ render: ({ field }) => {
235
+ const selected = Array.isArray(field.value) ? field.value : [];
236
+ const toggle = (value, checked) => {
237
+ if (checked) field.onChange([...selected, value]);
238
+ else field.onChange(selected.filter((existing) => existing !== value));
239
+ };
240
+ return /* @__PURE__ */ jsxs(FormItem, { children: [
241
+ label && /* @__PURE__ */ jsx(FormLabel, {
242
+ required,
243
+ tooltip,
244
+ children: label
245
+ }),
246
+ description && /* @__PURE__ */ jsx(FormDescription, { children: description }),
247
+ /* @__PURE__ */ jsx(FormControl, { children: /* @__PURE__ */ jsx("fieldset", {
248
+ className: "m-0 flex flex-col gap-2 border-0 p-0",
249
+ onBlur: field.onBlur,
250
+ children: options.map((option) => {
251
+ const itemId = `${field.name}-${option.value}`;
252
+ return /* @__PURE__ */ jsxs("div", {
253
+ className: "flex items-start gap-2",
254
+ children: [/* @__PURE__ */ jsx(Checkbox, {
255
+ id: itemId,
256
+ checked: selected.includes(option.value),
257
+ onCheckedChange: (next) => toggle(option.value, Boolean(next)),
258
+ disabled: option.disabled
259
+ }), /* @__PURE__ */ jsx(Label, {
260
+ htmlFor: itemId,
261
+ className: "type-text-sm font-normal leading-tight",
262
+ children: option.label
263
+ })]
264
+ }, option.value);
265
+ })
266
+ }) }),
267
+ /* @__PURE__ */ jsx(FormMessage, {})
268
+ ] });
269
+ }
270
+ });
271
+ }
272
+ function CheckboxField({ control, name, rules, label, description, tooltip }) {
273
+ return /* @__PURE__ */ jsx(FormField, {
274
+ control,
275
+ name,
276
+ rules,
277
+ render: ({ field }) => /* @__PURE__ */ jsxs(FormItem, {
278
+ className: "gap-1.5",
279
+ children: [
280
+ /* @__PURE__ */ jsxs("div", {
281
+ className: "flex items-start gap-2",
282
+ children: [/* @__PURE__ */ jsx(FormControl, { children: /* @__PURE__ */ jsx(Checkbox, {
283
+ checked: field.value ?? false,
284
+ onCheckedChange: (next) => field.onChange(Boolean(next)),
285
+ onBlur: field.onBlur
286
+ }) }), label && /* @__PURE__ */ jsx(FormLabel, {
287
+ tooltip,
288
+ className: "font-normal",
289
+ children: label
290
+ })]
291
+ }),
292
+ description && /* @__PURE__ */ jsx(FormDescription, {
293
+ className: "ml-6",
294
+ children: description
295
+ }),
296
+ /* @__PURE__ */ jsx(FormMessage, { className: "ml-6" })
297
+ ]
298
+ })
299
+ });
300
+ }
191
301
  //#endregion
192
- export { Form, FormControl, FormDescription, FormField, FormFields, FormHeader, FormItem, FormLabel, FormMessage, InputField, SelectField, TextareaField, useFormField };
302
+ export { CheckboxField, ChecklistField, Form, FormControl, FormDescription, FormField, FormFields, FormHeader, FormItem, FormLabel, FormMessage, InputField, RadioField, SelectField, TextareaField, useFormField };
@@ -1,6 +1,6 @@
1
1
  import { Button } from "./button.mjs";
2
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
2
  import { ComponentProps } from "react";
3
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
4
4
 
5
5
  //#region src/components/github-button.d.ts
6
6
  type GitHubButtonProps = Omit<ComponentProps<typeof Button>, "variant" | "icon">;
@@ -1,6 +1,6 @@
1
+ import * as React from "react";
1
2
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
3
  import { VariantProps } from "class-variance-authority";
3
- import * as React from "react";
4
4
  import * as _$class_variance_authority_types0 from "class-variance-authority/types";
5
5
 
6
6
  //#region src/components/input-group.d.ts
@@ -1,5 +1,5 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import * as React from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/input.d.ts
5
5
  interface InputProps extends Omit<React.ComponentProps<"input">, "size"> {
@@ -2,9 +2,9 @@
2
2
  import { cn } from "../lib/cn.mjs";
3
3
  import { Tooltip, TooltipContent, TooltipTrigger } from "./tooltip.mjs";
4
4
  import { Label } from "./label.mjs";
5
+ import * as React from "react";
5
6
  import { Info } from "lucide-react";
6
7
  import { jsx, jsxs } from "react/jsx-runtime";
7
- import * as React from "react";
8
8
  //#region src/components/input.tsx
9
9
  const inputSizeStyles = {
10
10
  sm: {
@@ -1,5 +1,5 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import * as React from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
3
  import * as LabelPrimitive from "@radix-ui/react-label";
4
4
 
5
5
  //#region src/components/label.d.ts
@@ -0,0 +1,11 @@
1
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
+
3
+ //#region src/components/page-loader.d.ts
4
+ interface PageLoaderProps {
5
+ className?: string;
6
+ }
7
+ declare function PageLoader({
8
+ className
9
+ }: PageLoaderProps): _$react_jsx_runtime0.JSX.Element;
10
+ //#endregion
11
+ export { PageLoader, type PageLoaderProps };
@@ -0,0 +1,122 @@
1
+ "use client";
2
+ import { cn } from "../lib/cn.mjs";
3
+ import { jsx, jsxs } from "react/jsx-runtime";
4
+ //#region src/components/page-loader.tsx
5
+ const CABLE_CAR_SVG = /* @__PURE__ */ jsxs("svg", {
6
+ xmlns: "http://www.w3.org/2000/svg",
7
+ viewBox: "0 0 120 130",
8
+ width: "240",
9
+ height: "260",
10
+ "aria-hidden": "true",
11
+ className: "block h-auto w-full",
12
+ children: [
13
+ /* @__PURE__ */ jsx("line", {
14
+ x1: "60",
15
+ y1: "3",
16
+ x2: "60",
17
+ y2: "58",
18
+ stroke: "#333",
19
+ strokeWidth: "4"
20
+ }),
21
+ /* @__PURE__ */ jsx("circle", {
22
+ cx: "60",
23
+ cy: "11",
24
+ r: "10",
25
+ fill: "#555"
26
+ }),
27
+ /* @__PURE__ */ jsx("rect", {
28
+ x: "5",
29
+ y: "58",
30
+ width: "110",
31
+ height: "64",
32
+ rx: "4",
33
+ fill: "#e90060"
34
+ }),
35
+ /* @__PURE__ */ jsx("rect", {
36
+ x: "5",
37
+ y: "58",
38
+ width: "110",
39
+ height: "20",
40
+ rx: "4",
41
+ fill: "#F5F0E8"
42
+ }),
43
+ /* @__PURE__ */ jsx("rect", {
44
+ x: "5",
45
+ y: "68",
46
+ width: "110",
47
+ height: "10",
48
+ fill: "#F5F0E8"
49
+ }),
50
+ /* @__PURE__ */ jsx("rect", {
51
+ x: "14",
52
+ y: "66",
53
+ width: "26",
54
+ height: "30",
55
+ rx: "2",
56
+ fill: "#5B8EC9",
57
+ stroke: "#C4B9A8",
58
+ strokeWidth: "1.5"
59
+ }),
60
+ /* @__PURE__ */ jsx("rect", {
61
+ x: "47",
62
+ y: "66",
63
+ width: "26",
64
+ height: "30",
65
+ rx: "2",
66
+ fill: "#5B8EC9",
67
+ stroke: "#C4B9A8",
68
+ strokeWidth: "1.5"
69
+ }),
70
+ /* @__PURE__ */ jsx("rect", {
71
+ x: "80",
72
+ y: "66",
73
+ width: "26",
74
+ height: "30",
75
+ rx: "2",
76
+ fill: "#5B8EC9",
77
+ stroke: "#C4B9A8",
78
+ strokeWidth: "1.5"
79
+ }),
80
+ /* @__PURE__ */ jsx("rect", {
81
+ x: "5",
82
+ y: "115",
83
+ width: "110",
84
+ height: "7",
85
+ rx: "3",
86
+ fill: "#9f0042"
87
+ })
88
+ ]
89
+ });
90
+ function PageLoader({ className }) {
91
+ return /* @__PURE__ */ jsx("div", {
92
+ className: cn("flex min-h-screen items-center justify-center bg-background", className),
93
+ role: "status",
94
+ "aria-label": "Loading Alpic…",
95
+ children: /* @__PURE__ */ jsxs("div", {
96
+ className: "relative h-[120px] w-[200px]",
97
+ children: [
98
+ /* @__PURE__ */ jsx("div", {
99
+ className: "absolute top-[30px] left-0 h-[3px] w-full rounded-sm bg-[#6c6c77]",
100
+ style: {
101
+ transform: "rotate(-15deg)",
102
+ transformOrigin: "left center"
103
+ }
104
+ }),
105
+ /* @__PURE__ */ jsx("div", {
106
+ className: "absolute top-[33px] -left-[45px] w-[45px] motion-safe:animate-[alpic-ride_4s_linear_infinite]",
107
+ children: CABLE_CAR_SVG
108
+ }),
109
+ /* @__PURE__ */ jsx("div", {
110
+ className: "pointer-events-none absolute -top-[40px] -left-[45px] z-10 h-[200px] w-[95px]",
111
+ style: { background: "linear-gradient(to right, var(--color-background) 47%, transparent)" }
112
+ }),
113
+ /* @__PURE__ */ jsx("div", {
114
+ className: "pointer-events-none absolute -top-[40px] left-[142px] z-10 h-[200px] w-[95px]",
115
+ style: { background: "linear-gradient(to right, transparent, var(--color-background) 53%)" }
116
+ })
117
+ ]
118
+ })
119
+ });
120
+ }
121
+ //#endregion
122
+ export { PageLoader };
@@ -1,5 +1,5 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import * as React from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/pagination.d.ts
5
5
  interface PaginationProps extends React.ComponentProps<"nav"> {
@@ -1,5 +1,5 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import * as React from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
3
  import * as PopoverPrimitive from "@radix-ui/react-popover";
4
4
 
5
5
  //#region src/components/popover.d.ts
@@ -1,5 +1,5 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import * as React from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
3
  import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
4
4
 
5
5
  //#region src/components/radio-group.d.ts
@@ -1,5 +1,5 @@
1
- import * as _$react_jsx_runtime0 from "react/jsx-runtime";
2
1
  import * as React from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
3
  import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area";
4
4
 
5
5
  //#region src/components/scroll-area.d.ts