diff --git a/src/App.vue b/src/App.vue index f938f54..cd2b1a3 100644 --- a/src/App.vue +++ b/src/App.vue @@ -653,7 +653,7 @@ export default { }, isOp() { // Returns if the current user has operator rights - return this.jwt.claims.op; + return this.jwt.claims.op || this.whoMap[this.username].op; }, isVIP() { // Returns if the current user has VIP rights. @@ -933,6 +933,14 @@ export default { this.messageBox.selectionStart = this.messageBox.selectionEnd = this.messageBox.value.length; }); }, + sendCommand(message) { + // Automatically send a message to the chat server. + // e.g. for the ProfileModal to send a "/kick username" command for easy operator buttons. + let origMsg = this.message; + this.message = message; + this.sendMessage(); + this.message = origMsg; + }, sendMessage() { if (!this.message) { return; @@ -4064,11 +4072,23 @@ export default { :message="reportModal.message" @accept="doReport" @cancel="reportModal.visible = false"> - +
diff --git a/src/components/ProfileModal.vue b/src/components/ProfileModal.vue index f1d3062..f3d166f 100644 --- a/src/components/ProfileModal.vue +++ b/src/components/ProfileModal.vue @@ -1,10 +1,13 @@