Merge pull request #1002 from RAnders00/mod-action-channel-replacement

Mod action channel replacement
This commit is contained in:
pajlada 2019-04-14 16:50:41 +02:00 committed by GitHub
commit a1918144e4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -1667,7 +1667,7 @@ void ChannelView::handleLinkClick(QMouseEvent *event, const Link &link,
case Link::UserAction:
{
QString value = link.value;
value.replace("{user}", layout->getMessage()->loginName);
value.replace("{user}", layout->getMessage()->loginName).replace("{channel}", this->channel_->getName());
this->channel_->sendMessage(value);
}
break;

View file

@ -161,7 +161,7 @@ ModerationPage::ModerationPage()
// clang-format off
auto label = modMode.emplace<QLabel>(
"Moderation mode is enabled by clicking <img width='18' height='18' src=':/buttons/modModeDisabled.png'> in a channel that you moderate.<br><br>"
"Moderation buttons can be bound to chat commands such as \"/ban {user}\", \"/timeout {user} 1000\" or any other custom text commands.<br>");
"Moderation buttons can be bound to chat commands such as \"/ban {user}\", \"/timeout {user} 1000\", \"/w someusername !report {user} was bad in channel {channel}\" or any other custom text commands.<br>");
label->setWordWrap(true);
label->setStyleSheet("color: #bbb");
// clang-format on