@exsto/ds 0.0.1-rc.17 → 0.0.1-rc.18

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 (46) hide show
  1. package/README.md +34 -0
  2. package/dist/ds/src/file-input.d.ts +9 -0
  3. package/dist/ds/src/time-field.d.ts +9 -0
  4. package/dist/file-input.js +2 -0
  5. package/dist/index.js +4 -3
  6. package/dist/source-hash.txt +1 -1
  7. package/dist/styles.css +143 -38
  8. package/dist/time-field.js +2 -0
  9. package/dist/ui/src/components/edyn/file-input/file-input.d.ts +90 -0
  10. package/dist/ui/src/components/edyn/file-input/file-input.js +261 -0
  11. package/dist/ui/src/components/edyn/file-input/file-input.js.map +1 -0
  12. package/dist/ui/src/components/edyn/file-input/file-input.test.d.ts +8 -0
  13. package/dist/ui/src/components/edyn/file-input/index.d.ts +1 -0
  14. package/dist/ui/src/components/edyn/multi-select/multi-select.d.ts +12 -1
  15. package/dist/ui/src/components/edyn/multi-select/multi-select.js +11 -7
  16. package/dist/ui/src/components/edyn/multi-select/multi-select.js.map +1 -1
  17. package/dist/ui/src/components/edyn/time-field/index.d.ts +1 -0
  18. package/dist/ui/src/components/edyn/time-field/time-field.d.ts +85 -0
  19. package/dist/ui/src/components/edyn/time-field/time-field.js +330 -0
  20. package/dist/ui/src/components/edyn/time-field/time-field.js.map +1 -0
  21. package/dist/ui/src/components/edyn/time-field/time-field.test.d.ts +8 -0
  22. package/dist/ui/src/components/ui/combobox/combobox.d.ts +10 -0
  23. package/dist/ui/src/components/ui/combobox/combobox.js +37 -5
  24. package/dist/ui/src/components/ui/combobox/combobox.js.map +1 -1
  25. package/dist/ui/src/components/ui/context-menu/context-menu.d.ts +1 -1
  26. package/dist/ui/src/components/ui/context-menu/context-menu.js +23 -10
  27. package/dist/ui/src/components/ui/context-menu/context-menu.js.map +1 -1
  28. package/dist/ui/src/components/ui/dropdown-menu/dropdown-menu.js +5 -4
  29. package/dist/ui/src/components/ui/dropdown-menu/dropdown-menu.js.map +1 -1
  30. package/dist/ui/src/components/ui/menubar/menubar.js +1 -1
  31. package/dist/ui/src/components/ui/menubar/menubar.js.map +1 -1
  32. package/dist/ui/src/components/ui/scroll-area/scroll-area.js +1 -1
  33. package/dist/ui/src/components/ui/scroll-area/scroll-area.js.map +1 -1
  34. package/dist/ui/src/components/ui/select/select.js +7 -6
  35. package/dist/ui/src/components/ui/select/select.js.map +1 -1
  36. package/dist/ui/src/components/ui/sheet/sheet.d.ts +8 -0
  37. package/dist/ui/src/components/ui/sheet/sheet.js +11 -3
  38. package/dist/ui/src/components/ui/sheet/sheet.js.map +1 -1
  39. package/dist/ui/src/components/ui/table/table.d.ts +9 -2
  40. package/dist/ui/src/components/ui/table/table.js +19 -6
  41. package/dist/ui/src/components/ui/table/table.js.map +1 -1
  42. package/dist/ui/src/index.d.ts +1 -0
  43. package/dist/ui/src/lib/popup-list.d.ts +29 -4
  44. package/dist/ui/src/lib/popup-list.js +30 -5
  45. package/dist/ui/src/lib/popup-list.js.map +1 -1
  46. package/package.json +9 -1
package/README.md CHANGED
@@ -81,6 +81,8 @@ query, so a subtree can be dark inside a light page.
81
81
  |---|---|
82
82
  | `@exsto/ds` | React components |
83
83
  | `@exsto/ds/date-picker` | The DatePicker (one day, typed or picked), on its own entry so the main one stays inside its size budget |
84
+ | `@exsto/ds/time-field` | The TimeField (a time of day typed in segments), on its own entry for the same reason |
85
+ | `@exsto/ds/file-input` | The FileInput (files picked or dropped, listed and removable), on its own entry for the same reason |
84
86
  | `@exsto/ds/rich-text-editor` | The rich-text editor, on its own entry so its engine loads only where it is used |
85
87
  | `@exsto/ds/styles.css` | Precompiled tokens and component styles |
86
88
  | `@exsto/ds/theme.css` | Uncompiled tokens, brand layer, and the Tailwind `@theme` mapping |
@@ -152,10 +154,42 @@ const missing = state.kind === 'empty'; // 'refused' is already said by the pick
152
154
 
153
155
  Refused text is reported each time it changes, also when the field held no day before, and emptying the field afterwards reports `empty`. A parent's `aria-invalid` only draws the invalid border; the picker's own message is added to `aria-describedby` once, after the parent's. `DateRangePicker`, for a range, is in the main entry.
154
156
 
