mirror of
https://github.com/FrankerFaceZ/FrankerFaceZ.git
synced 2025-08-23 22:40:54 +00:00
4.40.0
* Added: Chat actions for modding and un-modding users. * Fixed: Settings not being removed when an add-on is unloaded. * Changed: Add a few new icons. * API Added: Add support for header backgrounds for rich token documents. * API Added: Methods for adding/updating emotes to and removing emotes from an emote set. * API Added: Context flag to disable FFZ's chat message processing. * API Changed: Add-ons can now be hot reloaded for development purposes. This feature may be somewhat unstable.
This commit is contained in:
parent
14400e16bc
commit
8e48021c43
35 changed files with 1285 additions and 214 deletions
|
@ -39,6 +39,12 @@ export default class ChatLine extends Module {
|
|||
|
||||
this.line_types = {};
|
||||
|
||||
this.line_types.unknown = {
|
||||
renderNotice: (msg, current_user, room, inst, e) => {
|
||||
return `Unknown message type: ${msg.ffz_type}`
|
||||
}
|
||||
};
|
||||
|
||||
this.line_types.cheer = {
|
||||
renderNotice: (msg, current_user, room, inst, e) => {
|
||||
return this.i18n.tList(
|
||||
|
@ -741,6 +747,9 @@ other {# messages were deleted by a moderator.}
|
|||
if ( ! type && msg.bits > 0 && t.chat.context.get('chat.bits.cheer-notice') )
|
||||
type = t.line_types.cheer;
|
||||
|
||||
if ( ! type && msg.ffz_type )
|
||||
type = t.line_types.unknown;
|
||||
|
||||
if ( type ) {
|
||||
if ( type.render )
|
||||
return type.render(msg, current_user, current_room, this, e);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue