Skip to content

Commit

Permalink
Merge branch 'main' into hd-feat-tabs-sync
Browse files Browse the repository at this point in the history
  • Loading branch information
delucis authored Sep 28, 2023
2 parents a5d6f13 + 2ef3036 commit c056462
Show file tree
Hide file tree
Showing 87 changed files with 4,785 additions and 715 deletions.
5 changes: 5 additions & 0 deletions .changeset/cool-moons-thank.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@astrojs/starlight': patch
---

Prevent Starlight crashing when the content folder doesn't exist, or is empty
5 changes: 5 additions & 0 deletions .changeset/fair-trains-care.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@astrojs/starlight": patch
---

Fix content collection schema compatibility with Astro 3.1 and higher
5 changes: 5 additions & 0 deletions .changeset/few-roses-explain.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@astrojs/starlight": patch
---

Fix Dutch UI translation for “Previous page” links
5 changes: 5 additions & 0 deletions .git-blame-ignore-revs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Apply with:
# `git config --local blame.ignoreRevsFile .git-blame-ignore-revs`

# [Add Prettier and format files](https://github.com/withastro/starlight/pull/393)
9b172f5ee09697d80f301e9b70aca1946419ce24
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
prefer-workspace-packages=true
link-workspace-packages=true
shell-emulator=true
2 changes: 2 additions & 0 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Starlight Docs

