summaryrefslogtreecommitdiffstats
path: root/web/react/utils/constants.jsx
diff options
context:
space:
mode:
Diffstat (limited to 'web/react/utils/constants.jsx')
-rw-r--r--web/react/utils/constants.jsx62
1 files changed, 56 insertions, 6 deletions
diff --git a/web/react/utils/constants.jsx b/web/react/utils/constants.jsx
index 58ee8e2d2..891bc4624 100644
--- a/web/react/utils/constants.jsx
+++ b/web/react/utils/constants.jsx
@@ -1,24 +1,30 @@
// Copyright (c) 2015 Mattermost, Inc. All Rights Reserved.
// See License.txt for license information.
-var keyMirror = require('keymirror');
+import keyMirror from 'keymirror';
-module.exports = {
+export default {
ActionTypes: keyMirror({
RECIEVED_ERROR: null,
CLICK_CHANNEL: null,
CREATE_CHANNEL: null,
LEAVE_CHANNEL: null,
+ CREATE_POST: null,
+ POST_DELETED: null,
+
RECIEVED_CHANNELS: null,
RECIEVED_CHANNEL: null,
RECIEVED_MORE_CHANNELS: null,
RECIEVED_CHANNEL_EXTRA_INFO: null,
+ FOCUS_POST: null,
RECIEVED_POSTS: null,
+ RECIEVED_FOCUSED_POST: null,
RECIEVED_POST: null,
RECIEVED_EDIT_POST: null,
RECIEVED_SEARCH: null,
+ RECIEVED_SEARCH_TERM: null,
RECIEVED_POST_SELECTED: null,
RECIEVED_MENTION_DATA: null,
RECIEVED_ADD_MENTION: null,
@@ -39,8 +45,20 @@ module.exports = {
RECIEVED_LOGS: null,
RECIEVED_ALL_TEAMS: null,
+ SHOW_SEARCH: null,
+
TOGGLE_IMPORT_THEME_MODAL: null,
- TOGGLE_INVITE_MEMBER_MODAL: null
+ TOGGLE_INVITE_MEMBER_MODAL: null,
+ TOGGLE_DELETE_POST_MODAL: null,
+ TOGGLE_GET_TEAM_INVITE_LINK_MODAL: null,
+ TOGGLE_REGISTER_APP_MODAL: null,
+
+ SUGGESTION_PRETEXT_CHANGED: null,
+ SUGGESTION_RECEIVED_SUGGESTIONS: null,
+ SUGGESTION_CLEAR_SUGGESTIONS: null,
+ SUGGESTION_COMPLETE_WORD: null,
+ SUGGESTION_SELECT_NEXT: null,
+ SUGGESTION_SELECT_PREVIOUS: null
}),
PayloadSources: keyMirror({
@@ -59,7 +77,8 @@ module.exports = {
TYPING: 'typing'
},
- SPECIAL_MENTIONS: ['all', 'channel'],
+ //SPECIAL_MENTIONS: ['all', 'channel'],
+ SPECIAL_MENTIONS: ['channel'],
CHARACTER_LIMIT: 4000,
IMAGE_TYPES: ['jpg', 'gif', 'bmp', 'png', 'jpeg'],
AUDIO_TYPES: ['mp3', 'wav', 'wma', 'm4a', 'flac', 'aac'],
@@ -96,10 +115,14 @@ module.exports = {
EMAIL_SERVICE: 'email',
POST_CHUNK_SIZE: 60,
MAX_POST_CHUNKS: 3,
+ POST_FOCUS_CONTEXT_RADIUS: 10,
POST_LOADING: 'loading',
POST_FAILED: 'failed',
POST_DELETED: 'deleted',
- POST_TYPE_JOIN_LEAVE: 'join_leave',
+ POST_TYPE_JOIN_LEAVE: 'system_join_leave',
+ SYSTEM_MESSAGE_PREFIX: 'system_',
+ SYSTEM_MESSAGE_PROFILE_NAME: 'System',
+ SYSTEM_MESSAGE_PROFILE_IMAGE: '/static/images/logo_compact.png',
RESERVED_TEAM_NAMES: [
'www',
'web',
@@ -126,6 +149,7 @@ module.exports = {
],
MONTHS: ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'],
MAX_DMS: 20,
+ MAX_CHANNEL_POPOVER_COUNT: 100,
DM_CHANNEL: 'D',
OPEN_CHANNEL: 'O',
PRIVATE_CHANNEL: 'P',
@@ -333,6 +357,20 @@ module.exports = {
}
],
DEFAULT_CODE_THEME: 'github',
+ FONTS: {
+ 'Droid Serif': 'font--droid_serif',
+ 'Roboto Slab': 'font--roboto_slab',
+ Lora: 'font--lora',
+ Arvo: 'font--arvo',
+ 'Open Sans': 'font--open_sans',
+ Roboto: 'font--roboto',
+ 'PT Sans': 'font--pt_sans',
+ Lato: 'font--lato',
+ 'Source Sans Pro': 'font--source_sans_pro',
+ 'Exo 2': 'font--exo_2',
+ Ubuntu: 'font--ubuntu'
+ },
+ DEFAULT_FONT: 'Open Sans',
Preferences: {
CATEGORY_DIRECT_CHANNEL_SHOW: 'direct_channel_show',
CATEGORY_DISPLAY_SETTINGS: 'display_settings',
@@ -353,7 +391,8 @@ module.exports = {
BACKSPACE: 8,
ENTER: 13,
ESCAPE: 27,
- SPACE: 32
+ SPACE: 32,
+ TAB: 9
},
HighlightedLanguages: {
diff: 'Diff',
@@ -387,5 +426,16 @@ module.exports = {
},
NotificationPrefs: {
MENTION: 'mention'
+ },
+ FeatureTogglePrefix: 'feature_enabled_',
+ PRE_RELEASE_FEATURES: {
+ MARKDOWN_PREVIEW: {
+ label: 'markdown_preview', // github issue: https://github.com/mattermost/platform/pull/1389
+ description: 'Show markdown preview option in message input box'
+ },
+ EMBED_PREVIEW: {
+ label: 'embed_preview',
+ description: 'Show preview snippet of links below message'
+ }
}
};