@nextlyhq/ui 0.0.2-alpha.74 → 0.0.2-alpha.75
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.
- package/dist/index.cjs +269 -51
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +151 -17
- package/dist/index.d.ts +151 -17
- package/dist/index.mjs +267 -53
- package/dist/index.mjs.map +1 -1
- package/dist/styles.css +1 -1
- package/dist/styles.scoped.css +1 -1
- package/dist/tailwind-preset.cjs +20 -0
- package/dist/tailwind-preset.cjs.map +1 -1
- package/dist/tailwind-preset.d.cts +20 -0
- package/dist/tailwind-preset.d.ts +20 -0
- package/dist/tailwind-preset.mjs +20 -0
- package/dist/tailwind-preset.mjs.map +1 -1
- package/dist/theme.css +123 -3
- package/package.json +4 -4
package/dist/index.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
2
|
import * as React$1 from "react";
|
|
3
|
-
import { ButtonHTMLAttributes, ComponentProps, ComponentPropsWithoutRef, ElementRef, ForwardRefExoticComponent, HTMLAttributes, JSX, PropsWithoutRef, ReactNode, RefAttributes, TextareaHTMLAttributes } from "react";
|
|
3
|
+
import { AnchorHTMLAttributes, ButtonHTMLAttributes, ComponentProps, ComponentPropsWithoutRef, ElementRef, ForwardRefExoticComponent, HTMLAttributes, JSX, PropsWithoutRef, ReactNode, RefAttributes, TextareaHTMLAttributes } from "react";
|
|
4
4
|
import { VariantProps, cva } from "class-variance-authority";
|
|
5
5
|
import { Root } from "@radix-ui/react-label";
|
|
6
6
|
import * as SeparatorPrimitive from "@radix-ui/react-separator";
|
|
@@ -144,7 +144,6 @@ interface FormLabelWithTooltipProps extends React$1.ComponentPropsWithoutRef<typ
|
|
|
144
144
|
}
|
|
145
145
|
/** @public */
|
|
146
146
|
export declare const FormLabelWithTooltip: React$1.ForwardRefExoticComponent<React$1.PropsWithoutRef<FormLabelWithTooltipProps> & React$1.RefAttributes<React$1.ElementRef<typeof Label>>>;
|
|
147
|
-
/** The arms `badgeVariants` is built from. Its type is read from them: {@link VariantsFn}. */
|
|
148
147
|
declare const BADGE_VARIANT_MAP: {
|
|
149
148
|
variant: {
|
|
150
149
|
default: string;
|
|
@@ -152,6 +151,7 @@ declare const BADGE_VARIANT_MAP: {
|
|
|
152
151
|
success: string;
|
|
153
152
|
warning: string;
|
|
154
153
|
destructive: string;
|
|
154
|
+
info: string;
|
|
155
155
|
outline: string;
|
|
156
156
|
};
|
|
157
157
|
};
|
|
@@ -173,22 +173,21 @@ declare const BADGE_VARIANT_MAP: {
|
|
|
173
173
|
* - Padding: 2px 10px (vertical × horizontal)
|
|
174
174
|
* - Border radius: Full (pill shape)
|
|
175
175
|
* - Font: 12px (text-xs), medium weight (500)
|
|
176
|
-
* -
|
|
176
|
+
* - Status variants (success, warning, destructive, info): a neutral chip with
|
|
177
|
+
* a 6px dot in the status's solid colour before the label
|
|
177
178
|
*
|
|
178
|
-
* Variants
|
|
179
|
-
* - default:
|
|
180
|
-
* - primary:
|
|
181
|
-
* - success:
|
|
182
|
-
* -
|
|
183
|
-
* - destructive: Light red background
|
|
184
|
-
* - outline: Transparent background with border border-border
|
|
179
|
+
* Variants:
|
|
180
|
+
* - default: muted background
|
|
181
|
+
* - primary: primary tint
|
|
182
|
+
* - success, warning, destructive, info: quiet chip with a status dot
|
|
183
|
+
* - outline: transparent background with a border
|
|
185
184
|
* @experimental
|
|
186
185
|
*/
|
|
187
186
|
declare const badgeVariants: VariantsFn<typeof BADGE_VARIANT_MAP>;
|
|
188
187
|
/** @public */
|
|
189
188
|
interface BadgeProps extends HTMLAttributes<HTMLDivElement>, VariantProps<typeof badgeVariants> {}
|
|
190
189
|
/** @public */
|
|
191
|
-
declare function Badge({ className, variant, ...props }: BadgeProps): JSX.Element;
|
|
190
|
+
declare function Badge({ className, variant, children, ...props }: BadgeProps): JSX.Element;
|
|
192
191
|
/** The arms `cardVariants` is built from. Its type is read from them: {@link VariantsFn}. */
|
|
193
192
|
declare const CARD_VARIANT_MAP: {
|
|
194
193
|
variant: {
|
|
@@ -342,11 +341,12 @@ declare const ALERT_VARIANT_MAP: {
|
|
|
342
341
|
* - Padding: 16px (p-4)
|
|
343
342
|
* - Border radius: `rounded-md`, one step tighter than Card's `rounded-lg`
|
|
344
343
|
* for inline/flow content vs. larger container components
|
|
345
|
-
* - Border: 1px
|
|
344
|
+
* - Border: 1px; the card border for info and success, the status border for
|
|
345
|
+
* warning and destructive
|
|
346
346
|
* - Shadow: sm (subtle elevation)
|
|
347
347
|
* - Font: 14px (text-sm)
|
|
348
348
|
* - Layout: Flex with gap-3 for icon/content spacing
|
|
349
|
-
* - Colors:
|
|
349
|
+
* - Colors: the page's foreground text; the icon in the status's text colour
|
|
350
350
|
*
|
|
351
351
|
* Variants (4 total):
|
|
352
352
|
* - info (default): Blue - informational messages, neutral announcements
|
|
@@ -524,7 +524,14 @@ declare function Separator({ className, orientation, decorative, ...props }: Rea
|
|
|
524
524
|
*/
|
|
525
525
|
declare const Skeleton: React$1.ForwardRefExoticComponent<React$1.PropsWithoutRef<SkeletonProps> & React$1.RefAttributes<HTMLDivElement>>;
|
|
526
526
|
/** @experimental */
|
|
527
|
-
type SkeletonProps = React$1.ComponentProps<"div"
|
|
527
|
+
type SkeletonProps = React$1.ComponentProps<"div"> & {
|
|
528
|
+
/**
|
|
529
|
+
* Draw a still outline: no pulse, on the `secondary` surface. For a page's
|
|
530
|
+
* outline shown while its data is on its way, where motion would read as
|
|
531
|
+
* the page itself moving.
|
|
532
|
+
*/
|
|
533
|
+
still?: boolean;
|
|
534
|
+
};
|
|
528
535
|
/** The arms `progressVariants` is built from. Its type is read from them: {@link VariantsFn}. */
|
|
529
536
|
declare const PROGRESS_VARIANT_MAP: {
|
|
530
537
|
variant: {
|
|
@@ -568,7 +575,7 @@ type ProgressProps = {
|
|
|
568
575
|
* Visual variant for different states
|
|
569
576
|
*
|
|
570
577
|
* - `default`: Primary blue (bg-primary-500)
|
|
571
|
-
* - `success`: Green (bg-success-
|
|
578
|
+
* - `success`: Green (bg-success-solid)
|
|
572
579
|
* - `error`: Red (bg-destructive)
|
|
573
580
|
*
|
|
574
581
|
* @default "default"
|
|
@@ -1855,7 +1862,17 @@ declare const SHEET_VARIANT_MAP: {
|
|
|
1855
1862
|
*/
|
|
1856
1863
|
declare const sheetVariants: VariantsFn<typeof SHEET_VARIANT_MAP>;
|
|
1857
1864
|
/** @public */
|
|
1858
|
-
interface SheetContentProps extends React$1.ComponentPropsWithoutRef<typeof DialogPrimitive.Content>, VariantProps<typeof sheetVariants> {
|
|
1865
|
+
interface SheetContentProps extends React$1.ComponentPropsWithoutRef<typeof DialogPrimitive.Content>, VariantProps<typeof sheetVariants> {
|
|
1866
|
+
/**
|
|
1867
|
+
* For a bottom sheet: a grab strip at its top that drags the sheet down
|
|
1868
|
+
* and closes it past a quarter of its height or on a quick flick. Escape
|
|
1869
|
+
* and the sheet's own close control still close it, so the strip is a
|
|
1870
|
+
* pointer affordance only and is hidden from assistive technology.
|
|
1871
|
+
*/
|
|
1872
|
+
dragHandle?: boolean;
|
|
1873
|
+
}
|
|
1874
|
+
/** Whether a drag released at `distance` after `elapsed` ms closes the sheet. */
|
|
1875
|
+
declare function dragCloses(distance: number, elapsed: number, height: number): boolean;
|
|
1859
1876
|
/**
|
|
1860
1877
|
* SheetContent
|
|
1861
1878
|
*
|
|
@@ -3426,6 +3443,14 @@ interface PageShellProps extends HTMLAttributes<HTMLDivElement> {
|
|
|
3426
3443
|
* full-width page is still inset from the panel's edge.
|
|
3427
3444
|
*/
|
|
3428
3445
|
width?: "form" | "wide" | "full";
|
|
3446
|
+
/**
|
|
3447
|
+
* Where a bounded column sits on a wide screen. `start` (the default) keeps
|
|
3448
|
+
* it under the page's left edge, where the header, the panel and every list
|
|
3449
|
+
* begin, so moving between a list and its form shifts nothing sideways.
|
|
3450
|
+
* `center` balances it between equal gutters. A `full` column fills the row
|
|
3451
|
+
* either way.
|
|
3452
|
+
*/
|
|
3453
|
+
align?: "start" | "center";
|
|
3429
3454
|
}
|
|
3430
3455
|
/**
|
|
3431
3456
|
* What each named width resolves to, owned here because this is what applies it.
|
|
@@ -3510,6 +3535,21 @@ interface PageHeaderProps extends Omit<HTMLAttributes<HTMLElement>, "title"> {
|
|
|
3510
3535
|
breadcrumbs?: ReactNode;
|
|
3511
3536
|
/** Page-level actions, trailing the title on one line where there is room. */
|
|
3512
3537
|
actions?: ReactNode;
|
|
3538
|
+
/**
|
|
3539
|
+
* A row of tabs under the title, for a page whose sections each have their
|
|
3540
|
+
* own address (`PageTabs` with a `PageTab` per section). Rendered across the
|
|
3541
|
+
* header's full width, below the title and actions.
|
|
3542
|
+
*/
|
|
3543
|
+
tabs?: ReactNode;
|
|
3544
|
+
/**
|
|
3545
|
+
* The `id` of the title's `h1`, for a region that names itself by the page's
|
|
3546
|
+
* title (`aria-labelledby` on the page's form).
|
|
3547
|
+
*/
|
|
3548
|
+
titleId?: string;
|
|
3549
|
+
/** A leading visual, such as a plugin's icon tile, before the title. */
|
|
3550
|
+
media?: ReactNode;
|
|
3551
|
+
/** Small chips beside the title: a version, a status, a category. */
|
|
3552
|
+
meta?: ReactNode;
|
|
3513
3553
|
}
|
|
3514
3554
|
/**
|
|
3515
3555
|
* A page's own identity — its trail, its name, its one-line summary and its
|
|
@@ -3536,5 +3576,99 @@ interface PageHeaderProps extends Omit<HTMLAttributes<HTMLElement>, "title"> {
|
|
|
3536
3576
|
* @experimental
|
|
3537
3577
|
*/
|
|
3538
3578
|
export declare const PageHeader: ForwardRefExoticComponent<PropsWithoutRef<PageHeaderProps> & RefAttributes<HTMLElement>>;
|
|
3539
|
-
|
|
3579
|
+
/** @experimental */
|
|
3580
|
+
interface PageTabsProps extends HTMLAttributes<HTMLElement> {
|
|
3581
|
+
/** What the sections are, for assistive technology (`"Form sections"`). */
|
|
3582
|
+
label: string;
|
|
3583
|
+
}
|
|
3584
|
+
/**
|
|
3585
|
+
* The tab row of a page whose sections each have their own address. A labelled
|
|
3586
|
+
* `nav` of links rather than an ARIA tablist: every tab changes the URL, and a
|
|
3587
|
+
* link inside `role="tab"` breaks the tabs pattern's keyboard and announcement
|
|
3588
|
+
* contract. The current section is marked with `aria-current="page"` by
|
|
3589
|
+
* `PageTab`.
|
|
3590
|
+
* @experimental
|
|
3591
|
+
*/
|
|
3592
|
+
export declare const PageTabs: ForwardRefExoticComponent<PropsWithoutRef<PageTabsProps> & RefAttributes<HTMLElement>>;
|
|
3593
|
+
/**
|
|
3594
|
+
* The anchor attributes a tab passes through. `aria-current` is not among
|
|
3595
|
+
* them: it is derived from `current`, so the tab is announced as current
|
|
3596
|
+
* exactly when it is drawn as current.
|
|
3597
|
+
*/
|
|
3598
|
+
type PageTabAnchorProps = Omit<AnchorHTMLAttributes<HTMLAnchorElement>, "aria-current" | "href">;
|
|
3599
|
+
/**
|
|
3600
|
+
* A tab changes the address, so it always has a destination: its own `href`,
|
|
3601
|
+
* or, with `asChild`, the router link it wraps.
|
|
3602
|
+
* @experimental
|
|
3603
|
+
*/
|
|
3604
|
+
type PageTabProps = PageTabAnchorProps & {
|
|
3605
|
+
/** Whether this tab is the section being shown. */
|
|
3606
|
+
current?: boolean;
|
|
3607
|
+
} & ({
|
|
3608
|
+
/** Where the tab leads. */
|
|
3609
|
+
href: string;
|
|
3610
|
+
asChild?: false;
|
|
3611
|
+
} | {
|
|
3612
|
+
/**
|
|
3613
|
+
* Render the caller's own link element (a router link) in place of
|
|
3614
|
+
* an `<a>`; that element carries the destination. The tab keeps its
|
|
3615
|
+
* look and its `aria-current`.
|
|
3616
|
+
*/
|
|
3617
|
+
asChild: true;
|
|
3618
|
+
href?: undefined;
|
|
3619
|
+
});
|
|
3620
|
+
/**
|
|
3621
|
+
* One section of a `PageTabs` row: a link, underlined when current.
|
|
3622
|
+
* @experimental
|
|
3623
|
+
*/
|
|
3624
|
+
export declare const PageTab: ForwardRefExoticComponent<PropsWithoutRef<PageTabProps> & RefAttributes<HTMLAnchorElement>>;
|
|
3625
|
+
/**
|
|
3626
|
+
* The four kinds of page the admin draws, each with one width.
|
|
3627
|
+
*
|
|
3628
|
+
* - `list`: full width within the gutter (entries, users, keys, webhooks),
|
|
3629
|
+
* drawn as a padded block rather than a grid, so a page that hands its own
|
|
3630
|
+
* height down through `height: 100%` (a split pane, a media grid) keeps it.
|
|
3631
|
+
* - `form`: a 56rem column under the page's left edge (settings, create and
|
|
3632
|
+
* edit pages).
|
|
3633
|
+
* - `editor`: full width with no gutter and no padding: the editor draws its
|
|
3634
|
+
* own field column (inset by the gutter, and measured) and a side panel that
|
|
3635
|
+
* meets the window's edge.
|
|
3636
|
+
* - `workspace`: no gutter and no padding, for a page that lays out its own
|
|
3637
|
+
* surface (the dashboard, a builder canvas).
|
|
3638
|
+
* @experimental
|
|
3639
|
+
*/
|
|
3640
|
+
type PageType = "list" | "form" | "editor" | "workspace";
|
|
3641
|
+
/** @experimental */
|
|
3642
|
+
interface PageFrameListenerProps {
|
|
3643
|
+
/**
|
|
3644
|
+
* Called with the type of the outermost `PageFrame` drawn inside, as it
|
|
3645
|
+
* mounts or changes, and with `null` once none is left.
|
|
3646
|
+
*/
|
|
3647
|
+
onFrame: (type: PageType | null) => void;
|
|
3648
|
+
children?: ReactNode;
|
|
3649
|
+
}
|
|
3650
|
+
/**
|
|
3651
|
+
* Hears whether the content inside it draws a `PageFrame`, for a host that
|
|
3652
|
+
* gives unframed content a frame of its own and must not frame content twice.
|
|
3653
|
+
* Read from the frames themselves rather than from what the content is called,
|
|
3654
|
+
* so a page that draws a frame through any component is heard the same way.
|
|
3655
|
+
*
|
|
3656
|
+
* The frame claims in a layout effect, so a host that changes its own markup
|
|
3657
|
+
* in answer does so before the first paint.
|
|
3658
|
+
* @experimental
|
|
3659
|
+
*/
|
|
3660
|
+
export declare function PageFrameListener({ onFrame, children }: PageFrameListenerProps): JSX.Element;
|
|
3661
|
+
/** @experimental */
|
|
3662
|
+
interface PageFrameProps extends HTMLAttributes<HTMLDivElement> {
|
|
3663
|
+
/** Which kind of page this is; it decides the width. */
|
|
3664
|
+
type: PageType;
|
|
3665
|
+
}
|
|
3666
|
+
/**
|
|
3667
|
+
* A page's frame: the width and gutter its type gives it. A page says what it
|
|
3668
|
+
* is, and the frame decides how wide that is, so two pages of one type can
|
|
3669
|
+
* never drift apart.
|
|
3670
|
+
* @experimental
|
|
3671
|
+
*/
|
|
3672
|
+
export declare const PageFrame: ForwardRefExoticComponent<PropsWithoutRef<PageFrameProps> & RefAttributes<HTMLDivElement>>;
|
|
3673
|
+
export { Accordion, AccordionContent, type AccordionContentProps, AccordionItem, type AccordionItemProps, type AccordionProps, AccordionTrigger, type AccordionTriggerProps, type ActionCallbacks, type ActiveShortcut, Alert, AlertDescription, type AlertDescriptionProps, AlertDialog, AlertDialogAction, type AlertDialogActionProps, AlertDialogCancel, type AlertDialogCancelProps, AlertDialogContent, type AlertDialogContentProps, AlertDialogDescription, type AlertDialogDescriptionProps, AlertDialogFooter, type AlertDialogFooterProps, AlertDialogHeader, type AlertDialogHeaderProps, AlertDialogOverlay, type AlertDialogOverlayProps, AlertDialogPortal, AlertDialogTitle, type AlertDialogTitleProps, AlertDialogTrigger, type AlertProps, AlertTitle, type AlertTitleProps, Avatar, AvatarFallback, type AvatarFallbackProps, AvatarImage, type AvatarImageProps, type AvatarProps, Badge, type BadgeProps, type BleedProps, Button, type ButtonProps, Card, CardAction, type CardActionProps, CardContent, type CardContentProps, CardDescription, type CardDescriptionProps, CardFooter, type CardFooterProps, CardHeader, type CardHeaderProps, type CardProps, CardTitle, type CardTitleProps, Checkbox, Collapsible, CollapsibleContent, CollapsibleTrigger, type ColorPickerProps, type ColorSwatch, Command, CommandDialog, type CommandDialogProps, CommandEmpty, type CommandEmptyProps, CommandGroup, type CommandGroupProps, CommandInput, type CommandInputProps, CommandItem, type CommandItemProps, CommandList, type CommandListProps, type CommandProps, CommandSeparator, type CommandSeparatorProps, CommandShortcut, type CommandShortcutProps, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, type DataFetcher, Dialog, DialogClose, DialogContent, type DialogContentProps, DialogDescription, type DialogDescriptionProps, DialogFooter, type DialogFooterProps, DialogHeader, type DialogHeaderProps, DialogOverlay, type DialogOverlayProps, DialogPortal, DialogTitle, type DialogTitleProps, DialogTrigger, DropdownMenu, DropdownMenuCheckboxItem, type DropdownMenuCheckboxItemProps, DropdownMenuContent, type DropdownMenuContentProps, DropdownMenuGroup, DropdownMenuItem, type DropdownMenuItemProps, DropdownMenuLabel, type DropdownMenuLabelProps, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, type DropdownMenuRadioItemProps, DropdownMenuSeparator, type DropdownMenuSeparatorProps, DropdownMenuShortcut, type DropdownMenuShortcutProps, DropdownMenuSub, DropdownMenuSubContent, type DropdownMenuSubContentProps, DropdownMenuSubTrigger, type DropdownMenuSubTriggerProps, DropdownMenuTrigger, type FieldShellProps, type FieldShellRenderProps, type FieldWidth, type FilterInfo, type FormActionsProps, type FormLabelWithTooltipProps, type FormSectionProps, type GridProps, type IconFieldProps, type IconGlyphProps, type IconPickerProps, type IconSource, type IconSourceIcon, Input, type InputProps, type KeyChord, type KeySequence, Label, type ListResponse, type ModifierState, type PageFrameListenerProps, type PageFrameProps, type PageHeaderProps, type PageShellProps, type PageTabProps, type PageTabsProps, type PageType, type PaginationConfig, type PaginationMeta, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, PortalProvider, Progress, type ProgressProps, RadioGroup, RadioGroupItem, ResizableHandle, ResizablePanel, ResizablePanelGroup, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, type SelectTriggerProps, SelectValue, Separator, Sheet, SheetClose, type SheetCloseProps, SheetContent, type SheetContentProps, type SheetContentRef, SheetDescription, type SheetDescriptionProps, type SheetDescriptionRef, SheetFooter, type SheetFooterProps, SheetHeader, type SheetHeaderProps, SheetOverlay, type SheetOverlayProps, type SheetOverlayRef, SheetPortal, type SheetProps, SheetTitle, type SheetTitleProps, type SheetTitleRef, SheetTrigger, type SheetTriggerProps, type ShortcutBinding, type ShortcutLayerOptions, type ShortcutManager, type ShortcutManagerOptions, type ShortcutProviderProps, type ShortcutRegistration, Skeleton, type SkeletonProps, Slider, type SliderProps, type SliderThumbProps, type SortInfo, Spinner, type SpinnerProps, type StackProps, type StatProps, Switch, Table, TableBody, TableCaption, TableCell, type TableEmptyProps, type TableErrorProps, TableFooter, TableHead, TableHeader, type TableParams, TableRow, type TableSearchProps, type TableSkeletonProps, Tabs, TabsContent, type TabsContentProps, TabsList, type TabsListProps, type TabsProps, TabsTrigger, type TabsTriggerProps, Textarea, type ToasterProps, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, type TreeNode, TreeView, type TreeViewProps, type UseShortcutsOptions, alertVariants, badgeVariants, buttonVariants, cardVariants, dialogContentVariants, inputVariants, selectTriggerVariants, sheetVariants, spinnerVariants, toast, usePortalContainer };
|
|
3540
3674
|
//# sourceMappingURL=index.d.cts.map
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
|
|
2
2
|
import { VariantProps, cva } from "class-variance-authority";
|
|
3
3
|
import * as React$1 from "react";
|
|
4
|
-
import { ButtonHTMLAttributes, ComponentProps, ComponentPropsWithoutRef, ElementRef, ForwardRefExoticComponent, HTMLAttributes, JSX, PropsWithoutRef, ReactNode, RefAttributes, TextareaHTMLAttributes } from "react";
|
|
4
|
+
import { AnchorHTMLAttributes, ButtonHTMLAttributes, ComponentProps, ComponentPropsWithoutRef, ElementRef, ForwardRefExoticComponent, HTMLAttributes, JSX, PropsWithoutRef, ReactNode, RefAttributes, TextareaHTMLAttributes } from "react";
|
|
5
5
|
import { Root } from "@radix-ui/react-label";
|
|
6
6
|
import { LucideProps } from "lucide-react";
|
|
7
7
|
import { Content, Provider, Root as Root$1, Trigger } from "@radix-ui/react-tooltip";
|
|
@@ -144,7 +144,6 @@ interface FormLabelWithTooltipProps extends React$1.ComponentPropsWithoutRef<typ
|
|
|
144
144
|
}
|
|
145
145
|
/** @public */
|
|
146
146
|
export declare const FormLabelWithTooltip: React$1.ForwardRefExoticComponent<React$1.PropsWithoutRef<FormLabelWithTooltipProps> & React$1.RefAttributes<React$1.ElementRef<typeof Label>>>;
|
|
147
|
-
/** The arms `badgeVariants` is built from. Its type is read from them: {@link VariantsFn}. */
|
|
148
147
|
declare const BADGE_VARIANT_MAP: {
|
|
149
148
|
variant: {
|
|
150
149
|
default: string;
|
|
@@ -152,6 +151,7 @@ declare const BADGE_VARIANT_MAP: {
|
|
|
152
151
|
success: string;
|
|
153
152
|
warning: string;
|
|
154
153
|
destructive: string;
|
|
154
|
+
info: string;
|
|
155
155
|
outline: string;
|
|
156
156
|
};
|
|
157
157
|
};
|
|
@@ -173,22 +173,21 @@ declare const BADGE_VARIANT_MAP: {
|
|
|
173
173
|
* - Padding: 2px 10px (vertical × horizontal)
|
|
174
174
|
* - Border radius: Full (pill shape)
|
|
175
175
|
* - Font: 12px (text-xs), medium weight (500)
|
|
176
|
-
* -
|
|
176
|
+
* - Status variants (success, warning, destructive, info): a neutral chip with
|
|
177
|
+
* a 6px dot in the status's solid colour before the label
|
|
177
178
|
*
|
|
178
|
-
* Variants
|
|
179
|
-
* - default:
|
|
180
|
-
* - primary:
|
|
181
|
-
* - success:
|
|
182
|
-
* -
|
|
183
|
-
* - destructive: Light red background
|
|
184
|
-
* - outline: Transparent background with border border-border
|
|
179
|
+
* Variants:
|
|
180
|
+
* - default: muted background
|
|
181
|
+
* - primary: primary tint
|
|
182
|
+
* - success, warning, destructive, info: quiet chip with a status dot
|
|
183
|
+
* - outline: transparent background with a border
|
|
185
184
|
* @experimental
|
|
186
185
|
*/
|
|
187
186
|
declare const badgeVariants: VariantsFn<typeof BADGE_VARIANT_MAP>;
|
|
188
187
|
/** @public */
|
|
189
188
|
interface BadgeProps extends HTMLAttributes<HTMLDivElement>, VariantProps<typeof badgeVariants> {}
|
|
190
189
|
/** @public */
|
|
191
|
-
declare function Badge({ className, variant, ...props }: BadgeProps): JSX.Element;
|
|
190
|
+
declare function Badge({ className, variant, children, ...props }: BadgeProps): JSX.Element;
|
|
192
191
|
/** The arms `cardVariants` is built from. Its type is read from them: {@link VariantsFn}. */
|
|
193
192
|
declare const CARD_VARIANT_MAP: {
|
|
194
193
|
variant: {
|
|
@@ -342,11 +341,12 @@ declare const ALERT_VARIANT_MAP: {
|
|
|
342
341
|
* - Padding: 16px (p-4)
|
|
343
342
|
* - Border radius: `rounded-md`, one step tighter than Card's `rounded-lg`
|
|
344
343
|
* for inline/flow content vs. larger container components
|
|
345
|
-
* - Border: 1px
|
|
344
|
+
* - Border: 1px; the card border for info and success, the status border for
|
|
345
|
+
* warning and destructive
|
|
346
346
|
* - Shadow: sm (subtle elevation)
|
|
347
347
|
* - Font: 14px (text-sm)
|
|
348
348
|
* - Layout: Flex with gap-3 for icon/content spacing
|
|
349
|
-
* - Colors:
|
|
349
|
+
* - Colors: the page's foreground text; the icon in the status's text colour
|
|
350
350
|
*
|
|
351
351
|
* Variants (4 total):
|
|
352
352
|
* - info (default): Blue - informational messages, neutral announcements
|
|
@@ -524,7 +524,14 @@ declare function Separator({ className, orientation, decorative, ...props }: Rea
|
|
|
524
524
|
*/
|
|
525
525
|
declare const Skeleton: React$1.ForwardRefExoticComponent<React$1.PropsWithoutRef<SkeletonProps> & React$1.RefAttributes<HTMLDivElement>>;
|
|
526
526
|
/** @experimental */
|
|
527
|
-
type SkeletonProps = React$1.ComponentProps<"div"
|
|
527
|
+
type SkeletonProps = React$1.ComponentProps<"div"> & {
|
|
528
|
+
/**
|
|
529
|
+
* Draw a still outline: no pulse, on the `secondary` surface. For a page's
|
|
530
|
+
* outline shown while its data is on its way, where motion would read as
|
|
531
|
+
* the page itself moving.
|
|
532
|
+
*/
|
|
533
|
+
still?: boolean;
|
|
534
|
+
};
|
|
528
535
|
/** The arms `progressVariants` is built from. Its type is read from them: {@link VariantsFn}. */
|
|
529
536
|
declare const PROGRESS_VARIANT_MAP: {
|
|
530
537
|
variant: {
|
|
@@ -568,7 +575,7 @@ type ProgressProps = {
|
|
|
568
575
|
* Visual variant for different states
|
|
569
576
|
*
|
|
570
577
|
* - `default`: Primary blue (bg-primary-500)
|
|
571
|
-
* - `success`: Green (bg-success-
|
|
578
|
+
* - `success`: Green (bg-success-solid)
|
|
572
579
|
* - `error`: Red (bg-destructive)
|
|
573
580
|
*
|
|
574
581
|
* @default "default"
|
|
@@ -1855,7 +1862,17 @@ declare const SHEET_VARIANT_MAP: {
|
|
|
1855
1862
|
*/
|
|
1856
1863
|
declare const sheetVariants: VariantsFn<typeof SHEET_VARIANT_MAP>;
|
|
1857
1864
|
/** @public */
|
|
1858
|
-
interface SheetContentProps extends React$1.ComponentPropsWithoutRef<typeof DialogPrimitive.Content>, VariantProps<typeof sheetVariants> {
|
|
1865
|
+
interface SheetContentProps extends React$1.ComponentPropsWithoutRef<typeof DialogPrimitive.Content>, VariantProps<typeof sheetVariants> {
|
|
1866
|
+
/**
|
|
1867
|
+
* For a bottom sheet: a grab strip at its top that drags the sheet down
|
|
1868
|
+
* and closes it past a quarter of its height or on a quick flick. Escape
|
|
1869
|
+
* and the sheet's own close control still close it, so the strip is a
|
|
1870
|
+
* pointer affordance only and is hidden from assistive technology.
|
|
1871
|
+
*/
|
|
1872
|
+
dragHandle?: boolean;
|
|
1873
|
+
}
|
|
1874
|
+
/** Whether a drag released at `distance` after `elapsed` ms closes the sheet. */
|
|
1875
|
+
declare function dragCloses(distance: number, elapsed: number, height: number): boolean;
|
|
1859
1876
|
/**
|
|
1860
1877
|
* SheetContent
|
|
1861
1878
|
*
|
|
@@ -3426,6 +3443,14 @@ interface PageShellProps extends HTMLAttributes<HTMLDivElement> {
|
|
|
3426
3443
|
* full-width page is still inset from the panel's edge.
|
|
3427
3444
|
*/
|
|
3428
3445
|
width?: "form" | "wide" | "full";
|
|
3446
|
+
/**
|
|
3447
|
+
* Where a bounded column sits on a wide screen. `start` (the default) keeps
|
|
3448
|
+
* it under the page's left edge, where the header, the panel and every list
|
|
3449
|
+
* begin, so moving between a list and its form shifts nothing sideways.
|
|
3450
|
+
* `center` balances it between equal gutters. A `full` column fills the row
|
|
3451
|
+
* either way.
|
|
3452
|
+
*/
|
|
3453
|
+
align?: "start" | "center";
|
|
3429
3454
|
}
|
|
3430
3455
|
/**
|
|
3431
3456
|
* What each named width resolves to, owned here because this is what applies it.
|
|
@@ -3510,6 +3535,21 @@ interface PageHeaderProps extends Omit<HTMLAttributes<HTMLElement>, "title"> {
|
|
|
3510
3535
|
breadcrumbs?: ReactNode;
|
|
3511
3536
|
/** Page-level actions, trailing the title on one line where there is room. */
|
|
3512
3537
|
actions?: ReactNode;
|
|
3538
|
+
/**
|
|
3539
|
+
* A row of tabs under the title, for a page whose sections each have their
|
|
3540
|
+
* own address (`PageTabs` with a `PageTab` per section). Rendered across the
|
|
3541
|
+
* header's full width, below the title and actions.
|
|
3542
|
+
*/
|
|
3543
|
+
tabs?: ReactNode;
|
|
3544
|
+
/**
|
|
3545
|
+
* The `id` of the title's `h1`, for a region that names itself by the page's
|
|
3546
|
+
* title (`aria-labelledby` on the page's form).
|
|
3547
|
+
*/
|
|
3548
|
+
titleId?: string;
|
|
3549
|
+
/** A leading visual, such as a plugin's icon tile, before the title. */
|
|
3550
|
+
media?: ReactNode;
|
|
3551
|
+
/** Small chips beside the title: a version, a status, a category. */
|
|
3552
|
+
meta?: ReactNode;
|
|
3513
3553
|
}
|
|
3514
3554
|
/**
|
|
3515
3555
|
* A page's own identity — its trail, its name, its one-line summary and its
|
|
@@ -3536,5 +3576,99 @@ interface PageHeaderProps extends Omit<HTMLAttributes<HTMLElement>, "title"> {
|
|
|
3536
3576
|
* @experimental
|
|
3537
3577
|
*/
|
|
3538
3578
|
export declare const PageHeader: ForwardRefExoticComponent<PropsWithoutRef<PageHeaderProps> & RefAttributes<HTMLElement>>;
|
|
3539
|
-
|
|
3579
|
+
/** @experimental */
|
|
3580
|
+
interface PageTabsProps extends HTMLAttributes<HTMLElement> {
|
|
3581
|
+
/** What the sections are, for assistive technology (`"Form sections"`). */
|
|
3582
|
+
label: string;
|
|
3583
|
+
}
|
|
3584
|
+
/**
|
|
3585
|
+
* The tab row of a page whose sections each have their own address. A labelled
|
|
3586
|
+
* `nav` of links rather than an ARIA tablist: every tab changes the URL, and a
|
|
3587
|
+
* link inside `role="tab"` breaks the tabs pattern's keyboard and announcement
|
|
3588
|
+
* contract. The current section is marked with `aria-current="page"` by
|
|
3589
|
+
* `PageTab`.
|
|
3590
|
+
* @experimental
|
|
3591
|
+
*/
|
|
3592
|
+
export declare const PageTabs: ForwardRefExoticComponent<PropsWithoutRef<PageTabsProps> & RefAttributes<HTMLElement>>;
|
|
3593
|
+
/**
|
|
3594
|
+
* The anchor attributes a tab passes through. `aria-current` is not among
|
|
3595
|
+
* them: it is derived from `current`, so the tab is announced as current
|
|
3596
|
+
* exactly when it is drawn as current.
|
|
3597
|
+
*/
|
|
3598
|
+
type PageTabAnchorProps = Omit<AnchorHTMLAttributes<HTMLAnchorElement>, "aria-current" | "href">;
|
|
3599
|
+
/**
|
|
3600
|
+
* A tab changes the address, so it always has a destination: its own `href`,
|
|
3601
|
+
* or, with `asChild`, the router link it wraps.
|
|
3602
|
+
* @experimental
|
|
3603
|
+
*/
|
|
3604
|
+
type PageTabProps = PageTabAnchorProps & {
|
|
3605
|
+
/** Whether this tab is the section being shown. */
|
|
3606
|
+
current?: boolean;
|
|
3607
|
+
} & ({
|
|
3608
|
+
/** Where the tab leads. */
|
|
3609
|
+
href: string;
|
|
3610
|
+
asChild?: false;
|
|
3611
|
+
} | {
|
|
3612
|
+
/**
|
|
3613
|
+
* Render the caller's own link element (a router link) in place of
|
|
3614
|
+
* an `<a>`; that element carries the destination. The tab keeps its
|
|
3615
|
+
* look and its `aria-current`.
|
|
3616
|
+
*/
|
|
3617
|
+
asChild: true;
|
|
3618
|
+
href?: undefined;
|
|
3619
|
+
});
|
|
3620
|
+
/**
|
|
3621
|
+
* One section of a `PageTabs` row: a link, underlined when current.
|
|
3622
|
+
* @experimental
|
|
3623
|
+
*/
|
|
3624
|
+
export declare const PageTab: ForwardRefExoticComponent<PropsWithoutRef<PageTabProps> & RefAttributes<HTMLAnchorElement>>;
|
|
3625
|
+
/**
|
|
3626
|
+
* The four kinds of page the admin draws, each with one width.
|
|
3627
|
+
*
|
|
3628
|
+
* - `list`: full width within the gutter (entries, users, keys, webhooks),
|
|
3629
|
+
* drawn as a padded block rather than a grid, so a page that hands its own
|
|
3630
|
+
* height down through `height: 100%` (a split pane, a media grid) keeps it.
|
|
3631
|
+
* - `form`: a 56rem column under the page's left edge (settings, create and
|
|
3632
|
+
* edit pages).
|
|
3633
|
+
* - `editor`: full width with no gutter and no padding: the editor draws its
|
|
3634
|
+
* own field column (inset by the gutter, and measured) and a side panel that
|
|
3635
|
+
* meets the window's edge.
|
|
3636
|
+
* - `workspace`: no gutter and no padding, for a page that lays out its own
|
|
3637
|
+
* surface (the dashboard, a builder canvas).
|
|
3638
|
+
* @experimental
|
|
3639
|
+
*/
|
|
3640
|
+
type PageType = "list" | "form" | "editor" | "workspace";
|
|
3641
|
+
/** @experimental */
|
|
3642
|
+
interface PageFrameListenerProps {
|
|
3643
|
+
/**
|
|
3644
|
+
* Called with the type of the outermost `PageFrame` drawn inside, as it
|
|
3645
|
+
* mounts or changes, and with `null` once none is left.
|
|
3646
|
+
*/
|
|
3647
|
+
onFrame: (type: PageType | null) => void;
|
|
3648
|
+
children?: ReactNode;
|
|
3649
|
+
}
|
|
3650
|
+
/**
|
|
3651
|
+
* Hears whether the content inside it draws a `PageFrame`, for a host that
|
|
3652
|
+
* gives unframed content a frame of its own and must not frame content twice.
|
|
3653
|
+
* Read from the frames themselves rather than from what the content is called,
|
|
3654
|
+
* so a page that draws a frame through any component is heard the same way.
|
|
3655
|
+
*
|
|
3656
|
+
* The frame claims in a layout effect, so a host that changes its own markup
|
|
3657
|
+
* in answer does so before the first paint.
|
|
3658
|
+
* @experimental
|
|
3659
|
+
*/
|
|
3660
|
+
export declare function PageFrameListener({ onFrame, children }: PageFrameListenerProps): JSX.Element;
|
|
3661
|
+
/** @experimental */
|
|
3662
|
+
interface PageFrameProps extends HTMLAttributes<HTMLDivElement> {
|
|
3663
|
+
/** Which kind of page this is; it decides the width. */
|
|
3664
|
+
type: PageType;
|
|
3665
|
+
}
|
|
3666
|
+
/**
|
|
3667
|
+
* A page's frame: the width and gutter its type gives it. A page says what it
|
|
3668
|
+
* is, and the frame decides how wide that is, so two pages of one type can
|
|
3669
|
+
* never drift apart.
|
|
3670
|
+
* @experimental
|
|
3671
|
+
*/
|
|
3672
|
+
export declare const PageFrame: ForwardRefExoticComponent<PropsWithoutRef<PageFrameProps> & RefAttributes<HTMLDivElement>>;
|
|
3673
|
+
export { Accordion, AccordionContent, type AccordionContentProps, AccordionItem, type AccordionItemProps, type AccordionProps, AccordionTrigger, type AccordionTriggerProps, type ActionCallbacks, type ActiveShortcut, Alert, AlertDescription, type AlertDescriptionProps, AlertDialog, AlertDialogAction, type AlertDialogActionProps, AlertDialogCancel, type AlertDialogCancelProps, AlertDialogContent, type AlertDialogContentProps, AlertDialogDescription, type AlertDialogDescriptionProps, AlertDialogFooter, type AlertDialogFooterProps, AlertDialogHeader, type AlertDialogHeaderProps, AlertDialogOverlay, type AlertDialogOverlayProps, AlertDialogPortal, AlertDialogTitle, type AlertDialogTitleProps, AlertDialogTrigger, type AlertProps, AlertTitle, type AlertTitleProps, Avatar, AvatarFallback, type AvatarFallbackProps, AvatarImage, type AvatarImageProps, type AvatarProps, Badge, type BadgeProps, type BleedProps, Button, type ButtonProps, Card, CardAction, type CardActionProps, CardContent, type CardContentProps, CardDescription, type CardDescriptionProps, CardFooter, type CardFooterProps, CardHeader, type CardHeaderProps, type CardProps, CardTitle, type CardTitleProps, Checkbox, Collapsible, CollapsibleContent, CollapsibleTrigger, type ColorPickerProps, type ColorSwatch, Command, CommandDialog, type CommandDialogProps, CommandEmpty, type CommandEmptyProps, CommandGroup, type CommandGroupProps, CommandInput, type CommandInputProps, CommandItem, type CommandItemProps, CommandList, type CommandListProps, type CommandProps, CommandSeparator, type CommandSeparatorProps, CommandShortcut, type CommandShortcutProps, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, type DataFetcher, Dialog, DialogClose, DialogContent, type DialogContentProps, DialogDescription, type DialogDescriptionProps, DialogFooter, type DialogFooterProps, DialogHeader, type DialogHeaderProps, DialogOverlay, type DialogOverlayProps, DialogPortal, DialogTitle, type DialogTitleProps, DialogTrigger, DropdownMenu, DropdownMenuCheckboxItem, type DropdownMenuCheckboxItemProps, DropdownMenuContent, type DropdownMenuContentProps, DropdownMenuGroup, DropdownMenuItem, type DropdownMenuItemProps, DropdownMenuLabel, type DropdownMenuLabelProps, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, type DropdownMenuRadioItemProps, DropdownMenuSeparator, type DropdownMenuSeparatorProps, DropdownMenuShortcut, type DropdownMenuShortcutProps, DropdownMenuSub, DropdownMenuSubContent, type DropdownMenuSubContentProps, DropdownMenuSubTrigger, type DropdownMenuSubTriggerProps, DropdownMenuTrigger, type FieldShellProps, type FieldShellRenderProps, type FieldWidth, type FilterInfo, type FormActionsProps, type FormLabelWithTooltipProps, type FormSectionProps, type GridProps, type IconFieldProps, type IconGlyphProps, type IconPickerProps, type IconSource, type IconSourceIcon, Input, type InputProps, type KeyChord, type KeySequence, Label, type ListResponse, type ModifierState, type PageFrameListenerProps, type PageFrameProps, type PageHeaderProps, type PageShellProps, type PageTabProps, type PageTabsProps, type PageType, type PaginationConfig, type PaginationMeta, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, PortalProvider, Progress, type ProgressProps, RadioGroup, RadioGroupItem, ResizableHandle, ResizablePanel, ResizablePanelGroup, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, type SelectTriggerProps, SelectValue, Separator, Sheet, SheetClose, type SheetCloseProps, SheetContent, type SheetContentProps, type SheetContentRef, SheetDescription, type SheetDescriptionProps, type SheetDescriptionRef, SheetFooter, type SheetFooterProps, SheetHeader, type SheetHeaderProps, SheetOverlay, type SheetOverlayProps, type SheetOverlayRef, SheetPortal, type SheetProps, SheetTitle, type SheetTitleProps, type SheetTitleRef, SheetTrigger, type SheetTriggerProps, type ShortcutBinding, type ShortcutLayerOptions, type ShortcutManager, type ShortcutManagerOptions, type ShortcutProviderProps, type ShortcutRegistration, Skeleton, type SkeletonProps, Slider, type SliderProps, type SliderThumbProps, type SortInfo, Spinner, type SpinnerProps, type StackProps, type StatProps, Switch, Table, TableBody, TableCaption, TableCell, type TableEmptyProps, type TableErrorProps, TableFooter, TableHead, TableHeader, type TableParams, TableRow, type TableSearchProps, type TableSkeletonProps, Tabs, TabsContent, type TabsContentProps, TabsList, type TabsListProps, type TabsProps, TabsTrigger, type TabsTriggerProps, Textarea, type ToasterProps, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, type TreeNode, TreeView, type TreeViewProps, type UseShortcutsOptions, alertVariants, badgeVariants, buttonVariants, cardVariants, dialogContentVariants, inputVariants, selectTriggerVariants, sheetVariants, spinnerVariants, toast, usePortalContainer };
|
|
3540
3674
|
//# sourceMappingURL=index.d.ts.map
|