Last active
November 8, 2018 13:13
-
-
Save blha303/7938194 to your computer and use it in GitHub Desktop.
IRCCloud replace & with formatting characters | &b is bold, &r is reset, &<number from 0 to 15> is a color | I'm going to regret this.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var inputbox = $('#bufferInputView' + cb().bid()); | |
var msg = inputbox.val(); | |
inputbox.val(""); | |
var cc = "\u0003"; | |
var bold = "\u0002"; | |
var reset = "\u000f"; | |
var italic = "\u0016"; | |
var underline = "\u001f"; | |
cb().say(msg.replace(/&b/g,bold).replace(/&r/g,reset).replace(/&i/g,italic).replace(/&u/g,underline).replace(/&/g,cc)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks! Just what I needed.