[![Built with Starlight](https://astro.badg.es/v2/built-with-starlight/tiny.svg)](https://starlight.astro.build)

This directory contains the Starlight documentation website (built with Starlight!)

[![Open in StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/github/withastro/starlight/tree/main/docs)
Expand Down
9 changes: 8 additions & 1 deletion docs/astro.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ export const locales = {
ja: { label: '日本語', lang: 'ja' },
fr: { label: 'Français', lang: 'fr' },
it: { label: 'Italiano', lang: 'it' },
id: { label: 'Bahasa Indonesia', lang: 'id' },
zh: { label: '简体中文', lang: 'zh' },
'pt-br': { label: 'Português do Brasil', lang: 'pt-BR' },
ko: { label: '한국어', lang: 'ko' },
Expand Down Expand Up @@ -61,6 +62,7 @@ export default defineConfig({
ja: 'ここからはじめる',
fr: 'Commencez ici',
it: 'Inizia qui',
id: 'Mulai dari sini',
zh: '从这里开始',
'pt-BR': 'Comece Aqui',
ko: '여기서부터',
Expand All @@ -75,6 +77,7 @@ export default defineConfig({
ja: '入門',
fr: 'Mise en route',
it: 'Iniziamo',
id: 'Memulai',
zh: '开始使用',
'pt-BR': 'Introdução',
ko: '시작하기',
Expand All @@ -89,6 +92,7 @@ export default defineConfig({
ja: '手動セットアップ',
fr: 'Installation manuelle',
// it: 'Manual Setup',
id: 'Instalasi Manual',
zh: '手动配置',
'pt-BR': 'Instalação Manual',
ko: '수동으로 설정하기',
Expand All @@ -103,6 +107,7 @@ export default defineConfig({
ja: '環境への負荷',
fr: 'Impact environnemental',
it: 'Impatto ambientale',
id: 'Dampak terhadap lingkungan',
zh: '环境影响',
'pt-BR': 'Impacto Ambiental',
ko: '환경적 영향',
Expand All @@ -117,6 +122,7 @@ export default defineConfig({
ja: 'ショーケース',
fr: 'Vitrine',
// it: '',
id: 'Galeri',
ko: '쇼케이스',
},
},
Expand All @@ -130,6 +136,7 @@ export default defineConfig({
ja: 'ガイド',
fr: 'Guides',
it: 'Guide',
id: 'Petunjuk Penggunaan',
zh: '指南',
'pt-BR': 'Guias',
ko: '가이드',
Expand All @@ -144,6 +151,7 @@ export default defineConfig({
ja: 'リファレンス',
fr: 'Référence',
it: 'Riferimenti',
id: 'Referensi',
zh: '参考',
'pt-BR': 'Referência',
ko: '참조',
Expand All @@ -154,5 +162,4 @@ export default defineConfig({
lastUpdated: true,
}),
],
image: { service: { entrypoint: 'astro/assets/services/sharp' } },
});
4 changes: 2 additions & 2 deletions docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
"type": "module",
"version": "0.0.1",
"scripts": {
"test": "start-server-and-test preview http://localhost:4321 pa11y",
"pa11y": "pa11y-ci --sitemap 'http://localhost:4321/sitemap-index.xml' --sitemap-find 'https://starlight.astro.build' --sitemap-replace 'http://localhost:4321' --sitemap-exclude '/(de|zh|fr|es|pt-br|it|ko)/.*'",
"test": "start-server-and-test 'pnpm preview' http://localhost:4321 'pnpm pa11y'",
"pa11y": "pa11y-ci --sitemap 'http://localhost:4321/sitemap-0.xml' --sitemap-find 'https://starlight.astro.build' --sitemap-replace 'http://localhost:4321' --sitemap-exclude '/(de|zh|fr|es|pt-br|it|ko)/.*'",
"dev": "astro dev",
"start": "astro dev",
"build": "astro build",
Expand Down
Binary file removed docs/src/assets/showcase/commandkit.underctrl.io.png
Binary file not shown.
Binary file added docs/src/assets/showcase/dev.vrchatfrance.fr.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/src/assets/showcase/kanriapp.com.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/src/assets/showcase/refact.ai.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
56 changes: 56 additions & 0 deletions docs/src/components/showcase-sites.astro
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
---
import Card from './showcase-card.astro';
import FluidGrid from './fluid-grid.astro';
---

<FluidGrid>
<Card title="Athena OS" href="https://athenaos.org" thumbnail="www.athenaos.org.png" />
<Card
title="PubIndexAPI Docs"
href="https://docs.pubindexapi.com/"
thumbnail="docs.pubindexapi.com.png"
/>
<Card title="pls" href="https://dhruvkb.github.io/pls" thumbnail="dhruvkb.github.io-pls.png" />
<Card title="capo.js" href="https://rviscomi.github.io/capo.js/" thumbnail="capo.js.png" />
<Card
title="Web Monetization API"
href="https://webmonetization.org/"
thumbnail="webmonetization.org.png"
/>
<Card
title="QBCore Docs"
href="https://brycerussell.github.io/qbcore-docs/"
thumbnail="brycerussell.github.io-qbcore-docs.png"
/>
<Card title="har.fyi" href="https://har.fyi/" thumbnail="har.fyi.png" />
<Card title="xs-dev docs" href="https://xs-dev.js.org" thumbnail="xs-dev.js.org.png" />
<Card title="Felicity" href="https://felicity.pages.dev/" thumbnail="felicity.pages.dev.png" />
<Card
title="NgxEditor"
href="https://sibiraj-s.github.io/ngx-editor/"
thumbnail="sibiraj-s.github.io-ngx-editor.png"
/>
<Card
title="Astro Error Pages"
href="https://astro-error-page-documentation.vercel.app/"
thumbnail="astro-error-page-documentation.vercel.app.png"
/>
<Card title="Terrateam Docs" href="https://terrateam.io/docs" thumbnail="terrateam.io-docs.png" />
<Card
title="simple-fm"
href="https://simple.arciniega.one"
thumbnail="simple.arciniega.one.png"
/>
<Card
title="Obytes Starter"
href="https://starter.obytes.com"
thumbnail="starter.obytes.com.jpg"
/>
<Card title="Kanri" href="https://kanriapp.com" thumbnail="kanriapp.com.png" />
<Card
title="VRCFR Creator"
href="https://dev.vrchatfrance.fr"
thumbnail="dev.vrchatfrance.fr.png"
/>
<Card title="Refact" href="https://docs.refact.ai/" thumbnail="refact.ai.png" />
</FluidGrid>
49 changes: 49 additions & 0 deletions docs/src/components/sidebar-preview.astro
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
---
import type { AutoSidebarGroup, SidebarItem } from '../../../packages/starlight/utils/user-config';
import SidebarSublist from '../../../packages/starlight/components/SidebarSublist.astro';
import type { SidebarEntry } from '../../../packages/starlight/utils/navigation';
interface Props {
config: SidebarConfig;
}
type SidebarConfig = Exclude<SidebarItem, AutoSidebarGroup>[];
const { config } = Astro.props;
function makeEntries(items: SidebarConfig): SidebarEntry[] {
return items.map((item) => {
if ('link' in item) {
return {
type: 'link',
label: item.label,
href: item.link,
isCurrent: false,
badge: item.badge,
};
}
item;
return {
type: 'group',
label: item.label,
entries: makeEntries(item.items as SidebarConfig),
collapsed: item.collapsed,
};
});
}
---

<div class="sidebar-preview not-content">
<SidebarSublist sublist={makeEntries(config)} />
</div>

<style>
.sidebar-preview {
background-color: var(--sl-color-bg-sidebar);
border: 1px solid var(--sl-color-gray-5);
padding: 1rem var(--sl-sidebar-pad-x);
max-width: var(--sl-sidebar-width);
}
</style>
13 changes: 13 additions & 0 deletions docs/src/content/docs/es/guides/customization.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,19 @@ Puedes mostrar diferentes versiones de tu logo en modos claro y oscuro.
}),
```

## Habilitar el mapa del sitio

Starlight tiene soporte incorporado para generar un mapa del sitio. Habilita la generación del mapa del sitio estableciendo tu URL como `site` en `astro.config.mjs`:

```js
// astro.config.mjs

export default defineConfig({
site: 'https://stargazers.club',
integrations: [starlight({ title: 'Sitio con mapa del sitio' })],
});
```

## Diseño de página

De forma predeterminada, las páginas de Starlight utilizan un diseño con una barra lateral de navegación global y una tabla de contenidos que muestra los encabezados de la página actual.
Expand Down
2 changes: 1 addition & 1 deletion docs/src/content/docs/es/guides/i18n.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ Si no hay una traducción disponible para un idioma, Starlight mostrará a los l

## Traduce la UI de Starlight

Starlight proporciona de forma predeterminada traducciones para los textos utilizados en la UI al inglés, checo, francés, alemán, italiano, japonés, holandés, portugués, danés, español, turco, árabe, noruego, farsi, chino simplificado, coreano y sueco. También damos la bienvenida a [contribuciones para agregar más idiomas predeterminados](https://github.com/withastro/starlight/blob/main/CONTRIBUTING.md).
Starlight proporciona de forma predeterminada traducciones para los textos utilizados en la UI al inglés, checo, francés, alemán, italiano, japonés, holandés, portugués, danés, español, turco, árabe, noruego, farsi, hebreo, chino simplificado, coreano, indonesio, ruso y sueco. También damos la bienvenida a [contribuciones para agregar más idiomas predeterminados](https://github.com/withastro/starlight/blob/main/CONTRIBUTING.md).

1. Configura la colección de datos `i18n` en `src/content/config.ts` si aún no está configurada:

Expand Down
Loading

0 comments on commit c056462

Please sign in to comment.