Skip to content

Commit

Permalink
Merge branch 'main' into feat/sidebar-state-persistence
Browse files Browse the repository at this point in the history
  • Loading branch information
kitschpatrol committed Mar 14, 2024
2 parents d743d93 + 179f021 commit 7a96a92
Show file tree
Hide file tree
Showing 454 changed files with 25,167 additions and 6,574 deletions.
5 changes: 0 additions & 5 deletions .changeset/calm-bananas-nail.md

This file was deleted.

2 changes: 1 addition & 1 deletion .changeset/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"access": "public",
"baseBranch": "main",
"updateInternalDependencies": "patch",
"ignore": ["starlight-docs", "@example/*", "docs-i18n-tracker"],
"ignore": ["starlight-docs", "@example/*", "starlight-file-icons-generator"],
"___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH": {
"onlyUpdatePeerDependentsWhenOutOfRange": true
}
Expand Down
5 changes: 0 additions & 5 deletions .changeset/tidy-mails-brake.md

This file was deleted.

3 changes: 3 additions & 0 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,14 @@ i18n:
- docs/src/content/docs/ja/**/*
- docs/src/content/docs/zh-cn/**/*
- docs/src/content/docs/pt-br/**/*
- docs/src/content/docs/pt-pt/**/*
- docs/src/content/docs/ko/**/*
- docs/src/content/docs/ru/**/*
- docs/src/content/docs/id/**/*
- docs/src/content/docs/tr/**/*
- docs/src/content/docs/hi/**/*
- docs/src/content/docs/da/**/*
- docs/src/content/docs/uk/**/*

'🌟 core':
- packages/starlight/**
Expand Down
46 changes: 27 additions & 19 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ jobs:
name: Run unit tests
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v3
- uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
cache: 'pnpm'
Expand All @@ -35,13 +35,13 @@ jobs:
runs-on: ubuntu-20.04
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Setup PNPM
uses: pnpm/action-setup@v2
uses: pnpm/action-setup@v3

- name: Setup Node
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
cache: 'pnpm'
Expand All @@ -63,9 +63,9 @@ jobs:
name: Docs site builds on Windows
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v3
- uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
cache: 'pnpm'
Expand All @@ -74,19 +74,27 @@ jobs:
working-directory: ./docs
run: pnpm build

docs-i18n-tracker-smoke:
name: Docs i18n tracker builds
links:
name: Check for broken links
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: pnpm/action-setup@v2
- uses: actions/setup-node@v3
- name: Checkout
uses: actions/checkout@v4

- name: Setup PNPM
uses: pnpm/action-setup@v3

- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
cache: 'pnpm'
- run: pnpm i
- name: Build docs i18n tracker
working-directory: ./docs-i18n-tracker

- name: Install Dependencies
run: pnpm i

- name: Build docs site and check links
working-directory: ./docs
run: pnpm build
env:
CHECK_LINKS: true
8 changes: 4 additions & 4 deletions .github/workflows/format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,21 +10,21 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out code using Git
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}
# Needs access to push to main
token: ${{ secrets.FREDKBOT_GITHUB_TOKEN }}
- uses: pnpm/action-setup@v2
- uses: actions/setup-node@v3
- uses: pnpm/action-setup@v3
- uses: actions/setup-node@v4
with:
node-version: 18
cache: 'pnpm'
- run: pnpm i
- name: Format with Prettier
run: pnpm format
- name: Commit changes
uses: stefanzweifel/git-auto-commit-action@v4
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: '[ci] format'
branch: ${{ github.head_ref }}
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,16 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
# This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits
fetch-depth: 0

- name: Setup PNPM
uses: pnpm/action-setup@v2
uses: pnpm/action-setup@v3

- name: Setup Node
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 18
cache: 'pnpm'
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/size-limit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
- uses: pnpm/action-setup@v3
- run: pnpm i
- run: 'pnpm build:examples'
- run: pnpm size
Expand All @@ -31,7 +31,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
- uses: pnpm/action-setup@v3
- name: Run size-limit
uses: andresz1/size-limit-action@dd31dce7dcc72a041fd3e49abf0502b13fc4ce05
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/welcome-bot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
name: Welcome First-Time Contributors
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: zephyrproject-rtos/action-first-interaction@7e6446f8439d8b4399169880c36a3a12b5747699
with:
repo-token: ${{ secrets.FREDKBOT_GITHUB_TOKEN }}
Expand Down
21 changes: 18 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,20 @@ You should then be able to open <http://localhost:4321> and see your changes.
> **Note**
> Changes to the Starlight integration will require you to quit and restart the dev server to take effect.

### Check for broken links in the docs site

When adding or translating content in the Starlight docs site, you can check all internal links are valid.
All GitHub PRs are checked this way automatically, but testing locally can help if you want to confirm changes are correct before committing them.

To do this, move into the `docs/` directory from the root of the repo and then build the site with the `CHECK_LINKS` environment variable:

```sh
cd docs
CHECK_LINKS=true pnpm build
```

If there are any broken links, the build will fail and log which pages need to be fixed.

### Unit tests

The Starlight package includes unit tests in [`packages/starlight/__tests__/`](./packages/starlight/__tests__/), which are run using [Vitest][vitest].
Expand Down Expand Up @@ -200,13 +214,14 @@ Visit **<https://i18n.starlight.astro.build>** to track translation progress for
#### Adding a new language to Starlight’s docs
To add a language, you will need its BCP-47 tag and a label. See [“Adding a new language”](https://github.com/withastro/docs/blob/main/contributor-guides/translating-astro-docs.md#adding-a-new-language) in the Astro docs repo for some helpful tips around choosing these.
To add a language, you will need its BCP-47 tag and a label. See [“Adding a new language”](https://contribute.docs.astro.build/guides/i18n/#adding-a-new-language) in the Astro docs repo for some helpful tips around choosing these.
- Add your language to the `locales` config in `docs/astro.config.mjs`
- Add your language to the `locales` config in `docs/lunaria.config.json`
- Add your language’s subtag to the i18n label config in `.github/labeler.yml`
- Add your language to the `pa11y` script’s `--sitemap-exclude` flag in `package.json`
- Create the first translated page for your language.
This must be the Starlight landing page: `docs/src/content/docs/{language}/index.mdx`.
- Create the first translated page for your language.
This must be the Starlight landing page: `docs/src/content/docs/{language}/index.mdx`.
- Open a pull request on GitHub to add your changes to Starlight!
## Understanding Starlight
Expand Down
21 changes: 0 additions & 21 deletions docs-i18n-tracker/.gitignore

This file was deleted.

9 changes: 0 additions & 9 deletions docs-i18n-tracker/README.md

This file was deleted.

18 changes: 0 additions & 18 deletions docs-i18n-tracker/build.ts

This file was deleted.

23 changes: 0 additions & 23 deletions docs-i18n-tracker/lib/filter-warnings.cjs

This file was deleted.

33 changes: 0 additions & 33 deletions docs-i18n-tracker/lib/github-get.mjs

This file was deleted.

Loading

0 comments on commit 7a96a92

Please sign in to comment.