Files
onixbyte.com/docs/en-gb/_nav.json
T
zihluwang 164c319ac1 feat(i18n): default the cn build to Chinese
The .cn site exists for Chinese readers, so the unprefixed routes should
serve Chinese there. Rspress omits the prefix for the default locale, so
this also moves the routes:

              .com                      .cn
  English     /                         /en-gb/
  Chinese     /zh-hans/                 /

- Make the default locale a per-target value rather than a constant, and
  move the localePrefix helper inside createConfig so a prefix can no
  longer be hardcoded elsewhere.
- Build the sitemap priority map from localePrefix. The keys are full
  route paths, so the previous hardcoded "/zh-hans/..." entries would
  have silently stopped matching on .cn.
- Widen the nav Home activeMatch to cover either prefixed home, since the
  two targets put a different locale behind the prefix.

Note: README.md also carries the licence wording changed in the next
commit — a single file's hunks cannot be split non-interactively.
2026-09-25 15:38:03 +08:00

33 lines
595 B
JSON

[
{
"text": "nav.home",
"link": "/",
"activeMatch": "^/(en-gb/|zh-hans/)?$"
},
{
"text": "nav.products",
"link": "/products/",
"activeMatch": "/products/"
},
{
"text": "nav.services",
"link": "/services/",
"activeMatch": "/services/"
},
{
"text": "nav.insights",
"link": "/blogs/",
"activeMatch": "/blogs/"
},
{
"text": "nav.news",
"link": "/notifications/",
"activeMatch": "/notifications/"
},
{
"text": "nav.opensource",
"link": "/opensource-projects/",
"activeMatch": "/opensource-projects/"
}
]