Skip to content

feat: improve module installation flow#2342

Open
HugoRCD wants to merge 5 commits into
mainfrom
feat/improve-module-selection
Open

feat: improve module installation flow#2342
HugoRCD wants to merge 5 commits into
mainfrom
feat/improve-module-selection

Conversation

@HugoRCD

@HugoRCD HugoRCD commented Jul 22, 2026

Copy link
Copy Markdown
Member

Resolves #2326

CleanShot.2026-07-22.at.14.48.34.mp4

@HugoRCD
HugoRCD requested a review from atinux as a code owner July 22, 2026 13:49
@vercel

vercel Bot commented Jul 22, 2026

Copy link
Copy Markdown
Contributor

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

Project Deployment Actions Updated (UTC)
nuxt Ready Ready Preview, Comment Jul 22, 2026 4:13pm

Request Review

@coderabbitai

coderabbitai Bot commented Jul 22, 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: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: d590e1ff-4bee-4539-8a97-26b6a2ea975b

📥 Commits

Reviewing files that changed from the base of the PR and between f8cbfef and 285b7c8.

📒 Files selected for processing (7)
  • app/components/module/ModuleInstallGroup.vue
  • app/components/module/ModuleItem.vue
  • app/components/tools/PromptCard.vue
  • app/composables/useIdeDeeplink.ts
  • app/composables/useModules.ts
  • app/pages/modules/index.vue
  • layers/nuxi/shared/utils/ide-deeplinks.ts
🚧 Files skipped from review as they are similar to previous changes (6)
  • app/composables/useIdeDeeplink.ts
  • app/components/module/ModuleInstallGroup.vue
  • app/components/tools/PromptCard.vue
  • app/composables/useModules.ts
  • app/pages/modules/index.vue
  • app/components/module/ModuleItem.vue

📝 Walkthrough

Walkthrough

The changes add shared module installation and agent-prompt builders, modifier-key bulk selection, responsive install controls, and Cursor, Claude Code, and VS Code deeplink actions. Prompt-card and agent-tool contracts remove repository metadata in favor of optional icons. Deeplink utilities and composables now handle prompt-based browser navigation and clipboard preparation. Module detail and index pages expose the new installation, selection, and prompt controls. The root tooltip delay is reduced from 500 to 300 milliseconds.

Estimated code review effort: 4 (Complex) | ~60 minutes

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (2 warnings)

Check name Status Explanation Resolution
Out of Scope Changes check ⚠️ Warning Several IDE deeplink, prompt-card, and show_prompt changes extend beyond #2326's bulk-install name display request. Split the unrelated prompt/deeplink and VS Code changes into a separate PR, keeping this one focused on bulk-install module names.
Docstring Coverage ⚠️ Warning Docstring coverage is 16.67% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title is concise and broadly matches the module installation flow changes, though it is more general than the main feature.
Description check ✅ Passed The description is related to the PR and references the linked issue, so it is acceptable.
Linked Issues check ✅ Passed The bulk install toolbar now surfaces added modules with avatars and tooltips, satisfying #2326's request to show added module names.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/improve-module-selection

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

ESLint install timed out. The project may have too many dependencies for the sandbox.


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.

@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: 3

🧹 Nitpick comments (3)
app/components/module/ModuleInstallGroup.vue (1)

17-46: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Duplicated install/prompt copy logic across three components. ModuleInstallGroup.vue, ModuleItem.vue, and ModuleCard.vue each re-implement the same buildModuleInstallCommand/buildModuleAgentPrompt + useClipboard()/useAnalytics() copy pattern (and, in two cases, the same useIdeDeeplink() open logic), differing only by the analytics source tag.

  • app/components/module/ModuleInstallGroup.vue#L17-L46: extract copyInstall/copyPrompt/openCursor/openClaude into a shared composable parameterized by module and a source string.
  • app/components/module/ModuleItem.vue#L41-L45: replace copyInstallCommand with the same shared composable's copyInstall.
  • app/components/tools/ModuleCard.vue#L18-L45: replace copyInstall/copyPrompt with the shared composable, passing source: 'nuxt-agent'.
🤖 Prompt for 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.

