Skip to content

Commit b910a4a

Browse files
committed
[Docs Site] Upgrade Astro to 5.4.1 and Starlight to 0.32.2
1 parent 2fe7819 commit b910a4a

21 files changed

+437
-486
lines changed

package-lock.json

Lines changed: 354 additions & 394 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,11 @@
2828
"@actions/core": "1.11.1",
2929
"@actions/github": "6.0.0",
3030
"@astrojs/check": "0.9.4",
31-
"@astrojs/react": "4.2.0",
31+
"@astrojs/react": "4.2.1",
3232
"@astrojs/rss": "4.0.11",
3333
"@astrojs/sitemap": "3.2.1",
34-
"@astrojs/starlight": "0.31.1",
35-
"@astrojs/starlight-docsearch": "0.5.0",
34+
"@astrojs/starlight": "0.32.2",
35+
"@astrojs/starlight-docsearch": "0.6.0",
3636
"@astrojs/starlight-tailwind": "3.0.0",
3737
"@astrojs/tailwind": "5.1.5",
3838
"@cloudflare/vitest-pool-workers": "0.6.14",
@@ -50,7 +50,7 @@
5050
"@types/react-dom": "19.0.4",
5151
"@typescript-eslint/parser": "8.25.0",
5252
"algoliasearch": "5.20.2",
53-
"astro": "5.2.1",
53+
"astro": "5.4.1",
5454
"astro-breadcrumbs": "3.3.1",
5555
"astro-icon": "1.1.5",
5656
"astro-live-code": "0.0.5",
@@ -94,7 +94,7 @@
9494
"remark": "15.0.1",
9595
"sharp": "0.33.5",
9696
"solarflare-theme": "0.0.4",
97-
"starlight-image-zoom": "0.10.1",
97+
"starlight-image-zoom": "0.11.1",
9898
"starlight-links-validator": "0.14.3",
9999
"starlight-package-managers": "0.10.0",
100100
"strip-markdown": "6.0.0",

src/components/Description.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
<div class="text-xl leading-6 mb-4" style="color: var(--sl-color-white);">
1+
<div class="mb-4 text-xl leading-6" style="color: var(--sl-color-white);">
22
<slot />
33
</div>

src/components/Flex.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
<div class="flex flex-col md:flex-row justify-between gap-x-2 [&_p]:!mt-0">
1+
<div class="flex flex-col justify-between gap-x-2 md:flex-row [&_p]:!mt-0">
22
<slot />
33
</div>

