Changelog

🍿 Minor Changes
-
#1923
5269aadThanks @HiDeoo! - Overhauls the built-in localization system which is now powered by thei18nextlibrary and available to use anywhere in your documentation website.See the “Using UI translations” guide to learn more about how to access built-in UI labels or your own custom strings in your project. Plugin authors can also use the new
injectTranslations()helper to add or update translation strings.⚠️ BREAKING CHANGE: The
Astro.props.labelsprops has been removed from the props passed down to custom component overrides.If you are relying on
Astro.props.labels(for example to read a built-in UI label), you will need to update your code to use the newAstro.locals.t()helper instead.---import type { Props } from '@astrojs/starlight/props';// The `search.label` UI label for this page’s language:const searchLabel = Astro.locals.t('search.label');--- -
#2285
7286220Thanks @HiDeoo! - Adds support for translating sidebar badges. -
#1923
5269aadThanks @HiDeoo! - ⚠️ BREAKING CHANGE: The minimum supported version of Astro is now 4.14.0Please update Astro and Starlight together:
Terminal window npx @astrojs/upgrade
🐞 Patch Changes
-

🍿 Minor Changes
-
#1255
6f3202bThanks @Fryuni! - Adds support for server-rendered Starlight pages.When building a project with
hybridorserveroutput mode, a newprerenderoption on Starlight config can be set tofalseto make all Starlight pages be rendered on-demand:export default defineConfig({output: 'server',integrations: [starlight({prerender: false,}),],});
🐞 Patch Changes
-
#2242
756e85eThanks @delucis! - Refactors the logic for persisting and restoring sidebar state across navigations for better performance on slow or busy devices -
#1255
6f3202bThanks @Fryuni! - Improves performance of computing the last updated times from Git history.Instead of executing
gitfor each docs page, it is now executed twice regardless of the number of pages. -
#1255
6f3202bThanks @Fryuni! - Fixes last updated times on projects with customsrcDir
-
🐞 Patch Changes
-
#2281
5062d30Thanks @HiDeoo! - Fixes a potential text rendering issue that could include extra whitespaces for text containing colons. -
#2279
62d59e2Thanks @HiDeoo! - Fixes an issue with frontmatter schemas containing collection references used with the<StarlightPage />component and an Astro version greater than4.14.0.
-
🐞 Patch Changes
-
#2273
746e0cdThanks @delucis! - Fixes type error when using Starlight with Astro v4.15 -
#2265
25b661eThanks @SeraphicRav! - Adds TikTok social icon -
#2250
c0a6166Thanks @HiDeoo! - Removes internal E2E tests from the package published to the npm registry. -
#2253
72bc76aThanks @HiDeoo! - Fixes an issue preventing to use theclassattribute in hero action link buttons.
-

🍿 Minor Changes
-
#1784
68f56a7Thanks @HiDeoo! - Adds<LinkButton>component for visually distinct and emphasized call to action links -
#2150
9368494Thanks @delucis! - Adds state persistence across page navigations to the main site sidebar -
#2087
caa84eaThanks @HiDeoo! - Adds persistence to synced<Tabs>so that a user’s choices are reflected across page navigations. -
#2051
ec3b579Thanks @HiDeoo! - Adds a guideline to the last step of the<Steps>component.If you want to preserve the previous behaviour and hide the guideline on final steps, you can add the following custom CSS to your site:
/* Hide the guideline for the final step in <Steps> lists. */.sl-steps > li:last-of-type::after {background: transparent;} -
#1784
68f56a7Thanks @HiDeoo! - Changes the hero component action button default variant fromminimaltoprimary.⚠️ BREAKING CHANGE: If you want to preserve the previous appearance, hero component action buttons previously declared without a
variantwill need to be updated to include thevariantproperty with the valueminimal.hero:actions:- text: View on GitHublink: https://github.com/astronaut/my-projecticon: externalvariant: minimal -
#2168
e044feeThanks @HiDeoo! - ⚠️ BREAKING CHANGE: Updates the<StarlightPage />componentsidebarprop to accept an array ofSidebarItems like the main Starlightsidebarconfiguration inastro.config.mjs.This change simplifies the definition of sidebar items in the
<StarlightPage />component, allows for shared sidebar configuration between the globalsidebaroption and<StarlightPage />component, and also enables the usage of autogenerated sidebar groups with the<StarlightPage />component. If you are using the<StarlightPage />component with a customsidebarconfiguration, you will need to update thesidebarprop to an array ofSidebarItemobjects.For example, the following custom page with a custom
sidebarconfiguration defines a “Resources” group with a “New” badge, a link to the “Showcase” page which is part of thedocscontent collection, and a link to the Starlight website:src/pages/custom-page/example.astro <StarlightPagefrontmatter={{ title: 'My custom page' }}sidebar={[{type: 'group',label: 'Resources',badge: { text: 'New' },items: [{ type: 'link', label: 'Showcase', href: '/showcase/' },{type: 'link',label: 'Starlight',href: 'https://starlight.astro.build/',},],},]}><p>This is a custom page with a custom component.</p></StarlightPage>This configuration will now need to be updated to the following:
src/pages/custom-page/example.astro <StarlightPagefrontmatter={{ title: 'My custom page' }}sidebar={[{label: 'Resources',badge: { text: 'New' },items: ['showcase',{ label: 'Starlight', link: 'https://starlight.astro.build/' },],},]}><p>This is a custom page with a custom component.</p></StarlightPage>See the “Sidebar Navigation” guide to learn more about the available options for customizing the sidebar.
-
🐞 Patch Changes
-
#2155
8bed886Thanks @delucis! - Improves page load performance on slower devices -
#2167
9ac7725Thanks @delucis! - Fixes an issue detecting the built-in locale when running Starlight in a web container environment on Firefox -
#2166
4f12049Thanks @delucis! - Updates@astrojs/mdx,@astrojs/sitemap,astro-expressive-code,unified, andvfiledependencies to the latest version
-
🐞 Patch Changes
-
#2154
0b381d5Thanks @mktbsh! - Updates<head>logic to deduplicate<link rel="canonical">tags. This means that custom canonicals set via frontmatter now override the default canonical generated by Starlight. -
#2157
6757d97Thanks @astrobot-houston! - Updates file tree icon mapping to correctly map.cjsand.mjsextensions in several contexts -
#2156
904ad47Thanks @delucis! - Fixes builds for projects with a space in their pathname -
#2137
703903bThanks @cevdetardaharan! - Removestwitter:titleandtwitter:descriptionmeta tags from<head>
-
🐞 Patch Changes
-
#2126
ada51eeThanks @essential-randomness! - Adds support for markdown formatting in aside titles -
#2135
9bbb969Thanks @oluwatobiss! - Adds Pinterest social icon
-
🐞 Patch Changes
-
#2122
359a642Thanks @HiDeoo! - Fixes an i18n configuration issue for multilingual sites when using Astro’si18nconfig withprefixDefaultLocaleset tofalse. -
#2107
61e223bThanks @sanabel-al-firdaws! - Updates Arabic UI translations -
#2105
81f8a2cThanks @delucis! - Fixes an edge case in custom pagination link processingCustom link values for
prev/nextin page frontmatter are now always used as authored. Previously this was not the case in some edge cases such as for the first and final pages in the sidebar. -
#2119
464685aThanks @evadecker! - Improves styling of<hr>,<blockquote>, and<code>within asides
-

🍿 Minor Changes
-
#2025
47f32c1Thanks @HiDeoo! - Removes the/search shortcut for accessibility reasons.⚠️ Potentially breaking change: The
search.shortcutLabelUI string has been removed. If you were using this string in your custom UI, you will need to update your code. -
#2064
c5b47cbThanks @SnowDingo! - Improves styling of Markdown tables to work better in different contexts, including against different background colours like when used in asides. -
#2031
2bab648Thanks @delucis! - Makes sidebar entry parsing stricter in Starlight config⚠️ Potentially breaking change: Previously Starlight would accept a sidebar entry that matched one of its expected shapes, even if it included additional properties. For example, including both
linkanditemswas considered valid, withitemsbeing ignored. Now, it is an error to include more than one oflink,items, orautogeneratein a sidebar entry.If you see errors after updating, look for sidebar entries in the Starlight configuration in
astro.config.mjsthat include too many keys and remove the one that was previously ignored. -
#1874
eeba06eThanks @lorenzolewis! - Adds a new syntax for specifying sidebar link items for internal linksYou can now specify an internal page using only its slug, either as a string, or as an object with a
slugproperty:starlight({title: 'Docs with easier sidebars',sidebar: ['getting-started', { slug: 'guides/installation' }],});Starlight will use the linked page’s frontmatter to configure the sidebar link.
🐞 Patch Changes
- #2081
f0181d2Thanks @andrii-bodnar! - Updates the Ukrainian UI translations
-
🐞 Patch Changes
-
#2062
5ac0ac6Thanks @evadecker! - Increase theme and language select inline padding -
#2056
87e9ad0Thanks @HiDeoo! - Fixes an issue preventing remark plugins injected by Starlight plugins to handle Markdown text and leaf directives. -
#2063
3ee1a94Thanks @delucis! - TranslatefileTree.directoryandaside.*UI string into Norwegian (Bokmål). -
#2054
dbfd3eeThanks @HiDeoo! - Fixes an issue when using the<StarlightPage>component in a custom page with a user-definedsrcDirconfiguration.
-
🐞 Patch Changes
-
#2038
87f3f92Thanks @dragomano! - Updates Russian UI translations -
#2043
53f4cd4Thanks @playmr365! - Updates Czech UI translations -
#2041
8af5a60Thanks @HiDeoo! - Fixes<Steps>numbering bug caused by Chrome v126 CSS counter rewrite
-
🐞 Patch Changes
-
#2008
40359c7Thanks @vnepogodin! - Add Slovak language UI translation. -
#2004
0aa2f06Thanks @liruifengv! - Removes an outdated export inpackage.json -
#2007
44ca490Thanks @delucis! - Updates internal dependencies -
#1993
60165b2Thanks @HiDeoo! - Fixes an i18n configuration issue when using a single root locale.
-