Skip to content

[FEATURE] Add Copy Button for Code Blocks #9

@pushkarscripts

Description

@pushkarscripts

Feature Description

Add a copy-to-clipboard button for code snippets and command blocks across the platform.

The button should allow users to quickly copy code/examples without manually selecting the text.

Problem It Solves

Currently, users have to manually select and copy code snippets or terminal commands from the documentation pages. This becomes inconvenient, especially for longer code blocks or mobile users.

A dedicated copy button would improve usability and make the learning experience smoother.

Proposed Solution

Implement a copy button for all code blocks that:

  • copies the content to the clipboard on click
  • provides visual feedback such as "Copied!"
  • works properly on both desktop and mobile devices
  • maintains consistency with the current UI/theme

The implementation should remain lightweight and avoid unnecessary dependencies where possible.

Additional Context

The feature can behave similarly to copy buttons commonly seen in modern documentation platforms and developer websites.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or requestgood first issueGood for newcomersgssoc-26Part of GirlScript Summer of Code 2026gssoc:approvedApproved for GSSOC '26

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions