You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-08 21:42:24 +03:00
Add slash command for changing room name
Signed-off-by: Christopher Medlin <christopherjmedlin@protonmail.com>
This commit is contained in:
@@ -135,6 +135,18 @@ export const CommandMap = {
|
|||||||
},
|
},
|
||||||
}),
|
}),
|
||||||
|
|
||||||
|
name: new Command({
|
||||||
|
name: 'name',
|
||||||
|
args: '<name>',
|
||||||
|
description: _td('Sets the room name'),
|
||||||
|
runFn: function(roomId, args) {
|
||||||
|
if (args) {
|
||||||
|
return success(MatrixClientPeg.get().setRoomName(roomId, args));
|
||||||
|
}
|
||||||
|
return reject(this.getUsage());
|
||||||
|
},
|
||||||
|
}),
|
||||||
|
|
||||||
invite: new Command({
|
invite: new Command({
|
||||||
name: 'invite',
|
name: 'invite',
|
||||||
args: '<user-id>',
|
args: '<user-id>',
|
||||||
|
|||||||
@@ -133,6 +133,7 @@
|
|||||||
"Changes your display nickname": "Changes your display nickname",
|
"Changes your display nickname": "Changes your display nickname",
|
||||||
"Changes colour scheme of current room": "Changes colour scheme of current room",
|
"Changes colour scheme of current room": "Changes colour scheme of current room",
|
||||||
"Sets the room topic": "Sets the room topic",
|
"Sets the room topic": "Sets the room topic",
|
||||||
|
"Sets the room name": "Sets the room name",
|
||||||
"Invites user with given id to current room": "Invites user with given id to current room",
|
"Invites user with given id to current room": "Invites user with given id to current room",
|
||||||
"Joins room with given alias": "Joins room with given alias",
|
"Joins room with given alias": "Joins room with given alias",
|
||||||
"Leave room": "Leave room",
|
"Leave room": "Leave room",
|
||||||
|
|||||||
@@ -677,6 +677,7 @@
|
|||||||
"Integrations Error": "Integrations Error",
|
"Integrations Error": "Integrations Error",
|
||||||
"NOTE: Apps are not end-to-end encrypted": "NOTE: Apps are not end-to-end encrypted",
|
"NOTE: Apps are not end-to-end encrypted": "NOTE: Apps are not end-to-end encrypted",
|
||||||
"Sets the room topic": "Sets the room topic",
|
"Sets the room topic": "Sets the room topic",
|
||||||
|
"Sets the room name": "Sets the room name",
|
||||||
"The maximum permitted number of widgets have already been added to this room.": "The maximum permitted number of widgets have already been added to this room.",
|
"The maximum permitted number of widgets have already been added to this room.": "The maximum permitted number of widgets have already been added to this room.",
|
||||||
"To get started, please pick a username!": "To get started, please pick a username!",
|
"To get started, please pick a username!": "To get started, please pick a username!",
|
||||||
"Unable to create widget.": "Unable to create widget.",
|
"Unable to create widget.": "Unable to create widget.",
|
||||||
|
|||||||
Reference in New Issue
Block a user