mirror of
https://github.com/FrankerFaceZ/FrankerFaceZ.git
synced 2025-06-27 21:05:53 +00:00
The In-Line Actions Update
* Add extensible actions system. * Add extensive UI for configuring the actions system. * Add setting to disable channel hosting. * Fix the stupid Rooms thing popping up every time you open a channel. * Fix how we grab chat types from React. * Refactor how we handle incoming chat messages. * Add a hook for outgoing chat messages. * Fix emoji appearing squished with baseline emote alignment. * Display arrows on balloons. * Fix an issue generating emoji URLs. * Do not use the default values for settings with merge strategies if profiles have those settings, just empty. * Display a message in the chat settings menu if we tried opening FFZ's settings and failed. * Wait a bit for webpack's loader if it's not immediately there for some reason. * Probably other stuff. * Not mod cards. Yet.
This commit is contained in:
parent
e9214bb46a
commit
fdde05030f
67 changed files with 7689 additions and 226 deletions
|
@ -190,6 +190,11 @@ export default class SocketClient extends Module {
|
|||
}
|
||||
|
||||
ws.onopen = () => {
|
||||
if ( this._socket !== ws ) {
|
||||
this.log.warn('A socket connected that is not our primary socket.');
|
||||
return ws.close();
|
||||
}
|
||||
|
||||
this._state = State.CONNECTED;
|
||||
this._sent_user = false;
|
||||
|
||||
|
@ -249,11 +254,17 @@ export default class SocketClient extends Module {
|
|||
}
|
||||
|
||||
ws.onerror = () => {
|
||||
if ( ws !== this._socket )
|
||||
return;
|
||||
|
||||
if ( ! this._offline_time )
|
||||
this._offline_time = Date.now();
|
||||
}
|
||||
|
||||
ws.onclose = event => {
|
||||
if ( ws !== this._socket )
|
||||
return;
|
||||
|
||||
const old_state = this._state;
|
||||
this.log.info(`Disconnected. (${event.code}:${event.reason})`);
|
||||
|
||||
|
@ -290,6 +301,9 @@ export default class SocketClient extends Module {
|
|||
|
||||
|
||||
ws.onmessage = event => {
|
||||
if ( ws !== this._socket )
|
||||
return;
|
||||
|
||||
// Format:
|
||||
// -1 <cmd_name>[ <json_data>]
|
||||
// <reply-id> <ok/err>[ <json_data>]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue