@mdxui/tremor 6.0.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 +255 -0
- package/dist/dashboard/components/index.d.ts +355 -0
- package/dist/dashboard/components/index.js +549 -0
- package/dist/dashboard/components/index.js.map +1 -0
- package/dist/dashboard/index.d.ts +275 -0
- package/dist/dashboard/index.js +1062 -0
- package/dist/dashboard/index.js.map +1 -0
- package/dist/database/index.d.ts +334 -0
- package/dist/database/index.js +474 -0
- package/dist/database/index.js.map +1 -0
- package/dist/index.d.ts +9 -0
- package/dist/index.js +1089 -0
- package/dist/index.js.map +1 -0
- package/dist/insights/components/index.d.ts +362 -0
- package/dist/insights/components/index.js +1397 -0
- package/dist/insights/components/index.js.map +1 -0
- package/dist/insights/index.d.ts +360 -0
- package/dist/insights/index.js +1815 -0
- package/dist/insights/index.js.map +1 -0
- package/dist/overview/components/index.d.ts +86 -0
- package/dist/overview/components/index.js +775 -0
- package/dist/overview/components/index.js.map +1 -0
- package/dist/overview/index.d.ts +301 -0
- package/dist/overview/index.js +1077 -0
- package/dist/overview/index.js.map +1 -0
- package/dist/shared/index.d.ts +296 -0
- package/dist/shared/index.js +395 -0
- package/dist/shared/index.js.map +1 -0
- package/dist/solar/components/index.d.ts +341 -0
- package/dist/solar/components/index.js +831 -0
- package/dist/solar/components/index.js.map +1 -0
- package/dist/solar/index.d.ts +301 -0
- package/dist/solar/index.js +1130 -0
- package/dist/solar/index.js.map +1 -0
- package/package.json +135 -0
|
@@ -0,0 +1,341 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { ReactNode, ComponentType } from 'react';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Action configuration for CTA buttons
|
|
6
|
+
*/
|
|
7
|
+
interface CTAActionConfig {
|
|
8
|
+
href: string;
|
|
9
|
+
onClick?: () => void;
|
|
10
|
+
target?: "_blank" | "_self";
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Link component props for custom routing
|
|
14
|
+
*/
|
|
15
|
+
interface CTALinkProps {
|
|
16
|
+
href: string;
|
|
17
|
+
children: ReactNode;
|
|
18
|
+
className?: string;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* CTA (Call to Action) component props
|
|
22
|
+
*/
|
|
23
|
+
interface CTAProps {
|
|
24
|
+
/** Main title */
|
|
25
|
+
title: ReactNode;
|
|
26
|
+
/** Description text */
|
|
27
|
+
description?: ReactNode;
|
|
28
|
+
/** Primary call-to-action button text */
|
|
29
|
+
callToAction: ReactNode;
|
|
30
|
+
/** Secondary call-to-action button text */
|
|
31
|
+
secondaryCallToAction?: ReactNode;
|
|
32
|
+
/** Image URL or component */
|
|
33
|
+
image?: ReactNode;
|
|
34
|
+
/** Image alt text */
|
|
35
|
+
imageAlt?: string;
|
|
36
|
+
/** Action behaviors */
|
|
37
|
+
actions?: {
|
|
38
|
+
primary?: string | CTAActionConfig;
|
|
39
|
+
secondary?: string | CTAActionConfig;
|
|
40
|
+
};
|
|
41
|
+
/** Custom link component */
|
|
42
|
+
LinkComponent?: ComponentType<CTALinkProps>;
|
|
43
|
+
/** Additional className */
|
|
44
|
+
className?: string;
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* Call to Action section for the Solar template.
|
|
48
|
+
*
|
|
49
|
+
* Based on Tremor's Solar template CallToAction component with mdxui interface.
|
|
50
|
+
* Features:
|
|
51
|
+
* - Two-column layout with content and image
|
|
52
|
+
* - Primary and secondary action buttons
|
|
53
|
+
* - Responsive design
|
|
54
|
+
*
|
|
55
|
+
* @example
|
|
56
|
+
* ```tsx
|
|
57
|
+
* <CTA
|
|
58
|
+
* title="Ready to get started?"
|
|
59
|
+
* description="Begin your smart farming journey today."
|
|
60
|
+
* callToAction="Start now"
|
|
61
|
+
* secondaryCallToAction="Find nearest dealer"
|
|
62
|
+
* image="/images/farm.webp"
|
|
63
|
+
* actions={{
|
|
64
|
+
* primary: '/signup',
|
|
65
|
+
* secondary: '/dealers',
|
|
66
|
+
* }}
|
|
67
|
+
* />
|
|
68
|
+
* ```
|
|
69
|
+
*/
|
|
70
|
+
declare function CTA({ title, description, callToAction, secondaryCallToAction, image, imageAlt, actions, LinkComponent, className, }: CTAProps): react_jsx_runtime.JSX.Element;
|
|
71
|
+
|
|
72
|
+
/**
|
|
73
|
+
* Feature item definition
|
|
74
|
+
*/
|
|
75
|
+
interface FeatureItem {
|
|
76
|
+
/** Feature title */
|
|
77
|
+
title: string;
|
|
78
|
+
/** Feature description */
|
|
79
|
+
description: string;
|
|
80
|
+
/** Feature icon (React node or Lucide icon name) */
|
|
81
|
+
icon?: ReactNode;
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Feature block definition (for alternating layout)
|
|
85
|
+
*/
|
|
86
|
+
interface FeatureBlock {
|
|
87
|
+
/** Block badge/label */
|
|
88
|
+
badge: string;
|
|
89
|
+
/** Block title */
|
|
90
|
+
title: string;
|
|
91
|
+
/** Block description */
|
|
92
|
+
description: string;
|
|
93
|
+
/** Block illustration (React node) */
|
|
94
|
+
illustration?: ReactNode;
|
|
95
|
+
}
|
|
96
|
+
/**
|
|
97
|
+
* Link component props for custom routing
|
|
98
|
+
*/
|
|
99
|
+
interface FeaturesLinkProps {
|
|
100
|
+
href: string;
|
|
101
|
+
children: ReactNode;
|
|
102
|
+
className?: string;
|
|
103
|
+
}
|
|
104
|
+
/**
|
|
105
|
+
* Features component props
|
|
106
|
+
*/
|
|
107
|
+
interface FeaturesProps {
|
|
108
|
+
/** Section ID for anchor links */
|
|
109
|
+
id?: string;
|
|
110
|
+
/** Feature blocks for alternating layout */
|
|
111
|
+
blocks?: FeatureBlock[];
|
|
112
|
+
/** Simple feature items for grid layout */
|
|
113
|
+
items?: FeatureItem[];
|
|
114
|
+
/** Number of columns for grid layout */
|
|
115
|
+
columns?: 2 | 3 | 4;
|
|
116
|
+
/** Custom link component */
|
|
117
|
+
LinkComponent?: ComponentType<FeaturesLinkProps>;
|
|
118
|
+
/** Additional className */
|
|
119
|
+
className?: string;
|
|
120
|
+
/** Children for custom content */
|
|
121
|
+
children?: ReactNode;
|
|
122
|
+
}
|
|
123
|
+
/**
|
|
124
|
+
* Features section for the Solar template.
|
|
125
|
+
*
|
|
126
|
+
* Based on Tremor's Solar template Features component with mdxui interface.
|
|
127
|
+
* Supports both alternating block layout and simple grid layout.
|
|
128
|
+
*
|
|
129
|
+
* @example
|
|
130
|
+
* ```tsx
|
|
131
|
+
* <Features
|
|
132
|
+
* id="solutions"
|
|
133
|
+
* blocks={[
|
|
134
|
+
* {
|
|
135
|
+
* badge: 'Smart Farming',
|
|
136
|
+
* title: 'A network of autonomous systems',
|
|
137
|
+
* description: 'Deploy intelligent monitoring...',
|
|
138
|
+
* illustration: <OrbitAnimation />,
|
|
139
|
+
* },
|
|
140
|
+
* ]}
|
|
141
|
+
* />
|
|
142
|
+
* ```
|
|
143
|
+
*/
|
|
144
|
+
declare function Features({ id, blocks, items, columns, className, children, }: FeaturesProps): react_jsx_runtime.JSX.Element | null;
|
|
145
|
+
|
|
146
|
+
/**
|
|
147
|
+
* Footer link configuration
|
|
148
|
+
*/
|
|
149
|
+
interface FooterLink {
|
|
150
|
+
/** Link label */
|
|
151
|
+
label: string;
|
|
152
|
+
/** Link destination */
|
|
153
|
+
href: string;
|
|
154
|
+
/** Open in new tab */
|
|
155
|
+
external?: boolean;
|
|
156
|
+
}
|
|
157
|
+
/**
|
|
158
|
+
* Footer link group configuration
|
|
159
|
+
*/
|
|
160
|
+
interface FooterLinkGroup {
|
|
161
|
+
/** Group title */
|
|
162
|
+
title: string;
|
|
163
|
+
/** Links in this group */
|
|
164
|
+
links: FooterLink[];
|
|
165
|
+
}
|
|
166
|
+
/**
|
|
167
|
+
* Social link configuration
|
|
168
|
+
*/
|
|
169
|
+
interface SocialLink {
|
|
170
|
+
/** Platform name (twitter, github, discord, linkedin, youtube, instagram) */
|
|
171
|
+
platform: "twitter" | "github" | "discord" | "linkedin" | "youtube" | "instagram" | string;
|
|
172
|
+
/** Profile URL */
|
|
173
|
+
href: string;
|
|
174
|
+
}
|
|
175
|
+
/**
|
|
176
|
+
* Link component props for custom routing
|
|
177
|
+
*/
|
|
178
|
+
interface FooterLinkProps {
|
|
179
|
+
href: string;
|
|
180
|
+
children: ReactNode;
|
|
181
|
+
className?: string;
|
|
182
|
+
target?: string;
|
|
183
|
+
rel?: string;
|
|
184
|
+
}
|
|
185
|
+
/**
|
|
186
|
+
* Footer component props
|
|
187
|
+
*/
|
|
188
|
+
interface FooterProps {
|
|
189
|
+
/** Logo element or string */
|
|
190
|
+
logo?: ReactNode;
|
|
191
|
+
/** Simple footer links (flat list) */
|
|
192
|
+
links: FooterLink[];
|
|
193
|
+
/** Grouped footer links (columns) */
|
|
194
|
+
linkGroups?: FooterLinkGroup[];
|
|
195
|
+
/** Social media links */
|
|
196
|
+
social?: SocialLink[];
|
|
197
|
+
/** Copyright text */
|
|
198
|
+
copyright?: string;
|
|
199
|
+
/** Custom link component (e.g., Next.js Link) */
|
|
200
|
+
LinkComponent?: ComponentType<FooterLinkProps>;
|
|
201
|
+
/** Additional className */
|
|
202
|
+
className?: string;
|
|
203
|
+
}
|
|
204
|
+
/**
|
|
205
|
+
* Footer component for Solar template
|
|
206
|
+
*
|
|
207
|
+
* A responsive footer with logo, link columns, social links, and copyright.
|
|
208
|
+
* Based on the Solar template design.
|
|
209
|
+
*/
|
|
210
|
+
declare function Footer({ logo, links, linkGroups, social, copyright, LinkComponent, className, }: FooterProps): react_jsx_runtime.JSX.Element;
|
|
211
|
+
|
|
212
|
+
/**
|
|
213
|
+
* Navigation item configuration
|
|
214
|
+
*/
|
|
215
|
+
interface NavItem {
|
|
216
|
+
/** Link label */
|
|
217
|
+
label: string;
|
|
218
|
+
/** Link destination */
|
|
219
|
+
href: string;
|
|
220
|
+
}
|
|
221
|
+
/**
|
|
222
|
+
* CTA button configuration
|
|
223
|
+
*/
|
|
224
|
+
interface HeaderCTA {
|
|
225
|
+
/** Button label */
|
|
226
|
+
label: string;
|
|
227
|
+
/** Button destination */
|
|
228
|
+
href: string;
|
|
229
|
+
/** Click handler (alternative to href) */
|
|
230
|
+
onClick?: () => void;
|
|
231
|
+
}
|
|
232
|
+
/**
|
|
233
|
+
* Link component props for custom routing
|
|
234
|
+
*/
|
|
235
|
+
interface HeaderLinkProps {
|
|
236
|
+
href: string;
|
|
237
|
+
children: ReactNode;
|
|
238
|
+
className?: string;
|
|
239
|
+
onClick?: () => void;
|
|
240
|
+
}
|
|
241
|
+
/**
|
|
242
|
+
* Header component props
|
|
243
|
+
*/
|
|
244
|
+
interface HeaderProps {
|
|
245
|
+
/** Logo element or string */
|
|
246
|
+
logo: ReactNode;
|
|
247
|
+
/** Navigation items */
|
|
248
|
+
navItems: NavItem[];
|
|
249
|
+
/** Primary CTA button */
|
|
250
|
+
cta?: HeaderCTA;
|
|
251
|
+
/** Custom link component (e.g., Next.js Link) */
|
|
252
|
+
LinkComponent?: ComponentType<HeaderLinkProps>;
|
|
253
|
+
/** Sticky header behavior */
|
|
254
|
+
sticky?: boolean;
|
|
255
|
+
/** Transparent when at top */
|
|
256
|
+
transparentOnTop?: boolean;
|
|
257
|
+
/** Additional className */
|
|
258
|
+
className?: string;
|
|
259
|
+
}
|
|
260
|
+
/**
|
|
261
|
+
* Header component for Solar template
|
|
262
|
+
*
|
|
263
|
+
* A responsive navigation header with logo, nav items, and optional CTA button.
|
|
264
|
+
* Supports sticky behavior and transparent-on-top styling.
|
|
265
|
+
*/
|
|
266
|
+
declare function Header({ logo, navItems, cta, LinkComponent, sticky, transparentOnTop, className, }: HeaderProps): react_jsx_runtime.JSX.Element;
|
|
267
|
+
|
|
268
|
+
/**
|
|
269
|
+
* Hero CTA configuration
|
|
270
|
+
*/
|
|
271
|
+
interface HeroCTAConfig {
|
|
272
|
+
/** Primary button text */
|
|
273
|
+
primary?: string;
|
|
274
|
+
/** Secondary button text */
|
|
275
|
+
secondary?: string;
|
|
276
|
+
/** Primary button action */
|
|
277
|
+
primaryAction?: string | (() => void);
|
|
278
|
+
/** Secondary button action */
|
|
279
|
+
secondaryAction?: string | (() => void);
|
|
280
|
+
}
|
|
281
|
+
/**
|
|
282
|
+
* Link component props for custom routing
|
|
283
|
+
*/
|
|
284
|
+
interface HeroLinkProps {
|
|
285
|
+
href: string;
|
|
286
|
+
children: ReactNode;
|
|
287
|
+
className?: string;
|
|
288
|
+
}
|
|
289
|
+
/**
|
|
290
|
+
* Hero component props following mdxui content/actions pattern
|
|
291
|
+
*/
|
|
292
|
+
interface HeroProps {
|
|
293
|
+
/** Main title text (mdxui standard) */
|
|
294
|
+
title: string;
|
|
295
|
+
/** Supporting subtitle (mdxui standard) */
|
|
296
|
+
subtitle?: string;
|
|
297
|
+
/** Badge text (shown above title) */
|
|
298
|
+
badge?: string;
|
|
299
|
+
/** Primary call-to-action text (mdxui standard) */
|
|
300
|
+
callToAction: string;
|
|
301
|
+
/** Secondary call-to-action text (mdxui standard) */
|
|
302
|
+
secondaryCallToAction?: string;
|
|
303
|
+
/** Hero variant */
|
|
304
|
+
variant?: "default" | "minimal" | "gradient";
|
|
305
|
+
/** Action behaviors - where buttons navigate (mdxui standard) */
|
|
306
|
+
actions?: {
|
|
307
|
+
primary?: string | {
|
|
308
|
+
href: string;
|
|
309
|
+
onClick?: () => void;
|
|
310
|
+
target?: "_blank" | "_self";
|
|
311
|
+
};
|
|
312
|
+
secondary?: string | {
|
|
313
|
+
href: string;
|
|
314
|
+
onClick?: () => void;
|
|
315
|
+
target?: "_blank" | "_self";
|
|
316
|
+
};
|
|
317
|
+
};
|
|
318
|
+
/** Custom link component (e.g., Next.js Link) */
|
|
319
|
+
LinkComponent?: ComponentType<HeroLinkProps>;
|
|
320
|
+
/** Additional className */
|
|
321
|
+
className?: string;
|
|
322
|
+
/** Children for custom content */
|
|
323
|
+
children?: ReactNode;
|
|
324
|
+
}
|
|
325
|
+
/**
|
|
326
|
+
* Hero component - Default variant
|
|
327
|
+
*
|
|
328
|
+
* A centered hero section with title, subtitle, badge, and CTA buttons.
|
|
329
|
+
* Based on the Solar template design with mdxui interface.
|
|
330
|
+
*/
|
|
331
|
+
declare function Hero({ title, subtitle, badge, callToAction, secondaryCallToAction, variant, actions, LinkComponent, className, children, }: HeroProps): react_jsx_runtime.JSX.Element;
|
|
332
|
+
/**
|
|
333
|
+
* HeroMinimal - A minimal, clean hero variant without background effects
|
|
334
|
+
*/
|
|
335
|
+
declare function HeroMinimal({ title, subtitle, badge, callToAction, secondaryCallToAction, actions, LinkComponent, className, children, }: HeroProps): react_jsx_runtime.JSX.Element;
|
|
336
|
+
/**
|
|
337
|
+
* HeroGradient - Hero variant with gradient background effects
|
|
338
|
+
*/
|
|
339
|
+
declare function HeroGradient({ title, subtitle, badge, callToAction, secondaryCallToAction, actions, LinkComponent, className, children, }: HeroProps): react_jsx_runtime.JSX.Element;
|
|
340
|
+
|
|
341
|
+
export { CTA, type CTAActionConfig, type CTALinkProps, type CTAProps, type FeatureBlock, type FeatureItem, Features, type FeaturesLinkProps, type FeaturesProps, Footer, type FooterLink, type FooterLinkGroup, type FooterLinkProps, type FooterProps, Header, type HeaderCTA, type HeaderLinkProps, type HeaderProps, Hero, type HeroCTAConfig, HeroGradient, type HeroLinkProps, HeroMinimal, type HeroProps, type NavItem, type SocialLink };
|