Skip to content

Instantly share code, notes, and snippets.

@zipcode
Created September 10, 2015 17:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zipcode/29357726dcb249cbc344 to your computer and use it in GitHub Desktop.
Save zipcode/29357726dcb249cbc344 to your computer and use it in GitHub Desktop.
Clicking on an emoji in the emoji list opens the original image
// ==UserScript==
// @name Slack emoji downloader
// @namespace http://zip.sexy
// @version 0.1
// @description Clickable slack emoji on the config page
// @author @zip
// @match https://*.slack.com/customize/emoji
// @grant none
// ==/UserScript==
// It's really annoyingly hard to copy an emoji from one slack to another
// this lets you click on an icon and get at its original form
// so you can save it and use it somewhere else
(function() {
document.body.addEventListener("click", function (event) {
if (event.target && event.target.dataset && event.target.dataset.original) {
window.open(event.target.dataset.original);
event.preventDefault();
event.stopPropagation();
}
});
}).call(this);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment