Skip to content

Commit

Permalink
Show copied message on header
Browse files Browse the repository at this point in the history
  • Loading branch information
gcatanese committed Jan 3, 2024
1 parent ea7f5da commit 3e36e6f
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions panel.js
Original file line number Diff line number Diff line change
Expand Up @@ -213,14 +213,12 @@ function copyToClipboardHandler() {
value = value.replace(THREE_DS_SUFFIX, "")
copyToClipboard(value);

// Show the message
$('#textIsCopiedMessageSpanId').show();
// Hide other message
$('#copyToClipboardMessageSpanId').hide();
// Show message "Copied!"
$('#header').html("Copied ✅");

// Hide after x seconds
setTimeout(function() {
$('#textIsCopiedMessageSpanId').hide()
$('#header').html("");
}, 1000 * 2);
}

Expand Down

0 comments on commit 3e36e6f

Please sign in to comment.