src/components/HomepageHero.astro

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
---
22
import { Image } from "astro:assets";
3-
import type { Props } from "@astrojs/starlight/props";
43
import type { ImageMetadata } from "astro";
54
6-
const { data } = Astro.props.entry;
5+
const { data } = Astro.locals.starlightRoute.entry;
76
const { title = data.title, tagline, image } = data.hero || {};
87
98
const imageAttrs = {
@@ -45,15 +44,15 @@ if (image) {
4544
{rawHtml && <div class="hero-html sl-flex" set:html={rawHtml} />}
4645
<div class="sl-flex stack">
4746
<div class="sl-flex copy">
48-
<div class="sl-flex copy links">
49-
<a class="px-2" href="/products/">Products</a>
50-
<a class="px-2" href="/fundamentals/subscriptions-and-billing/"
47+
<div class="sl-flex copy links space-x-4">
48+
<a href="/products/">Products</a>
49+
<a href="/fundamentals/subscriptions-and-billing/"
5150
>Subscriptions and billing</a
5251
>
53-
<a class="px-2" href="/api/">API</a>
54-
<a class="px-2" href="/changelog/">Changelog</a>
55-
<a class="px-2" href="/glossary/">Glossary</a>
56-
<a class="px-2" href="/reference-architecture/">Architectures</a>
52+
<a href="/api/">API</a>
53+
<a href="/changelog/">Changelog</a>
54+
<a href="/glossary/">Glossary</a>
55+
<a href="/reference-architecture/">Architectures</a>
5756
</div>
5857
<h1 id={"_top"} data-page-title set:html={title} />
5958
{tagline && <div class="tagline" set:html={tagline} />}

src/components/MetaInfo.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@ const props = z
1212
const { text } = props.parse(Astro.props);
1313
---
1414

15-
<span class="text-xs align-middle">{text}</span>
15+
<span class="align-middle text-xs">{text}</span>

src/components/RelatedProduct.astro

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@ const props = z.object({
1313
const { header, href, product } = props.parse(Astro.props);
1414
---
1515

16-
<div class="grid grid-cols-[32px_auto] gap-x-2 items-start">
16+
<div class="grid grid-cols-[32px_auto] items-start gap-x-2">
1717
<AstroIcon
1818
name={product}
19-
class="text-[color:var(--orange-accent-200)] text-7xl"
19+
class="text-7xl text-[color:var(--orange-accent-200)]"
2020
/>
2121
<div class="!mt-0">
2222
<strong>

src/components/homepage/FeaturedContentSection.astro

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ const { title, text, image, cards, imagePosition } = props.parse(Astro.props);
3232
<div class="flex h-1/3 items-center">
3333
{
3434
imagePosition === "before" && (
35-
<div class="w-full m-8">
35+
<div class="m-8 w-full">
3636
<Image
3737
src={image.light}
3838
alt={`${title} section image`}
@@ -61,7 +61,10 @@ const { title, text, image, cards, imagePosition } = props.parse(Astro.props);
6161
moreVideosLink="false"
6262
/>
6363

64-
<LinkCard title={"Explore our Developer Platform"} href={"/products/?product-group=Developer+platform"} />
64+
<LinkCard
65+
title={"Explore our Developer Platform"}
66+
href={"/products/?product-group=Developer+platform"}
67+
/>
6568
</Card>
6669
</div>
6770
) : (
@@ -80,7 +83,7 @@ const { title, text, image, cards, imagePosition } = props.parse(Astro.props);
8083

8184
{
8285
imagePosition === "after" && (
83-
<div class="w-full m-8">
86+
<div class="m-8 w-full">
8487
<Image
8588
src={image.light}
8689
alt={`${title} section image`}

src/components/homepage/FooterHeroBlock.astro

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ const blocks = [
5959
---
6060

6161
<div
62-
class="flex bg-gray-100 dark:bg-gray-800 bleed *:!mt-0 items-start justify-between py-10"
62+
class="bleed flex items-start justify-between bg-gray-100 py-10 *:!mt-0 dark:bg-gray-800"
6363
>
6464
{
6565
blocks.map(({ title, text, links }) => (
@@ -68,13 +68,13 @@ const blocks = [
6868
<p class="w-80">{text}</p>
6969
<ul class="list-none pl-0">
7070
{links.map((link) => (
71-
<li class="flex !mt-4">
71+
<li class="!mt-4 flex">
7272
<Icon
7373
name={link.icon}
7474
size="1.5rem"
7575
color="var(--sl-color-white)"
7676
/>
77-
<a href={link.href} class="pl-2 no-underline !text-black">
77+
<a href={link.href} class="pl-2 !text-black no-underline">
7878
{link.text}
7979
</a>
8080
</li>

src/components/homepage/TryItSection.astro

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ import Render from "~/components/Render.astro";
1414

1515
<div class="tryit-sidebar">
1616
<Card title="">
17-
<div class="*:block *:p-2 *:rounded">
17+
<div class="*:block *:rounded *:p-2">
1818
<label for="section1" id="section1Label">
1919
<strong>Return HTML</strong>
2020
</label>
@@ -34,7 +34,7 @@ import Render from "~/components/Render.astro";
3434
</Card>
3535
</div>
3636

37-
<div class="tryit-code ml-8 w-full !mt-0">
37+
<div class="tryit-code !mt-0 ml-8 w-full">
3838
<div id="section1Content" class="!mt-0 hidden">
3939
<Render file="return-html-example-js" product="workers" />
4040
</div>

0 commit comments

Comments
 (0)