In `@app/components/module/ModuleInstallGroup.vue` around lines 17 - 46, Extract
the duplicated module install, prompt-copy, and IDE-open logic into a shared
composable parameterized by module and analytics source. Update
app/components/module/ModuleInstallGroup.vue lines 17-46 to use it for
copyInstall, copyPrompt, openCursor, and openClaude; update
app/components/module/ModuleItem.vue lines 41-45 to use its copyInstall; and
update app/components/tools/ModuleCard.vue lines 18-45 to use copyInstall and
copyPrompt with source 'nuxt-agent', preserving existing analytics behavior.
app/components/module/ModuleItem.vue (1)

28-29: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Reuse selectedSort from useModules(). ModuleItem.vue is deriving the same value from route.query.sortBy that useModules() already exposes, so pulling it from the composable keeps the date/tooltip logic aligned with the rest of the modules page and avoids future drift.

🤖 Prompt for 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.

In `@app/components/module/ModuleItem.vue` around lines 28 - 29, Update
ModuleItem.vue to stop deriving selectedSort from route.query.sortBy and instead
reuse the selectedSort value returned by useModules(). Remove the now-unneeded
route/computed logic while preserving the existing date and tooltip behavior.
app/components/tools/PromptCard.vue (1)

2-14: 🎯 Functional Correctness | 🔵 Trivial | 💤 Low value

Remove the unused deeplinks prop

PromptCard now builds both IDE links from prompt, so deeplinks is never read and only makes the component contract misleading.

🤖 Prompt for 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.