157
+ ## Time
158
+
159
+ `TimeField` is a time of day typed in segments (hours, minutes, optional seconds, AM/PM where the locale uses it), with ArrowUp and ArrowDown to step a segment, ArrowLeft and ArrowRight to move between them, and the names a screen reader needs for each. It is on its own entry, like the DatePicker. The value is an `HH:mm` (or `HH:mm:ss`) string in 24-hour form, whatever the hour cycle on screen.
160
+
161
+ ```tsx
162
+ import { TimeField } from '@exsto/ds/time-field';
163
+
164
+ <TimeField aria-label="Start time" value={time} onValueChange={setTime} />;
165
+ ```
166
+
167
+ ## Files
168
+
169
+ `FileInput` chooses files by picking or dropping them. A real `<input type="file">` lies under the drop area, so Tab, Enter and Space, the system's file dialog, a drop and a screen reader's name come from the browser; on top of that it lists the chosen files with their sizes and a remove button named after each, checks them against `accept`, `maxSize` and `maxFiles` (a drop skips the dialog's own filter), and says in one live region what was added, removed or refused. It is on its own entry, like the DatePicker.
170
+
171
+ ```tsx
172
+ import { FileInput } from '@exsto/ds/file-input';
173
+
174
+ <FileInput aria-label="Attachments" multiple accept=".pdf,image/*" maxSize={5 * 1024 * 1024} value={files} onValueChange={setFiles} onReject={(rejected) => report(rejected)} />;
175
+ ```
176
+
155
177
  ## Open popups and keyboard audits
156
178
 
157
179
  While a menu, dialog, sheet, popover, select or drawer is open, Base UI puts two empty `<span tabindex="0" data-base-ui-focus-guard>` around it. They are the sentinels that hand focus back into the popup when Tab runs past either end, so they are focusable on purpose, and they always were. From `0.0.1-rc.16` the design system also takes their `aria-hidden` off while the popup is open, because a focusable element that is hidden from assistive technology fails axe's `aria-hidden-focus` (WCAG 4.1.2). A check that walks the Tab order should skip `[data-base-ui-focus-guard]`, as it skips any other sentinel: they hold no text and name nothing.
158
180
 
181
+ ## Composing a popup of your own
182
+
183
+ Select, Combobox, MultiSelect and the menus share one shape, and the pieces are exported so a popup an app builds itself matches them instead of copying their classes:
184
+
185
+ ```tsx
186
+ import { cn, POPUP_FRAME_CLASS, POPUP_LIST_HEIGHT_CLASS, POPUP_LIST_WIDTH_CLASS, popupItemClass } from '@exsto/ds';
187
+ ```
188
+
189
+ - `popupItemClass(flavor?, checkable?)` is one row: 32px tall, 8px of padding, the highlight and the chosen weight. `'base-ui'` (the default) is for Base UI parts, `'cmdk'` for cmdk's; `checkable` leaves room at the end for the check, which sits at `POPUP_ITEM_INDICATOR_CLASS`.
190
+ - `POPUP_GROUP_LABEL_CLASS` is a group's heading. `ComboboxGroup`, `ComboboxLabel`, `ComboboxCollection` and `ComboboxSeparator` give a Combobox its groups, drawn the same way Select draws its own.
191
+ - `POPUP_FRAME_CLASS` is the frame (a 10px radius and a 1px ring, no border). `POPUP_LIST_WIDTH_CLASS` is its width: at least the control and 8rem, as wide as the longest row, 28rem at most. `POPUP_LIST_HEIGHT_CLASS` caps the scrolling part: eight rows, or as many whole rows as the room allows, so a list never ends on half a row. Put it on a `ScrollArea` that holds the list's own `p-1`, inside a popup that is a flex column with `max-h-(--available-height)`.
192
+
159
193
  ## Status
160
194
 
161
195
  Release candidates (`0.0.1-rc.N`). The API is not stable yet; treat minor versions
@@ -0,0 +1,9 @@
1
+ /**
2
+ * `@exsto/ds/file-input` - the FileInput, on its own entry on purpose.
3
+ *
4
+ * A file field that is a real `<input type="file">` under a drop area, with the list of what was chosen, the checks against
5
+ * `accept`, `maxSize` and `maxFiles`, and a live region that says what was added, removed or refused: about 10 KB unminified.
6
+ * Re-exported from `@exsto/ds` it would be one more thing in the entry every consumer loads and a bundler cannot always tell
7
+ * it unused. Here an app pays for it only on the pages that import this path.
8
+ */
9
+ export * from '../../ui/src/components/edyn/file-input';
@@ -0,0 +1,9 @@
1
+ /**
2
+ * `@exsto/ds/time-field` - the TimeField, on its own entry on purpose.
3
+ *
4
+ * A time of day typed in segments (hours, minutes, optional seconds, AM/PM where the locale uses it) with the arrow keys,
5
+ * Tab and the screen-reader names a native time input has: about 11 KB unminified. Re-exported from `@exsto/ds` it would be
6
+ * one more thing in the entry every consumer loads and a bundler cannot always tell it unused. Here an app pays for it only on
7
+ * the pages that import this path.
8
+ */
9
+ export * from '../../ui/src/components/edyn/time-field';
@@ -0,0 +1,2 @@
1
+ import { DEFAULT_FILE_INPUT_LABELS, FileInput, formatBytes, matchesAccept, sortFiles } from "./ui/src/components/edyn/file-input/file-input.js";
2
+ export { DEFAULT_FILE_INPUT_LABELS, FileInput, formatBytes, matchesAccept, sortFiles };
package/dist/index.js CHANGED
@@ -13,7 +13,8 @@ import { AVATAR_TONES, InitialsAvatar, avatarTone, initialsOf } from "./ui/src/c
13
13
  import { useMergedRefs } from "./ui/src/hooks/use-merged-refs.js";
14
14
  import { ScrollArea, ScrollBar } from "./ui/src/components/ui/scroll-area/scroll-area.js";
15
15
  import { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from "./ui/src/components/ui/tooltip/tooltip.js";
16
- import { DEFAULT_MULTI_SELECT_LABELS, MultiSelect, VIRTUALIZE_FROM, fullSelection, resolveChosen, summarize } from "./ui/src/components/edyn/multi-select/multi-select.js";
16
+ import { POPUP_FRAME_CLASS, POPUP_GROUP_LABEL_CLASS, POPUP_ITEM_INDICATOR_CLASS, POPUP_LIST_HEIGHT_CLASS, POPUP_LIST_WIDTH_CLASS, popupItemClass } from "./ui/src/lib/popup-list.js";
17
+ import { DEFAULT_MULTI_SELECT_LABELS, MultiSelect, SEARCH_FROM, VIRTUALIZE_FROM, fullSelection, resolveChosen, summarize } from "./ui/src/components/edyn/multi-select/multi-select.js";
17
18
  import { DEFAULT_PRESENCE_LABELS, PRESENCE_STATES, Presence } from "./ui/src/components/edyn/presence/presence.js";
18
19
  import { PROGRESS_LINE_COLOR, ProgressLine } from "./ui/src/components/edyn/progress-line/progress-line.js";
19
20
  import { RICH_TEXT_ATTRIBUTES, RICH_TEXT_ELEMENTS, RICH_TEXT_LINK_PROTOCOLS, isAllowedRichTextHref } from "./ui/src/components/edyn/rich-text-content/allow-list.js";
@@ -33,7 +34,7 @@ import { Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious
33
34
  import { ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent } from "./ui/src/components/ui/chart/chart.js";
34
35
  import { Checkbox } from "./ui/src/components/ui/checkbox/checkbox.js";
35
36
  import { Collapsible, CollapsibleContent, CollapsibleTrigger } from "./ui/src/components/ui/collapsible/collapsible.js";
36
- import { Combobox, ComboboxContent, ComboboxEmpty, ComboboxInput, ComboboxItem } from "./ui/src/components/ui/combobox/combobox.js";
37
+ import { Combobox, ComboboxCollection, ComboboxContent, ComboboxEmpty, ComboboxGroup, ComboboxInput, ComboboxItem, ComboboxLabel, ComboboxSeparator } from "./ui/src/components/ui/combobox/combobox.js";
37
38
  import { Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger } from "./ui/src/components/ui/dialog/dialog.js";
38
39
  import { Input } from "./ui/src/components/ui/input/input.js";
39
40
  import { Textarea } from "./ui/src/components/ui/textarea/textarea.js";
@@ -74,4 +75,4 @@ import { Tabs, TabsContent, TabsList, TabsTrigger, tabsListVariants } from "./ui
74
75
  import { Toast, ToastAction, ToastClose, ToastContent, ToastDescription, ToastPortal, ToastProvider, ToastTitle, ToastViewport, Toaster, createToastManager, toast, useToastManager } from "./ui/src/components/ui/toast/toast.js";
75
76
  import { Toggle, toggleVariants } from "./ui/src/components/ui/toggle/toggle.js";
76
77
  import { ToggleGroup, ToggleGroupItem } from "./ui/src/components/ui/toggle-group/toggle-group.js";
77
- export { AVATAR_TONES, Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertAction, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogMedia, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AnimatedNumber, AspectRatio, Attachment, AttachmentAction, AttachmentActions, AttachmentContent, AttachmentDescription, AttachmentGroup, AttachmentMedia, AttachmentTitle, AttachmentTrigger, AudioPlayer, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage, Badge, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Bubble, BubbleContent, BubbleGroup, BubbleReactions, Button, ButtonGroup, ButtonGroupSeparator, ButtonGroupText, Calendar, CalendarDayButton, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, Checkbox, Collapsible, CollapsibleContent, CollapsibleTrigger, Combobox, ComboboxContent, ComboboxEmpty, ComboboxInput, ComboboxItem, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, DEFAULT_MULTI_SELECT_LABELS, DEFAULT_PRESENCE_LABELS, DateRangePicker, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DirectionProvider, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyTitle, Field, FieldDescription, FieldError, FieldLabel, HoverCard, HoverCardContent, HoverCardTrigger, Indicator, InitialsAvatar, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, Item, ItemActions, ItemContent, ItemDescription, ItemFooter, ItemGroup, ItemHeader, ItemMedia, ItemSeparator, ItemTitle, Kbd, KbdGroup, Label, Marker, MarkerContent, MarkerIcon, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, Message, MessageAvatar, MessageContent, MessageFooter, MessageGroup, MessageHeader, MessageScroller, MessageScrollerButton, MessageScrollerContent, MessageScrollerItem, MessageScrollerProvider, MessageScrollerViewport, MultiSelect, NativeSelect, NativeSelectOptGroup, NativeSelectOption, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuPositioner, NavigationMenuTrigger, NumberText, PRESENCE_STATES, PROGRESS_DURATION, PROGRESS_EASE, PROGRESS_LINE_COLOR, Pagination, Popover, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, Presence, Progress, ProgressLine, Questionnaire, QuestionnaireActions, QuestionnaireChoice, QuestionnaireChoiceDescription, QuestionnaireChoices, QuestionnaireDescription, QuestionnaireError, QuestionnaireInput, QuestionnaireItem, QuestionnaireNext, QuestionnairePrevious, QuestionnaireProgress, QuestionnaireSkip, QuestionnaireSubmit, QuestionnaireTitle, RICH_TEXT_ATTRIBUTES, RICH_TEXT_BODY_CLASS, RICH_TEXT_ELEMENTS, RICH_TEXT_LINK_PROTOCOLS, RICH_TEXT_MENTION_CLASS, RadioGroup, RadioGroupItem, ResizableHandle, ResizablePanel, ResizablePanelGroup, RichTextContent, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, Slider, Spinner, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, Toast, ToastAction, ToastClose, ToastContent, ToastDescription, ToastPortal, ToastProvider, ToastTitle, ToastViewport, Toaster, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, VIRTUALIZE_FROM, VideoPlayer, avatarTone, badgeVariants, buttonVariants, clampPage, cn, createToastManager, dateToDay, dayToDate, formatCount, formatMediaTime, fullSelection, getPaginationRange, indicatorVariants, initialsOf, isAllowedRichTextHref, markerVariants, navigationMenuTriggerStyle, progressFill, progressTrack, resolveChosen, richTextToNodes, spinnerVariants, summarize, tabsListVariants, toast, toggleVariants, useAnimatedValues, useCarousel, useDirection, useIsMobile, useMediaPlayer, useMergedRefs, useMessageScroller, useMessageScrollerScrollable, useMessageScrollerVisibility, useSidebar, useToastManager };
78
+ export { AVATAR_TONES, Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertAction, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogMedia, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AnimatedNumber, AspectRatio, Attachment, AttachmentAction, AttachmentActions, AttachmentContent, AttachmentDescription, AttachmentGroup, AttachmentMedia, AttachmentTitle, AttachmentTrigger, AudioPlayer, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage, Badge, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Bubble, BubbleContent, BubbleGroup, BubbleReactions, Button, ButtonGroup, ButtonGroupSeparator, ButtonGroupText, Calendar, CalendarDayButton, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, Checkbox, Collapsible, CollapsibleContent, CollapsibleTrigger, Combobox, ComboboxCollection, ComboboxContent, ComboboxEmpty, ComboboxGroup, ComboboxInput, ComboboxItem, ComboboxLabel, ComboboxSeparator, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, DEFAULT_MULTI_SELECT_LABELS, DEFAULT_PRESENCE_LABELS, DateRangePicker, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DirectionProvider, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyTitle, Field, FieldDescription, FieldError, FieldLabel, HoverCard, HoverCardContent, HoverCardTrigger, Indicator, InitialsAvatar, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, Item, ItemActions, ItemContent, ItemDescription, ItemFooter, ItemGroup, ItemHeader, ItemMedia, ItemSeparator, ItemTitle, Kbd, KbdGroup, Label, Marker, MarkerContent, MarkerIcon, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, Message, MessageAvatar, MessageContent, MessageFooter, MessageGroup, MessageHeader, MessageScroller, MessageScrollerButton, MessageScrollerContent, MessageScrollerItem, MessageScrollerProvider, MessageScrollerViewport, MultiSelect, NativeSelect, NativeSelectOptGroup, NativeSelectOption, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuPositioner, NavigationMenuTrigger, NumberText, POPUP_FRAME_CLASS, POPUP_GROUP_LABEL_CLASS, POPUP_ITEM_INDICATOR_CLASS, POPUP_LIST_HEIGHT_CLASS, POPUP_LIST_WIDTH_CLASS, PRESENCE_STATES, PROGRESS_DURATION, PROGRESS_EASE, PROGRESS_LINE_COLOR, Pagination, Popover, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, Presence, Progress, ProgressLine, Questionnaire, QuestionnaireActions, QuestionnaireChoice, QuestionnaireChoiceDescription, QuestionnaireChoices, QuestionnaireDescription, QuestionnaireError, QuestionnaireInput, QuestionnaireItem, QuestionnaireNext, QuestionnairePrevious, QuestionnaireProgress, QuestionnaireSkip, QuestionnaireSubmit, QuestionnaireTitle, RICH_TEXT_ATTRIBUTES, RICH_TEXT_BODY_CLASS, RICH_TEXT_ELEMENTS, RICH_TEXT_LINK_PROTOCOLS, RICH_TEXT_MENTION_CLASS, RadioGroup, RadioGroupItem, ResizableHandle, ResizablePanel, ResizablePanelGroup, RichTextContent, SEARCH_FROM, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, Slider, Spinner, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, Toast, ToastAction, ToastClose, ToastContent, ToastDescription, ToastPortal, ToastProvider, ToastTitle, ToastViewport, Toaster, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, VIRTUALIZE_FROM, VideoPlayer, avatarTone, badgeVariants, buttonVariants, clampPage, cn, createToastManager, dateToDay, dayToDate, formatCount, formatMediaTime, fullSelection, getPaginationRange, indicatorVariants, initialsOf, isAllowedRichTextHref, markerVariants, navigationMenuTriggerStyle, popupItemClass, progressFill, progressTrack, resolveChosen, richTextToNodes, spinnerVariants, summarize, tabsListVariants, toast, toggleVariants, useAnimatedValues, useCarousel, useDirection, useIsMobile, useMediaPlayer, useMergedRefs, useMessageScroller, useMessageScrollerScrollable, useMessageScrollerVisibility, useSidebar, useToastManager };
@@ -1 +1 @@
1
- 188147f3f789366cf669116233eddeed7297dad660bbaa9749fc44c833dabdd3
1
+ e7f64dd8a5e900b4cc6189554ed97571e1a11bc66a714ebfa14d32bfe3bae156
package/dist/styles.css CHANGED
@@ -1128,6 +1128,10 @@
1128
1128
  max-height: calc(var(--spacing) * 88);
1129
1129
  }
1130
1130
 
1131
+ .max-h-\[min\(16\.5rem\,round\(down\,var\(--available-height\,100dvh\)_-_0\.5rem\,2rem\)_\+_0\.5rem\)\] {
1132
+ max-height: min(16.5rem, round(down, var(--available-height, 100dvh) - .5rem, 2rem) + .5rem);
1133
+ }
1134
+
1131
1135
  .max-h-inherit {
1132
1136
  max-height: inherit;
1133
1137
  }
@@ -1220,6 +1224,10 @@
1220
1224
  width: calc(var(--spacing) * 5);
1221
1225
  }
1222
1226
 
1227
+ .w-7 {
1228
+ width: calc(var(--spacing) * 7);
1229
+ }
1230
+
1223
1231
  .w-10 {
1224
1232
  width: calc(var(--spacing) * 10);
1225
1233
  }
@@ -1280,10 +1288,6 @@
1280
1288
  max-width: calc(100% - 2rem);
1281
1289
  }
