Skip to content

Releases: withastro/starlight

@astrojs/[email protected]

16 Aug 18:36
f68fe5b
Compare
Choose a tag to compare

Patch Changes

  • #2219 74d4716 Thanks @HiDeoo! - Fixes a sidebar persistence issue when navigating between pages with different sidebar content.

@astrojs/[email protected]

16 Aug 17:18
96d5967
Compare
Choose a tag to compare

Minor Changes

  • #1784 68f56a7 Thanks @HiDeoo! - Adds <LinkButton> component for visually distinct and emphasized call to action links

  • #2150 9368494 Thanks @delucis! - Adds state persistence across page navigations to the main site sidebar

  • #2087 caa84ea Thanks @HiDeoo! - Adds persistence to synced <Tabs> so that a user's choices are reflected across page navigations.

  • #2051 ec3b579 Thanks @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 68f56a7 Thanks @HiDeoo! - Changes the hero component action button default variant from minimal to primary.

    ⚠️ BREAKING CHANGE: If you want to preserve the previous appearance, hero component action buttons previously declared without a variant will need to be updated to include the variant property with the value minimal.

    hero:
      actions:
        - text: View on GitHub
          link: https://github.com/astronaut/my-project
          icon: external
    +     variant: minimal
  • #2168 e044fee Thanks @HiDeoo! - ⚠️ BREAKING CHANGE: Updates the <StarlightPage /> component sidebar prop to accept an array of SidebarItems like the main Starlight sidebar configuration in astro.config.mjs.

    This change simplifies the definition of sidebar items in the <StarlightPage /> component, allows for shared sidebar configuration between the global sidebar option 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 custom sidebar configuration, you will need to update the sidebar prop to an array of SidebarItem objects.

    For example, the following custom page with a custom sidebar configuration defines a “Resources” group with a “New” badge, a link to the “Showcase” page which is part of the docs content collection, and a link to the Starlight website:

    ---
    // src/pages/custom-page/example.astro
    ---
    
    <StarlightPage
      frontmatter={{ 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
    ---
    
    <StarlightPage
      frontmatter={{ 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.

@astrojs/[email protected]

13 Aug 09:29
5311d80
Compare
Choose a tag to compare

Patch Changes

@astrojs/[email protected]

06 Aug 09:51
41506e5
Compare
Choose a tag to compare

Patch Changes

  • #2155 8bed886 Thanks @delucis! - Improves page load performance on slower devices

  • #2167 9ac7725 Thanks @delucis! - Fixes an issue detecting the built-in locale when running Starlight in a web container environment on Firefox

  • #2166 4f12049 Thanks @delucis! - Updates @astrojs/mdx, @astrojs/sitemap, astro-expressive-code, unified, and vfile dependencies to the latest version

@astrojs/[email protected]

29 Jul 14:51
b4345ce
Compare
Choose a tag to compare

Patch Changes

  • #2154 0b381d5 Thanks @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 6757d97 Thanks @astrobot-houston! - Updates file tree icon mapping to correctly map .cjs and .mjs extensions in several contexts

  • #2156 904ad47 Thanks @delucis! - Fixes builds for projects with a space in their pathname

  • #2137 703903b Thanks @cevdetardaharan! - Removes twitter:title and twitter:description meta tags from <head>

@astrojs/[email protected]

23 Jul 13:56
ab105c3
Compare
Choose a tag to compare

Patch Changes

@astrojs/[email protected]

10 Jul 16:25
24c6765
Compare
Choose a tag to compare

Patch Changes

  • #2122 359a642 Thanks @HiDeoo! - Fixes an i18n configuration issue for multilingual sites when using Astro’s i18n config with prefixDefaultLocale set to false.

  • #2107 61e223b Thanks @sanabel-al-firdaws! - Updates Arabic UI translations

  • #2105 81f8a2c Thanks @delucis! - Fixes an edge case in custom pagination link processing

    Custom link values for prev/next in 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 464685a Thanks @evadecker! - Improves styling of <hr>, <blockquote>, and <code> within asides

@astrojs/[email protected]

05 Jul 11:24
1c70df6
Compare
Choose a tag to compare

Minor Changes

  • #2025 47f32c1 Thanks @HiDeoo! - Removes the / search shortcut for accessibility reasons.

    ⚠️ Potentially breaking change: The search.shortcutLabel UI string has been removed. If you were using this string in your custom UI, you will need to update your code.

  • #2064 c5b47cb Thanks @SnowDingo! - Improves styling of Markdown tables to work better in different contexts, including against different background colours like when used in asides.

  • #2031 2bab648 Thanks @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 link and items was considered valid, with items being ignored. Now, it is an error to include more than one of link, items, or autogenerate in a sidebar entry.

    If you see errors after updating, look for sidebar entries in the Starlight configuration in astro.config.mjs that include too many keys and remove the one that was previously ignored.

  • #1874 eeba06e Thanks @lorenzolewis! - Adds a new syntax for specifying sidebar link items for internal links

    You can now specify an internal page using only its slug, either as a string, or as an object with a slug property:

    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

@astrojs/[email protected]

28 Jun 16:19
1d32c8b
Compare
Choose a tag to compare

Patch Changes

  • #2062 5ac0ac6 Thanks @evadecker! - Increase theme and language select inline padding

  • #2056 87e9ad0 Thanks @HiDeoo! - Fixes an issue preventing remark plugins injected by Starlight plugins to handle Markdown text and leaf directives.

  • #2063 3ee1a94 Thanks @delucis! - Translate fileTree.directory and aside.* UI string into Norwegian (Bokmål).

  • #2054 dbfd3ee Thanks @HiDeoo! - Fixes an issue when using the <StarlightPage> component in a custom page with a user-defined srcDir configuration.

@astrojs/[email protected]

20 Jun 18:27
ee18ce4
Compare
Choose a tag to compare

Patch Changes