@radui/ui 0.0.47 → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +12 -4
- package/dist/components/Accordion.d.ts +23 -40
- package/dist/components/Accordion.js +1 -1
- package/dist/components/AlertDialog.d.ts +79 -25
- package/dist/components/AlertDialog.js +1 -1
- package/dist/components/AspectRatio.d.ts +6 -9
- package/dist/components/AspectRatio.js +1 -1
- package/dist/components/Avatar.d.ts +9 -17
- package/dist/components/Avatar.js +1 -1
- package/dist/components/AvatarGroup.d.ts +21 -17
- package/dist/components/AvatarGroup.js +1 -1
- package/dist/components/AvatarPrimitiveFallback-BV0bK5Qg.js +1 -0
- package/dist/components/Badge.d.ts +7 -5
- package/dist/components/Badge.js +1 -1
- package/dist/components/BlockQuote.d.ts +7 -8
- package/dist/components/BlockQuote.js +1 -1
- package/dist/components/Button.d.ts +15 -6
- package/dist/components/Button.js +1 -1
- package/dist/components/Callout.d.ts +24 -29
- package/dist/components/Callout.js +1 -1
- package/dist/components/Card.d.ts +7 -15
- package/dist/components/Card.js +1 -1
- package/dist/components/Checkbox.d.ts +27 -17
- package/dist/components/Checkbox.js +1 -1
- package/dist/components/CheckboxCards.d.ts +28 -31
- package/dist/components/CheckboxCards.js +1 -1
- package/dist/components/CheckboxGroup.d.ts +31 -31
- package/dist/components/CheckboxGroup.js +1 -1
- package/dist/components/CheckboxGroupPrimitive-DrGqSxi3.js +1 -0
- package/dist/components/Code.d.ts +7 -3
- package/dist/components/Code.js +1 -1
- package/dist/components/Collapsible.d.ts +16 -22
- package/dist/components/Collapsible.js +1 -1
- package/dist/components/ContextMenu.d.ts +78 -35
- package/dist/components/ContextMenu.js +1 -1
- package/dist/components/DataList.d.ts +9 -17
- package/dist/components/DataList.js +1 -1
- package/dist/components/Dialog.d.ts +78 -32
- package/dist/components/Dialog.js +1 -1
- package/dist/components/Disclosure.d.ts +20 -26
- package/dist/components/Disclosure.js +1 -1
- package/dist/components/DropdownMenu.d.ts +78 -35
- package/dist/components/DropdownMenu.js +1 -1
- package/dist/components/Em.d.ts +5 -9
- package/dist/components/Em.js +1 -1
- package/dist/components/Heading.d.ts +7 -275
- package/dist/components/Heading.js +1 -1
- package/dist/components/HoverCard.d.ts +34 -33
- package/dist/components/HoverCard.js +1 -1
- package/dist/components/Kbd.d.ts +6 -8
- package/dist/components/Kbd.js +1 -1
- package/dist/components/Link.d.ts +6 -12
- package/dist/components/Link.js +1 -1
- package/dist/components/MenuPrimitive-DuUPySFO.js +1 -0
- package/dist/components/Menubar.d.ts +68 -45
- package/dist/components/Menubar.js +1 -1
- package/dist/components/Minimap.d.ts +48 -0
- package/dist/components/Minimap.js +1 -0
- package/dist/components/NavigationMenu.d.ts +35 -0
- package/dist/components/NavigationMenu.js +1 -0
- package/dist/components/NumberField.d.ts +17 -37
- package/dist/components/NumberField.js +1 -1
- package/dist/components/Progress.d.ts +22 -19
- package/dist/components/Progress.js +1 -1
- package/dist/components/Quote.d.ts +4 -8
- package/dist/components/Quote.js +1 -1
- package/dist/components/Radio.d.ts +11 -4
- package/dist/components/Radio.js +1 -1
- package/dist/components/RadioCards.d.ts +32 -35
- package/dist/components/RadioCards.js +1 -1
- package/dist/components/RadioGroup.d.ts +34 -37
- package/dist/components/RadioGroup.js +1 -1
- package/dist/components/RadioGroupPrimitive-D9grAL7G.js +1 -0
- package/dist/components/ScrollArea.d.ts +22 -14
- package/dist/components/ScrollArea.js +1 -1
- package/dist/components/Select.d.ts +69 -16
- package/dist/components/Select.js +1 -1
- package/dist/components/Separator.d.ts +5 -9
- package/dist/components/Separator.js +1 -1
- package/dist/components/Skeleton.d.ts +8 -7
- package/dist/components/Skeleton.js +1 -1
- package/dist/components/Slider.d.ts +78 -26
- package/dist/components/Slider.js +1 -1
- package/dist/components/Splitter.d.ts +57 -0
- package/dist/components/Splitter.js +1 -0
- package/dist/components/Steps.d.ts +38 -0
- package/dist/components/Steps.js +1 -0
- package/dist/components/Strong.d.ts +6 -7
- package/dist/components/Strong.js +1 -1
- package/dist/components/Switch.d.ts +28 -6
- package/dist/components/Switch.js +1 -1
- package/dist/components/TabNav.d.ts +15 -25
- package/dist/components/TabNav.js +1 -1
- package/dist/components/Table.d.ts +23 -27
- package/dist/components/Table.js +1 -1
- package/dist/components/Tabs.d.ts +23 -44
- package/dist/components/Tabs.js +1 -1
- package/dist/components/Text.d.ts +8 -274
- package/dist/components/Text.js +1 -1
- package/dist/components/TextArea.d.ts +9 -14
- package/dist/components/TextArea.js +1 -1
- package/dist/components/Theme.d.ts +9 -5
- package/dist/components/Theme.js +1 -1
- package/dist/components/Toggle.d.ts +8 -19
- package/dist/components/Toggle.js +1 -1
- package/dist/components/ToggleGroup.d.ts +55 -34
- package/dist/components/ToggleGroup.js +1 -1
- package/dist/components/Tooltip.d.ts +31 -18
- package/dist/components/Tooltip.js +1 -1
- package/dist/components/Tree.d.ts +31 -14
- package/dist/components/Tree.js +1 -1
- package/dist/components/VisuallyHidden.d.ts +6 -10
- package/dist/components/VisuallyHidden.js +1 -1
- package/dist/components/{floating-ui.react-jh3caJnc.js → floating-ui.react-CLbXmKZY.js} +2 -2
- package/dist/components/index-BRmT6kl7.js +1 -0
- package/dist/components/index-Bf4LVEjJ.js +1 -0
- package/dist/components/index-BtoPzkH9.js +1 -0
- package/dist/components/index-DBZNt4Em.js +1 -0
- package/dist/components/index-Dc5Cm9z0.js +1 -0
- package/dist/components/index-Di6TooPD.js +1 -0
- package/dist/components/{index-8D8A0ALD.js → index-DnCiOYxZ.js} +1 -1
- package/dist/components/index-XqbKa2D2.js +1 -0
- package/dist/components/index-YgKcfT__.js +1 -0
- package/dist/themes/default.css +1 -1
- package/package.json +21 -3
- package/dist/components/AvatarPrimitiveFallback-CSD78PQE.js +0 -1
- package/dist/components/CheckboxGroupPrimitive-PcT11bev.js +0 -1
- package/dist/components/MenuPrimitive-M690K2sI.js +0 -1
- package/dist/components/RadioGroupPrimitive-CUgW2PyL.js +0 -1
- package/dist/components/index-BNg6qXF-.js +0 -1
- package/dist/components/index-CaFVBHZz.js +0 -1
- package/dist/components/index-CyT0hgZn.js +0 -1
- package/dist/components/index-DAboJYKJ.js +0 -1
- package/dist/components/index-DIw4zyNG.js +0 -1
- package/dist/components/index-DpUtikes.js +0 -1
- package/dist/components/index-ZMIfeyHL.js +0 -1
- package/dist/components/setupTests.d.ts +0 -3
package/README.md
CHANGED
|
@@ -2,17 +2,25 @@
|
|
|
2
2
|
|
|
3
3
|
# RAD UI
|
|
4
4
|
|
|
5
|
-
Head over to [Storybook](https://main--657eda33d6033847be90aaf8.chromatic.com/) to check out latest components.
|
|
6
|
-
|
|
7
5
|

|
|
8
6
|
|
|
7
|
+
## Sponsored by
|
|
8
|
+
|
|
9
|
+
<p align="center">
|
|
10
|
+
<img src="./docs/public/sponsorship/browserstack_light.png" alt="BrowserStack" width="200" />
|
|
11
|
+
|
|
12
|
+
<img src="./docs/public/sponsorship/code_rabbit_light.png" alt="CodeRabbit" width="200" />
|
|
13
|
+
</p>
|
|
14
|
+
|
|
9
15
|
## Introduction to Rad UI
|
|
10
16
|
|
|
11
17
|
Rad UI is a React UI library designed to simplify and enhance the process of building user interfaces. With a focus on ease of use and flexibility, Rad UI empowers developers to create engaging and efficient user experiences. Whether you're starting a new project or improving an existing one, Rad UI provides a collection of components and utilities to streamline development.
|
|
12
18
|
|
|
19
|
+
Head over to [Storybook](https://main--657eda33d6033847be90aaf8.chromatic.com/) to check out latest components.
|
|
20
|
+
|
|
13
21
|
## Documentation
|
|
14
22
|
|
|
15
|
-
For full documentation, visit
|
|
23
|
+
For full documentation, visit [Documentation](https://www.rad-ui.com/docs/first-steps/introduction).
|
|
16
24
|
|
|
17
25
|
## Installation
|
|
18
26
|
|
|
@@ -67,7 +75,7 @@ For more details, you can read on how to contribute to development of Rad UI in
|
|
|
67
75
|
|
|
68
76
|
## Open source licensing info
|
|
69
77
|
|
|
70
|
-
For Licensing
|
|
78
|
+
For Licensing information you can check out [LICENSE](LICENSE).
|
|
71
79
|
|
|
72
80
|
## Dev Environment
|
|
73
81
|
|
|
@@ -1,52 +1,35 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
|
|
3
|
-
type AccordionHeaderProps = {
|
|
4
|
-
children: React.ReactNode;
|
|
5
|
-
className?: string;
|
|
6
|
-
};
|
|
7
|
-
|
|
8
|
-
type AccordionItemProps = {
|
|
9
|
-
children: React.ReactNode;
|
|
10
|
-
className?: string;
|
|
11
|
-
value?: number | string;
|
|
12
|
-
disabled?: boolean;
|
|
13
|
-
asChild?: boolean;
|
|
14
|
-
};
|
|
15
|
-
|
|
16
|
-
type AccordionRootProps = {
|
|
17
|
-
children: React.ReactNode;
|
|
18
|
-
customRootClass?: string;
|
|
19
|
-
transitionDuration?: number;
|
|
20
|
-
transitionTimingFunction?: string;
|
|
21
|
-
orientation?: 'horizontal' | 'vertical';
|
|
22
|
-
asChild?: boolean;
|
|
23
|
-
loop?: boolean;
|
|
24
|
-
disableTabIndexing?: boolean;
|
|
25
|
-
openMultiple?: boolean;
|
|
26
|
-
value?: (number | string)[];
|
|
27
|
-
defaultValue?: (number | string)[];
|
|
28
|
-
onValueChange?: (value: (number | string)[]) => void;
|
|
29
|
-
};
|
|
30
|
-
|
|
31
3
|
type AccordionProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
32
4
|
children?: React.ReactNode;
|
|
33
5
|
};
|
|
34
6
|
declare const Accordion: {
|
|
35
7
|
(): null;
|
|
36
|
-
Root:
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
8
|
+
Root: React.ForwardRefExoticComponent<Omit<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref">, "defaultValue"> & {
|
|
9
|
+
customRootClass?: string;
|
|
10
|
+
transitionDuration?: number;
|
|
11
|
+
transitionTimingFunction?: string;
|
|
12
|
+
orientation?: "horizontal" | "vertical";
|
|
13
|
+
asChild?: boolean;
|
|
14
|
+
loop?: boolean;
|
|
15
|
+
disableTabIndexing?: boolean;
|
|
16
|
+
openMultiple?: boolean;
|
|
17
|
+
value?: (number | string)[];
|
|
18
|
+
defaultValue?: (number | string)[];
|
|
19
|
+
onValueChange?: (value: (number | string)[]) => void;
|
|
20
|
+
} & React.RefAttributes<HTMLDivElement>>;
|
|
21
|
+
Item: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
22
|
+
value?: number | string;
|
|
23
|
+
disabled?: boolean;
|
|
24
|
+
asChild?: boolean;
|
|
25
|
+
} & React.RefAttributes<HTMLDivElement>>;
|
|
26
|
+
Header: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
27
|
+
Trigger: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & {
|
|
42
28
|
index?: number;
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
Content: React.FC<{
|
|
46
|
-
children: React.ReactNode;
|
|
29
|
+
} & React.RefAttributes<HTMLButtonElement>>;
|
|
30
|
+
Content: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
47
31
|
index: number;
|
|
48
|
-
|
|
49
|
-
}>;
|
|
32
|
+
} & React.RefAttributes<HTMLDivElement>>;
|
|
50
33
|
};
|
|
51
34
|
|
|
52
35
|
export { Accordion as default };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use client';import e,{createContext as
|
|
1
|
+
'use client';import{_ as e,a as n,b as i}from"./tslib.es6-BtVxab8e.js";import t,{createContext as a,useRef as o,useState as r,useContext as l,useEffect as c,useId as s}from"react";import{c as d}from"./clsx-BaVHROc5.js";import{c as u}from"./index-BVxS3Ixi.js";import{u as m}from"./index-fkj4Fdgt.js";import{R as v}from"./index-BRmT6kl7.js";import{P as f}from"./index-Dc5Cm9z0.js";import{C as p}from"./index-XqbKa2D2.js";import{B as C}from"./index-DnCiOYxZ.js";var g=a({rootClass:"",activeItems:[],setActiveItems:function(){},accordionRef:void 0,transitionDuration:0,transitionTimingFunction:"ease-out",openMultiple:!1}),h="Accordion",b=t.forwardRef((function(i,a){var r=i.children,l=i.orientation,c=void 0===l?"vertical":l,s=i.disableTabIndexing,p=void 0===s||s,C=i.asChild,b=i.transitionDuration,N=void 0===b?0:b,x=i.transitionTimingFunction,I=void 0===x?"linear":x,R=i.customRootClass,E=i.loop,T=void 0===E||E,A=i.openMultiple,V=void 0!==A&&A,j=i.value,y=i.defaultValue,D=void 0===y?[]:y,w=i.onValueChange,F=e(i,["children","orientation","disableTabIndexing","asChild","transitionDuration","transitionTimingFunction","customRootClass","loop","openMultiple","value","defaultValue","onValueChange"]),M=o(null),P=u(R,h),k=void 0!==j?V?j:j.length>0?[j[0]]:[]:void 0,H=V?D:D.length>0?[D[0]]:[],B=m(k,H,w),G=B[0],O=B[1];return t.createElement(g.Provider,{value:{rootClass:P,activeItems:G,setActiveItems:O,accordionRef:M,transitionDuration:N,transitionTimingFunction:I,openMultiple:V}},t.createElement(v.Root,{orientation:c,loop:T,disableTabIndexing:p},t.createElement(v.Group,null,t.createElement(f.div,n({className:d("".concat(P,"-root")),ref:function(e){var n=e;M.current=n,"function"==typeof a?a(n):a&&(a.current=n)},asChild:C},F),r))))}));b.displayName=h;var N=a({itemValue:0,setItemValue:function(){},disabled:!1}),x=t.forwardRef((function(i,a){var u=i.children,m=i.value,v=i.className,C=void 0===v?"":v,h=i.disabled,b=void 0!==h&&h;i.asChild;var x=e(i,["children","value","className","disabled","asChild"]),I=o(null),R=r(null!=m?m:0),E=R[0],T=R[1],A=l(g),V=A.rootClass,j=A.activeItems,y=A.transitionDuration,D=A.transitionTimingFunction,w=r(j.includes(E)),F=w[0],M=w[1];c((function(){M(j.includes(E))}),[j,E]);var P=s();return c((function(){void 0!==m&&m!==E&&T(m)}),[m]),t.createElement(N.Provider,{value:{itemValue:E,setItemValue:T,disabled:b}},t.createElement(p.Root,{open:F,onOpenChange:M,disabled:b,transitionDuration:y,transitionTimingFunction:D,asChild:!0},t.createElement(f.div,n({ref:function(e){var n=e;I.current=n,"function"==typeof a?a(n):a&&(a.current=n)},className:d("".concat(V,"-item"),C)},x,{id:"accordion-data-item-".concat(P),role:"region","data-state":F?"open":"closed"}),u)))}));x.displayName="AccordionItem";var I=t.forwardRef((function(i,a){var o=i.children,r=i.className,c=void 0===r?"":r,s=e(i,["children","className"]),u=l(g).rootClass;return t.createElement("div",n({ref:a,className:d("".concat(u,"-header"),c)},s),o)}));I.displayName="AccordionHeader";var R=t.forwardRef((function(a,o){var r=a.children,c=a.index,s=a.className,u=void 0===s?"":s,m=a.onClick,f=e(a,["children","index","className","onClick"]),h=l(g),b=h.setActiveItems,x=h.rootClass,I=h.activeItems,R=h.openMultiple,E=l(N),T=E.itemValue,A=E.disabled;return t.createElement(v.Item,null,t.createElement(p.Trigger,{disabled:A,asChild:!0},t.createElement(C,n({className:d("".concat(x,"-trigger"),u),ref:o,"aria-disabled":A,onClick:function(e){var n;n=I||[],R?n.includes(T)?b(n.filter((function(e){return e!==T}))):b(i(i([],n,!0),[T],!1)):n.includes(T)?b([]):b([T]),null==m||m(e)},"aria-expanded":I.includes(T),"aria-controls":"content-".concat(c)},f),r)))}));R.displayName="AccordionTrigger";var E=t.forwardRef((function(i,a){var o=i.children,r=i.index,c=i.className,s=void 0===c?"":c,u=e(i,["children","index","className"]),m=l(g).rootClass;return t.createElement(p.Content,n({ref:a,asChild:!0,className:d("".concat(m,"-content"),s),id:"content-".concat(r),role:"region","aria-labelledby":"section-".concat(r)},u),o)}));E.displayName="AccordionContent";var T=function(){return console.warn("Direct usage of Accordion is not supported. Please use Accordion.Root, Accordion.Item, etc. instead. "),null};T.Root=b,T.Item=x,T.Header=I,T.Trigger=R,T.Content=E;export{T as default};
|
|
@@ -1,62 +1,116 @@
|
|
|
1
1
|
import * as React$1 from 'react';
|
|
2
2
|
import React__default from 'react';
|
|
3
|
+
import DialogPrimitive from '~/core/primitives/Dialog';
|
|
4
|
+
import Primitive from '~/core/primitives/Primitive';
|
|
3
5
|
|
|
4
|
-
type
|
|
6
|
+
type DialogPrimitiveActionProps = {
|
|
5
7
|
children: React__default.ReactNode;
|
|
6
|
-
asChild?: boolean;
|
|
7
8
|
className?: string;
|
|
9
|
+
asChild?: boolean;
|
|
8
10
|
};
|
|
9
11
|
|
|
10
|
-
type
|
|
12
|
+
type DialogPrimitiveCancelProps = {
|
|
11
13
|
children: React__default.ReactNode;
|
|
12
14
|
asChild?: boolean;
|
|
13
15
|
className?: string;
|
|
14
16
|
};
|
|
15
17
|
|
|
16
|
-
type
|
|
18
|
+
type DialogPrimitiveContentProps = {
|
|
17
19
|
children: React__default.ReactNode;
|
|
18
20
|
className?: string;
|
|
21
|
+
asChild?: boolean;
|
|
22
|
+
forceMount?: boolean;
|
|
23
|
+
role?: string;
|
|
24
|
+
'aria-modal'?: boolean;
|
|
25
|
+
'aria-labelledby'?: string;
|
|
26
|
+
'aria-describedby'?: string;
|
|
19
27
|
};
|
|
20
28
|
|
|
21
|
-
type
|
|
29
|
+
type DialogPrimitiveRootProps$1 = {
|
|
22
30
|
children: React__default.ReactNode;
|
|
31
|
+
open?: boolean;
|
|
32
|
+
onOpenChange?: (open: boolean) => void;
|
|
33
|
+
onClickOutside?: () => void;
|
|
34
|
+
className?: string;
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
type DialogPrimitiveRootProps = React__default.ComponentPropsWithoutRef<typeof DialogPrimitive.Root>;
|
|
38
|
+
type AlertDialogRootProps = Omit<DialogPrimitiveRootProps, 'open' | 'onOpenChange'> & {
|
|
39
|
+
customRootClass?: string;
|
|
40
|
+
className?: string;
|
|
41
|
+
defaultOpen?: boolean;
|
|
42
|
+
open?: boolean;
|
|
43
|
+
onOpenChange?: (open: boolean) => void;
|
|
23
44
|
};
|
|
24
45
|
|
|
25
|
-
type
|
|
46
|
+
type DialogPrimitiveTriggerProps = {
|
|
26
47
|
children: React__default.ReactNode;
|
|
27
48
|
asChild?: boolean;
|
|
28
49
|
className?: string;
|
|
50
|
+
disabled?: boolean;
|
|
29
51
|
};
|
|
30
52
|
|
|
31
|
-
type
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
53
|
+
type DialogPrimitivePortalProps = React__default.ComponentPropsWithoutRef<typeof DialogPrimitive.Portal>;
|
|
54
|
+
type AlertDialogPortalProps = DialogPrimitivePortalProps & {
|
|
55
|
+
container?: Element | null;
|
|
56
|
+
forceMount?: boolean;
|
|
57
|
+
keepMounted?: boolean;
|
|
58
|
+
};
|
|
59
|
+
|
|
60
|
+
type PrimitiveH2Props = React__default.ComponentPropsWithoutRef<typeof Primitive.h2>;
|
|
61
|
+
type AlertDialogTitleProps = PrimitiveH2Props & {
|
|
62
|
+
className?: string;
|
|
63
|
+
asChild?: boolean;
|
|
64
|
+
};
|
|
65
|
+
|
|
66
|
+
type PrimitivePProps = React__default.ComponentPropsWithoutRef<typeof Primitive.p>;
|
|
67
|
+
type AlertDialogDescriptionProps = PrimitivePProps & {
|
|
35
68
|
className?: string;
|
|
69
|
+
asChild?: boolean;
|
|
36
70
|
};
|
|
37
71
|
|
|
38
72
|
declare const AlertDialog: {
|
|
39
73
|
(): null;
|
|
40
|
-
Root: {
|
|
41
|
-
|
|
74
|
+
Root: React$1.ForwardRefExoticComponent<Omit<Omit<DialogPrimitiveRootProps$1 & React$1.RefAttributes<HTMLDivElement>, "ref">, "open" | "onOpenChange"> & {
|
|
75
|
+
customRootClass?: string;
|
|
76
|
+
className?: string;
|
|
77
|
+
defaultOpen?: boolean;
|
|
78
|
+
open?: boolean;
|
|
79
|
+
onOpenChange?: (open: boolean) => void;
|
|
80
|
+
} & React$1.RefAttributes<HTMLDivElement>>;
|
|
81
|
+
Trigger: React$1.ForwardRefExoticComponent<Omit<DialogPrimitiveTriggerProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & {
|
|
82
|
+
className?: string;
|
|
83
|
+
disabled?: boolean;
|
|
84
|
+
} & React$1.RefAttributes<HTMLButtonElement>>;
|
|
85
|
+
Overlay: React$1.ForwardRefExoticComponent<Omit<{
|
|
86
|
+
className?: string;
|
|
87
|
+
asChild?: boolean;
|
|
88
|
+
forceMount?: boolean;
|
|
89
|
+
children?: React.ReactNode;
|
|
90
|
+
} & React$1.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
91
|
+
className?: string;
|
|
92
|
+
asChild?: boolean;
|
|
93
|
+
forceMount?: boolean;
|
|
94
|
+
children?: React.ReactNode;
|
|
95
|
+
} & React$1.RefAttributes<HTMLDivElement>>;
|
|
96
|
+
Portal: {
|
|
97
|
+
({ children, ...props }: AlertDialogPortalProps): React$1.JSX.Element;
|
|
42
98
|
displayName: string;
|
|
43
99
|
};
|
|
44
|
-
|
|
45
|
-
Overlay: ({ className }: {
|
|
100
|
+
Content: React$1.ForwardRefExoticComponent<Omit<DialogPrimitiveContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
46
101
|
className?: string;
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
Title:
|
|
51
|
-
|
|
102
|
+
asChild?: boolean;
|
|
103
|
+
forceMount?: boolean;
|
|
104
|
+
} & React$1.RefAttributes<HTMLDivElement>>;
|
|
105
|
+
Title: React$1.ForwardRefExoticComponent<AlertDialogTitleProps & React$1.RefAttributes<HTMLElement>>;
|
|
106
|
+
Description: React$1.ForwardRefExoticComponent<AlertDialogDescriptionProps & React$1.RefAttributes<HTMLElement>>;
|
|
107
|
+
Cancel: React$1.ForwardRefExoticComponent<Omit<DialogPrimitiveCancelProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & {
|
|
52
108
|
className?: string;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
children: React.ReactNode;
|
|
109
|
+
} & React$1.RefAttributes<HTMLButtonElement>>;
|
|
110
|
+
Action: React$1.ForwardRefExoticComponent<Omit<DialogPrimitiveActionProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & {
|
|
56
111
|
className?: string;
|
|
57
|
-
}
|
|
58
|
-
Cancel: ({ children, asChild, className, ...props }: AlertDialogCancelProps) => React$1.JSX.Element;
|
|
59
|
-
Action: ({ children, asChild, className, ...props }: AlertDialogActionProps) => React$1.JSX.Element;
|
|
112
|
+
} & React$1.RefAttributes<HTMLButtonElement>>;
|
|
60
113
|
};
|
|
61
114
|
|
|
62
115
|
export { AlertDialog as default };
|
|
116
|
+
export type { AlertDialogRootProps as __fix_types_1 };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use client';import{_ as e,a}from"./tslib.es6-BtVxab8e.js";import t,{createContext as r,useContext as
|
|
1
|
+
'use client';import{_ as e,a}from"./tslib.es6-BtVxab8e.js";import t,{createContext as i,forwardRef as r,useState as o,useContext as l,useRef as n,useEffect as s}from"react";import{c}from"./index-BVxS3Ixi.js";import{c as d}from"./clsx-BaVHROc5.js";import{u as m}from"./index-fkj4Fdgt.js";import{D as u}from"./index-BtoPzkH9.js";import{F as v}from"./index-Di6TooPD.js";import{P as p}from"./index-Dc5Cm9z0.js";import"./index-DnCiOYxZ.js";import"./floating-ui.react-CLbXmKZY.js";import"react/jsx-runtime";import"react-dom";var f=i({rootClass:"",isOpen:!1,setIsOpen:function(){},titleId:void 0,descriptionId:void 0,setTitleId:function(){},setDescriptionId:function(){}}),h="AlertDialog",C=r((function(i,r){var l=i.children,n=i.className,s=void 0===n?"":n,v=i.customRootClass,p=void 0===v?"":v,C=i.defaultOpen,N=void 0!==C&&C,g=i.open,D=i.onOpenChange,I=e(i,["children","className","customRootClass","defaultOpen","open","onOpenChange"]),y=c(p,h),A=m(g,N,D),O=A[0],E=A[1],b=o(void 0),j=b[0],x=b[1],T=o(void 0),M={rootClass:y,isOpen:O,setIsOpen:E,titleId:j,descriptionId:T[0],setTitleId:x,setDescriptionId:T[1]};return t.createElement(u.Root,a({open:O,onOpenChange:E,className:d(y,s)},I),t.createElement(f.Provider,{value:M},t.createElement("div",{ref:r,className:d(y,s)},l)))}));C.displayName=h;var N=r((function(i,r){var o=i.children,n=i.className,s=void 0===n?"":n,c=i.asChild,m=void 0!==c&&c,v=i.forceMount,p=void 0!==v&&v,h=e(i,["children","className","asChild","forceMount"]),C=l(f),N=C.rootClass,g=C.titleId,D=C.descriptionId;return t.createElement(u.Content,a({ref:r,className:d("".concat(N,"-content"),s),asChild:m,forceMount:p,role:"alertdialog","aria-modal":!0,"aria-labelledby":g,"aria-describedby":D},h),o)}));N.displayName="AlertDialogContent";var g=r((function(i,r){var o=i.children,n=i.asChild,s=i.className,c=void 0===s?"":s,m=i.disabled,v=void 0!==m&&m,p=e(i,["children","asChild","className","disabled"]),h=l(f),C=h.rootClass,N=h.isOpen?"open":"closed",g=v?"":void 0;return t.createElement(u.Trigger,a({ref:r,className:d("".concat(C,"-trigger"),c),asChild:n,disabled:v,"data-state":N,"data-disabled":g},p),o)}));g.displayName="AlertDialogTrigger";var D=function(i){var r=i.children,o=e(i,["children"]);return t.createElement(u.Portal,a({},o),r)};D.displayName="AlertDialogPortal";var I=r((function(i,r){var o=i.className,n=void 0===o?"":o,s=i.asChild,c=void 0!==s&&s,m=i.forceMount,v=void 0!==m&&m,p=i.children,h=e(i,["className","asChild","forceMount","children"]),C=l(f).rootClass;return t.createElement(u.Overlay,a({ref:r,className:d("".concat(C,"-overlay"),n),asChild:c,forceMount:v},h),p)}));I.displayName="AlertDialogOverlay";var y=r((function(i,r){var o=i.children,n=i.asChild,s=i.className,c=void 0===s?"":s,d=e(i,["children","asChild","className"]),m=l(f).rootClass;return t.createElement(u.Cancel,a({ref:r,className:"".concat(m,"-cancel ").concat(c),asChild:n},d),o)}));y.displayName="AlertDialogCancel";var A=r((function(i,r){var o=i.children,n=i.asChild,s=i.className,c=void 0===s?"":s,d=e(i,["children","asChild","className"]),m=l(f).rootClass;return t.createElement(u.Action,a({ref:r,className:"".concat(m,"-action ").concat(c),asChild:n},d),o)}));A.displayName="AlertDialogAction";var O=r((function(i,r){var o=i.children,c=i.className,d=void 0===c?"":c,m=i.asChild,u=void 0!==m&&m,h=i.id,C=e(i,["children","className","asChild","id"]),N=l(f),g=N.rootClass,D=N.setTitleId,I=N.titleId,y=v.useId(),A=null!=h?h:y,O=n(A),E=n(I);return s((function(){E.current=I}),[I]),s((function(){return O.current=A,A&&D(A),function(){E.current===O.current&&D(void 0)}}),[A,D]),t.createElement(p.h2,a({ref:r,id:A,className:"".concat(g,"-title ").concat(d),asChild:u},C),o)}));O.displayName="AlertDialogTitle";var E=r((function(i,r){var o=i.children,c=i.className,d=void 0===c?"":c,m=i.asChild,u=void 0!==m&&m,h=i.id,C=e(i,["children","className","asChild","id"]),N=l(f),g=N.rootClass,D=N.setDescriptionId,I=N.descriptionId,y=v.useId(),A=null!=h?h:y,O=n(A),E=n(I);return s((function(){E.current=I}),[I]),s((function(){return O.current=A,A&&D(A),function(){E.current===O.current&&D(void 0)}}),[A,D]),t.createElement(p.p,a({ref:r,id:A,className:"".concat(g,"-description ").concat(d),asChild:u},C),o)}));E.displayName="AlertDialogDescription";var b=function(){return console.warn("Direct usage of AlertDialog is not supported. Please use AlertDialog.Root, AlertDialog.Content, etc. instead."),null};b.Root=C,b.Trigger=g,b.Overlay=I,b.Portal=D,b.Content=N,b.Title=O,b.Description=E,b.Cancel=y,b.Action=A;export{b as default};
|
|
@@ -1,16 +1,13 @@
|
|
|
1
|
-
import React from 'react';
|
|
1
|
+
import React, { ComponentPropsWithoutRef } from 'react';
|
|
2
2
|
|
|
3
|
-
type AspectRatioProps = {
|
|
4
|
-
children: React.ReactNode;
|
|
3
|
+
type AspectRatioProps = ComponentPropsWithoutRef<'div'> & {
|
|
5
4
|
customRootClass?: string;
|
|
6
|
-
className?: string;
|
|
7
5
|
ratio?: string;
|
|
8
|
-
props: Record<string, any>[];
|
|
9
|
-
};
|
|
10
|
-
declare const AspectRatio: {
|
|
11
|
-
({ children, customRootClass, className, ratio, ...props }: AspectRatioProps): React.JSX.Element;
|
|
12
|
-
displayName: string;
|
|
13
6
|
};
|
|
7
|
+
declare const AspectRatio: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
8
|
+
customRootClass?: string;
|
|
9
|
+
ratio?: string;
|
|
10
|
+
} & React.RefAttributes<HTMLDivElement>>;
|
|
14
11
|
|
|
15
12
|
export { AspectRatio as default };
|
|
16
13
|
export type { AspectRatioProps };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use client';import{_ as a,a as s}from"./tslib.es6-BtVxab8e.js";import
|
|
1
|
+
'use client';import{_ as a,a as s}from"./tslib.es6-BtVxab8e.js";import r from"react";import{c as t}from"./index-BVxS3Ixi.js";import{c as e}from"./clsx-BaVHROc5.js";var o="AspectRatio",m=r.forwardRef((function(m,i){var c=m.children,l=m.customRootClass,d=m.className,f=m.ratio,p=void 0===f?"1":f,N=a(m,["children","customRootClass","className","ratio"]);isNaN(Number(p))&&!p.match(/^(\d+)\/(\d+)$/)&&(p="1"),Number(p)<=0&&(p="1");var n=t(l,o);return r.createElement("div",s({ref:i,style:{aspectRatio:p},className:e(n,d)},N),c)}));m.displayName=o;export{m as default};
|
|
@@ -1,15 +1,12 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import React__default from 'react';
|
|
3
|
-
import
|
|
4
|
-
import
|
|
3
|
+
import AvatarPrimitiveFallback from '~/core/primitives/Avatar/fragments/AvatarPrimitiveFallback';
|
|
4
|
+
import AvatarPrimitiveRoot from '~/core/primitives/Avatar/fragments/AvatarPrimitiveRoot';
|
|
5
|
+
import AvatarPrimitiveImage from '~/core/primitives/Avatar/fragments/AvatarPrimitiveImage';
|
|
5
6
|
|
|
6
|
-
|
|
7
|
-
children: React__default.ReactNode;
|
|
8
|
-
asChild?: boolean;
|
|
9
|
-
className?: string;
|
|
10
|
-
}
|
|
7
|
+
type AvatarFallbackProps = React__default.ComponentPropsWithoutRef<typeof AvatarPrimitiveFallback>;
|
|
11
8
|
|
|
12
|
-
type AvatarRootProps =
|
|
9
|
+
type AvatarRootProps = React__default.ComponentPropsWithoutRef<typeof AvatarPrimitiveRoot> & {
|
|
13
10
|
customRootClass?: string;
|
|
14
11
|
className?: string;
|
|
15
12
|
size?: string;
|
|
@@ -17,19 +14,14 @@ type AvatarRootProps = AvatarPrimitiveRootProps & {
|
|
|
17
14
|
color?: string;
|
|
18
15
|
};
|
|
19
16
|
|
|
20
|
-
type AvatarImageProps =
|
|
21
|
-
src?: string;
|
|
22
|
-
alt?: string;
|
|
23
|
-
};
|
|
17
|
+
type AvatarImageProps = React__default.ComponentPropsWithoutRef<typeof AvatarPrimitiveImage>;
|
|
24
18
|
|
|
25
19
|
declare const Avatar: {
|
|
26
20
|
(): null;
|
|
27
21
|
displayName: string;
|
|
28
|
-
Root:
|
|
29
|
-
Image:
|
|
30
|
-
Fallback:
|
|
31
|
-
className?: string;
|
|
32
|
-
}) => React.JSX.Element;
|
|
22
|
+
Root: React.ForwardRefExoticComponent<AvatarRootProps & React.RefAttributes<HTMLElement>>;
|
|
23
|
+
Image: React.ForwardRefExoticComponent<AvatarImageProps & React.RefAttributes<HTMLElement>>;
|
|
24
|
+
Fallback: React.ForwardRefExoticComponent<AvatarFallbackProps & React.RefAttributes<HTMLElement>>;
|
|
33
25
|
};
|
|
34
26
|
declare namespace AvatarProps {
|
|
35
27
|
type Root = AvatarRootProps;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use client';import{_ as a,a as r}from"./tslib.es6-BtVxab8e.js";import
|
|
1
|
+
'use client';import{_ as a,a as r}from"./tslib.es6-BtVxab8e.js";import e,{createContext as s,useContext as o}from"react";import{A as t,a as l,b as i}from"./AvatarPrimitiveFallback-BV0bK5Qg.js";import{c}from"./clsx-BaVHROc5.js";import{c as m}from"./index-BVxS3Ixi.js";import{u as n,a as v,b as d}from"./index-Bf4LVEjJ.js";import"./index-Dc5Cm9z0.js";var f=s({size:"",variant:"",color:"",rootClass:""}),u="Avatar",p=e.forwardRef((function(s,o){var l=s.children,i=s.customRootClass,p=void 0===i?"":i,N=s.className,A=void 0===N?"":N,b=s.size,R=void 0===b?"":b,j=s.variant,C=void 0===j?"":j,g=s.color,k=void 0===g?"":g,x=a(s,["children","customRootClass","className","size","variant","color"]),z=m(p,u),h=n("avatar",{variant:C,size:R}),w=v(k),y=d(h(),w());return e.createElement(f.Provider,{value:{size:R,variant:C,color:k,rootClass:z}},e.createElement(t,r({ref:o,className:c(z,A)},y(),x),l))}));p.displayName=u;var N=e.forwardRef((function(s,t){var i=s.src,m=void 0===i?"":i,n=s.alt,v=void 0===n?"":n,d=a(s,["src","alt"]),u=o(f).rootClass;return e.createElement(l,r({ref:t,className:c("".concat(u,"-image")),src:m,alt:v},d))}));N.displayName="AvatarImage";var A=e.forwardRef((function(s,t){var l=s.children,m=s.className,n=void 0===m?"":m,v=a(s,["children","className"]),d=o(f).rootClass;return e.createElement(i,r({ref:t,className:c("".concat(d,"-fallback"),n)},v),l)}));A.displayName="AvatarFallback";var b=function(){return console.warn("Direct usage of Avatar is not supported. Please use Avatar.Root, Avatar.Image, Avatar.Fallback instead."),null};b.displayName="Avatar",b.Root=p,b.Image=N,b.Fallback=A;export{b as default};
|
|
@@ -1,35 +1,39 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import React__default from 'react';
|
|
3
|
+
import Primitive from '~/core/primitives/Primitive';
|
|
4
|
+
import AvatarPrimitiveRoot from '~/core/primitives/Avatar/fragments/AvatarPrimitiveRoot';
|
|
5
|
+
import { AvatarRootImageProps as AvatarRootImageProps$1 } from '~/core/primitives/Avatar/fragments/AvatarPrimitiveImage';
|
|
6
|
+
import AvatarPrimitiveFallback from '~/core/primitives/Avatar/fragments/AvatarPrimitiveFallback';
|
|
3
7
|
|
|
4
|
-
type
|
|
8
|
+
type AvatarRootImageProps = React__default.ComponentPropsWithoutRef<typeof Primitive.img> & {
|
|
9
|
+
src?: string;
|
|
10
|
+
alt?: string;
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
type AvatarGroupRootProps = React__default.ComponentPropsWithoutRef<'div'> & {
|
|
5
14
|
customRootClass?: string | '';
|
|
6
15
|
size?: string;
|
|
7
16
|
variant?: string;
|
|
8
|
-
children: React__default.ReactNode;
|
|
9
|
-
className?: string;
|
|
10
17
|
};
|
|
11
18
|
|
|
12
|
-
type AvatarGroupItemProps = {
|
|
19
|
+
type AvatarGroupItemProps = React__default.ComponentPropsWithoutRef<typeof AvatarPrimitiveRoot> & {
|
|
13
20
|
color?: string;
|
|
14
|
-
children: React__default.ReactNode;
|
|
15
21
|
};
|
|
16
22
|
|
|
17
|
-
type AvatarGroupAvatarProps =
|
|
18
|
-
src: string;
|
|
19
|
-
alt: string;
|
|
20
|
-
};
|
|
23
|
+
type AvatarGroupAvatarProps = AvatarRootImageProps$1;
|
|
21
24
|
|
|
22
|
-
type AvatarGroupFallbackProps =
|
|
23
|
-
children: React__default.ReactNode;
|
|
24
|
-
fallback?: string;
|
|
25
|
-
};
|
|
25
|
+
type AvatarGroupFallbackProps = React__default.ComponentPropsWithoutRef<typeof AvatarPrimitiveFallback>;
|
|
26
26
|
|
|
27
27
|
declare const AvatarGroup: {
|
|
28
28
|
(): null;
|
|
29
|
-
Root:
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
29
|
+
Root: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
30
|
+
customRootClass?: string | "";
|
|
31
|
+
size?: string;
|
|
32
|
+
variant?: string;
|
|
33
|
+
} & React.RefAttributes<HTMLDivElement>>;
|
|
34
|
+
Item: React.ForwardRefExoticComponent<AvatarGroupItemProps & React.RefAttributes<HTMLElement>>;
|
|
35
|
+
Avatar: React.ForwardRefExoticComponent<AvatarRootImageProps & React.RefAttributes<HTMLElement>>;
|
|
36
|
+
Fallback: React.ForwardRefExoticComponent<AvatarGroupFallbackProps & React.RefAttributes<HTMLElement>>;
|
|
33
37
|
};
|
|
34
38
|
declare namespace AvatarGroupProps {
|
|
35
39
|
type Root = AvatarGroupRootProps;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use client';import{_ as a,a as r}from"./tslib.es6-BtVxab8e.js";import
|
|
1
|
+
'use client';import{_ as a,a as r}from"./tslib.es6-BtVxab8e.js";import e,{createContext as t,useContext as s}from"react";import{c as o}from"./clsx-BaVHROc5.js";import{c as l}from"./index-BVxS3Ixi.js";import{u as i,b as c,a as n}from"./index-Bf4LVEjJ.js";import{A as m,a as v,b as d}from"./AvatarPrimitiveFallback-BV0bK5Qg.js";import"./index-Dc5Cm9z0.js";var u=t({rootClass:"",size:"",variant:""}),f="AvatarGroup",p=e.forwardRef((function(t,s){var n=t.customRootClass,m=void 0===n?"":n,v=t.size,d=void 0===v?"":v,p=t.variant,A=void 0===p?"":p,N=t.children,G=t.className,b=void 0===G?"":G,R=a(t,["customRootClass","size","variant","children","className"]),h=l(m,f),j=i("avatar",{variant:A,size:d}),C=c(j());return e.createElement(u.Provider,{value:{size:d,variant:A,rootClass:h}},e.createElement("div",r({ref:s,className:o(h,b)},C(),R),N))}));p.displayName=f;var A=e.forwardRef((function(t,l){var i=t.color,v=void 0===i?"":i,d=t.children,f=t.className,p=a(t,["color","children","className"]),A=s(u).rootClass,N=n(v),G=c(N());return e.createElement(m,r({ref:l,className:o("".concat(A,"-item"),f)},G(),p),d)}));A.displayName="AvatarGroupItem";var N=e.forwardRef((function(t,s){var o=t.src,l=t.alt,i=a(t,["src","alt"]);return e.createElement(v,r({ref:s,src:o,alt:l},i))}));N.displayName="AvatarGroupAvatar";var G=e.forwardRef((function(t,l){var i=t.children,c=t.className,n=a(t,["children","className"]),m=s(u).rootClass;return e.createElement(d,r({ref:l,className:o("".concat(m,"-fallback"),c)},n),i)}));G.displayName="AvatarGroupFallback";var b=function(){return console.warn("Direct usage of AvatarGroup is not supported. Please use AvatarGroup.Root, AvatarGroup.Item, AvatarGroup.Avatar, AvatarGroup.Fallback instead."),null};b.Root=p,b.Item=A,b.Avatar=N,b.Fallback=G;export{b as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use client';import{_ as a,a as r}from"./tslib.es6-BtVxab8e.js";import e,{createContext as i,useState as o,useContext as s,useEffect as l}from"react";import{P as d}from"./index-Dc5Cm9z0.js";var n=i({}),t=e.forwardRef((function(i,s){var l=i.children,t=i.asChild,m=void 0!==t&&t,c=a(i,["children","asChild"]),v=o(!1),f=v[0],h=v[1],u=o(!1),E=u[0],p=u[1],g={isImageLoaded:f,hasError:E,setHasError:p,handleLoadImage:function(){h(!0),p(!1)},handleErrorImage:function(){h(!1),p(!0)}};return e.createElement(n.Provider,{value:g},e.createElement(d.span,r({ref:s,asChild:m},c),l))}));t.displayName="AvatarPrimitiveRoot";var m=e.forwardRef((function(i,o){var t=i.src,m=void 0===t?"":t,c=i.alt,v=void 0===c?"":c,f=a(i,["src","alt"]),h=s(n),u=h.handleErrorImage,E=h.handleLoadImage,p=h.hasError;return p?null:(l((function(){m||u()}),[m,u,p]),e.createElement(d.img,r({ref:o,src:m,alt:v,onError:u,onLoad:E},f)))}));m.displayName="AvatarPrimitiveImage";var c=e.forwardRef((function(i,o){var l=i.children,t=i.asChild,m=void 0!==t&&t,c=i.className,v=void 0===c?"":c,f=a(i,["children","asChild","className"]);return s(n).isImageLoaded?null:e.createElement(d.span,r({ref:o,asChild:m,className:v},f),l)}));c.displayName="AvatarPrimitiveFallback";export{t as A,m as a,c as b};
|
|
@@ -1,15 +1,17 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
|
|
3
|
-
type BadgeProps = {
|
|
4
|
-
children?: React.ReactNode;
|
|
3
|
+
type BadgeProps = React.ComponentPropsWithoutRef<'div'> & {
|
|
5
4
|
customRootClass?: string;
|
|
6
|
-
className?: string;
|
|
7
5
|
variant?: string;
|
|
8
6
|
size?: string;
|
|
9
7
|
color?: string;
|
|
10
|
-
props?: object[];
|
|
11
8
|
};
|
|
12
|
-
declare const Badge:
|
|
9
|
+
declare const Badge: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
10
|
+
customRootClass?: string;
|
|
11
|
+
variant?: string;
|
|
12
|
+
size?: string;
|
|
13
|
+
color?: string;
|
|
14
|
+
} & React.RefAttributes<HTMLDivElement>>;
|
|
13
15
|
|
|
14
16
|
export { Badge as default };
|
|
15
17
|
export type { BadgeProps };
|
package/dist/components/Badge.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use client';import{_ as a,a as s}from"./tslib.es6-BtVxab8e.js";import o from"react";import{c as r}from"./index-BVxS3Ixi.js";import{c as
|
|
1
|
+
'use client';import{_ as a,a as s}from"./tslib.es6-BtVxab8e.js";import o from"react";import{c as r}from"./index-BVxS3Ixi.js";import{c as e}from"./clsx-BaVHROc5.js";import{u as i,a as t,b as m}from"./index-Bf4LVEjJ.js";var d="Badge",c=o.forwardRef((function(c,l){var n=c.children,v=c.customRootClass,f=void 0===v?"":v,p=c.className,u=void 0===p?"":p,j=c.color,x=void 0===j?"":j,N=c.variant,b=void 0===N?"":N,z=c.size,R=void 0===z?"":z,g=a(c,["children","customRootClass","className","color","variant","size"]),h=r(f,d),C=i("badge",{variant:b,size:R}),w=t(x),y=m(C(),w());return o.createElement("div",s({ref:l,className:e(h,u)},y(),g),n)}));c.displayName=d;export{c as default};
|
|
@@ -1,18 +1,17 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
|
|
3
|
-
type BlockQuoteProps = {
|
|
4
|
-
children: React.ReactNode;
|
|
3
|
+
type BlockQuoteProps = React.ComponentPropsWithoutRef<'blockquote'> & {
|
|
5
4
|
customRootClass?: string;
|
|
6
|
-
className?: string;
|
|
7
5
|
color?: string;
|
|
8
6
|
variant?: string;
|
|
9
7
|
size?: string;
|
|
10
|
-
props?: Record<string, any>[];
|
|
11
|
-
};
|
|
12
|
-
declare const BlockQuote: {
|
|
13
|
-
({ children, customRootClass, className, color, variant, size, ...props }: BlockQuoteProps): React.JSX.Element;
|
|
14
|
-
displayName: string;
|
|
15
8
|
};
|
|
9
|
+
declare const BlockQuote: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.BlockquoteHTMLAttributes<HTMLQuoteElement>, HTMLQuoteElement>, "ref"> & {
|
|
10
|
+
customRootClass?: string;
|
|
11
|
+
color?: string;
|
|
12
|
+
variant?: string;
|
|
13
|
+
size?: string;
|
|
14
|
+
} & React.RefAttributes<HTMLQuoteElement>>;
|
|
16
15
|
|
|
17
16
|
export { BlockQuote as default };
|
|
18
17
|
export type { BlockQuoteProps };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use client';import{_ as a,a as o}from"./tslib.es6-BtVxab8e.js";import
|
|
1
|
+
'use client';import{_ as a,a as o}from"./tslib.es6-BtVxab8e.js";import r from"react";import{c as s}from"./clsx-BaVHROc5.js";import{c as t}from"./index-BVxS3Ixi.js";var e="BlockQuote",c=r.forwardRef((function(c,i){var l=c.children,d=c.customRootClass,m=void 0===d?"":d,n=c.className,u=void 0===n?"":n,v=c.color,f=void 0===v?"":v,p=c.variant,b=void 0===p?"":p,k=c.size,N=void 0===k?"":k,j=a(c,["children","customRootClass","className","color","variant","size"]),q=t(m,e),x={};return b&&(x["data-block-quote-variant"]=b),N&&(x["data-block-quote-size"]=N),f&&(x["data-rad-ui-accent-color"]=f),r.createElement("blockquote",o({ref:i,className:s(q,u)},j,x),l)}));c.displayName=e;export{c as default};
|
|
@@ -1,15 +1,24 @@
|
|
|
1
|
-
import React, {
|
|
1
|
+
import React, { ComponentPropsWithoutRef } from 'react';
|
|
2
|
+
import ButtonPrimitive from '~/core/primitives/Button';
|
|
2
3
|
|
|
3
4
|
type ButtonProps = {
|
|
4
5
|
customRootClass?: string;
|
|
5
6
|
variant?: string;
|
|
6
7
|
size?: string;
|
|
7
8
|
color?: string;
|
|
8
|
-
} &
|
|
9
|
-
declare const Button: {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
9
|
+
} & ComponentPropsWithoutRef<typeof ButtonPrimitive>;
|
|
10
|
+
declare const Button: React.ForwardRefExoticComponent<{
|
|
11
|
+
customRootClass?: string;
|
|
12
|
+
variant?: string;
|
|
13
|
+
size?: string;
|
|
14
|
+
color?: string;
|
|
15
|
+
} & Omit<{
|
|
16
|
+
label?: string;
|
|
17
|
+
description?: string;
|
|
18
|
+
asChild?: boolean;
|
|
19
|
+
required?: boolean;
|
|
20
|
+
onChange?: any;
|
|
21
|
+
} & Omit<React.DetailedHTMLProps<React.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
13
22
|
|
|
14
23
|
export { Button as default };
|
|
15
24
|
export type { ButtonProps };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use client';import{_ as o,a
|
|
1
|
+
'use client';import{_ as o,a}from"./tslib.es6-BtVxab8e.js";import i,{forwardRef as s}from"react";import{c as t}from"./index-BVxS3Ixi.js";import{c as e}from"./clsx-BaVHROc5.js";import{B as r}from"./index-DnCiOYxZ.js";import{u as d,a as n,b as l}from"./index-Bf4LVEjJ.js";import"./index-Dc5Cm9z0.js";var m="Button",c=s((function(s,c){var p=s.children,v=s.type,u=void 0===v?"button":v,f=s.customRootClass,b=void 0===f?"":f,j=s.className,x=void 0===j?"":j,C=s.variant,y=void 0===C?"":C,N=s.size,k=void 0===N?"":N,z=s.color,h=void 0===z?"":z,B=s.disabled,R=void 0!==B&&B,g=s.onClick,D=o(s,["children","type","customRootClass","className","variant","size","color","disabled","onClick"]),E=t(b,m),P=d("button",{variant:y,size:k}),_=n(h),q=l(P(),_());return i.createElement(r,a({ref:c,type:u,disabled:R,"data-disabled":R?"":void 0,className:e(E,x)},q(),{onClick:function(o){if(R)return o.preventDefault(),void o.stopPropagation();null==g||g(o)}},D),p)}));c.displayName=m;export{c as default};
|