коммит произвёл
Joram Wilander
родитель
6f0a7e4b13
Коммит
f3825ba766
@@ -4,6 +4,7 @@
|
||||
import React from 'react';
|
||||
|
||||
import SuggestionStore from 'stores/suggestion_store.jsx';
|
||||
import ChannelStore from 'stores/channel_store.jsx';
|
||||
import UserStore from 'stores/user_store.jsx';
|
||||
import * as Utils from 'utils/utils.jsx';
|
||||
import Client from 'utils/web_client.jsx';
|
||||
@@ -25,7 +26,10 @@ class AtMentionSuggestion extends Suggestion {
|
||||
description = (
|
||||
<FormattedMessage
|
||||
id='suggestion.mention.all'
|
||||
defaultMessage='Notifies everyone in the team'
|
||||
defaultMessage='Notifies everyone in the channel, use in {townsquare} to notify the whole team'
|
||||
values={{
|
||||
townsquare: ChannelStore.getByName('town-square').display_name
|
||||
}}
|
||||
/>
|
||||
);
|
||||
icon = <i className='mention__image fa fa-users fa-2x'/>;
|
||||
@@ -97,10 +101,13 @@ export default class AtMentionProvider {
|
||||
}
|
||||
|
||||
if (!pretext.startsWith('/msg')) {
|
||||
// add dummy users to represent the @channel special mention when not using the /msg command
|
||||
// add dummy users to represent the @channel and @all special mentions when not using the /msg command
|
||||
if ('channel'.startsWith(usernamePrefix)) {
|
||||
filtered.push({username: 'channel'});
|
||||
}
|
||||
if ('all'.startsWith(usernamePrefix)) {
|
||||
filtered.push({username: 'all'});
|
||||
}
|
||||
}
|
||||
|
||||
filtered = filtered.sort((a, b) => a.username.localeCompare(b.username));
|
||||
|
||||
@@ -842,7 +842,7 @@ class NotificationsTab extends React.Component {
|
||||
/>
|
||||
<FormattedMessage
|
||||
id='user.settings.notifications.channelWide'
|
||||
defaultMessage='Channel-wide mentions "@channel"'
|
||||
defaultMessage='Channel-wide mentions "@channel", "@all"'
|
||||
/>
|
||||
</label>
|
||||
</div>
|
||||
@@ -896,12 +896,9 @@ class NotificationsTab extends React.Component {
|
||||
keys.push('@' + user.username);
|
||||
}
|
||||
|
||||
// if (this.state.allKey) {
|
||||
// keys.push('@all');
|
||||
// }
|
||||
|
||||
if (this.state.channelKey) {
|
||||
keys.push('@channel');
|
||||
keys.push('@all');
|
||||
}
|
||||
if (this.state.customKeys.length > 0) {
|
||||
keys = keys.concat(this.state.customKeys.split(','));
|
||||
|
||||
Ссылка в новой задаче
Block a user