This is a VS Code extension that will allow your Twitch chat to highlight a line of code via a command message. Example: `!line 8 server.js`. See master branch README.md for more details
The user should now be able to set the following settings for the extension:
channels (The channels the twitch-js IRC module will join)
highlightColor (The background color the decoration will use)
highlightBorder (The CSS style the decoration border will use)
announceBot (Whether the bot should announce when joining and departing the chat room)
joinMessage (The message the bot will say when joining a chat room)
leaveMessage (The message the bot will say when leaving a chat room)
Additionally, when the user tries to connect for the first time, and no credentials exist, the user will be prompted to set the credentials. There is a bug at the moment where the VSCode input prompts cancel if VSCode loses focus. I haven't had the time to figure that one out yet.
Changed Files
package.json
I removed the unnecessary settings that this plugin doesn't use.
I added highlightColor and highlightBorder settings.
extensions.ts
I changed the highlightDecorationType variable to be set both when the extension is activated and when a change to the twitchhighlighter settings have changed.
I created the setupDecoratorType function to handle setting the highlightDecorationType values.
Refactored the startChatHandler to allow the end user to add their twitch credentials if they aren't present when they try to connect.
Refactored the setTwitchClientIdHandler, setTwitchClientIdWithCredentialManager, setTwitchPasswordHandler, and setPasswordWithCredentialManager functions to await the VSCode input prompts when setting the twitch credentials. (Although for some reason if VSCode loses focus the prompts will close...)
server.ts
I changed the twitch-js module to debug by default (the twitch-js outputs more info into our log)
I added the ability for the twitch client to announce it's arrival to the chat room and its departure. This can be adjusted in the settings.
The user should now be able to set the following settings for the extension:
Additionally, when the user tries to connect for the first time, and no credentials exist, the user will be prompted to set the credentials.
There is a bug at the moment where the VSCode input prompts cancel if VSCode loses focus. I haven't had the time to figure that one out yet.Changed Files
package.json
highlightColor
andhighlightBorder
settings.extensions.ts
highlightDecorationType
variable to be set both when the extension is activated and when a change to thetwitchhighlighter
settings have changed.setupDecoratorType
function to handle setting thehighlightDecorationType
values.startChatHandler
to allow the end user to add their twitch credentials if they aren't present when they try to connect.setTwitchClientIdHandler
,setTwitchClientIdWithCredentialManager
,setTwitchPasswordHandler
, andsetPasswordWithCredentialManager
functions to await the VSCode input prompts when setting the twitch credentials. (Although for some reason if VSCode loses focus the prompts will close...)server.ts
Addresses
11
32
33 (changed
console.debug
toconsole.log
)