highlightjs-copy icon indicating copy to clipboard operation
highlightjs-copy copied to clipboard

Show a icon with a checkmark instead of text

Open sickdyd opened this issue 9 months ago • 1 comments

Leaving this here just in case someone is interested in having something similar.

Basically this removes localization and uses the clipboard icon with a check mark on top to confirm that the copy has happened. It's a bit more discreet than the original version. I decided to do this to solve an issue I was having where the confirmation text "Copied!" was not vertically centered (check screenshot).

This is the result:

https://github.com/user-attachments/assets/8ea27360-1eee-4cdf-b861-52c5c6cd04d6

This is the alignment problem I faced:

Screenshot 2025-03-13 at 15 53 35

sickdyd avatar Mar 13 '25 06:03 sickdyd

Deploy Preview for highlightjs-copy canceled.

Name Link
Latest commit 8f6a8c3d977a785c1e5c1fcfe376d268bf553d83
Latest deploy log https://app.netlify.com/sites/highlightjs-copy/deploys/67d2816ab7f3d000084cf8a0

netlify[bot] avatar Mar 13 '25 06:03 netlify[bot]

Deploy Preview for highlightjs-copy canceled.

Name Link
Latest commit 58751e90761a76520f986afde4cacd39c25148b0
Latest deploy log https://app.netlify.com/projects/highlightjs-copy/deploys/6827ebc8dc0f2a0008e424da

netlify[bot] avatar May 17 '25 01:05 netlify[bot]