Skip to content

bug:Fixed the missing Copy button in Installation Section#364

Merged
tsahil01 merged 1 commit intododopayments:mainfrom
saurabh007007:feature/copybutton-missing
Feb 23, 2026
Merged

bug:Fixed the missing Copy button in Installation Section#364
tsahil01 merged 1 commit intododopayments:mainfrom
saurabh007007:feature/copybutton-missing

Conversation

@saurabh007007
Copy link
Copy Markdown
Contributor

@saurabh007007 saurabh007007 commented Feb 18, 2026

Summary

This PR adds the missing copy button inside the installation block. #363

Changes

  • Changed the src/components/landing/quick-integrations.tsx file to add copy button here

Screenshots/Recordings (if UI)

  • Before
Screenshot 2026-02-18 at 5 32 19 AM
  • After
Screenshot 2026-02-18 at 5 40 28 AM

How to Test

Steps to validate locally:

  1. npm ci
  2. npm run typecheck
  3. npm run build

Checklist

  • Title is clear and descriptive
  • Related issue linked (if any)
  • Tests or manual verification steps included
  • CI passes (typecheck & build)
  • Docs updated (if needed)

Summary by CodeRabbit

  • New Features
    • Added copy buttons to code blocks on the landing page integration examples, enabling users to quickly copy code snippets for npm, pnpm, and bun package managers.

Copilot AI review requested due to automatic review settings February 18, 2026 00:14
@vercel
Copy link
Copy Markdown

vercel bot commented Feb 18, 2026

@saurabh007007 is attempting to deploy a commit to the Dodo Payments Team on Vercel.

A member of the Team first needs to authorize it.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Feb 18, 2026

📝 Walkthrough

Walkthrough

The pull request modifies the CodeExample component in the quick-integrations file to add CodeBlockCopyButton children to npm, pnpm, and bun code blocks, enabling copy functionality for installation commands without changing code structure or content.

Changes

Cohort / File(s) Summary
Copy Button Addition
src/components/landing/quick-integrations.tsx
Added CodeBlockCopyButton as a child element to CodeBlock components for npm, pnpm, and bun package manager tabs to provide copy-to-clipboard functionality.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Possibly related issues

Poem

🐰 A copy button hops with glee,
Three tabs now share this symphony,
Npm, pnpm, bun so fine,
Click and paste with one design!
Installation dreams come true,

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and specifically describes the main change: adding the missing copy button in the Installation Section.
Description check ✅ Passed The PR description covers all key sections from the template including summary, changes, before/after screenshots, testing steps, and a checklist.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

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

Tip

Issue Planner is now in beta. Read the docs and try it out! Share your feedback on Discord.


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
Copy Markdown
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

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@src/components/landing/quick-integrations.tsx`:
- Line 138: The CodeBlockCopyButton is being rendered as an icon-only Button
(size="icon") with CopyIcon/CheckIcon children and no accessible name; add an
aria-label to each call site of CodeBlockCopyButton (all four usages) so screen
readers get a meaningful name, or alternatively update the component in
src/components/landing/code-block.tsx to provide a sensible default aria-label
when spreading ...props into Button (e.g., when only icon children are present)
so Button(size="icon") always receives an aria-label; reference
CodeBlockCopyButton, Button, CopyIcon, and CheckIcon when making the change.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds the missing copy button to the Installation section’s command code blocks on the landing page (fixing issue #363), aligning the Installation tabbed commands with other code examples that already support copy-to-clipboard.

Changes:

  • Render CodeBlockCopyButton inside each Installation command CodeBlock (npm/pnpm/bun).
  • Ensures the copy affordance appears for tabbed install commands, not just single-code examples.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +137 to +139
>
<CodeBlockCopyButton />
</CodeBlock>
Copy link

Copilot AI Feb 18, 2026

Choose a reason for hiding this comment

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

CodeBlockCopyButton is rendered as an icon-only button without an accessible name. Please pass an aria-label (and/or add visually hidden text) so screen readers can identify it (e.g., "Copy command").

Copilot uses AI. Check for mistakes.
Comment on lines +147 to +149
>
<CodeBlockCopyButton />
</CodeBlock>
Copy link

Copilot AI Feb 18, 2026

Choose a reason for hiding this comment

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

CodeBlockCopyButton is used as an icon-only control here without an accessible label. Add an aria-label (and/or sr-only text) so assistive tech can announce the purpose of the button.

Copilot uses AI. Check for mistakes.
Comment on lines +157 to +159
>
<CodeBlockCopyButton />
</CodeBlock>
Copy link

Copilot AI Feb 18, 2026

Choose a reason for hiding this comment

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

This icon-only CodeBlockCopyButton needs an accessible name. Please add an aria-label (and/or visually hidden text) describing the action (copy the bun command).

Copilot uses AI. Check for mistakes.
@tsahil01
Copy link
Copy Markdown
Member

@saurabh007007 thanks for the fix, merging it.

@tsahil01 tsahil01 merged commit 4651ebc into dodopayments:main Feb 23, 2026
8 of 10 checks passed
@saurabh007007
Copy link
Copy Markdown
Contributor Author

@saurabh007007 thanks for the fix, merging it.

Thanks for merging it! Happy to contribute — looking forward to working on more improvements.

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.

3 participants