@codefast/ui 0.0.14 → 0.0.16

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/alert.js CHANGED
@@ -7,7 +7,7 @@ var _chunkG3NP7M2Njs = require('./chunk-G3NP7M2N.js');
7
7
  var _react = require('react'); var React = _interopRequireWildcard(_react);
8
8
  var _jsxruntime = require('react/jsx-runtime');
9
9
  var alertVariants = _chunkG3NP7M2Njs.cva.call(void 0, {
10
- base: "relative w-full rounded-lg border p-4 text-sm [&>svg+div]:-translate-y-[3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg~*]:pl-7",
10
+ base: "[&>svg+div]:-translate-y-0.75 relative w-full rounded-lg border p-4 text-sm [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg~*]:pl-7",
11
11
  variants: {
12
12
  variant: {
13
13
  default: "bg-background text-foreground [&>svg]:text-foreground",
package/dist/alert.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/alert.tsx"],"names":[],"mappings":";;;;;;AAAA,YAAY,WAAW;AA+BrB;AAvBF,IAAM,gBAAgB,IAAI;AAAA,EACxB,MAAM;AAAA,EACN,UAAU;AAAA,IACR,SAAS;AAAA,MACP,SAAS;AAAA,MACT,aAAa;AAAA,IACf;AAAA,EACF;AAAA,EACA,iBAAiB;AAAA,IACf,SAAS;AAAA,EACX;AACF,CAAC;AAWD,IAAM,QAAc,iBAAqC,CAAC,EAAE,WAAW,SAAS,GAAG,MAAM,GAAG,QAC1F,oBAAC,SAAI,KAAU,MAAK,SAAQ,WAAW,cAAc,EAAE,SAAS,UAAU,CAAC,GAAI,GAAG,OAAO,CAC1F;AAED,MAAM,cAAc;AASpB,IAAM,aAAmB,iBAA+C,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAC1G,oBAAC,QAAG,KAAU,WAAW,GAAG,gDAAgD,SAAS,GAAI,GAAG,OACzF,UACH,CACD;AAED,WAAW,cAAc;AASzB,IAAM,mBAAyB;AAAA,EAC7B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB,oBAAC,SAAI,KAAU,WAAW,GAAG,iCAAiC,SAAS,GAAI,GAAG,OAAO;AAEzF;AAEA,iBAAiB,cAAc","sourcesContent":["import * as React from \"react\";\nimport { type VariantProps } from \"cva\";\nimport { cn, cva } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Variant: Alert\n * -------------------------------------------------------------------------- */\n\nconst alertVariants = cva({\n base: \"relative w-full rounded-lg border p-4 text-sm [&>svg+div]:-translate-y-[3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg~*]:pl-7\",\n variants: {\n variant: {\n default: \"bg-background text-foreground [&>svg]:text-foreground\",\n destructive: \"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n },\n});\n\ntype AlertVariantsProps = VariantProps<typeof alertVariants>;\n\n/* -----------------------------------------------------------------------------\n * Component: Alert\n * -------------------------------------------------------------------------- */\n\ntype AlertElement = HTMLDivElement;\ntype AlertProps = React.HTMLAttributes<HTMLDivElement> & AlertVariantsProps;\n\nconst Alert = React.forwardRef<AlertElement, AlertProps>(({ className, variant, ...props }, ref) => (\n <div ref={ref} role=\"alert\" className={alertVariants({ variant, className })} {...props} />\n));\n\nAlert.displayName = \"Alert\";\n\n/* -----------------------------------------------------------------------------\n * Component: AlertTitle\n * -------------------------------------------------------------------------- */\n\ntype AlertTitleElement = HTMLHeadingElement;\ntype AlertTitleProps = React.HTMLAttributes<HTMLHeadingElement>;\n\nconst AlertTitle = React.forwardRef<AlertTitleElement, AlertTitleProps>(({ className, children, ...props }, ref) => (\n <h5 ref={ref} className={cn(\"mb-1 font-medium leading-none tracking-tight\", className)} {...props}>\n {children}\n </h5>\n));\n\nAlertTitle.displayName = \"AlertTitle\";\n\n/* -----------------------------------------------------------------------------\n * Component: AlertDescription\n * -------------------------------------------------------------------------- */\n\ntype AlertDescriptionElement = HTMLDivElement;\ntype AlertDescriptionProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst AlertDescription = React.forwardRef<AlertDescriptionElement, AlertDescriptionProps>(\n ({ className, ...props }, ref) => (\n <div ref={ref} className={cn(\"text-sm [&_p]:leading-relaxed\", className)} {...props} />\n ),\n);\n\nAlertDescription.displayName = \"AlertDescription\";\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Alert, AlertTitle, AlertDescription, type AlertProps, type AlertTitleProps, type AlertDescriptionProps };\n"]}
1
+ {"version":3,"sources":["../src/alert.tsx"],"names":[],"mappings":";;;;;;AAAA,YAAY,WAAW;AA+BrB;AAvBF,IAAM,gBAAgB,IAAI;AAAA,EACxB,MAAM;AAAA,EACN,UAAU;AAAA,IACR,SAAS;AAAA,MACP,SAAS;AAAA,MACT,aAAa;AAAA,IACf;AAAA,EACF;AAAA,EACA,iBAAiB;AAAA,IACf,SAAS;AAAA,EACX;AACF,CAAC;AAWD,IAAM,QAAc,iBAAqC,CAAC,EAAE,WAAW,SAAS,GAAG,MAAM,GAAG,QAC1F,oBAAC,SAAI,KAAU,MAAK,SAAQ,WAAW,cAAc,EAAE,SAAS,UAAU,CAAC,GAAI,GAAG,OAAO,CAC1F;AAED,MAAM,cAAc;AASpB,IAAM,aAAmB,iBAA+C,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAC1G,oBAAC,QAAG,KAAU,WAAW,GAAG,gDAAgD,SAAS,GAAI,GAAG,OACzF,UACH,CACD;AAED,WAAW,cAAc;AASzB,IAAM,mBAAyB;AAAA,EAC7B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB,oBAAC,SAAI,KAAU,WAAW,GAAG,iCAAiC,SAAS,GAAI,GAAG,OAAO;AAEzF;AAEA,iBAAiB,cAAc","sourcesContent":["import * as React from \"react\";\nimport { type VariantProps } from \"cva\";\nimport { cn, cva } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Variant: Alert\n * -------------------------------------------------------------------------- */\n\nconst alertVariants = cva({\n base: \"[&>svg+div]:-translate-y-0.75 relative w-full rounded-lg border p-4 text-sm [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg~*]:pl-7\",\n variants: {\n variant: {\n default: \"bg-background text-foreground [&>svg]:text-foreground\",\n destructive: \"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n },\n});\n\ntype AlertVariantsProps = VariantProps<typeof alertVariants>;\n\n/* -----------------------------------------------------------------------------\n * Component: Alert\n * -------------------------------------------------------------------------- */\n\ntype AlertElement = HTMLDivElement;\ntype AlertProps = React.HTMLAttributes<HTMLDivElement> & AlertVariantsProps;\n\nconst Alert = React.forwardRef<AlertElement, AlertProps>(({ className, variant, ...props }, ref) => (\n <div ref={ref} role=\"alert\" className={alertVariants({ variant, className })} {...props} />\n));\n\nAlert.displayName = \"Alert\";\n\n/* -----------------------------------------------------------------------------\n * Component: AlertTitle\n * -------------------------------------------------------------------------- */\n\ntype AlertTitleElement = HTMLHeadingElement;\ntype AlertTitleProps = React.HTMLAttributes<HTMLHeadingElement>;\n\nconst AlertTitle = React.forwardRef<AlertTitleElement, AlertTitleProps>(({ className, children, ...props }, ref) => (\n <h5 ref={ref} className={cn(\"mb-1 font-medium leading-none tracking-tight\", className)} {...props}>\n {children}\n </h5>\n));\n\nAlertTitle.displayName = \"AlertTitle\";\n\n/* -----------------------------------------------------------------------------\n * Component: AlertDescription\n * -------------------------------------------------------------------------- */\n\ntype AlertDescriptionElement = HTMLDivElement;\ntype AlertDescriptionProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst AlertDescription = React.forwardRef<AlertDescriptionElement, AlertDescriptionProps>(\n ({ className, ...props }, ref) => (\n <div ref={ref} className={cn(\"text-sm [&_p]:leading-relaxed\", className)} {...props} />\n ),\n);\n\nAlertDescription.displayName = \"AlertDescription\";\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Alert, AlertTitle, AlertDescription, type AlertProps, type AlertTitleProps, type AlertDescriptionProps };\n"]}
package/dist/alert.mjs CHANGED
@@ -7,7 +7,7 @@ import {
7
7
  import * as React from "react";
8
8
  import { jsx } from "react/jsx-runtime";
9
9
  var alertVariants = cva({
10
- base: "relative w-full rounded-lg border p-4 text-sm [&>svg+div]:-translate-y-[3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg~*]:pl-7",
10
+ base: "[&>svg+div]:-translate-y-0.75 relative w-full rounded-lg border p-4 text-sm [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg~*]:pl-7",
11
11
  variants: {
12
12
  variant: {
13
13
  default: "bg-background text-foreground [&>svg]:text-foreground",
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/alert.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { type VariantProps } from \"cva\";\nimport { cn, cva } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Variant: Alert\n * -------------------------------------------------------------------------- */\n\nconst alertVariants = cva({\n base: \"relative w-full rounded-lg border p-4 text-sm [&>svg+div]:-translate-y-[3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg~*]:pl-7\",\n variants: {\n variant: {\n default: \"bg-background text-foreground [&>svg]:text-foreground\",\n destructive: \"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n },\n});\n\ntype AlertVariantsProps = VariantProps<typeof alertVariants>;\n\n/* -----------------------------------------------------------------------------\n * Component: Alert\n * -------------------------------------------------------------------------- */\n\ntype AlertElement = HTMLDivElement;\ntype AlertProps = React.HTMLAttributes<HTMLDivElement> & AlertVariantsProps;\n\nconst Alert = React.forwardRef<AlertElement, AlertProps>(({ className, variant, ...props }, ref) => (\n <div ref={ref} role=\"alert\" className={alertVariants({ variant, className })} {...props} />\n));\n\nAlert.displayName = \"Alert\";\n\n/* -----------------------------------------------------------------------------\n * Component: AlertTitle\n * -------------------------------------------------------------------------- */\n\ntype AlertTitleElement = HTMLHeadingElement;\ntype AlertTitleProps = React.HTMLAttributes<HTMLHeadingElement>;\n\nconst AlertTitle = React.forwardRef<AlertTitleElement, AlertTitleProps>(({ className, children, ...props }, ref) => (\n <h5 ref={ref} className={cn(\"mb-1 font-medium leading-none tracking-tight\", className)} {...props}>\n {children}\n </h5>\n));\n\nAlertTitle.displayName = \"AlertTitle\";\n\n/* -----------------------------------------------------------------------------\n * Component: AlertDescription\n * -------------------------------------------------------------------------- */\n\ntype AlertDescriptionElement = HTMLDivElement;\ntype AlertDescriptionProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst AlertDescription = React.forwardRef<AlertDescriptionElement, AlertDescriptionProps>(\n ({ className, ...props }, ref) => (\n <div ref={ref} className={cn(\"text-sm [&_p]:leading-relaxed\", className)} {...props} />\n ),\n);\n\nAlertDescription.displayName = \"AlertDescription\";\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Alert, AlertTitle, AlertDescription, type AlertProps, type AlertTitleProps, type AlertDescriptionProps };\n"],"mappings":";;;;;;AAAA,YAAY,WAAW;AA+BrB;AAvBF,IAAM,gBAAgB,IAAI;AAAA,EACxB,MAAM;AAAA,EACN,UAAU;AAAA,IACR,SAAS;AAAA,MACP,SAAS;AAAA,MACT,aAAa;AAAA,IACf;AAAA,EACF;AAAA,EACA,iBAAiB;AAAA,IACf,SAAS;AAAA,EACX;AACF,CAAC;AAWD,IAAM,QAAc,iBAAqC,CAAC,EAAE,WAAW,SAAS,GAAG,MAAM,GAAG,QAC1F,oBAAC,SAAI,KAAU,MAAK,SAAQ,WAAW,cAAc,EAAE,SAAS,UAAU,CAAC,GAAI,GAAG,OAAO,CAC1F;AAED,MAAM,cAAc;AASpB,IAAM,aAAmB,iBAA+C,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAC1G,oBAAC,QAAG,KAAU,WAAW,GAAG,gDAAgD,SAAS,GAAI,GAAG,OACzF,UACH,CACD;AAED,WAAW,cAAc;AASzB,IAAM,mBAAyB;AAAA,EAC7B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB,oBAAC,SAAI,KAAU,WAAW,GAAG,iCAAiC,SAAS,GAAI,GAAG,OAAO;AAEzF;AAEA,iBAAiB,cAAc;","names":[]}
1
+ {"version":3,"sources":["../src/alert.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { type VariantProps } from \"cva\";\nimport { cn, cva } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Variant: Alert\n * -------------------------------------------------------------------------- */\n\nconst alertVariants = cva({\n base: \"[&>svg+div]:-translate-y-0.75 relative w-full rounded-lg border p-4 text-sm [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg~*]:pl-7\",\n variants: {\n variant: {\n default: \"bg-background text-foreground [&>svg]:text-foreground\",\n destructive: \"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n },\n});\n\ntype AlertVariantsProps = VariantProps<typeof alertVariants>;\n\n/* -----------------------------------------------------------------------------\n * Component: Alert\n * -------------------------------------------------------------------------- */\n\ntype AlertElement = HTMLDivElement;\ntype AlertProps = React.HTMLAttributes<HTMLDivElement> & AlertVariantsProps;\n\nconst Alert = React.forwardRef<AlertElement, AlertProps>(({ className, variant, ...props }, ref) => (\n <div ref={ref} role=\"alert\" className={alertVariants({ variant, className })} {...props} />\n));\n\nAlert.displayName = \"Alert\";\n\n/* -----------------------------------------------------------------------------\n * Component: AlertTitle\n * -------------------------------------------------------------------------- */\n\ntype AlertTitleElement = HTMLHeadingElement;\ntype AlertTitleProps = React.HTMLAttributes<HTMLHeadingElement>;\n\nconst AlertTitle = React.forwardRef<AlertTitleElement, AlertTitleProps>(({ className, children, ...props }, ref) => (\n <h5 ref={ref} className={cn(\"mb-1 font-medium leading-none tracking-tight\", className)} {...props}>\n {children}\n </h5>\n));\n\nAlertTitle.displayName = \"AlertTitle\";\n\n/* -----------------------------------------------------------------------------\n * Component: AlertDescription\n * -------------------------------------------------------------------------- */\n\ntype AlertDescriptionElement = HTMLDivElement;\ntype AlertDescriptionProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst AlertDescription = React.forwardRef<AlertDescriptionElement, AlertDescriptionProps>(\n ({ className, ...props }, ref) => (\n <div ref={ref} className={cn(\"text-sm [&_p]:leading-relaxed\", className)} {...props} />\n ),\n);\n\nAlertDescription.displayName = \"AlertDescription\";\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Alert, AlertTitle, AlertDescription, type AlertProps, type AlertTitleProps, type AlertDescriptionProps };\n"],"mappings":";;;;;;AAAA,YAAY,WAAW;AA+BrB;AAvBF,IAAM,gBAAgB,IAAI;AAAA,EACxB,MAAM;AAAA,EACN,UAAU;AAAA,IACR,SAAS;AAAA,MACP,SAAS;AAAA,MACT,aAAa;AAAA,IACf;AAAA,EACF;AAAA,EACA,iBAAiB;AAAA,IACf,SAAS;AAAA,EACX;AACF,CAAC;AAWD,IAAM,QAAc,iBAAqC,CAAC,EAAE,WAAW,SAAS,GAAG,MAAM,GAAG,QAC1F,oBAAC,SAAI,KAAU,MAAK,SAAQ,WAAW,cAAc,EAAE,SAAS,UAAU,CAAC,GAAI,GAAG,OAAO,CAC1F;AAED,MAAM,cAAc;AASpB,IAAM,aAAmB,iBAA+C,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAC1G,oBAAC,QAAG,KAAU,WAAW,GAAG,gDAAgD,SAAS,GAAI,GAAG,OACzF,UACH,CACD;AAED,WAAW,cAAc;AASzB,IAAM,mBAAyB;AAAA,EAC7B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB,oBAAC,SAAI,KAAU,WAAW,GAAG,iCAAiC,SAAS,GAAI,GAAG,OAAO;AAEzF;AAEA,iBAAiB,cAAc;","names":[]}
@@ -16,7 +16,7 @@ var SelectTrigger = React.forwardRef(
16
16
  {
17
17
  ref,
18
18
  className: _chunkG3NP7M2Njs.cn.call(void 0,
19
- "border-input placeholder:text-muted-foreground focus-visible:ring-ring flex h-10 w-full items-center justify-between whitespace-nowrap rounded-md border bg-transparent px-3 text-sm shadow-sm focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",
19
+ "border-input placeholder:text-muted-foreground focus-visible:ring-ring flex h-10 w-full items-center justify-between gap-2 whitespace-nowrap rounded-md border bg-transparent px-3 text-sm shadow-sm focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1 [&>span]:truncate",
20
20
  className
21
21
  ),
22
22
  ...props,
@@ -117,4 +117,4 @@ SelectSeparator.displayName = SelectPrimitive.Separator.displayName;
117
117
 
118
118
 
119
119
  exports.Select = Select; exports.SelectGroup = SelectGroup; exports.SelectValue = SelectValue; exports.SelectTrigger = SelectTrigger; exports.SelectScrollUpButton = SelectScrollUpButton; exports.SelectScrollDownButton = SelectScrollDownButton; exports.SelectContent = SelectContent; exports.SelectLabel = SelectLabel; exports.SelectItem = SelectItem; exports.SelectSeparator = SelectSeparator;
120
- //# sourceMappingURL=chunk-OSFYUOPN.js.map
120
+ //# sourceMappingURL=chunk-BA3XYBWR.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/select.tsx"],"names":[],"mappings":";;;;;AAEA,YAAY,WAAW;AACvB,SAAS,eAAe,WAAW,iBAAiB,qBAAqB;AACzE,YAAY,qBAAqB;AAiC7B,SAUI,KAVJ;AAzBJ,IAAM,SAAyB;AAO/B,IAAM,cAA8B;AAOpC,IAAM,cAA8B;AASpC,IAAM,gBAAsB;AAAA,EAC1B,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAClC;A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GACF;AAEJ;AAEA,cAAc,cAA8B,wBAAQ;AASpD,IAAM,cAAoB,iBAAiD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACnG,oBAAiB,uBAAhB,EAAsB,KAAU,WAAW,GAAG,qCAAqC,SAAS,GAAI,GAAG,OAAO,CAC5G;AAED,YAAY,cAA8B,sBAAM;AAShD,IAAM,aAAmB,iBAA+C,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAC1G;AAAA,EAAiB;AAAA,EAAhB;AAAA,IACC;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA,IAEJ;AAAA,0BAAC,UAAK,WAAU,8DACd,8BAAiB,+BAAhB,EACC,8BAAC,aAAU,WAAU,UAAS,GAChC,GACF;AAAA,MACA,oBAAiB,0BAAhB,EAA0B,UAAS;AAAA;AAAA;AACtC,CACD;AAED,WAAW,cAA8B,qBAAK;AAS9C,IAAM,kBAAwB;AAAA,EAC5B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB,oBAAiB,2BAAhB,EAA0B,KAAU,WAAW,GAAG,4BAA4B,SAAS,GAAI,GAAG,OAAO;AAE1G;AAEA,gBAAgB,cAA8B,0BAAU","sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { CaretSortIcon, CheckIcon, ChevronDownIcon, ChevronUpIcon } from \"@radix-ui/react-icons\";\nimport * as SelectPrimitive from \"@radix-ui/react-select\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: Select\n * -------------------------------------------------------------------------- */\n\ntype SelectProps = React.ComponentProps<typeof SelectPrimitive.Root>;\nconst Select = SelectPrimitive.Root;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectGroup\n * -------------------------------------------------------------------------- */\n\ntype SelectGroupProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Group>;\nconst SelectGroup = SelectPrimitive.Group;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectValue\n * -------------------------------------------------------------------------- */\n\ntype SelectValueProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Value>;\nconst SelectValue = SelectPrimitive.Value;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectTrigger\n * -------------------------------------------------------------------------- */\n\ntype SelectTriggerElement = React.ElementRef<typeof SelectPrimitive.Trigger>;\ntype SelectTriggerProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Trigger>;\n\nconst SelectTrigger = React.forwardRef<SelectTriggerElement, SelectTriggerProps>(\n ({ className, children, ...props }, ref) => (\n <SelectPrimitive.Trigger\n ref={ref}\n className={cn(\n \"border-input placeholder:text-muted-foreground focus-visible:ring-ring flex h-10 w-full items-center justify-between gap-2 whitespace-nowrap rounded-md border bg-transparent px-3 text-sm shadow-sm focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1 [&>span]:truncate\",\n className,\n )}\n {...props}\n >\n {children}\n <SelectPrimitive.Icon asChild>\n <CaretSortIcon className=\"size-4 opacity-50\" />\n </SelectPrimitive.Icon>\n </SelectPrimitive.Trigger>\n ),\n);\n\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectScrollUpButton\n * -------------------------------------------------------------------------- */\n\ntype SelectScrollUpButtonElement = React.ElementRef<typeof SelectPrimitive.ScrollUpButton>;\ntype SelectScrollUpButtonProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.ScrollUpButton>;\n\nconst SelectScrollUpButton = React.forwardRef<SelectScrollUpButtonElement, SelectScrollUpButtonProps>(\n ({ className, ...props }, ref) => (\n <SelectPrimitive.ScrollUpButton\n ref={ref}\n className={cn(\"flex cursor-default items-center justify-center py-1\", className)}\n {...props}\n >\n <ChevronUpIcon />\n </SelectPrimitive.ScrollUpButton>\n ),\n);\n\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectScrollDownButton\n * -------------------------------------------------------------------------- */\n\ntype SelectScrollDownButtonElement = React.ElementRef<typeof SelectPrimitive.ScrollDownButton>;\ntype SelectScrollDownButtonProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.ScrollDownButton>;\n\nconst SelectScrollDownButton = React.forwardRef<SelectScrollDownButtonElement, SelectScrollDownButtonProps>(\n ({ className, ...props }, ref) => (\n <SelectPrimitive.ScrollDownButton\n ref={ref}\n className={cn(\"flex cursor-default items-center justify-center py-1\", className)}\n {...props}\n >\n <ChevronDownIcon />\n </SelectPrimitive.ScrollDownButton>\n ),\n);\n\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectContent\n * -------------------------------------------------------------------------- */\n\ntype SelectContentElement = React.ElementRef<typeof SelectPrimitive.Content>;\ntype SelectContentProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Content>;\n\nconst SelectContent = React.forwardRef<SelectContentElement, SelectContentProps>(\n ({ className, children, position = \"popper\", ...props }, ref) => (\n <SelectPrimitive.Portal>\n <SelectPrimitive.Content\n ref={ref}\n className={cn(\n \"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=open]:data-[side=bottom]:slide-in-from-top-2 data-[state=open]:data-[side=left]:slide-in-from-right-2 data-[state=open]:data-[side=right]:slide-in-from-left-2 data-[state=open]:data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:data-[side=bottom]:slide-out-to-top-2 data-[state=closed]:data-[side=left]:slide-out-to-right-2 data-[state=closed]:data-[side=right]:slide-out-to-left-2 data-[state=closed]:data-[side=top]:slide-out-to-bottom-2 relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border shadow-md\",\n position === \"popper\" &&\n \"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1\",\n className,\n )}\n position={position}\n {...props}\n >\n <SelectScrollUpButton />\n <SelectPrimitive.Viewport\n className={cn(\n \"p-1\",\n position === \"popper\" &&\n \"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]\",\n )}\n >\n {children}\n </SelectPrimitive.Viewport>\n <SelectScrollDownButton />\n </SelectPrimitive.Content>\n </SelectPrimitive.Portal>\n ),\n);\n\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectLabel\n * -------------------------------------------------------------------------- */\n\ntype SelectLabelElement = React.ElementRef<typeof SelectPrimitive.Label>;\ntype SelectLabelProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Label>;\n\nconst SelectLabel = React.forwardRef<SelectLabelElement, SelectLabelProps>(({ className, ...props }, ref) => (\n <SelectPrimitive.Label ref={ref} className={cn(\"px-2 py-1.5 text-sm font-semibold\", className)} {...props} />\n));\n\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectItem\n * -------------------------------------------------------------------------- */\n\ntype SelectItemElement = React.ElementRef<typeof SelectPrimitive.Item>;\ntype SelectItemProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Item>;\n\nconst SelectItem = React.forwardRef<SelectItemElement, SelectItemProps>(({ className, children, ...props }, ref) => (\n <SelectPrimitive.Item\n ref={ref}\n className={cn(\n \"focus:bg-accent focus:text-accent-foreground relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-2 pr-8 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50\",\n className,\n )}\n {...props}\n >\n <span className=\"absolute right-2 flex size-3.5 items-center justify-center\">\n <SelectPrimitive.ItemIndicator>\n <CheckIcon className=\"size-4\" />\n </SelectPrimitive.ItemIndicator>\n </span>\n <SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>\n </SelectPrimitive.Item>\n));\n\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectSeparator\n * -------------------------------------------------------------------------- */\n\ntype SelectSeparatorElement = React.ElementRef<typeof SelectPrimitive.Separator>;\ntype SelectSeparatorProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Separator>;\n\nconst SelectSeparator = React.forwardRef<SelectSeparatorElement, SelectSeparatorProps>(\n ({ className, ...props }, ref) => (\n <SelectPrimitive.Separator ref={ref} className={cn(\"bg-muted -mx-1 my-1 h-px\", className)} {...props} />\n ),\n);\n\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n type SelectProps,\n type SelectGroupProps,\n type SelectValueProps,\n type SelectTriggerProps,\n type SelectContentProps,\n type SelectLabelProps,\n type SelectItemProps,\n type SelectSeparatorProps,\n type SelectScrollUpButtonProps,\n type SelectScrollDownButtonProps,\n};\n"]}
@@ -16,7 +16,7 @@ var SelectTrigger = React.forwardRef(
16
16
  {
17
17
  ref,
18
18
  className: cn(
19
- "border-input placeholder:text-muted-foreground focus-visible:ring-ring flex h-10 w-full items-center justify-between whitespace-nowrap rounded-md border bg-transparent px-3 text-sm shadow-sm focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",
19
+ "border-input placeholder:text-muted-foreground focus-visible:ring-ring flex h-10 w-full items-center justify-between gap-2 whitespace-nowrap rounded-md border bg-transparent px-3 text-sm shadow-sm focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1 [&>span]:truncate",
20
20
  className
21
21
  ),
22
22
  ...props,
@@ -117,4 +117,4 @@ export {
117
117
  SelectItem,
118
118
  SelectSeparator
119
119
  };
120
- //# sourceMappingURL=chunk-BBQXHKST.mjs.map
120
+ //# sourceMappingURL=chunk-Q24YJU6W.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/select.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { CaretSortIcon, CheckIcon, ChevronDownIcon, ChevronUpIcon } from \"@radix-ui/react-icons\";\nimport * as SelectPrimitive from \"@radix-ui/react-select\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: Select\n * -------------------------------------------------------------------------- */\n\ntype SelectProps = React.ComponentProps<typeof SelectPrimitive.Root>;\nconst Select = SelectPrimitive.Root;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectGroup\n * -------------------------------------------------------------------------- */\n\ntype SelectGroupProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Group>;\nconst SelectGroup = SelectPrimitive.Group;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectValue\n * -------------------------------------------------------------------------- */\n\ntype SelectValueProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Value>;\nconst SelectValue = SelectPrimitive.Value;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectTrigger\n * -------------------------------------------------------------------------- */\n\ntype SelectTriggerElement = React.ElementRef<typeof SelectPrimitive.Trigger>;\ntype SelectTriggerProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Trigger>;\n\nconst SelectTrigger = React.forwardRef<SelectTriggerElement, SelectTriggerProps>(\n ({ className, children, ...props }, ref) => (\n <SelectPrimitive.Trigger\n ref={ref}\n className={cn(\n \"border-input placeholder:text-muted-foreground focus-visible:ring-ring flex h-10 w-full items-center justify-between gap-2 whitespace-nowrap rounded-md border bg-transparent px-3 text-sm shadow-sm focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1 [&>span]:truncate\",\n className,\n )}\n {...props}\n >\n {children}\n <SelectPrimitive.Icon asChild>\n <CaretSortIcon className=\"size-4 opacity-50\" />\n </SelectPrimitive.Icon>\n </SelectPrimitive.Trigger>\n ),\n);\n\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectScrollUpButton\n * -------------------------------------------------------------------------- */\n\ntype SelectScrollUpButtonElement = React.ElementRef<typeof SelectPrimitive.ScrollUpButton>;\ntype SelectScrollUpButtonProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.ScrollUpButton>;\n\nconst SelectScrollUpButton = React.forwardRef<SelectScrollUpButtonElement, SelectScrollUpButtonProps>(\n ({ className, ...props }, ref) => (\n <SelectPrimitive.ScrollUpButton\n ref={ref}\n className={cn(\"flex cursor-default items-center justify-center py-1\", className)}\n {...props}\n >\n <ChevronUpIcon />\n </SelectPrimitive.ScrollUpButton>\n ),\n);\n\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectScrollDownButton\n * -------------------------------------------------------------------------- */\n\ntype SelectScrollDownButtonElement = React.ElementRef<typeof SelectPrimitive.ScrollDownButton>;\ntype SelectScrollDownButtonProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.ScrollDownButton>;\n\nconst SelectScrollDownButton = React.forwardRef<SelectScrollDownButtonElement, SelectScrollDownButtonProps>(\n ({ className, ...props }, ref) => (\n <SelectPrimitive.ScrollDownButton\n ref={ref}\n className={cn(\"flex cursor-default items-center justify-center py-1\", className)}\n {...props}\n >\n <ChevronDownIcon />\n </SelectPrimitive.ScrollDownButton>\n ),\n);\n\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectContent\n * -------------------------------------------------------------------------- */\n\ntype SelectContentElement = React.ElementRef<typeof SelectPrimitive.Content>;\ntype SelectContentProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Content>;\n\nconst SelectContent = React.forwardRef<SelectContentElement, SelectContentProps>(\n ({ className, children, position = \"popper\", ...props }, ref) => (\n <SelectPrimitive.Portal>\n <SelectPrimitive.Content\n ref={ref}\n className={cn(\n \"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=open]:data-[side=bottom]:slide-in-from-top-2 data-[state=open]:data-[side=left]:slide-in-from-right-2 data-[state=open]:data-[side=right]:slide-in-from-left-2 data-[state=open]:data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:data-[side=bottom]:slide-out-to-top-2 data-[state=closed]:data-[side=left]:slide-out-to-right-2 data-[state=closed]:data-[side=right]:slide-out-to-left-2 data-[state=closed]:data-[side=top]:slide-out-to-bottom-2 relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border shadow-md\",\n position === \"popper\" &&\n \"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1\",\n className,\n )}\n position={position}\n {...props}\n >\n <SelectScrollUpButton />\n <SelectPrimitive.Viewport\n className={cn(\n \"p-1\",\n position === \"popper\" &&\n \"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]\",\n )}\n >\n {children}\n </SelectPrimitive.Viewport>\n <SelectScrollDownButton />\n </SelectPrimitive.Content>\n </SelectPrimitive.Portal>\n ),\n);\n\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectLabel\n * -------------------------------------------------------------------------- */\n\ntype SelectLabelElement = React.ElementRef<typeof SelectPrimitive.Label>;\ntype SelectLabelProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Label>;\n\nconst SelectLabel = React.forwardRef<SelectLabelElement, SelectLabelProps>(({ className, ...props }, ref) => (\n <SelectPrimitive.Label ref={ref} className={cn(\"px-2 py-1.5 text-sm font-semibold\", className)} {...props} />\n));\n\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectItem\n * -------------------------------------------------------------------------- */\n\ntype SelectItemElement = React.ElementRef<typeof SelectPrimitive.Item>;\ntype SelectItemProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Item>;\n\nconst SelectItem = React.forwardRef<SelectItemElement, SelectItemProps>(({ className, children, ...props }, ref) => (\n <SelectPrimitive.Item\n ref={ref}\n className={cn(\n \"focus:bg-accent focus:text-accent-foreground relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-2 pr-8 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50\",\n className,\n )}\n {...props}\n >\n <span className=\"absolute right-2 flex size-3.5 items-center justify-center\">\n <SelectPrimitive.ItemIndicator>\n <CheckIcon className=\"size-4\" />\n </SelectPrimitive.ItemIndicator>\n </span>\n <SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>\n </SelectPrimitive.Item>\n));\n\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: SelectSeparator\n * -------------------------------------------------------------------------- */\n\ntype SelectSeparatorElement = React.ElementRef<typeof SelectPrimitive.Separator>;\ntype SelectSeparatorProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Separator>;\n\nconst SelectSeparator = React.forwardRef<SelectSeparatorElement, SelectSeparatorProps>(\n ({ className, ...props }, ref) => (\n <SelectPrimitive.Separator ref={ref} className={cn(\"bg-muted -mx-1 my-1 h-px\", className)} {...props} />\n ),\n);\n\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n type SelectProps,\n type SelectGroupProps,\n type SelectValueProps,\n type SelectTriggerProps,\n type SelectContentProps,\n type SelectLabelProps,\n type SelectItemProps,\n type SelectSeparatorProps,\n type SelectScrollUpButtonProps,\n type SelectScrollDownButtonProps,\n};\n"],"mappings":";;;;;AAEA,YAAY,WAAW;AACvB,SAAS,eAAe,WAAW,iBAAiB,qBAAqB;AACzE,YAAY,qBAAqB;AAiC7B,SAUI,KAVJ;AAzBJ,IAAM,SAAyB;AAO/B,IAAM,cAA8B;AAOpC,IAAM,cAA8B;AASpC,IAAM,gBAAsB;AAAA,EAC1B,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAClC;AAAA,IAAiB;AAAA,IAAhB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA,MAEH;AAAA;AAAA,QACD,oBAAiB,sBAAhB,EAAqB,SAAO,MAC3B,8BAAC,iBAAc,WAAU,qBAAoB,GAC/C;AAAA;AAAA;AAAA,EACF;AAEJ;AAEA,cAAc,cAA8B,wBAAQ;AASpD,IAAM,uBAA6B;AAAA,EACjC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB;AAAA,IAAiB;AAAA,IAAhB;AAAA,MACC;AAAA,MACA,WAAW,GAAG,wDAAwD,SAAS;AAAA,MAC9E,GAAG;AAAA,MAEJ,8BAAC,iBAAc;AAAA;AAAA,EACjB;AAEJ;AAEA,qBAAqB,cAA8B,+BAAe;AASlE,IAAM,yBAA+B;AAAA,EACnC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB;AAAA,IAAiB;AAAA,IAAhB;AAAA,MACC;AAAA,MACA,WAAW,GAAG,wDAAwD,SAAS;AAAA,MAC9E,GAAG;AAAA,MAEJ,8BAAC,mBAAgB;AAAA;AAAA,EACnB;AAEJ;AAEA,uBAAuB,cAA8B,iCAAiB;AAStE,IAAM,gBAAs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
@@ -28,7 +28,7 @@ declare const CommandInput: React.ForwardRefExoticComponent<Omit<Omit<Pick<Pick<
28
28
  ref?: React.Ref<HTMLInputElement> | undefined;
29
29
  } & {
30
30
  asChild?: boolean | undefined;
31
- }, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "onChange" | "type" | "value"> & {
31
+ }, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "type" | "value" | "onChange"> & {
32
32
  value?: string | undefined;
33
33
  onValueChange?: ((search: string) => void) | undefined;
34
34
  } & React.RefAttributes<HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
@@ -77,7 +77,7 @@ declare const CommandItem: React.ForwardRefExoticComponent<Omit<{
77
77
  ref?: React.Ref<HTMLDivElement> | undefined;
78
78
  } & {
79
79
  asChild?: boolean | undefined;
80
- }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "onSelect" | "disabled" | "value"> & {
80
+ }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "disabled" | "value" | "onSelect"> & {
81
81
  disabled?: boolean | undefined;
82
82
  onSelect?: ((value: string) => void) | undefined;
83
83
  value?: string | undefined;
package/dist/command.d.ts CHANGED
@@ -28,7 +28,7 @@ declare const CommandInput: React.ForwardRefExoticComponent<Omit<Omit<Pick<Pick<
28
28
  ref?: React.Ref<HTMLInputElement> | undefined;
29
29
  } & {
30
30
  asChild?: boolean | undefined;
31
- }, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "onChange" | "type" | "value"> & {
31
+ }, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "type" | "value" | "onChange"> & {
32
32
  value?: string | undefined;
33
33
  onValueChange?: ((search: string) => void) | undefined;
34
34
  } & React.RefAttributes<HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
@@ -77,7 +77,7 @@ declare const CommandItem: React.ForwardRefExoticComponent<Omit<{
77
77
  ref?: React.Ref<HTMLDivElement> | undefined;
78
78
  } & {
79
79
  asChild?: boolean | undefined;
80
- }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "onSelect" | "disabled" | "value"> & {
80
+ }, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "disabled" | "value" | "onSelect"> & {
81
81
  disabled?: boolean | undefined;
82
82
  onSelect?: ((value: string) => void) | undefined;
83
83
  value?: string | undefined;
@@ -1,6 +1,5 @@
1
1
  import * as React from 'react';
2
2
  import * as ReactTable from '@tanstack/react-table';
3
- export * from '@tanstack/react-table';
4
3
 
5
4
  interface DataTableViewOptionsProps<TData> {
6
5
  table: ReactTable.Table<TData>;
@@ -1,6 +1,5 @@
1
1
  import * as React from 'react';
2
2
  import * as ReactTable from '@tanstack/react-table';
3
- export * from '@tanstack/react-table';
4
3
 
5
4
  interface DataTableViewOptionsProps<TData> {
6
5
  table: ReactTable.Table<TData>;
@@ -1,11 +1,11 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _createStarExport(obj) { Object.keys(obj) .filter((key) => key !== "default" && key !== "__esModule") .forEach((key) => { if (exports.hasOwnProperty(key)) { return; } Object.defineProperty(exports, key, {enumerable: true, configurable: true, get: () => obj[key]}); }); }"use client";
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
2
2
 
3
3
 
4
4
 
5
5
 
6
6
 
7
7
 
8
- var _chunkOSFYUOPNjs = require('./chunk-OSFYUOPN.js');
8
+ var _chunkBA3XYBWRjs = require('./chunk-BA3XYBWR.js');
9
9
 
10
10
 
11
11
 
@@ -35,7 +35,6 @@ var _chunkG3NP7M2Njs = require('./chunk-G3NP7M2N.js');
35
35
 
36
36
 
37
37
  var _reacticons = require('@radix-ui/react-icons');
38
- var _reacttable = require('@tanstack/react-table'); _createStarExport(_reacttable);
39
38
  var _jsxruntime = require('react/jsx-runtime');
40
39
  function DataTableViewOptions({ table }) {
41
40
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3ZZ3SRTJjs.DropdownMenu, { children: [
@@ -79,15 +78,15 @@ function DataTablePagination({
79
78
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center space-x-2", children: [
80
79
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm font-medium", children: "Rows per page" }),
81
80
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
82
- _chunkOSFYUOPNjs.Select,
81
+ _chunkBA3XYBWRjs.Select,
83
82
  {
84
- value: `${table.getState().pagination.pageSize}`,
83
+ value: String(table.getState().pagination.pageSize),
85
84
  onValueChange: (value) => {
86
85
  table.setPageSize(Number(value));
87
86
  },
88
87
  children: [
89
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkOSFYUOPNjs.SelectTrigger, { className: "h-8 w-[70px]", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkOSFYUOPNjs.SelectValue, { placeholder: table.getState().pagination.pageSize }) }),
90
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkOSFYUOPNjs.SelectContent, { side: "top", children: [10, 20, 30, 40, 50].map((pageSize) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkOSFYUOPNjs.SelectItem, { value: `${pageSize}`, children: pageSize }, pageSize)) })
88
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBA3XYBWRjs.SelectTrigger, { className: "h-8 w-[70px]", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBA3XYBWRjs.SelectValue, { placeholder: table.getState().pagination.pageSize }) }),
89
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBA3XYBWRjs.SelectContent, { side: "top", children: [10, 20, 30, 40, 50].map((pageSize) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBA3XYBWRjs.SelectItem, { value: `${pageSize}`, children: pageSize }, pageSize)) })
91
90
  ]
92
91
  }
93
92
  )
@@ -1 +1 @@
1
- {"version":3,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U,0CAAyC;AAAA,YAAE;AAAA;AAAA;AAAA,MAEpE;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACC,SAAS,MAAM;AACb,mBAAO,cAAc,IAAI;AAAA,UAC3B;AAAA,UAEA;AAAA,gCAAC,iBAAc,WAAU,0CAAyC;AAAA,YAAE;AAAA;AAAA;AAAA,MAEtE;AAAA,MACA,oBAAC,yBAAsB;AAAA,MACvB;AAAA,QAAC;AAAA;AAAA,UACC,SAAS,MAAM;AACb,mBAAO,iBAAiB,KAAK;AAAA,UAC/B;AAAA,UAEA;AAAA,gCAAC,eAAY,WAAU,0CAAyC;AAAA,YAAE;AAAA;AAAA;AAAA,MAEpE;AAAA,OACF;AAAA,KACF,GACF;AAEJ;AAEA,SAAS,SAAS,EAAE,OAAO,GAAyD;AAClF,UAAQ,QAAQ;AAAA,IACd,KAAK;AACH,aAAO,oBAAC,iBAAc,WAAU,eAAc;AAAA,IAChD,KAAK;AACH,aAAO,oBAAC,eAAY,WAAU,eAAc;AAAA,IAC9C;AACE,aAAO,oBAAC,iBAAc,WAAU,eAAc;AAAA,EAClD;AACF","sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport type * as ReactTable from \"@tanstack/react-table\";\nimport { type SortDirection } from \"@tanstack/react-table\";\nimport {\n ArrowDownIcon,\n ArrowUpIcon,\n CaretSortIcon,\n ChevronLeftIcon,\n ChevronRightIcon,\n DoubleArrowLeftIcon,\n DoubleArrowRightIcon,\n EyeNoneIcon,\n MixerHorizontalIcon,\n} from \"@radix-ui/react-icons\";\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuItem,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n DropdownMenuTrigger,\n} from \"./dropdown-menu\";\nimport { Button } from \"./button\";\nimport { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from \"./select\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: DataTableViewOptions\n * -------------------------------------------------------------------------- */\n\ninterface DataTableViewOptionsProps<TData> {\n table: ReactTable.Table<TData>;\n}\n\nfunction DataTableViewOptions<TData>({ table }: DataTableViewOptionsProps<TData>): React.JSX.Element {\n return (\n <DropdownMenu>\n <DropdownMenuTrigger asChild>\n <Button variant=\"outline\" size=\"sm\" className=\"ml-auto hidden h-8 lg:flex\">\n <MixerHorizontalIcon className=\"mr-2 size-4\" />\n View\n </Button>\n </DropdownMenuTrigger>\n <DropdownMenuContent align=\"end\" className=\"w-[150px]\">\n <DropdownMenuLabel>Toggle columns</DropdownMenuLabel>\n <DropdownMenuSeparator />\n {table\n .getAllColumns()\n .filter((column) => typeof column.accessorFn !== \"undefined\" && column.getCanHide())\n .map((column) => {\n return (\n <DropdownMenuCheckboxItem\n key={column.id}\n className=\"capitalize\"\n checked={column.getIsVisible()}\n onCheckedChange={(value) => {\n column.toggleVisibility(Boolean(value));\n }}\n >\n {column.id}\n </DropdownMenuCheckboxItem>\n );\n })}\n </DropdownMenuContent>\n </DropdownMenu>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: DataTablePagination\n * -------------------------------------------------------------------------- */\n\ninterface DataTablePaginationProps<TData> extends React.HTMLAttributes<HTMLDivElement> {\n table: ReactTable.Table<TData>;\n}\n\nfunction DataTablePagination<TData>({\n table,\n className,\n ...props\n}: DataTablePaginationProps<TData>): React.JSX.Element {\n return (\n <div className={cn(\"flex items-center justify-between px-2\", className)} {...props}>\n <div className=\"text-muted-foreground flex-1 text-sm\">\n {table.getFilteredSelectedRowModel().rows.length} of {table.getFilteredRowModel().rows.length} row(s) selected.\n </div>\n <div className=\"flex items-center space-x-6 lg:space-x-8\">\n <div className=\"flex items-center space-x-2\">\n <p className=\"text-sm font-medium\">Rows per page</p>\n <Select\n value={`${table.getState().pagination.pageSize}`}\n onValueChange={(value) => {\n table.setPageSize(Number(value));\n }}\n >\n <SelectTrigger className=\"h-8 w-[70px]\">\n <SelectValue placeholder={table.getState().pagination.pageSize} />\n </SelectTrigger>\n <SelectContent side=\"top\">\n {[10, 20, 30, 40, 50].map((pageSize) => (\n <SelectItem key={pageSize} value={`${pageSize}`}>\n {pageSize}\n </SelectItem>\n ))}\n </SelectContent>\n </Select>\n </div>\n <div className=\"flex w-[100px] items-center justify-center text-sm font-medium\">\n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n </div>\n <div className=\"flex items-center space-x-2\">\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n className=\"hidden lg:flex\"\n onClick={() => {\n table.setPageIndex(0);\n }}\n disabled={!table.getCanPreviousPage()}\n >\n <span className=\"sr-only\">Go to first page</span>\n <DoubleArrowLeftIcon className=\"size-4\" />\n </Button>\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n onClick={() => {\n table.previousPage();\n }}\n disabled={!table.getCanPreviousPage()}\n >\n <span className=\"sr-only\">Go to previous page</span>\n <ChevronLeftIcon className=\"size-4\" />\n </Button>\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n onClick={() => {\n table.nextPage();\n }}\n disabled={!table.getCanNextPage()}\n >\n <span className=\"sr-only\">Go to next page</span>\n <ChevronRightIcon className=\"size-4\" />\n </Button>\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n className=\"hidden lg:flex\"\n onClick={() => {\n table.setPageIndex(table.getPageCount() - 1);\n }}\n disabled={!table.getCanNextPage()}\n >\n <span className=\"sr-only\">Go to last page</span>\n <DoubleArrowRightIcon className=\"size-4\" />\n </Button>\n </div>\n </div>\n </div>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: DataTableColumnHeader\n * -------------------------------------------------------------------------- */\n\ninterface DataTableColumnHeaderProps<TData, TValue> extends React.HTMLAttributes<HTMLDivElement> {\n column: ReactTable.Column<TData, TValue>;\n title: string;\n}\n\nfunction DataTableColumnHeader<TData, TValue>({\n column,\n title,\n className,\n}: DataTableColumnHeaderProps<TData, TValue>): React.JSX.Element {\n if (!column.getCanSort()) {\n return <div className={cn(className)}>{title}</div>;\n }\n\n return (\n <div className={cn(\"flex items-center space-x-2\", className)}>\n <DropdownMenu>\n <DropdownMenuTrigger asChild>\n <Button variant=\"ghost\" size=\"xs\" className=\"data-[state=open]:bg-accent -ml-3\">\n <span>{title}</span>\n <SortIcon sorted={column.getIsSorted()} />\n </Button>\n </DropdownMenuTrigger>\n <DropdownMenuContent align=\"start\">\n <DropdownMenuItem\n onClick={() => {\n column.toggleSorting(false);\n }}\n >\n <ArrowUpIcon className=\"text-muted-foreground/70 mr-2 size-3.5\" />\n Asc\n </DropdownMenuItem>\n <DropdownMenuItem\n onClick={() => {\n column.toggleSorting(true);\n }}\n >\n <ArrowDownIcon className=\"text-muted-foreground/70 mr-2 size-3.5\" />\n Desc\n </DropdownMenuItem>\n <DropdownMenuSeparator />\n <DropdownMenuItem\n onClick={() => {\n column.toggleVisibility(false);\n }}\n >\n <EyeNoneIcon className=\"text-muted-foreground/70 mr-2 size-3.5\" />\n Hide\n </DropdownMenuItem>\n </DropdownMenuContent>\n </DropdownMenu>\n </div>\n );\n}\n\nfunction SortIcon({ sorted }: { sorted: false | SortDirection }): React.JSX.Element {\n switch (sorted) {\n case \"desc\":\n return <ArrowDownIcon className=\"ml-2 size-4\" />;\n case \"asc\":\n return <ArrowUpIcon className=\"ml-2 size-4\" />;\n default:\n return <CaretSortIcon className=\"ml-2 size-4\" />;\n }\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n DataTableViewOptions,\n DataTablePagination,\n DataTableColumnHeader,\n type DataTableViewOptionsProps,\n type DataTablePaginationProps,\n type DataTableColumnHeaderProps,\n};\n\nexport * from \"@tanstack/react-table\";\n"]}
1
+ {"version":3,"sources":["../src/data-table.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAKA;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AA0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AAAA;AAAA;AAAA,MAEtE;AAAA,MACA,oBAAC,yBAAsB;AAAA,MACvB;AAAA,QAAC;AAAA;AAAA,UACC,SAAS,MAAM;AACb,mBAAO,iBAAiB,KAAK;AAAA,UAC/B;AAAA,UAEA;AAAA,gCAAC,eAAY,WAAU,0CAAyC;AAAA,YAAE;AAAA;AAAA;AAAA,MAEpE;AAAA,OACF;AAAA,KACF,GACF;AAEJ;AAEA,SAAS,SAAS,EAAE,OAAO,GAAyD;AAClF,UAAQ,QAAQ;AAAA,IACd,KAAK;AACH,aAAO,oBAAC,iBAAc,WAAU,eAAc;AAAA,IAChD,KAAK;AACH,aAAO,oBAAC,eAAY,WAAU,eAAc;AAAA,IAC9C;AACE,aAAO,oBAAC,iBAAc,WAAU,eAAc;AAAA,EAClD;AACF","sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport type * as ReactTable from \"@tanstack/react-table\";\nimport { type SortDirection } from \"@tanstack/react-table\";\nimport {\n ArrowDownIcon,\n ArrowUpIcon,\n CaretSortIcon,\n ChevronLeftIcon,\n ChevronRightIcon,\n DoubleArrowLeftIcon,\n DoubleArrowRightIcon,\n EyeNoneIcon,\n MixerHorizontalIcon,\n} from \"@radix-ui/react-icons\";\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuItem,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n DropdownMenuTrigger,\n} from \"./dropdown-menu\";\nimport { Button } from \"./button\";\nimport { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from \"./select\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: DataTableViewOptions\n * -------------------------------------------------------------------------- */\n\ninterface DataTableViewOptionsProps<TData> {\n table: ReactTable.Table<TData>;\n}\n\nfunction DataTableViewOptions<TData>({ table }: DataTableViewOptionsProps<TData>): React.JSX.Element {\n return (\n <DropdownMenu>\n <DropdownMenuTrigger asChild>\n <Button variant=\"outline\" size=\"sm\" className=\"ml-auto hidden h-8 lg:flex\">\n <MixerHorizontalIcon className=\"mr-2 size-4\" />\n View\n </Button>\n </DropdownMenuTrigger>\n <DropdownMenuContent align=\"end\" className=\"w-[150px]\">\n <DropdownMenuLabel>Toggle columns</DropdownMenuLabel>\n <DropdownMenuSeparator />\n {table\n .getAllColumns()\n .filter((column) => typeof column.accessorFn !== \"undefined\" && column.getCanHide())\n .map((column) => {\n return (\n <DropdownMenuCheckboxItem\n key={column.id}\n className=\"capitalize\"\n checked={column.getIsVisible()}\n onCheckedChange={(value) => {\n column.toggleVisibility(Boolean(value));\n }}\n >\n {column.id}\n </DropdownMenuCheckboxItem>\n );\n })}\n </DropdownMenuContent>\n </DropdownMenu>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: DataTablePagination\n * -------------------------------------------------------------------------- */\n\ninterface DataTablePaginationProps<TData> extends React.HTMLAttributes<HTMLDivElement> {\n table: ReactTable.Table<TData>;\n}\n\nfunction DataTablePagination<TData>({\n table,\n className,\n ...props\n}: DataTablePaginationProps<TData>): React.JSX.Element {\n return (\n <div className={cn(\"flex items-center justify-between px-2\", className)} {...props}>\n <div className=\"text-muted-foreground flex-1 text-sm\">\n {table.getFilteredSelectedRowModel().rows.length} of {table.getFilteredRowModel().rows.length} row(s) selected.\n </div>\n <div className=\"flex items-center space-x-6 lg:space-x-8\">\n <div className=\"flex items-center space-x-2\">\n <p className=\"text-sm font-medium\">Rows per page</p>\n <Select\n value={String(table.getState().pagination.pageSize)}\n onValueChange={(value) => {\n table.setPageSize(Number(value));\n }}\n >\n <SelectTrigger className=\"h-8 w-[70px]\">\n <SelectValue placeholder={table.getState().pagination.pageSize} />\n </SelectTrigger>\n <SelectContent side=\"top\">\n {[10, 20, 30, 40, 50].map((pageSize) => (\n <SelectItem key={pageSize} value={`${pageSize}`}>\n {pageSize}\n </SelectItem>\n ))}\n </SelectContent>\n </Select>\n </div>\n <div className=\"flex w-[100px] items-center justify-center text-sm font-medium\">\n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n </div>\n <div className=\"flex items-center space-x-2\">\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n className=\"hidden lg:flex\"\n onClick={() => {\n table.setPageIndex(0);\n }}\n disabled={!table.getCanPreviousPage()}\n >\n <span className=\"sr-only\">Go to first page</span>\n <DoubleArrowLeftIcon className=\"size-4\" />\n </Button>\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n onClick={() => {\n table.previousPage();\n }}\n disabled={!table.getCanPreviousPage()}\n >\n <span className=\"sr-only\">Go to previous page</span>\n <ChevronLeftIcon className=\"size-4\" />\n </Button>\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n onClick={() => {\n table.nextPage();\n }}\n disabled={!table.getCanNextPage()}\n >\n <span className=\"sr-only\">Go to next page</span>\n <ChevronRightIcon className=\"size-4\" />\n </Button>\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n className=\"hidden lg:flex\"\n onClick={() => {\n table.setPageIndex(table.getPageCount() - 1);\n }}\n disabled={!table.getCanNextPage()}\n >\n <span className=\"sr-only\">Go to last page</span>\n <DoubleArrowRightIcon className=\"size-4\" />\n </Button>\n </div>\n </div>\n </div>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: DataTableColumnHeader\n * -------------------------------------------------------------------------- */\n\ninterface DataTableColumnHeaderProps<TData, TValue> extends React.HTMLAttributes<HTMLDivElement> {\n column: ReactTable.Column<TData, TValue>;\n title: string;\n}\n\nfunction DataTableColumnHeader<TData, TValue>({\n column,\n title,\n className,\n}: DataTableColumnHeaderProps<TData, TValue>): React.JSX.Element {\n if (!column.getCanSort()) {\n return <div className={cn(className)}>{title}</div>;\n }\n\n return (\n <div className={cn(\"flex items-center space-x-2\", className)}>\n <DropdownMenu>\n <DropdownMenuTrigger asChild>\n <Button variant=\"ghost\" size=\"xs\" className=\"data-[state=open]:bg-accent -ml-3\">\n <span>{title}</span>\n <SortIcon sorted={column.getIsSorted()} />\n </Button>\n </DropdownMenuTrigger>\n <DropdownMenuContent align=\"start\">\n <DropdownMenuItem\n onClick={() => {\n column.toggleSorting(false);\n }}\n >\n <ArrowUpIcon className=\"text-muted-foreground/70 mr-2 size-3.5\" />\n Asc\n </DropdownMenuItem>\n <DropdownMenuItem\n onClick={() => {\n column.toggleSorting(true);\n }}\n >\n <ArrowDownIcon className=\"text-muted-foreground/70 mr-2 size-3.5\" />\n Desc\n </DropdownMenuItem>\n <DropdownMenuSeparator />\n <DropdownMenuItem\n onClick={() => {\n column.toggleVisibility(false);\n }}\n >\n <EyeNoneIcon className=\"text-muted-foreground/70 mr-2 size-3.5\" />\n Hide\n </DropdownMenuItem>\n </DropdownMenuContent>\n </DropdownMenu>\n </div>\n );\n}\n\nfunction SortIcon({ sorted }: { sorted: false | SortDirection }): React.JSX.Element {\n switch (sorted) {\n case \"desc\":\n return <ArrowDownIcon className=\"ml-2 size-4\" />;\n case \"asc\":\n return <ArrowUpIcon className=\"ml-2 size-4\" />;\n default:\n return <CaretSortIcon className=\"ml-2 size-4\" />;\n }\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n DataTableViewOptions,\n DataTablePagination,\n DataTableColumnHeader,\n type DataTableViewOptionsProps,\n type DataTablePaginationProps,\n type DataTableColumnHeaderProps,\n};\n"]}
@@ -5,7 +5,7 @@ import {
5
5
  SelectItem,
6
6
  SelectTrigger,
7
7
  SelectValue
8
- } from "./chunk-BBQXHKST.mjs";
8
+ } from "./chunk-Q24YJU6W.mjs";
9
9
  import {
10
10
  DropdownMenu,
11
11
  DropdownMenuCheckboxItem,
@@ -35,7 +35,6 @@ import {
35
35
  EyeNoneIcon,
36
36
  MixerHorizontalIcon
37
37
  } from "@radix-ui/react-icons";
38
- export * from "@tanstack/react-table";
39
38
  import { jsx, jsxs } from "react/jsx-runtime";
40
39
  function DataTableViewOptions({ table }) {
41
40
  return /* @__PURE__ */ jsxs(DropdownMenu, { children: [
@@ -81,7 +80,7 @@ function DataTablePagination({
81
80
  /* @__PURE__ */ jsxs(
82
81
  Select,
83
82
  {
84
- value: `${table.getState().pagination.pageSize}`,
83
+ value: String(table.getState().pagination.pageSize),
85
84
  onValueChange: (value) => {
86
85
  table.setPageSize(Number(value));
87
86
  },
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/data-table.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport type * as ReactTable from \"@tanstack/react-table\";\nimport { type SortDirection } from \"@tanstack/react-table\";\nimport {\n ArrowDownIcon,\n ArrowUpIcon,\n CaretSortIcon,\n ChevronLeftIcon,\n ChevronRightIcon,\n DoubleArrowLeftIcon,\n DoubleArrowRightIcon,\n EyeNoneIcon,\n MixerHorizontalIcon,\n} from \"@radix-ui/react-icons\";\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuItem,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n DropdownMenuTrigger,\n} from \"./dropdown-menu\";\nimport { Button } from \"./button\";\nimport { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from \"./select\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: DataTableViewOptions\n * -------------------------------------------------------------------------- */\n\ninterface DataTableViewOptionsProps<TData> {\n table: ReactTable.Table<TData>;\n}\n\nfunction DataTableViewOptions<TData>({ table }: DataTableViewOptionsProps<TData>): React.JSX.Element {\n return (\n <DropdownMenu>\n <DropdownMenuTrigger asChild>\n <Button variant=\"outline\" size=\"sm\" className=\"ml-auto hidden h-8 lg:flex\">\n <MixerHorizontalIcon className=\"mr-2 size-4\" />\n View\n </Button>\n </DropdownMenuTrigger>\n <DropdownMenuContent align=\"end\" className=\"w-[150px]\">\n <DropdownMenuLabel>Toggle columns</DropdownMenuLabel>\n <DropdownMenuSeparator />\n {table\n .getAllColumns()\n .filter((column) => typeof column.accessorFn !== \"undefined\" && column.getCanHide())\n .map((column) => {\n return (\n <DropdownMenuCheckboxItem\n key={column.id}\n className=\"capitalize\"\n checked={column.getIsVisible()}\n onCheckedChange={(value) => {\n column.toggleVisibility(Boolean(value));\n }}\n >\n {column.id}\n </DropdownMenuCheckboxItem>\n );\n })}\n </DropdownMenuContent>\n </DropdownMenu>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: DataTablePagination\n * -------------------------------------------------------------------------- */\n\ninterface DataTablePaginationProps<TData> extends React.HTMLAttributes<HTMLDivElement> {\n table: ReactTable.Table<TData>;\n}\n\nfunction DataTablePagination<TData>({\n table,\n className,\n ...props\n}: DataTablePaginationProps<TData>): React.JSX.Element {\n return (\n <div className={cn(\"flex items-center justify-between px-2\", className)} {...props}>\n <div className=\"text-muted-foreground flex-1 text-sm\">\n {table.getFilteredSelectedRowModel().rows.length} of {table.getFilteredRowModel().rows.length} row(s) selected.\n </div>\n <div className=\"flex items-center space-x-6 lg:space-x-8\">\n <div className=\"flex items-center space-x-2\">\n <p className=\"text-sm font-medium\">Rows per page</p>\n <Select\n value={`${table.getState().pagination.pageSize}`}\n onValueChange={(value) => {\n table.setPageSize(Number(value));\n }}\n >\n <SelectTrigger className=\"h-8 w-[70px]\">\n <SelectValue placeholder={table.getState().pagination.pageSize} />\n </SelectTrigger>\n <SelectContent side=\"top\">\n {[10, 20, 30, 40, 50].map((pageSize) => (\n <SelectItem key={pageSize} value={`${pageSize}`}>\n {pageSize}\n </SelectItem>\n ))}\n </SelectContent>\n </Select>\n </div>\n <div className=\"flex w-[100px] items-center justify-center text-sm font-medium\">\n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n </div>\n <div className=\"flex items-center space-x-2\">\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n className=\"hidden lg:flex\"\n onClick={() => {\n table.setPageIndex(0);\n }}\n disabled={!table.getCanPreviousPage()}\n >\n <span className=\"sr-only\">Go to first page</span>\n <DoubleArrowLeftIcon className=\"size-4\" />\n </Button>\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n onClick={() => {\n table.previousPage();\n }}\n disabled={!table.getCanPreviousPage()}\n >\n <span className=\"sr-only\">Go to previous page</span>\n <ChevronLeftIcon className=\"size-4\" />\n </Button>\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n onClick={() => {\n table.nextPage();\n }}\n disabled={!table.getCanNextPage()}\n >\n <span className=\"sr-only\">Go to next page</span>\n <ChevronRightIcon className=\"size-4\" />\n </Button>\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n className=\"hidden lg:flex\"\n onClick={() => {\n table.setPageIndex(table.getPageCount() - 1);\n }}\n disabled={!table.getCanNextPage()}\n >\n <span className=\"sr-only\">Go to last page</span>\n <DoubleArrowRightIcon className=\"size-4\" />\n </Button>\n </div>\n </div>\n </div>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: DataTableColumnHeader\n * -------------------------------------------------------------------------- */\n\ninterface DataTableColumnHeaderProps<TData, TValue> extends React.HTMLAttributes<HTMLDivElement> {\n column: ReactTable.Column<TData, TValue>;\n title: string;\n}\n\nfunction DataTableColumnHeader<TData, TValue>({\n column,\n title,\n className,\n}: DataTableColumnHeaderProps<TData, TValue>): React.JSX.Element {\n if (!column.getCanSort()) {\n return <div className={cn(className)}>{title}</div>;\n }\n\n return (\n <div className={cn(\"flex items-center space-x-2\", className)}>\n <DropdownMenu>\n <DropdownMenuTrigger asChild>\n <Button variant=\"ghost\" size=\"xs\" className=\"data-[state=open]:bg-accent -ml-3\">\n <span>{title}</span>\n <SortIcon sorted={column.getIsSorted()} />\n </Button>\n </DropdownMenuTrigger>\n <DropdownMenuContent align=\"start\">\n <DropdownMenuItem\n onClick={() => {\n column.toggleSorting(false);\n }}\n >\n <ArrowUpIcon className=\"text-muted-foreground/70 mr-2 size-3.5\" />\n Asc\n </DropdownMenuItem>\n <DropdownMenuItem\n onClick={() => {\n column.toggleSorting(true);\n }}\n >\n <ArrowDownIcon className=\"text-muted-foreground/70 mr-2 size-3.5\" />\n Desc\n </DropdownMenuItem>\n <DropdownMenuSeparator />\n <DropdownMenuItem\n onClick={() => {\n column.toggleVisibility(false);\n }}\n >\n <EyeNoneIcon className=\"text-muted-foreground/70 mr-2 size-3.5\" />\n Hide\n </DropdownMenuItem>\n </DropdownMenuContent>\n </DropdownMenu>\n </div>\n );\n}\n\nfunction SortIcon({ sorted }: { sorted: false | SortDirection }): React.JSX.Element {\n switch (sorted) {\n case \"desc\":\n return <ArrowDownIcon className=\"ml-2 size-4\" />;\n case \"asc\":\n return <ArrowUpIcon className=\"ml-2 size-4\" />;\n default:\n return <CaretSortIcon className=\"ml-2 size-4\" />;\n }\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n DataTableViewOptions,\n DataTablePagination,\n DataTableColumnHeader,\n type DataTableViewOptionsProps,\n type DataTablePaginationProps,\n type DataTableColumnHeaderProps,\n};\n\nexport * from \"@tanstack/react-table\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAKA;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AA0OP,cAAc;AAhNN,SACE,KADF;AAJR,SAAS,qBAA4B,EAAE,MAAM,GAAwD;AACnG,SACE,qBAAC,gBACC;AAAA,wBAAC,uBAAoB,SAAO,MAC1B,+BAAC,UAAO,SAAQ,WAAU,MAAK,MAAK,WAAU,8BAC5C;AAAA,0BAAC,uBAAoB,WAAU,eAAc;AAAA,MAAE;AAAA,OAEjD,GACF;AAAA,IACA,qBAAC,uBAAoB,OAAM,OAAM,WAAU,aACzC;AAAA,0BAAC,qBAAkB,4BAAc;AAAA,MACjC,oBAAC,yBAAsB;AAAA,MACtB,MACE,cAAc,EACd,OAAO,CAAC,WAAW,OAAO,OAAO,eAAe,eAAe,OAAO,WAAW,CAAC,EAClF,IAAI,CAAC,WAAW;AACf,eACE;AAAA,UAAC;AAAA;AAAA,YAEC,WAAU;AAAA,YACV,SAAS,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"version":3,"sources":["../src/data-table.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport type * as ReactTable from \"@tanstack/react-table\";\nimport { type SortDirection } from \"@tanstack/react-table\";\nimport {\n ArrowDownIcon,\n ArrowUpIcon,\n CaretSortIcon,\n ChevronLeftIcon,\n ChevronRightIcon,\n DoubleArrowLeftIcon,\n DoubleArrowRightIcon,\n EyeNoneIcon,\n MixerHorizontalIcon,\n} from \"@radix-ui/react-icons\";\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuItem,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n DropdownMenuTrigger,\n} from \"./dropdown-menu\";\nimport { Button } from \"./button\";\nimport { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from \"./select\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: DataTableViewOptions\n * -------------------------------------------------------------------------- */\n\ninterface DataTableViewOptionsProps<TData> {\n table: ReactTable.Table<TData>;\n}\n\nfunction DataTableViewOptions<TData>({ table }: DataTableViewOptionsProps<TData>): React.JSX.Element {\n return (\n <DropdownMenu>\n <DropdownMenuTrigger asChild>\n <Button variant=\"outline\" size=\"sm\" className=\"ml-auto hidden h-8 lg:flex\">\n <MixerHorizontalIcon className=\"mr-2 size-4\" />\n View\n </Button>\n </DropdownMenuTrigger>\n <DropdownMenuContent align=\"end\" className=\"w-[150px]\">\n <DropdownMenuLabel>Toggle columns</DropdownMenuLabel>\n <DropdownMenuSeparator />\n {table\n .getAllColumns()\n .filter((column) => typeof column.accessorFn !== \"undefined\" && column.getCanHide())\n .map((column) => {\n return (\n <DropdownMenuCheckboxItem\n key={column.id}\n className=\"capitalize\"\n checked={column.getIsVisible()}\n onCheckedChange={(value) => {\n column.toggleVisibility(Boolean(value));\n }}\n >\n {column.id}\n </DropdownMenuCheckboxItem>\n );\n })}\n </DropdownMenuContent>\n </DropdownMenu>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: DataTablePagination\n * -------------------------------------------------------------------------- */\n\ninterface DataTablePaginationProps<TData> extends React.HTMLAttributes<HTMLDivElement> {\n table: ReactTable.Table<TData>;\n}\n\nfunction DataTablePagination<TData>({\n table,\n className,\n ...props\n}: DataTablePaginationProps<TData>): React.JSX.Element {\n return (\n <div className={cn(\"flex items-center justify-between px-2\", className)} {...props}>\n <div className=\"text-muted-foreground flex-1 text-sm\">\n {table.getFilteredSelectedRowModel().rows.length} of {table.getFilteredRowModel().rows.length} row(s) selected.\n </div>\n <div className=\"flex items-center space-x-6 lg:space-x-8\">\n <div className=\"flex items-center space-x-2\">\n <p className=\"text-sm font-medium\">Rows per page</p>\n <Select\n value={String(table.getState().pagination.pageSize)}\n onValueChange={(value) => {\n table.setPageSize(Number(value));\n }}\n >\n <SelectTrigger className=\"h-8 w-[70px]\">\n <SelectValue placeholder={table.getState().pagination.pageSize} />\n </SelectTrigger>\n <SelectContent side=\"top\">\n {[10, 20, 30, 40, 50].map((pageSize) => (\n <SelectItem key={pageSize} value={`${pageSize}`}>\n {pageSize}\n </SelectItem>\n ))}\n </SelectContent>\n </Select>\n </div>\n <div className=\"flex w-[100px] items-center justify-center text-sm font-medium\">\n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n </div>\n <div className=\"flex items-center space-x-2\">\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n className=\"hidden lg:flex\"\n onClick={() => {\n table.setPageIndex(0);\n }}\n disabled={!table.getCanPreviousPage()}\n >\n <span className=\"sr-only\">Go to first page</span>\n <DoubleArrowLeftIcon className=\"size-4\" />\n </Button>\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n onClick={() => {\n table.previousPage();\n }}\n disabled={!table.getCanPreviousPage()}\n >\n <span className=\"sr-only\">Go to previous page</span>\n <ChevronLeftIcon className=\"size-4\" />\n </Button>\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n onClick={() => {\n table.nextPage();\n }}\n disabled={!table.getCanNextPage()}\n >\n <span className=\"sr-only\">Go to next page</span>\n <ChevronRightIcon className=\"size-4\" />\n </Button>\n <Button\n variant=\"outline\"\n size=\"icon-xs\"\n className=\"hidden lg:flex\"\n onClick={() => {\n table.setPageIndex(table.getPageCount() - 1);\n }}\n disabled={!table.getCanNextPage()}\n >\n <span className=\"sr-only\">Go to last page</span>\n <DoubleArrowRightIcon className=\"size-4\" />\n </Button>\n </div>\n </div>\n </div>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: DataTableColumnHeader\n * -------------------------------------------------------------------------- */\n\ninterface DataTableColumnHeaderProps<TData, TValue> extends React.HTMLAttributes<HTMLDivElement> {\n column: ReactTable.Column<TData, TValue>;\n title: string;\n}\n\nfunction DataTableColumnHeader<TData, TValue>({\n column,\n title,\n className,\n}: DataTableColumnHeaderProps<TData, TValue>): React.JSX.Element {\n if (!column.getCanSort()) {\n return <div className={cn(className)}>{title}</div>;\n }\n\n return (\n <div className={cn(\"flex items-center space-x-2\", className)}>\n <DropdownMenu>\n <DropdownMenuTrigger asChild>\n <Button variant=\"ghost\" size=\"xs\" className=\"data-[state=open]:bg-accent -ml-3\">\n <span>{title}</span>\n <SortIcon sorted={column.getIsSorted()} />\n </Button>\n </DropdownMenuTrigger>\n <DropdownMenuContent align=\"start\">\n <DropdownMenuItem\n onClick={() => {\n column.toggleSorting(false);\n }}\n >\n <ArrowUpIcon className=\"text-muted-foreground/70 mr-2 size-3.5\" />\n Asc\n </DropdownMenuItem>\n <DropdownMenuItem\n onClick={() => {\n column.toggleSorting(true);\n }}\n >\n <ArrowDownIcon className=\"text-muted-foreground/70 mr-2 size-3.5\" />\n Desc\n </DropdownMenuItem>\n <DropdownMenuSeparator />\n <DropdownMenuItem\n onClick={() => {\n column.toggleVisibility(false);\n }}\n >\n <EyeNoneIcon className=\"text-muted-foreground/70 mr-2 size-3.5\" />\n Hide\n </DropdownMenuItem>\n </DropdownMenuContent>\n </DropdownMenu>\n </div>\n );\n}\n\nfunction SortIcon({ sorted }: { sorted: false | SortDirection }): React.JSX.Element {\n switch (sorted) {\n case \"desc\":\n return <ArrowDownIcon className=\"ml-2 size-4\" />;\n case \"asc\":\n return <ArrowUpIcon className=\"ml-2 size-4\" />;\n default:\n return <CaretSortIcon className=\"ml-2 size-4\" />;\n }\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n DataTableViewOptions,\n DataTablePagination,\n DataTableColumnHeader,\n type DataTableViewOptionsProps,\n type DataTablePaginationProps,\n type DataTableColumnHeaderProps,\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAKA;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AA0BC,SACE,KADF;AAJR,SAAS,qBAA4B,EAAE,MAAM,GAAwD;AACnG,SACE,qBAAC,gBACC;AAAA,wBAAC,uBAAoB,SAAO,MAC1B,+BAAC,UAAO,SAAQ,WAAU,MAAK,MAAK,WAAU,8BAC5C;AAAA,0BAAC,uBAAoB,WAAU,eAAc;AAAA,MAAE;AAAA,OAEjD,GACF;AAAA,IACA,qBAAC,uBAAoB,OAAM,OAAM,WAAU,aACzC;AAAA,0BAAC,qBAAkB,4BAAc;AAAA,MACjC,oBAAC,yBAAsB;AAAA,MACtB,MACE,cAAc,EACd,OAAO,CAAC,WAAW,OAAO,OAAO,eAAe,eAAe,OAAO,WAAW,CAAC,EAClF,IAAI,CAAC,WAAW;AACf,eACE;AAAA,UAAC;AAAA;AAAA,YAEC,WAAU;AAAA,YACV,SAAS,OAAO,aAAa;AAAA,YAC7B,iBAAiB,CAAC,UAAU;AAC1B,qBAAO,iBAAiB,QAAQ,KAAK,CAAC;AAAA,YACxC;AAAA,YAEC,iBAAO;AAAA;AAAA,UAPH,OAAO;AAAA,QAQd;AAAA,MAEJ,CAAC;AAAA,OACL;AAAA,KACF;AAEJ;AAUA,SAAS,oBAA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+BAAC,UAAO,SAAQ,SAAQ,MAAK,MAAK,WAAU,qCAC1C;AAAA,0BAAC,UAAM,iBAAM;AAAA,MACb,oBAAC,YAAS,QAAQ,OAAO,YAAY,GAAG;AAAA,OAC1C,GACF;AAAA,IACA,qBAAC,uBAAoB,OAAM,SACzB;AAAA;AAAA,QAAC;AAAA;AAAA,UACC,SAAS,MAAM;AACb,mBAAO,cAAc,KAAK;AAAA,UAC5B;AAAA,UAEA;AAAA,gCAAC,eAAY,WAAU,0CAAyC;AAAA,YAAE;AAAA;AAAA;AAAA,MAEpE;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACC,SAAS,MAAM;AACb,mBAAO,cAAc,IAAI;AAAA,UAC3B;AAAA,UAEA;AAAA,gCAAC,iBAAc,WAAU,0CAAyC;AAAA,YAAE;AAAA;AAAA;AAAA,MAEtE;AAAA,MACA,oBAAC,yBAAsB;AAAA,MACvB;AAAA,QAAC;AAAA;AAAA,UACC,SAAS,MAAM;AACb,mBAAO,iBAAiB,KAAK;AAAA,UAC/B;AAAA,UAEA;AAAA,gCAAC,eAAY,WAAU,0CAAyC;AAAA,YAAE;AAAA;AAAA;AAAA,MAEpE;AAAA,OACF;AAAA,KACF,GACF;AAEJ;AAEA,SAAS,SAAS,EAAE,OAAO,GAAyD;AAClF,UAAQ,QAAQ;AAAA,IACd,KAAK;AACH,aAAO,oBAAC,iBAAc,WAAU,eAAc;AAAA,IAChD,KAAK;AACH,aAAO,oBAAC,eAAY,WAAU,eAAc;AAAA,IAC9C;AACE,aAAO,oBAAC,iBAAc,WAAU,eAAc;AAAA,EAClD;AACF;","names":[]}
package/dist/select.js CHANGED
@@ -10,7 +10,7 @@
10
10
 
11
11
 
12
12
 
13
- var _chunkOSFYUOPNjs = require('./chunk-OSFYUOPN.js');
13
+ var _chunkBA3XYBWRjs = require('./chunk-BA3XYBWR.js');
14
14
  require('./chunk-G3NP7M2N.js');
15
15
 
16
16
 
@@ -23,5 +23,5 @@ require('./chunk-G3NP7M2N.js');
23
23
 
24
24
 
25
25
 
26
- exports.Select = _chunkOSFYUOPNjs.Select; exports.SelectContent = _chunkOSFYUOPNjs.SelectContent; exports.SelectGroup = _chunkOSFYUOPNjs.SelectGroup; exports.SelectItem = _chunkOSFYUOPNjs.SelectItem; exports.SelectLabel = _chunkOSFYUOPNjs.SelectLabel; exports.SelectScrollDownButton = _chunkOSFYUOPNjs.SelectScrollDownButton; exports.SelectScrollUpButton = _chunkOSFYUOPNjs.SelectScrollUpButton; exports.SelectSeparator = _chunkOSFYUOPNjs.SelectSeparator; exports.SelectTrigger = _chunkOSFYUOPNjs.SelectTrigger; exports.SelectValue = _chunkOSFYUOPNjs.SelectValue;
26
+ exports.Select = _chunkBA3XYBWRjs.Select; exports.SelectContent = _chunkBA3XYBWRjs.SelectContent; exports.SelectGroup = _chunkBA3XYBWRjs.SelectGroup; exports.SelectItem = _chunkBA3XYBWRjs.SelectItem; exports.SelectLabel = _chunkBA3XYBWRjs.SelectLabel; exports.SelectScrollDownButton = _chunkBA3XYBWRjs.SelectScrollDownButton; exports.SelectScrollUpButton = _chunkBA3XYBWRjs.SelectScrollUpButton; exports.SelectSeparator = _chunkBA3XYBWRjs.SelectSeparator; exports.SelectTrigger = _chunkBA3XYBWRjs.SelectTrigger; exports.SelectValue = _chunkBA3XYBWRjs.SelectValue;
27
27
  //# sourceMappingURL=select.js.map
package/dist/select.mjs CHANGED
@@ -10,7 +10,7 @@ import {
10
10
  SelectSeparator,
11
11
  SelectTrigger,
12
12
  SelectValue
13
- } from "./chunk-BBQXHKST.mjs";
13
+ } from "./chunk-Q24YJU6W.mjs";
14
14
  import "./chunk-UG3URV2Z.mjs";
15
15
  export {
16
16
  Select,