nextworks 0.2.0-alpha.11 → 0.2.0-alpha.13
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 +283 -282
- package/dist/cli_manifests/blocks_manifest.json +198 -175
- package/dist/kits/blocks/.nextworks/docs/BLOCKS_QUICKSTART.md +101 -100
- package/dist/kits/blocks/.nextworks/docs/BLOCKS_README.md +105 -104
- package/dist/kits/blocks/.nextworks/docs/THEME_GUIDE.md +1 -1
- package/dist/kits/blocks/app/templates/aiworkflow/PresetThemeVars.tsx +58 -0
- package/dist/kits/blocks/app/templates/aiworkflow/README.md +46 -0
- package/dist/kits/blocks/app/templates/aiworkflow/components/CTA.tsx +44 -0
- package/dist/kits/blocks/app/templates/aiworkflow/components/Contact.tsx +105 -0
- package/dist/kits/blocks/app/templates/aiworkflow/components/FAQ.tsx +63 -0
- package/dist/kits/blocks/app/templates/aiworkflow/components/Features.tsx +65 -0
- package/dist/kits/blocks/app/templates/aiworkflow/components/Footer.tsx +109 -0
- package/dist/kits/blocks/app/templates/aiworkflow/components/Hero.tsx +636 -0
- package/dist/kits/blocks/app/templates/aiworkflow/components/Navbar.tsx +90 -0
- package/dist/kits/blocks/app/templates/aiworkflow/components/Pricing.tsx +86 -0
- package/dist/kits/blocks/app/templates/aiworkflow/components/ProcessTimeline.tsx +103 -0
- package/dist/kits/blocks/app/templates/aiworkflow/components/Testimonials.tsx +56 -0
- package/dist/kits/blocks/app/templates/aiworkflow/components/TrustBadges.tsx +59 -0
- package/dist/kits/blocks/app/templates/aiworkflow/page.tsx +43 -0
- package/dist/kits/blocks/app/templates/digitalagency/PresetThemeVars.tsx +80 -80
- package/dist/kits/blocks/app/templates/digitalagency/README.md +42 -42
- package/dist/kits/blocks/app/templates/digitalagency/components/Pricing.tsx +114 -114
- package/dist/kits/blocks/app/templates/digitalagency/components/Process.tsx +59 -59
- package/dist/kits/blocks/app/templates/digitalagency/components/Services.tsx +55 -55
- package/dist/kits/blocks/app/templates/digitalagency/components/Team.tsx +28 -28
- package/dist/kits/blocks/app/templates/digitalagency/components/Testimonials.tsx +65 -65
- package/dist/kits/blocks/app/templates/digitalagency/page.tsx +38 -38
- package/dist/kits/blocks/app/templates/gallery/PresetThemeVars.tsx +84 -84
- package/dist/kits/blocks/app/templates/productlaunch/PresetThemeVars.tsx +75 -75
- package/dist/kits/blocks/app/templates/productlaunch/README.md +62 -62
- package/dist/kits/blocks/app/templates/productlaunch/components/About.tsx +84 -84
- package/dist/kits/blocks/app/templates/productlaunch/components/CTA.tsx +50 -50
- package/dist/kits/blocks/app/templates/productlaunch/components/Contact.tsx +231 -231
- package/dist/kits/blocks/app/templates/productlaunch/components/FAQ.tsx +86 -86
- package/dist/kits/blocks/app/templates/productlaunch/components/Features.tsx +83 -83
- package/dist/kits/blocks/app/templates/productlaunch/components/Footer.tsx +132 -132
- package/dist/kits/blocks/app/templates/productlaunch/components/Hero.tsx +88 -88
- package/dist/kits/blocks/app/templates/productlaunch/components/Navbar.tsx +116 -116
- package/dist/kits/blocks/app/templates/productlaunch/components/Pricing.tsx +106 -106
- package/dist/kits/blocks/app/templates/productlaunch/components/ProcessTimeline.tsx +110 -110
- package/dist/kits/blocks/app/templates/productlaunch/components/ServicesGrid.tsx +68 -68
- package/dist/kits/blocks/app/templates/productlaunch/components/Team.tsx +104 -104
- package/dist/kits/blocks/app/templates/productlaunch/components/Testimonials.tsx +90 -90
- package/dist/kits/blocks/app/templates/productlaunch/components/TrustBadges.tsx +76 -76
- package/dist/kits/blocks/app/templates/productlaunch/page.tsx +43 -43
- package/dist/kits/blocks/app/templates/saasdashboard/PresetThemeVars.tsx +80 -80
- package/dist/kits/blocks/app/templates/saasdashboard/README.md +44 -44
- package/dist/kits/blocks/app/templates/saasdashboard/components/Contact.tsx +129 -129
- package/dist/kits/blocks/app/templates/saasdashboard/components/Dashboard.tsx +293 -293
- package/dist/kits/blocks/app/templates/saasdashboard/components/FAQ.tsx +55 -55
- package/dist/kits/blocks/app/templates/saasdashboard/components/Features.tsx +90 -90
- package/dist/kits/blocks/app/templates/saasdashboard/components/Footer.tsx +77 -77
- package/dist/kits/blocks/app/templates/saasdashboard/components/Hero.tsx +104 -104
- package/dist/kits/blocks/app/templates/saasdashboard/components/Hero_mask.tsx +126 -126
- package/dist/kits/blocks/app/templates/saasdashboard/components/Navbar.tsx +117 -117
- package/dist/kits/blocks/app/templates/saasdashboard/components/Pricing.tsx +90 -90
- package/dist/kits/blocks/app/templates/saasdashboard/components/SmoothScroll.tsx +96 -96
- package/dist/kits/blocks/app/templates/saasdashboard/components/Testimonials.tsx +72 -72
- package/dist/kits/blocks/app/templates/saasdashboard/components/TrustBadges.tsx +53 -53
- package/dist/kits/blocks/app/templates/saasdashboard/page.tsx +39 -39
- package/dist/kits/blocks/components/enhanced-theme-provider.tsx +195 -195
- package/dist/kits/blocks/components/providers/BlocksAppProviders.tsx +27 -27
- package/dist/kits/blocks/components/sections/About.tsx +291 -291
- package/dist/kits/blocks/components/sections/CTA.tsx +257 -257
- package/dist/kits/blocks/components/sections/Contact.tsx +267 -267
- package/dist/kits/blocks/components/sections/FAQ.tsx +214 -214
- package/dist/kits/blocks/components/sections/Features.tsx +268 -268
- package/dist/kits/blocks/components/sections/Footer.tsx +302 -302
- package/dist/kits/blocks/components/sections/HeroMotion.tsx +308 -308
- package/dist/kits/blocks/components/sections/HeroOverlay.tsx +358 -358
- package/dist/kits/blocks/components/sections/HeroProductDemo.tsx +236 -0
- package/dist/kits/blocks/components/sections/HeroSplit.tsx +352 -352
- package/dist/kits/blocks/components/sections/Navbar.tsx +350 -350
- package/dist/kits/blocks/components/sections/PortfolioSimple.tsx +549 -549
- package/dist/kits/blocks/components/sections/Pricing.tsx +264 -264
- package/dist/kits/blocks/components/sections/ProcessTimeline.tsx +325 -325
- package/dist/kits/blocks/components/sections/ServicesGrid.tsx +210 -210
- package/dist/kits/blocks/components/sections/Team.tsx +309 -309
- package/dist/kits/blocks/components/sections/Testimonials.tsx +158 -158
- package/dist/kits/blocks/components/sections/TrustBadges.tsx +162 -162
- package/dist/kits/blocks/components/sections/product-demo/ApprovalInboxPanel.tsx +125 -0
- package/dist/kits/blocks/components/sections/product-demo/DemoStage.tsx +397 -0
- package/dist/kits/blocks/components/sections/product-demo/DemoWindow.tsx +128 -0
- package/dist/kits/blocks/components/sections/product-demo/KnowledgePanel.tsx +127 -0
- package/dist/kits/blocks/components/sections/product-demo/RunConsolePanel.tsx +150 -0
- package/dist/kits/blocks/components/sections/product-demo/WorkflowStudioPanel.tsx +191 -0
- package/dist/kits/blocks/components/sections/product-demo/types.ts +193 -0
- package/dist/kits/blocks/components/theme-provider.tsx +1 -1
- package/dist/kits/blocks/components/ui/alert-dialog.tsx +134 -134
- package/dist/kits/blocks/components/ui/brand-node.tsx +121 -121
- package/dist/kits/blocks/components/ui/button.tsx +122 -122
- package/dist/kits/blocks/components/ui/card.tsx +95 -95
- package/dist/kits/blocks/components/ui/checkbox.tsx +30 -30
- package/dist/kits/blocks/components/ui/cta-button.tsx +125 -125
- package/dist/kits/blocks/components/ui/dropdown-menu.tsx +201 -201
- package/dist/kits/blocks/components/ui/feature-card.tsx +91 -91
- package/dist/kits/blocks/components/ui/input.tsx +27 -27
- package/dist/kits/blocks/components/ui/label.tsx +29 -29
- package/dist/kits/blocks/components/ui/pricing-card.tsx +120 -120
- package/dist/kits/blocks/components/ui/select.tsx +25 -25
- package/dist/kits/blocks/components/ui/skeleton.tsx +13 -13
- package/dist/kits/blocks/components/ui/table.tsx +98 -98
- package/dist/kits/blocks/components/ui/testimonial-card.tsx +108 -108
- package/dist/kits/blocks/components/ui/textarea.tsx +26 -26
- package/dist/kits/blocks/components/ui/theme-selector.tsx +243 -243
- package/dist/kits/blocks/components/ui/theme-toggle.tsx +74 -74
- package/dist/kits/blocks/components/ui/toaster.tsx +7 -7
- package/dist/kits/blocks/lib/themes.ts +400 -400
- package/dist/kits/blocks/lib/utils.ts +6 -6
- package/dist/kits/blocks/package-deps.json +3 -3
- package/package.json +1 -1
|
@@ -1,158 +1,158 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
|
|
3
|
-
import React from "react";
|
|
4
|
-
import { cn } from "@/lib/utils";
|
|
5
|
-
import { TestimonialCard } from "@/components/ui/testimonial-card";
|
|
6
|
-
|
|
7
|
-
/**
|
|
8
|
-
* Data used to render a TestimonialCard.
|
|
9
|
-
* @public
|
|
10
|
-
*/
|
|
11
|
-
export interface TestimonialCardData {
|
|
12
|
-
/** The testimonial quote text */
|
|
13
|
-
testimonialText: string;
|
|
14
|
-
/** The author's display name (prefixed with hyphen in defaults) */
|
|
15
|
-
testimonialAuthor: string;
|
|
16
|
-
/** Author initials displayed in the avatar */
|
|
17
|
-
testimonialAuthorInitials: string;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
/**
|
|
21
|
-
* Props for the Testimonials section component.
|
|
22
|
-
*
|
|
23
|
-
* @remarks
|
|
24
|
-
* - Styling: slot-style className overrides are merged after defaults via cn().
|
|
25
|
-
* - Motion: enableMotion toggles card hover transitions.
|
|
26
|
-
* - Accessibility: semantic <section> with aria-label.
|
|
27
|
-
*/
|
|
28
|
-
export interface TestimonialsProps {
|
|
29
|
-
/** Optional id */
|
|
30
|
-
id?: string;
|
|
31
|
-
/** Root className merged into slots */
|
|
32
|
-
className?: string;
|
|
33
|
-
|
|
34
|
-
/** Testimonial items to render. @defaultValue defaultTestimonialData */
|
|
35
|
-
testimonials?: TestimonialCardData[];
|
|
36
|
-
/** Heading displayed above the grid. @defaultValue "What Our Customers Say" */
|
|
37
|
-
testimonialSectionHeader?: string;
|
|
38
|
-
|
|
39
|
-
/** When false, disables hover transitions on cards */
|
|
40
|
-
enableMotion?: boolean;
|
|
41
|
-
|
|
42
|
-
/** Slot-style overrides */
|
|
43
|
-
section?: { className?: string };
|
|
44
|
-
container?: { className?: string };
|
|
45
|
-
header?: { className?: string };
|
|
46
|
-
heading?: { className?: string };
|
|
47
|
-
grid?: { className?: string };
|
|
48
|
-
card?: { className?: string };
|
|
49
|
-
content?: { className?: string };
|
|
50
|
-
text?: { className?: string };
|
|
51
|
-
author?: { className?: string };
|
|
52
|
-
avatar?: { className?: string };
|
|
53
|
-
avatarText?: { className?: string };
|
|
54
|
-
|
|
55
|
-
/** ARIA label for the section. @defaultValue "Testimonials section" */
|
|
56
|
-
ariaLabel?: string;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
const defaultTestimonialData: TestimonialCardData[] = [
|
|
60
|
-
{
|
|
61
|
-
testimonialText: "Lorem ipsum dolor sit amet! Consectetur adipiscing elit.",
|
|
62
|
-
testimonialAuthor: " - Cillum Dolore",
|
|
63
|
-
testimonialAuthorInitials: "CD",
|
|
64
|
-
},
|
|
65
|
-
{
|
|
66
|
-
testimonialText:
|
|
67
|
-
"Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi!",
|
|
68
|
-
testimonialAuthor: " - Voluptate Velit",
|
|
69
|
-
testimonialAuthorInitials: "VV",
|
|
70
|
-
},
|
|
71
|
-
{
|
|
72
|
-
testimonialText: "Cillum dolore eu fugiat nulla pariatur!",
|
|
73
|
-
testimonialAuthor: " - Laboris Nisi",
|
|
74
|
-
testimonialAuthorInitials: "LN",
|
|
75
|
-
},
|
|
76
|
-
];
|
|
77
|
-
|
|
78
|
-
/**
|
|
79
|
-
* Testimonials section that renders a grid of TestimonialCard items.
|
|
80
|
-
*
|
|
81
|
-
* @remarks
|
|
82
|
-
* - Slot-style overrides match TestimonialCard sub-slots (card, content, text, etc.).
|
|
83
|
-
* - Motion can be disabled via enableMotion.
|
|
84
|
-
*
|
|
85
|
-
* @example
|
|
86
|
-
* <Testimonials testimonials={[{ testimonialText: 'Great!', testimonialAuthor: ' - Jane', testimonialAuthorInitials: 'J' }]} />
|
|
87
|
-
*/
|
|
88
|
-
export function Testimonials({
|
|
89
|
-
id,
|
|
90
|
-
className,
|
|
91
|
-
testimonials = defaultTestimonialData,
|
|
92
|
-
testimonialSectionHeader = "What Our Customers Say",
|
|
93
|
-
enableMotion = true,
|
|
94
|
-
section = { className: "py-16 px-6 bg-muted" },
|
|
95
|
-
container = { className: "max-w-7xl mx-auto" },
|
|
96
|
-
header = { className: "text-center mb-12" },
|
|
97
|
-
heading = {
|
|
98
|
-
className: "text-3xl md:text-4xl font-bold font-poppins text-foreground",
|
|
99
|
-
},
|
|
100
|
-
grid = { className: "grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8" },
|
|
101
|
-
card = {
|
|
102
|
-
className:
|
|
103
|
-
"bg-card/90 backdrop-blur p-6 rounded-lg shadow-md transition-transform duration-200 hover:-translate-y-1 border border-border bg-[var(--card-bg)] text-[var(--card-fg)] border-[var(--card-border)] shadow-[var(--card-shadow)]",
|
|
104
|
-
},
|
|
105
|
-
content = { className: "flex flex-col space-y-4" },
|
|
106
|
-
text = {
|
|
107
|
-
className:
|
|
108
|
-
"text-card-foreground text-base leading-relaxed italic font-inter text-[var(--card-fg)]",
|
|
109
|
-
},
|
|
110
|
-
author = {
|
|
111
|
-
className:
|
|
112
|
-
"text-muted-foreground text-sm font-medium font-poppins text-[var(--card-muted-fg)]",
|
|
113
|
-
},
|
|
114
|
-
avatar = {
|
|
115
|
-
className:
|
|
116
|
-
"w-12 h-12 bg-primary text-primary-foreground rounded-full flex items-center justify-center text-lg font-bold bg-[var(--badge-bg)] text-[var(--badge-fg)] border-[var(--badge-border)]",
|
|
117
|
-
},
|
|
118
|
-
avatarText = { className: "text-primary-foreground font-bold" },
|
|
119
|
-
ariaLabel = "Testimonials section",
|
|
120
|
-
}: TestimonialsProps) {
|
|
121
|
-
return (
|
|
122
|
-
<section
|
|
123
|
-
id={id || "testimonials"}
|
|
124
|
-
className={cn(section.className, className)}
|
|
125
|
-
aria-label={ariaLabel}
|
|
126
|
-
>
|
|
127
|
-
<div className={container.className}>
|
|
128
|
-
{/* Section Header */}
|
|
129
|
-
<div className={header.className}>
|
|
130
|
-
<h2 className={heading.className}>{testimonialSectionHeader}</h2>
|
|
131
|
-
</div>
|
|
132
|
-
|
|
133
|
-
{/* Testimonials Grid */}
|
|
134
|
-
<div className={grid.className}>
|
|
135
|
-
{testimonials.map((testimonial, index) => (
|
|
136
|
-
<TestimonialCard
|
|
137
|
-
key={index}
|
|
138
|
-
testimonialText={testimonial.testimonialText}
|
|
139
|
-
testimonialAuthor={testimonial.testimonialAuthor}
|
|
140
|
-
testimonialAuthorInitials={testimonial.testimonialAuthorInitials}
|
|
141
|
-
card={{
|
|
142
|
-
className: cn(
|
|
143
|
-
card.className,
|
|
144
|
-
!enableMotion && "transition-none hover:!translate-y-0",
|
|
145
|
-
),
|
|
146
|
-
}}
|
|
147
|
-
content={content}
|
|
148
|
-
text={text}
|
|
149
|
-
author={author}
|
|
150
|
-
avatar={avatar}
|
|
151
|
-
avatarText={avatarText}
|
|
152
|
-
/>
|
|
153
|
-
))}
|
|
154
|
-
</div>
|
|
155
|
-
</div>
|
|
156
|
-
</section>
|
|
157
|
-
);
|
|
158
|
-
}
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import React from "react";
|
|
4
|
+
import { cn } from "@/lib/utils";
|
|
5
|
+
import { TestimonialCard } from "@/components/ui/testimonial-card";
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Data used to render a TestimonialCard.
|
|
9
|
+
* @public
|
|
10
|
+
*/
|
|
11
|
+
export interface TestimonialCardData {
|
|
12
|
+
/** The testimonial quote text */
|
|
13
|
+
testimonialText: string;
|
|
14
|
+
/** The author's display name (prefixed with hyphen in defaults) */
|
|
15
|
+
testimonialAuthor: string;
|
|
16
|
+
/** Author initials displayed in the avatar */
|
|
17
|
+
testimonialAuthorInitials: string;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Props for the Testimonials section component.
|
|
22
|
+
*
|
|
23
|
+
* @remarks
|
|
24
|
+
* - Styling: slot-style className overrides are merged after defaults via cn().
|
|
25
|
+
* - Motion: enableMotion toggles card hover transitions.
|
|
26
|
+
* - Accessibility: semantic <section> with aria-label.
|
|
27
|
+
*/
|
|
28
|
+
export interface TestimonialsProps {
|
|
29
|
+
/** Optional id */
|
|
30
|
+
id?: string;
|
|
31
|
+
/** Root className merged into slots */
|
|
32
|
+
className?: string;
|
|
33
|
+
|
|
34
|
+
/** Testimonial items to render. @defaultValue defaultTestimonialData */
|
|
35
|
+
testimonials?: TestimonialCardData[];
|
|
36
|
+
/** Heading displayed above the grid. @defaultValue "What Our Customers Say" */
|
|
37
|
+
testimonialSectionHeader?: string;
|
|
38
|
+
|
|
39
|
+
/** When false, disables hover transitions on cards */
|
|
40
|
+
enableMotion?: boolean;
|
|
41
|
+
|
|
42
|
+
/** Slot-style overrides */
|
|
43
|
+
section?: { className?: string };
|
|
44
|
+
container?: { className?: string };
|
|
45
|
+
header?: { className?: string };
|
|
46
|
+
heading?: { className?: string };
|
|
47
|
+
grid?: { className?: string };
|
|
48
|
+
card?: { className?: string };
|
|
49
|
+
content?: { className?: string };
|
|
50
|
+
text?: { className?: string };
|
|
51
|
+
author?: { className?: string };
|
|
52
|
+
avatar?: { className?: string };
|
|
53
|
+
avatarText?: { className?: string };
|
|
54
|
+
|
|
55
|
+
/** ARIA label for the section. @defaultValue "Testimonials section" */
|
|
56
|
+
ariaLabel?: string;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
const defaultTestimonialData: TestimonialCardData[] = [
|
|
60
|
+
{
|
|
61
|
+
testimonialText: "Lorem ipsum dolor sit amet! Consectetur adipiscing elit.",
|
|
62
|
+
testimonialAuthor: " - Cillum Dolore",
|
|
63
|
+
testimonialAuthorInitials: "CD",
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
testimonialText:
|
|
67
|
+
"Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi!",
|
|
68
|
+
testimonialAuthor: " - Voluptate Velit",
|
|
69
|
+
testimonialAuthorInitials: "VV",
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
testimonialText: "Cillum dolore eu fugiat nulla pariatur!",
|
|
73
|
+
testimonialAuthor: " - Laboris Nisi",
|
|
74
|
+
testimonialAuthorInitials: "LN",
|
|
75
|
+
},
|
|
76
|
+
];
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* Testimonials section that renders a grid of TestimonialCard items.
|
|
80
|
+
*
|
|
81
|
+
* @remarks
|
|
82
|
+
* - Slot-style overrides match TestimonialCard sub-slots (card, content, text, etc.).
|
|
83
|
+
* - Motion can be disabled via enableMotion.
|
|
84
|
+
*
|
|
85
|
+
* @example
|
|
86
|
+
* <Testimonials testimonials={[{ testimonialText: 'Great!', testimonialAuthor: ' - Jane', testimonialAuthorInitials: 'J' }]} />
|
|
87
|
+
*/
|
|
88
|
+
export function Testimonials({
|
|
89
|
+
id,
|
|
90
|
+
className,
|
|
91
|
+
testimonials = defaultTestimonialData,
|
|
92
|
+
testimonialSectionHeader = "What Our Customers Say",
|
|
93
|
+
enableMotion = true,
|
|
94
|
+
section = { className: "py-16 px-6 bg-muted" },
|
|
95
|
+
container = { className: "max-w-7xl mx-auto" },
|
|
96
|
+
header = { className: "text-center mb-12" },
|
|
97
|
+
heading = {
|
|
98
|
+
className: "text-3xl md:text-4xl font-bold font-poppins text-foreground",
|
|
99
|
+
},
|
|
100
|
+
grid = { className: "grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8" },
|
|
101
|
+
card = {
|
|
102
|
+
className:
|
|
103
|
+
"bg-card/90 backdrop-blur p-6 rounded-lg shadow-md transition-transform duration-200 hover:-translate-y-1 border border-border bg-[var(--card-bg)] text-[var(--card-fg)] border-[var(--card-border)] shadow-[var(--card-shadow)]",
|
|
104
|
+
},
|
|
105
|
+
content = { className: "flex flex-col space-y-4" },
|
|
106
|
+
text = {
|
|
107
|
+
className:
|
|
108
|
+
"text-card-foreground text-base leading-relaxed italic font-inter text-[var(--card-fg)]",
|
|
109
|
+
},
|
|
110
|
+
author = {
|
|
111
|
+
className:
|
|
112
|
+
"text-muted-foreground text-sm font-medium font-poppins text-[var(--card-muted-fg)]",
|
|
113
|
+
},
|
|
114
|
+
avatar = {
|
|
115
|
+
className:
|
|
116
|
+
"w-12 h-12 bg-primary text-primary-foreground rounded-full flex items-center justify-center text-lg font-bold bg-[var(--badge-bg)] text-[var(--badge-fg)] border-[var(--badge-border)]",
|
|
117
|
+
},
|
|
118
|
+
avatarText = { className: "text-primary-foreground font-bold" },
|
|
119
|
+
ariaLabel = "Testimonials section",
|
|
120
|
+
}: TestimonialsProps) {
|
|
121
|
+
return (
|
|
122
|
+
<section
|
|
123
|
+
id={id || "testimonials"}
|
|
124
|
+
className={cn(section.className, className)}
|
|
125
|
+
aria-label={ariaLabel}
|
|
126
|
+
>
|
|
127
|
+
<div className={container.className}>
|
|
128
|
+
{/* Section Header */}
|
|
129
|
+
<div className={header.className}>
|
|
130
|
+
<h2 className={heading.className}>{testimonialSectionHeader}</h2>
|
|
131
|
+
</div>
|
|
132
|
+
|
|
133
|
+
{/* Testimonials Grid */}
|
|
134
|
+
<div className={grid.className}>
|
|
135
|
+
{testimonials.map((testimonial, index) => (
|
|
136
|
+
<TestimonialCard
|
|
137
|
+
key={index}
|
|
138
|
+
testimonialText={testimonial.testimonialText}
|
|
139
|
+
testimonialAuthor={testimonial.testimonialAuthor}
|
|
140
|
+
testimonialAuthorInitials={testimonial.testimonialAuthorInitials}
|
|
141
|
+
card={{
|
|
142
|
+
className: cn(
|
|
143
|
+
card.className,
|
|
144
|
+
!enableMotion && "transition-none hover:!translate-y-0",
|
|
145
|
+
),
|
|
146
|
+
}}
|
|
147
|
+
content={content}
|
|
148
|
+
text={text}
|
|
149
|
+
author={author}
|
|
150
|
+
avatar={avatar}
|
|
151
|
+
avatarText={avatarText}
|
|
152
|
+
/>
|
|
153
|
+
))}
|
|
154
|
+
</div>
|
|
155
|
+
</div>
|
|
156
|
+
</section>
|
|
157
|
+
);
|
|
158
|
+
}
|
|
@@ -1,162 +1,162 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
|
|
3
|
-
import React from "react";
|
|
4
|
-
import { cn } from "@/lib/utils";
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* A single trust badge (stat or certification).
|
|
8
|
-
* @public
|
|
9
|
-
*/
|
|
10
|
-
export interface TrustBadgeData {
|
|
11
|
-
/** Main badge text (e.g., "99.9% Uptime") */
|
|
12
|
-
badgeText: string;
|
|
13
|
-
/** Optional short descriptor above/below the text */
|
|
14
|
-
badgeDescription?: string;
|
|
15
|
-
/** Optional icon/emoji representation */
|
|
16
|
-
badgeIcon?: string;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
/**
|
|
20
|
-
* Props for the TrustBadges section component.
|
|
21
|
-
*
|
|
22
|
-
* @remarks
|
|
23
|
-
* - Layout: choose horizontal row or vertical stack via layout.
|
|
24
|
-
* - Styling: slot-style overrides are merged after defaults via cn().
|
|
25
|
-
* - Motion: enableMotion toggles hover scale.
|
|
26
|
-
*/
|
|
27
|
-
export interface TrustBadgesProps {
|
|
28
|
-
/** Optional id on root. @defaultValue "trust-badges" */
|
|
29
|
-
id?: string;
|
|
30
|
-
/** Root className merged into section slot */
|
|
31
|
-
className?: string;
|
|
32
|
-
|
|
33
|
-
/** Badges to display. @defaultValue defaultTrustBadgeData */
|
|
34
|
-
badges?: TrustBadgeData[];
|
|
35
|
-
/** Optional heading above badges */
|
|
36
|
-
trustBadgesSectionHeader?: string;
|
|
37
|
-
|
|
38
|
-
/** Slot-style overrides */
|
|
39
|
-
section?: { className?: string };
|
|
40
|
-
container?: { className?: string };
|
|
41
|
-
header?: { className?: string };
|
|
42
|
-
heading?: { className?: string };
|
|
43
|
-
badgesContainer?: { className?: string };
|
|
44
|
-
badge?: { className?: string };
|
|
45
|
-
badgeContent?: { className?: string };
|
|
46
|
-
icon?: { className?: string };
|
|
47
|
-
description?: { className?: string };
|
|
48
|
-
text?: { className?: string };
|
|
49
|
-
|
|
50
|
-
/** Layout orientation. @defaultValue "horizontal" */
|
|
51
|
-
layout?: "horizontal" | "vertical";
|
|
52
|
-
/** When false, disables hover scale */
|
|
53
|
-
enableMotion?: boolean;
|
|
54
|
-
/** ARIA label for the section. @defaultValue "Trust badges section" */
|
|
55
|
-
ariaLabel?: string;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
const defaultTrustBadgeData: TrustBadgeData[] = [
|
|
59
|
-
{
|
|
60
|
-
badgeText: "10,000+ businesses",
|
|
61
|
-
badgeDescription: "Trusted by",
|
|
62
|
-
badgeIcon: "📊",
|
|
63
|
-
},
|
|
64
|
-
{
|
|
65
|
-
badgeText: "SOC 2 Compliant",
|
|
66
|
-
badgeDescription: "Enterprise security",
|
|
67
|
-
badgeIcon: "🔒",
|
|
68
|
-
},
|
|
69
|
-
{
|
|
70
|
-
badgeText: "99.9% Uptime",
|
|
71
|
-
badgeDescription: "Reliable service",
|
|
72
|
-
badgeIcon: "⚡",
|
|
73
|
-
},
|
|
74
|
-
];
|
|
75
|
-
|
|
76
|
-
/**
|
|
77
|
-
* Compact section to showcase trust signals like usage stats and compliance.
|
|
78
|
-
*
|
|
79
|
-
* @remarks
|
|
80
|
-
* - Horizontal by default; switch to vertical with layout="vertical".
|
|
81
|
-
* - Hover motion can be disabled via enableMotion.
|
|
82
|
-
*
|
|
83
|
-
* @example
|
|
84
|
-
* <TrustBadges badges={[{ badgeText: 'SOC 2', badgeDescription: 'Security', badgeIcon: '🔒' }]} />
|
|
85
|
-
*/
|
|
86
|
-
export function TrustBadges({
|
|
87
|
-
id,
|
|
88
|
-
className,
|
|
89
|
-
badges = defaultTrustBadgeData,
|
|
90
|
-
trustBadgesSectionHeader,
|
|
91
|
-
section = { className: "py-8 px-6 bg-muted" },
|
|
92
|
-
container = { className: "max-w-7xl mx-auto" },
|
|
93
|
-
header = { className: "text-center mb-6" },
|
|
94
|
-
heading = {
|
|
95
|
-
className: "text-xl font-semibold text-foreground text-[var(--heading-fg)]",
|
|
96
|
-
},
|
|
97
|
-
badgesContainer = {
|
|
98
|
-
className:
|
|
99
|
-
"flex flex-col md:flex-row justify-center items-center gap-8 flex-wrap",
|
|
100
|
-
},
|
|
101
|
-
badge = {
|
|
102
|
-
className:
|
|
103
|
-
"flex flex-col items-center text-center min-w-[200px] transition-all duration-300 ease-in-out hover:scale-[1.02]",
|
|
104
|
-
},
|
|
105
|
-
badgeContent = { className: "flex flex-col items-center space-y-2" },
|
|
106
|
-
icon = { className: "text-2xl mb-2" },
|
|
107
|
-
description = {
|
|
108
|
-
className:
|
|
109
|
-
"text-sm font-medium text-muted-foreground text-[var(--card-muted-fg)]",
|
|
110
|
-
},
|
|
111
|
-
text = {
|
|
112
|
-
className: "text-lg font-bold text-foreground text-[var(--card-fg)]",
|
|
113
|
-
},
|
|
114
|
-
layout = "horizontal",
|
|
115
|
-
enableMotion = true,
|
|
116
|
-
ariaLabel = "Trust badges section",
|
|
117
|
-
}: TrustBadgesProps) {
|
|
118
|
-
const containerClasses =
|
|
119
|
-
layout === "vertical"
|
|
120
|
-
? "flex flex-col justify-center items-center gap-8"
|
|
121
|
-
: badgesContainer.className;
|
|
122
|
-
|
|
123
|
-
return (
|
|
124
|
-
<section
|
|
125
|
-
id={id || "trust-badges"}
|
|
126
|
-
className={cn(section.className, className)}
|
|
127
|
-
aria-label={ariaLabel}
|
|
128
|
-
>
|
|
129
|
-
<div className={container.className}>
|
|
130
|
-
{trustBadgesSectionHeader && (
|
|
131
|
-
<div className={header.className}>
|
|
132
|
-
<h2 className={heading.className}>{trustBadgesSectionHeader}</h2>
|
|
133
|
-
</div>
|
|
134
|
-
)}
|
|
135
|
-
|
|
136
|
-
<div className={containerClasses}>
|
|
137
|
-
{badges.map((badgeData, index) => (
|
|
138
|
-
<div
|
|
139
|
-
key={index}
|
|
140
|
-
className={cn(
|
|
141
|
-
badge.className,
|
|
142
|
-
!enableMotion && "transition-none hover:!scale-100",
|
|
143
|
-
)}
|
|
144
|
-
>
|
|
145
|
-
<div className={badgeContent.className}>
|
|
146
|
-
{badgeData.badgeIcon && (
|
|
147
|
-
<div className={icon.className}>{badgeData.badgeIcon}</div>
|
|
148
|
-
)}
|
|
149
|
-
{badgeData.badgeDescription && (
|
|
150
|
-
<p className={description.className}>
|
|
151
|
-
{badgeData.badgeDescription}
|
|
152
|
-
</p>
|
|
153
|
-
)}
|
|
154
|
-
<p className={text.className}>{badgeData.badgeText}</p>
|
|
155
|
-
</div>
|
|
156
|
-
</div>
|
|
157
|
-
))}
|
|
158
|
-
</div>
|
|
159
|
-
</div>
|
|
160
|
-
</section>
|
|
161
|
-
);
|
|
162
|
-
}
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import React from "react";
|
|
4
|
+
import { cn } from "@/lib/utils";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* A single trust badge (stat or certification).
|
|
8
|
+
* @public
|
|
9
|
+
*/
|
|
10
|
+
export interface TrustBadgeData {
|
|
11
|
+
/** Main badge text (e.g., "99.9% Uptime") */
|
|
12
|
+
badgeText: string;
|
|
13
|
+
/** Optional short descriptor above/below the text */
|
|
14
|
+
badgeDescription?: string;
|
|
15
|
+
/** Optional icon/emoji representation */
|
|
16
|
+
badgeIcon?: string;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* Props for the TrustBadges section component.
|
|
21
|
+
*
|
|
22
|
+
* @remarks
|
|
23
|
+
* - Layout: choose horizontal row or vertical stack via layout.
|
|
24
|
+
* - Styling: slot-style overrides are merged after defaults via cn().
|
|
25
|
+
* - Motion: enableMotion toggles hover scale.
|
|
26
|
+
*/
|
|
27
|
+
export interface TrustBadgesProps {
|
|
28
|
+
/** Optional id on root. @defaultValue "trust-badges" */
|
|
29
|
+
id?: string;
|
|
30
|
+
/** Root className merged into section slot */
|
|
31
|
+
className?: string;
|
|
32
|
+
|
|
33
|
+
/** Badges to display. @defaultValue defaultTrustBadgeData */
|
|
34
|
+
badges?: TrustBadgeData[];
|
|
35
|
+
/** Optional heading above badges */
|
|
36
|
+
trustBadgesSectionHeader?: string;
|
|
37
|
+
|
|
38
|
+
/** Slot-style overrides */
|
|
39
|
+
section?: { className?: string };
|
|
40
|
+
container?: { className?: string };
|
|
41
|
+
header?: { className?: string };
|
|
42
|
+
heading?: { className?: string };
|
|
43
|
+
badgesContainer?: { className?: string };
|
|
44
|
+
badge?: { className?: string };
|
|
45
|
+
badgeContent?: { className?: string };
|
|
46
|
+
icon?: { className?: string };
|
|
47
|
+
description?: { className?: string };
|
|
48
|
+
text?: { className?: string };
|
|
49
|
+
|
|
50
|
+
/** Layout orientation. @defaultValue "horizontal" */
|
|
51
|
+
layout?: "horizontal" | "vertical";
|
|
52
|
+
/** When false, disables hover scale */
|
|
53
|
+
enableMotion?: boolean;
|
|
54
|
+
/** ARIA label for the section. @defaultValue "Trust badges section" */
|
|
55
|
+
ariaLabel?: string;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
const defaultTrustBadgeData: TrustBadgeData[] = [
|
|
59
|
+
{
|
|
60
|
+
badgeText: "10,000+ businesses",
|
|
61
|
+
badgeDescription: "Trusted by",
|
|
62
|
+
badgeIcon: "📊",
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
badgeText: "SOC 2 Compliant",
|
|
66
|
+
badgeDescription: "Enterprise security",
|
|
67
|
+
badgeIcon: "🔒",
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
badgeText: "99.9% Uptime",
|
|
71
|
+
badgeDescription: "Reliable service",
|
|
72
|
+
badgeIcon: "⚡",
|
|
73
|
+
},
|
|
74
|
+
];
|
|
75
|
+
|
|
76
|
+
/**
|
|
77
|
+
* Compact section to showcase trust signals like usage stats and compliance.
|
|
78
|
+
*
|
|
79
|
+
* @remarks
|
|
80
|
+
* - Horizontal by default; switch to vertical with layout="vertical".
|
|
81
|
+
* - Hover motion can be disabled via enableMotion.
|
|
82
|
+
*
|
|
83
|
+
* @example
|
|
84
|
+
* <TrustBadges badges={[{ badgeText: 'SOC 2', badgeDescription: 'Security', badgeIcon: '🔒' }]} />
|
|
85
|
+
*/
|
|
86
|
+
export function TrustBadges({
|
|
87
|
+
id,
|
|
88
|
+
className,
|
|
89
|
+
badges = defaultTrustBadgeData,
|
|
90
|
+
trustBadgesSectionHeader,
|
|
91
|
+
section = { className: "py-8 px-6 bg-muted" },
|
|
92
|
+
container = { className: "max-w-7xl mx-auto" },
|
|
93
|
+
header = { className: "text-center mb-6" },
|
|
94
|
+
heading = {
|
|
95
|
+
className: "text-xl font-semibold text-foreground text-[var(--heading-fg)]",
|
|
96
|
+
},
|
|
97
|
+
badgesContainer = {
|
|
98
|
+
className:
|
|
99
|
+
"flex flex-col md:flex-row justify-center items-center gap-8 flex-wrap",
|
|
100
|
+
},
|
|
101
|
+
badge = {
|
|
102
|
+
className:
|
|
103
|
+
"flex flex-col items-center text-center min-w-[200px] transition-all duration-300 ease-in-out hover:scale-[1.02]",
|
|
104
|
+
},
|
|
105
|
+
badgeContent = { className: "flex flex-col items-center space-y-2" },
|
|
106
|
+
icon = { className: "text-2xl mb-2" },
|
|
107
|
+
description = {
|
|
108
|
+
className:
|
|
109
|
+
"text-sm font-medium text-muted-foreground text-[var(--card-muted-fg)]",
|
|
110
|
+
},
|
|
111
|
+
text = {
|
|
112
|
+
className: "text-lg font-bold text-foreground text-[var(--card-fg)]",
|
|
113
|
+
},
|
|
114
|
+
layout = "horizontal",
|
|
115
|
+
enableMotion = true,
|
|
116
|
+
ariaLabel = "Trust badges section",
|
|
117
|
+
}: TrustBadgesProps) {
|
|
118
|
+
const containerClasses =
|
|
119
|
+
layout === "vertical"
|
|
120
|
+
? "flex flex-col justify-center items-center gap-8"
|
|
121
|
+
: badgesContainer.className;
|
|
122
|
+
|
|
123
|
+
return (
|
|
124
|
+
<section
|
|
125
|
+
id={id || "trust-badges"}
|
|
126
|
+
className={cn(section.className, className)}
|
|
127
|
+
aria-label={ariaLabel}
|
|
128
|
+
>
|
|
129
|
+
<div className={container.className}>
|
|
130
|
+
{trustBadgesSectionHeader && (
|
|
131
|
+
<div className={header.className}>
|
|
132
|
+
<h2 className={heading.className}>{trustBadgesSectionHeader}</h2>
|
|
133
|
+
</div>
|
|
134
|
+
)}
|
|
135
|
+
|
|
136
|
+
<div className={containerClasses}>
|
|
137
|
+
{badges.map((badgeData, index) => (
|
|
138
|
+
<div
|
|
139
|
+
key={index}
|
|
140
|
+
className={cn(
|
|
141
|
+
badge.className,
|
|
142
|
+
!enableMotion && "transition-none hover:!scale-100",
|
|
143
|
+
)}
|
|
144
|
+
>
|
|
145
|
+
<div className={badgeContent.className}>
|
|
146
|
+
{badgeData.badgeIcon && (
|
|
147
|
+
<div className={icon.className}>{badgeData.badgeIcon}</div>
|
|
148
|
+
)}
|
|
149
|
+
{badgeData.badgeDescription && (
|
|
150
|
+
<p className={description.className}>
|
|
151
|
+
{badgeData.badgeDescription}
|
|
152
|
+
</p>
|
|
153
|
+
)}
|
|
154
|
+
<p className={text.className}>{badgeData.badgeText}</p>
|
|
155
|
+
</div>
|
|
156
|
+
</div>
|
|
157
|
+
))}
|
|
158
|
+
</div>
|
|
159
|
+
</div>
|
|
160
|
+
</section>
|
|
161
|
+
);
|
|
162
|
+
}
|