p2plabsxyz / dscan

A decentralized storage and file-sharing tool that uploads content to IPFS and generates decentralized QR codes.
https://chromewebstore.google.com/detail/dscan-own-your-identity-o/idpfgkgogjjgklefnkjdpghkifbjenap
MIT License
38 stars 26 forks source link

[feat]: add small "copied" popup feature after clicking on "copy generated CID" svg button #13

Closed akhileshthite closed 2 years ago

akhileshthite commented 2 years ago

Screenshot 2022-03-06 at 5 58 29 PM

Code link: https://github.com/buidltools/dscan/blob/b6ff5d621213534f8a705901e328a78071240e40/src/js/qrcode.js#L45

Copy function:

  // Copy CID to clipboard when copy button is clicked
  $("#svg-cid")
    .off()
    .on("click", function () {
      navigator.clipboard.writeText(cid);
    });

For file structure and contributing guide, check the main README.md.

atifcppprogrammer commented 2 years ago

Hi @AkhileshThite what are you looking for here specifically, from the title i gather that a small tool tip should appear indicating that the generated CID has been copied ? Yes ?

akhileshthite commented 2 years ago

Hi @AkhileshThite what are you looking for here specifically, from the title i gather that a small tool tip should appear indicating that the generated CID has been copied ? Yes ?

Yes. Something like this. but just "copied" text message. Screenshot 2022-03-09 at 8 41 00 PM

atifcppprogrammer commented 2 years ago

Thanks @AkhileshThite that clears things up, please assign it to me.

atifcppprogrammer commented 2 years ago

Hi @AkhileshThite created a pull request for this issue ! please review.

akhileshthite commented 2 years ago

Hi @AkhileshThite created a pull request for this issue ! please review.

Will review soon.