1282
1290
 
1283
- .max-w-\[max\(24rem\,var\(--anchor-width\)\)\] {
1284
- max-width: max(24rem, var(--anchor-width));
1285
- }
1286
-
1287
1291
  .max-w-\[max\(var\(--anchor-width\)\,min\(28rem\,var\(--available-width\)\)\)\] {
1288
1292
  max-width: max(var(--anchor-width), min(28rem, var(--available-width)));
1289
1293
  }
@@ -1304,10 +1308,6 @@
1304
1308
  max-width: var(--container-xs);
1305
1309
  }
1306
1310
 
1307
- .min-w-\(--anchor-width\) {
1308
- min-width: var(--anchor-width);
1309
- }
1310
-
1311
1311
  .min-w-\(--cell-size\) {
1312
1312
  min-width: var(--cell-size);
1313
1313
  }
@@ -1332,10 +1332,6 @@
1332
1332
  min-width: calc(var(--spacing) * 32);
1333
1333
  }
1334
1334
 
1335
- .min-w-36 {
1336
- min-width: calc(var(--spacing) * 36);
1337
- }
1338
-
1339
1335
  .min-w-40 {
1340
1336
  min-width: calc(var(--spacing) * 40);
1341
1337
  }
@@ -1348,12 +1344,8 @@
1348
1344
  min-width: 14ch;
1349
1345
  }
1350
1346
 
1351
- .min-w-\[96px\] {
1352
- min-width: 96px;
1353
- }
1354
-
1355
- .min-w-\[var\(--anchor-width\)\] {
1356
- min-width: var(--anchor-width);
1347
+ .min-w-\[max\(8rem\,var\(--anchor-width\)\)\] {
1348
+ min-width: max(8rem, var(--anchor-width));
1357
1349
  }
1358
1350
 
1359
1351
  .flex-1 {
@@ -1567,6 +1559,10 @@
1567
1559
  cursor: default;
1568
1560
  }
1569
1561
 
1562
+ .cursor-not-allowed {
1563
+ cursor: not-allowed;
1564
+ }
1565
+
1570
1566
  .cursor-pointer {
1571
1567
  cursor: pointer;
1572
1568
  }
@@ -1799,6 +1795,10 @@
1799
1795
  overflow-x: hidden !important;
1800
1796
  }
1801
1797
 
1798
+ .overflow-x-visible {
1799
+ overflow-x: visible;
1800
+ }
1801
+
1802
1802
  .overflow-y-auto {
1803
1803
  overflow-y: auto;
1804
1804
  }
@@ -1984,6 +1984,10 @@
1984
1984
  }
1985
1985
  }
1986
1986
 
