Skip to content
This repository has been archived by the owner on Jun 4, 2022. It is now read-only.

Commit

Permalink
Merge pull request #99 from heruns/dev
Browse files Browse the repository at this point in the history
chore(plugin): add hover style for copy button & clear selection after copy
  • Loading branch information
ppoffice authored May 6, 2019
2 parents 1c7958b + 60330a2 commit 29ea81e
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions layout/plugins/clipboard.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@
color: #9a9a9a;
background: none;
border: none;
cursor: pointer;
}
.hljs .clipboard-btn:hover {
color: #8a8a8a;
}
.hljs > .clipboard-btn {
Expand Down Expand Up @@ -51,6 +56,9 @@
return document.getElementById(trigger.getAttribute('data-clipboard-target-id'));
}
});
clipboard.on('success', function(e) {
e.clearSelection();
})
})
</script>
<% } %>

0 comments on commit 29ea81e

Please sign in to comment.