From c577522f07afc37661725355c62cd9d2abe2faaa Mon Sep 17 00:00:00 2001 From: Semere Tereffe Date: Sat, 13 Dec 2025 15:10:01 +0300 Subject: [PATCH 1/3] add working copy-as-md button --- www/src/components/PageTitle.astro | 48 +++++++++++++++++++++++++++++- 1 file changed, 47 insertions(+), 1 deletion(-) diff --git a/www/src/components/PageTitle.astro b/www/src/components/PageTitle.astro index ba71fa2f5f..564d3d05f1 100644 --- a/www/src/components/PageTitle.astro +++ b/www/src/components/PageTitle.astro @@ -13,11 +13,13 @@ const { lastUpdated, entry: { data: { title, author }, + body, }, } = Astro.locals.starlightRoute; const slug = Astro.url.pathname.replace(/^\//, "").replace(/\/$/, ""); const isBlogPost = slug.startsWith('blog/'); +const isDocsPost = slug.startsWith('docs/'); --- { isBlogPost @@ -37,10 +39,33 @@ const isBlogPost = slug.startsWith('blog/'); : -

{title}

+
+

{title}

+ { + isDocsPost ? : + } +
{ description &&

{description}

}
} + +