1987
+ .border-destructive {
1988
+ border-color: var(--destructive);
1989
+ }
1990
+
1987
1991
  .border-input {
1988
1992
  border-color: var(--input);
1989
1993
  }
@@ -2377,10 +2381,6 @@
2377
2381
  padding-bottom: calc(var(--spacing) * 4);
2378
2382
  }
2379
2383
 
2380
- .pl-1\.5 {
2381
- padding-left: calc(var(--spacing) * 1.5);
2382
- }
2383
-
2384
2384
  .pl-2 {
2385
2385
  padding-left: calc(var(--spacing) * 2);
2386
2386
  }
@@ -2633,10 +2633,18 @@
2633
2633
  text-decoration-line: underline;
2634
2634
  }
2635
2635
 
2636
+ .underline-offset-3 {
2637
+ text-underline-offset: 3px;
2638
+ }
2639
+
2636
2640
  .underline-offset-4 {
2637
2641
  text-underline-offset: 4px;
2638
2642
  }
2639
2643
 
2644
+ .caret-transparent {
2645
+ caret-color: #0000;
2646
+ }
2647
+
2640
2648
  .opacity-0 {
2641
2649
  opacity: 0;
2642
2650
  }
@@ -2721,6 +2729,16 @@
2721
2729
  --tw-ring-color: var(--card);
2722
2730
  }
2723
2731
 
2732
+ .ring-destructive\/20 {
2733
+ --tw-ring-color: var(--destructive);
2734
+ }
2735
+
2736
+ @supports (color: color-mix(in lab, red, red)) {
2737
+ .ring-destructive\/20 {
2738
+ --tw-ring-color: color-mix(in oklab, var(--destructive) 20%, transparent);
2739
+ }
2740
+ }
2741
+
2724
2742
  .ring-foreground\/10 {
2725
2743
  --tw-ring-color: var(--foreground);
2726
2744
  }
@@ -3055,6 +3073,10 @@
3055
3073
  grid-column-start: 2;
3056
3074
  }
3057
3075
 
3076
+ .group-data-highlighted\:text-foreground:is(:where(.group)[data-highlighted] *) {
3077
+ color: var(--foreground);
3078
+ }
3079
+
3058
3080
  .group-data-indeterminate\/checkbox-indicator\:block:is(:where(.group\/checkbox-indicator)[data-indeterminate] *) {
3059
3081
  display: block;
3060
3082
  }
@@ -3561,6 +3583,14 @@
3561
3583
  background-color: var(--primary);
3562
3584
  }
3563
3585
 
3586
+ .selection\:bg-transparent ::selection {
3587
+ background-color: #0000;
3588
+ }
3589
+
3590
+ .selection\:bg-transparent::selection {
3591
+ background-color: #0000;
3592
+ }
3593
+
3564
3594
  .selection\:text-primary-foreground ::selection {
3565
3595
  color: var(--primary-foreground);
3566
3596
  }
@@ -3908,6 +3938,10 @@
3908
3938
  border-bottom-right-radius: var(--radius);
3909
3939
  }
3910
3940
 
3941
+ .empty\:hidden:empty {
3942
+ display: none;
3943
+ }
3944
+
3911
3945
  .empty\:p-0:empty {
3912
3946
  padding: 0;
3913
3947
  }
@@ -3961,6 +3995,16 @@
3961
3995
  }
3962
3996
  }
3963
3997
 
3998
+ .hover\:bg-foreground\/4:hover {
3999
+ background-color: var(--foreground);
4000
+ }
4001
+
4002
+ @supports (color: color-mix(in lab, red, red)) {
4003
+ .hover\:bg-foreground\/4:hover {
4004
+ background-color: color-mix(in oklab, var(--foreground) 4%, transparent);
4005
+ }
4006
+ }
4007
+
3964
4008
  .hover\:bg-foreground\/6:hover {
3965
4009
  background-color: var(--foreground);
3966
4010
  }
@@ -4048,6 +4092,16 @@
4048
4092
  background-color: var(--accent);
4049
4093
  }
4050
4094
 
4095
+ .focus\:bg-foreground\/10:focus {
4096
+ background-color: var(--foreground);
4097
+ }
4098
+
4099
+ @supports (color: color-mix(in lab, red, red)) {
4100
+ .focus\:bg-foreground\/10:focus {
4101
+ background-color: color-mix(in oklab, var(--foreground) 10%, transparent);
4102
+ }
4103
+ }
4104
+
4051
4105
  .focus\:bg-muted:focus {
4052
4106
  background-color: var(--muted);
4053
4107
  }
@@ -4477,6 +4531,25 @@
4477
4531
  padding: 0;
4478
4532
  }
4479
4533
 
4534
+ .has-\[input\:focus-visible\]\:border-ring:has(:is(input:focus-visible)) {
4535
+ border-color: var(--ring);
4536
+ }
4537
+
4538
+ .has-\[input\:focus-visible\]\:ring-3:has(:is(input:focus-visible)) {
4539
+ --tw-ring-shadow: var(--tw-ring-inset, ) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color, currentcolor);
4540
+ box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);
4541
+ }
4542
+
4543
+ .has-\[input\:focus-visible\]\:ring-ring\/50:has(:is(input:focus-visible)) {
4544
+ --tw-ring-color: var(--ring);
4545
+ }
4546
+
4547
+ @supports (color: color-mix(in lab, red, red)) {
4548
+ .has-\[input\:focus-visible\]\:ring-ring\/50:has(:is(input:focus-visible)) {
4549
+ --tw-ring-color: color-mix(in oklab, var(--ring) 50%, transparent);
4550
+ }
4551
+ }
4552
+
4480
4553
  .has-\[select\:disabled\]\:opacity-50:has(:is(select:disabled)) {
4481
4554
  opacity: .5;
4482
4555
  }
@@ -4715,6 +4788,20 @@
4715
4788
  opacity: 0;
4716
4789
  }
4717
4790
 
4791
+ .data-dragging\:border-ring[data-dragging] {
4792
+ border-color: var(--ring);
4793
+ }
4794
+
4795
+ .data-dragging\:bg-foreground\/6[data-dragging] {
4796
+ background-color: var(--foreground);
4797
+ }
4798
+
4799
+ @supports (color: color-mix(in lab, red, red)) {
4800
+ .data-dragging\:bg-foreground\/6[data-dragging] {
4801
+ background-color: color-mix(in oklab, var(--foreground) 6%, transparent);
4802
+ }
4803
+ }
4804
+
4718
4805
  .data-ending-style\:scale-90[data-ending-style] {
4719
4806
  --tw-scale-x: 90%;
4720
4807
  --tw-scale-y: 90%;
@@ -4743,6 +4830,10 @@
4743
4830
  opacity: 1;
4744
4831
  }
