Skip to content

feat: package page to compare page carry the name#3030

Open
btea wants to merge 2 commits into
npmx-dev:mainfrom
btea:feat/package-page-to-compare-page-carrry-package-name
Open

feat: package page to compare page carry the name#3030
btea wants to merge 2 commits into
npmx-dev:mainfrom
btea:feat/package-page-to-compare-page-carrry-package-name

Conversation

@btea

@btea btea commented Jul 11, 2026

Copy link
Copy Markdown
Contributor

🔗 Linked issue

/

🧭 Context

Based on the current structure, if a user is on the package page and then clicks to jump to the compare page, I think it would be reasonable to compare the current package. Therefore, it would be more convenient to directly carry over the package name.

📚 Description

@vercel

vercel Bot commented Jul 11, 2026

Copy link
Copy Markdown
Contributor

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

Project Deployment Actions Updated (UTC)
npmx.dev Ready Ready Preview, Comment Jul 11, 2026 2:27am
2 Skipped Deployments
Project Deployment Actions Updated (UTC)
docs.npmx.dev Ignored Ignored Preview Jul 11, 2026 2:27am
npmx-lunaria Ignored Ignored Jul 11, 2026 2:27am

Request Review

@coderabbitai

coderabbitai Bot commented Jul 11, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 938e818e-54ff-4280-bbcf-d748516525ec

📥 Commits

Reviewing files that changed from the base of the PR and between 7e5b19d and 51a72f0.

📒 Files selected for processing (1)
  • app/components/Link/Base.vue
🚧 Files skipped from review as they are similar to previous changes (1)
  • app/components/Link/Base.vue

📝 Walkthrough

Summary by CodeRabbit

  • Bug Fixes
    • Improved desktop navigation for comparison pages so links correctly retain the active package context.
    • Comparison links now pass through the current link identity and adjust their destination to include the relevant package query parameters, ensuring the correct package is selected on load.

Walkthrough

Desktop navigation now passes link names to LinkBase. For compare links on package pages, LinkBase adds the current package name to the destination query before rendering the NuxtLink.

Changes

Package-aware compare links

Layer / File(s) Summary
Link name contract and navigation wiring
app/components/Link/Base.vue, app/components/AppHeader.vue
LinkBase accepts an optional name prop, and desktop navigation supplies each link’s name.
Compare destination routing
app/components/Link/Base.vue
Compare destinations merge the current package name into the query, and NuxtLink uses the computed destination.
🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title reflects the main change: carrying the current package name from the package page to the compare page.
Description check ✅ Passed The description matches the change and explains why the package name is carried to the compare page.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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.

@codecov

codecov Bot commented Jul 11, 2026

Copy link
Copy Markdown

Codecov Report

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

Files with missing lines Patch % Lines
app/components/Link/Base.vue 50.00% 3 Missing and 1 partial ⚠️

📢 Thoughts on this report? Let us know!

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@app/components/Link/Base.vue`:
- Around line 39-40: Add a JSDoc comment describing the `name` prop in the
component props definition, and update the `NuxtLink` template using
`v-bind="props"` so `name` is explicitly overridden or omitted after the spread,
preventing it from being rendered as an `<a>` attribute.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: aeeb1ecc-2d7f-4d85-b0a1-97fa8adf26c1

📥 Commits

Reviewing files that changed from the base of the PR and between 6a5befd and 7e5b19d.

📒 Files selected for processing (2)
  • app/components/AppHeader.vue
  • app/components/Link/Base.vue

Comment thread app/components/Link/Base.vue
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.

1 participant