-
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
refactor: CrossLink Prev to Previous and cleanup of Pagination keys
#8378
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
👋 Codeowner Review RequestThe following codeowners have been identified for the changed files: Team reviewers: @nodejs/nodejs-website Please review the changes when you have a chance. Thank you! 🙏 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR refactors the pagination-related translation keys to improve user experience and eliminate duplication. The main change is updating "Prev" to "Previous" in the CrossLink component for better readability, while consolidating pagination translation keys under a unified structure.
Key Changes:
- Changed
common.crossLink.previousfrom "Prev" to "Previous" for improved UX - Removed duplicate
components.paginationkeys that were redundant - Updated
Pagination.tsxto reference the correctcomponents.common.paginationkeys
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| packages/i18n/src/locales/en.json | Updated CrossLink to display "Previous" instead of "Prev"; removed duplicate pagination keys from components.pagination |
| apps/site/components/Common/Pagination.tsx | Updated to use components.common.pagination keys instead of the removed components.pagination keys |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #8378 +/- ##
=======================================
Coverage 76.42% 76.42%
=======================================
Files 118 118
Lines 9928 9928
Branches 334 334
=======================================
Hits 7587 7587
Misses 2339 2339
Partials 2 2 ☔ View full report in Codecov by Sentry. |
📦 Build Size ComparisonSummary
Changes➕ Added Assets (6)
➖ Removed Assets (6)
|
necessitates renaming the key in pagination due to dynamic reference in CrossLink
Description
While browsing the site, I got bothered by the abbreviation
Prevshowing to users. We have the screen real estate to use the full word here. I was initially concerned about internationalization too, which made me look aten.jsonkey composition. I then noticed we were definingprevandnextin two places... and only using one, or worse, intermingling them. This PR unifies the keys under the more structuredcommon.pagination...now the text and the label draw from the same object.I chose not to refactor
PaginationPropsor non-user-facing references at this time which still use things likeprevandprevAria. I could be convinced to do so, but wanted to start here. This might also thrash Crowdin translations.Validation
Related Issues
Check List
pnpm formatto ensure the code follows the style guide.pnpm testto check if all tests are passing.pnpm buildto check if the website builds without errors.