4745
4832
 
4833
+ .data-has-overflow-x\:pb-\(--scroll-bar-reserve\)[data-has-overflow-x] {
4834
+ padding-bottom: var(--scroll-bar-reserve);
4835
+ }
4836
+
4746
4837
  .data-highlighted\:bg-foreground\/6[data-highlighted] {
4747
4838
  background-color: var(--foreground);
4748
4839
  }
@@ -4813,10 +4904,6 @@
4813
4904
  border-color: var(--ring);
4814
4905
  }
4815
4906
 
4816
- .data-popup-open\:bg-accent[data-popup-open] {
4817
- background-color: var(--accent);
4818
- }
4819
-
4820
4907
  .data-popup-open\:bg-foreground\/6[data-popup-open] {
4821
4908
  background-color: var(--foreground);
4822
4909
  }
@@ -4837,10 +4924,6 @@
4837
4924
  }
4838
4925
  }
4839
4926
 
4840
- .data-popup-open\:text-accent-foreground[data-popup-open] {
4841
- color: var(--accent-foreground);
4842
- }
4843
-
4844
4927
  .data-popup-open\:ring-3[data-popup-open] {
4845
4928
  --tw-ring-shadow: var(--tw-ring-inset, ) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color, currentcolor);
4846
4929
  box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);
@@ -5885,6 +5968,16 @@
5885
5968
  translate: var(--tw-translate-x) var(--tw-translate-y);
5886
5969
  }
5887
5970
 
5971
+ .dark\:border-destructive\/50:is(.dark *) {
5972
+ border-color: var(--destructive);
5973
+ }
5974
+
5975
+ @supports (color: color-mix(in lab, red, red)) {
5976
+ .dark\:border-destructive\/50:is(.dark *) {
5977
+ border-color: color-mix(in oklab, var(--destructive) 50%, transparent);
5978
+ }
5979
+ }
5980
+
5888
5981
  .dark\:border-input:is(.dark *) {
5889
5982
  border-color: var(--input);
5890
5983
  }
@@ -5975,6 +6068,16 @@
5975
6068
  color: var(--color-red-300);
5976
6069
  }
5977
6070
 
6071
+ .dark\:ring-destructive\/40:is(.dark *) {
6072
+ --tw-ring-color: var(--destructive);
6073
+ }
6074
+
6075
+ @supports (color: color-mix(in lab, red, red)) {
6076
+ .dark\:ring-destructive\/40:is(.dark *) {
6077
+ --tw-ring-color: color-mix(in oklab, var(--destructive) 40%, transparent);
6078
+ }
6079
+ }
6080
+
5978
6081
  .dark\:group-data-checked\/questionnaire-choice\:bg-primary:is(.dark *):is(:is(:where(.group\/questionnaire-choice):where([data-state="checked"]), :where(.group\/questionnaire-choice):where([data-checked]:not([data-checked="false"]))) *) {
5979
6082
  background-color: var(--primary);
5980
6083
  }
@@ -6750,6 +6853,12 @@
6750
6853
  border-bottom-width: 1px;
6751
6854
  }
6752
6855
 
6856
+ @media (hover: hover) {
6857
+ .\[\&_tr\]\:hover\:bg-transparent tr:hover {
6858
+ background-color: #0000;
6859
+ }
6860
+ }
6861
+
6753
6862
  .\[\&_tr\:last-child\]\:border-0 tr:last-child {
6754
6863
  border-style: var(--tw-border-style);
6755
6864
  border-width: 0;
@@ -6991,14 +7100,6 @@
6991
7100
  color: currentColor;
6992
7101
  }
6993
7102
 
6994
- :is(.focus\:\*\:\[svg\]\:text-accent-foreground:focus > *):is(svg) {
6995
- color: var(--accent-foreground);
6996
- }
6997
-
6998
- :is(.data-\[variant\=destructive\]\:\*\:\[svg\]\:text-destructive[data-variant="destructive"] > *):is(svg) {
6999
- color: var(--destructive);
7000
- }
7001
-
7002
7103
  :is(.data-\[variant\=destructive\]\:\*\:\[svg\]\:text-destructive\![data-variant="destructive"] > *):is(svg) {
7003
7104
  color: var(--destructive) !important;
7004
7105
  }
@@ -7710,6 +7811,10 @@
7710
7811
  initial-value: 0;
7711
7812
  }
7712
7813
 
