Skip to content

Comments

feat: show replaceable dependencies#1468

Merged
ghostdevv merged 2 commits intomainfrom
jg/replaceable-depoondencies
Feb 13, 2026
Merged

feat: show replaceable dependencies#1468
ghostdevv merged 2 commits intomainfrom
jg/replaceable-depoondencies

Conversation

@43081j
Copy link
Contributor

@43081j 43081j commented Feb 13, 2026

This adds a replacements notice to the dependency list just like outdated,
vulnerable, etc.

Each dependency with community replacements shows an amber warning and
tooltip.

@vercel
Copy link

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

Request Review

@github-actions
Copy link

github-actions bot commented Feb 13, 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.
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 13, 2026

Codecov Report

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

Files with missing lines Patch % Lines
app/components/Package/Dependencies.vue 87.50% 1 Missing and 1 partial ⚠️

📢 Thoughts on this report? Let us know!

This adds a replacements notice to the dependency list just like outdated,
vulnerable, etc.

Each dependency with community replacements shows an amber warning and
tooltip.
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 13, 2026

📝 Walkthrough

Walkthrough

Adds dependency replacement suggestions: a new client-only composable useReplacementDependencies fetches replacement data per dependency and exposes a shallow reactive map. The Dependencies component integrates this to show per-dependency replacement indicators, tooltips and CSS classes via new helpers (getDepVersionTooltip, getDepVersionClass) and i18n keys. Added translations and schema entry (has_replacement) in i18n and lunaria locale files. New unit tests cover the composable for success, error handling and empty/undefined inputs.

Possibly related PRs

  • refactor: separate npm composables #827 — Also modifies app/components/Package/Dependencies.vue and the dependency-version tooltip/class logic; closely related changes to how per-dependency version UI is computed.

Suggested labels

front

Suggested reviewers

  • danielroe
  • whitep4nth3r
🚥 Pre-merge checks | ✅ 2
✅ Passed checks (2 passed)
Check name Status Explanation
Description check ✅ Passed The pull request description accurately describes the changeset, detailing the addition of a replacements notice to the dependency list with amber warning and tooltip indicators.
Merge Conflict Detection ✅ Passed ✅ No merge conflicts detected when merging into main

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

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch jg/replaceable-depoondencies

No actionable comments were generated in the recent review. 🎉


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

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
app/components/Package/Dependencies.vue (1)

130-171: ⚠️ Potential issue | 🟡 Minor

Add SR‑only text for the replacement indicator.

Screen readers currently won’t get the “has replacement” message, unlike outdated/vulnerable indicators. Add an SR‑only hint so the new indicator is accessible.

♿ Suggested fix
             <TooltipApp
               v-if="replacementDeps[dep]"
               class="shrink-0 p-2 -m-2 text-amber-700 dark:text-amber-500"
               aria-hidden="true"
               :text="$t('package.dependencies.has_replacement')"
             >
               <span class="i-carbon:idea w-3 h-3" />
             </TooltipApp>
+            <span v-if="replacementDeps[dep]" class="sr-only">
+              ({{ $t('package.dependencies.has_replacement') }})
+            </span>

@ghostdevv ghostdevv added this pull request to the merge queue Feb 13, 2026
Merged via the queue into main with commit 295520c Feb 13, 2026
20 checks passed
@ghostdevv ghostdevv deleted the jg/replaceable-depoondencies branch February 13, 2026 16:27
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