feat: release v0.4.0 — search i18n, blog bilingual dedup, and language-aware navigation#59
Merged
Conversation
The IIFE wrapper scoped Observer locally, breaking the reference from the first script block (theme toggle calls Observer.removeAnimationDelay()). Changed `const Observer` to `window.Observer` to keep it globally accessible while still avoiding redeclaration errors on View Transitions. Signed-off-by: dongjiang <dongjiang1989@126.com>
…e-aware navigation - Search index deduplicates bilingual blog pairs by translationId, adds urlEn - SearchModal uses urlEn when system language is English - PostNavigation shows prev/next titles and URLs matching page language - TableOfContents heading "目录" → data-i18n="blog.tableOfContents" - Cache data refreshed (⭐18,972, 169 contributors from 60 repos) - Version bump to 0.4.0 Signed-off-by: dongjiang <dongjiang1989@126.com>
Contributor
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
lyj715824
approved these changes
Jul 17, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Which issue(s) this PR fixes:
Changes
Added
ProjectCard.astroand[slug].astrolang+translationIdfrontmatter links zh/en versions; language toggle switches between variants; list/grid cards render both via.i18n-zh/.i18n-en; bilingual posts excluded from pagination, RSS, related and adjacent postsChanged
translationIdinto single entry withtitle/titleEn,excerpt/excerptEn,url/urlEn— index shrinks from 11 to 9 blog entriesitem.urlEnwhen system language is English, so search results navigate to the correct language variantdata-i18n="blog.tableOfContents"(shows "Table of Contents" in English mode)Fixed
GITHUB_TOKENwithADMIN_PATsecretconst Observercaused SyntaxError on client route swap — wrapped in IIFE, exposed aswindow.Observerfor theme toggle accessTest plan
npm run checkpasses (astro check, eslint, prettier) — 0 errors, 0 warnings, 0 hintsnpm run buildcompletes successfullySpecial notes for reviewers:
Release v0.4.0 — search i18n, blog bilingual dedup, and language-aware navigation