7814
+ [data-slot="scroll-area"] {
7815
+ --scroll-bar-reserve: calc(var(--scroll-bar-size) + var(--scroll-bar-gap));
7816
+ }
7817
+
7713
7818
  [data-slot="scroll-area-scrollbar"] {
7714
7819
  --scroll-bar-offset-top: calc(var(--scroll-bar-gap) + var(--scroll-bar-start));
7715
7820
  --scroll-bar-length: calc(100% - var(--scroll-bar-gap) * 2 - var(--scroll-bar-start));
@@ -0,0 +1,2 @@
1
+ import { DEFAULT_TIME_FIELD_LABELS, EMPTY_TIME, TimeField, editSegment, formatTime, localeHourCycle, parseTime, rangeOf, stepValue, typeDigit } from "./ui/src/components/edyn/time-field/time-field.js";
2
+ export { DEFAULT_TIME_FIELD_LABELS, EMPTY_TIME, TimeField, editSegment, formatTime, localeHourCycle, parseTime, rangeOf, stepValue, typeDigit };
@@ -0,0 +1,90 @@
1
+ import { ComponentPropsWithoutRef, ReactNode } from 'react';
2
+ export type TFileRejectReason = 'type' | 'size' | 'count';
3
+ export interface IFileRejection {
4
+ file: File;
5
+ reason: TFileRejectReason;
6
+ }
7
+ /** The words a FileInput says and announces. Pass the ones to change. */
8
+ export interface IFileInputLabels {
9
+ /** The prompt in the drop area when it takes one file, before the "browse" link. */
10
+ dropOne: string;
11
+ /** The same, when it takes several. */
12
+ dropMany: string;
13
+ browse: string;
14
+ /** The accessible name of the file chooser itself, when the caller gives it no name of its own. */
15
+ chooseOne: string;
16
+ chooseMany: string;
17
+ /** The accessible name of the list of chosen files. */
18
+ list: string;
19
+ remove: (name: string) => string;
20
+ /** Announced when files are added. */
21
+ added: (count: number) => string;
22
+ /** Announced when a file is taken out. */
23
+ removed: (name: string) => string;
24
+ /** Said, and shown, for a file that was refused. */
25
+ rejection: (name: string, reason: TFileRejectReason, limit: string) => string;
26
+ }
27
+ export declare const DEFAULT_FILE_INPUT_LABELS: IFileInputLabels;
28
+ /** 1,536 bytes as "1.5 KB": the size a person reads next to a file's name. */
29
+ export declare const formatBytes: (bytes: number) => string;
30
+ /** Whether a file is one `accept` allows: an extension (`.pdf`), a type (`application/pdf`) or a family of types (`image/*`). No `accept` allows all. */
31
+ export declare const matchesAccept: (file: {
32
+ name: string;
33
+ type: string;
34
+ }, accept: string | undefined) => boolean;
35
+ export interface ISortFilesInput {
36
+ incoming: readonly File[];
37
+ current: readonly File[];
38
+ multiple: boolean;
39
+ accept?: string;
40
+ maxSize?: number;
41
+ maxFiles?: number;
42
+ }
43
+ /**
44
+ * Which of the files just offered are taken, and which are refused and why. A file already chosen is skipped without a word. With one
45
+ * file allowed, the first acceptable one replaces what was chosen and the rest are refused as too many.
46
+ */
47
+ export declare const sortFiles: ({ incoming, current, multiple, accept, maxSize, maxFiles, }: ISortFilesInput) => {
48
+ accepted: File[];
49
+ rejected: IFileRejection[];
50
+ };
51
+ export interface IFileInputProps extends Omit<ComponentPropsWithoutRef<'div'>, 'defaultValue' | 'onChange' | 'children' | 'id'> {
52
+ /** The chosen files. Leave it out and the field keeps them itself. */
53
+ value?: readonly File[];
54
+ defaultValue?: readonly File[];
55
+ onValueChange?: (files: File[]) => void;
56
+ /** What the picker offers, and what a drop is held to: extensions (`.pdf`), types (`application/pdf`) or families (`image/*`). */
57
+ accept?: string;
58
+ /** Several files, added to each other, instead of one that is replaced. */
59
+ multiple?: boolean;
60
+ /** The most a file may weigh, in bytes. */
61
+ maxSize?: number;
62
+ /** The most files that may be chosen. Several-file fields only. */
63
+ maxFiles?: number;
64
+ /** Called with the files that were refused, each with the reason. They are also listed under the field. */
65
+ onReject?: (rejections: IFileRejection[]) => void;
66
+ disabled?: boolean;
67
+ invalid?: boolean;
68
+ required?: boolean;
69
+ /** Submits the chosen files with a form, under this name. */
70
+ name?: string;
71
+ /** For a `<Label htmlFor>` to name the field. */
72
+ id?: string;
73
+ /** What the field accepts, in words ("PDF or PNG, up to 5 MB"), read with the field. */
74
+ hint?: ReactNode;
75
+ labels?: Partial<IFileInputLabels>;
76
+ 'aria-label'?: string;
77
+ 'aria-labelledby'?: string;
78
+ }
79
+ /**
80
+ * Chooses files by picking them or by dropping them on the field, in the kit's look. It exists so an app does not fall back to
81
+ * `<input type="file">`, which cannot be styled and has no list of what was chosen.
82
+ *
83
+ * The control is a real file input laid over the whole drop area, so Tab, Enter and Space, the system's file dialog, a drop and a
84
+ * screen reader's name for it all come from the browser. What the browser lacks is added around it: the list of chosen files with a
85
+ * button to take each out, the checks against `accept`, `maxSize` and `maxFiles` (a drop skips the dialog's own filter), and a
86
+ * live region that says what was added, removed or refused.
87
+ *
88
+ * Name the field with `aria-label`, `aria-labelledby` or a `<Label htmlFor={id}>`; with none of those it is named "Choose files".
89
+ */
90
+ export declare const FileInput: ({ value, defaultValue, onValueChange, accept, multiple, maxSize, maxFiles, onReject, disabled, invalid, required, name, id, hint, labels: labelOverrides, className, "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, ...rest }: IFileInputProps) => import('react').JSX.Element;