@uselets/ui 0.2.0 → 0.3.0
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/README.md +16 -2
- package/dist/components/alert.js +1 -1
- package/dist/components/alert.js.map +1 -1
- package/dist/components/avatar.d.ts +4 -4
- package/dist/components/avatar.js +1 -1
- package/dist/components/avatar.js.map +1 -1
- package/dist/components/button.d.ts +5 -2
- package/dist/components/button.js +1 -1
- package/dist/components/button.js.map +1 -1
- package/dist/components/card.js +1 -1
- package/dist/components/card.js.map +1 -1
- package/dist/components/checkbox.d.ts +20 -0
- package/dist/components/checkbox.js +2 -0
- package/dist/components/checkbox.js.map +1 -0
- package/dist/components/dialog.d.ts +17 -9
- package/dist/components/dialog.js +1 -1
- package/dist/components/dialog.js.map +1 -1
- package/dist/components/drawer.js +1 -1
- package/dist/components/drawer.js.map +1 -1
- package/dist/components/dropdown-menu.d.ts +35 -40
- package/dist/components/dropdown-menu.js +1 -1
- package/dist/components/dropdown-menu.js.map +1 -1
- package/dist/components/field.js +1 -1
- package/dist/components/field.js.map +1 -1
- package/dist/components/input-otp.js +1 -1
- package/dist/components/input-otp.js.map +1 -1
- package/dist/components/input.js +1 -1
- package/dist/components/input.js.map +1 -1
- package/dist/components/kbd.d.ts +6 -3
- package/dist/components/kbd.js.map +1 -1
- package/dist/components/label.d.ts +2 -1
- package/dist/components/label.js +1 -1
- package/dist/components/label.js.map +1 -1
- package/dist/components/native-select.js +1 -1
- package/dist/components/native-select.js.map +1 -1
- package/dist/components/popover.d.ts +43 -0
- package/dist/components/popover.js +2 -0
- package/dist/components/popover.js.map +1 -0
- package/dist/components/select.d.ts +15 -17
- package/dist/components/select.js +1 -1
- package/dist/components/select.js.map +1 -1
- package/dist/components/separator.d.ts +4 -2
- package/dist/components/separator.js +1 -1
- package/dist/components/separator.js.map +1 -1
- package/dist/components/sonner.js.map +1 -1
- package/dist/components/spinner.d.ts +10 -2
- package/dist/components/spinner.js +1 -1
- package/dist/components/spinner.js.map +1 -1
- package/dist/components/theme.d.ts +5 -2
- package/dist/components/theme.js +1 -1
- package/dist/components/theme.js.map +1 -1
- package/dist/components/tooltip.d.ts +29 -0
- package/dist/components/tooltip.js +2 -0
- package/dist/components/tooltip.js.map +1 -0
- package/dist/index.d.ts +6 -3
- package/dist/index.js +1 -1
- package/dist/styles.css +1 -1
- package/dist/styles.css.map +1 -1
- package/package.json +8 -7
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @uselets/ui
|
|
2
2
|
|
|
3
|
-
React component library for the
|
|
3
|
+
React component library for the LET'S design system.
|
|
4
4
|
|
|
5
5
|
## Requirements
|
|
6
6
|
|
|
@@ -99,10 +99,12 @@ You can import from the package root (`@uselets/ui`) or by subpath (`@uselets/ui
|
|
|
99
99
|
| `kbd` | `Kbd`, `KbdGroup` | Keyboard shortcut presentation primitives. |
|
|
100
100
|
| `label` | `Label` | Styled `<label>` wrapper. |
|
|
101
101
|
| `native-select` | `NativeSelect`, `NativeSelectOption`, `NativeSelectOptGroup` | Native `<select>` API with `size: 'sm' \| 'default'` (default: `default`). |
|
|
102
|
+
| `popover` | `Popover`, `PopoverTrigger`, `PopoverContent`, `PopoverAnchor`, `PopoverHeader`, `PopoverTitle`, `PopoverDescription` | `PopoverContent` supports positioning props (`side`, `sideOffset`, `align`, `alignOffset`) and can be used in controlled mode via root props (`open`, `onOpenChange`). |
|
|
102
103
|
| `select` | `Select`, `SelectTrigger`, `SelectValue`, `SelectContent`, `SelectGroup`, `SelectItem`, `SelectLabel`, `SelectSeparator`, `SelectScrollUpButton`, `SelectScrollDownButton` | `SelectTrigger.size: 'sm' \| 'default'`; `SelectContent` supports positioning props (`side`, `sideOffset`, `align`, `alignOffset`, `alignItemWithTrigger`). |
|
|
103
104
|
| `separator` | `Separator` | `orientation: 'horizontal' \| 'vertical'` (default: `horizontal`). |
|
|
104
105
|
| `skeleton` | `Skeleton` | Generic loading placeholder block. |
|
|
105
|
-
| `spinner` | `Spinner` | Loader icon (`role="status"`), accepts SVG props (`
|
|
106
|
+
| `spinner` | `Spinner` | Loader icon (`role="status"`), accepts SVG props and supports `size: 'sm' \| 'default' \| 'lg'` (default: `default`). |
|
|
107
|
+
| `tooltip` | `TooltipProvider`, `Tooltip`, `TooltipTrigger`, `TooltipContent` | `TooltipProvider.delayDuration` controls global hover delay; `Tooltip` supports controlled mode (`open`, `onOpenChange`); `TooltipContent` supports positioning props like `side`, `align`, and `sideOffset`. |
|
|
106
108
|
| `sonner` | `Toaster`, `toast` | Toaster wrapper around Sonner with theme integration from `next-themes` and custom icons. |
|
|
107
109
|
|
|
108
110
|
### Sonner example
|
|
@@ -120,3 +122,15 @@ export function App() {
|
|
|
120
122
|
)
|
|
121
123
|
}
|
|
122
124
|
```
|
|
125
|
+
|
|
126
|
+
## Tooltip setup
|
|
127
|
+
|
|
128
|
+
For consistent tooltip behavior across the app, wrap your application root with `TooltipProvider`.
|
|
129
|
+
|
|
130
|
+
```tsx
|
|
131
|
+
import { TooltipProvider } from '@uselets/ui/tooltip'
|
|
132
|
+
|
|
133
|
+
export function AppRoot() {
|
|
134
|
+
return <TooltipProvider delayDuration={200}>{/* app */}</TooltipProvider>
|
|
135
|
+
}
|
|
136
|
+
```
|
package/dist/components/alert.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{t as e}from"../chunk-IpJEthwI.js";import{cn as t}from"../lib/utils.js";import{cva as n}from"class-variance-authority";import{jsx as r}from"react/jsx-runtime";const i=n(`grid gap-0.5 rounded-lg border px-2.5 py-2 text-left text-sm has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4 w-full relative group/alert`,{variants:{variant:{default:`bg-card text-card-foreground`,destructive:`text-destructive bg-card *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current`}},defaultVariants:{variant:`default`}});function Alert({className:e,variant:n,...a}){return r(`div`,{"data-slot":`alert`,role:`alert`,className:t(i({variant:n}),e),...a})}function AlertTitle({className:e,...n}){return r(`div`,{"data-slot":`alert-title`,className:t(`font-medium group-has-[>svg]/alert:col-start-2
|
|
1
|
+
import{t as e}from"../chunk-IpJEthwI.js";import{cn as t}from"../lib/utils.js";import{cva as n}from"class-variance-authority";import{jsx as r}from"react/jsx-runtime";const i=n(`grid gap-0.5 rounded-lg border px-2.5 py-2 text-left text-sm has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4 w-full relative group/alert`,{variants:{variant:{default:`bg-card text-card-foreground`,destructive:`text-destructive bg-card *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current`}},defaultVariants:{variant:`default`}});function Alert({className:e,variant:n,...a}){return r(`div`,{"data-slot":`alert`,role:`alert`,className:t(i({variant:n}),e),...a})}function AlertTitle({className:e,...n}){return r(`div`,{"data-slot":`alert-title`,className:t(`font-medium group-has-[>svg]/alert:col-start-2`,`[&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground`,e),...n})}function AlertDescription({className:e,...n}){return r(`div`,{"data-slot":`alert-description`,className:t(`text-muted-foreground text-sm text-balance md:text-pretty [&_p:not(:last-child)]:mb-4`,`[&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground`,e),...n})}function AlertAction({className:e,...n}){return r(`div`,{"data-slot":`alert-action`,className:t(`absolute top-2 right-2`,e),...n})}export{Alert,AlertAction,AlertDescription,AlertTitle};
|
|
2
2
|
//# sourceMappingURL=alert.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"alert.js","names":[],"sources":["../../src/components/alert.tsx"],"sourcesContent":["import type * as React from 'react'\n\nimport { cva, type VariantProps } from 'class-variance-authority'\n\nimport { cn } from '../lib/utils'\n\nconst alertVariants = cva(\n \"grid gap-0.5 rounded-lg border px-2.5 py-2 text-left text-sm has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4 w-full relative group/alert\",\n {\n variants: {\n variant: {\n default: 'bg-card text-card-foreground',\n destructive: 'text-destructive bg-card *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current'\n }\n },\n defaultVariants: {\n variant: 'default'\n }\n }\n)\n\nexport type AlertProps = React.ComponentProps<'div'> & VariantProps<typeof alertVariants>\n\nexport type AlertTitleProps = React.ComponentProps<'div'>\n\nexport type AlertDescriptionProps = React.ComponentProps<'div'>\n\nexport type AlertActionProps = React.ComponentProps<'div'>\n\nfunction Alert({ className, variant, ...props }: AlertProps) {\n return <div data-slot=\"alert\" role=\"alert\" className={cn(alertVariants({ variant }), className)} {...props} />\n}\n\nfunction AlertTitle({ className, ...props }: AlertTitleProps) {\n return (\n <div\n data-slot=\"alert-title\"\n className={cn(\n 'font-medium group-has-[>svg]/alert:col-start-2
|
|
1
|
+
{"version":3,"file":"alert.js","names":[],"sources":["../../src/components/alert.tsx"],"sourcesContent":["import type * as React from 'react'\n\nimport { cva, type VariantProps } from 'class-variance-authority'\n\nimport { cn } from '../lib/utils'\n\nconst alertVariants = cva(\n \"grid gap-0.5 rounded-lg border px-2.5 py-2 text-left text-sm has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4 w-full relative group/alert\",\n {\n variants: {\n variant: {\n default: 'bg-card text-card-foreground',\n destructive: 'text-destructive bg-card *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current'\n }\n },\n defaultVariants: {\n variant: 'default'\n }\n }\n)\n\nexport type AlertProps = React.ComponentProps<'div'> & VariantProps<typeof alertVariants>\n\nexport type AlertTitleProps = React.ComponentProps<'div'>\n\nexport type AlertDescriptionProps = React.ComponentProps<'div'>\n\nexport type AlertActionProps = React.ComponentProps<'div'>\n\nfunction Alert({ className, variant, ...props }: AlertProps) {\n return <div data-slot=\"alert\" role=\"alert\" className={cn(alertVariants({ variant }), className)} {...props} />\n}\n\nfunction AlertTitle({ className, ...props }: AlertTitleProps) {\n return (\n <div\n data-slot=\"alert-title\"\n className={cn(\n 'font-medium group-has-[>svg]/alert:col-start-2',\n '[&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground',\n className\n )}\n {...props}\n />\n )\n}\n\nfunction AlertDescription({ className, ...props }: AlertDescriptionProps) {\n return (\n <div\n data-slot=\"alert-description\"\n className={cn(\n 'text-muted-foreground text-sm text-balance md:text-pretty [&_p:not(:last-child)]:mb-4',\n '[&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground',\n className\n )}\n {...props}\n />\n )\n}\n\nfunction AlertAction({ className, ...props }: AlertActionProps) {\n return <div data-slot=\"alert-action\" className={cn('absolute top-2 right-2', className)} {...props} />\n}\n\nexport { Alert, AlertAction, AlertDescription, AlertTitle }\n"],"mappings":"qKAMA,MAAM,EAAgB,EACpB,4TACA,CACE,SAAU,CACR,QAAS,CACP,QAAS,+BACT,YAAa,oGACd,CACF,CACD,gBAAiB,CACf,QAAS,UACV,CACF,CACF,CAUD,SAAS,MAAM,CAAE,YAAW,UAAS,GAAG,GAAqB,CAC3D,OAAO,EAAC,MAAA,CAAI,YAAU,QAAQ,KAAK,QAAQ,UAAW,EAAG,EAAc,CAAE,UAAS,CAAC,CAAE,EAAU,CAAE,GAAI,GAAS,CAGhH,SAAS,WAAW,CAAE,YAAW,GAAG,GAA0B,CAC5D,OACE,EAAC,MAAA,CACC,YAAU,cACV,UAAW,EACT,iDACA,uEACA,EACD,CACD,GAAI,GACJ,CAIN,SAAS,iBAAiB,CAAE,YAAW,GAAG,GAAgC,CACxE,OACE,EAAC,MAAA,CACC,YAAU,oBACV,UAAW,EACT,wFACA,uEACA,EACD,CACD,GAAI,GACJ,CAIN,SAAS,YAAY,CAAE,YAAW,GAAG,GAA2B,CAC9D,OAAO,EAAC,MAAA,CAAI,YAAU,eAAe,UAAW,EAAG,yBAA0B,EAAU,CAAE,GAAI,GAAS"}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { t as __name } from "../chunk-IpJEthwI.js";
|
|
2
2
|
import * as react_jsx_runtime0 from "react/jsx-runtime";
|
|
3
|
-
import { Avatar as Avatar$1 } from "
|
|
3
|
+
import { Avatar as Avatar$1 } from "radix-ui";
|
|
4
4
|
import * as React from "react";
|
|
5
5
|
|
|
6
6
|
//#region src/components/avatar.d.ts
|
|
7
|
-
type AvatarProps = Avatar$1.Root
|
|
7
|
+
type AvatarProps = React.ComponentProps<typeof Avatar$1.Root> & {
|
|
8
8
|
size?: 'default' | 'sm' | 'lg';
|
|
9
9
|
};
|
|
10
|
-
type AvatarImageProps = Avatar$1.Image
|
|
11
|
-
type AvatarFallbackProps = Avatar$1.Fallback
|
|
10
|
+
type AvatarImageProps = React.ComponentProps<typeof Avatar$1.Image>;
|
|
11
|
+
type AvatarFallbackProps = React.ComponentProps<typeof Avatar$1.Fallback>;
|
|
12
12
|
type AvatarBadgeProps = React.ComponentProps<'span'>;
|
|
13
13
|
type AvatarGroupProps = React.ComponentProps<'div'>;
|
|
14
14
|
type AvatarGroupCountProps = React.ComponentProps<'div'>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{t as e}from"../chunk-IpJEthwI.js";import{cn as t}from"../lib/utils.js";import{jsx as n}from"react/jsx-runtime";import{Avatar as r}from"
|
|
1
|
+
import{t as e}from"../chunk-IpJEthwI.js";import{cn as t}from"../lib/utils.js";import{jsx as n}from"react/jsx-runtime";import{Avatar as r}from"radix-ui";function Avatar({className:e,size:i=`default`,...a}){return n(r.Root,{"data-slot":`avatar`,"data-size":i,className:t(`group/avatar relative flex shrink-0 size-8 rounded-full select-none`,`data-[size=lg]:size-10 data-[size=sm]:size-6`,`after:absolute after:inset-0 after:rounded-full after:border after:border-border after:mix-blend-darken dark:after:mix-blend-lighten`,e),...a})}function AvatarImage({className:e,...i}){return n(r.Image,{"data-slot":`avatar-image`,className:t(`rounded-full aspect-square size-full object-cover`,e),...i})}function AvatarFallback({className:e,...i}){return n(r.Fallback,{"data-slot":`avatar-fallback`,className:t(`bg-muted text-muted-foreground rounded-full flex size-full items-center justify-center text-sm group-data-[size=sm]/avatar:text-xs`,e),...i})}function AvatarBadge({className:e,...r}){return n(`span`,{"data-slot":`avatar-badge`,className:t(`bg-primary text-primary-foreground ring-background absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full bg-blend-color ring-2 select-none`,`group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden`,`group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2`,`group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2`,e),...r})}function AvatarGroup({className:e,...r}){return n(`div`,{"data-slot":`avatar-group`,className:t(`*:data-[slot=avatar]:ring-background group/avatar-group flex -space-x-2 *:data-[slot=avatar]:ring-2`,e),...r})}function AvatarGroupCount({className:e,...r}){return n(`div`,{"data-slot":`avatar-group-count`,className:t(`bg-muted text-muted-foreground ring-background relative flex shrink-0 items-center justify-center size-8 rounded-full text-sm ring-2`,`group-has-data-[size=lg]/avatar-group:size-10 group-has-data-[size=sm]/avatar-group:size-6`,`[&>svg]:size-4 group-has-data-[size=lg]/avatar-group:[&>svg]:size-5 group-has-data-[size=sm]/avatar-group:[&>svg]:size-3`,e),...r})}export{Avatar,AvatarBadge,AvatarFallback,AvatarGroup,AvatarGroupCount,AvatarImage};
|
|
2
2
|
//# sourceMappingURL=avatar.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"avatar.js","names":["AvatarPrimitive"],"sources":["../../src/components/avatar.tsx"],"sourcesContent":["import type * as React from 'react'\n\nimport { Avatar as AvatarPrimitive } from '
|
|
1
|
+
{"version":3,"file":"avatar.js","names":["AvatarPrimitive"],"sources":["../../src/components/avatar.tsx"],"sourcesContent":["import type * as React from 'react'\n\nimport { Avatar as AvatarPrimitive } from 'radix-ui'\n\nimport { cn } from '../lib/utils'\n\nexport type AvatarProps = React.ComponentProps<typeof AvatarPrimitive.Root> & {\n size?: 'default' | 'sm' | 'lg'\n}\n\nexport type AvatarImageProps = React.ComponentProps<typeof AvatarPrimitive.Image>\n\nexport type AvatarFallbackProps = React.ComponentProps<typeof AvatarPrimitive.Fallback>\n\nexport type AvatarBadgeProps = React.ComponentProps<'span'>\n\nexport type AvatarGroupProps = React.ComponentProps<'div'>\n\nexport type AvatarGroupCountProps = React.ComponentProps<'div'>\n\nfunction Avatar({ className, size = 'default', ...props }: AvatarProps) {\n return (\n <AvatarPrimitive.Root\n data-slot=\"avatar\"\n data-size={size}\n className={cn(\n 'group/avatar relative flex shrink-0 size-8 rounded-full select-none',\n 'data-[size=lg]:size-10 data-[size=sm]:size-6',\n 'after:absolute after:inset-0 after:rounded-full after:border after:border-border after:mix-blend-darken dark:after:mix-blend-lighten',\n className\n )}\n {...props}\n />\n )\n}\n\nfunction AvatarImage({ className, ...props }: AvatarImageProps) {\n return (\n <AvatarPrimitive.Image\n data-slot=\"avatar-image\"\n className={cn('rounded-full aspect-square size-full object-cover', className)}\n {...props}\n />\n )\n}\n\nfunction AvatarFallback({ className, ...props }: AvatarFallbackProps) {\n return (\n <AvatarPrimitive.Fallback\n data-slot=\"avatar-fallback\"\n className={cn(\n 'bg-muted text-muted-foreground rounded-full flex size-full items-center justify-center text-sm group-data-[size=sm]/avatar:text-xs',\n className\n )}\n {...props}\n />\n )\n}\n\nfunction AvatarBadge({ className, ...props }: AvatarBadgeProps) {\n return (\n <span\n data-slot=\"avatar-badge\"\n className={cn(\n 'bg-primary text-primary-foreground ring-background absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full bg-blend-color ring-2 select-none',\n 'group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden',\n 'group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2',\n 'group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2',\n className\n )}\n {...props}\n />\n )\n}\n\nfunction AvatarGroup({ className, ...props }: AvatarGroupProps) {\n return (\n <div\n data-slot=\"avatar-group\"\n className={cn(\n '*:data-[slot=avatar]:ring-background group/avatar-group flex -space-x-2 *:data-[slot=avatar]:ring-2',\n className\n )}\n {...props}\n />\n )\n}\n\nfunction AvatarGroupCount({ className, ...props }: AvatarGroupCountProps) {\n return (\n <div\n data-slot=\"avatar-group-count\"\n className={cn(\n 'bg-muted text-muted-foreground ring-background relative flex shrink-0 items-center justify-center size-8 rounded-full text-sm ring-2',\n 'group-has-data-[size=lg]/avatar-group:size-10 group-has-data-[size=sm]/avatar-group:size-6',\n '[&>svg]:size-4 group-has-data-[size=lg]/avatar-group:[&>svg]:size-5 group-has-data-[size=sm]/avatar-group:[&>svg]:size-3',\n className\n )}\n {...props}\n />\n )\n}\n\nexport { Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage }\n"],"mappings":"wJAoBA,SAAS,OAAO,CAAE,YAAW,OAAO,UAAW,GAAG,GAAsB,CACtE,OACE,EAACA,EAAgB,KAAA,CACf,YAAU,SACV,YAAW,EACX,UAAW,EACT,sEACA,+CACA,uIACA,EACD,CACD,GAAI,GACJ,CAIN,SAAS,YAAY,CAAE,YAAW,GAAG,GAA2B,CAC9D,OACE,EAACA,EAAgB,MAAA,CACf,YAAU,eACV,UAAW,EAAG,oDAAqD,EAAU,CAC7E,GAAI,GACJ,CAIN,SAAS,eAAe,CAAE,YAAW,GAAG,GAA8B,CACpE,OACE,EAACA,EAAgB,SAAA,CACf,YAAU,kBACV,UAAW,EACT,qIACA,EACD,CACD,GAAI,GACJ,CAIN,SAAS,YAAY,CAAE,YAAW,GAAG,GAA2B,CAC9D,OACE,EAAC,OAAA,CACC,YAAU,eACV,UAAW,EACT,2KACA,gFACA,4FACA,gFACA,EACD,CACD,GAAI,GACJ,CAIN,SAAS,YAAY,CAAE,YAAW,GAAG,GAA2B,CAC9D,OACE,EAAC,MAAA,CACC,YAAU,eACV,UAAW,EACT,sGACA,EACD,CACD,GAAI,GACJ,CAIN,SAAS,iBAAiB,CAAE,YAAW,GAAG,GAAgC,CACxE,OACE,EAAC,MAAA,CACC,YAAU,qBACV,UAAW,EACT,uIACA,6FACA,2HACA,EACD,CACD,GAAI,GACJ"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as __name } from "../chunk-IpJEthwI.js";
|
|
2
2
|
import { VariantProps } from "class-variance-authority";
|
|
3
3
|
import * as react_jsx_runtime0 from "react/jsx-runtime";
|
|
4
|
-
import
|
|
4
|
+
import * as React from "react";
|
|
5
5
|
import * as class_variance_authority_types0 from "class-variance-authority/types";
|
|
6
6
|
|
|
7
7
|
//#region src/components/button.d.ts
|
|
@@ -9,11 +9,14 @@ declare const buttonVariants: (props?: ({
|
|
|
9
9
|
variant?: "default" | "destructive" | "outline" | "secondary" | "ghost" | "link" | null | undefined;
|
|
10
10
|
size?: "default" | "xs" | "sm" | "lg" | "icon" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
|
|
11
11
|
} & class_variance_authority_types0.ClassProp) | undefined) => string;
|
|
12
|
-
type ButtonProps =
|
|
12
|
+
type ButtonProps = React.ComponentProps<'button'> & VariantProps<typeof buttonVariants> & {
|
|
13
|
+
asChild?: boolean;
|
|
14
|
+
};
|
|
13
15
|
declare function Button({
|
|
14
16
|
className,
|
|
15
17
|
variant,
|
|
16
18
|
size,
|
|
19
|
+
asChild,
|
|
17
20
|
...props
|
|
18
21
|
}: ButtonProps): react_jsx_runtime0.JSX.Element;
|
|
19
22
|
//#endregion
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{t as e}from"../chunk-IpJEthwI.js";import{cn as t}from"../lib/utils.js";import{cva as n}from"class-variance-authority";import{jsx as r}from"react/jsx-runtime";import{
|
|
1
|
+
import{t as e}from"../chunk-IpJEthwI.js";import{cn as t}from"../lib/utils.js";import{cva as n}from"class-variance-authority";import{jsx as r}from"react/jsx-runtime";import{Slot as i}from"radix-ui";const a=n(`focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:aria-invalid:border-destructive/50 rounded-lg border border-transparent bg-clip-padding text-sm font-medium focus-visible:ring-3 aria-invalid:ring-3 [&_svg:not([class*='size-'])]:size-4 inline-flex items-center justify-center whitespace-nowrap transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none shrink-0 [&_svg]:shrink-0 outline-none group/button select-none`,{variants:{variant:{default:`bg-primary text-primary-foreground hover:bg-primary/80`,outline:`border-border bg-background hover:bg-muted hover:text-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50 aria-expanded:bg-muted aria-expanded:text-foreground`,secondary:`bg-secondary text-secondary-foreground hover:bg-secondary/80 aria-expanded:bg-secondary aria-expanded:text-secondary-foreground`,ghost:`hover:bg-muted hover:text-foreground dark:hover:bg-muted/50 aria-expanded:bg-muted aria-expanded:text-foreground`,destructive:`bg-destructive/10 hover:bg-destructive/20 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/20 text-destructive focus-visible:border-destructive/40 dark:hover:bg-destructive/30`,link:`text-primary underline-offset-4 hover:underline`},size:{default:`h-8 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2`,xs:`h-6 gap-1 rounded-[min(var(--radius-md),10px)] px-2 text-xs in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3`,sm:`h-7 gap-1 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5`,lg:`h-9 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-3 has-data-[icon=inline-start]:pl-3`,icon:`size-8`,"icon-xs":`size-6 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-lg [&_svg:not([class*='size-'])]:size-3`,"icon-sm":`size-7 rounded-[min(var(--radius-md),12px)] in-data-[slot=button-group]:rounded-lg`,"icon-lg":`size-9`}},defaultVariants:{variant:`default`,size:`default`}});function Button({className:e,variant:n=`default`,size:o=`default`,asChild:s=!1,...c}){return r(s?i.Root:`button`,{"data-slot":`button`,"data-variant":n,"data-size":o,className:t(a({variant:n,size:o,className:e})),...c})}export{Button,a as buttonVariants};
|
|
2
2
|
//# sourceMappingURL=button.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"button.js","names":[
|
|
1
|
+
{"version":3,"file":"button.js","names":[],"sources":["../../src/components/button.tsx"],"sourcesContent":["import type * as React from 'react'\n\nimport { cva, type VariantProps } from 'class-variance-authority'\nimport { Slot } from 'radix-ui'\n\nimport { cn } from '../lib/utils'\n\nconst buttonVariants = cva(\n \"focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:aria-invalid:border-destructive/50 rounded-lg border border-transparent bg-clip-padding text-sm font-medium focus-visible:ring-3 aria-invalid:ring-3 [&_svg:not([class*='size-'])]:size-4 inline-flex items-center justify-center whitespace-nowrap transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none shrink-0 [&_svg]:shrink-0 outline-none group/button select-none\",\n {\n variants: {\n variant: {\n default: 'bg-primary text-primary-foreground hover:bg-primary/80',\n outline:\n 'border-border bg-background hover:bg-muted hover:text-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50 aria-expanded:bg-muted aria-expanded:text-foreground',\n secondary:\n 'bg-secondary text-secondary-foreground hover:bg-secondary/80 aria-expanded:bg-secondary aria-expanded:text-secondary-foreground',\n ghost:\n 'hover:bg-muted hover:text-foreground dark:hover:bg-muted/50 aria-expanded:bg-muted aria-expanded:text-foreground',\n destructive:\n 'bg-destructive/10 hover:bg-destructive/20 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/20 text-destructive focus-visible:border-destructive/40 dark:hover:bg-destructive/30',\n link: 'text-primary underline-offset-4 hover:underline'\n },\n size: {\n default: 'h-8 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2',\n xs: \"h-6 gap-1 rounded-[min(var(--radius-md),10px)] px-2 text-xs in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3\",\n sm: \"h-7 gap-1 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5\",\n lg: 'h-9 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-3 has-data-[icon=inline-start]:pl-3',\n icon: 'size-8',\n 'icon-xs':\n \"size-6 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-lg [&_svg:not([class*='size-'])]:size-3\",\n 'icon-sm': 'size-7 rounded-[min(var(--radius-md),12px)] in-data-[slot=button-group]:rounded-lg',\n 'icon-lg': 'size-9'\n }\n },\n defaultVariants: {\n variant: 'default',\n size: 'default'\n }\n }\n)\n\nexport type ButtonProps = React.ComponentProps<'button'> &\n VariantProps<typeof buttonVariants> & {\n asChild?: boolean\n }\n\nfunction Button({ className, variant = 'default', size = 'default', asChild = false, ...props }: ButtonProps) {\n const Comp = asChild ? Slot.Root : 'button'\n\n return (\n <Comp\n data-slot=\"button\"\n data-variant={variant}\n data-size={size}\n className={cn(buttonVariants({ variant, size, className }))}\n {...props}\n />\n )\n}\n\nexport { Button, buttonVariants }\n"],"mappings":"qMAOA,MAAM,EAAiB,EACrB,mjBACA,CACE,SAAU,CACR,QAAS,CACP,QAAS,yDACT,QACE,kLACF,UACE,kIACF,MACE,mHACF,YACE,8NACF,KAAM,kDACP,CACD,KAAM,CACJ,QAAS,uFACT,GAAI,gNACJ,GAAI,0NACJ,GAAI,uFACJ,KAAM,SACN,UACE,0HACF,UAAW,qFACX,UAAW,SACZ,CACF,CACD,gBAAiB,CACf,QAAS,UACT,KAAM,UACP,CACF,CACF,CAOD,SAAS,OAAO,CAAE,YAAW,UAAU,UAAW,OAAO,UAAW,UAAU,GAAO,GAAG,GAAsB,CAG5G,OACE,EAHW,EAAU,EAAK,KAAO,SAAA,CAI/B,YAAU,SACV,eAAc,EACd,YAAW,EACX,UAAW,EAAG,EAAe,CAAE,UAAS,OAAM,YAAW,CAAC,CAAC,CAC3D,GAAI,GACJ"}
|
package/dist/components/card.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{t as e}from"../chunk-IpJEthwI.js";import{cn as t}from"../lib/utils.js";import{jsx as n}from"react/jsx-runtime";function Card({className:e,size:r=`default`,...i}){return n(`div`,{"data-slot":`card`,"data-size":r,className:t(`
|
|
1
|
+
import{t as e}from"../chunk-IpJEthwI.js";import{cn as t}from"../lib/utils.js";import{jsx as n}from"react/jsx-runtime";function Card({className:e,size:r=`default`,...i}){return n(`div`,{"data-slot":`card`,"data-size":r,className:t(`group/card flex flex-col gap-4 overflow-hidden rounded-xl py-4 text-sm bg-card text-card-foreground ring-foreground/10 ring-1`,`has-data-[slot=card-footer]:pb-0 has-[>img:first-child]:pt-0`,`data-[size=sm]:gap-3 data-[size=sm]:py-3 data-[size=sm]:has-data-[slot=card-footer]:pb-0`,`*:[img:first-child]:rounded-t-xl *:[img:last-child]:rounded-b-xl`,e),...i})}function CardHeader({className:e,...r}){return n(`div`,{"data-slot":`card-header`,className:t(`group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-xl px-4`,`group-data-[size=sm]/card:px-3 [.border-b]:pb-4 group-data-[size=sm]/card:[.border-b]:pb-3`,`has-data-[slot=card-action]:grid-cols-[1fr_auto] has-data-[slot=card-description]:grid-rows-[auto_auto]`,e),...r})}function CardTitle({className:e,...r}){return n(`div`,{"data-slot":`card-title`,className:t(`text-base leading-snug font-medium group-data-[size=sm]/card:text-sm`,e),...r})}function CardDescription({className:e,...r}){return n(`div`,{"data-slot":`card-description`,className:t(`text-muted-foreground text-sm`,e),...r})}function CardAction({className:e,...r}){return n(`div`,{"data-slot":`card-action`,className:t(`col-start-2 row-span-2 row-start-1 self-start justify-self-end`,e),...r})}function CardContent({className:e,...r}){return n(`div`,{"data-slot":`card-content`,className:t(`px-4 group-data-[size=sm]/card:px-3`,e),...r})}function CardFooter({className:e,...r}){return n(`div`,{"data-slot":`card-footer`,className:t(`bg-muted/50 flex items-center rounded-b-xl border-t p-4`,`group-data-[size=sm]/card:p-3`,e),...r})}export{Card,CardAction,CardContent,CardDescription,CardFooter,CardHeader,CardTitle};
|
|
2
2
|
//# sourceMappingURL=card.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"card.js","names":[],"sources":["../../src/components/card.tsx"],"sourcesContent":["import type * as React from 'react'\n\nimport { cn } from '../lib/utils'\n\nexport type CardProps = React.ComponentProps<'div'> & { size?: 'default' | 'sm' }\n\nexport type CardHeaderProps = React.ComponentProps<'div'>\n\nexport type CardTitleProps = React.ComponentProps<'div'>\n\nexport type CardDescriptionProps = React.ComponentProps<'div'>\n\nexport type CardActionProps = React.ComponentProps<'div'>\n\nexport type CardContentProps = React.ComponentProps<'div'>\n\nexport type CardFooterProps = React.ComponentProps<'div'>\n\nfunction Card({ className, size = 'default', ...props }: CardProps) {\n return (\n <div\n data-slot=\"card\"\n data-size={size}\n className={cn(\n '
|
|
1
|
+
{"version":3,"file":"card.js","names":[],"sources":["../../src/components/card.tsx"],"sourcesContent":["import type * as React from 'react'\n\nimport { cn } from '../lib/utils'\n\nexport type CardProps = React.ComponentProps<'div'> & { size?: 'default' | 'sm' }\n\nexport type CardHeaderProps = React.ComponentProps<'div'>\n\nexport type CardTitleProps = React.ComponentProps<'div'>\n\nexport type CardDescriptionProps = React.ComponentProps<'div'>\n\nexport type CardActionProps = React.ComponentProps<'div'>\n\nexport type CardContentProps = React.ComponentProps<'div'>\n\nexport type CardFooterProps = React.ComponentProps<'div'>\n\nfunction Card({ className, size = 'default', ...props }: CardProps) {\n return (\n <div\n data-slot=\"card\"\n data-size={size}\n className={cn(\n 'group/card flex flex-col gap-4 overflow-hidden rounded-xl py-4 text-sm bg-card text-card-foreground ring-foreground/10 ring-1',\n 'has-data-[slot=card-footer]:pb-0 has-[>img:first-child]:pt-0',\n 'data-[size=sm]:gap-3 data-[size=sm]:py-3 data-[size=sm]:has-data-[slot=card-footer]:pb-0',\n '*:[img:first-child]:rounded-t-xl *:[img:last-child]:rounded-b-xl',\n className\n )}\n {...props}\n />\n )\n}\n\nfunction CardHeader({ className, ...props }: CardHeaderProps) {\n return (\n <div\n data-slot=\"card-header\"\n className={cn(\n 'group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-xl px-4',\n 'group-data-[size=sm]/card:px-3 [.border-b]:pb-4 group-data-[size=sm]/card:[.border-b]:pb-3',\n 'has-data-[slot=card-action]:grid-cols-[1fr_auto] has-data-[slot=card-description]:grid-rows-[auto_auto]',\n className\n )}\n {...props}\n />\n )\n}\n\nfunction CardTitle({ className, ...props }: CardTitleProps) {\n return (\n <div\n data-slot=\"card-title\"\n className={cn('text-base leading-snug font-medium group-data-[size=sm]/card:text-sm', className)}\n {...props}\n />\n )\n}\n\nfunction CardDescription({ className, ...props }: CardDescriptionProps) {\n return <div data-slot=\"card-description\" className={cn('text-muted-foreground text-sm', className)} {...props} />\n}\n\nfunction CardAction({ className, ...props }: CardActionProps) {\n return (\n <div\n data-slot=\"card-action\"\n className={cn('col-start-2 row-span-2 row-start-1 self-start justify-self-end', className)}\n {...props}\n />\n )\n}\n\nfunction CardContent({ className, ...props }: CardContentProps) {\n return <div data-slot=\"card-content\" className={cn('px-4 group-data-[size=sm]/card:px-3', className)} {...props} />\n}\n\nfunction CardFooter({ className, ...props }: CardFooterProps) {\n return (\n <div\n data-slot=\"card-footer\"\n className={cn(\n 'bg-muted/50 flex items-center rounded-b-xl border-t p-4',\n 'group-data-[size=sm]/card:p-3',\n className\n )}\n {...props}\n />\n )\n}\n\nexport { Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle }\n"],"mappings":"sHAkBA,SAAS,KAAK,CAAE,YAAW,OAAO,UAAW,GAAG,GAAoB,CAClE,OACE,EAAC,MAAA,CACC,YAAU,OACV,YAAW,EACX,UAAW,EACT,gIACA,+DACA,2FACA,mEACA,EACD,CACD,GAAI,GACJ,CAIN,SAAS,WAAW,CAAE,YAAW,GAAG,GAA0B,CAC5D,OACE,EAAC,MAAA,CACC,YAAU,cACV,UAAW,EACT,kGACA,6FACA,0GACA,EACD,CACD,GAAI,GACJ,CAIN,SAAS,UAAU,CAAE,YAAW,GAAG,GAAyB,CAC1D,OACE,EAAC,MAAA,CACC,YAAU,aACV,UAAW,EAAG,uEAAwE,EAAU,CAChG,GAAI,GACJ,CAIN,SAAS,gBAAgB,CAAE,YAAW,GAAG,GAA+B,CACtE,OAAO,EAAC,MAAA,CAAI,YAAU,mBAAmB,UAAW,EAAG,gCAAiC,EAAU,CAAE,GAAI,GAAS,CAGnH,SAAS,WAAW,CAAE,YAAW,GAAG,GAA0B,CAC5D,OACE,EAAC,MAAA,CACC,YAAU,cACV,UAAW,EAAG,iEAAkE,EAAU,CAC1F,GAAI,GACJ,CAIN,SAAS,YAAY,CAAE,YAAW,GAAG,GAA2B,CAC9D,OAAO,EAAC,MAAA,CAAI,YAAU,eAAe,UAAW,EAAG,sCAAuC,EAAU,CAAE,GAAI,GAAS,CAGrH,SAAS,WAAW,CAAE,YAAW,GAAG,GAA0B,CAC5D,OACE,EAAC,MAAA,CACC,YAAU,cACV,UAAW,EACT,0DACA,gCACA,EACD,CACD,GAAI,GACJ"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { t as __name } from "../chunk-IpJEthwI.js";
|
|
2
|
+
import { VariantProps } from "class-variance-authority";
|
|
3
|
+
import * as react_jsx_runtime0 from "react/jsx-runtime";
|
|
4
|
+
import { Checkbox as Checkbox$1 } from "radix-ui";
|
|
5
|
+
import * as React from "react";
|
|
6
|
+
import * as class_variance_authority_types0 from "class-variance-authority/types";
|
|
7
|
+
|
|
8
|
+
//#region src/components/checkbox.d.ts
|
|
9
|
+
declare const checkboxVariants: (props?: ({
|
|
10
|
+
size?: "default" | "sm" | "lg" | null | undefined;
|
|
11
|
+
} & class_variance_authority_types0.ClassProp) | undefined) => string;
|
|
12
|
+
type CheckboxProps = React.ComponentProps<typeof Checkbox$1.Root> & VariantProps<typeof checkboxVariants>;
|
|
13
|
+
declare function Checkbox({
|
|
14
|
+
className,
|
|
15
|
+
size,
|
|
16
|
+
...props
|
|
17
|
+
}: CheckboxProps): react_jsx_runtime0.JSX.Element;
|
|
18
|
+
//#endregion
|
|
19
|
+
export { Checkbox, CheckboxProps };
|
|
20
|
+
//# sourceMappingURL=checkbox.d.ts.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{t as e}from"../chunk-IpJEthwI.js";import{cn as t}from"../lib/utils.js";import{cva as n}from"class-variance-authority";import{jsx as r}from"react/jsx-runtime";import{Checkbox as i}from"radix-ui";import{IconCheck as a}from"@tabler/icons-react";const o=n(`border-input dark:bg-input/30 data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary data-checked:border-primary aria-invalid:aria-checked:border-primary aria-invalid:border-destructive dark:aria-invalid:border-destructive/50 focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 flex items-center justify-center border transition-colors group-has-disabled/field:opacity-50 focus-visible:ring-3 aria-invalid:ring-3 peer relative shrink-0 outline-none after:absolute after:-inset-x-3 after:-inset-y-2 disabled:cursor-not-allowed disabled:opacity-50`,{variants:{size:{sm:`size-3.5 rounded-[3px] [&_[data-slot=checkbox-indicator]>svg]:size-3`,default:`size-4 rounded-[4px] [&_[data-slot=checkbox-indicator]>svg]:size-3.5`,lg:`size-5 rounded-[5px] [&_[data-slot=checkbox-indicator]>svg]:size-4`}},defaultVariants:{size:`default`}});function Checkbox({className:e,size:n=`default`,...s}){return r(i.Root,{"data-slot":`checkbox`,"data-size":n,className:t(o({size:n}),e),...s,children:r(i.Indicator,{"data-slot":`checkbox-indicator`,className:`grid place-content-center text-current transition-none`,children:r(a,{})})})}export{Checkbox};
|
|
2
|
+
//# sourceMappingURL=checkbox.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"checkbox.js","names":["CheckboxPrimitive"],"sources":["../../src/components/checkbox.tsx"],"sourcesContent":["import type * as React from 'react'\n\nimport { IconCheck } from '@tabler/icons-react'\nimport { cva, type VariantProps } from 'class-variance-authority'\nimport { Checkbox as CheckboxPrimitive } from 'radix-ui'\n\nimport { cn } from '../lib/utils'\n\nconst checkboxVariants = cva(\n 'border-input dark:bg-input/30 data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary data-checked:border-primary aria-invalid:aria-checked:border-primary aria-invalid:border-destructive dark:aria-invalid:border-destructive/50 focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 flex items-center justify-center border transition-colors group-has-disabled/field:opacity-50 focus-visible:ring-3 aria-invalid:ring-3 peer relative shrink-0 outline-none after:absolute after:-inset-x-3 after:-inset-y-2 disabled:cursor-not-allowed disabled:opacity-50',\n {\n variants: {\n size: {\n sm: 'size-3.5 rounded-[3px] [&_[data-slot=checkbox-indicator]>svg]:size-3',\n default: 'size-4 rounded-[4px] [&_[data-slot=checkbox-indicator]>svg]:size-3.5',\n lg: 'size-5 rounded-[5px] [&_[data-slot=checkbox-indicator]>svg]:size-4'\n }\n },\n defaultVariants: {\n size: 'default'\n }\n }\n)\n\nexport type CheckboxProps = React.ComponentProps<typeof CheckboxPrimitive.Root> & VariantProps<typeof checkboxVariants>\n\nfunction Checkbox({ className, size = 'default', ...props }: CheckboxProps) {\n return (\n <CheckboxPrimitive.Root\n data-slot=\"checkbox\"\n data-size={size}\n className={cn(checkboxVariants({ size }), className)}\n {...props}\n >\n <CheckboxPrimitive.Indicator\n data-slot=\"checkbox-indicator\"\n className=\"grid place-content-center text-current transition-none\"\n >\n <IconCheck />\n </CheckboxPrimitive.Indicator>\n </CheckboxPrimitive.Root>\n )\n}\n\nexport { Checkbox }\n"],"mappings":"yPAQA,MAAM,EAAmB,EACvB,+oBACA,CACE,SAAU,CACR,KAAM,CACJ,GAAI,uEACJ,QAAS,uEACT,GAAI,qEACL,CACF,CACD,gBAAiB,CACf,KAAM,UACP,CACF,CACF,CAID,SAAS,SAAS,CAAE,YAAW,OAAO,UAAW,GAAG,GAAwB,CAC1E,OACE,EAACA,EAAkB,KAAA,CACjB,YAAU,WACV,YAAW,EACX,UAAW,EAAG,EAAiB,CAAE,OAAM,CAAC,CAAE,EAAU,CACpD,GAAI,WAEJ,EAACA,EAAkB,UAAA,CACjB,YAAU,qBACV,UAAU,kEAEV,EAAC,EAAA,EAAA,CAAY,EACe,EACP"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { t as __name } from "../chunk-IpJEthwI.js";
|
|
2
2
|
import { VariantProps } from "class-variance-authority";
|
|
3
3
|
import * as react_jsx_runtime0 from "react/jsx-runtime";
|
|
4
|
+
import { Dialog as Dialog$1 } from "radix-ui";
|
|
4
5
|
import * as React from "react";
|
|
5
|
-
import { Dialog as Dialog$1 } from "@base-ui/react/dialog";
|
|
6
6
|
import * as class_variance_authority_types0 from "class-variance-authority/types";
|
|
7
7
|
|
|
8
8
|
//#region src/components/dialog.d.ts
|
|
@@ -10,33 +10,41 @@ declare const dialogContentVariants: (props?: ({
|
|
|
10
10
|
size?: "sm" | "lg" | "md" | "xl" | "2xl" | null | undefined;
|
|
11
11
|
} & class_variance_authority_types0.ClassProp) | undefined) => string;
|
|
12
12
|
type DialogSize = NonNullable<VariantProps<typeof dialogContentVariants>['size']>;
|
|
13
|
-
type DialogProps = Dialog$1.Root
|
|
13
|
+
type DialogProps = React.ComponentProps<typeof Dialog$1.Root> & {
|
|
14
14
|
size?: DialogSize;
|
|
15
15
|
};
|
|
16
|
-
type DialogTriggerProps = Dialog$1.Trigger
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
type
|
|
20
|
-
type
|
|
16
|
+
type DialogTriggerProps = React.ComponentProps<typeof Dialog$1.Trigger> & {
|
|
17
|
+
render?: React.ReactElement;
|
|
18
|
+
};
|
|
19
|
+
type DialogPortalProps = React.ComponentProps<typeof Dialog$1.Portal>;
|
|
20
|
+
type DialogCloseProps = React.ComponentProps<typeof Dialog$1.Close> & {
|
|
21
|
+
render?: React.ReactElement;
|
|
22
|
+
};
|
|
23
|
+
type DialogOverlayProps = React.ComponentProps<typeof Dialog$1.Overlay>;
|
|
24
|
+
type DialogContentProps = React.ComponentProps<typeof Dialog$1.Content> & {
|
|
21
25
|
showCloseButton?: boolean;
|
|
22
26
|
};
|
|
23
27
|
type DialogHeaderProps = React.ComponentProps<'div'>;
|
|
24
28
|
type DialogFooterProps = React.ComponentProps<'div'> & {
|
|
25
29
|
showCloseButton?: boolean;
|
|
26
30
|
};
|
|
27
|
-
type DialogTitleProps = Dialog$1.Title
|
|
28
|
-
type DialogDescriptionProps = Dialog$1.Description
|
|
31
|
+
type DialogTitleProps = React.ComponentProps<typeof Dialog$1.Title>;
|
|
32
|
+
type DialogDescriptionProps = React.ComponentProps<typeof Dialog$1.Description>;
|
|
29
33
|
declare function Dialog({
|
|
30
34
|
size,
|
|
31
35
|
...props
|
|
32
36
|
}: DialogProps): react_jsx_runtime0.JSX.Element;
|
|
33
37
|
declare function DialogTrigger({
|
|
38
|
+
render,
|
|
39
|
+
children,
|
|
34
40
|
...props
|
|
35
41
|
}: DialogTriggerProps): react_jsx_runtime0.JSX.Element;
|
|
36
42
|
declare function DialogPortal({
|
|
37
43
|
...props
|
|
38
44
|
}: DialogPortalProps): react_jsx_runtime0.JSX.Element;
|
|
39
45
|
declare function DialogClose({
|
|
46
|
+
render,
|
|
47
|
+
children,
|
|
40
48
|
...props
|
|
41
49
|
}: DialogCloseProps): react_jsx_runtime0.JSX.Element;
|
|
42
50
|
declare function DialogOverlay({
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{t as e}from"../chunk-IpJEthwI.js";import{cn as t}from"../lib/utils.js";import{Button as n}from"./button.js";import{cva as r}from"class-variance-authority";import{jsx as i,jsxs as a}from"react/jsx-runtime";import
|
|
1
|
+
import{t as e}from"../chunk-IpJEthwI.js";import{cn as t}from"../lib/utils.js";import{Button as n}from"./button.js";import{cva as r}from"class-variance-authority";import{jsx as i,jsxs as a}from"react/jsx-runtime";import{Dialog as o}from"radix-ui";import{IconX as s}from"@tabler/icons-react";import*as c from"react";const l=r(`bg-background data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 ring-foreground/10 grid max-w-[calc(100%-2rem)] gap-4 rounded-xl p-4 text-sm ring-1 duration-100 fixed top-1/2 left-1/2 z-50 w-full -translate-x-1/2 -translate-y-1/2 outline-none`,{variants:{size:{sm:`sm:max-w-sm`,md:`sm:max-w-md`,lg:`sm:max-w-lg`,xl:`sm:max-w-xl`,"2xl":`sm:max-w-2xl`}},defaultVariants:{size:`sm`}}),u=c.createContext({size:`sm`});function Dialog({size:e=`sm`,...t}){let n=c.useMemo(()=>({size:e}),[e]);return i(u.Provider,{value:n,children:i(o.Root,{"data-slot":`dialog`,...t})})}function DialogTrigger({render:e,children:t,...n}){return e?i(o.Trigger,{"data-slot":`dialog-trigger`,asChild:!0,...n,children:e}):i(o.Trigger,{"data-slot":`dialog-trigger`,...n,children:t})}function DialogPortal({...e}){return i(o.Portal,{"data-slot":`dialog-portal`,...e})}function DialogClose({render:e,children:t,...n}){return e?i(o.Close,{"data-slot":`dialog-close`,asChild:!0,...n,children:e}):i(o.Close,{"data-slot":`dialog-close`,...n,children:t})}function DialogOverlay({className:e,...n}){return i(o.Overlay,{"data-slot":`dialog-overlay`,className:t(`bg-black/10 fixed inset-0 isolate z-50`,`data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0`,`duration-100 supports-backdrop-filter:backdrop-blur-xs`,e),...n})}function DialogContent({className:e,children:r,showCloseButton:d=!0,...f}){let{size:p}=c.useContext(u);return a(DialogPortal,{children:[i(DialogOverlay,{}),a(o.Content,{"data-slot":`dialog-content`,className:t(l({size:p}),e),...f,children:[r,d&&i(o.Close,{"data-slot":`dialog-close`,asChild:!0,children:a(n,{variant:`ghost`,className:`absolute top-2 right-2`,size:`icon-sm`,children:[i(s,{}),i(`span`,{className:`sr-only`,children:`Close`})]})})]})]})}function DialogHeader({className:e,...n}){return i(`div`,{"data-slot":`dialog-header`,className:t(`gap-2 flex flex-col`,e),...n})}function DialogFooter({className:e,showCloseButton:r=!1,children:s,...c}){return a(`div`,{"data-slot":`dialog-footer`,className:t(`bg-muted/50 -mx-4 -mb-4 rounded-b-xl border-t p-4`,`flex flex-col-reverse gap-2 sm:flex-row sm:justify-end`,e),...c,children:[s,r&&i(o.Close,{asChild:!0,children:i(n,{variant:`outline`,children:`Close`})})]})}function DialogTitle({className:e,...n}){return i(o.Title,{"data-slot":`dialog-title`,className:t(`text-base leading-none font-medium`,e),...n})}function DialogDescription({className:e,...n}){return i(o.Description,{"data-slot":`dialog-description`,className:t(`text-muted-foreground text-sm`,`*:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground`,e),...n})}export{Dialog,DialogClose,DialogContent,DialogDescription,DialogFooter,DialogHeader,DialogOverlay,DialogPortal,DialogTitle,DialogTrigger};
|
|
2
2
|
//# sourceMappingURL=dialog.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dialog.js","names":["DialogPrimitive"],"sources":["../../src/components/dialog.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport {
|
|
1
|
+
{"version":3,"file":"dialog.js","names":["DialogPrimitive"],"sources":["../../src/components/dialog.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport { IconX } from '@tabler/icons-react'\nimport { cva, type VariantProps } from 'class-variance-authority'\nimport { Dialog as DialogPrimitive } from 'radix-ui'\n\nimport { cn } from '../lib/utils'\nimport { Button } from './button'\n\nconst dialogContentVariants = cva(\n 'bg-background data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 ring-foreground/10 grid max-w-[calc(100%-2rem)] gap-4 rounded-xl p-4 text-sm ring-1 duration-100 fixed top-1/2 left-1/2 z-50 w-full -translate-x-1/2 -translate-y-1/2 outline-none',\n {\n variants: {\n size: {\n sm: 'sm:max-w-sm',\n md: 'sm:max-w-md',\n lg: 'sm:max-w-lg',\n xl: 'sm:max-w-xl',\n '2xl': 'sm:max-w-2xl'\n }\n },\n defaultVariants: {\n size: 'sm'\n }\n }\n)\n\ntype DialogSize = NonNullable<VariantProps<typeof dialogContentVariants>['size']>\ntype DialogSizeContextValue = { size: DialogSize }\nconst DialogSizeContext = React.createContext<DialogSizeContextValue>({ size: 'sm' })\n\nexport type DialogProps = React.ComponentProps<typeof DialogPrimitive.Root> & { size?: DialogSize }\nexport type DialogTriggerProps = React.ComponentProps<typeof DialogPrimitive.Trigger> & { render?: React.ReactElement }\nexport type DialogPortalProps = React.ComponentProps<typeof DialogPrimitive.Portal>\nexport type DialogCloseProps = React.ComponentProps<typeof DialogPrimitive.Close> & { render?: React.ReactElement }\nexport type DialogOverlayProps = React.ComponentProps<typeof DialogPrimitive.Overlay>\nexport type DialogContentProps = React.ComponentProps<typeof DialogPrimitive.Content> & {\n showCloseButton?: boolean\n}\nexport type DialogHeaderProps = React.ComponentProps<'div'>\nexport type DialogFooterProps = React.ComponentProps<'div'> & { showCloseButton?: boolean }\nexport type DialogTitleProps = React.ComponentProps<typeof DialogPrimitive.Title>\nexport type DialogDescriptionProps = React.ComponentProps<typeof DialogPrimitive.Description>\n\nfunction Dialog({ size = 'sm', ...props }: DialogProps) {\n const contextValue = React.useMemo<DialogSizeContextValue>(() => ({ size }), [size])\n\n return (\n <DialogSizeContext.Provider value={contextValue}>\n <DialogPrimitive.Root data-slot=\"dialog\" {...props} />\n </DialogSizeContext.Provider>\n )\n}\n\nfunction DialogTrigger({ render, children, ...props }: DialogTriggerProps) {\n if (render) {\n return (\n <DialogPrimitive.Trigger data-slot=\"dialog-trigger\" asChild {...props}>\n {render}\n </DialogPrimitive.Trigger>\n )\n }\n\n return (\n <DialogPrimitive.Trigger data-slot=\"dialog-trigger\" {...props}>\n {children}\n </DialogPrimitive.Trigger>\n )\n}\n\nfunction DialogPortal({ ...props }: DialogPortalProps) {\n return <DialogPrimitive.Portal data-slot=\"dialog-portal\" {...props} />\n}\n\nfunction DialogClose({ render, children, ...props }: DialogCloseProps) {\n if (render) {\n return (\n <DialogPrimitive.Close data-slot=\"dialog-close\" asChild {...props}>\n {render}\n </DialogPrimitive.Close>\n )\n }\n\n return (\n <DialogPrimitive.Close data-slot=\"dialog-close\" {...props}>\n {children}\n </DialogPrimitive.Close>\n )\n}\n\nfunction DialogOverlay({ className, ...props }: DialogOverlayProps) {\n return (\n <DialogPrimitive.Overlay\n data-slot=\"dialog-overlay\"\n className={cn(\n 'bg-black/10 fixed inset-0 isolate z-50',\n 'data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0',\n 'duration-100 supports-backdrop-filter:backdrop-blur-xs',\n className\n )}\n {...props}\n />\n )\n}\n\nfunction DialogContent({ className, children, showCloseButton = true, ...props }: DialogContentProps) {\n const { size } = React.useContext(DialogSizeContext)\n\n return (\n <DialogPortal>\n <DialogOverlay />\n <DialogPrimitive.Content\n data-slot=\"dialog-content\"\n className={cn(dialogContentVariants({ size }), className)}\n {...props}\n >\n {children}\n {showCloseButton && (\n <DialogPrimitive.Close data-slot=\"dialog-close\" asChild>\n <Button variant=\"ghost\" className=\"absolute top-2 right-2\" size=\"icon-sm\">\n <IconX />\n <span className=\"sr-only\">Close</span>\n </Button>\n </DialogPrimitive.Close>\n )}\n </DialogPrimitive.Content>\n </DialogPortal>\n )\n}\n\nfunction DialogHeader({ className, ...props }: DialogHeaderProps) {\n return <div data-slot=\"dialog-header\" className={cn('gap-2 flex flex-col', className)} {...props} />\n}\n\nfunction DialogFooter({ className, showCloseButton = false, children, ...props }: DialogFooterProps) {\n return (\n <div\n data-slot=\"dialog-footer\"\n className={cn(\n 'bg-muted/50 -mx-4 -mb-4 rounded-b-xl border-t p-4',\n 'flex flex-col-reverse gap-2 sm:flex-row sm:justify-end',\n className\n )}\n {...props}\n >\n {children}\n {showCloseButton && (\n <DialogPrimitive.Close asChild>\n <Button variant=\"outline\">Close</Button>\n </DialogPrimitive.Close>\n )}\n </div>\n )\n}\n\nfunction DialogTitle({ className, ...props }: DialogTitleProps) {\n return (\n <DialogPrimitive.Title\n data-slot=\"dialog-title\"\n className={cn('text-base leading-none font-medium', className)}\n {...props}\n />\n )\n}\n\nfunction DialogDescription({ className, ...props }: DialogDescriptionProps) {\n return (\n <DialogPrimitive.Description\n data-slot=\"dialog-description\"\n className={cn(\n 'text-muted-foreground text-sm',\n '*:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground',\n className\n )}\n {...props}\n />\n )\n}\n\nexport {\n Dialog,\n DialogClose,\n DialogContent,\n DialogDescription,\n DialogFooter,\n DialogHeader,\n DialogOverlay,\n DialogPortal,\n DialogTitle,\n DialogTrigger\n}\n"],"mappings":"0TASA,MAAM,EAAwB,EAC5B,wUACA,CACE,SAAU,CACR,KAAM,CACJ,GAAI,cACJ,GAAI,cACJ,GAAI,cACJ,GAAI,cACJ,MAAO,eACR,CACF,CACD,gBAAiB,CACf,KAAM,KACP,CACF,CACF,CAIK,EAAoB,EAAM,cAAsC,CAAE,KAAM,KAAM,CAAC,CAerF,SAAS,OAAO,CAAE,OAAO,KAAM,GAAG,GAAsB,CACtD,IAAM,EAAe,EAAM,aAAuC,CAAE,OAAM,EAAG,CAAC,EAAK,CAAC,CAEpF,OACE,EAAC,EAAkB,SAAA,CAAS,MAAO,WACjC,EAACA,EAAgB,KAAA,CAAK,YAAU,SAAS,GAAI,GAAS,EAC3B,CAIjC,SAAS,cAAc,CAAE,SAAQ,WAAU,GAAG,GAA6B,CASzE,OARI,EAEA,EAACA,EAAgB,QAAA,CAAQ,YAAU,iBAAiB,QAAA,GAAQ,GAAI,WAC7D,GACuB,CAK5B,EAACA,EAAgB,QAAA,CAAQ,YAAU,iBAAiB,GAAI,EACrD,YACuB,CAI9B,SAAS,aAAa,CAAE,GAAG,GAA4B,CACrD,OAAO,EAACA,EAAgB,OAAA,CAAO,YAAU,gBAAgB,GAAI,GAAS,CAGxE,SAAS,YAAY,CAAE,SAAQ,WAAU,GAAG,GAA2B,CASrE,OARI,EAEA,EAACA,EAAgB,MAAA,CAAM,YAAU,eAAe,QAAA,GAAQ,GAAI,WACzD,GACqB,CAK1B,EAACA,EAAgB,MAAA,CAAM,YAAU,eAAe,GAAI,EACjD,YACqB,CAI5B,SAAS,cAAc,CAAE,YAAW,GAAG,GAA6B,CAClE,OACE,EAACA,EAAgB,QAAA,CACf,YAAU,iBACV,UAAW,EACT,yCACA,0FACA,yDACA,EACD,CACD,GAAI,GACJ,CAIN,SAAS,cAAc,CAAE,YAAW,WAAU,kBAAkB,GAAM,GAAG,GAA6B,CACpG,GAAM,CAAE,QAAS,EAAM,WAAW,EAAkB,CAEpD,OACE,EAAC,aAAA,CAAA,SAAA,CACC,EAAC,cAAA,EAAA,CAAgB,CACjB,EAACA,EAAgB,QAAA,CACf,YAAU,iBACV,UAAW,EAAG,EAAsB,CAAE,OAAM,CAAC,CAAE,EAAU,CACzD,GAAI,YAEH,EACA,GACC,EAACA,EAAgB,MAAA,CAAM,YAAU,eAAe,QAAA,YAC9C,EAAC,EAAA,CAAO,QAAQ,QAAQ,UAAU,yBAAyB,KAAK,oBAC9D,EAAC,EAAA,EAAA,CAAQ,CACT,EAAC,OAAA,CAAK,UAAU,mBAAU,SAAY,CAAA,EAC/B,EACa,CAAA,EAEF,CAAA,CAAA,CACb,CAInB,SAAS,aAAa,CAAE,YAAW,GAAG,GAA4B,CAChE,OAAO,EAAC,MAAA,CAAI,YAAU,gBAAgB,UAAW,EAAG,sBAAuB,EAAU,CAAE,GAAI,GAAS,CAGtG,SAAS,aAAa,CAAE,YAAW,kBAAkB,GAAO,WAAU,GAAG,GAA4B,CACnG,OACE,EAAC,MAAA,CACC,YAAU,gBACV,UAAW,EACT,oDACA,yDACA,EACD,CACD,GAAI,YAEH,EACA,GACC,EAACA,EAAgB,MAAA,CAAM,QAAA,YACrB,EAAC,EAAA,CAAO,QAAQ,mBAAU,SAAc,EAClB,CAAA,EAEtB,CAIV,SAAS,YAAY,CAAE,YAAW,GAAG,GAA2B,CAC9D,OACE,EAACA,EAAgB,MAAA,CACf,YAAU,eACV,UAAW,EAAG,qCAAsC,EAAU,CAC9D,GAAI,GACJ,CAIN,SAAS,kBAAkB,CAAE,YAAW,GAAG,GAAiC,CAC1E,OACE,EAACA,EAAgB,YAAA,CACf,YAAU,qBACV,UAAW,EACT,gCACA,uEACA,EACD,CACD,GAAI,GACJ"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{t as e}from"../chunk-IpJEthwI.js";import{cn as t}from"../lib/utils.js";import{cva as n}from"class-variance-authority";import{jsx as r,jsxs as i}from"react/jsx-runtime";import*as a from"react";import{Drawer as o}from"vaul";const s=n(`bg-background flex h-auto flex-col text-sm data-[vaul-drawer-direction=bottom]:inset-x-0 data-[vaul-drawer-direction=bottom]:bottom-0 data-[vaul-drawer-direction=bottom]:rounded-t-xl data-[vaul-drawer-direction=bottom]:border-t data-[vaul-drawer-direction=left]:inset-y-0 data-[vaul-drawer-direction=left]:left-0 data-[vaul-drawer-direction=left]:rounded-r-xl data-[vaul-drawer-direction=left]:border-r data-[vaul-drawer-direction=right]:inset-y-0 data-[vaul-drawer-direction=right]:right-0 data-[vaul-drawer-direction=right]:rounded-l-xl data-[vaul-drawer-direction=right]:border-l data-[vaul-drawer-direction=top]:inset-x-0 data-[vaul-drawer-direction=top]:top-0 data-[vaul-drawer-direction=top]:rounded-b-xl data-[vaul-drawer-direction=top]:border-b group/drawer-content fixed z-50`,{variants:{size:{sm:`data-[vaul-drawer-direction=bottom]:mt-24 data-[vaul-drawer-direction=bottom]:max-h-[80vh] data-[vaul-drawer-direction=top]:mb-24 data-[vaul-drawer-direction=top]:max-h-[80vh] data-[vaul-drawer-direction=left]:w-3/4 data-[vaul-drawer-direction=left]:sm:max-w-sm data-[vaul-drawer-direction=right]:w-3/4 data-[vaul-drawer-direction=right]:sm:max-w-sm`,md:`data-[vaul-drawer-direction=bottom]:mt-20 data-[vaul-drawer-direction=bottom]:max-h-[85vh] data-[vaul-drawer-direction=top]:mb-20 data-[vaul-drawer-direction=top]:max-h-[85vh] data-[vaul-drawer-direction=left]:w-4/5 data-[vaul-drawer-direction=left]:sm:max-w-md data-[vaul-drawer-direction=right]:w-4/5 data-[vaul-drawer-direction=right]:sm:max-w-md`,lg:`data-[vaul-drawer-direction=bottom]:mt-12 data-[vaul-drawer-direction=bottom]:max-h-[90vh] data-[vaul-drawer-direction=top]:mb-12 data-[vaul-drawer-direction=top]:max-h-[90vh] data-[vaul-drawer-direction=left]:w-[90%] data-[vaul-drawer-direction=left]:sm:max-w-lg data-[vaul-drawer-direction=right]:w-[90%] data-[vaul-drawer-direction=right]:sm:max-w-lg`}},defaultVariants:{size:`sm`}}),c=a.createContext({size:`sm`});function Drawer({size:e=`sm`,...t}){let n=a.useMemo(()=>({size:e}),[e]);return r(c.Provider,{value:n,children:r(o.Root,{"data-slot":`drawer`,...t})})}function DrawerTrigger({...e}){return r(o.Trigger,{"data-slot":`drawer-trigger`,...e})}function DrawerPortal({...e}){return r(o.Portal,{"data-slot":`drawer-portal`,...e})}function DrawerClose({...e}){return r(o.Close,{"data-slot":`drawer-close`,...e})}function DrawerOverlay({className:e,...n}){return r(o.Overlay,{"data-slot":`drawer-overlay`,className:t(`data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0
|
|
1
|
+
import{t as e}from"../chunk-IpJEthwI.js";import{cn as t}from"../lib/utils.js";import{cva as n}from"class-variance-authority";import{jsx as r,jsxs as i}from"react/jsx-runtime";import*as a from"react";import{Drawer as o}from"vaul";const s=n(`bg-background flex h-auto flex-col text-sm data-[vaul-drawer-direction=bottom]:inset-x-0 data-[vaul-drawer-direction=bottom]:bottom-0 data-[vaul-drawer-direction=bottom]:rounded-t-xl data-[vaul-drawer-direction=bottom]:border-t data-[vaul-drawer-direction=left]:inset-y-0 data-[vaul-drawer-direction=left]:left-0 data-[vaul-drawer-direction=left]:rounded-r-xl data-[vaul-drawer-direction=left]:border-r data-[vaul-drawer-direction=right]:inset-y-0 data-[vaul-drawer-direction=right]:right-0 data-[vaul-drawer-direction=right]:rounded-l-xl data-[vaul-drawer-direction=right]:border-l data-[vaul-drawer-direction=top]:inset-x-0 data-[vaul-drawer-direction=top]:top-0 data-[vaul-drawer-direction=top]:rounded-b-xl data-[vaul-drawer-direction=top]:border-b group/drawer-content fixed z-50`,{variants:{size:{sm:`data-[vaul-drawer-direction=bottom]:mt-24 data-[vaul-drawer-direction=bottom]:max-h-[80vh] data-[vaul-drawer-direction=top]:mb-24 data-[vaul-drawer-direction=top]:max-h-[80vh] data-[vaul-drawer-direction=left]:w-3/4 data-[vaul-drawer-direction=left]:sm:max-w-sm data-[vaul-drawer-direction=right]:w-3/4 data-[vaul-drawer-direction=right]:sm:max-w-sm`,md:`data-[vaul-drawer-direction=bottom]:mt-20 data-[vaul-drawer-direction=bottom]:max-h-[85vh] data-[vaul-drawer-direction=top]:mb-20 data-[vaul-drawer-direction=top]:max-h-[85vh] data-[vaul-drawer-direction=left]:w-4/5 data-[vaul-drawer-direction=left]:sm:max-w-md data-[vaul-drawer-direction=right]:w-4/5 data-[vaul-drawer-direction=right]:sm:max-w-md`,lg:`data-[vaul-drawer-direction=bottom]:mt-12 data-[vaul-drawer-direction=bottom]:max-h-[90vh] data-[vaul-drawer-direction=top]:mb-12 data-[vaul-drawer-direction=top]:max-h-[90vh] data-[vaul-drawer-direction=left]:w-[90%] data-[vaul-drawer-direction=left]:sm:max-w-lg data-[vaul-drawer-direction=right]:w-[90%] data-[vaul-drawer-direction=right]:sm:max-w-lg`}},defaultVariants:{size:`sm`}}),c=a.createContext({size:`sm`});function Drawer({size:e=`sm`,...t}){let n=a.useMemo(()=>({size:e}),[e]);return r(c.Provider,{value:n,children:r(o.Root,{"data-slot":`drawer`,...t})})}function DrawerTrigger({...e}){return r(o.Trigger,{"data-slot":`drawer-trigger`,...e})}function DrawerPortal({...e}){return r(o.Portal,{"data-slot":`drawer-portal`,...e})}function DrawerClose({...e}){return r(o.Close,{"data-slot":`drawer-close`,...e})}function DrawerOverlay({className:e,...n}){return r(o.Overlay,{"data-slot":`drawer-overlay`,className:t(`bg-black/10 fixed inset-0 z-50`,`data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0`,`supports-backdrop-filter:backdrop-blur-xs`,e),...n})}function DrawerContent({className:e,children:n,...l}){let{size:u}=a.useContext(c);return i(DrawerPortal,{"data-slot":`drawer-portal`,children:[r(DrawerOverlay,{}),i(o.Content,{"data-slot":`drawer-content`,className:t(s({size:u}),e),...l,children:[r(`div`,{className:`bg-muted mt-4 h-1 w-25 rounded-full mx-auto hidden shrink-0 group-data-[vaul-drawer-direction=bottom]/drawer-content:block`}),n]})]})}function DrawerHeader({className:e,...n}){return r(`div`,{"data-slot":`drawer-header`,className:t(`p-4 flex flex-col gap-0.5 md:gap-0.5`,`group-data-[vaul-drawer-direction=bottom]/drawer-content:text-center`,`group-data-[vaul-drawer-direction=top]/drawer-content:text-center md:text-left`,e),...n})}function DrawerFooter({className:e,...n}){return r(`div`,{"data-slot":`drawer-footer`,className:t(`gap-2 p-4 mt-auto flex flex-col`,e),...n})}function DrawerTitle({className:e,...n}){return r(o.Title,{"data-slot":`drawer-title`,className:t(`text-foreground text-base font-medium`,e),...n})}function DrawerDescription({className:e,...n}){return r(o.Description,{"data-slot":`drawer-description`,className:t(`text-muted-foreground text-sm`,e),...n})}export{Drawer,DrawerClose,DrawerContent,DrawerDescription,DrawerFooter,DrawerHeader,DrawerOverlay,DrawerPortal,DrawerTitle,DrawerTrigger};
|
|
2
2
|
//# sourceMappingURL=drawer.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"drawer.js","names":["DrawerPrimitive"],"sources":["../../src/components/drawer.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport { cva, type VariantProps } from 'class-variance-authority'\nimport { Drawer as DrawerPrimitive } from 'vaul'\n\nimport { cn } from '../lib/utils'\n\nconst drawerContentVariants = cva(\n 'bg-background flex h-auto flex-col text-sm data-[vaul-drawer-direction=bottom]:inset-x-0 data-[vaul-drawer-direction=bottom]:bottom-0 data-[vaul-drawer-direction=bottom]:rounded-t-xl data-[vaul-drawer-direction=bottom]:border-t data-[vaul-drawer-direction=left]:inset-y-0 data-[vaul-drawer-direction=left]:left-0 data-[vaul-drawer-direction=left]:rounded-r-xl data-[vaul-drawer-direction=left]:border-r data-[vaul-drawer-direction=right]:inset-y-0 data-[vaul-drawer-direction=right]:right-0 data-[vaul-drawer-direction=right]:rounded-l-xl data-[vaul-drawer-direction=right]:border-l data-[vaul-drawer-direction=top]:inset-x-0 data-[vaul-drawer-direction=top]:top-0 data-[vaul-drawer-direction=top]:rounded-b-xl data-[vaul-drawer-direction=top]:border-b group/drawer-content fixed z-50',\n {\n variants: {\n size: {\n sm: 'data-[vaul-drawer-direction=bottom]:mt-24 data-[vaul-drawer-direction=bottom]:max-h-[80vh] data-[vaul-drawer-direction=top]:mb-24 data-[vaul-drawer-direction=top]:max-h-[80vh] data-[vaul-drawer-direction=left]:w-3/4 data-[vaul-drawer-direction=left]:sm:max-w-sm data-[vaul-drawer-direction=right]:w-3/4 data-[vaul-drawer-direction=right]:sm:max-w-sm',\n md: 'data-[vaul-drawer-direction=bottom]:mt-20 data-[vaul-drawer-direction=bottom]:max-h-[85vh] data-[vaul-drawer-direction=top]:mb-20 data-[vaul-drawer-direction=top]:max-h-[85vh] data-[vaul-drawer-direction=left]:w-4/5 data-[vaul-drawer-direction=left]:sm:max-w-md data-[vaul-drawer-direction=right]:w-4/5 data-[vaul-drawer-direction=right]:sm:max-w-md',\n lg: 'data-[vaul-drawer-direction=bottom]:mt-12 data-[vaul-drawer-direction=bottom]:max-h-[90vh] data-[vaul-drawer-direction=top]:mb-12 data-[vaul-drawer-direction=top]:max-h-[90vh] data-[vaul-drawer-direction=left]:w-[90%] data-[vaul-drawer-direction=left]:sm:max-w-lg data-[vaul-drawer-direction=right]:w-[90%] data-[vaul-drawer-direction=right]:sm:max-w-lg'\n }\n },\n defaultVariants: {\n size: 'sm'\n }\n }\n)\n\ntype DrawerSize = NonNullable<VariantProps<typeof drawerContentVariants>['size']>\
|
|
1
|
+
{"version":3,"file":"drawer.js","names":["DrawerPrimitive"],"sources":["../../src/components/drawer.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport { cva, type VariantProps } from 'class-variance-authority'\nimport { Drawer as DrawerPrimitive } from 'vaul'\n\nimport { cn } from '../lib/utils'\n\nconst drawerContentVariants = cva(\n 'bg-background flex h-auto flex-col text-sm data-[vaul-drawer-direction=bottom]:inset-x-0 data-[vaul-drawer-direction=bottom]:bottom-0 data-[vaul-drawer-direction=bottom]:rounded-t-xl data-[vaul-drawer-direction=bottom]:border-t data-[vaul-drawer-direction=left]:inset-y-0 data-[vaul-drawer-direction=left]:left-0 data-[vaul-drawer-direction=left]:rounded-r-xl data-[vaul-drawer-direction=left]:border-r data-[vaul-drawer-direction=right]:inset-y-0 data-[vaul-drawer-direction=right]:right-0 data-[vaul-drawer-direction=right]:rounded-l-xl data-[vaul-drawer-direction=right]:border-l data-[vaul-drawer-direction=top]:inset-x-0 data-[vaul-drawer-direction=top]:top-0 data-[vaul-drawer-direction=top]:rounded-b-xl data-[vaul-drawer-direction=top]:border-b group/drawer-content fixed z-50',\n {\n variants: {\n size: {\n sm: 'data-[vaul-drawer-direction=bottom]:mt-24 data-[vaul-drawer-direction=bottom]:max-h-[80vh] data-[vaul-drawer-direction=top]:mb-24 data-[vaul-drawer-direction=top]:max-h-[80vh] data-[vaul-drawer-direction=left]:w-3/4 data-[vaul-drawer-direction=left]:sm:max-w-sm data-[vaul-drawer-direction=right]:w-3/4 data-[vaul-drawer-direction=right]:sm:max-w-sm',\n md: 'data-[vaul-drawer-direction=bottom]:mt-20 data-[vaul-drawer-direction=bottom]:max-h-[85vh] data-[vaul-drawer-direction=top]:mb-20 data-[vaul-drawer-direction=top]:max-h-[85vh] data-[vaul-drawer-direction=left]:w-4/5 data-[vaul-drawer-direction=left]:sm:max-w-md data-[vaul-drawer-direction=right]:w-4/5 data-[vaul-drawer-direction=right]:sm:max-w-md',\n lg: 'data-[vaul-drawer-direction=bottom]:mt-12 data-[vaul-drawer-direction=bottom]:max-h-[90vh] data-[vaul-drawer-direction=top]:mb-12 data-[vaul-drawer-direction=top]:max-h-[90vh] data-[vaul-drawer-direction=left]:w-[90%] data-[vaul-drawer-direction=left]:sm:max-w-lg data-[vaul-drawer-direction=right]:w-[90%] data-[vaul-drawer-direction=right]:sm:max-w-lg'\n }\n },\n defaultVariants: {\n size: 'sm'\n }\n }\n)\n\ntype DrawerSize = NonNullable<VariantProps<typeof drawerContentVariants>['size']>\ntype DrawerSizeContextValue = { size: DrawerSize }\nconst DrawerSizeContext = React.createContext<DrawerSizeContextValue>({ size: 'sm' })\n\nexport type DrawerProps = React.ComponentProps<typeof DrawerPrimitive.Root> & { size?: DrawerSize }\nexport type DrawerTriggerProps = React.ComponentProps<typeof DrawerPrimitive.Trigger>\nexport type DrawerPortalProps = React.ComponentProps<typeof DrawerPrimitive.Portal>\nexport type DrawerCloseProps = React.ComponentProps<typeof DrawerPrimitive.Close>\nexport type DrawerOverlayProps = React.ComponentProps<typeof DrawerPrimitive.Overlay>\nexport type DrawerContentProps = React.ComponentProps<typeof DrawerPrimitive.Content>\nexport type DrawerHeaderProps = React.ComponentProps<'div'>\nexport type DrawerFooterProps = React.ComponentProps<'div'>\nexport type DrawerTitleProps = React.ComponentProps<typeof DrawerPrimitive.Title>\nexport type DrawerDescriptionProps = React.ComponentProps<typeof DrawerPrimitive.Description>\n\nfunction Drawer({ size = 'sm', ...props }: DrawerProps) {\n const contextValue = React.useMemo<DrawerSizeContextValue>(() => ({ size }), [size])\n\n return (\n <DrawerSizeContext.Provider value={contextValue}>\n <DrawerPrimitive.Root data-slot=\"drawer\" {...props} />\n </DrawerSizeContext.Provider>\n )\n}\n\nfunction DrawerTrigger({ ...props }: DrawerTriggerProps) {\n return <DrawerPrimitive.Trigger data-slot=\"drawer-trigger\" {...props} />\n}\n\nfunction DrawerPortal({ ...props }: DrawerPortalProps) {\n return <DrawerPrimitive.Portal data-slot=\"drawer-portal\" {...props} />\n}\n\nfunction DrawerClose({ ...props }: DrawerCloseProps) {\n return <DrawerPrimitive.Close data-slot=\"drawer-close\" {...props} />\n}\n\nfunction DrawerOverlay({ className, ...props }: DrawerOverlayProps) {\n return (\n <DrawerPrimitive.Overlay\n data-slot=\"drawer-overlay\"\n className={cn(\n 'bg-black/10 fixed inset-0 z-50',\n 'data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0',\n 'supports-backdrop-filter:backdrop-blur-xs',\n className\n )}\n {...props}\n />\n )\n}\n\nfunction DrawerContent({ className, children, ...props }: DrawerContentProps) {\n const { size } = React.useContext(DrawerSizeContext)\n\n return (\n <DrawerPortal data-slot=\"drawer-portal\">\n <DrawerOverlay />\n <DrawerPrimitive.Content\n data-slot=\"drawer-content\"\n className={cn(drawerContentVariants({ size }), className)}\n {...props}\n >\n <div className=\"bg-muted mt-4 h-1 w-25 rounded-full mx-auto hidden shrink-0 group-data-[vaul-drawer-direction=bottom]/drawer-content:block\" />\n {children}\n </DrawerPrimitive.Content>\n </DrawerPortal>\n )\n}\n\nfunction DrawerHeader({ className, ...props }: DrawerHeaderProps) {\n return (\n <div\n data-slot=\"drawer-header\"\n className={cn(\n 'p-4 flex flex-col gap-0.5 md:gap-0.5',\n 'group-data-[vaul-drawer-direction=bottom]/drawer-content:text-center',\n 'group-data-[vaul-drawer-direction=top]/drawer-content:text-center md:text-left',\n className\n )}\n {...props}\n />\n )\n}\n\nfunction DrawerFooter({ className, ...props }: DrawerFooterProps) {\n return <div data-slot=\"drawer-footer\" className={cn('gap-2 p-4 mt-auto flex flex-col', className)} {...props} />\n}\n\nfunction DrawerTitle({ className, ...props }: DrawerTitleProps) {\n return (\n <DrawerPrimitive.Title\n data-slot=\"drawer-title\"\n className={cn('text-foreground text-base font-medium', className)}\n {...props}\n />\n )\n}\n\nfunction DrawerDescription({ className, ...props }: DrawerDescriptionProps) {\n return (\n <DrawerPrimitive.Description\n data-slot=\"drawer-description\"\n className={cn('text-muted-foreground text-sm', className)}\n {...props}\n />\n )\n}\n\nexport {\n Drawer,\n DrawerClose,\n DrawerContent,\n DrawerDescription,\n DrawerFooter,\n DrawerHeader,\n DrawerOverlay,\n DrawerPortal,\n DrawerTitle,\n DrawerTrigger\n}\n"],"mappings":"qOAOA,MAAM,EAAwB,EAC5B,mxBACA,CACE,SAAU,CACR,KAAM,CACJ,GAAI,gWACJ,GAAI,gWACJ,GAAI,oWACL,CACF,CACD,gBAAiB,CACf,KAAM,KACP,CACF,CACF,CAIK,EAAoB,EAAM,cAAsC,CAAE,KAAM,KAAM,CAAC,CAarF,SAAS,OAAO,CAAE,OAAO,KAAM,GAAG,GAAsB,CACtD,IAAM,EAAe,EAAM,aAAuC,CAAE,OAAM,EAAG,CAAC,EAAK,CAAC,CAEpF,OACE,EAAC,EAAkB,SAAA,CAAS,MAAO,WACjC,EAACA,EAAgB,KAAA,CAAK,YAAU,SAAS,GAAI,GAAS,EAC3B,CAIjC,SAAS,cAAc,CAAE,GAAG,GAA6B,CACvD,OAAO,EAACA,EAAgB,QAAA,CAAQ,YAAU,iBAAiB,GAAI,GAAS,CAG1E,SAAS,aAAa,CAAE,GAAG,GAA4B,CACrD,OAAO,EAACA,EAAgB,OAAA,CAAO,YAAU,gBAAgB,GAAI,GAAS,CAGxE,SAAS,YAAY,CAAE,GAAG,GAA2B,CACnD,OAAO,EAACA,EAAgB,MAAA,CAAM,YAAU,eAAe,GAAI,GAAS,CAGtE,SAAS,cAAc,CAAE,YAAW,GAAG,GAA6B,CAClE,OACE,EAACA,EAAgB,QAAA,CACf,YAAU,iBACV,UAAW,EACT,iCACA,0FACA,4CACA,EACD,CACD,GAAI,GACJ,CAIN,SAAS,cAAc,CAAE,YAAW,WAAU,GAAG,GAA6B,CAC5E,GAAM,CAAE,QAAS,EAAM,WAAW,EAAkB,CAEpD,OACE,EAAC,aAAA,CAAa,YAAU,0BACtB,EAAC,cAAA,EAAA,CAAgB,CACjB,EAACA,EAAgB,QAAA,CACf,YAAU,iBACV,UAAW,EAAG,EAAsB,CAAE,OAAM,CAAC,CAAE,EAAU,CACzD,GAAI,YAEJ,EAAC,MAAA,CAAI,UAAU,6HAAA,CAA+H,CAC7I,EAAA,EACuB,CAAA,EACb,CAInB,SAAS,aAAa,CAAE,YAAW,GAAG,GAA4B,CAChE,OACE,EAAC,MAAA,CACC,YAAU,gBACV,UAAW,EACT,uCACA,uEACA,iFACA,EACD,CACD,GAAI,GACJ,CAIN,SAAS,aAAa,CAAE,YAAW,GAAG,GAA4B,CAChE,OAAO,EAAC,MAAA,CAAI,YAAU,gBAAgB,UAAW,EAAG,kCAAmC,EAAU,CAAE,GAAI,GAAS,CAGlH,SAAS,YAAY,CAAE,YAAW,GAAG,GAA2B,CAC9D,OACE,EAACA,EAAgB,MAAA,CACf,YAAU,eACV,UAAW,EAAG,wCAAyC,EAAU,CACjE,GAAI,GACJ,CAIN,SAAS,kBAAkB,CAAE,YAAW,GAAG,GAAiC,CAC1E,OACE,EAACA,EAAgB,YAAA,CACf,YAAU,qBACV,UAAW,EAAG,gCAAiC,EAAU,CACzD,GAAI,GACJ"}
|
|
@@ -1,34 +1,34 @@
|
|
|
1
1
|
import { t as __name } from "../chunk-IpJEthwI.js";
|
|
2
2
|
import * as react_jsx_runtime0 from "react/jsx-runtime";
|
|
3
|
+
import { DropdownMenu as DropdownMenu$1 } from "radix-ui";
|
|
3
4
|
import * as React from "react";
|
|
4
|
-
import { Menu } from "@base-ui/react/menu";
|
|
5
5
|
|
|
6
6
|
//#region src/components/dropdown-menu.d.ts
|
|
7
|
-
type DropdownMenuProps =
|
|
8
|
-
type DropdownMenuPortalProps =
|
|
9
|
-
type DropdownMenuTriggerProps =
|
|
10
|
-
type DropdownMenuContentProps =
|
|
11
|
-
type DropdownMenuGroupProps =
|
|
12
|
-
type DropdownMenuLabelProps =
|
|
7
|
+
type DropdownMenuProps = React.ComponentProps<typeof DropdownMenu$1.Root>;
|
|
8
|
+
type DropdownMenuPortalProps = React.ComponentProps<typeof DropdownMenu$1.Portal>;
|
|
9
|
+
type DropdownMenuTriggerProps = React.ComponentProps<typeof DropdownMenu$1.Trigger>;
|
|
10
|
+
type DropdownMenuContentProps = React.ComponentProps<typeof DropdownMenu$1.Content>;
|
|
11
|
+
type DropdownMenuGroupProps = React.ComponentProps<typeof DropdownMenu$1.Group>;
|
|
12
|
+
type DropdownMenuLabelProps = React.ComponentProps<typeof DropdownMenu$1.Label> & {
|
|
13
13
|
inset?: boolean;
|
|
14
14
|
};
|
|
15
|
-
type DropdownMenuItemProps =
|
|
15
|
+
type DropdownMenuItemProps = React.ComponentProps<typeof DropdownMenu$1.Item> & {
|
|
16
16
|
inset?: boolean;
|
|
17
17
|
variant?: 'default' | 'destructive';
|
|
18
18
|
};
|
|
19
|
-
type DropdownMenuSubProps =
|
|
20
|
-
type DropdownMenuSubTriggerProps =
|
|
19
|
+
type DropdownMenuSubProps = React.ComponentProps<typeof DropdownMenu$1.Sub>;
|
|
20
|
+
type DropdownMenuSubTriggerProps = React.ComponentProps<typeof DropdownMenu$1.SubTrigger> & {
|
|
21
21
|
inset?: boolean;
|
|
22
22
|
};
|
|
23
|
-
type DropdownMenuSubContentProps =
|
|
24
|
-
type DropdownMenuCheckboxItemProps =
|
|
23
|
+
type DropdownMenuSubContentProps = React.ComponentProps<typeof DropdownMenu$1.SubContent>;
|
|
24
|
+
type DropdownMenuCheckboxItemProps = React.ComponentProps<typeof DropdownMenu$1.CheckboxItem> & {
|
|
25
25
|
inset?: boolean;
|
|
26
26
|
};
|
|
27
|
-
type DropdownMenuRadioGroupProps =
|
|
28
|
-
type DropdownMenuRadioItemProps =
|
|
27
|
+
type DropdownMenuRadioGroupProps = React.ComponentProps<typeof DropdownMenu$1.RadioGroup>;
|
|
28
|
+
type DropdownMenuRadioItemProps = React.ComponentProps<typeof DropdownMenu$1.RadioItem> & {
|
|
29
29
|
inset?: boolean;
|
|
30
30
|
};
|
|
31
|
-
type DropdownMenuSeparatorProps =
|
|
31
|
+
type DropdownMenuSeparatorProps = React.ComponentProps<typeof DropdownMenu$1.Separator>;
|
|
32
32
|
type DropdownMenuShortcutProps = React.ComponentProps<'span'>;
|
|
33
33
|
declare function DropdownMenu({
|
|
34
34
|
...props
|
|
@@ -40,47 +40,24 @@ declare function DropdownMenuTrigger({
|
|
|
40
40
|
...props
|
|
41
41
|
}: DropdownMenuTriggerProps): react_jsx_runtime0.JSX.Element;
|
|
42
42
|
declare function DropdownMenuContent({
|
|
43
|
+
className,
|
|
43
44
|
align,
|
|
44
|
-
alignOffset,
|
|
45
|
-
side,
|
|
46
45
|
sideOffset,
|
|
47
|
-
className,
|
|
48
46
|
...props
|
|
49
47
|
}: DropdownMenuContentProps): react_jsx_runtime0.JSX.Element;
|
|
50
48
|
declare function DropdownMenuGroup({
|
|
51
49
|
...props
|
|
52
50
|
}: DropdownMenuGroupProps): react_jsx_runtime0.JSX.Element;
|
|
53
|
-
declare function DropdownMenuLabel({
|
|
54
|
-
className,
|
|
55
|
-
inset,
|
|
56
|
-
...props
|
|
57
|
-
}: DropdownMenuLabelProps): react_jsx_runtime0.JSX.Element;
|
|
58
51
|
declare function DropdownMenuItem({
|
|
59
52
|
className,
|
|
60
53
|
inset,
|
|
61
54
|
variant,
|
|
62
55
|
...props
|
|
63
56
|
}: DropdownMenuItemProps): react_jsx_runtime0.JSX.Element;
|
|
64
|
-
declare function DropdownMenuSub({
|
|
65
|
-
...props
|
|
66
|
-
}: DropdownMenuSubProps): react_jsx_runtime0.JSX.Element;
|
|
67
|
-
declare function DropdownMenuSubTrigger({
|
|
68
|
-
className,
|
|
69
|
-
inset,
|
|
70
|
-
children,
|
|
71
|
-
...props
|
|
72
|
-
}: DropdownMenuSubTriggerProps): react_jsx_runtime0.JSX.Element;
|
|
73
|
-
declare function DropdownMenuSubContent({
|
|
74
|
-
align,
|
|
75
|
-
alignOffset,
|
|
76
|
-
side,
|
|
77
|
-
sideOffset,
|
|
78
|
-
className,
|
|
79
|
-
...props
|
|
80
|
-
}: DropdownMenuSubContentProps): react_jsx_runtime0.JSX.Element;
|
|
81
57
|
declare function DropdownMenuCheckboxItem({
|
|
82
58
|
className,
|
|
83
59
|
children,
|
|
60
|
+
checked,
|
|
84
61
|
inset,
|
|
85
62
|
...props
|
|
86
63
|
}: DropdownMenuCheckboxItemProps): react_jsx_runtime0.JSX.Element;
|
|
@@ -93,6 +70,11 @@ declare function DropdownMenuRadioItem({
|
|
|
93
70
|
inset,
|
|
94
71
|
...props
|
|
95
72
|
}: DropdownMenuRadioItemProps): react_jsx_runtime0.JSX.Element;
|
|
73
|
+
declare function DropdownMenuLabel({
|
|
74
|
+
className,
|
|
75
|
+
inset,
|
|
76
|
+
...props
|
|
77
|
+
}: DropdownMenuLabelProps): react_jsx_runtime0.JSX.Element;
|
|
96
78
|
declare function DropdownMenuSeparator({
|
|
97
79
|
className,
|
|
98
80
|
...props
|
|
@@ -101,6 +83,19 @@ declare function DropdownMenuShortcut({
|
|
|
101
83
|
className,
|
|
102
84
|
...props
|
|
103
85
|
}: DropdownMenuShortcutProps): react_jsx_runtime0.JSX.Element;
|
|
86
|
+
declare function DropdownMenuSub({
|
|
87
|
+
...props
|
|
88
|
+
}: DropdownMenuSubProps): react_jsx_runtime0.JSX.Element;
|
|
89
|
+
declare function DropdownMenuSubTrigger({
|
|
90
|
+
className,
|
|
91
|
+
inset,
|
|
92
|
+
children,
|
|
93
|
+
...props
|
|
94
|
+
}: DropdownMenuSubTriggerProps): react_jsx_runtime0.JSX.Element;
|
|
95
|
+
declare function DropdownMenuSubContent({
|
|
96
|
+
className,
|
|
97
|
+
...props
|
|
98
|
+
}: DropdownMenuSubContentProps): react_jsx_runtime0.JSX.Element;
|
|
104
99
|
//#endregion
|
|
105
100
|
export { DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuCheckboxItemProps, DropdownMenuContent, DropdownMenuContentProps, DropdownMenuGroup, DropdownMenuGroupProps, DropdownMenuItem, DropdownMenuItemProps, DropdownMenuLabel, DropdownMenuLabelProps, DropdownMenuPortal, DropdownMenuPortalProps, DropdownMenuProps, DropdownMenuRadioGroup, DropdownMenuRadioGroupProps, DropdownMenuRadioItem, DropdownMenuRadioItemProps, DropdownMenuSeparator, DropdownMenuSeparatorProps, DropdownMenuShortcut, DropdownMenuShortcutProps, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubContentProps, DropdownMenuSubProps, DropdownMenuSubTrigger, DropdownMenuSubTriggerProps, DropdownMenuTrigger, DropdownMenuTriggerProps };
|
|
106
101
|
//# sourceMappingURL=dropdown-menu.d.ts.map
|