Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Makes the chat username colour the same colour as the chat text. Supports both light and dark modes.
// ==UserScript==
// @name Twitch Plain Chat colours
// @namespace https://techygrrrl.stream
// @version 0.1
// @description Make the chat username colour the main text colour.
// @author techygrrrl
// @match https://*.twitch.com/*
// @match https://*.twitch.tv/*
// @grant none
// ==/UserScript==
(function() {
'use strict';
let found = false
// Check and click in milliseconds
const CHECK_INTERVAL = 200
setInterval(() => {
perform()
}, CHECK_INTERVAL)
function perform() {
if (found) return
const css = `
.chat-author__display-name {
color: inherit !important;
}
`
const styleTag = document.createElement('style')
styleTag.innerHTML = css
document.head.appendChild(styleTag)
found = true
}
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment