Skip to content

Commit 193e682

Browse files
committed
feat: responsive title sizes
1 parent 6052597 commit 193e682

4 files changed

Lines changed: 41 additions & 6 deletions

File tree

src/overrides/Hero.astro

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ const {
2121
size="l"
2222
style={{ marginTop: "var(--cui-spacings-kilo)" }}
2323
color="subtle"
24+
className="subtitle"
2425
>
2526
Docs, guides, and resources to help you accept payments with SumUp.
2627
</Body>
@@ -32,10 +33,21 @@ const {
3233
text-align: center;
3334
}
3435

35-
@media screen and (max-width: 600px) {
36+
@media screen and (max-width: 980px) {
3637
.title {
37-
font-size: var(--cui-display-s-font-size);
38-
line-height: var(--cui-display-s-line-height);
38+
font-size: var(--cui-headline-l-font-size);
39+
line-height: var(--cui-headline-l-line-height);
40+
}
41+
}
42+
43+
@media screen and (max-width: 520px) {
44+
.title {
45+
font-size: var(--cui-headline-m-font-size);
46+
line-height: var(--cui-headline-m-line-height);
47+
}
48+
.subtitle {
49+
font-size: var(--cui-body-m-font-size);
50+
line-height: var(--cui-body-m-line-height);
3951
}
4052
}
4153
</style>

src/overrides/PageTitle.astro

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,14 @@ const {
77
---
88

99
<div class="page-title">
10-
<Display as="h1" size="s" weight="semibold" id={"_top"} data-page-title>
10+
<Display
11+
as="h1"
12+
size="s"
13+
weight="semibold"
14+
id={"_top"}
15+
className="title"
16+
data-page-title
17+
>
1118
{title}
1219
</Display>
1320
{
@@ -16,6 +23,7 @@ const {
1623
size="l"
1724
style={{ marginTop: "var(--cui-spacings-mega)" }}
1825
color="subtle"
26+
className="subtitle"
1927
>
2028
{description}
2129
</Body>
@@ -28,4 +36,18 @@ const {
2836
text-align: center;
2937
padding: var(--cui-spacings-tera) 0 var(--cui-spacings-byte);
3038
}
39+
40+
@media screen and (max-width: 980px) {
41+
.title {
42+
font-size: var(--cui-headline-l-font-size);
43+
line-height: var(--cui-headline-l-line-height);
44+
}
45+
}
46+
47+
@media screen and (max-width: 520px) {
48+
.subtitle {
49+
font-size: var(--cui-body-m-font-size);
50+
line-height: var(--cui-body-m-line-height);
51+
}
52+
}
3153
</style>

src/pages/api/[...path].astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ const sidebar: StarlightUserConfig["sidebar"] = [
9999
const props = {
100100
frontmatter: {
101101
title: "API Reference",
102-
description: "SumUp API reference.",
102+
description: "SumUp API reference and code samples.",
103103
tableOfContents: false,
104104
},
105105
sidebar,

src/pages/changelog/index.astro

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ const posts = await Promise.all(
2626
const props = {
2727
frontmatter: {
2828
title: "Changelog",
29-
description: "Changelog",
29+
description:
30+
"Subscribe to stay up to date with new features and API and SDK changes.",
3031
template: "splash",
3132
tableOfContents: false,
3233
},

0 commit comments

Comments
 (0)