Skip to content

fix(i18n): update zh-CN translations & localize error page#1755

Open
RYGRIT wants to merge 3 commits intonpmx-dev:mainfrom
RYGRIT:i18n/zh-CN
Open

fix(i18n): update zh-CN translations & localize error page#1755
RYGRIT wants to merge 3 commits intonpmx-dev:mainfrom
RYGRIT:i18n/zh-CN

Conversation

@RYGRIT
Copy link
Contributor

@RYGRIT RYGRIT commented Feb 28, 2026

🔗 Linked issue

🧭 Context

📚 Description

  • add 401404500503 and default i18n keys to error page
  • add Chart options button tooltips
  • update zh-CN Translations (profile page)
  • deprecated fields on NuxtError objects(statusCode -> status and statusMessage -> statusText)

@vercel
Copy link

vercel bot commented Feb 28, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
npmx.dev Ready Ready Preview, Comment Feb 28, 2026 4:42pm
2 Skipped Deployments
Project Deployment Actions Updated (UTC)
docs.npmx.dev Ignored Ignored Preview Feb 28, 2026 4:42pm
npmx-lunaria Ignored Ignored Feb 28, 2026 4:42pm

Request Review

@github-actions
Copy link

github-actions bot commented Feb 28, 2026

Lunaria Status Overview

🌕 This pull request will trigger status changes.

Learn more

By default, every PR changing files present in the Lunaria configuration's files property will be considered and trigger status changes accordingly.

You can change this by adding one of the keywords present in the ignoreKeywords property in your Lunaria configuration file in the PR's title (ignoring all files) or by including a tracker directive in the merged commit's description.

Tracked Files

File Note
lunaria/files/en-GB.json Localization changed, will be marked as complete.
lunaria/files/en-US.json Source changed, localizations will be marked as outdated.
lunaria/files/zh-CN.json Localization changed, will be marked as complete.
Warnings reference
Icon Description
🔄️ The source for this localization has been updated since the creation of this pull request, make sure all changes in the source have been applied.

@codecov
Copy link

codecov bot commented Feb 28, 2026

Codecov Report

❌ Patch coverage is 0% with 6 lines in your changes missing coverage. Please review.
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
app/error.vue 0.00% 5 Missing and 1 partial ⚠️

📢 Thoughts on this report? Let us know!

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 28, 2026

📝 Walkthrough

Walkthrough

Adds new i18n entries and schema properties for HTTP error messages and two chart UI labels. app/error.vue now reads status and statusText from the incoming error prop and uses translated messages for 401, 404, 500, 503 and a default fallback. Two components (TrendsChart.vue and VersionDistribution.vue) add open_options and close_options button title keys. i18n/schema.json and locale files (en, en-GB, en-US, zh-CN) are updated to include the error object and trends.open_options / trends.close_options translations.

Possibly related PRs

Suggested reviewers

  • danielroe
  • 9romise
  • shuuji3
🚥 Pre-merge checks | ✅ 1
✅ Passed checks (1 passed)
Check name Status Explanation
Description check ✅ Passed The pull request description clearly relates to the changeset, covering error page i18n keys, chart button tooltips, and zh-CN translations.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
app/error.vue (1)

29-31: Minor: useHead title may not update reactively.

Passing status.value and statusText.value directly evaluates them once. If the error were ever to change, the title would not update. For an error page this is typically acceptable, but for full reactivity consider wrapping in a getter:

useHead({
  title: () => `${status.value} - ${statusText.value}`,
})

ℹ️ Review info

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 97eb03f and be724be.

📒 Files selected for processing (1)
  • app/error.vue

Copy link
Contributor

@graphieros graphieros left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Changes made in the chart configuration are ok

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants