rupoui 1.3.8 → 1.4.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/card/Card.d.ts +4 -0
- package/dist/components/card/CardLayout.d.ts +6 -0
- package/dist/components/card/card.styles.d.ts +238 -0
- package/dist/components/card/card.types.d.ts +40 -0
- package/dist/components/card/context.d.ts +15 -0
- package/dist/components/card/index.d.ts +4 -0
- package/dist/index.cjs +2 -2
- package/dist/index.d.ts +1 -0
- package/dist/index.js +4483 -4079
- package/dist/provider/types.d.ts +3 -0
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { CardBodyProps, CardFooterProps, CardHeaderProps } from './card.types';
|
|
3
|
+
|
|
4
|
+
export declare const CardHeader: React.ForwardRefExoticComponent<CardHeaderProps & React.RefAttributes<HTMLDivElement>>;
|
|
5
|
+
export declare const CardBody: React.ForwardRefExoticComponent<CardBodyProps & React.RefAttributes<HTMLDivElement>>;
|
|
6
|
+
export declare const CardFooter: React.ForwardRefExoticComponent<CardFooterProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -0,0 +1,238 @@
|
|
|
1
|
+
export declare const card: import('tailwind-variants').TVReturnType<{
|
|
2
|
+
variant: {
|
|
3
|
+
solid: {
|
|
4
|
+
base: string;
|
|
5
|
+
};
|
|
6
|
+
bordered: {
|
|
7
|
+
base: string;
|
|
8
|
+
};
|
|
9
|
+
flat: {
|
|
10
|
+
base: string;
|
|
11
|
+
};
|
|
12
|
+
ghost: {
|
|
13
|
+
base: string;
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
color: {
|
|
17
|
+
default: {};
|
|
18
|
+
primary: {};
|
|
19
|
+
secondary: {};
|
|
20
|
+
success: {};
|
|
21
|
+
warning: {};
|
|
22
|
+
danger: {};
|
|
23
|
+
};
|
|
24
|
+
radius: {
|
|
25
|
+
none: {
|
|
26
|
+
base: string;
|
|
27
|
+
};
|
|
28
|
+
sm: {
|
|
29
|
+
base: string;
|
|
30
|
+
};
|
|
31
|
+
md: {
|
|
32
|
+
base: string;
|
|
33
|
+
};
|
|
34
|
+
lg: {
|
|
35
|
+
base: string;
|
|
36
|
+
};
|
|
37
|
+
xl: {
|
|
38
|
+
base: string;
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
shadow: {
|
|
42
|
+
none: {
|
|
43
|
+
base: string;
|
|
44
|
+
};
|
|
45
|
+
sm: {
|
|
46
|
+
base: string;
|
|
47
|
+
};
|
|
48
|
+
md: {
|
|
49
|
+
base: string;
|
|
50
|
+
};
|
|
51
|
+
lg: {
|
|
52
|
+
base: string;
|
|
53
|
+
};
|
|
54
|
+
};
|
|
55
|
+
isHoverable: {
|
|
56
|
+
true: {
|
|
57
|
+
base: string;
|
|
58
|
+
};
|
|
59
|
+
};
|
|
60
|
+
isClickable: {
|
|
61
|
+
true: {
|
|
62
|
+
base: string[];
|
|
63
|
+
};
|
|
64
|
+
};
|
|
65
|
+
isBlurred: {
|
|
66
|
+
true: {
|
|
67
|
+
base: string;
|
|
68
|
+
};
|
|
69
|
+
};
|
|
70
|
+
fullWidth: {
|
|
71
|
+
true: {
|
|
72
|
+
base: string;
|
|
73
|
+
};
|
|
74
|
+
};
|
|
75
|
+
}, {
|
|
76
|
+
base: string[];
|
|
77
|
+
header: string;
|
|
78
|
+
body: string;
|
|
79
|
+
footer: string;
|
|
80
|
+
}, undefined, {
|
|
81
|
+
variant: {
|
|
82
|
+
solid: {
|
|
83
|
+
base: string;
|
|
84
|
+
};
|
|
85
|
+
bordered: {
|
|
86
|
+
base: string;
|
|
87
|
+
};
|
|
88
|
+
flat: {
|
|
89
|
+
base: string;
|
|
90
|
+
};
|
|
91
|
+
ghost: {
|
|
92
|
+
base: string;
|
|
93
|
+
};
|
|
94
|
+
};
|
|
95
|
+
color: {
|
|
96
|
+
default: {};
|
|
97
|
+
primary: {};
|
|
98
|
+
secondary: {};
|
|
99
|
+
success: {};
|
|
100
|
+
warning: {};
|
|
101
|
+
danger: {};
|
|
102
|
+
};
|
|
103
|
+
radius: {
|
|
104
|
+
none: {
|
|
105
|
+
base: string;
|
|
106
|
+
};
|
|
107
|
+
sm: {
|
|
108
|
+
base: string;
|
|
109
|
+
};
|
|
110
|
+
md: {
|
|
111
|
+
base: string;
|
|
112
|
+
};
|
|
113
|
+
lg: {
|
|
114
|
+
base: string;
|
|
115
|
+
};
|
|
116
|
+
xl: {
|
|
117
|
+
base: string;
|
|
118
|
+
};
|
|
119
|
+
};
|
|
120
|
+
shadow: {
|
|
121
|
+
none: {
|
|
122
|
+
base: string;
|
|
123
|
+
};
|
|
124
|
+
sm: {
|
|
125
|
+
base: string;
|
|
126
|
+
};
|
|
127
|
+
md: {
|
|
128
|
+
base: string;
|
|
129
|
+
};
|
|
130
|
+
lg: {
|
|
131
|
+
base: string;
|
|
132
|
+
};
|
|
133
|
+
};
|
|
134
|
+
isHoverable: {
|
|
135
|
+
true: {
|
|
136
|
+
base: string;
|
|
137
|
+
};
|
|
138
|
+
};
|
|
139
|
+
isClickable: {
|
|
140
|
+
true: {
|
|
141
|
+
base: string[];
|
|
142
|
+
};
|
|
143
|
+
};
|
|
144
|
+
isBlurred: {
|
|
145
|
+
true: {
|
|
146
|
+
base: string;
|
|
147
|
+
};
|
|
148
|
+
};
|
|
149
|
+
fullWidth: {
|
|
150
|
+
true: {
|
|
151
|
+
base: string;
|
|
152
|
+
};
|
|
153
|
+
};
|
|
154
|
+
}, {
|
|
155
|
+
base: string[];
|
|
156
|
+
header: string;
|
|
157
|
+
body: string;
|
|
158
|
+
footer: string;
|
|
159
|
+
}, import('tailwind-variants').TVReturnType<{
|
|
160
|
+
variant: {
|
|
161
|
+
solid: {
|
|
162
|
+
base: string;
|
|
163
|
+
};
|
|
164
|
+
bordered: {
|
|
165
|
+
base: string;
|
|
166
|
+
};
|
|
167
|
+
flat: {
|
|
168
|
+
base: string;
|
|
169
|
+
};
|
|
170
|
+
ghost: {
|
|
171
|
+
base: string;
|
|
172
|
+
};
|
|
173
|
+
};
|
|
174
|
+
color: {
|
|
175
|
+
default: {};
|
|
176
|
+
primary: {};
|
|
177
|
+
secondary: {};
|
|
178
|
+
success: {};
|
|
179
|
+
warning: {};
|
|
180
|
+
danger: {};
|
|
181
|
+
};
|
|
182
|
+
radius: {
|
|
183
|
+
none: {
|
|
184
|
+
base: string;
|
|
185
|
+
};
|
|
186
|
+
sm: {
|
|
187
|
+
base: string;
|
|
188
|
+
};
|
|
189
|
+
md: {
|
|
190
|
+
base: string;
|
|
191
|
+
};
|
|
192
|
+
lg: {
|
|
193
|
+
base: string;
|
|
194
|
+
};
|
|
195
|
+
xl: {
|
|
196
|
+
base: string;
|
|
197
|
+
};
|
|
198
|
+
};
|
|
199
|
+
shadow: {
|
|
200
|
+
none: {
|
|
201
|
+
base: string;
|
|
202
|
+
};
|
|
203
|
+
sm: {
|
|
204
|
+
base: string;
|
|
205
|
+
};
|
|
206
|
+
md: {
|
|
207
|
+
base: string;
|
|
208
|
+
};
|
|
209
|
+
lg: {
|
|
210
|
+
base: string;
|
|
211
|
+
};
|
|
212
|
+
};
|
|
213
|
+
isHoverable: {
|
|
214
|
+
true: {
|
|
215
|
+
base: string;
|
|
216
|
+
};
|
|
217
|
+
};
|
|
218
|
+
isClickable: {
|
|
219
|
+
true: {
|
|
220
|
+
base: string[];
|
|
221
|
+
};
|
|
222
|
+
};
|
|
223
|
+
isBlurred: {
|
|
224
|
+
true: {
|
|
225
|
+
base: string;
|
|
226
|
+
};
|
|
227
|
+
};
|
|
228
|
+
fullWidth: {
|
|
229
|
+
true: {
|
|
230
|
+
base: string;
|
|
231
|
+
};
|
|
232
|
+
};
|
|
233
|
+
}, {
|
|
234
|
+
base: string[];
|
|
235
|
+
header: string;
|
|
236
|
+
body: string;
|
|
237
|
+
footer: string;
|
|
238
|
+
}, undefined, unknown, unknown, undefined>>;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { HTMLMotionProps } from 'framer-motion';
|
|
2
|
+
import { HTMLAttributes, ReactNode } from 'react';
|
|
3
|
+
import { card } from './card.styles';
|
|
4
|
+
|
|
5
|
+
export type CardVariant = "solid" | "bordered" | "flat" | "ghost";
|
|
6
|
+
export type CardColor = "default" | "primary" | "secondary" | "success" | "warning" | "danger";
|
|
7
|
+
export type CardRadius = "none" | "sm" | "md" | "lg" | "xl";
|
|
8
|
+
export type CardShadow = "none" | "sm" | "md" | "lg";
|
|
9
|
+
export type CardSlots = keyof ReturnType<typeof card>;
|
|
10
|
+
export interface CardProps extends Omit<HTMLMotionProps<"div">, "color" | "onClick" | "ref"> {
|
|
11
|
+
children: ReactNode;
|
|
12
|
+
variant?: CardVariant;
|
|
13
|
+
color?: CardColor;
|
|
14
|
+
radius?: CardRadius;
|
|
15
|
+
shadow?: CardShadow;
|
|
16
|
+
isHoverable?: boolean;
|
|
17
|
+
isClickable?: boolean;
|
|
18
|
+
isBlurred?: boolean;
|
|
19
|
+
fullWidth?: boolean;
|
|
20
|
+
onClick?: (event: React.MouseEvent<HTMLElement> | React.KeyboardEvent<HTMLElement>) => void;
|
|
21
|
+
className?: string;
|
|
22
|
+
classNames?: {
|
|
23
|
+
base?: string;
|
|
24
|
+
header?: string;
|
|
25
|
+
body?: string;
|
|
26
|
+
footer?: string;
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
export interface CardHeaderProps extends HTMLAttributes<HTMLDivElement> {
|
|
30
|
+
children?: ReactNode;
|
|
31
|
+
className?: string;
|
|
32
|
+
}
|
|
33
|
+
export interface CardBodyProps extends HTMLAttributes<HTMLDivElement> {
|
|
34
|
+
children?: ReactNode;
|
|
35
|
+
className?: string;
|
|
36
|
+
}
|
|
37
|
+
export interface CardFooterProps extends HTMLAttributes<HTMLDivElement> {
|
|
38
|
+
children?: ReactNode;
|
|
39
|
+
className?: string;
|
|
40
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { CardProps } from './card.types';
|
|
2
|
+
|
|
3
|
+
export interface CardContextValue {
|
|
4
|
+
variant: NonNullable<CardProps["variant"]>;
|
|
5
|
+
color: NonNullable<CardProps["color"]>;
|
|
6
|
+
radius: NonNullable<CardProps["radius"]>;
|
|
7
|
+
shadow: NonNullable<CardProps["shadow"]>;
|
|
8
|
+
isHoverable: boolean;
|
|
9
|
+
isClickable: boolean;
|
|
10
|
+
isBlurred: boolean;
|
|
11
|
+
fullWidth: boolean;
|
|
12
|
+
classNames?: CardProps["classNames"];
|
|
13
|
+
}
|
|
14
|
+
export declare const CardContext: import('react').Context<CardContextValue | null>;
|
|
15
|
+
export declare const useCardContext: () => CardContextValue;
|