notra-editor 0.6.0 → 0.7.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/dist/components/blockquote-button/blockquote-button.d.cts +2 -2
- package/dist/components/blockquote-button/blockquote-button.d.ts +2 -2
- package/dist/components/code-block-button/code-block-button.d.cts +2 -2
- package/dist/components/code-block-button/code-block-button.d.ts +2 -2
- package/dist/components/heading-dropdown-menu/heading-dropdown-menu.d.cts +2 -2
- package/dist/components/heading-dropdown-menu/heading-dropdown-menu.d.ts +2 -2
- package/dist/components/heading-dropdown-menu/heading-menu-item.d.cts +2 -2
- package/dist/components/heading-dropdown-menu/heading-menu-item.d.ts +2 -2
- package/dist/components/image-popover/image-popover.d.cts +2 -2
- package/dist/components/image-popover/image-popover.d.ts +2 -2
- package/dist/components/image-popover/use-image-popover.d.cts +3 -3
- package/dist/components/image-popover/use-image-popover.d.ts +3 -3
- package/dist/components/link-popover/link-popover.d.cts +2 -2
- package/dist/components/link-popover/link-popover.d.ts +2 -2
- package/dist/components/link-popover/use-link-popover.d.cts +2 -2
- package/dist/components/link-popover/use-link-popover.d.ts +2 -2
- package/dist/components/list-dropdown-menu/list-dropdown-menu.d.cts +2 -2
- package/dist/components/list-dropdown-menu/list-dropdown-menu.d.ts +2 -2
- package/dist/components/list-dropdown-menu/list-menu-item.d.cts +2 -2
- package/dist/components/list-dropdown-menu/list-menu-item.d.ts +2 -2
- package/dist/components/mark-button/mark-button.d.cts +2 -2
- package/dist/components/mark-button/mark-button.d.ts +2 -2
- package/dist/components/toolbar/toolbar.d.cts +2 -2
- package/dist/components/toolbar/toolbar.d.ts +2 -2
- package/dist/components/ui/button.d.cts +2 -2
- package/dist/components/ui/button.d.ts +2 -2
- package/dist/components/ui/command.cjs +92 -29
- package/dist/components/ui/command.cjs.map +1 -1
- package/dist/components/ui/command.d.cts +18 -8
- package/dist/components/ui/command.d.ts +18 -8
- package/dist/components/ui/command.mjs +95 -29
- package/dist/components/ui/command.mjs.map +1 -1
- package/dist/components/ui/dialog.cjs +188 -0
- package/dist/components/ui/dialog.cjs.map +1 -0
- package/dist/components/ui/dialog.d.cts +20 -0
- package/dist/components/ui/dialog.d.ts +20 -0
- package/dist/components/ui/dialog.mjs +155 -0
- package/dist/components/ui/dialog.mjs.map +1 -0
- package/dist/components/ui/dropdown-menu.cjs +3 -2
- package/dist/components/ui/dropdown-menu.cjs.map +1 -1
- package/dist/components/ui/dropdown-menu.d.cts +16 -16
- package/dist/components/ui/dropdown-menu.d.ts +16 -16
- package/dist/components/ui/dropdown-menu.mjs +3 -2
- package/dist/components/ui/dropdown-menu.mjs.map +1 -1
- package/dist/components/ui/input-group.cjs +175 -0
- package/dist/components/ui/input-group.cjs.map +1 -0
- package/dist/components/ui/input-group.d.cts +20 -0
- package/dist/components/ui/input-group.d.ts +20 -0
- package/dist/components/ui/input-group.mjs +146 -0
- package/dist/components/ui/input-group.mjs.map +1 -0
- package/dist/components/ui/input.cjs +1 -1
- package/dist/components/ui/input.cjs.map +1 -1
- package/dist/components/ui/input.d.cts +2 -2
- package/dist/components/ui/input.d.ts +2 -2
- package/dist/components/ui/input.mjs +1 -1
- package/dist/components/ui/input.mjs.map +1 -1
- package/dist/components/ui/popover.cjs +46 -6
- package/dist/components/ui/popover.cjs.map +1 -1
- package/dist/components/ui/popover.d.cts +9 -6
- package/dist/components/ui/popover.d.ts +9 -6
- package/dist/components/ui/popover.mjs +43 -6
- package/dist/components/ui/popover.mjs.map +1 -1
- package/dist/components/ui/separator.cjs +2 -1
- package/dist/components/ui/separator.cjs.map +1 -1
- package/dist/components/ui/separator.d.cts +2 -2
- package/dist/components/ui/separator.d.ts +2 -2
- package/dist/components/ui/separator.mjs +2 -1
- package/dist/components/ui/separator.mjs.map +1 -1
- package/dist/components/ui/textarea.cjs +43 -0
- package/dist/components/ui/textarea.cjs.map +1 -0
- package/dist/components/ui/textarea.d.cts +6 -0
- package/dist/components/ui/textarea.d.ts +6 -0
- package/dist/components/ui/textarea.mjs +19 -0
- package/dist/components/ui/textarea.mjs.map +1 -0
- package/dist/components/undo-redo-button/undo-redo-button.d.cts +2 -2
- package/dist/components/undo-redo-button/undo-redo-button.d.ts +2 -2
- package/dist/components/undo-redo-button/use-undo-redo.d.cts +2 -2
- package/dist/components/undo-redo-button/use-undo-redo.d.ts +2 -2
- package/dist/extensions/code-block.cjs.map +1 -1
- package/dist/extensions/code-block.mjs.map +1 -1
- package/dist/styles/globals.css +953 -205
- package/dist/themes/default/editor.css +69 -0
- package/dist/themes/default/shared.css +33 -0
- package/package.json +3 -1
- package/dist/icons/redo-icon.cjs +0 -54
- package/dist/icons/redo-icon.cjs.map +0 -1
- package/dist/icons/redo-icon.d.cts +0 -7
- package/dist/icons/redo-icon.d.ts +0 -7
- package/dist/icons/redo-icon.mjs +0 -30
- package/dist/icons/redo-icon.mjs.map +0 -1
- package/dist/icons/undo-icon.cjs +0 -54
- package/dist/icons/undo-icon.cjs.map +0 -1
- package/dist/icons/undo-icon.d.cts +0 -7
- package/dist/icons/undo-icon.d.ts +0 -7
- package/dist/icons/undo-icon.mjs +0 -30
- package/dist/icons/undo-icon.mjs.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../src/components/ui/input-group.tsx"],"sourcesContent":["'use client';\n\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport * as React from 'react';\n\nimport { Button } from './button';\nimport { Input } from './input';\nimport { Textarea } from './textarea';\nimport { cn } from '../../lib/utils';\n\nfunction InputGroup({ className, ...props }: React.ComponentProps<'div'>) {\n\treturn (\n\t\t<div\n\t\t\tclassName={cn(\n\t\t\t\t'nt:group/input-group nt:relative nt:flex nt:h-8 nt:w-full nt:min-w-0 nt:items-center nt:rounded-lg nt:border nt:border-input nt:transition-colors nt:outline-none nt:in-data-[slot=combobox-content]:focus-within:border-inherit nt:in-data-[slot=combobox-content]:focus-within:ring-0 nt:has-disabled:bg-input/50 nt:has-disabled:opacity-50 nt:has-[[data-slot=input-group-control]:focus-visible]:border-ring nt:has-[[data-slot=input-group-control]:focus-visible]:ring-3 nt:has-[[data-slot=input-group-control]:focus-visible]:ring-ring/50 nt:has-[[data-slot][aria-invalid=true]]:border-destructive nt:has-[[data-slot][aria-invalid=true]]:ring-3 nt:has-[[data-slot][aria-invalid=true]]:ring-destructive/20 nt:has-[>[data-align=block-end]]:h-auto nt:has-[>[data-align=block-end]]:flex-col nt:has-[>[data-align=block-start]]:h-auto nt:has-[>[data-align=block-start]]:flex-col nt:has-[>textarea]:h-auto nt:dark:bg-input/30 nt:dark:has-disabled:bg-input/80 nt:dark:has-[[data-slot][aria-invalid=true]]:ring-destructive/40 nt:has-[>[data-align=block-end]]:[&>input]:pt-3 nt:has-[>[data-align=block-start]]:[&>input]:pb-3 nt:has-[>[data-align=inline-end]]:[&>input]:pr-1.5 nt:has-[>[data-align=inline-start]]:[&>input]:pl-1.5',\n\t\t\t\tclassName\n\t\t\t)}\n\t\t\tdata-slot=\"input-group\"\n\t\t\trole=\"group\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst inputGroupAddonVariants = cva(\n\t'nt:flex nt:h-auto nt:cursor-text nt:items-center nt:justify-center nt:gap-2 nt:py-1.5 nt:text-sm nt:font-medium nt:text-muted-foreground nt:select-none nt:group-data-[disabled=true]/input-group:opacity-50 nt:[&>kbd]:rounded-[calc(var(--radius)-5px)] nt:[&>svg:not([class*=size-])]:size-4',\n\t{\n\t\tvariants: {\n\t\t\talign: {\n\t\t\t\t'inline-start':\n\t\t\t\t\t'nt:order-first nt:pl-2 nt:has-[>button]:ml-[-0.3rem] nt:has-[>kbd]:ml-[-0.15rem]',\n\t\t\t\t'inline-end':\n\t\t\t\t\t'nt:order-last nt:pr-2 nt:has-[>button]:mr-[-0.3rem] nt:has-[>kbd]:mr-[-0.15rem]',\n\t\t\t\t'block-start':\n\t\t\t\t\t'nt:order-first nt:w-full nt:justify-start nt:px-2.5 nt:pt-2 nt:group-has-[>input]/input-group:pt-2 nt:[.border-b]:pb-2',\n\t\t\t\t'block-end':\n\t\t\t\t\t'nt:order-last nt:w-full nt:justify-start nt:px-2.5 nt:pb-2 nt:group-has-[>input]/input-group:pb-2 nt:[.border-t]:pt-2'\n\t\t\t}\n\t\t},\n\t\tdefaultVariants: {\n\t\t\talign: 'inline-start'\n\t\t}\n\t}\n);\n\nfunction InputGroupAddon({\n\tclassName,\n\talign = 'inline-start',\n\t...props\n}: React.ComponentProps<'div'> & VariantProps<typeof inputGroupAddonVariants>) {\n\treturn (\n\t\t<div\n\t\t\tclassName={cn(inputGroupAddonVariants({ align }), className)}\n\t\t\tdata-align={align}\n\t\t\tdata-slot=\"input-group-addon\"\n\t\t\trole=\"group\"\n\t\t\tonClick={(e) => {\n\t\t\t\tif ((e.target as HTMLElement).closest('button')) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\te.currentTarget.parentElement?.querySelector('input')?.focus();\n\t\t\t}}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst inputGroupButtonVariants = cva(\n\t'nt:flex nt:items-center nt:gap-2 nt:text-sm nt:shadow-none',\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\txs: 'nt:h-6 nt:gap-1 nt:rounded-[calc(var(--radius)-3px)] nt:px-1.5 nt:[&>svg:not([class*=size-])]:size-3.5',\n\t\t\t\tsm: 'nt:',\n\t\t\t\t'icon-xs':\n\t\t\t\t\t'nt:size-6 nt:rounded-[calc(var(--radius)-3px)] nt:p-0 nt:has-[>svg]:p-0',\n\t\t\t\t'icon-sm': 'nt:size-8 nt:p-0 nt:has-[>svg]:p-0'\n\t\t\t}\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: 'xs'\n\t\t}\n\t}\n);\n\nfunction InputGroupButton({\n\tclassName,\n\ttype = 'button',\n\tvariant = 'ghost',\n\tsize = 'xs',\n\t...props\n}: Omit<React.ComponentProps<typeof Button>, 'size'> &\n\tVariantProps<typeof inputGroupButtonVariants>) {\n\treturn (\n\t\t<Button\n\t\t\tclassName={cn(inputGroupButtonVariants({ size }), className)}\n\t\t\tdata-size={size}\n\t\t\ttype={type}\n\t\t\tvariant={variant}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction InputGroupText({ className, ...props }: React.ComponentProps<'span'>) {\n\treturn (\n\t\t<span\n\t\t\tclassName={cn(\n\t\t\t\t'nt:flex nt:items-center nt:gap-2 nt:text-sm nt:text-muted-foreground nt:[&_svg]:pointer-events-none nt:[&_svg:not([class*=size-])]:size-4',\n\t\t\t\tclassName\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction InputGroupInput({\n\tclassName,\n\t...props\n}: React.ComponentProps<'input'>) {\n\treturn (\n\t\t<Input\n\t\t\tclassName={cn(\n\t\t\t\t'nt:flex-1 nt:rounded-none nt:border-0 nt:bg-transparent nt:shadow-none nt:ring-0 nt:focus-visible:ring-0 nt:disabled:bg-transparent nt:aria-invalid:ring-0 nt:dark:bg-transparent nt:dark:disabled:bg-transparent',\n\t\t\t\tclassName\n\t\t\t)}\n\t\t\tdata-slot=\"input-group-control\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction InputGroupTextarea({\n\tclassName,\n\t...props\n}: React.ComponentProps<'textarea'>) {\n\treturn (\n\t\t<Textarea\n\t\t\tclassName={cn(\n\t\t\t\t'nt:flex-1 nt:resize-none nt:rounded-none nt:border-0 nt:bg-transparent nt:py-2 nt:shadow-none nt:ring-0 nt:focus-visible:ring-0 nt:disabled:bg-transparent nt:aria-invalid:ring-0 nt:dark:bg-transparent nt:dark:disabled:bg-transparent',\n\t\t\t\tclassName\n\t\t\t)}\n\t\t\tdata-slot=\"input-group-control\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport {\n\tInputGroup,\n\tInputGroupAddon,\n\tInputGroupButton,\n\tInputGroupText,\n\tInputGroupInput,\n\tInputGroupTextarea\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;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,iBAAiB;AAAA,EACzB;AAAA,EACA,OAAO;AAAA,EACP,UAAU;AAAA,EACV,OAAO;AAAA,EACP,GAAG;AACJ,GACgD;AAC/C,SACC;AAAA,IAAC;AAAA;AAAA,MACA,eAAW,iBAAG,yBAAyB,EAAE,KAAK,CAAC,GAAG,SAAS;AAAA,MAC3D,aAAW;AAAA,MACX;AAAA,MACA;AAAA,MACC,GAAG;AAAA;AAAA,EACL;AAEF;AAEA,SAAS,eAAe,EAAE,WAAW,GAAG,MAAM,GAAiC;AAC9E,SACC;AAAA,IAAC;AAAA;AAAA,MACA,eAAW;AAAA,QACV;AAAA,QACA;AAAA,MACD;AAAA,MACC,GAAG;AAAA;AAAA,EACL;AAEF;AAEA,SAAS,gBAAgB;AAAA,EACxB;AAAA,EACA,GAAG;AACJ,GAAkC;AACjC,SACC;AAAA,IAAC;AAAA;AAAA,MACA,eAAW;AAAA,QACV;AAAA,QACA;AAAA,MACD;AAAA,MACA,aAAU;AAAA,MACT,GAAG;AAAA;AAAA,EACL;AAEF;AAEA,SAAS,mBAAmB;AAAA,EAC3B;AAAA,EACA,GAAG;AACJ,GAAqC;AACpC,SACC;AAAA,IAAC;AAAA;AAAA,MACA,eAAW;AAAA,QACV;AAAA,QACA;AAAA,MACD;AAAA,MACA,aAAU;AAAA,MACT,GAAG;AAAA;AAAA,EACL;AAEF;","names":[]}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
2
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
|
+
import { VariantProps } from 'class-variance-authority';
|
|
4
|
+
import * as React from 'react';
|
|
5
|
+
import { Button } from './button.cjs';
|
|
6
|
+
|
|
7
|
+
declare function InputGroup({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
8
|
+
declare const inputGroupAddonVariants: (props?: ({
|
|
9
|
+
align?: "inline-start" | "inline-end" | "block-start" | "block-end" | null | undefined;
|
|
10
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
11
|
+
declare function InputGroupAddon({ className, align, ...props }: React.ComponentProps<'div'> & VariantProps<typeof inputGroupAddonVariants>): react_jsx_runtime.JSX.Element;
|
|
12
|
+
declare const inputGroupButtonVariants: (props?: ({
|
|
13
|
+
size?: "xs" | "sm" | "icon-xs" | "icon-sm" | null | undefined;
|
|
14
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
15
|
+
declare function InputGroupButton({ className, type, variant, size, ...props }: Omit<React.ComponentProps<typeof Button>, 'size'> & VariantProps<typeof inputGroupButtonVariants>): react_jsx_runtime.JSX.Element;
|
|
16
|
+
declare function InputGroupText({ className, ...props }: React.ComponentProps<'span'>): react_jsx_runtime.JSX.Element;
|
|
17
|
+
declare function InputGroupInput({ className, ...props }: React.ComponentProps<'input'>): react_jsx_runtime.JSX.Element;
|
|
18
|
+
declare function InputGroupTextarea({ className, ...props }: React.ComponentProps<'textarea'>): react_jsx_runtime.JSX.Element;
|
|
19
|
+
|
|
20
|
+
export { InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea };
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
2
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
|
+
import { VariantProps } from 'class-variance-authority';
|
|
4
|
+
import * as React from 'react';
|
|
5
|
+
import { Button } from './button.js';
|
|
6
|
+
|
|
7
|
+
declare function InputGroup({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
8
|
+
declare const inputGroupAddonVariants: (props?: ({
|
|
9
|
+
align?: "inline-start" | "inline-end" | "block-start" | "block-end" | null | undefined;
|
|
10
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
11
|
+
declare function InputGroupAddon({ className, align, ...props }: React.ComponentProps<'div'> & VariantProps<typeof inputGroupAddonVariants>): react_jsx_runtime.JSX.Element;
|
|
12
|
+
declare const inputGroupButtonVariants: (props?: ({
|
|
13
|
+
size?: "xs" | "sm" | "icon-xs" | "icon-sm" | null | undefined;
|
|
14
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
15
|
+
declare function InputGroupButton({ className, type, variant, size, ...props }: Omit<React.ComponentProps<typeof Button>, 'size'> & VariantProps<typeof inputGroupButtonVariants>): react_jsx_runtime.JSX.Element;
|
|
16
|
+
declare function InputGroupText({ className, ...props }: React.ComponentProps<'span'>): react_jsx_runtime.JSX.Element;
|
|
17
|
+
declare function InputGroupInput({ className, ...props }: React.ComponentProps<'input'>): react_jsx_runtime.JSX.Element;
|
|
18
|
+
declare function InputGroupTextarea({ className, ...props }: React.ComponentProps<'textarea'>): react_jsx_runtime.JSX.Element;
|
|
19
|
+
|
|
20
|
+
export { InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea };
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx } from "react/jsx-runtime";
|
|
3
|
+
import { cva } from "class-variance-authority";
|
|
4
|
+
import { Button } from "./button";
|
|
5
|
+
import { Input } from "./input";
|
|
6
|
+
import { Textarea } from "./textarea";
|
|
7
|
+
import { cn } from "../../lib/utils";
|
|
8
|
+
function InputGroup({ className, ...props }) {
|
|
9
|
+
return /* @__PURE__ */ jsx(
|
|
10
|
+
"div",
|
|
11
|
+
{
|
|
12
|
+
className: cn(
|
|
13
|
+
"nt:group/input-group nt:relative nt:flex nt:h-8 nt:w-full nt:min-w-0 nt:items-center nt:rounded-lg nt:border nt:border-input nt:transition-colors nt:outline-none nt:in-data-[slot=combobox-content]:focus-within:border-inherit nt:in-data-[slot=combobox-content]:focus-within:ring-0 nt:has-disabled:bg-input/50 nt:has-disabled:opacity-50 nt:has-[[data-slot=input-group-control]:focus-visible]:border-ring nt:has-[[data-slot=input-group-control]:focus-visible]:ring-3 nt:has-[[data-slot=input-group-control]:focus-visible]:ring-ring/50 nt:has-[[data-slot][aria-invalid=true]]:border-destructive nt:has-[[data-slot][aria-invalid=true]]:ring-3 nt:has-[[data-slot][aria-invalid=true]]:ring-destructive/20 nt:has-[>[data-align=block-end]]:h-auto nt:has-[>[data-align=block-end]]:flex-col nt:has-[>[data-align=block-start]]:h-auto nt:has-[>[data-align=block-start]]:flex-col nt:has-[>textarea]:h-auto nt:dark:bg-input/30 nt:dark:has-disabled:bg-input/80 nt:dark:has-[[data-slot][aria-invalid=true]]:ring-destructive/40 nt:has-[>[data-align=block-end]]:[&>input]:pt-3 nt:has-[>[data-align=block-start]]:[&>input]:pb-3 nt:has-[>[data-align=inline-end]]:[&>input]:pr-1.5 nt:has-[>[data-align=inline-start]]:[&>input]:pl-1.5",
|
|
14
|
+
className
|
|
15
|
+
),
|
|
16
|
+
"data-slot": "input-group",
|
|
17
|
+
role: "group",
|
|
18
|
+
...props
|
|
19
|
+
}
|
|
20
|
+
);
|
|
21
|
+
}
|
|
22
|
+
const inputGroupAddonVariants = cva(
|
|
23
|
+
"nt:flex nt:h-auto nt:cursor-text nt:items-center nt:justify-center nt:gap-2 nt:py-1.5 nt:text-sm nt:font-medium nt:text-muted-foreground nt:select-none nt:group-data-[disabled=true]/input-group:opacity-50 nt:[&>kbd]:rounded-[calc(var(--radius)-5px)] nt:[&>svg:not([class*=size-])]:size-4",
|
|
24
|
+
{
|
|
25
|
+
variants: {
|
|
26
|
+
align: {
|
|
27
|
+
"inline-start": "nt:order-first nt:pl-2 nt:has-[>button]:ml-[-0.3rem] nt:has-[>kbd]:ml-[-0.15rem]",
|
|
28
|
+
"inline-end": "nt:order-last nt:pr-2 nt:has-[>button]:mr-[-0.3rem] nt:has-[>kbd]:mr-[-0.15rem]",
|
|
29
|
+
"block-start": "nt:order-first nt:w-full nt:justify-start nt:px-2.5 nt:pt-2 nt:group-has-[>input]/input-group:pt-2 nt:[.border-b]:pb-2",
|
|
30
|
+
"block-end": "nt:order-last nt:w-full nt:justify-start nt:px-2.5 nt:pb-2 nt:group-has-[>input]/input-group:pb-2 nt:[.border-t]:pt-2"
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
defaultVariants: {
|
|
34
|
+
align: "inline-start"
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
);
|
|
38
|
+
function InputGroupAddon({
|
|
39
|
+
className,
|
|
40
|
+
align = "inline-start",
|
|
41
|
+
...props
|
|
42
|
+
}) {
|
|
43
|
+
return /* @__PURE__ */ jsx(
|
|
44
|
+
"div",
|
|
45
|
+
{
|
|
46
|
+
className: cn(inputGroupAddonVariants({ align }), className),
|
|
47
|
+
"data-align": align,
|
|
48
|
+
"data-slot": "input-group-addon",
|
|
49
|
+
role: "group",
|
|
50
|
+
onClick: (e) => {
|
|
51
|
+
if (e.target.closest("button")) {
|
|
52
|
+
return;
|
|
53
|
+
}
|
|
54
|
+
e.currentTarget.parentElement?.querySelector("input")?.focus();
|
|
55
|
+
},
|
|
56
|
+
...props
|
|
57
|
+
}
|
|
58
|
+
);
|
|
59
|
+
}
|
|
60
|
+
const inputGroupButtonVariants = cva(
|
|
61
|
+
"nt:flex nt:items-center nt:gap-2 nt:text-sm nt:shadow-none",
|
|
62
|
+
{
|
|
63
|
+
variants: {
|
|
64
|
+
size: {
|
|
65
|
+
xs: "nt:h-6 nt:gap-1 nt:rounded-[calc(var(--radius)-3px)] nt:px-1.5 nt:[&>svg:not([class*=size-])]:size-3.5",
|
|
66
|
+
sm: "nt:",
|
|
67
|
+
"icon-xs": "nt:size-6 nt:rounded-[calc(var(--radius)-3px)] nt:p-0 nt:has-[>svg]:p-0",
|
|
68
|
+
"icon-sm": "nt:size-8 nt:p-0 nt:has-[>svg]:p-0"
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
defaultVariants: {
|
|
72
|
+
size: "xs"
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
);
|
|
76
|
+
function InputGroupButton({
|
|
77
|
+
className,
|
|
78
|
+
type = "button",
|
|
79
|
+
variant = "ghost",
|
|
80
|
+
size = "xs",
|
|
81
|
+
...props
|
|
82
|
+
}) {
|
|
83
|
+
return /* @__PURE__ */ jsx(
|
|
84
|
+
Button,
|
|
85
|
+
{
|
|
86
|
+
className: cn(inputGroupButtonVariants({ size }), className),
|
|
87
|
+
"data-size": size,
|
|
88
|
+
type,
|
|
89
|
+
variant,
|
|
90
|
+
...props
|
|
91
|
+
}
|
|
92
|
+
);
|
|
93
|
+
}
|
|
94
|
+
function InputGroupText({ className, ...props }) {
|
|
95
|
+
return /* @__PURE__ */ jsx(
|
|
96
|
+
"span",
|
|
97
|
+
{
|
|
98
|
+
className: cn(
|
|
99
|
+
"nt:flex nt:items-center nt:gap-2 nt:text-sm nt:text-muted-foreground nt:[&_svg]:pointer-events-none nt:[&_svg:not([class*=size-])]:size-4",
|
|
100
|
+
className
|
|
101
|
+
),
|
|
102
|
+
...props
|
|
103
|
+
}
|
|
104
|
+
);
|
|
105
|
+
}
|
|
106
|
+
function InputGroupInput({
|
|
107
|
+
className,
|
|
108
|
+
...props
|
|
109
|
+
}) {
|
|
110
|
+
return /* @__PURE__ */ jsx(
|
|
111
|
+
Input,
|
|
112
|
+
{
|
|
113
|
+
className: cn(
|
|
114
|
+
"nt:flex-1 nt:rounded-none nt:border-0 nt:bg-transparent nt:shadow-none nt:ring-0 nt:focus-visible:ring-0 nt:disabled:bg-transparent nt:aria-invalid:ring-0 nt:dark:bg-transparent nt:dark:disabled:bg-transparent",
|
|
115
|
+
className
|
|
116
|
+
),
|
|
117
|
+
"data-slot": "input-group-control",
|
|
118
|
+
...props
|
|
119
|
+
}
|
|
120
|
+
);
|
|
121
|
+
}
|
|
122
|
+
function InputGroupTextarea({
|
|
123
|
+
className,
|
|
124
|
+
...props
|
|
125
|
+
}) {
|
|
126
|
+
return /* @__PURE__ */ jsx(
|
|
127
|
+
Textarea,
|
|
128
|
+
{
|
|
129
|
+
className: cn(
|
|
130
|
+
"nt:flex-1 nt:resize-none nt:rounded-none nt:border-0 nt:bg-transparent nt:py-2 nt:shadow-none nt:ring-0 nt:focus-visible:ring-0 nt:disabled:bg-transparent nt:aria-invalid:ring-0 nt:dark:bg-transparent nt:dark:disabled:bg-transparent",
|
|
131
|
+
className
|
|
132
|
+
),
|
|
133
|
+
"data-slot": "input-group-control",
|
|
134
|
+
...props
|
|
135
|
+
}
|
|
136
|
+
);
|
|
137
|
+
}
|
|
138
|
+
export {
|
|
139
|
+
InputGroup,
|
|
140
|
+
InputGroupAddon,
|
|
141
|
+
InputGroupButton,
|
|
142
|
+
InputGroupInput,
|
|
143
|
+
InputGroupText,
|
|
144
|
+
InputGroupTextarea
|
|
145
|
+
};
|
|
146
|
+
//# sourceMappingURL=input-group.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../src/components/ui/input-group.tsx"],"sourcesContent":["'use client';\n\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport * as React from 'react';\n\nimport { Button } from './button';\nimport { Input } from './input';\nimport { Textarea } from './textarea';\nimport { cn } from '../../lib/utils';\n\nfunction InputGroup({ className, ...props }: React.ComponentProps<'div'>) {\n\treturn (\n\t\t<div\n\t\t\tclassName={cn(\n\t\t\t\t'nt:group/input-group nt:relative nt:flex nt:h-8 nt:w-full nt:min-w-0 nt:items-center nt:rounded-lg nt:border nt:border-input nt:transition-colors nt:outline-none nt:in-data-[slot=combobox-content]:focus-within:border-inherit nt:in-data-[slot=combobox-content]:focus-within:ring-0 nt:has-disabled:bg-input/50 nt:has-disabled:opacity-50 nt:has-[[data-slot=input-group-control]:focus-visible]:border-ring nt:has-[[data-slot=input-group-control]:focus-visible]:ring-3 nt:has-[[data-slot=input-group-control]:focus-visible]:ring-ring/50 nt:has-[[data-slot][aria-invalid=true]]:border-destructive nt:has-[[data-slot][aria-invalid=true]]:ring-3 nt:has-[[data-slot][aria-invalid=true]]:ring-destructive/20 nt:has-[>[data-align=block-end]]:h-auto nt:has-[>[data-align=block-end]]:flex-col nt:has-[>[data-align=block-start]]:h-auto nt:has-[>[data-align=block-start]]:flex-col nt:has-[>textarea]:h-auto nt:dark:bg-input/30 nt:dark:has-disabled:bg-input/80 nt:dark:has-[[data-slot][aria-invalid=true]]:ring-destructive/40 nt:has-[>[data-align=block-end]]:[&>input]:pt-3 nt:has-[>[data-align=block-start]]:[&>input]:pb-3 nt:has-[>[data-align=inline-end]]:[&>input]:pr-1.5 nt:has-[>[data-align=inline-start]]:[&>input]:pl-1.5',\n\t\t\t\tclassName\n\t\t\t)}\n\t\t\tdata-slot=\"input-group\"\n\t\t\trole=\"group\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst inputGroupAddonVariants = cva(\n\t'nt:flex nt:h-auto nt:cursor-text nt:items-center nt:justify-center nt:gap-2 nt:py-1.5 nt:text-sm nt:font-medium nt:text-muted-foreground nt:select-none nt:group-data-[disabled=true]/input-group:opacity-50 nt:[&>kbd]:rounded-[calc(var(--radius)-5px)] nt:[&>svg:not([class*=size-])]:size-4',\n\t{\n\t\tvariants: {\n\t\t\talign: {\n\t\t\t\t'inline-start':\n\t\t\t\t\t'nt:order-first nt:pl-2 nt:has-[>button]:ml-[-0.3rem] nt:has-[>kbd]:ml-[-0.15rem]',\n\t\t\t\t'inline-end':\n\t\t\t\t\t'nt:order-last nt:pr-2 nt:has-[>button]:mr-[-0.3rem] nt:has-[>kbd]:mr-[-0.15rem]',\n\t\t\t\t'block-start':\n\t\t\t\t\t'nt:order-first nt:w-full nt:justify-start nt:px-2.5 nt:pt-2 nt:group-has-[>input]/input-group:pt-2 nt:[.border-b]:pb-2',\n\t\t\t\t'block-end':\n\t\t\t\t\t'nt:order-last nt:w-full nt:justify-start nt:px-2.5 nt:pb-2 nt:group-has-[>input]/input-group:pb-2 nt:[.border-t]:pt-2'\n\t\t\t}\n\t\t},\n\t\tdefaultVariants: {\n\t\t\talign: 'inline-start'\n\t\t}\n\t}\n);\n\nfunction InputGroupAddon({\n\tclassName,\n\talign = 'inline-start',\n\t...props\n}: React.ComponentProps<'div'> & VariantProps<typeof inputGroupAddonVariants>) {\n\treturn (\n\t\t<div\n\t\t\tclassName={cn(inputGroupAddonVariants({ align }), className)}\n\t\t\tdata-align={align}\n\t\t\tdata-slot=\"input-group-addon\"\n\t\t\trole=\"group\"\n\t\t\tonClick={(e) => {\n\t\t\t\tif ((e.target as HTMLElement).closest('button')) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\te.currentTarget.parentElement?.querySelector('input')?.focus();\n\t\t\t}}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nconst inputGroupButtonVariants = cva(\n\t'nt:flex nt:items-center nt:gap-2 nt:text-sm nt:shadow-none',\n\t{\n\t\tvariants: {\n\t\t\tsize: {\n\t\t\t\txs: 'nt:h-6 nt:gap-1 nt:rounded-[calc(var(--radius)-3px)] nt:px-1.5 nt:[&>svg:not([class*=size-])]:size-3.5',\n\t\t\t\tsm: 'nt:',\n\t\t\t\t'icon-xs':\n\t\t\t\t\t'nt:size-6 nt:rounded-[calc(var(--radius)-3px)] nt:p-0 nt:has-[>svg]:p-0',\n\t\t\t\t'icon-sm': 'nt:size-8 nt:p-0 nt:has-[>svg]:p-0'\n\t\t\t}\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: 'xs'\n\t\t}\n\t}\n);\n\nfunction InputGroupButton({\n\tclassName,\n\ttype = 'button',\n\tvariant = 'ghost',\n\tsize = 'xs',\n\t...props\n}: Omit<React.ComponentProps<typeof Button>, 'size'> &\n\tVariantProps<typeof inputGroupButtonVariants>) {\n\treturn (\n\t\t<Button\n\t\t\tclassName={cn(inputGroupButtonVariants({ size }), className)}\n\t\t\tdata-size={size}\n\t\t\ttype={type}\n\t\t\tvariant={variant}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction InputGroupText({ className, ...props }: React.ComponentProps<'span'>) {\n\treturn (\n\t\t<span\n\t\t\tclassName={cn(\n\t\t\t\t'nt:flex nt:items-center nt:gap-2 nt:text-sm nt:text-muted-foreground nt:[&_svg]:pointer-events-none nt:[&_svg:not([class*=size-])]:size-4',\n\t\t\t\tclassName\n\t\t\t)}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction InputGroupInput({\n\tclassName,\n\t...props\n}: React.ComponentProps<'input'>) {\n\treturn (\n\t\t<Input\n\t\t\tclassName={cn(\n\t\t\t\t'nt:flex-1 nt:rounded-none nt:border-0 nt:bg-transparent nt:shadow-none nt:ring-0 nt:focus-visible:ring-0 nt:disabled:bg-transparent nt:aria-invalid:ring-0 nt:dark:bg-transparent nt:dark:disabled:bg-transparent',\n\t\t\t\tclassName\n\t\t\t)}\n\t\t\tdata-slot=\"input-group-control\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction InputGroupTextarea({\n\tclassName,\n\t...props\n}: React.ComponentProps<'textarea'>) {\n\treturn (\n\t\t<Textarea\n\t\t\tclassName={cn(\n\t\t\t\t'nt:flex-1 nt:resize-none nt:rounded-none nt:border-0 nt:bg-transparent nt:py-2 nt:shadow-none nt:ring-0 nt:focus-visible:ring-0 nt:disabled:bg-transparent nt:aria-invalid:ring-0 nt:dark:bg-transparent nt:dark:disabled:bg-transparent',\n\t\t\t\tclassName\n\t\t\t)}\n\t\t\tdata-slot=\"input-group-control\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport {\n\tInputGroup,\n\tInputGroupAddon,\n\tInputGroupButton,\n\tInputGroupText,\n\tInputGroupInput,\n\tInputGroupTextarea\n};\n"],"mappings":";AAYE;AAVF,SAAS,WAA8B;AAGvC,SAAS,cAAc;AACvB,SAAS,aAAa;AACtB,SAAS,gBAAgB;AACzB,SAAS,UAAU;AAEnB,SAAS,WAAW,EAAE,WAAW,GAAG,MAAM,GAAgC;AACzE,SACC;AAAA,IAAC;AAAA;AAAA,MACA,WAAW;AAAA,QACV;AAAA,QACA;AAAA,MACD;AAAA,MACA,aAAU;AAAA,MACV,MAAK;AAAA,MACJ,GAAG;AAAA;A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,SACC;AAAA,IAAC;AAAA;AAAA,MACA,WAAW;AAAA,QACV;AAAA,QACA;AAAA,MACD;AAAA,MACC,GAAG;AAAA;AAAA,EACL;AAEF;AAEA,SAAS,gBAAgB;AAAA,EACxB;AAAA,EACA,GAAG;AACJ,GAAkC;AACjC,SACC;AAAA,IAAC;AAAA;AAAA,MACA,WAAW;AAAA,QACV;AAAA,QACA;AAAA,MACD;AAAA,MACA,aAAU;AAAA,MACT,GAAG;AAAA;AAAA,EACL;AAEF;AAEA,SAAS,mBAAmB;AAAA,EAC3B;AAAA,EACA,GAAG;AACJ,GAAqC;AACpC,SACC;AAAA,IAAC;AAAA;AAAA,MACA,WAAW;AAAA,QACV;AAAA,QACA;AAAA,MACD;AAAA,MACA,aAAU;AAAA,MACT,GAAG;AAAA;AAAA,EACL;AAEF;","names":[]}
|
|
@@ -28,7 +28,7 @@ function Input({ className, type, ...props }) {
|
|
|
28
28
|
"input",
|
|
29
29
|
{
|
|
30
30
|
className: (0, import_utils.cn)(
|
|
31
|
-
"nt:
|
|
31
|
+
"nt:h-8 nt:w-full nt:min-w-0 nt:rounded-lg nt:border nt:border-input nt:bg-transparent nt:px-2.5 nt:py-1 nt:text-base nt:transition-colors nt:outline-none nt:file:inline-flex nt:file:h-6 nt:file:border-0 nt:file:bg-transparent nt:file:text-sm nt:file:font-medium nt:file:text-foreground nt:placeholder:text-muted-foreground nt:focus-visible:border-ring nt:focus-visible:ring-3 nt:focus-visible:ring-ring/50 nt:disabled:pointer-events-none nt:disabled:cursor-not-allowed nt:disabled:bg-input/50 nt:disabled:opacity-50 nt:aria-invalid:border-destructive nt:aria-invalid:ring-3 nt:aria-invalid:ring-destructive/20 nt:md:text-sm nt:dark:bg-input/30 nt:dark:disabled:bg-input/80 nt:dark:aria-invalid:border-destructive/50 nt:dark:aria-invalid:ring-destructive/40",
|
|
32
32
|
className
|
|
33
33
|
),
|
|
34
34
|
"data-slot": "input",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/components/ui/input.tsx"],"sourcesContent":["import * as React from 'react';\n\nimport { cn } from '../../lib/utils';\n\nfunction Input({ className, type, ...props }: React.ComponentProps<'input'>) {\n\treturn (\n\t\t<input\n\t\t\tclassName={cn(\n\t\t\t\t'nt:
|
|
1
|
+
{"version":3,"sources":["../../../src/components/ui/input.tsx"],"sourcesContent":["import * as React from 'react';\n\nimport { cn } from '../../lib/utils';\n\nfunction Input({ className, type, ...props }: React.ComponentProps<'input'>) {\n\treturn (\n\t\t<input\n\t\t\tclassName={cn(\n\t\t\t\t'nt:h-8 nt:w-full nt:min-w-0 nt:rounded-lg nt:border nt:border-input nt:bg-transparent nt:px-2.5 nt:py-1 nt:text-base nt:transition-colors nt:outline-none nt:file:inline-flex nt:file:h-6 nt:file:border-0 nt:file:bg-transparent nt:file:text-sm nt:file:font-medium nt:file:text-foreground nt:placeholder:text-muted-foreground nt:focus-visible:border-ring nt:focus-visible:ring-3 nt:focus-visible:ring-ring/50 nt:disabled:pointer-events-none nt:disabled:cursor-not-allowed nt:disabled:bg-input/50 nt:disabled:opacity-50 nt:aria-invalid:border-destructive nt:aria-invalid:ring-3 nt:aria-invalid:ring-destructive/20 nt:md:text-sm nt:dark:bg-input/30 nt:dark:disabled:bg-input/80 nt:dark:aria-invalid:border-destructive/50 nt:dark:aria-invalid:ring-destructive/40',\n\t\t\t\tclassName\n\t\t\t)}\n\t\t\tdata-slot=\"input\"\n\t\t\ttype={type}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport { Input };\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAME;AAJF,mBAAmB;AAEnB,SAAS,MAAM,EAAE,WAAW,MAAM,GAAG,MAAM,GAAkC;AAC5E,SACC;AAAA,IAAC;AAAA;AAAA,MACA,eAAW;AAAA,QACV;AAAA,QACA;AAAA,MACD;AAAA,MACA,aAAU;AAAA,MACV;AAAA,MACC,GAAG;AAAA;AAAA,EACL;AAEF;","names":[]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import * as
|
|
2
|
+
import * as React from 'react';
|
|
3
3
|
|
|
4
|
-
declare function Input({ className, type, ...props }:
|
|
4
|
+
declare function Input({ className, type, ...props }: React.ComponentProps<'input'>): react_jsx_runtime.JSX.Element;
|
|
5
5
|
|
|
6
6
|
export { Input };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import * as
|
|
2
|
+
import * as React from 'react';
|
|
3
3
|
|
|
4
|
-
declare function Input({ className, type, ...props }:
|
|
4
|
+
declare function Input({ className, type, ...props }: React.ComponentProps<'input'>): react_jsx_runtime.JSX.Element;
|
|
5
5
|
|
|
6
6
|
export { Input };
|
|
@@ -5,7 +5,7 @@ function Input({ className, type, ...props }) {
|
|
|
5
5
|
"input",
|
|
6
6
|
{
|
|
7
7
|
className: cn(
|
|
8
|
-
"nt:
|
|
8
|
+
"nt:h-8 nt:w-full nt:min-w-0 nt:rounded-lg nt:border nt:border-input nt:bg-transparent nt:px-2.5 nt:py-1 nt:text-base nt:transition-colors nt:outline-none nt:file:inline-flex nt:file:h-6 nt:file:border-0 nt:file:bg-transparent nt:file:text-sm nt:file:font-medium nt:file:text-foreground nt:placeholder:text-muted-foreground nt:focus-visible:border-ring nt:focus-visible:ring-3 nt:focus-visible:ring-ring/50 nt:disabled:pointer-events-none nt:disabled:cursor-not-allowed nt:disabled:bg-input/50 nt:disabled:opacity-50 nt:aria-invalid:border-destructive nt:aria-invalid:ring-3 nt:aria-invalid:ring-destructive/20 nt:md:text-sm nt:dark:bg-input/30 nt:dark:disabled:bg-input/80 nt:dark:aria-invalid:border-destructive/50 nt:dark:aria-invalid:ring-destructive/40",
|
|
9
9
|
className
|
|
10
10
|
),
|
|
11
11
|
"data-slot": "input",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/components/ui/input.tsx"],"sourcesContent":["import * as React from 'react';\n\nimport { cn } from '../../lib/utils';\n\nfunction Input({ className, type, ...props }: React.ComponentProps<'input'>) {\n\treturn (\n\t\t<input\n\t\t\tclassName={cn(\n\t\t\t\t'nt:
|
|
1
|
+
{"version":3,"sources":["../../../src/components/ui/input.tsx"],"sourcesContent":["import * as React from 'react';\n\nimport { cn } from '../../lib/utils';\n\nfunction Input({ className, type, ...props }: React.ComponentProps<'input'>) {\n\treturn (\n\t\t<input\n\t\t\tclassName={cn(\n\t\t\t\t'nt:h-8 nt:w-full nt:min-w-0 nt:rounded-lg nt:border nt:border-input nt:bg-transparent nt:px-2.5 nt:py-1 nt:text-base nt:transition-colors nt:outline-none nt:file:inline-flex nt:file:h-6 nt:file:border-0 nt:file:bg-transparent nt:file:text-sm nt:file:font-medium nt:file:text-foreground nt:placeholder:text-muted-foreground nt:focus-visible:border-ring nt:focus-visible:ring-3 nt:focus-visible:ring-ring/50 nt:disabled:pointer-events-none nt:disabled:cursor-not-allowed nt:disabled:bg-input/50 nt:disabled:opacity-50 nt:aria-invalid:border-destructive nt:aria-invalid:ring-3 nt:aria-invalid:ring-destructive/20 nt:md:text-sm nt:dark:bg-input/30 nt:dark:disabled:bg-input/80 nt:dark:aria-invalid:border-destructive/50 nt:dark:aria-invalid:ring-destructive/40',\n\t\t\t\tclassName\n\t\t\t)}\n\t\t\tdata-slot=\"input\"\n\t\t\ttype={type}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport { Input };\n"],"mappings":"AAME;AAJF,SAAS,UAAU;AAEnB,SAAS,MAAM,EAAE,WAAW,MAAM,GAAG,MAAM,GAAkC;AAC5E,SACC;AAAA,IAAC;AAAA;AAAA,MACA,WAAW;AAAA,QACV;AAAA,QACA;AAAA,MACD;AAAA,MACA,aAAU;AAAA,MACV;AAAA,MACC,GAAG;AAAA;AAAA,EACL;AAEF;","names":[]}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
"use client";
|
|
2
3
|
var __defProp = Object.defineProperty;
|
|
3
4
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
@@ -21,6 +22,9 @@ __export(popover_exports, {
|
|
|
21
22
|
Popover: () => Popover,
|
|
22
23
|
PopoverAnchor: () => PopoverAnchor,
|
|
23
24
|
PopoverContent: () => PopoverContent,
|
|
25
|
+
PopoverDescription: () => PopoverDescription,
|
|
26
|
+
PopoverHeader: () => PopoverHeader,
|
|
27
|
+
PopoverTitle: () => PopoverTitle,
|
|
24
28
|
PopoverTrigger: () => PopoverTrigger
|
|
25
29
|
});
|
|
26
30
|
module.exports = __toCommonJS(popover_exports);
|
|
@@ -37,11 +41,6 @@ function PopoverTrigger({
|
|
|
37
41
|
}) {
|
|
38
42
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_radix_ui.Popover.Trigger, { "data-slot": "popover-trigger", ...props });
|
|
39
43
|
}
|
|
40
|
-
function PopoverAnchor({
|
|
41
|
-
...props
|
|
42
|
-
}) {
|
|
43
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_radix_ui.Popover.Anchor, { "data-slot": "popover-anchor", ...props });
|
|
44
|
-
}
|
|
45
44
|
function PopoverContent({
|
|
46
45
|
className,
|
|
47
46
|
align = "center",
|
|
@@ -53,7 +52,7 @@ function PopoverContent({
|
|
|
53
52
|
{
|
|
54
53
|
align,
|
|
55
54
|
className: (0, import_utils.cn)(
|
|
56
|
-
"nt:z-50 nt:w-72 nt:origin-(--radix-popover-content-transform-origin) nt:rounded-lg nt:bg-popover nt:p-
|
|
55
|
+
"nt:z-50 nt:flex nt:w-72 nt:origin-(--radix-popover-content-transform-origin) nt:flex-col nt:gap-2.5 nt:rounded-lg nt:bg-popover nt:p-2.5 nt:text-sm nt:text-popover-foreground nt:shadow-md nt:ring-1 nt:ring-foreground/10 nt:outline-hidden nt:duration-100 nt:data-[side=bottom]:slide-in-from-top-2 nt:data-[side=left]:slide-in-from-right-2 nt:data-[side=right]:slide-in-from-left-2 nt:data-[side=top]:slide-in-from-bottom-2 nt:data-open:animate-in nt:data-open:fade-in-0 nt:data-open:zoom-in-95 nt:data-closed:animate-out nt:data-closed:fade-out-0 nt:data-closed:zoom-out-95",
|
|
57
56
|
className
|
|
58
57
|
),
|
|
59
58
|
"data-slot": "popover-content",
|
|
@@ -62,11 +61,52 @@ function PopoverContent({
|
|
|
62
61
|
}
|
|
63
62
|
) });
|
|
64
63
|
}
|
|
64
|
+
function PopoverAnchor({
|
|
65
|
+
...props
|
|
66
|
+
}) {
|
|
67
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_radix_ui.Popover.Anchor, { "data-slot": "popover-anchor", ...props });
|
|
68
|
+
}
|
|
69
|
+
function PopoverHeader({ className, ...props }) {
|
|
70
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
71
|
+
"div",
|
|
72
|
+
{
|
|
73
|
+
className: (0, import_utils.cn)("nt:flex nt:flex-col nt:gap-0.5 nt:text-sm", className),
|
|
74
|
+
"data-slot": "popover-header",
|
|
75
|
+
...props
|
|
76
|
+
}
|
|
77
|
+
);
|
|
78
|
+
}
|
|
79
|
+
function PopoverTitle({ className, ...props }) {
|
|
80
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
81
|
+
"div",
|
|
82
|
+
{
|
|
83
|
+
className: (0, import_utils.cn)("nt:font-medium", className),
|
|
84
|
+
"data-slot": "popover-title",
|
|
85
|
+
...props
|
|
86
|
+
}
|
|
87
|
+
);
|
|
88
|
+
}
|
|
89
|
+
function PopoverDescription({
|
|
90
|
+
className,
|
|
91
|
+
...props
|
|
92
|
+
}) {
|
|
93
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
94
|
+
"p",
|
|
95
|
+
{
|
|
96
|
+
className: (0, import_utils.cn)("nt:text-muted-foreground", className),
|
|
97
|
+
"data-slot": "popover-description",
|
|
98
|
+
...props
|
|
99
|
+
}
|
|
100
|
+
);
|
|
101
|
+
}
|
|
65
102
|
// Annotate the CommonJS export names for ESM import in node:
|
|
66
103
|
0 && (module.exports = {
|
|
67
104
|
Popover,
|
|
68
105
|
PopoverAnchor,
|
|
69
106
|
PopoverContent,
|
|
107
|
+
PopoverDescription,
|
|
108
|
+
PopoverHeader,
|
|
109
|
+
PopoverTitle,
|
|
70
110
|
PopoverTrigger
|
|
71
111
|
});
|
|
72
112
|
//# sourceMappingURL=popover.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/components/ui/popover.tsx"],"sourcesContent":["
|
|
1
|
+
{"version":3,"sources":["../../../src/components/ui/popover.tsx"],"sourcesContent":["'use client';\n\nimport { Popover as PopoverPrimitive } from 'radix-ui';\nimport * as React from 'react';\n\nimport { cn } from '../../lib/utils';\n\nfunction Popover({\n\t...props\n}: React.ComponentProps<typeof PopoverPrimitive.Root>) {\n\treturn <PopoverPrimitive.Root data-slot=\"popover\" {...props} />;\n}\n\nfunction PopoverTrigger({\n\t...props\n}: React.ComponentProps<typeof PopoverPrimitive.Trigger>) {\n\treturn <PopoverPrimitive.Trigger data-slot=\"popover-trigger\" {...props} />;\n}\n\nfunction PopoverContent({\n\tclassName,\n\talign = 'center',\n\tsideOffset = 4,\n\t...props\n}: React.ComponentProps<typeof PopoverPrimitive.Content>) {\n\treturn (\n\t\t<PopoverPrimitive.Portal>\n\t\t\t<PopoverPrimitive.Content\n\t\t\t\talign={align}\n\t\t\t\tclassName={cn(\n\t\t\t\t\t'nt:z-50 nt:flex nt:w-72 nt:origin-(--radix-popover-content-transform-origin) nt:flex-col nt:gap-2.5 nt:rounded-lg nt:bg-popover nt:p-2.5 nt:text-sm nt:text-popover-foreground nt:shadow-md nt:ring-1 nt:ring-foreground/10 nt:outline-hidden nt:duration-100 nt:data-[side=bottom]:slide-in-from-top-2 nt:data-[side=left]:slide-in-from-right-2 nt:data-[side=right]:slide-in-from-left-2 nt:data-[side=top]:slide-in-from-bottom-2 nt:data-open:animate-in nt:data-open:fade-in-0 nt:data-open:zoom-in-95 nt:data-closed:animate-out nt:data-closed:fade-out-0 nt:data-closed:zoom-out-95',\n\t\t\t\t\tclassName\n\t\t\t\t)}\n\t\t\t\tdata-slot=\"popover-content\"\n\t\t\t\tsideOffset={sideOffset}\n\t\t\t\t{...props}\n\t\t\t/>\n\t\t</PopoverPrimitive.Portal>\n\t);\n}\n\nfunction PopoverAnchor({\n\t...props\n}: React.ComponentProps<typeof PopoverPrimitive.Anchor>) {\n\treturn <PopoverPrimitive.Anchor data-slot=\"popover-anchor\" {...props} />;\n}\n\nfunction PopoverHeader({ className, ...props }: React.ComponentProps<'div'>) {\n\treturn (\n\t\t<div\n\t\t\tclassName={cn('nt:flex nt:flex-col nt:gap-0.5 nt:text-sm', className)}\n\t\t\tdata-slot=\"popover-header\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction PopoverTitle({ className, ...props }: React.ComponentProps<'h2'>) {\n\treturn (\n\t\t<div\n\t\t\tclassName={cn('nt:font-medium', className)}\n\t\t\tdata-slot=\"popover-title\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction PopoverDescription({\n\tclassName,\n\t...props\n}: React.ComponentProps<'p'>) {\n\treturn (\n\t\t<p\n\t\t\tclassName={cn('nt:text-muted-foreground', className)}\n\t\t\tdata-slot=\"popover-description\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport {\n\tPopover,\n\tPopoverAnchor,\n\tPopoverContent,\n\tPopoverDescription,\n\tPopoverHeader,\n\tPopoverTitle,\n\tPopoverTrigger\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAUQ;AARR,sBAA4C;AAG5C,mBAAmB;AAEnB,SAAS,QAAQ;AAAA,EAChB,GAAG;AACJ,G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 -1,10 +1,13 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { Popover as Popover$1 } from 'radix-ui';
|
|
3
|
-
import * as
|
|
3
|
+
import * as React from 'react';
|
|
4
4
|
|
|
5
|
-
declare function Popover({ ...props }:
|
|
6
|
-
declare function PopoverTrigger({ ...props }:
|
|
7
|
-
declare function
|
|
8
|
-
declare function
|
|
5
|
+
declare function Popover({ ...props }: React.ComponentProps<typeof Popover$1.Root>): react_jsx_runtime.JSX.Element;
|
|
6
|
+
declare function PopoverTrigger({ ...props }: React.ComponentProps<typeof Popover$1.Trigger>): react_jsx_runtime.JSX.Element;
|
|
7
|
+
declare function PopoverContent({ className, align, sideOffset, ...props }: React.ComponentProps<typeof Popover$1.Content>): react_jsx_runtime.JSX.Element;
|
|
8
|
+
declare function PopoverAnchor({ ...props }: React.ComponentProps<typeof Popover$1.Anchor>): react_jsx_runtime.JSX.Element;
|
|
9
|
+
declare function PopoverHeader({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
10
|
+
declare function PopoverTitle({ className, ...props }: React.ComponentProps<'h2'>): react_jsx_runtime.JSX.Element;
|
|
11
|
+
declare function PopoverDescription({ className, ...props }: React.ComponentProps<'p'>): react_jsx_runtime.JSX.Element;
|
|
9
12
|
|
|
10
|
-
export { Popover, PopoverAnchor, PopoverContent, PopoverTrigger };
|
|
13
|
+
export { Popover, PopoverAnchor, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger };
|
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { Popover as Popover$1 } from 'radix-ui';
|
|
3
|
-
import * as
|
|
3
|
+
import * as React from 'react';
|
|
4
4
|
|
|
5
|
-
declare function Popover({ ...props }:
|
|
6
|
-
declare function PopoverTrigger({ ...props }:
|
|
7
|
-
declare function
|
|
8
|
-
declare function
|
|
5
|
+
declare function Popover({ ...props }: React.ComponentProps<typeof Popover$1.Root>): react_jsx_runtime.JSX.Element;
|
|
6
|
+
declare function PopoverTrigger({ ...props }: React.ComponentProps<typeof Popover$1.Trigger>): react_jsx_runtime.JSX.Element;
|
|
7
|
+
declare function PopoverContent({ className, align, sideOffset, ...props }: React.ComponentProps<typeof Popover$1.Content>): react_jsx_runtime.JSX.Element;
|
|
8
|
+
declare function PopoverAnchor({ ...props }: React.ComponentProps<typeof Popover$1.Anchor>): react_jsx_runtime.JSX.Element;
|
|
9
|
+
declare function PopoverHeader({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
10
|
+
declare function PopoverTitle({ className, ...props }: React.ComponentProps<'h2'>): react_jsx_runtime.JSX.Element;
|
|
11
|
+
declare function PopoverDescription({ className, ...props }: React.ComponentProps<'p'>): react_jsx_runtime.JSX.Element;
|
|
9
12
|
|
|
10
|
-
export { Popover, PopoverAnchor, PopoverContent, PopoverTrigger };
|
|
13
|
+
export { Popover, PopoverAnchor, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger };
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
"use client";
|
|
1
2
|
import { jsx } from "react/jsx-runtime";
|
|
2
3
|
import { Popover as PopoverPrimitive } from "radix-ui";
|
|
3
4
|
import { cn } from "../../lib/utils";
|
|
@@ -11,11 +12,6 @@ function PopoverTrigger({
|
|
|
11
12
|
}) {
|
|
12
13
|
return /* @__PURE__ */ jsx(PopoverPrimitive.Trigger, { "data-slot": "popover-trigger", ...props });
|
|
13
14
|
}
|
|
14
|
-
function PopoverAnchor({
|
|
15
|
-
...props
|
|
16
|
-
}) {
|
|
17
|
-
return /* @__PURE__ */ jsx(PopoverPrimitive.Anchor, { "data-slot": "popover-anchor", ...props });
|
|
18
|
-
}
|
|
19
15
|
function PopoverContent({
|
|
20
16
|
className,
|
|
21
17
|
align = "center",
|
|
@@ -27,7 +23,7 @@ function PopoverContent({
|
|
|
27
23
|
{
|
|
28
24
|
align,
|
|
29
25
|
className: cn(
|
|
30
|
-
"nt:z-50 nt:w-72 nt:origin-(--radix-popover-content-transform-origin) nt:rounded-lg nt:bg-popover nt:p-
|
|
26
|
+
"nt:z-50 nt:flex nt:w-72 nt:origin-(--radix-popover-content-transform-origin) nt:flex-col nt:gap-2.5 nt:rounded-lg nt:bg-popover nt:p-2.5 nt:text-sm nt:text-popover-foreground nt:shadow-md nt:ring-1 nt:ring-foreground/10 nt:outline-hidden nt:duration-100 nt:data-[side=bottom]:slide-in-from-top-2 nt:data-[side=left]:slide-in-from-right-2 nt:data-[side=right]:slide-in-from-left-2 nt:data-[side=top]:slide-in-from-bottom-2 nt:data-open:animate-in nt:data-open:fade-in-0 nt:data-open:zoom-in-95 nt:data-closed:animate-out nt:data-closed:fade-out-0 nt:data-closed:zoom-out-95",
|
|
31
27
|
className
|
|
32
28
|
),
|
|
33
29
|
"data-slot": "popover-content",
|
|
@@ -36,10 +32,51 @@ function PopoverContent({
|
|
|
36
32
|
}
|
|
37
33
|
) });
|
|
38
34
|
}
|
|
35
|
+
function PopoverAnchor({
|
|
36
|
+
...props
|
|
37
|
+
}) {
|
|
38
|
+
return /* @__PURE__ */ jsx(PopoverPrimitive.Anchor, { "data-slot": "popover-anchor", ...props });
|
|
39
|
+
}
|
|
40
|
+
function PopoverHeader({ className, ...props }) {
|
|
41
|
+
return /* @__PURE__ */ jsx(
|
|
42
|
+
"div",
|
|
43
|
+
{
|
|
44
|
+
className: cn("nt:flex nt:flex-col nt:gap-0.5 nt:text-sm", className),
|
|
45
|
+
"data-slot": "popover-header",
|
|
46
|
+
...props
|
|
47
|
+
}
|
|
48
|
+
);
|
|
49
|
+
}
|
|
50
|
+
function PopoverTitle({ className, ...props }) {
|
|
51
|
+
return /* @__PURE__ */ jsx(
|
|
52
|
+
"div",
|
|
53
|
+
{
|
|
54
|
+
className: cn("nt:font-medium", className),
|
|
55
|
+
"data-slot": "popover-title",
|
|
56
|
+
...props
|
|
57
|
+
}
|
|
58
|
+
);
|
|
59
|
+
}
|
|
60
|
+
function PopoverDescription({
|
|
61
|
+
className,
|
|
62
|
+
...props
|
|
63
|
+
}) {
|
|
64
|
+
return /* @__PURE__ */ jsx(
|
|
65
|
+
"p",
|
|
66
|
+
{
|
|
67
|
+
className: cn("nt:text-muted-foreground", className),
|
|
68
|
+
"data-slot": "popover-description",
|
|
69
|
+
...props
|
|
70
|
+
}
|
|
71
|
+
);
|
|
72
|
+
}
|
|
39
73
|
export {
|
|
40
74
|
Popover,
|
|
41
75
|
PopoverAnchor,
|
|
42
76
|
PopoverContent,
|
|
77
|
+
PopoverDescription,
|
|
78
|
+
PopoverHeader,
|
|
79
|
+
PopoverTitle,
|
|
43
80
|
PopoverTrigger
|
|
44
81
|
};
|
|
45
82
|
//# sourceMappingURL=popover.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/components/ui/popover.tsx"],"sourcesContent":["
|
|
1
|
+
{"version":3,"sources":["../../../src/components/ui/popover.tsx"],"sourcesContent":["'use client';\n\nimport { Popover as PopoverPrimitive } from 'radix-ui';\nimport * as React from 'react';\n\nimport { cn } from '../../lib/utils';\n\nfunction Popover({\n\t...props\n}: React.ComponentProps<typeof PopoverPrimitive.Root>) {\n\treturn <PopoverPrimitive.Root data-slot=\"popover\" {...props} />;\n}\n\nfunction PopoverTrigger({\n\t...props\n}: React.ComponentProps<typeof PopoverPrimitive.Trigger>) {\n\treturn <PopoverPrimitive.Trigger data-slot=\"popover-trigger\" {...props} />;\n}\n\nfunction PopoverContent({\n\tclassName,\n\talign = 'center',\n\tsideOffset = 4,\n\t...props\n}: React.ComponentProps<typeof PopoverPrimitive.Content>) {\n\treturn (\n\t\t<PopoverPrimitive.Portal>\n\t\t\t<PopoverPrimitive.Content\n\t\t\t\talign={align}\n\t\t\t\tclassName={cn(\n\t\t\t\t\t'nt:z-50 nt:flex nt:w-72 nt:origin-(--radix-popover-content-transform-origin) nt:flex-col nt:gap-2.5 nt:rounded-lg nt:bg-popover nt:p-2.5 nt:text-sm nt:text-popover-foreground nt:shadow-md nt:ring-1 nt:ring-foreground/10 nt:outline-hidden nt:duration-100 nt:data-[side=bottom]:slide-in-from-top-2 nt:data-[side=left]:slide-in-from-right-2 nt:data-[side=right]:slide-in-from-left-2 nt:data-[side=top]:slide-in-from-bottom-2 nt:data-open:animate-in nt:data-open:fade-in-0 nt:data-open:zoom-in-95 nt:data-closed:animate-out nt:data-closed:fade-out-0 nt:data-closed:zoom-out-95',\n\t\t\t\t\tclassName\n\t\t\t\t)}\n\t\t\t\tdata-slot=\"popover-content\"\n\t\t\t\tsideOffset={sideOffset}\n\t\t\t\t{...props}\n\t\t\t/>\n\t\t</PopoverPrimitive.Portal>\n\t);\n}\n\nfunction PopoverAnchor({\n\t...props\n}: React.ComponentProps<typeof PopoverPrimitive.Anchor>) {\n\treturn <PopoverPrimitive.Anchor data-slot=\"popover-anchor\" {...props} />;\n}\n\nfunction PopoverHeader({ className, ...props }: React.ComponentProps<'div'>) {\n\treturn (\n\t\t<div\n\t\t\tclassName={cn('nt:flex nt:flex-col nt:gap-0.5 nt:text-sm', className)}\n\t\t\tdata-slot=\"popover-header\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction PopoverTitle({ className, ...props }: React.ComponentProps<'h2'>) {\n\treturn (\n\t\t<div\n\t\t\tclassName={cn('nt:font-medium', className)}\n\t\t\tdata-slot=\"popover-title\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nfunction PopoverDescription({\n\tclassName,\n\t...props\n}: React.ComponentProps<'p'>) {\n\treturn (\n\t\t<p\n\t\t\tclassName={cn('nt:text-muted-foreground', className)}\n\t\t\tdata-slot=\"popover-description\"\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport {\n\tPopover,\n\tPopoverAnchor,\n\tPopoverContent,\n\tPopoverDescription,\n\tPopoverHeader,\n\tPopoverTitle,\n\tPopoverTrigger\n};\n"],"mappings":";AAUQ;AAR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AA;AAAA,EACL;AAEF;","names":[]}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
"use client";
|
|
2
3
|
var __defProp = Object.defineProperty;
|
|
3
4
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
@@ -34,7 +35,7 @@ function Separator({
|
|
|
34
35
|
import_radix_ui.Separator.Root,
|
|
35
36
|
{
|
|
36
37
|
className: (0, import_utils.cn)(
|
|
37
|
-
"nt:shrink-0 nt:bg-border nt:data-
|
|
38
|
+
"nt:shrink-0 nt:bg-border nt:data-horizontal:h-px nt:data-horizontal:w-full nt:data-vertical:w-px nt:data-vertical:self-stretch",
|
|
38
39
|
className
|
|
39
40
|
),
|
|
40
41
|
"data-slot": "separator",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/components/ui/separator.tsx"],"sourcesContent":["
|
|
1
|
+
{"version":3,"sources":["../../../src/components/ui/separator.tsx"],"sourcesContent":["'use client';\n\nimport { Separator as SeparatorPrimitive } from 'radix-ui';\nimport * as React from 'react';\n\nimport { cn } from '../../lib/utils';\n\nfunction Separator({\n\tclassName,\n\torientation = 'horizontal',\n\tdecorative = true,\n\t...props\n}: React.ComponentProps<typeof SeparatorPrimitive.Root>) {\n\treturn (\n\t\t<SeparatorPrimitive.Root\n\t\t\tclassName={cn(\n\t\t\t\t'nt:shrink-0 nt:bg-border nt:data-horizontal:h-px nt:data-horizontal:w-full nt:data-vertical:w-px nt:data-vertical:self-stretch',\n\t\t\t\tclassName\n\t\t\t)}\n\t\t\tdata-slot=\"separator\"\n\t\t\tdecorative={decorative}\n\t\t\torientation={orientation}\n\t\t\t{...props}\n\t\t/>\n\t);\n}\n\nexport { Separator };\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAcE;AAZF,sBAAgD;AAGhD,mBAAmB;AAEnB,SAAS,UAAU;AAAA,EAClB;AAAA,EACA,cAAc;AAAA,EACd,aAAa;AAAA,EACb,GAAG;AACJ,GAAyD;AACxD,SACC;AAAA,IAAC,gBAAAA,UAAmB;AAAA,IAAnB;AAAA,MACA,eAAW;AAAA,QACV;AAAA,QACA;AAAA,MACD;AAAA,MACA,aAAU;AAAA,MACV;AAAA,MACA;AAAA,MACC,GAAG;AAAA;AAAA,EACL;AAEF;","names":["SeparatorPrimitive"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { Separator as Separator$1 } from 'radix-ui';
|
|
3
|
-
import * as
|
|
3
|
+
import * as React from 'react';
|
|
4
4
|
|
|
5
|
-
declare function Separator({ className, orientation, decorative, ...props }:
|
|
5
|
+
declare function Separator({ className, orientation, decorative, ...props }: React.ComponentProps<typeof Separator$1.Root>): react_jsx_runtime.JSX.Element;
|
|
6
6
|
|
|
7
7
|
export { Separator };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { Separator as Separator$1 } from 'radix-ui';
|
|
3
|
-
import * as
|
|
3
|
+
import * as React from 'react';
|
|
4
4
|
|
|
5
|
-
declare function Separator({ className, orientation, decorative, ...props }:
|
|
5
|
+
declare function Separator({ className, orientation, decorative, ...props }: React.ComponentProps<typeof Separator$1.Root>): react_jsx_runtime.JSX.Element;
|
|
6
6
|
|
|
7
7
|
export { Separator };
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
"use client";
|
|
1
2
|
import { jsx } from "react/jsx-runtime";
|
|
2
3
|
import { Separator as SeparatorPrimitive } from "radix-ui";
|
|
3
4
|
import { cn } from "../../lib/utils";
|
|
@@ -11,7 +12,7 @@ function Separator({
|
|
|
11
12
|
SeparatorPrimitive.Root,
|
|
12
13
|
{
|
|
13
14
|
className: cn(
|
|
14
|
-
"nt:shrink-0 nt:bg-border nt:data-
|
|
15
|
+
"nt:shrink-0 nt:bg-border nt:data-horizontal:h-px nt:data-horizontal:w-full nt:data-vertical:w-px nt:data-vertical:self-stretch",
|
|
15
16
|
className
|
|
16
17
|
),
|
|
17
18
|
"data-slot": "separator",
|