From cd7b710d944f63d85f78adcf2d2d148b097b8e81 Mon Sep 17 00:00:00 2001 From: nerix Date: Sat, 26 Jul 2025 12:24:56 +0200 Subject: [PATCH] feat: show text if emote failed to load (#6355) --- CHANGELOG.md | 1 + src/messages/MessageElement.cpp | 62 ++++--- src/messages/MessageElement.hpp | 5 + tests/snapshots/IrcMessageHandler/action.json | 15 -- .../IrcMessageHandler/bad-emotes.json | 15 -- .../IrcMessageHandler/bad-emotes2.json | 15 -- tests/snapshots/IrcMessageHandler/cheer1.json | 160 ------------------ tests/snapshots/IrcMessageHandler/cheer2.json | 32 ---- tests/snapshots/IrcMessageHandler/cheer3.json | 32 ---- .../IrcMessageHandler/emote-emoji.json | 45 ----- tests/snapshots/IrcMessageHandler/emote.json | 15 -- tests/snapshots/IrcMessageHandler/emotes.json | 45 ----- .../snapshots/IrcMessageHandler/emotes2.json | 135 --------------- .../snapshots/IrcMessageHandler/emotes3.json | 60 ------- .../snapshots/IrcMessageHandler/emotes4.json | 15 -- .../snapshots/IrcMessageHandler/emotes5.json | 15 -- .../IrcMessageHandler/first-msg.json | 15 -- .../IrcMessageHandler/ignore-replace.json | 75 -------- tests/snapshots/IrcMessageHandler/mod.json | 30 ---- .../snapshots/IrcMessageHandler/no-tags.json | 15 -- .../IrcMessageHandler/redeemed-highlight.json | 30 ---- .../IrcMessageHandler/reply-single.json | 45 ----- .../IrcMessageHandler/reward-bits.json | 15 -- .../IrcMessageHandler/rm-deleted.json | 60 ------- .../IrcMessageHandler/shared-chat-emotes.json | 105 ------------ tests/snapshots/IrcMessageHandler/simple.json | 15 -- 26 files changed, 47 insertions(+), 1025 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index fc9c0183..b52db477 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -49,6 +49,7 @@ - Bugfix: Fixed eventsub message delete notifications not being affected by "Show deletions of single messages". (#6233) - Bugfix: Don't add reply buttons to messages that are invalid reply targets. (#6119) - Bugfix: Fixed invalid commands from being forwarded to Helix, making it possible for information to leak (e.g. if you typed `/bann username ban reason` it would be seen by others in chat as `username ban reason`). (#6272, #6330) +- Bugfix: Emotes that failed to load their images now show as text. (#6355) - Bugfix: Fixed a crash that occurs when searching for emotes in channel-less contexts. (#6357) - Dev: Mini refactor of Split. (#6148) - Dev: Conan will no longer generate a `CMakeUserPresets.json` file. (#6117) diff --git a/src/messages/MessageElement.cpp b/src/messages/MessageElement.cpp index 26d12dcc..cb85790e 100644 --- a/src/messages/MessageElement.cpp +++ b/src/messages/MessageElement.cpp @@ -181,11 +181,9 @@ QJsonObject CircularImageElement::toJson() const EmoteElement::EmoteElement(const EmotePtr &emote, MessageElementFlags flags, const MessageColor &textElementColor) : MessageElement(flags) + , textColor_(textElementColor) , emote_(emote) { - this->textElement_.reset(new TextElement( - emote->getCopyString(), MessageElementFlag::Misc, textElementColor)); - this->setTooltip(emote->tooltip.string); } @@ -197,33 +195,38 @@ EmotePtr EmoteElement::getEmote() const void EmoteElement::addToContainer(MessageLayoutContainer &container, const MessageLayoutContext &ctx) { - if (ctx.flags.hasAny(this->getFlags())) + if (ctx.flags.hasNone(this->getFlags())) { - if (ctx.flags.has(MessageElementFlag::EmoteImages)) - { - auto image = this->emote_->images.getImageOrLoaded( - container.getImageScale()); - if (image->isEmpty()) - { - return; - } + return; + } + if (ctx.flags.has(MessageElementFlag::EmoteImages)) + { + auto image = + this->emote_->images.getImageOrLoaded(container.getImageScale()); + + if (image->isEmpty()) + { + this->ensureText(true); + } + else + { auto emoteScale = getSettings()->emoteScale.getValue(); auto size = image->size() * container.getScale() * emoteScale; container.addElement(this->makeImageLayoutElement(image, size)); - } - else - { - if (this->textElement_) - { - auto textCtx = ctx; - textCtx.flags = MessageElementFlag::Misc; - this->textElement_->addToContainer(container, textCtx); - } + return; } } + else + { + this->ensureText(false); + } + + auto textCtx = ctx; + textCtx.flags = MessageElementFlag::Misc; + this->textElement_->addToContainer(container, textCtx); } MessageLayoutElement *EmoteElement::makeImageLayoutElement( @@ -232,6 +235,23 @@ MessageLayoutElement *EmoteElement::makeImageLayoutElement( return new ImageLayoutElement(*this, image, size); } +void EmoteElement::ensureText(bool asFallback) +{ + if (this->textElement_ && asFallback == this->usingFallbackColor_) + { + return; + } + + auto color = this->textColor_; + if (asFallback) + { + color = MessageColor::System; + } + this->textElement_ = std::make_unique( + this->emote_->getCopyString(), MessageElementFlag::Misc, color); + this->usingFallbackColor_ = asFallback; +} + QJsonObject EmoteElement::toJson() const { auto base = MessageElement::toJson(); diff --git a/src/messages/MessageElement.hpp b/src/messages/MessageElement.hpp index 17ad724f..67f664ac 100644 --- a/src/messages/MessageElement.hpp +++ b/src/messages/MessageElement.hpp @@ -397,7 +397,12 @@ protected: QSizeF size); private: + void ensureText(bool asFallback); + std::unique_ptr textElement_; + MessageColor textColor_; + bool usingFallbackColor_ = false; + EmotePtr emote_; }; diff --git a/tests/snapshots/IrcMessageHandler/action.json b/tests/snapshots/IrcMessageHandler/action.json index 639648d9..aa5257f0 100644 --- a/tests/snapshots/IrcMessageHandler/action.json +++ b/tests/snapshots/IrcMessageHandler/action.json @@ -144,21 +144,6 @@ "type": "None", "value": "" }, - "text": { - "color": "#ffcc44ff", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/bad-emotes.json b/tests/snapshots/IrcMessageHandler/bad-emotes.json index a219dd15..a89e54ef 100644 --- a/tests/snapshots/IrcMessageHandler/bad-emotes.json +++ b/tests/snapshots/IrcMessageHandler/bad-emotes.json @@ -112,21 +112,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa Tooltip", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/bad-emotes2.json b/tests/snapshots/IrcMessageHandler/bad-emotes2.json index 528a0bdc..8051e075 100644 --- a/tests/snapshots/IrcMessageHandler/bad-emotes2.json +++ b/tests/snapshots/IrcMessageHandler/bad-emotes2.json @@ -112,21 +112,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa Tooltip", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/cheer1.json b/tests/snapshots/IrcMessageHandler/cheer1.json index 5dd1a350..9d6eccaa 100644 --- a/tests/snapshots/IrcMessageHandler/cheer1.json +++ b/tests/snapshots/IrcMessageHandler/cheer1.json @@ -113,22 +113,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "cheer", - "emote" - ] - }, "tooltip": "Cheer1
Twitch Cheer Emote", "trailingSpace": true, "type": "EmoteElement" @@ -148,22 +132,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "cheer", - "emote" - ] - }, "tooltip": "Cheer1
Twitch Cheer Emote", "trailingSpace": true, "type": "EmoteElement" @@ -213,22 +181,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "cheer", - "emote" - ] - }, "tooltip": "Cheer1
Twitch Cheer Emote", "trailingSpace": true, "type": "EmoteElement" @@ -248,22 +200,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "cheer", - "emote" - ] - }, "tooltip": "Cheer1
Twitch Cheer Emote", "trailingSpace": true, "type": "EmoteElement" @@ -298,22 +234,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "cheer", - "emote" - ] - }, "tooltip": "Cheer1
Twitch Cheer Emote", "trailingSpace": true, "type": "EmoteElement" @@ -333,22 +253,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "cheer", - "emote" - ] - }, "tooltip": "Cheer1
Twitch Cheer Emote", "trailingSpace": true, "type": "EmoteElement" @@ -383,22 +287,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "cheer", - "emote" - ] - }, "tooltip": "Cheer1
Twitch Cheer Emote", "trailingSpace": true, "type": "EmoteElement" @@ -418,22 +306,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "cheer", - "emote" - ] - }, "tooltip": "Cheer1
Twitch Cheer Emote", "trailingSpace": true, "type": "EmoteElement" @@ -468,22 +340,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "cheer", - "emote" - ] - }, "tooltip": "Cheer1
Twitch Cheer Emote", "trailingSpace": true, "type": "EmoteElement" @@ -503,22 +359,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "cheer", - "emote" - ] - }, "tooltip": "Cheer1
Twitch Cheer Emote", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/cheer2.json b/tests/snapshots/IrcMessageHandler/cheer2.json index a3649ea9..f6e2ccb9 100644 --- a/tests/snapshots/IrcMessageHandler/cheer2.json +++ b/tests/snapshots/IrcMessageHandler/cheer2.json @@ -113,22 +113,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "cheer", - "emote" - ] - }, "tooltip": "Cheer1
Twitch Cheer Emote", "trailingSpace": true, "type": "EmoteElement" @@ -148,22 +132,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "cheer", - "emote" - ] - }, "tooltip": "Cheer1
Twitch Cheer Emote", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/cheer3.json b/tests/snapshots/IrcMessageHandler/cheer3.json index 4fbc8c85..d1c4cc26 100644 --- a/tests/snapshots/IrcMessageHandler/cheer3.json +++ b/tests/snapshots/IrcMessageHandler/cheer3.json @@ -113,22 +113,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "cheer", - "emote" - ] - }, "tooltip": "Cheer1
Twitch Cheer Emote", "trailingSpace": true, "type": "EmoteElement" @@ -148,22 +132,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "cheer", - "emote" - ] - }, "tooltip": "Cheer1
Twitch Cheer Emote", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/emote-emoji.json b/tests/snapshots/IrcMessageHandler/emote-emoji.json index 8d1d03c4..203473f6 100644 --- a/tests/snapshots/IrcMessageHandler/emote-emoji.json +++ b/tests/snapshots/IrcMessageHandler/emote-emoji.json @@ -144,21 +144,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" @@ -176,21 +161,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "😂" - ] - }, "tooltip": ":joy:
Emoji", "trailingSpace": true, "type": "EmoteElement" @@ -210,21 +180,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/emote.json b/tests/snapshots/IrcMessageHandler/emote.json index 5cb520ce..b1199a17 100644 --- a/tests/snapshots/IrcMessageHandler/emote.json +++ b/tests/snapshots/IrcMessageHandler/emote.json @@ -112,21 +112,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Keepo" - ] - }, "tooltip": "Keepo
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/emotes.json b/tests/snapshots/IrcMessageHandler/emotes.json index ce387835..480e75e0 100644 --- a/tests/snapshots/IrcMessageHandler/emotes.json +++ b/tests/snapshots/IrcMessageHandler/emotes.json @@ -112,21 +112,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" @@ -146,21 +131,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Keepo" - ] - }, "tooltip": "Keepo
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" @@ -180,21 +150,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "PogChamp" - ] - }, "tooltip": "PogChamp
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/emotes2.json b/tests/snapshots/IrcMessageHandler/emotes2.json index 51c162f2..960bf3ba 100644 --- a/tests/snapshots/IrcMessageHandler/emotes2.json +++ b/tests/snapshots/IrcMessageHandler/emotes2.json @@ -94,21 +94,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "BTTVEmote" - ] - }, "tooltip": "BTTVEmote Tooltip", "trailingSpace": true, "type": "EmoteElement" @@ -128,21 +113,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" @@ -235,21 +205,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "😂" - ] - }, "tooltip": ":joy:
Emoji", "trailingSpace": true, "type": "EmoteElement" @@ -267,21 +222,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "😂" - ] - }, "tooltip": ":joy:
Emoji", "trailingSpace": true, "type": "EmoteElement" @@ -301,21 +241,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "PogChamp" - ] - }, "tooltip": "PogChamp
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" @@ -336,21 +261,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "7TVGlobal" - ] - }, "tooltip": "7TVGlobal Tooltip", "trailingSpace": true, "type": "EmoteElement" @@ -370,21 +280,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Keepo" - ] - }, "tooltip": "Keepo
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" @@ -404,21 +299,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "FFZEmote" - ] - }, "tooltip": "FFZEmote Tooltip", "trailingSpace": true, "type": "EmoteElement" @@ -438,21 +318,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "FFZGlobal" - ] - }, "tooltip": "FFZGlobal Tooltip", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/emotes3.json b/tests/snapshots/IrcMessageHandler/emotes3.json index 9121cb5b..56c68bce 100644 --- a/tests/snapshots/IrcMessageHandler/emotes3.json +++ b/tests/snapshots/IrcMessageHandler/emotes3.json @@ -92,21 +92,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "😂" - ] - }, "tooltip": ":joy:
Emoji", "trailingSpace": true, "type": "EmoteElement" @@ -126,21 +111,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa
Twitch Emote", "trailingSpace": false, "type": "EmoteElement" @@ -158,21 +128,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "😂" - ] - }, "tooltip": ":joy:
Emoji", "trailingSpace": true, "type": "EmoteElement" @@ -207,21 +162,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/emotes4.json b/tests/snapshots/IrcMessageHandler/emotes4.json index f40d884f..3bca2f62 100644 --- a/tests/snapshots/IrcMessageHandler/emotes4.json +++ b/tests/snapshots/IrcMessageHandler/emotes4.json @@ -92,21 +92,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "f" - ] - }, "tooltip": "f
Twitch Emote", "trailingSpace": false, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/emotes5.json b/tests/snapshots/IrcMessageHandler/emotes5.json index d4e792dc..967d958e 100644 --- a/tests/snapshots/IrcMessageHandler/emotes5.json +++ b/tests/snapshots/IrcMessageHandler/emotes5.json @@ -92,21 +92,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "fo" - ] - }, "tooltip": "fo
Twitch Emote", "trailingSpace": false, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/first-msg.json b/tests/snapshots/IrcMessageHandler/first-msg.json index 949f3c73..1a270628 100644 --- a/tests/snapshots/IrcMessageHandler/first-msg.json +++ b/tests/snapshots/IrcMessageHandler/first-msg.json @@ -114,21 +114,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/ignore-replace.json b/tests/snapshots/IrcMessageHandler/ignore-replace.json index 4f365b1c..4a26944c 100644 --- a/tests/snapshots/IrcMessageHandler/ignore-replace.json +++ b/tests/snapshots/IrcMessageHandler/ignore-replace.json @@ -94,21 +94,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "PogChamp" - ] - }, "tooltip": "PogChamp
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" @@ -143,21 +128,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" @@ -192,21 +162,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Keepo" - ] - }, "tooltip": "Keepo
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" @@ -247,21 +202,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" @@ -298,21 +238,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "MyCoolTwitchEmote" - ] - }, "tooltip": "MyCoolTwitchEmote Tooltip", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/mod.json b/tests/snapshots/IrcMessageHandler/mod.json index fecb35a4..78b6a0b1 100644 --- a/tests/snapshots/IrcMessageHandler/mod.json +++ b/tests/snapshots/IrcMessageHandler/mod.json @@ -119,21 +119,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kreygasm" - ] - }, "tooltip": "Kreygasm
Twitch Emote", "trailingSpace": false, "type": "EmoteElement" @@ -168,21 +153,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kreygasm" - ] - }, "tooltip": "Kreygasm
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/no-tags.json b/tests/snapshots/IrcMessageHandler/no-tags.json index a2fa64eb..6c1eb622 100644 --- a/tests/snapshots/IrcMessageHandler/no-tags.json +++ b/tests/snapshots/IrcMessageHandler/no-tags.json @@ -92,21 +92,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa Tooltip", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/redeemed-highlight.json b/tests/snapshots/IrcMessageHandler/redeemed-highlight.json index 89a99eee..778f893d 100644 --- a/tests/snapshots/IrcMessageHandler/redeemed-highlight.json +++ b/tests/snapshots/IrcMessageHandler/redeemed-highlight.json @@ -94,21 +94,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "BTTVGlobal" - ] - }, "tooltip": "BTTVGlobal Tooltip", "trailingSpace": true, "type": "EmoteElement" @@ -143,21 +128,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - ":)" - ] - }, "tooltip": ":)
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/reply-single.json b/tests/snapshots/IrcMessageHandler/reply-single.json index 4a2e96da..41e1a4c8 100644 --- a/tests/snapshots/IrcMessageHandler/reply-single.json +++ b/tests/snapshots/IrcMessageHandler/reply-single.json @@ -169,21 +169,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Keepo" - ] - }, "tooltip": "Keepo
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" @@ -203,21 +188,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "FFZEmote" - ] - }, "tooltip": "FFZEmote Tooltip", "trailingSpace": true, "type": "EmoteElement" @@ -235,21 +205,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "😭" - ] - }, "tooltip": ":sob:
Emoji", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/reward-bits.json b/tests/snapshots/IrcMessageHandler/reward-bits.json index b2a54ecd..87dffce5 100644 --- a/tests/snapshots/IrcMessageHandler/reward-bits.json +++ b/tests/snapshots/IrcMessageHandler/reward-bits.json @@ -84,21 +84,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "MyBitsEmote" - ] - }, "tooltip": "MyBitsEmote
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/rm-deleted.json b/tests/snapshots/IrcMessageHandler/rm-deleted.json index d4eca658..6bde75a8 100644 --- a/tests/snapshots/IrcMessageHandler/rm-deleted.json +++ b/tests/snapshots/IrcMessageHandler/rm-deleted.json @@ -95,21 +95,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "7TVEmote" - ] - }, "tooltip": "7TVEmote Tooltip", "trailingSpace": true, "type": "EmoteElement" @@ -129,21 +114,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" @@ -180,21 +150,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "7TVEmote" - ] - }, "tooltip": "7TVEmote Tooltip", "trailingSpace": true, "type": "EmoteElement" @@ -212,21 +167,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "❤️" - ] - }, "tooltip": ":heart:
Emoji", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/shared-chat-emotes.json b/tests/snapshots/IrcMessageHandler/shared-chat-emotes.json index 66e9d855..7089e02a 100644 --- a/tests/snapshots/IrcMessageHandler/shared-chat-emotes.json +++ b/tests/snapshots/IrcMessageHandler/shared-chat-emotes.json @@ -112,21 +112,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa
Twitch Emote", "trailingSpace": true, "type": "EmoteElement" @@ -161,21 +146,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "BTTVGlobal" - ] - }, "tooltip": "BTTVGlobal Tooltip", "trailingSpace": true, "type": "EmoteElement" @@ -211,21 +181,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "7TVGlobal" - ] - }, "tooltip": "7TVGlobal Tooltip", "trailingSpace": true, "type": "EmoteElement" @@ -260,21 +215,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "FFZGlobal" - ] - }, "tooltip": "FFZGlobal Tooltip", "trailingSpace": true, "type": "EmoteElement" @@ -294,21 +234,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "BTTVTwitchDev" - ] - }, "tooltip": "BTTVTwitchDev Tooltip", "trailingSpace": true, "type": "EmoteElement" @@ -329,21 +254,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "7TVTwitchDev" - ] - }, "tooltip": "7TVTwitchDev Tooltip", "trailingSpace": true, "type": "EmoteElement" @@ -363,21 +273,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "FFZTwitchDev" - ] - }, "tooltip": "FFZTwitchDev Tooltip", "trailingSpace": true, "type": "EmoteElement" diff --git a/tests/snapshots/IrcMessageHandler/simple.json b/tests/snapshots/IrcMessageHandler/simple.json index 6720ebd3..c4151397 100644 --- a/tests/snapshots/IrcMessageHandler/simple.json +++ b/tests/snapshots/IrcMessageHandler/simple.json @@ -114,21 +114,6 @@ "type": "None", "value": "" }, - "text": { - "color": "Text", - "flags": "Misc", - "link": { - "type": "None", - "value": "" - }, - "style": "ChatMedium", - "tooltip": "", - "trailingSpace": true, - "type": "TextElement", - "words": [ - "Kappa" - ] - }, "tooltip": "Kappa
Twitch Emote", "trailingSpace": true, "type": "EmoteElement"