Skip to content

feat: highlight selected version#964

Open
shamilkotta wants to merge 2 commits intonpmx-dev:mainfrom
shamilkotta:feat/version-selection
Open

feat: highlight selected version#964
shamilkotta wants to merge 2 commits intonpmx-dev:mainfrom
shamilkotta:feat/version-selection

Conversation

@shamilkotta
Copy link
Contributor

@shamilkotta shamilkotta commented Feb 4, 2026

fixes: #924

Before:
image

After:
image

@vercel
Copy link

vercel bot commented Feb 4, 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 4, 2026 7:07pm
2 Skipped Deployments
Project Deployment Actions Updated (UTC)
docs.npmx.dev Ignored Ignored Preview Feb 4, 2026 7:07pm
npmx-lunaria Ignored Ignored Feb 4, 2026 7:07pm

Request Review

@shamilkotta shamilkotta changed the title feat: Highlight selected version feat: highlight selected version Feb 4, 2026
@codecov
Copy link

codecov bot commented Feb 4, 2026

Codecov Report

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

Files with missing lines Patch % Lines
app/components/Package/Versions.vue 72.91% 11 Missing and 2 partials ⚠️
app/pages/package/[...package].vue 0.00% 1 Missing ⚠️

📢 Thoughts on this report? Let us know!

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 4, 2026

📝 Walkthrough

Walkthrough

The pull request refactors version highlighting logic in the package versions component. A new optional selectedVersion prop was added to enable external control of the current version display. Multiple helper functions were introduced to determine which version rows and sections should be highlighted as current, replacing hard-coded "latest" tag checks. The highlighting logic now consistently applies across visible rows, hidden rows, expanded version lists, and major version groups. The parent page component was updated to pass the selected version to the component, allowing dynamic current-version indication throughout the versions display.

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Linked Issues check ⚠️ Warning The PR addresses version highlighting in the package versions component, but the linked issue #923 is about viewing user's own likes and building a logged-in profile page, which are completely unrelated to the code changes. Verify that issue #923 is the correct linked issue for this PR. The changes implement version highlighting, not user likes functionality. Update the linked issue reference if necessary.
✅ Passed checks (2 passed)
Check name Status Explanation
Out of Scope Changes check ✅ Passed All changes are directly related to implementing version highlighting functionality in the Versions component and passing the selected version prop through the package page.
Description check ✅ Passed The pull request description relates to the changeset by referencing issue #924 and showing before/after screenshots demonstrating version highlighting functionality.

✏️ 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

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

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.

Selected package version should be highlighted in the Versions section?

1 participant