Skip to content

Instantly share code, notes, and snippets.

@Nexuist
Last active September 17, 2017 00:09
Show Gist options
  • Save Nexuist/90860d54c906b238c63857bcd43ecb0c to your computer and use it in GitHub Desktop.
Save Nexuist/90860d54c906b238c63857bcd43ecb0c to your computer and use it in GitHub Desktop.
Paste this into Discord's DevTools for a TouchBar thinking emoji (🤔) button.
const {TouchBar} = require("electron").remote;
const {TouchBarButton} = TouchBar;
let thinkingButton = new TouchBarButton({
label: "🤔",
backgroundColor: "#7851A9",
click: () => {
let chatbox = document.getElementsByTagName("textarea")[0];
chatbox.value += " :thinking:";
}
});
let bar = new TouchBar([
thinkingButton
]);
require("electron").remote.getCurrentWindow().setTouchBar(bar);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment