From 57db26a827f124fae4d15ef4d7796b9c04c757c3 Mon Sep 17 00:00:00 2001 From: rainbow napkin Date: Wed, 1 Oct 2025 21:41:49 -0400 Subject: [PATCH 1/2] Quick Cleanup --- src/app/channel/channelManager.js | 3 --- www/css/theme/movie-night.css | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/src/app/channel/channelManager.js b/src/app/channel/channelManager.js index b36d7b5..289c227 100644 --- a/src/app/channel/channelManager.js +++ b/src/app/channel/channelManager.js @@ -20,11 +20,8 @@ const config = require('../../../config.json'); //Local Imports const channelModel = require('../../schemas/channel/channelSchema'); const emoteModel = require('../../schemas/emoteSchema'); -const {userModel} = require('../../schemas/user/userSchema'); -const userBanModel = require('../../schemas/user/userBanSchema'); const socketUtils = require('../../utils/socketUtils'); const loggerUtils = require('../../utils/loggerUtils'); -const csrfUtils = require('../../utils/csrfUtils'); const presenceUtils = require('../../utils/presenceUtils'); const activeChannel = require('./activeChannel'); const chatHandler = require('./chatHandler'); diff --git a/www/css/theme/movie-night.css b/www/css/theme/movie-night.css index 00e2f24..fa3d836 100644 --- a/www/css/theme/movie-night.css +++ b/www/css/theme/movie-night.css @@ -214,7 +214,7 @@ textarea{ text-shadow: var(--danger-glow0-alt1); } -.positive-button{ +.positive-button:not([disabled]){ background-color: var(--focus0); color: white; } From 23ad6794738c928ebcec5cf37e1e23173ee46b92 Mon Sep 17 00:00:00 2001 From: rainbow napkin Date: Thu, 2 Oct 2025 02:29:29 -0400 Subject: [PATCH 2/2] Client-side PM Pre-processing complete. --- www/js/channel/panels/pmPanel.js | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/www/js/channel/panels/pmPanel.js b/www/js/channel/panels/pmPanel.js index 85e191e..261c694 100644 --- a/www/js/channel/panels/pmPanel.js +++ b/www/js/channel/panels/pmPanel.js @@ -108,14 +108,20 @@ class pmPanel extends panelObj{ //Pull current sesh from sesh list const sesh = this.client.pmHandler.seshList.get(this.activeSesh); - //Send message out to server - this.client.pmSocket.emit("pm", { - recipients: sesh.recipients, - msg: this.seshPrompt.value - }); + //Preprocess message from prompt + const preprocessedMessage = this.client.chatBox.commandPreprocessor.preprocess(this.seshPrompt.value); - //Clear our prompt - this.seshPrompt.value = ""; + //If preprocessedMessage had it's send flag thrown as false + if(preprocessedMessage != false){ + //Stick recipients into the pre-processed message + preprocessedMessage.recipients = sesh.recipients; + + //Send message out to server + this.client.pmSocket.emit("pm", preprocessedMessage); + } + + //Clear our prompt + this.seshPrompt.value = ""; } }