Skip to content

feat: improve code page scroll to top#1739

Open
btea wants to merge 1 commit intonpmx-dev:mainfrom
btea:feat/improve-code-page-scroll-to-top
Open

feat: improve code page scroll to top#1739
btea wants to merge 1 commit intonpmx-dev:mainfrom
btea:feat/improve-code-page-scroll-to-top

Conversation

@btea
Copy link
Contributor

@btea btea commented Feb 28, 2026

🔗 Linked issue

/

🧭 Context

improve #1686

📚 Description

/

@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 7:14am
2 Skipped Deployments
Project Deployment Actions Updated (UTC)
docs.npmx.dev Ignored Ignored Preview Feb 28, 2026 7:14am
npmx-lunaria Ignored Ignored Feb 28, 2026 7:14am

Request Review

@codecov
Copy link

codecov bot commented Feb 28, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ All tests successful. No failed tests found.

📢 Thoughts on this report? Let us know!

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 28, 2026

📝 Walkthrough

Walkthrough

This change modifies the package code preview component to add scroll position-based visibility control for a "Scroll to Top" button. A reactive isVisible computed property is introduced that derives its state from the vertical scroll position (y) obtained via the useScroll() composable on the content container. The button is conditionally rendered only when the scroll position exceeds the defined SCROLL_TO_TOP_THRESHOLD constant. The component's public interface remains unchanged.

Possibly related PRs

Suggested reviewers

  • danielroe
🚥 Pre-merge checks | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Description check ❓ Inconclusive The pull request description is largely empty or placeholder text, providing minimal information about the changes despite the changeset being concrete. Author should provide a meaningful description explaining why the scroll-to-top visibility feature was implemented and how it addresses issue #1686.

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

Actionable comments posted: 1


ℹ️ Review info

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 8d13fe9 and 230cbaa.

📒 Files selected for processing (1)
  • app/pages/package-code/[[org]]/[packageName]/v/[version]/[...filePath].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