RoleColorEverywhere: Fix not working on voice channel and chat (#3934)

Co-authored-by: Nuckyz <61953774+Nuckyz@users.noreply.github.com>
This commit is contained in:
sadan4 2026-01-23 21:28:49 -05:00 committed by GitHub
parent 1e284c7cdf
commit fbfc38a1a6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -127,7 +127,7 @@ export default definePlugin({
find: "#{intl::GUEST_NAME_SUFFIX})]",
replacement: [
{
match: /#{intl::GUEST_NAME_SUFFIX}.{0,50}?""\](?<=guildId:(\i),.{0,50}?user:(\i).+?)/,
match: /#{intl::GUEST_NAME_SUFFIX}.{0,50}?""\](?<=guildId:(\i),.+?user:(\i).+?)/,
replace: "$&,style:$self.getColorStyle($2.id,$1),"
}
],
@ -195,7 +195,7 @@ export default definePlugin({
const author = useMessageAuthor(message);
// Do not apply role color if the send fails, otherwise it becomes indistinguishable
if (message.state !== "SEND_FAILED") return;
if (message.state === "SEND_FAILED") return;
if (author.colorString != null && messageSaturation !== 0) {
const value = `color-mix(in oklab, ${author.colorString} ${messageSaturation}%, var({DEFAULT}))`;