In `@app/components/tools/PromptCard.vue` around lines 2 - 14, Remove the unused
deeplinks property from the props type in PromptCard, leaving prompt and the
other actively used props unchanged. Ensure callers are no longer required to
provide deeplinks and rely on the existing useIdeDeeplink flow for both IDE
links.
🤖 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/composables/useIdeDeeplink.ts`:
- Around line 40-49: Update openInCursor and openInClaudeCode to retain each
builder’s needsClipboardFallback result and show the fallback toast when it is
true, explicitly stating that the opened prompt was shortened and the complete
prompt is available in the clipboard; preserve the existing deeplink opening and
clipboard-copy behavior.

In `@app/composables/useModules.ts`:
- Around line 57-63: Update buildBulkModuleAgentPrompt to use the module’s name
when m.npm is absent, matching the existing single-module fallback and the
install command’s m.name behavior. Ensure the generated module list never
renders “undefined” for the identifier while preserving npm as the preferred
value.

In `@app/pages/modules/index.vue`:
- Around line 69-81: Update selectModuleRange so that when
lastSelectedIndex.value is null after a filter, sort, or search change, the
clicked module becomes the new anchor without replacing the existing
modulesToAdd selection; preserve prior selections while adding the clicked
module if needed, and keep normal range selection behavior unchanged when an
anchor exists.

---

Nitpick comments:
In `@app/components/module/ModuleInstallGroup.vue`:
- Around line 17-46: Extract the duplicated module install, prompt-copy, and
IDE-open logic into a shared composable parameterized by module and analytics
source. Update app/components/module/ModuleInstallGroup.vue lines 17-46 to use
it for copyInstall, copyPrompt, openCursor, and openClaude; update
app/components/module/ModuleItem.vue lines 41-45 to use its copyInstall; and
update app/components/tools/ModuleCard.vue lines 18-45 to use copyInstall and
copyPrompt with source 'nuxt-agent', preserving existing analytics behavior.

In `@app/components/module/ModuleItem.vue`:
- Around line 28-29: Update ModuleItem.vue to stop deriving selectedSort from
route.query.sortBy and instead reuse the selectedSort value returned by
useModules(). Remove the now-unneeded route/computed logic while preserving the
existing date and tooltip behavior.

In `@app/components/tools/PromptCard.vue`:
- Around line 2-14: Remove the unused deeplinks property from the props type in
PromptCard, leaving prompt and the other actively used props unchanged. Ensure
callers are no longer required to provide deeplinks and rely on the existing
useIdeDeeplink flow for both IDE links.
🪄 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: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 5a3f8058-ccbe-481d-826f-d54e6658cafd

📥 Commits

Reviewing files that changed from the base of the PR and between 7d60f57 and f7ee8a3.

📒 Files selected for processing (13)
  • app/app.vue
  • app/components/module/ModuleInstallGroup.vue
  • app/components/module/ModuleItem.vue
  • app/components/tools/ModuleCard.vue
  • app/components/tools/PromptCard.vue
  • app/composables/useIdeDeeplink.ts
  • app/composables/useModules.ts
  • app/pages/modules/[slug].vue
  • app/pages/modules/index.vue
  • layers/nuxi/agent/lib/base-instructions.ts
  • layers/nuxi/agent/tools/show_prompt.ts
  • layers/nuxi/shared/types/tools.ts
  • layers/nuxi/shared/utils/ide-deeplinks.ts
💤 Files with no reviewable changes (2)
  • layers/nuxi/shared/types/tools.ts
  • layers/nuxi/agent/lib/base-instructions.ts

Comment thread app/composables/useIdeDeeplink.ts Outdated
Comment thread app/composables/useModules.ts
Comment thread app/pages/modules/index.vue
@HugoRCD
HugoRCD marked this pull request as draft July 22, 2026 14:01
@HugoRCD HugoRCD self-assigned this Jul 22, 2026
@HugoRCD
HugoRCD marked this pull request as ready for review July 22, 2026 14:50
@HugoRCD
HugoRCD requested a review from danielroe July 22, 2026 14:51
Comment on lines +33 to +42
{
label: 'Open in Cursor',
icon: 'i-simple-icons-cursor',
onSelect: openCursor
},
{
label: 'Open in Claude Code',
icon: 'i-simple-icons-anthropic',
onSelect: openClaude
}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think we could easily get into a state where we have so many IDEs listed here.... why these two, for example?

maybe skip it and just have install + prompt options?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I listed these two because I think they're the most widely used, but also because they're the only ones I know of at the moment that have this deeplink system, which is very convenient

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

vscode://GitHub.Copilot-Chat/chat?agent=agent&prompt=<URL-encoded-prompt>
vscode-insiders://GitHub.Copilot-Chat/chat?agent=agent&prompt=<URL-encoded-prompt>

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I added VS Code, but I don't know if having Insider as well is redundant, which confirms your point that it's complicated to list some and not others, and at the same time it's a feature I find really cool

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Same with the GitHub Copilot app, you can do something like ghapp://model/gpt-5.5 if you want to open the app with that model, or something like these:

ghapp://session/new?repo=github/github-app
ghapp://session/new/github/github-app
ghapp://session/new?repo=github/github-app&pr=123
ghapp://session/new?repo=github/github-app&branch=main
ghapp://session/new?repo=github/github-app&prompt=fix+bug
ghapp://session/new?repo=github/github-app&mode=plan
ghapp://session/new?repo=github/github-app&mode=interactive
ghapp://session/new?repo=github/github-app&mode=autopilot
ghapp://session/new?repo=github/github-app&pr=123&prompt=review+this+PR&mode=autopilot
ghapp://session/new?repo=github/github-app&branch=feature/name&prompt=continue+work&mode=plan

@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/composables/useIdeDeeplink.ts`:
- Around line 33-42: Update openInCursor to sanitize the prompt by removing
Cursor-blocked text before passing it to buildCursorBrowserUrl, while continuing
to pass the original prompt to copyPromptToClipboard. Leave openInClaudeCode
unchanged.
🪄 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: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 6d5a5e37-7ca3-4b85-8a5c-b6491d6e1dba

📥 Commits

Reviewing files that changed from the base of the PR and between f7ee8a3 and 9de0ce5.

📒 Files selected for processing (8)
  • app/components/module/ModuleInstallGroup.vue
  • app/components/module/ModuleItem.vue
  • app/components/tools/ModuleCard.vue
  • app/components/tools/PromptCard.vue
  • app/composables/useIdeDeeplink.ts
  • app/composables/useModules.ts
  • app/pages/modules/index.vue
  • layers/nuxi/app/components/chat/ChatContent.vue
🚧 Files skipped from review as they are similar to previous changes (2)
  • app/components/tools/ModuleCard.vue
  • app/components/module/ModuleInstallGroup.vue

Comment thread app/composables/useIdeDeeplink.ts Outdated
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.

[Docs]: Add feature to show modules that has been added in bulk installation

2 participants