@voila.dev/ui-landing 1.1.9 → 1.1.10
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/package.json +1 -1
- package/src/components/article-card.tsx +2 -2
- package/src/components/article-tags.tsx +1 -1
- package/src/components/bento-grid.tsx +2 -2
- package/src/components/cta-banner.tsx +2 -2
- package/src/components/eyebrow.tsx +2 -2
- package/src/components/numbered-cards.tsx +2 -2
- package/src/components/prose-article.tsx +2 -2
- package/src/components/section-variants.ts +5 -5
- package/src/components/testimonial-grid.tsx +8 -5
- package/src/lib/tones.ts +22 -24
package/package.json
CHANGED
|
@@ -76,7 +76,7 @@ function ImageFallback({
|
|
|
76
76
|
<div
|
|
77
77
|
data-slot="article-card-image-fallback"
|
|
78
78
|
className={cn(
|
|
79
|
-
"relative aspect-video overflow-hidden rounded-t-lg bg-linear-to-br from-
|
|
79
|
+
"relative aspect-video overflow-hidden rounded-t-lg bg-linear-to-br from-brand/20 to-highlight/20",
|
|
80
80
|
className,
|
|
81
81
|
)}
|
|
82
82
|
{...props}
|
|
@@ -107,7 +107,7 @@ function Title({ className, ...props }: React.ComponentProps<"h3">) {
|
|
|
107
107
|
<h3
|
|
108
108
|
data-slot="article-card-title"
|
|
109
109
|
className={cn(
|
|
110
|
-
"mb-2 line-clamp-2 text-lg font-semibold transition-colors group-hover:text-
|
|
110
|
+
"mb-2 line-clamp-2 text-lg font-semibold transition-colors group-hover:text-brand",
|
|
111
111
|
className,
|
|
112
112
|
)}
|
|
113
113
|
{...props}
|
|
@@ -17,7 +17,7 @@ function Tag({ className, ...props }: React.ComponentProps<"span">) {
|
|
|
17
17
|
<span
|
|
18
18
|
data-slot="article-tag"
|
|
19
19
|
className={cn(
|
|
20
|
-
"inline-flex items-center rounded-full bg-
|
|
20
|
+
"inline-flex items-center rounded-full bg-brand/10 px-2.5 py-0.5 text-xs font-medium text-brand transition-colors",
|
|
21
21
|
className,
|
|
22
22
|
)}
|
|
23
23
|
{...props}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { cn } from "@voila.dev/ui/lib/utils";
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import { accentHighlightBlobClass, brandGradientClass } from "#/lib/tones.ts";
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* Bento grid with a featured gradient tile. Compose: Root > FeaturedItem (FeaturedContent >
|
|
@@ -38,7 +38,7 @@ function FeaturedItem({
|
|
|
38
38
|
<div
|
|
39
39
|
className={cn(
|
|
40
40
|
"pointer-events-none absolute -bottom-20 -left-10 h-56 w-56 rounded-full blur-3xl",
|
|
41
|
-
|
|
41
|
+
accentHighlightBlobClass,
|
|
42
42
|
)}
|
|
43
43
|
/>
|
|
44
44
|
{children}
|
|
@@ -4,7 +4,7 @@ import { Container, type ContainerProps } from "#/components/container.tsx";
|
|
|
4
4
|
import { Heading, type HeadingProps } from "#/components/heading.tsx";
|
|
5
5
|
import { Section, type SectionProps } from "#/components/section.tsx";
|
|
6
6
|
import { Text, type TextProps } from "#/components/text.tsx";
|
|
7
|
-
import {
|
|
7
|
+
import { accentHighlightBlobClass, brandGradientClass } from "#/lib/tones.ts";
|
|
8
8
|
|
|
9
9
|
/**
|
|
10
10
|
* Gradient call-to-action banner with decorative blur blobs. Compose: Root > Title,
|
|
@@ -42,7 +42,7 @@ function Root({
|
|
|
42
42
|
<div
|
|
43
43
|
className={cn(
|
|
44
44
|
"pointer-events-none absolute -bottom-20 -left-10 h-56 w-56 rounded-full blur-3xl",
|
|
45
|
-
|
|
45
|
+
accentHighlightBlobClass,
|
|
46
46
|
)}
|
|
47
47
|
/>
|
|
48
48
|
|
|
@@ -10,8 +10,8 @@ import {
|
|
|
10
10
|
} from "#/lib/tones.ts";
|
|
11
11
|
|
|
12
12
|
/**
|
|
13
|
-
* The badge pill that opens most sections ("
|
|
14
|
-
*
|
|
13
|
+
* The badge pill that opens most sections ("New platform", "For
|
|
14
|
+
* clients"…): tinted rounded-full chip with an optional pulse dot or icon and a
|
|
15
15
|
* label in the tone color. Reproduces the inline pattern of
|
|
16
16
|
* the source design.
|
|
17
17
|
*/
|
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
} from "#/lib/tones.ts";
|
|
10
10
|
|
|
11
11
|
/**
|
|
12
|
-
* Grid of numbered step cards ("
|
|
12
|
+
* Grid of numbered step cards ("Step 1/2/3"). Compose: Root (tone, columns) > Card >
|
|
13
13
|
* CardHeader (CardIcon + CardLabel) + CardTitle + CardDescription.
|
|
14
14
|
*/
|
|
15
15
|
|
|
@@ -100,7 +100,7 @@ function CardIcon({ className, ...props }: React.ComponentProps<"span">) {
|
|
|
100
100
|
);
|
|
101
101
|
}
|
|
102
102
|
|
|
103
|
-
/** The "
|
|
103
|
+
/** The "Step N" label next to the icon. */
|
|
104
104
|
function CardLabel({ className, ...props }: React.ComponentProps<"span">) {
|
|
105
105
|
return (
|
|
106
106
|
<span
|
|
@@ -17,9 +17,9 @@ function ProseArticle({
|
|
|
17
17
|
{
|
|
18
18
|
className: cn(
|
|
19
19
|
"prose prose-lg md:prose-xl mx-auto max-w-none",
|
|
20
|
-
"prose-blockquote:border-l-
|
|
20
|
+
"prose-blockquote:border-l-brand prose-blockquote:bg-muted/50 prose-blockquote:py-1 prose-blockquote:pl-6 prose-blockquote:not-italic",
|
|
21
21
|
"prose-p:text-muted-foreground",
|
|
22
|
-
"prose-a:text-
|
|
22
|
+
"prose-a:text-brand",
|
|
23
23
|
"prose-strong:text-foreground",
|
|
24
24
|
"prose-img:rounded-xl",
|
|
25
25
|
className,
|
|
@@ -13,12 +13,12 @@ export const sectionVariants = cva({
|
|
|
13
13
|
background: {
|
|
14
14
|
default: "bg-background",
|
|
15
15
|
muted: "bg-muted",
|
|
16
|
-
|
|
16
|
+
brand: "bg-brand text-primary-foreground",
|
|
17
17
|
gradient: "bg-gradient-to-br from-background via-background to-muted",
|
|
18
18
|
"gradient-primary":
|
|
19
19
|
"bg-gradient-to-br from-primary/5 via-background to-primary/10",
|
|
20
|
-
"gradient-
|
|
21
|
-
"bg-gradient-to-br from-
|
|
20
|
+
"gradient-brand":
|
|
21
|
+
"bg-gradient-to-br from-brand/5 via-background to-brand/10",
|
|
22
22
|
},
|
|
23
23
|
},
|
|
24
24
|
defaultVariants: {
|
|
@@ -40,8 +40,8 @@ export const sectionSpacingOptions = [
|
|
|
40
40
|
export const sectionBackgroundOptions = [
|
|
41
41
|
"default",
|
|
42
42
|
"muted",
|
|
43
|
-
"
|
|
43
|
+
"brand",
|
|
44
44
|
"gradient",
|
|
45
45
|
"gradient-primary",
|
|
46
|
-
"gradient-
|
|
46
|
+
"gradient-brand",
|
|
47
47
|
] as const satisfies readonly NonNullable<SectionVariants["background"]>[];
|
|
@@ -2,7 +2,10 @@ import { QuotesIcon, StarIcon } from "@phosphor-icons/react";
|
|
|
2
2
|
import { cva, type VariantProps } from "@voila.dev/ui/cva";
|
|
3
3
|
import { cn } from "@voila.dev/ui/lib/utils";
|
|
4
4
|
|
|
5
|
-
import {
|
|
5
|
+
import {
|
|
6
|
+
accentHighlightStarClass,
|
|
7
|
+
accentHighlightTintClass,
|
|
8
|
+
} from "#/lib/tones.ts";
|
|
6
9
|
|
|
7
10
|
/**
|
|
8
11
|
* Testimonial figure cards (quote, avatar initial, star rating). Compose: Root > Item >
|
|
@@ -67,7 +70,7 @@ function Footer({ className, ...props }: React.ComponentProps<"div">) {
|
|
|
67
70
|
<div
|
|
68
71
|
data-slot="testimonial-footer"
|
|
69
72
|
className={cn(
|
|
70
|
-
"mt-6 flex items-center gap-3 border-t border-border/60 pt-5",
|
|
73
|
+
"mt-6 flex flex-wrap items-center gap-3 border-t border-border/60 pt-5",
|
|
71
74
|
className,
|
|
72
75
|
)}
|
|
73
76
|
{...props}
|
|
@@ -80,7 +83,7 @@ const testimonialAvatarVariants = cva({
|
|
|
80
83
|
variants: {
|
|
81
84
|
accent: {
|
|
82
85
|
primary: "bg-primary/10 text-primary",
|
|
83
|
-
|
|
86
|
+
highlight: accentHighlightTintClass,
|
|
84
87
|
},
|
|
85
88
|
},
|
|
86
89
|
defaultVariants: {
|
|
@@ -92,7 +95,7 @@ type TestimonialAvatarVariants = VariantProps<typeof testimonialAvatarVariants>;
|
|
|
92
95
|
|
|
93
96
|
const testimonialAvatarAccentOptions = [
|
|
94
97
|
"primary",
|
|
95
|
-
"
|
|
98
|
+
"highlight",
|
|
96
99
|
] as const satisfies readonly NonNullable<
|
|
97
100
|
TestimonialAvatarVariants["accent"]
|
|
98
101
|
>[];
|
|
@@ -158,7 +161,7 @@ function Rating({ count = 5, className, ...props }: TestimonialRatingProps) {
|
|
|
158
161
|
// Stars are a static decorative sequence — the index is the identity.
|
|
159
162
|
key={index}
|
|
160
163
|
weight="fill"
|
|
161
|
-
className={cn("h-3.5 w-3.5",
|
|
164
|
+
className={cn("h-3.5 w-3.5", accentHighlightStarClass)}
|
|
162
165
|
/>
|
|
163
166
|
))}
|
|
164
167
|
</div>
|
package/src/lib/tones.ts
CHANGED
|
@@ -7,8 +7,8 @@
|
|
|
7
7
|
|
|
8
8
|
export const toneOptions = [
|
|
9
9
|
"primary",
|
|
10
|
-
"
|
|
11
|
-
"
|
|
10
|
+
"brand",
|
|
11
|
+
"highlight",
|
|
12
12
|
"destructive",
|
|
13
13
|
"muted",
|
|
14
14
|
] as const;
|
|
@@ -17,41 +17,40 @@ export type Tone = (typeof toneOptions)[number];
|
|
|
17
17
|
|
|
18
18
|
export const toneTextClass: Record<Tone, string> = {
|
|
19
19
|
primary: "text-primary",
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
brand: "text-brand",
|
|
21
|
+
highlight: "text-highlight",
|
|
22
22
|
destructive: "text-destructive",
|
|
23
23
|
muted: "text-muted-foreground",
|
|
24
24
|
};
|
|
25
25
|
|
|
26
26
|
export const toneTintBackgroundClass: Record<Tone, string> = {
|
|
27
27
|
primary: "bg-primary/10",
|
|
28
|
-
|
|
29
|
-
|
|
28
|
+
brand: "bg-brand/10",
|
|
29
|
+
highlight: "bg-highlight/10",
|
|
30
30
|
destructive: "bg-destructive/10",
|
|
31
31
|
muted: "bg-muted",
|
|
32
32
|
};
|
|
33
33
|
|
|
34
34
|
export const toneSolidBackgroundClass: Record<Tone, string> = {
|
|
35
35
|
primary: "bg-primary",
|
|
36
|
-
|
|
37
|
-
|
|
36
|
+
brand: "bg-brand",
|
|
37
|
+
highlight: "bg-highlight",
|
|
38
38
|
destructive: "bg-destructive",
|
|
39
39
|
muted: "bg-muted-foreground",
|
|
40
40
|
};
|
|
41
41
|
|
|
42
42
|
export const toneSolidClass: Record<Tone, string> = {
|
|
43
43
|
primary: "bg-primary text-primary-foreground",
|
|
44
|
-
|
|
45
|
-
|
|
44
|
+
brand: "bg-brand text-brand-foreground",
|
|
45
|
+
highlight: "bg-highlight text-highlight-foreground",
|
|
46
46
|
destructive: "bg-destructive text-white",
|
|
47
47
|
muted: "bg-muted text-muted-foreground",
|
|
48
48
|
};
|
|
49
49
|
|
|
50
50
|
export const toneConnectorLineClass: Record<Tone, string> = {
|
|
51
51
|
primary: "bg-gradient-to-b from-primary via-primary/40 to-primary/10",
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
"bg-gradient-to-b from-organization via-organization/40 to-organization/10",
|
|
52
|
+
brand: "bg-gradient-to-b from-brand via-brand/40 to-brand/10",
|
|
53
|
+
highlight: "bg-gradient-to-b from-highlight via-highlight/40 to-highlight/10",
|
|
55
54
|
destructive:
|
|
56
55
|
"bg-gradient-to-b from-destructive via-destructive/40 to-destructive/10",
|
|
57
56
|
muted: "bg-gradient-to-b from-border via-border/40 to-border/10",
|
|
@@ -59,27 +58,26 @@ export const toneConnectorLineClass: Record<Tone, string> = {
|
|
|
59
58
|
|
|
60
59
|
export const toneHoverBorderClass: Record<Tone, string> = {
|
|
61
60
|
primary: "hover:border-primary/40",
|
|
62
|
-
|
|
63
|
-
|
|
61
|
+
brand: "hover:border-brand/40",
|
|
62
|
+
highlight: "hover:border-highlight/40",
|
|
64
63
|
destructive: "hover:border-destructive/40",
|
|
65
64
|
muted: "hover:border-border",
|
|
66
65
|
};
|
|
67
66
|
|
|
68
67
|
export const tonePanelClass: Record<Tone, string> = {
|
|
69
68
|
primary: "border-primary/20 bg-primary/5",
|
|
70
|
-
|
|
71
|
-
|
|
69
|
+
brand: "border-brand/20 bg-brand/5",
|
|
70
|
+
highlight: "border-highlight/20 bg-highlight/5",
|
|
72
71
|
destructive: "border-destructive/20 bg-destructive/5",
|
|
73
72
|
muted: "border-border bg-muted/50",
|
|
74
73
|
};
|
|
75
74
|
|
|
76
75
|
/*
|
|
77
|
-
* Accent
|
|
78
|
-
*
|
|
79
|
-
* rebuild has shipped (they are close to, but not equal to, the brand roles).
|
|
76
|
+
* Accent classes for marketing highlights - built on the brand roles from
|
|
77
|
+
* `@voila.dev/ui-tokens` so a rebrand is a token change, not a find-and-replace.
|
|
80
78
|
*/
|
|
81
79
|
|
|
82
|
-
export const
|
|
83
|
-
export const
|
|
84
|
-
export const
|
|
85
|
-
export const brandGradientClass = "bg-gradient-to-br from-primary to-
|
|
80
|
+
export const accentHighlightTintClass = "bg-highlight/10 text-highlight";
|
|
81
|
+
export const accentHighlightStarClass = "fill-highlight text-highlight";
|
|
82
|
+
export const accentHighlightBlobClass = "bg-highlight/20";
|
|
83
|
+
export const brandGradientClass = "bg-gradient-to-br from-primary to-brand";
|