Merge pull request #2208 from mattermost/client-upgrades
Updating some client deps + eslint
Этот коммит содержится в:
@@ -1,204 +0,0 @@
|
||||
{
|
||||
"extends": "eslint:recommended",
|
||||
"ecmaFeatures": {
|
||||
"jsx": true,
|
||||
"blockBindings": true,
|
||||
"modules": true,
|
||||
"classes": true,
|
||||
"arrowFunctions": true,
|
||||
"defaultParams": true
|
||||
},
|
||||
"parser": "babel-eslint",
|
||||
"plugins": [
|
||||
"react"
|
||||
],
|
||||
"env": {
|
||||
"browser": true,
|
||||
"node": true,
|
||||
"jquery": true,
|
||||
"es6": true
|
||||
},
|
||||
"globals": {
|
||||
"React": false,
|
||||
"ReactDOM": false,
|
||||
"ReactBootstrap": false,
|
||||
"ReactIntl": false,
|
||||
"ReactIntlLocaleData": false,
|
||||
"Chart": false,
|
||||
"katex": false
|
||||
},
|
||||
"rules": {
|
||||
"comma-dangle": [2, "never"],
|
||||
"no-arrow-condition": 2,
|
||||
"no-case-declarations": 2,
|
||||
"no-cond-assign": [2, "except-parens"],
|
||||
"no-console": 2,
|
||||
"no-constant-condition": 2,
|
||||
"no-debugger": 2,
|
||||
"no-dupe-args": 2,
|
||||
"no-dupe-keys": 2,
|
||||
"no-duplicate-case": 2,
|
||||
"no-empty": 2,
|
||||
"no-empty-pattern": 2,
|
||||
"no-ex-assign": 2,
|
||||
"no-extra-semi": 2,
|
||||
"no-fallthrough": 2,
|
||||
"no-func-assign": 2,
|
||||
"no-inner-declarations": 0,
|
||||
"no-invalid-regexp": 2,
|
||||
"no-irregular-whitespace": 2,
|
||||
"no-unexpected-multiline": 2,
|
||||
"no-unreachable": 2,
|
||||
"no-magic-numbers": [1, { "ignore": [-1, 0, 1, 2], "enforceConst": true, "detectObjects": true } ],
|
||||
"valid-typeof": 2,
|
||||
|
||||
"block-scoped-var": 2,
|
||||
"complexity": [0, 8],
|
||||
"consistent-return": 2,
|
||||
"curly": [2, "all"],
|
||||
"dot-location": [2, "object"],
|
||||
"dot-notation": 2,
|
||||
"eqeqeq": [2, "smart"],
|
||||
"global-require": 2,
|
||||
"guard-for-in": 2,
|
||||
"no-alert": 2,
|
||||
"no-array-constructor": 2,
|
||||
"no-caller": 2,
|
||||
"no-div-regex": 2,
|
||||
"no-else-return": 2,
|
||||
"no-eval": 2,
|
||||
"no-extend-native": 2,
|
||||
"no-extra-bind": 2,
|
||||
"no-floating-decimal": 2,
|
||||
"no-implied-eval": 2,
|
||||
"no-iterator": 2,
|
||||
"no-labels": 2,
|
||||
"no-lone-blocks": 2,
|
||||
"no-loop-func": 2,
|
||||
"no-multi-spaces": [2, { "exceptions": { "Property": false } }],
|
||||
"no-multi-str": 0,
|
||||
"no-native-reassign": 2,
|
||||
"no-new": 2,
|
||||
"no-new-func": 2,
|
||||
"no-new-object": 2,
|
||||
"no-new-wrappers": 2,
|
||||
"no-octal-escape": 2,
|
||||
"no-param-reassign": 2,
|
||||
"no-process-env": 2,
|
||||
"no-process-exit": 2,
|
||||
"no-proto": 2,
|
||||
"no-redeclare": 2,
|
||||
"no-return-assign": [2, "always"],
|
||||
"no-script-url": 2,
|
||||
"no-self-compare": 2,
|
||||
"no-sequences": 2,
|
||||
"no-throw-literal": 2,
|
||||
"no-undef-init": 2,
|
||||
"no-unused-expressions": 2,
|
||||
"no-useless-concat": 1,
|
||||
"no-void": 2,
|
||||
"no-warning-comments": 1,
|
||||
"no-with": 2,
|
||||
"radix": 2,
|
||||
"vars-on-top": 0,
|
||||
"wrap-iife": [2, "outside"],
|
||||
"yoda": [2, "never", {"exceptRange": false, "onlyEquality": false}],
|
||||
|
||||
"no-undefined": 2,
|
||||
"no-shadow": [2, {"hoist": "functions"}],
|
||||
"no-shadow-restricted-names": 2,
|
||||
"no-unused-vars": [2, {"vars": "all", "args": "after-used"}],
|
||||
"no-use-before-define": [2, "nofunc"],
|
||||
|
||||
// Style
|
||||
"array-bracket-spacing": [2, "never"],
|
||||
"brace-style": [2, "1tbs", { "allowSingleLine": false }],
|
||||
"camelcase": [2, {"properties": "never"}],
|
||||
"comma-spacing": [2, {"before": false, "after": true}],
|
||||
"comma-style": [2, "last"],
|
||||
"computed-property-spacing": [2, "never"],
|
||||
"consistent-this": [2, "self"],
|
||||
"func-names": 2,
|
||||
"func-style": [2, "declaration"],
|
||||
"indent": [2, 4, {"SwitchCase": 0}],
|
||||
"jsx-quotes": [2, "prefer-single"],
|
||||
"key-spacing": [2, {"beforeColon": false, "afterColon": true}],
|
||||
"linebreak-style": 2,
|
||||
"lines-around-comment": [2, { "beforeBlockComment": true, "beforeLineComment": true, "allowBlockStart": true, "allowBlockEnd": true }],
|
||||
"new-cap": 2,
|
||||
"new-parens": 2,
|
||||
"no-lonely-if": 2,
|
||||
"no-mixed-spaces-and-tabs": 2,
|
||||
"no-multiple-empty-lines": [2, {"max": 1}],
|
||||
"no-negated-condition": 2,
|
||||
"no-nested-ternary": 2,
|
||||
"no-spaced-func": 2,
|
||||
"no-ternary": 0,
|
||||
"no-trailing-spaces": [2, { "skipBlankLines": false }],
|
||||
"no-underscore-dangle": 2,
|
||||
"no-unneeded-ternary": [2, {"defaultAssignment": false}],
|
||||
"object-curly-spacing": [2, "never"],
|
||||
"one-var": [2, "never"],
|
||||
"operator-linebreak": [2, "after"],
|
||||
"padded-blocks": [2, "never"],
|
||||
"quote-props": [2, "as-needed"],
|
||||
"quotes": [2, "single", "avoid-escape"],
|
||||
"semi": [2, "always"],
|
||||
"semi-spacing": [2, {"before": false, "after": true}],
|
||||
"space-after-keywords": [2, "always"],
|
||||
"space-before-blocks": [2, "always"],
|
||||
"space-before-function-paren": [2, "never"],
|
||||
"space-before-keywords": [2, "always"],
|
||||
"space-in-parens": [2, "never"],
|
||||
"space-infix-ops": 2,
|
||||
"space-return-throw-case": 2,
|
||||
"space-unary-ops": [2, { "words": true, "nonwords": false }],
|
||||
"wrap-regex": 2,
|
||||
|
||||
// ES6 stuff
|
||||
"arrow-parens": [2, "always"],
|
||||
"arrow-body-style": 0,
|
||||
"arrow-spacing": [2, { "before": true, "after": true }],
|
||||
"constructor-super": 2,
|
||||
"generator-star-spacing": [2, {"before": false, "after": true}],
|
||||
"no-class-assign": 2,
|
||||
"no-const-assign": 2,
|
||||
"no-dupe-class-members": 2,
|
||||
"no-this-before-super": 2,
|
||||
"no-var": 0,
|
||||
"object-shorthand": [1, "always"],
|
||||
"prefer-arrow-callback": 1,
|
||||
"prefer-const": 1,
|
||||
"prefer-spread": 2,
|
||||
"prefer-reflect": 1,
|
||||
"prefer-template": 0,
|
||||
"require-yield": 2,
|
||||
|
||||
// React Specific
|
||||
"react/display-name": [2, { "acceptTranspilerName": true }],
|
||||
"react/jsx-boolean-value": [2, "always"],
|
||||
"react/jsx-closing-bracket-location": [2, { "location": "tag-aligned" }],
|
||||
"react/jsx-curly-spacing": [2, "never"],
|
||||
"react/jsx-indent-props": [2, 4],
|
||||
"react/jsx-key": 2,
|
||||
"react/jsx-max-props-per-line": [2, { "maximum": 1 }],
|
||||
"react/jsx-no-bind": 1,
|
||||
"react/jsx-no-duplicate-props": [2, { "ignoreCase": false }],
|
||||
"react/jsx-no-literals": 1,
|
||||
"react/jsx-no-undef": 2,
|
||||
"react/jsx-uses-react": 2,
|
||||
"react/jsx-uses-vars": 2,
|
||||
"react/no-danger": 0,
|
||||
"react/no-did-mount-set-state": 2,
|
||||
"react/no-did-update-set-state": 2,
|
||||
"react/no-direct-mutation-state": 2,
|
||||
"react/no-multi-comp": [2, { "ignoreStateless": true }],
|
||||
"react/no-set-state": 0,
|
||||
"react/no-unknown-property": 2,
|
||||
"react/prefer-es6-class": 2,
|
||||
"react/prop-types": 2,
|
||||
"react/self-closing-comp": 2,
|
||||
"react/sort-comp": 0,
|
||||
"react/wrap-multilines": 2
|
||||
}
|
||||
}
|
||||
226
web/react/.eslintrc.json
Обычный файл
226
web/react/.eslintrc.json
Обычный файл
@@ -0,0 +1,226 @@
|
||||
{
|
||||
"extends": "eslint:recommended",
|
||||
"parserOptions": {
|
||||
"ecmaVersion": 6,
|
||||
"sourceType": "module",
|
||||
"ecmaFeatures": {
|
||||
"jsx": true,
|
||||
"impliedStrict": true,
|
||||
"modules": true
|
||||
}
|
||||
},
|
||||
"parser": "babel-eslint",
|
||||
"plugins": [
|
||||
"react"
|
||||
],
|
||||
"env": {
|
||||
"browser": true,
|
||||
"node": true,
|
||||
"jquery": true,
|
||||
"es6": true
|
||||
},
|
||||
"globals": {
|
||||
"React": false,
|
||||
"ReactDOM": false,
|
||||
"ReactBootstrap": false,
|
||||
"ReactIntl": false,
|
||||
"ReactIntlLocaleData": false,
|
||||
"Chart": false,
|
||||
"katex": false
|
||||
},
|
||||
"rules": {
|
||||
"comma-dangle": [2, "never"],
|
||||
"array-callback-return": 2,
|
||||
"prefer-rest-params": 2,
|
||||
"no-unmodified-loop-condition": 2,
|
||||
"sort-imports": 0,
|
||||
"no-new-symbol": 2,
|
||||
"no-empty-function": 2,
|
||||
"no-whitespace-before-property": 2,
|
||||
"no-useless-constructor": 2,
|
||||
"id-blacklist": 0,
|
||||
"one-var-declaration-per-line": 0,
|
||||
"no-extra-label": 2,
|
||||
"template-curly-spacing": [2, "never"],
|
||||
"no-self-assign": 2,
|
||||
"newline-per-chained-call": 0,
|
||||
"no-confusing-arrow": 2,
|
||||
"no-case-declarations": 2,
|
||||
"no-cond-assign": [2, "except-parens"],
|
||||
"no-console": 2,
|
||||
"no-constant-condition": 2,
|
||||
"no-debugger": 2,
|
||||
"no-dupe-args": 2,
|
||||
"no-dupe-keys": 2,
|
||||
"no-duplicate-case": 2,
|
||||
"no-empty": 2,
|
||||
"no-empty-pattern": 2,
|
||||
"no-ex-assign": 2,
|
||||
"no-extra-semi": 2,
|
||||
"no-fallthrough": 2,
|
||||
"no-func-assign": 2,
|
||||
"no-inner-declarations": 0,
|
||||
"no-invalid-regexp": 2,
|
||||
"no-irregular-whitespace": 2,
|
||||
"no-unexpected-multiline": 2,
|
||||
"no-unreachable": 2,
|
||||
"no-magic-numbers": [1, { "ignore": [-1, 0, 1, 2], "enforceConst": true, "detectObjects": true } ],
|
||||
"valid-typeof": 2,
|
||||
|
||||
"block-scoped-var": 2,
|
||||
"complexity": [0, 8],
|
||||
"consistent-return": 2,
|
||||
"curly": [2, "all"],
|
||||
"dot-location": [2, "object"],
|
||||
"dot-notation": 2,
|
||||
"eqeqeq": [2, "smart"],
|
||||
"global-require": 2,
|
||||
"guard-for-in": 2,
|
||||
"no-alert": 2,
|
||||
"no-array-constructor": 2,
|
||||
"no-caller": 2,
|
||||
"no-div-regex": 2,
|
||||
"no-else-return": 2,
|
||||
"no-eval": 2,
|
||||
"no-extend-native": 2,
|
||||
"no-extra-bind": 2,
|
||||
"no-floating-decimal": 2,
|
||||
"no-implied-eval": 2,
|
||||
"no-implicit-globals": 0,
|
||||
"no-iterator": 2,
|
||||
"no-labels": 2,
|
||||
"no-lone-blocks": 2,
|
||||
"no-loop-func": 2,
|
||||
"no-multi-spaces": [2, { "exceptions": { "Property": false } }],
|
||||
"no-multi-str": 0,
|
||||
"no-native-reassign": 2,
|
||||
"no-new": 2,
|
||||
"no-new-func": 2,
|
||||
"no-new-object": 2,
|
||||
"no-new-wrappers": 2,
|
||||
"no-octal-escape": 2,
|
||||
"no-param-reassign": 2,
|
||||
"no-process-env": 2,
|
||||
"no-process-exit": 2,
|
||||
"no-proto": 2,
|
||||
"no-redeclare": 2,
|
||||
"no-return-assign": [2, "always"],
|
||||
"no-script-url": 2,
|
||||
"no-self-compare": 2,
|
||||
"no-sequences": 2,
|
||||
"no-throw-literal": 2,
|
||||
"no-undef-init": 2,
|
||||
"no-unused-expressions": 2,
|
||||
"no-useless-concat": 1,
|
||||
"no-void": 2,
|
||||
"no-warning-comments": 1,
|
||||
"no-with": 2,
|
||||
"radix": 2,
|
||||
"vars-on-top": 0,
|
||||
"wrap-iife": [2, "outside"],
|
||||
"yoda": [2, "never", {"exceptRange": false, "onlyEquality": false}],
|
||||
|
||||
"no-undefined": 2,
|
||||
"no-shadow": [2, {"hoist": "functions"}],
|
||||
"no-shadow-restricted-names": 2,
|
||||
"no-unused-vars": [2, {"vars": "all", "args": "after-used"}],
|
||||
"no-use-before-define": [2, "nofunc"],
|
||||
|
||||
// Style
|
||||
"array-bracket-spacing": [2, "never"],
|
||||
"brace-style": [2, "1tbs", { "allowSingleLine": false }],
|
||||
"camelcase": [2, {"properties": "never"}],
|
||||
"comma-spacing": [2, {"before": false, "after": true}],
|
||||
"comma-style": [2, "last"],
|
||||
"computed-property-spacing": [2, "never"],
|
||||
"consistent-this": [2, "self"],
|
||||
"func-names": 2,
|
||||
"func-style": [2, "declaration"],
|
||||
"indent": [2, 4, {"SwitchCase": 0}],
|
||||
"jsx-quotes": [2, "prefer-single"],
|
||||
"key-spacing": [2, {"beforeColon": false, "afterColon": true}],
|
||||
"linebreak-style": 2,
|
||||
"lines-around-comment": [2, { "beforeBlockComment": true, "beforeLineComment": true, "allowBlockStart": true, "allowBlockEnd": true }],
|
||||
"new-cap": 2,
|
||||
"new-parens": 2,
|
||||
"no-lonely-if": 2,
|
||||
"no-mixed-spaces-and-tabs": 2,
|
||||
"no-multiple-empty-lines": [2, {"max": 1}],
|
||||
"no-negated-condition": 2,
|
||||
"no-nested-ternary": 2,
|
||||
"no-spaced-func": 2,
|
||||
"no-ternary": 0,
|
||||
"no-trailing-spaces": [2, { "skipBlankLines": false }],
|
||||
"no-underscore-dangle": 2,
|
||||
"no-unneeded-ternary": [2, {"defaultAssignment": false}],
|
||||
"object-curly-spacing": [2, "never"],
|
||||
"one-var": [2, "never"],
|
||||
"operator-linebreak": [2, "after"],
|
||||
"padded-blocks": [2, "never"],
|
||||
"quote-props": [2, "as-needed"],
|
||||
"quotes": [2, "single", "avoid-escape"],
|
||||
"semi": [2, "always"],
|
||||
"semi-spacing": [2, {"before": false, "after": true}],
|
||||
"keyword-spacing": [2, {"before": true, "after": true, "overrides": {}}],
|
||||
"space-before-blocks": [2, "always"],
|
||||
"space-before-function-paren": [2, "never"],
|
||||
"space-in-parens": [2, "never"],
|
||||
"space-infix-ops": 2,
|
||||
"space-unary-ops": [2, { "words": true, "nonwords": false }],
|
||||
"wrap-regex": 2,
|
||||
|
||||
// ES6 stuff
|
||||
"arrow-parens": [2, "always"],
|
||||
"arrow-body-style": 0,
|
||||
"arrow-spacing": [2, { "before": true, "after": true }],
|
||||
"constructor-super": 2,
|
||||
"generator-star-spacing": [2, {"before": false, "after": true}],
|
||||
"no-class-assign": 2,
|
||||
"no-const-assign": 2,
|
||||
"no-dupe-class-members": 2,
|
||||
"no-this-before-super": 2,
|
||||
"no-var": 0,
|
||||
"object-shorthand": [1, "always"],
|
||||
"prefer-arrow-callback": 1,
|
||||
"prefer-const": 1,
|
||||
"prefer-spread": 2,
|
||||
"prefer-reflect": 1,
|
||||
"prefer-template": 0,
|
||||
"require-yield": 2,
|
||||
|
||||
// React Specific
|
||||
"react/display-name": [2, { "ignoreTranspilerName": false }],
|
||||
"react/no-deprecated": 2,
|
||||
"react/no-is-mounted": 2,
|
||||
"react/no-string-refs": 1,
|
||||
"react/jsx-pascal-case": 2,
|
||||
"react/jsx-indent": [1, 4],
|
||||
"react/jsx-equals-spacing": [2, "never"],
|
||||
"react/jsx-handler-names": 0,
|
||||
"react/jsx-boolean-value": [2, "always"],
|
||||
"react/jsx-closing-bracket-location": [2, { "location": "tag-aligned" }],
|
||||
"react/jsx-curly-spacing": [2, "never"],
|
||||
"react/jsx-indent-props": [2, 4],
|
||||
"react/jsx-key": 2,
|
||||
"react/jsx-max-props-per-line": [2, { "maximum": 1 }],
|
||||
"react/jsx-no-bind": 1,
|
||||
"react/jsx-space-before-closing": [2, "never"],
|
||||
"react/jsx-no-duplicate-props": [2, { "ignoreCase": false }],
|
||||
"react/jsx-no-literals": 1,
|
||||
"react/jsx-no-undef": 2,
|
||||
"react/jsx-uses-react": 2,
|
||||
"react/jsx-uses-vars": 2,
|
||||
"react/no-danger": 0,
|
||||
"react/no-did-mount-set-state": 2,
|
||||
"react/no-did-update-set-state": 2,
|
||||
"react/no-direct-mutation-state": 2,
|
||||
"react/no-multi-comp": [2, { "ignoreStateless": true }],
|
||||
"react/no-set-state": 0,
|
||||
"react/no-unknown-property": 2,
|
||||
"react/prefer-es6-class": 2,
|
||||
"react/prop-types": 2,
|
||||
"react/self-closing-comp": 2,
|
||||
"react/sort-comp": 0,
|
||||
"react/wrap-multilines": 2
|
||||
}
|
||||
}
|
||||
@@ -68,7 +68,7 @@ class AccessHistoryModal extends React.Component {
|
||||
render() {
|
||||
var content;
|
||||
if (this.state.audits.loading) {
|
||||
content = (<LoadingScreen />);
|
||||
content = (<LoadingScreen/>);
|
||||
} else {
|
||||
content = (
|
||||
<AuditTable
|
||||
|
||||
@@ -199,7 +199,7 @@ export default class ActivityLogModal extends React.Component {
|
||||
className='activity-log__table'
|
||||
>
|
||||
<div className='activity-log__report'>
|
||||
<div className='report__platform'><i className={devicePicture} />{devicePlatform}</div>
|
||||
<div className='report__platform'><i className={devicePicture}/>{devicePlatform}</div>
|
||||
<div className='report__info'>
|
||||
<div>
|
||||
<FormattedMessage
|
||||
@@ -231,7 +231,7 @@ export default class ActivityLogModal extends React.Component {
|
||||
|
||||
let content;
|
||||
if (this.state.sessions.loading) {
|
||||
content = <LoadingScreen />;
|
||||
content = <LoadingScreen/>;
|
||||
} else {
|
||||
content = <form role='form'>{activityList}</form>;
|
||||
}
|
||||
|
||||
@@ -130,47 +130,47 @@ export default class AdminController extends React.Component {
|
||||
}
|
||||
|
||||
render() {
|
||||
var tab = <LoadingScreen />;
|
||||
var tab = <LoadingScreen/>;
|
||||
|
||||
if (this.state.config != null) {
|
||||
if (this.state.selected === 'email_settings') {
|
||||
tab = <EmailSettingsTab config={this.state.config} />;
|
||||
tab = <EmailSettingsTab config={this.state.config}/>;
|
||||
} else if (this.state.selected === 'log_settings') {
|
||||
tab = <LogSettingsTab config={this.state.config} />;
|
||||
tab = <LogSettingsTab config={this.state.config}/>;
|
||||
} else if (this.state.selected === 'logs') {
|
||||
tab = <LogsTab />;
|
||||
tab = <LogsTab/>;
|
||||
} else if (this.state.selected === 'audits') {
|
||||
tab = <AuditsTab />;
|
||||
tab = <AuditsTab/>;
|
||||
} else if (this.state.selected === 'image_settings') {
|
||||
tab = <FileSettingsTab config={this.state.config} />;
|
||||
tab = <FileSettingsTab config={this.state.config}/>;
|
||||
} else if (this.state.selected === 'privacy_settings') {
|
||||
tab = <PrivacySettingsTab config={this.state.config} />;
|
||||
tab = <PrivacySettingsTab config={this.state.config}/>;
|
||||
} else if (this.state.selected === 'rate_settings') {
|
||||
tab = <RateSettingsTab config={this.state.config} />;
|
||||
tab = <RateSettingsTab config={this.state.config}/>;
|
||||
} else if (this.state.selected === 'gitlab_settings') {
|
||||
tab = <GitLabSettingsTab config={this.state.config} />;
|
||||
tab = <GitLabSettingsTab config={this.state.config}/>;
|
||||
} else if (this.state.selected === 'sql_settings') {
|
||||
tab = <SqlSettingsTab config={this.state.config} />;
|
||||
tab = <SqlSettingsTab config={this.state.config}/>;
|
||||
} else if (this.state.selected === 'team_settings') {
|
||||
tab = <TeamSettingsTab config={this.state.config} />;
|
||||
tab = <TeamSettingsTab config={this.state.config}/>;
|
||||
} else if (this.state.selected === 'service_settings') {
|
||||
tab = <ServiceSettingsTab config={this.state.config} />;
|
||||
tab = <ServiceSettingsTab config={this.state.config}/>;
|
||||
} else if (this.state.selected === 'legal_and_support_settings') {
|
||||
tab = <LegalAndSupportSettingsTab config={this.state.config} />;
|
||||
tab = <LegalAndSupportSettingsTab config={this.state.config}/>;
|
||||
} else if (this.state.selected === 'ldap_settings') {
|
||||
tab = <LdapSettingsTab config={this.state.config} />;
|
||||
tab = <LdapSettingsTab config={this.state.config}/>;
|
||||
} else if (this.state.selected === 'license') {
|
||||
tab = <LicenseSettingsTab config={this.state.config} />;
|
||||
tab = <LicenseSettingsTab config={this.state.config}/>;
|
||||
} else if (this.state.selected === 'team_users') {
|
||||
if (this.state.teams) {
|
||||
tab = <TeamUsersTab team={this.state.teams[this.state.selectedTeam]} />;
|
||||
tab = <TeamUsersTab team={this.state.teams[this.state.selectedTeam]}/>;
|
||||
}
|
||||
} else if (this.state.selected === 'team_analytics') {
|
||||
if (this.state.teams) {
|
||||
tab = <TeamAnalyticsTab team={this.state.teams[this.state.selectedTeam]} />;
|
||||
tab = <TeamAnalyticsTab team={this.state.teams[this.state.selectedTeam]}/>;
|
||||
}
|
||||
} else if (this.state.selected === 'system_analytics') {
|
||||
tab = <SystemAnalyticsTab />;
|
||||
tab = <SystemAnalyticsTab/>;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -236,7 +236,7 @@ export default class AdminSidebar extends React.Component {
|
||||
return (
|
||||
<div className='sidebar--left sidebar--collapsable'>
|
||||
<div>
|
||||
<AdminSidebarHeader />
|
||||
<AdminSidebarHeader/>
|
||||
<div className='nav-pills__container'>
|
||||
<ul className='nav nav-pills nav-stacked'>
|
||||
<li>
|
||||
|
||||
@@ -61,7 +61,7 @@ export default class SidebarHeader extends React.Component {
|
||||
</div>
|
||||
</div>
|
||||
</a>
|
||||
<AdminNavbarDropdown ref='dropdown' />
|
||||
<AdminNavbarDropdown ref='dropdown'/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -54,7 +54,7 @@ export default class Audits extends React.Component {
|
||||
}
|
||||
|
||||
if (this.state.audits === null) {
|
||||
content = <LoadingScreen />;
|
||||
content = <LoadingScreen/>;
|
||||
} else {
|
||||
content = (
|
||||
<div style={{margin: '10px'}}>
|
||||
|
||||
@@ -47,7 +47,7 @@ export default class Logs extends React.Component {
|
||||
var content = null;
|
||||
|
||||
if (this.state.logs === null) {
|
||||
content = <LoadingScreen />;
|
||||
content = <LoadingScreen/>;
|
||||
} else {
|
||||
content = [];
|
||||
|
||||
@@ -61,7 +61,7 @@ export default class Logs extends React.Component {
|
||||
style.color = 'red';
|
||||
}
|
||||
|
||||
content.push(<br key={'br_' + i} />);
|
||||
content.push(<br key={'br_' + i}/>);
|
||||
content.push(
|
||||
<span
|
||||
key={'log_' + i}
|
||||
|
||||
@@ -4,10 +4,6 @@
|
||||
import {FormattedMessage} from 'mm-intl';
|
||||
|
||||
export default class StatisticCount extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
}
|
||||
|
||||
render() {
|
||||
let loading = (
|
||||
<FormattedMessage
|
||||
|
||||
@@ -112,9 +112,6 @@ export default class UserList extends React.Component {
|
||||
this.getTeamProfiles(newProps.team.id);
|
||||
}
|
||||
|
||||
componentWillUnmount() {
|
||||
}
|
||||
|
||||
render() {
|
||||
var serverError = '';
|
||||
if (this.state.serverError) {
|
||||
@@ -134,7 +131,7 @@ export default class UserList extends React.Component {
|
||||
/>
|
||||
</h3>
|
||||
{serverError}
|
||||
<LoadingScreen />
|
||||
<LoadingScreen/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -207,9 +207,6 @@ const holders = defineMessages({
|
||||
});
|
||||
|
||||
class AuditTable extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
}
|
||||
render() {
|
||||
var accessList = [];
|
||||
|
||||
|
||||
@@ -27,7 +27,9 @@ export default class Authorize extends React.Component {
|
||||
window.location.replace(data.redirect);
|
||||
}
|
||||
},
|
||||
() => {}
|
||||
() => {
|
||||
//Do nothing on error
|
||||
}
|
||||
);
|
||||
}
|
||||
handleDeny() {
|
||||
|
||||
@@ -55,10 +55,10 @@ export default class CenterPanel extends React.Component {
|
||||
let postsContainer;
|
||||
let createPost;
|
||||
if (this.state.showTutorialScreens) {
|
||||
postsContainer = <TutorialIntroScreens />;
|
||||
postsContainer = <TutorialIntroScreens/>;
|
||||
createPost = null;
|
||||
} else if (this.state.showPostFocus) {
|
||||
postsContainer = <PostFocusView />;
|
||||
postsContainer = <PostFocusView/>;
|
||||
|
||||
handleClick = function clickHandler(e) {
|
||||
e.preventDefault();
|
||||
@@ -80,13 +80,13 @@ export default class CenterPanel extends React.Component {
|
||||
</div>
|
||||
);
|
||||
} else {
|
||||
postsContainer = <PostsViewContainer />;
|
||||
postsContainer = <PostsViewContainer/>;
|
||||
createPost = (
|
||||
<div
|
||||
className='post-create__container'
|
||||
id='post-create'
|
||||
>
|
||||
<CreatePost />
|
||||
<CreatePost/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
@@ -108,7 +108,7 @@ export default class CenterPanel extends React.Component {
|
||||
className='app__content'
|
||||
>
|
||||
<div id='channel-header'>
|
||||
<ChannelHeader />
|
||||
<ChannelHeader/>
|
||||
</div>
|
||||
{postsContainer}
|
||||
{createPost}
|
||||
|
||||
@@ -408,7 +408,7 @@ export default class ChannelHeader extends React.Component {
|
||||
aria-expanded='true'
|
||||
>
|
||||
<strong className='heading'>{channelTitle} </strong>
|
||||
<span className='glyphicon glyphicon-chevron-down header-dropdown__icon' />
|
||||
<span className='glyphicon glyphicon-chevron-down header-dropdown__icon'/>
|
||||
</a>
|
||||
<ul
|
||||
className='dropdown-menu'
|
||||
@@ -439,7 +439,7 @@ export default class ChannelHeader extends React.Component {
|
||||
channelId={channel.id}
|
||||
/>
|
||||
</th>
|
||||
<th className='search-bar__container'><NavbarSearchBox /></th>
|
||||
<th className='search-bar__container'><NavbarSearchBox/></th>
|
||||
<th>
|
||||
<div className='dropdown channel-header__links'>
|
||||
<OverlayTrigger
|
||||
|
||||
@@ -138,7 +138,7 @@ export default class ChannelInviteModal extends React.Component {
|
||||
|
||||
var content;
|
||||
if (this.state.loading) {
|
||||
content = (<LoadingScreen />);
|
||||
content = (<LoadingScreen/>);
|
||||
} else {
|
||||
content = (
|
||||
<MemberList
|
||||
|
||||
@@ -172,7 +172,7 @@ export default class ChannelMembersModal extends React.Component {
|
||||
|
||||
let content;
|
||||
if (this.state.loading) {
|
||||
content = (<LoadingScreen />);
|
||||
content = (<LoadingScreen/>);
|
||||
} else {
|
||||
content = (
|
||||
<div className='team-member-list'>
|
||||
|
||||
@@ -168,7 +168,7 @@ export default class ChannelNotificationsModal extends React.Component {
|
||||
checked={notifyActive[1]}
|
||||
onChange={this.handleUpdateNotifyLevel.bind(this, 'all')}
|
||||
/>
|
||||
<FormattedMessage id='channel_notifications.allActivity' />
|
||||
<FormattedMessage id='channel_notifications.allActivity'/>
|
||||
</label>
|
||||
<br/>
|
||||
</div>
|
||||
@@ -179,7 +179,7 @@ export default class ChannelNotificationsModal extends React.Component {
|
||||
checked={notifyActive[2]}
|
||||
onChange={this.handleUpdateNotifyLevel.bind(this, 'mention')}
|
||||
/>
|
||||
<FormattedMessage id='channel_notifications.onlyMentions' />
|
||||
<FormattedMessage id='channel_notifications.onlyMentions'/>
|
||||
</label>
|
||||
<br/>
|
||||
</div>
|
||||
@@ -190,7 +190,7 @@ export default class ChannelNotificationsModal extends React.Component {
|
||||
checked={notifyActive[3]}
|
||||
onChange={this.handleUpdateNotifyLevel.bind(this, 'none')}
|
||||
/>
|
||||
<FormattedMessage id='channel_notifications.never' />
|
||||
<FormattedMessage id='channel_notifications.never'/>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
@@ -234,11 +234,11 @@ export default class ChannelNotificationsModal extends React.Component {
|
||||
/>
|
||||
);
|
||||
} else if (this.state.notifyLevel === 'mention') {
|
||||
describe = (<FormattedMessage id='channel_notifications.onlyMentions' />);
|
||||
describe = (<FormattedMessage id='channel_notifications.onlyMentions'/>);
|
||||
} else if (this.state.notifyLevel === 'all') {
|
||||
describe = (<FormattedMessage id='channel_notifications.allActivity' />);
|
||||
describe = (<FormattedMessage id='channel_notifications.allActivity'/>);
|
||||
} else {
|
||||
describe = (<FormattedMessage id='channel_notifications.never' />);
|
||||
describe = (<FormattedMessage id='channel_notifications.never'/>);
|
||||
}
|
||||
|
||||
handleUpdateSection = function updateSection(e) {
|
||||
@@ -311,7 +311,7 @@ export default class ChannelNotificationsModal extends React.Component {
|
||||
defaultMessage='For all unread messages'
|
||||
/>
|
||||
</label>
|
||||
<br />
|
||||
<br/>
|
||||
</div>
|
||||
<div className='radio'>
|
||||
<label>
|
||||
@@ -320,9 +320,9 @@ export default class ChannelNotificationsModal extends React.Component {
|
||||
checked={this.state.markUnreadLevel === 'mention'}
|
||||
onChange={this.handleUpdateMarkUnreadLevel.bind(this, 'mention')}
|
||||
/>
|
||||
<FormattedMessage id='channel_notifications.onlyMentions' />
|
||||
<FormattedMessage id='channel_notifications.onlyMentions'/>
|
||||
</label>
|
||||
<br />
|
||||
<br/>
|
||||
</div>
|
||||
</div>
|
||||
)];
|
||||
@@ -363,7 +363,7 @@ export default class ChannelNotificationsModal extends React.Component {
|
||||
/>
|
||||
);
|
||||
} else {
|
||||
describe = (<FormattedMessage id='channel_notifications.onlyMentions' />);
|
||||
describe = (<FormattedMessage id='channel_notifications.onlyMentions'/>);
|
||||
}
|
||||
|
||||
const handleUpdateSection = function handleUpdateSection(e) {
|
||||
|
||||
@@ -7,9 +7,6 @@ import SidebarRight from '../components/sidebar_right.jsx';
|
||||
import SidebarRightMenu from '../components/sidebar_right_menu.jsx';
|
||||
|
||||
export default class ChannelView extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
}
|
||||
render() {
|
||||
return (
|
||||
<div className='container-fluid'>
|
||||
@@ -31,7 +28,7 @@ export default class ChannelView extends React.Component {
|
||||
>
|
||||
<Sidebar/>
|
||||
</div>
|
||||
<CenterPanel />
|
||||
<CenterPanel/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -477,7 +477,7 @@ class CreatePost extends React.Component {
|
||||
className='send-button theme'
|
||||
onClick={this.handleSubmit}
|
||||
>
|
||||
<i className='fa fa-paper-plane' />
|
||||
<i className='fa fa-paper-plane'/>
|
||||
</a>
|
||||
{tutorialTip}
|
||||
</div>
|
||||
|
||||
@@ -178,8 +178,8 @@ export default class DeletePostModal extends React.Component {
|
||||
term: (postTerm)
|
||||
}}
|
||||
/>
|
||||
<br />
|
||||
<br />
|
||||
<br/>
|
||||
<br/>
|
||||
{commentWarning}
|
||||
{error}
|
||||
</Modal.Body>
|
||||
|
||||
@@ -135,9 +135,9 @@ class EditPostModal extends React.Component {
|
||||
PreferenceStore.removeChangeListener(this.onPreferenceChange);
|
||||
}
|
||||
render() {
|
||||
var error = (<div className='form-group'><br /></div>);
|
||||
var error = (<div className='form-group'><br/></div>);
|
||||
if (this.state.error) {
|
||||
error = (<div className='form-group has-error'><br /><label className='control-label'>{this.state.error}</label></div>);
|
||||
error = (<div className='form-group has-error'><br/><label className='control-label'>{this.state.error}</label></div>);
|
||||
}
|
||||
|
||||
return (
|
||||
|
||||
@@ -70,7 +70,7 @@ export default class EmailVerify extends React.Component {
|
||||
);
|
||||
if (this.props.resendSuccess) {
|
||||
resendConfirm = (
|
||||
<div><br /><p className='alert alert-success'><i className='fa fa-check'></i>
|
||||
<div><br/><p className='alert alert-success'><i className='fa fa-check'></i>
|
||||
<FormattedMessage
|
||||
id='email_verify.sent'
|
||||
defaultMessage=' Verification email sent.'
|
||||
|
||||
@@ -245,7 +245,9 @@ class FileAttachment extends React.Component {
|
||||
this.setState({fileSize: parseInt(data.size, 10), mime: data.mime});
|
||||
}
|
||||
}.bind(this),
|
||||
function error() {}
|
||||
function error() {
|
||||
// Do nothing
|
||||
}
|
||||
);
|
||||
} else {
|
||||
fileSizeString = utils.fileSizeToString(this.state.fileSize);
|
||||
@@ -312,4 +314,4 @@ FileAttachment.propTypes = {
|
||||
handleImageClick: React.PropTypes.func
|
||||
};
|
||||
|
||||
export default injectIntl(FileAttachment);
|
||||
export default injectIntl(FileAttachment);
|
||||
|
||||
@@ -37,7 +37,7 @@ export default function FileInfoPreview({filename, fileUrl, fileInfo, formatMess
|
||||
href={fileUrl}
|
||||
target='_blank'
|
||||
>
|
||||
<span className='file-details__preview-helper' />
|
||||
<span className='file-details__preview-helper'/>
|
||||
<img src={Utils.getPreviewImagePath(filename)}/>
|
||||
</a>
|
||||
<div className='file-details'>
|
||||
@@ -47,3 +47,10 @@ export default function FileInfoPreview({filename, fileUrl, fileInfo, formatMess
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
FileInfoPreview.propTypes = {
|
||||
filename: React.PropTypes.string.isRequired,
|
||||
fileUrl: React.PropTypes.string.isRequired,
|
||||
fileInfo: React.PropTypes.object.isRequired,
|
||||
formatMessage: React.PropTypes.func.isRequired
|
||||
};
|
||||
|
||||
@@ -305,7 +305,7 @@ class FileUpload extends React.Component {
|
||||
className='btn btn-file'
|
||||
>
|
||||
<span>
|
||||
<i className='glyphicon glyphicon-paperclip' />
|
||||
<i className='glyphicon glyphicon-paperclip'/>
|
||||
</span>
|
||||
<input
|
||||
ref='fileInput'
|
||||
|
||||
@@ -48,8 +48,8 @@ export default class GetLinkModal extends React.Component {
|
||||
helpText = (
|
||||
<p>
|
||||
{this.props.helpText}
|
||||
<br />
|
||||
<br />
|
||||
<br/>
|
||||
<br/>
|
||||
</p>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -376,7 +376,7 @@ class InviteMemberModal extends React.Component {
|
||||
);
|
||||
if (this.state.isSendingEmails) {
|
||||
sendButtonLabel = (
|
||||
<span><i className='fa fa-spinner fa-spin' />
|
||||
<span><i className='fa fa-spinner fa-spin'/>
|
||||
<FormattedMessage
|
||||
id='invite_member.sending'
|
||||
defaultMessage=' Sending'
|
||||
|
||||
@@ -28,7 +28,7 @@ export default class Login extends React.Component {
|
||||
key='gitlab'
|
||||
href={'/' + teamName + '/login/gitlab'}
|
||||
>
|
||||
<span className='icon' />
|
||||
<span className='icon'/>
|
||||
<span>
|
||||
<FormattedMessage
|
||||
id='login.gitlab'
|
||||
@@ -46,7 +46,7 @@ export default class Login extends React.Component {
|
||||
key='google'
|
||||
href={'/' + teamName + '/login/google'}
|
||||
>
|
||||
<span className='icon' />
|
||||
<span className='icon'/>
|
||||
<span>
|
||||
<FormattedMessage
|
||||
id='login.google'
|
||||
@@ -80,7 +80,7 @@ export default class Login extends React.Component {
|
||||
if (msg != null) {
|
||||
extraBox = (
|
||||
<div className='alert alert-success'>
|
||||
<i className='fa fa-check' />
|
||||
<i className='fa fa-check'/>
|
||||
{msg}
|
||||
</div>
|
||||
);
|
||||
|
||||
@@ -4,10 +4,6 @@
|
||||
import MemberListItem from './member_list_item.jsx';
|
||||
|
||||
export default class MemberList extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
}
|
||||
|
||||
render() {
|
||||
var members = [];
|
||||
|
||||
|
||||
@@ -112,7 +112,7 @@ export default class MemberListItem extends React.Component {
|
||||
</div>
|
||||
);
|
||||
} else {
|
||||
invite = (<div className='member-role text-capitalize'><span className='fa fa-pencil hidden'></span>{member.roles || <FormattedMessage id='member_item.member' />}</div>);
|
||||
invite = (<div className='member-role text-capitalize'><span className='fa fa-pencil hidden'></span>{member.roles || <FormattedMessage id='member_item.member'/>}</div>);
|
||||
}
|
||||
|
||||
return (
|
||||
|
||||
@@ -82,7 +82,7 @@ export default class MoreChannels extends React.Component {
|
||||
if (this.state.channels != null) {
|
||||
var channels = this.state.channels;
|
||||
if (channels.loading) {
|
||||
moreChannels = <LoadingScreen />;
|
||||
moreChannels = <LoadingScreen/>;
|
||||
} else if (channels.length) {
|
||||
moreChannels = (
|
||||
<table className='more-table table'>
|
||||
|
||||
@@ -380,7 +380,7 @@ export default class Navbar extends React.Component {
|
||||
<span className='icon-bar'></span>
|
||||
<span className='icon-bar'></span>
|
||||
<span className='icon-bar'></span>
|
||||
<NotifyCounts />
|
||||
<NotifyCounts/>
|
||||
</button>
|
||||
);
|
||||
|
||||
@@ -393,7 +393,7 @@ export default class Navbar extends React.Component {
|
||||
data-target='#sidebar-nav'
|
||||
onClick={this.toggleRightSidebar}
|
||||
>
|
||||
<span dangerouslySetInnerHTML={{__html: Constants.MENU_ICON}} />
|
||||
<span dangerouslySetInnerHTML={{__html: Constants.MENU_ICON}}/>
|
||||
</button>
|
||||
);
|
||||
}
|
||||
@@ -502,7 +502,7 @@ export default class Navbar extends React.Component {
|
||||
className='navbar-toggle pull-right'
|
||||
onClick={this.showSearch}
|
||||
>
|
||||
<span className='glyphicon glyphicon-search icon--white' />
|
||||
<span className='glyphicon glyphicon-search icon--white'/>
|
||||
</button>
|
||||
);
|
||||
|
||||
|
||||
@@ -4,10 +4,6 @@
|
||||
import PostAttachment from './post_attachment.jsx';
|
||||
|
||||
export default class PostAttachmentList extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
}
|
||||
|
||||
render() {
|
||||
let content = [];
|
||||
this.props.attachments.forEach((attachment, i) => {
|
||||
|
||||
@@ -46,6 +46,7 @@ export default class PostAttachmentOEmbed extends React.Component {
|
||||
}
|
||||
});
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
render() {
|
||||
|
||||
@@ -52,7 +52,7 @@ export default class PostBodyAdditionalContent extends React.Component {
|
||||
render() {
|
||||
let content = [];
|
||||
|
||||
if (Boolean(this.props.post.type)) {
|
||||
if (this.props.post.type) {
|
||||
const component = this.getComponent();
|
||||
|
||||
if (component) {
|
||||
|
||||
@@ -15,7 +15,7 @@ export default class PostHeader extends React.Component {
|
||||
render() {
|
||||
var post = this.props.post;
|
||||
|
||||
let userProfile = <UserProfile userId={post.user_id} />;
|
||||
let userProfile = <UserProfile userId={post.user_id}/>;
|
||||
let botIndicator;
|
||||
|
||||
if (post.props && post.props.from_webhook) {
|
||||
|
||||
@@ -252,7 +252,7 @@ export default class PostsView extends React.Component {
|
||||
key={currentPostDay.toDateString()}
|
||||
className='date-separator'
|
||||
>
|
||||
<hr className='separator__hr' />
|
||||
<hr className='separator__hr'/>
|
||||
<div className='separator__text'>
|
||||
<FormattedDate
|
||||
value={currentPostDay}
|
||||
@@ -455,7 +455,7 @@ export default class PostsView extends React.Component {
|
||||
href='#'
|
||||
onClick={this.loadMorePostsBottom}
|
||||
>
|
||||
<FormattedMessage id='posts_view.loadMore' />
|
||||
<FormattedMessage id='posts_view.loadMore'/>
|
||||
</a>
|
||||
);
|
||||
} else {
|
||||
@@ -528,11 +528,11 @@ PostsView.propTypes = {
|
||||
function FloatingTimestamp({isScrolling, post}) {
|
||||
// only show on mobile
|
||||
if ($(window).width() > 768) {
|
||||
return <noscript />;
|
||||
return <noscript/>;
|
||||
}
|
||||
|
||||
if (!post) {
|
||||
return <noscript />;
|
||||
return <noscript/>;
|
||||
}
|
||||
|
||||
const dateString = (
|
||||
@@ -557,10 +557,15 @@ function FloatingTimestamp({isScrolling, post}) {
|
||||
);
|
||||
}
|
||||
|
||||
FloatingTimestamp.propTypes = {
|
||||
isScrolling: React.PropTypes.bool.isRequired,
|
||||
post: React.PropTypes.object
|
||||
};
|
||||
|
||||
function ScrollToBottomArrows({isScrolling, atBottom, onClick}) {
|
||||
// only show on mobile
|
||||
if ($(window).width() > 768) {
|
||||
return <noscript />;
|
||||
return <noscript/>;
|
||||
}
|
||||
|
||||
let className = 'post-list__arrows';
|
||||
@@ -573,7 +578,13 @@ function ScrollToBottomArrows({isScrolling, atBottom, onClick}) {
|
||||
className={className}
|
||||
onClick={onClick}
|
||||
>
|
||||
<span dangerouslySetInnerHTML={{__html: Constants.SCROLL_BOTTOM_ICON}} />
|
||||
<span dangerouslySetInnerHTML={{__html: Constants.SCROLL_BOTTOM_ICON}}/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
ScrollToBottomArrows.propTypes = {
|
||||
isScrolling: React.PropTypes.bool.isRequired,
|
||||
atBottom: React.PropTypes.bool.isRequired,
|
||||
onClick: React.PropTypes.func.isRequired
|
||||
};
|
||||
|
||||
@@ -173,7 +173,9 @@ export default class PostsViewContainer extends React.Component {
|
||||
scrollPostId={this.state.scrollPost}
|
||||
postViewScrolled={this.handlePostsViewScroll}
|
||||
loadMorePostsTopClicked={this.loadMorePostsTop}
|
||||
loadMorePostsBottomClicked={() => {}}
|
||||
loadMorePostsBottomClicked={() => {
|
||||
// Do Nothing
|
||||
}}
|
||||
showMoreMessagesTop={!this.state.atTop[this.state.currentChannelIndex]}
|
||||
showMoreMessagesBottom={false}
|
||||
introText={channel ? createChannelIntroMessage(channel) : null}
|
||||
|
||||
@@ -246,7 +246,7 @@ class RhsComment extends React.Component {
|
||||
<div>
|
||||
<ul className='post__header'>
|
||||
<li className='col__name'>
|
||||
<strong><UserProfile userId={post.user_id} /></strong>
|
||||
<strong><UserProfile userId={post.user_id}/></strong>
|
||||
</li>
|
||||
<li className='col'>
|
||||
<time className='post__time'>
|
||||
|
||||
@@ -185,7 +185,7 @@ export default class RhsRootPost extends React.Component {
|
||||
);
|
||||
}
|
||||
|
||||
let userProfile = <UserProfile userId={post.user_id} />;
|
||||
let userProfile = <UserProfile userId={post.user_id}/>;
|
||||
let botIndicator;
|
||||
|
||||
if (post.props && post.props.from_webhook) {
|
||||
|
||||
@@ -196,12 +196,12 @@ export default class RhsThread extends React.Component {
|
||||
var currentId = UserStore.getCurrentId();
|
||||
var searchForm;
|
||||
if (currentId != null) {
|
||||
searchForm = <SearchBox />;
|
||||
searchForm = <SearchBox/>;
|
||||
}
|
||||
|
||||
return (
|
||||
<div className='post-right__container'>
|
||||
<FileUploadOverlay overlayType='right' />
|
||||
<FileUploadOverlay overlayType='right'/>
|
||||
<div className='search-bar__container sidebar--right__search-header'>{searchForm}</div>
|
||||
<div className='sidebar-right__body'>
|
||||
<RhsHeaderPost
|
||||
|
||||
@@ -169,7 +169,7 @@ class SearchBar extends React.Component {
|
||||
style={{overflow: 'visible'}}
|
||||
autoComplete='off'
|
||||
>
|
||||
<span className='glyphicon glyphicon-search sidebar__search-icon' />
|
||||
<span className='glyphicon glyphicon-search sidebar__search-icon'/>
|
||||
<SuggestionBox
|
||||
ref='search'
|
||||
className='form-control search-bar'
|
||||
|
||||
@@ -97,7 +97,7 @@ export default class SearchResults extends React.Component {
|
||||
var currentId = UserStore.getCurrentId();
|
||||
var searchForm = null;
|
||||
if (currentId) {
|
||||
searchForm = <SearchBox />;
|
||||
searchForm = <SearchBox/>;
|
||||
}
|
||||
var noResults = (!results || !results.order || !results.order.length);
|
||||
var searchTerm = SearchStore.getSearchTerm();
|
||||
@@ -151,7 +151,7 @@ export default class SearchResults extends React.Component {
|
||||
<div className='sidebar--right__content'>
|
||||
<div className='search-bar__container sidebar--right__search-header'>{searchForm}</div>
|
||||
<div className='sidebar-right__body'>
|
||||
<SearchResultsHeader isMentionSearch={this.props.isMentionSearch} />
|
||||
<SearchResultsHeader isMentionSearch={this.props.isMentionSearch}/>
|
||||
<div
|
||||
id='search-items-container'
|
||||
className='search-items-container'
|
||||
|
||||
@@ -60,7 +60,7 @@ export default class SearchResultsItem extends React.Component {
|
||||
return (
|
||||
<div className='search-item__container'>
|
||||
<div className='date-separator'>
|
||||
<hr className='separator__hr' />
|
||||
<hr className='separator__hr'/>
|
||||
<div className='separator__text'>
|
||||
<FormattedDate
|
||||
value={this.props.post.create_at}
|
||||
@@ -84,7 +84,7 @@ export default class SearchResultsItem extends React.Component {
|
||||
</div>
|
||||
<div>
|
||||
<ul className='post__header'>
|
||||
<li className='col__name'><strong><UserProfile userId={this.props.post.user_id} /></strong></li>
|
||||
<li className='col__name'><strong><UserProfile userId={this.props.post.user_id}/></strong></li>
|
||||
<li className='col'>
|
||||
<time className='search-item-time'>
|
||||
<FormattedDate
|
||||
|
||||
@@ -61,7 +61,7 @@ export default class SettingItemMax extends React.Component {
|
||||
{extraInfo}
|
||||
</li>
|
||||
<li className='setting-list-item'>
|
||||
<hr />
|
||||
<hr/>
|
||||
{serverError}
|
||||
{clientError}
|
||||
{submit}
|
||||
|
||||
@@ -40,7 +40,7 @@ export default class SettingsSidebar extends React.Component {
|
||||
href='#'
|
||||
onClick={this.handleClick.bind(null, tab)}
|
||||
>
|
||||
<i className={tab.icon} />
|
||||
<i className={tab.icon}/>
|
||||
{tab.uiName}
|
||||
</a>
|
||||
</li>
|
||||
|
||||
@@ -87,6 +87,7 @@ export default class SidebarRight extends React.Component {
|
||||
$('.sidebar__overlay').remove();
|
||||
});
|
||||
}, 500);*/
|
||||
return null;
|
||||
}
|
||||
componentDidUpdate() {
|
||||
this.doStrangeThings();
|
||||
@@ -115,7 +116,7 @@ export default class SidebarRight extends React.Component {
|
||||
var content = '';
|
||||
|
||||
if (this.state.search_visible) {
|
||||
content = <SearchResults isMentionSearch={this.state.is_mention_search} />;
|
||||
content = <SearchResults isMentionSearch={this.state.is_mention_search}/>;
|
||||
} else if (this.state.post_right_visible) {
|
||||
content = (
|
||||
<RhsThread
|
||||
|
||||
@@ -130,21 +130,21 @@ export default class TeamSignUp extends React.Component {
|
||||
return (
|
||||
<div>
|
||||
{teamListing}
|
||||
<EmailSignUpPage />
|
||||
<EmailSignUpPage/>
|
||||
</div>
|
||||
);
|
||||
} else if (this.state.page === 'gitlab') {
|
||||
return (
|
||||
<div>
|
||||
{teamListing}
|
||||
<SSOSignupPage service={Constants.GITLAB_SERVICE} />
|
||||
<SSOSignupPage service={Constants.GITLAB_SERVICE}/>
|
||||
</div>
|
||||
);
|
||||
} else if (this.state.page === 'google') {
|
||||
return (
|
||||
<div>
|
||||
{teamListing}
|
||||
<SSOSignupPage service={Constants.GOOGLE_SERVICE} />
|
||||
<SSOSignupPage service={Constants.GOOGLE_SERVICE}/>
|
||||
</div>
|
||||
);
|
||||
} else if (this.state.page === 'none') {
|
||||
@@ -157,6 +157,8 @@ export default class TeamSignUp extends React.Component {
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -4,10 +4,6 @@
|
||||
import {FormattedMessage, FormattedHTMLMessage} from 'mm-intl';
|
||||
|
||||
export default class SignupTeamConfirm extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
}
|
||||
|
||||
render() {
|
||||
return (
|
||||
<div className='signup-team__container'>
|
||||
|
||||
@@ -254,7 +254,7 @@ class SignupUserComplete extends React.Component {
|
||||
key='gitlab'
|
||||
href={'/' + this.props.teamName + '/signup/gitlab' + window.location.search}
|
||||
>
|
||||
<span className='icon' />
|
||||
<span className='icon'/>
|
||||
<span>
|
||||
<FormattedMessage
|
||||
id='signup_user_completed.gitlab'
|
||||
@@ -272,7 +272,7 @@ class SignupUserComplete extends React.Component {
|
||||
key='google'
|
||||
href={'/' + this.props.teamName + '/signup/google' + window.location.search}
|
||||
>
|
||||
<span className='icon' />
|
||||
<span className='icon'/>
|
||||
<span>
|
||||
<FormattedMessage
|
||||
id='signup_user_completed.google'
|
||||
|
||||
@@ -24,7 +24,7 @@ class AtMentionSuggestion extends React.Component {
|
||||
defaultMessage='Notifies everyone in the team'
|
||||
/>
|
||||
);
|
||||
icon = <i className='mention-img fa fa-users fa-2x' />;
|
||||
icon = <i className='mention-img fa fa-users fa-2x'/>;
|
||||
} else if (item.username === 'channel') {
|
||||
username = 'channel';
|
||||
description = (
|
||||
@@ -33,7 +33,7 @@ class AtMentionSuggestion extends React.Component {
|
||||
defaultMessage='Notifies everyone in the channel'
|
||||
/>
|
||||
);
|
||||
icon = <i className='mention-img fa fa-users fa-2x' />;
|
||||
icon = <i className='mention-img fa fa-users fa-2x'/>;
|
||||
} else {
|
||||
username = item.username;
|
||||
description = Utils.getFullName(item);
|
||||
|
||||
@@ -140,7 +140,7 @@ export default class SuggestionBox extends React.Component {
|
||||
return (
|
||||
<div>
|
||||
{textbox}
|
||||
<SuggestionListComponent suggestionId={this.suggestionId} />
|
||||
<SuggestionListComponent suggestionId={this.suggestionId}/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -36,7 +36,7 @@ export default class TeamExportTab extends React.Component {
|
||||
case 'in-progress':
|
||||
messageSection = (
|
||||
<p className='confirm-import alert alert-warning'>
|
||||
<i className='fa fa-spinner fa-pulse' />
|
||||
<i className='fa fa-spinner fa-pulse'/>
|
||||
<FormattedMessage
|
||||
id='team_export_tab.exporting'
|
||||
defaultMessage=' Exporting...'
|
||||
@@ -47,7 +47,7 @@ export default class TeamExportTab extends React.Component {
|
||||
case 'ready':
|
||||
messageSection = (
|
||||
<p className='confirm-import alert alert-success'>
|
||||
<i className='fa fa-check' />
|
||||
<i className='fa fa-check'/>
|
||||
<FormattedMessage
|
||||
id='team_export_tab.ready'
|
||||
defaultMessage=' Ready for '
|
||||
@@ -67,7 +67,7 @@ export default class TeamExportTab extends React.Component {
|
||||
case 'failure':
|
||||
messageSection = (
|
||||
<p className='confirm-import alert alert-warning'>
|
||||
<i className='fa fa-warning' />
|
||||
<i className='fa fa-warning'/>
|
||||
<FormattedMessage
|
||||
id='team_export_tab.unable'
|
||||
defaultMessage=' Unable to export: {error}'
|
||||
|
||||
@@ -79,7 +79,7 @@ class TeamImportTab extends React.Component {
|
||||
case 'done':
|
||||
messageSection = (
|
||||
<p className='confirm-import alert alert-success'>
|
||||
<i className='fa fa-check' />
|
||||
<i className='fa fa-check'/>
|
||||
<FormattedMessage
|
||||
id='team_import_tab.successful'
|
||||
defaultMessage=' Import successful: '
|
||||
@@ -99,7 +99,7 @@ class TeamImportTab extends React.Component {
|
||||
case 'fail':
|
||||
messageSection = (
|
||||
<p className='confirm-import alert alert-warning'>
|
||||
<i className='fa fa-warning' />
|
||||
<i className='fa fa-warning'/>
|
||||
<FormattedMessage
|
||||
id='team_import_tab.failure'
|
||||
defaultMessage=' Import failure: '
|
||||
|
||||
@@ -56,7 +56,7 @@ export default class TeamMembersModal extends React.Component {
|
||||
</Modal.Header>
|
||||
<Modal.Body ref='modalBody'>
|
||||
<div className='team-member-list'>
|
||||
<MemberListTeam />
|
||||
<MemberListTeam/>
|
||||
</div>
|
||||
</Modal.Body>
|
||||
<Modal.Footer>
|
||||
|
||||
@@ -55,7 +55,7 @@ export default class TeamSettings extends React.Component {
|
||||
case 'export':
|
||||
result = (
|
||||
<div>
|
||||
<ExportTab />
|
||||
<ExportTab/>
|
||||
</div>
|
||||
);
|
||||
break;
|
||||
|
||||
@@ -23,7 +23,7 @@ export default class ChooseAuthPage extends React.Component {
|
||||
}.bind(this)
|
||||
}
|
||||
>
|
||||
<span className='icon' />
|
||||
<span className='icon'/>
|
||||
<span>
|
||||
<FormattedMessage
|
||||
id='choose_auth_page.gitlabCreate'
|
||||
@@ -47,7 +47,7 @@ export default class ChooseAuthPage extends React.Component {
|
||||
}
|
||||
}
|
||||
>
|
||||
<span className='icon' />
|
||||
<span className='icon'/>
|
||||
<span>
|
||||
<FormattedMessage
|
||||
id='choose_auth_page.googleCreate'
|
||||
@@ -71,7 +71,7 @@ export default class ChooseAuthPage extends React.Component {
|
||||
}.bind(this)
|
||||
}
|
||||
>
|
||||
<span className='fa fa-envelope' />
|
||||
<span className='fa fa-envelope'/>
|
||||
<span>
|
||||
<FormattedMessage
|
||||
id='choose_auth_page.emailCreate'
|
||||
|
||||
@@ -183,7 +183,7 @@ export default class TeamSignupSendInvitesPage extends React.Component {
|
||||
<FormattedMessage
|
||||
id='team_signup_send_invites.next'
|
||||
defaultMessage='Next'
|
||||
/><i className='glyphicon glyphicon-chevron-right' />
|
||||
/><i className='glyphicon glyphicon-chevron-right'/>
|
||||
</button>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
@@ -150,7 +150,7 @@ class TeamSignupWelcomePage extends React.Component {
|
||||
id='team_signup_welcome.confirm'
|
||||
defaultMessage='Please confirm your email address:'
|
||||
/>
|
||||
<br />
|
||||
<br/>
|
||||
<div className='inner__content'>
|
||||
<div className='block--gray'>{this.props.state.team.email}</div>
|
||||
</div>
|
||||
@@ -176,7 +176,7 @@ class TeamSignupWelcomePage extends React.Component {
|
||||
</button>
|
||||
{storageError}
|
||||
</div>
|
||||
<hr />
|
||||
<hr/>
|
||||
<div className={emailDivContainerClass}>
|
||||
<div className={emailDivClass}>
|
||||
<div className='row'>
|
||||
|
||||
@@ -10,9 +10,6 @@ var Tooltip = ReactBootstrap.Tooltip;
|
||||
var OverlayTrigger = ReactBootstrap.OverlayTrigger;
|
||||
|
||||
export default class TimeSince extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
}
|
||||
componentDidMount() {
|
||||
this.intervalId = setInterval(() => {
|
||||
this.forceUpdate();
|
||||
@@ -51,7 +48,7 @@ export default class TimeSince extends React.Component {
|
||||
overlay={tooltip}
|
||||
>
|
||||
<time className='post__time'>
|
||||
<FormattedRelative value={this.props.eventTime} />
|
||||
<FormattedRelative value={this.props.eventTime}/>
|
||||
</time>
|
||||
</OverlayTrigger>
|
||||
);
|
||||
|
||||
@@ -22,7 +22,7 @@ export default class ModalToggleButton extends React.Component {
|
||||
}
|
||||
|
||||
render() {
|
||||
const {children, dialogType, dialogProps, onClick, ...props} = this.props; // eslint-disable-line no-redeclare
|
||||
const {children, dialogType, dialogProps, onClick, ...props} = this.props; // eslint-disable-line no-use-before-define
|
||||
|
||||
// allow callers to provide an onClick which will be called before the modal is shown
|
||||
let clickHandler = this.show;
|
||||
|
||||
@@ -58,6 +58,7 @@ export default class TutorialIntroScreens extends React.Component {
|
||||
case 2:
|
||||
return this.createScreenThree();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
createScreenOne() {
|
||||
const circles = this.createCircles();
|
||||
|
||||
@@ -4,9 +4,6 @@
|
||||
// Indicator for the left sidebar which indicate if there's unread posts in a channel that is not shown
|
||||
// because it is either above or below the screen
|
||||
export default class UnreadChannelIndicator extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
}
|
||||
render() {
|
||||
let displayValue = 'none';
|
||||
if (this.props.show) {
|
||||
|
||||
@@ -57,7 +57,7 @@ class UserSettingsIntegrationsTab extends React.Component {
|
||||
if (global.window.mm_config.EnableIncomingWebhooks === 'true') {
|
||||
if (this.props.activeSection === 'incoming-hooks') {
|
||||
inputs.push(
|
||||
<ManageIncomingHooks key='incoming-hook-ui' />
|
||||
<ManageIncomingHooks key='incoming-hook-ui'/>
|
||||
);
|
||||
|
||||
incomingHooksSection = (
|
||||
@@ -88,7 +88,7 @@ class UserSettingsIntegrationsTab extends React.Component {
|
||||
if (global.window.mm_config.EnableOutgoingWebhooks === 'true') {
|
||||
if (this.props.activeSection === 'outgoing-hooks') {
|
||||
inputs.push(
|
||||
<ManageOutgoingHooks key='outgoing-hook-ui' />
|
||||
<ManageOutgoingHooks key='outgoing-hook-ui'/>
|
||||
);
|
||||
|
||||
outgoingHooksSection = (
|
||||
@@ -119,7 +119,7 @@ class UserSettingsIntegrationsTab extends React.Component {
|
||||
if (global.window.mm_config.EnableCommands === 'true') {
|
||||
if (this.props.activeSection === 'command-hooks') {
|
||||
inputs.push(
|
||||
<ManageCommandHooks key='command-hook-ui' />
|
||||
<ManageCommandHooks key='command-hook-ui'/>
|
||||
);
|
||||
|
||||
commandHooksSection = (
|
||||
|
||||
@@ -111,12 +111,13 @@ class UserSettingsModal extends React.Component {
|
||||
this.afterConfirm = () => this.handleHide();
|
||||
this.showConfirmModal();
|
||||
|
||||
return false;
|
||||
return;
|
||||
}
|
||||
|
||||
this.resetTheme();
|
||||
this.deactivateTab();
|
||||
this.props.onModalDismissed();
|
||||
return;
|
||||
}
|
||||
|
||||
// called after the dialog is fully hidden and faded out
|
||||
@@ -295,7 +296,12 @@ class UserSettingsModal extends React.Component {
|
||||
closeModal={this.closeModal}
|
||||
collapseModal={this.collapseModal}
|
||||
setEnforceFocus={(enforceFocus) => this.setState({enforceFocus})}
|
||||
setRequireConfirm={(requireConfirm) => this.requireConfirm = requireConfirm}
|
||||
setRequireConfirm={
|
||||
(requireConfirm) => {
|
||||
this.requireConfirm = requireConfirm;
|
||||
return;
|
||||
}
|
||||
}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -445,7 +445,7 @@ class NotificationsTab extends React.Component {
|
||||
title={formatMessage(holders.desktopSounds)}
|
||||
describe={describe}
|
||||
updateSection={handleUpdateSoundSection}
|
||||
disableOpen = {!this.state.soundNeeded}
|
||||
disableOpen={!this.state.soundNeeded}
|
||||
/>
|
||||
);
|
||||
}
|
||||
@@ -826,4 +826,4 @@ NotificationsTab.propTypes = {
|
||||
collapseModal: React.PropTypes.func.isRequired
|
||||
};
|
||||
|
||||
export default injectIntl(NotificationsTab);
|
||||
export default injectIntl(NotificationsTab);
|
||||
|
||||
@@ -203,7 +203,9 @@ class ViewImageModal extends React.Component {
|
||||
window.open(serverData.public_link);
|
||||
}
|
||||
},
|
||||
() => {}
|
||||
() => {
|
||||
//Do Nothing on error
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
@@ -383,6 +385,11 @@ function LoadingImagePreview({progress, loading}) {
|
||||
);
|
||||
}
|
||||
|
||||
LoadingImagePreview.propTypes = {
|
||||
progress: React.PropTypes.number,
|
||||
loading: React.PropTypes.string
|
||||
};
|
||||
|
||||
function ImagePreview({filename, fileUrl, fileInfo, maxHeight}) {
|
||||
let previewUrl;
|
||||
if (fileInfo.has_preview_image) {
|
||||
@@ -405,4 +412,11 @@ function ImagePreview({filename, fileUrl, fileInfo, maxHeight}) {
|
||||
);
|
||||
}
|
||||
|
||||
export default injectIntl(ViewImageModal);
|
||||
ImagePreview.propTypes = {
|
||||
filename: React.PropTypes.string.isRequired,
|
||||
fileUrl: React.PropTypes.string.isRequired,
|
||||
fileInfo: React.PropTypes.object.isRequired,
|
||||
maxHeight: React.PropTypes.number.isRequired
|
||||
};
|
||||
|
||||
export default injectIntl(ViewImageModal);
|
||||
|
||||
@@ -4,9 +4,6 @@
|
||||
import {FormattedMessage} from 'mm-intl';
|
||||
|
||||
export default class ViewImagePopoverBar extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
}
|
||||
render() {
|
||||
var publicLink = '';
|
||||
if (global.window.mm_config.EnablePublicLink === 'true') {
|
||||
|
||||
@@ -94,6 +94,7 @@ export default class YoutubeVideo extends React.Component {
|
||||
receivedYoutubeData: true,
|
||||
title: metadata.title
|
||||
});
|
||||
return null;
|
||||
}
|
||||
|
||||
play() {
|
||||
|
||||
@@ -3,10 +3,10 @@
|
||||
"version": "0.0.1",
|
||||
"private": true,
|
||||
"dependencies": {
|
||||
"autolinker": "0.22.0",
|
||||
"fastclick": "^1.0.6",
|
||||
"autolinker": "0.24.0",
|
||||
"fastclick": "1.0.6",
|
||||
"flux": "2.1.1",
|
||||
"highlight.js": "8.9.1",
|
||||
"highlight.js": "9.1.0",
|
||||
"keymirror": "0.1.1",
|
||||
"marked": "mattermost/marked#cb85e5cc81bc7937dbb73c3c53d9532b1b97e3ca",
|
||||
"mm-intl": "mattermost/mm-intl#805442fd474fa40cd586ddeda404dbbe8e60626d",
|
||||
@@ -14,18 +14,18 @@
|
||||
"twemoji": "1.4.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"babel-eslint": "4.1.7",
|
||||
"babel-plugin-transform-runtime": "6.1.4",
|
||||
"babel-preset-es2015": "6.1.18",
|
||||
"babel-preset-react": "6.1.18",
|
||||
"babel-preset-stage-0": "6.1.18",
|
||||
"babel-eslint": "5.0.0",
|
||||
"babel-plugin-transform-runtime": "6.5.2",
|
||||
"babel-preset-es2015": "6.5.0",
|
||||
"babel-preset-react": "6.5.0",
|
||||
"babel-preset-stage-0": "6.5.0",
|
||||
"babelify": "7.2.0",
|
||||
"browserify": "12.0.1",
|
||||
"eslint": "1.9.0",
|
||||
"eslint-plugin-react": "3.9.0",
|
||||
"browserify": "13.0.0",
|
||||
"eslint": "2.2.0",
|
||||
"eslint-plugin-react": "4.0.0",
|
||||
"exorcist": "0.4.0",
|
||||
"uglify-js": "2.6.1",
|
||||
"watchify": "3.6.1"
|
||||
"watchify": "3.7.0"
|
||||
},
|
||||
"scripts": {
|
||||
"check": "",
|
||||
|
||||
@@ -56,7 +56,7 @@ class Root extends React.Component {
|
||||
tab={this.props.map.ActiveTab}
|
||||
teamId={this.props.map.TeamId}
|
||||
/>
|
||||
<SelectTeamModal />
|
||||
<SelectTeamModal/>
|
||||
</div>
|
||||
</IntlProvider>
|
||||
);
|
||||
@@ -65,7 +65,7 @@ class Root extends React.Component {
|
||||
|
||||
global.window.setup_admin_console_page = function setup(props) {
|
||||
ReactDOM.render(
|
||||
<Root map={props} />,
|
||||
<Root map={props}/>,
|
||||
document.getElementById('admin_controller')
|
||||
);
|
||||
};
|
||||
|
||||
@@ -29,6 +29,7 @@ class Root extends React.Component {
|
||||
translations: data,
|
||||
loaded: true
|
||||
});
|
||||
return;
|
||||
},
|
||||
() => {
|
||||
this.setState({
|
||||
@@ -64,7 +65,7 @@ class Root extends React.Component {
|
||||
|
||||
global.window.setup_authorize_page = function setup(props) {
|
||||
ReactDOM.render(
|
||||
<Root map={props} />,
|
||||
<Root map={props}/>,
|
||||
document.getElementById('authorize')
|
||||
);
|
||||
};
|
||||
|
||||
@@ -68,18 +68,17 @@ class Root extends React.Component {
|
||||
<ChannelLoader/>
|
||||
<ErrorBar/>
|
||||
<ChannelView/>
|
||||
|
||||
<GetPostLinkModal />
|
||||
<GetTeamInviteLinkModal />
|
||||
<InviteMemberModal />
|
||||
<ImportThemeModal />
|
||||
<TeamSettingsModal />
|
||||
<RenameChannelModal />
|
||||
<MoreChannelsModal />
|
||||
<EditPostModal />
|
||||
<DeletePostModal />
|
||||
<RemovedFromChannelModal />
|
||||
<RegisterAppModal />
|
||||
<GetPostLinkModal/>
|
||||
<GetTeamInviteLinkModal/>
|
||||
<InviteMemberModal/>
|
||||
<ImportThemeModal/>
|
||||
<TeamSettingsModal/>
|
||||
<RenameChannelModal/>
|
||||
<MoreChannelsModal/>
|
||||
<EditPostModal/>
|
||||
<DeletePostModal/>
|
||||
<RemovedFromChannelModal/>
|
||||
<RegisterAppModal/>
|
||||
</div>
|
||||
</IntlProvider>
|
||||
);
|
||||
@@ -94,7 +93,7 @@ global.window.setup_channel_page = function setup(props, team, channel) {
|
||||
}
|
||||
|
||||
ReactDOM.render(
|
||||
<Root map={props} />,
|
||||
<Root map={props}/>,
|
||||
document.getElementById('channel_view')
|
||||
);
|
||||
};
|
||||
|
||||
@@ -62,7 +62,7 @@ class Root extends React.Component {
|
||||
|
||||
global.window.setup_claim_account_page = function setup(props) {
|
||||
ReactDOM.render(
|
||||
<Root map={props} />,
|
||||
<Root map={props}/>,
|
||||
document.getElementById('claim')
|
||||
);
|
||||
};
|
||||
@@ -48,7 +48,7 @@ class Root extends React.Component {
|
||||
locale={this.props.map.Locale}
|
||||
messages={this.state.translations}
|
||||
>
|
||||
<Docs site={this.props.map.Site} />
|
||||
<Docs site={this.props.map.Site}/>
|
||||
</IntlProvider>
|
||||
);
|
||||
}
|
||||
@@ -58,7 +58,7 @@ global.window.mm_user = global.window.mm_user || {};
|
||||
|
||||
global.window.setup_documentation_page = function setup(props) {
|
||||
ReactDOM.render(
|
||||
<Root map={props} />,
|
||||
<Root map={props}/>,
|
||||
document.getElementById('docs')
|
||||
);
|
||||
};
|
||||
|
||||
@@ -48,7 +48,7 @@ class Root extends React.Component {
|
||||
locale={this.props.map.Locale}
|
||||
messages={this.state.translations}
|
||||
>
|
||||
<FindTeam />
|
||||
<FindTeam/>
|
||||
</IntlProvider>
|
||||
);
|
||||
}
|
||||
@@ -56,7 +56,7 @@ class Root extends React.Component {
|
||||
|
||||
global.window.setup_find_team_page = function setup(props) {
|
||||
ReactDOM.render(
|
||||
<Root map={props} />,
|
||||
<Root map={props}/>,
|
||||
document.getElementById('find-team')
|
||||
);
|
||||
};
|
||||
@@ -60,7 +60,7 @@ class Root extends React.Component {
|
||||
|
||||
global.window.setup_login_page = function setup(props) {
|
||||
ReactDOM.render(
|
||||
<Root map={props} />,
|
||||
<Root map={props}/>,
|
||||
document.getElementById('login')
|
||||
);
|
||||
};
|
||||
@@ -62,7 +62,7 @@ class Root extends React.Component {
|
||||
|
||||
global.window.setup_password_reset_page = function setup(props) {
|
||||
ReactDOM.render(
|
||||
<Root map={props} />,
|
||||
<Root map={props}/>,
|
||||
document.getElementById('reset')
|
||||
);
|
||||
};
|
||||
|
||||
@@ -49,7 +49,7 @@ class Root extends React.Component {
|
||||
locale={this.props.map.Locale}
|
||||
messages={this.state.translations}
|
||||
>
|
||||
<SignupTeam teams={this.props.teams} />
|
||||
<SignupTeam teams={this.props.teams}/>
|
||||
</IntlProvider>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -60,7 +60,7 @@ class Root extends React.Component {
|
||||
|
||||
global.window.setup_signup_team_complete_page = function setup(props) {
|
||||
ReactDOM.render(
|
||||
<Root map={props} />,
|
||||
<Root map={props}/>,
|
||||
document.getElementById('signup-team-complete')
|
||||
);
|
||||
};
|
||||
@@ -58,7 +58,7 @@ class Root extends React.Component {
|
||||
|
||||
global.window.setup_signup_team_confirm_page = function setup(props) {
|
||||
ReactDOM.render(
|
||||
<Root map={props} />,
|
||||
<Root map={props}/>,
|
||||
document.getElementById('signup-team-confirm')
|
||||
);
|
||||
};
|
||||
@@ -63,7 +63,7 @@ class Root extends React.Component {
|
||||
|
||||
global.window.setup_signup_user_complete_page = function setup(props) {
|
||||
ReactDOM.render(
|
||||
<Root map={props} />,
|
||||
<Root map={props}/>,
|
||||
document.getElementById('signup-user-complete')
|
||||
);
|
||||
};
|
||||
@@ -61,7 +61,7 @@ class Root extends React.Component {
|
||||
|
||||
global.window.setupVerifyPage = function setup(props) {
|
||||
ReactDOM.render(
|
||||
<Root map={props} />,
|
||||
<Root map={props}/>,
|
||||
document.getElementById('verify')
|
||||
);
|
||||
};
|
||||
|
||||
@@ -28,7 +28,7 @@ class ModalStoreClass extends EventEmitter {
|
||||
|
||||
handleEventPayload(payload) {
|
||||
// toggle event handlers should accept a boolean show/hide value and can accept a map of arguments
|
||||
const {type, value, ...args} = payload.action; //eslint-disable-line no-redeclare
|
||||
const {type, value, ...args} = payload.action; //eslint-disable-line no-use-before-define
|
||||
|
||||
switch (type) {
|
||||
case ActionTypes.TOGGLE_IMPORT_THEME_MODAL:
|
||||
|
||||
@@ -210,7 +210,7 @@ class SuggestionStore extends EventEmitter {
|
||||
}
|
||||
|
||||
handleEventPayload(payload) {
|
||||
const {type, id, ...other} = payload.action; // eslint-disable-line no-redeclare
|
||||
const {type, id, ...other} = payload.action; // eslint-disable-line no-use-before-define
|
||||
|
||||
switch (type) {
|
||||
case ActionTypes.SUGGESTION_PRETEXT_CHANGED:
|
||||
|
||||
@@ -23,6 +23,7 @@ export function createChannelIntroMessage(channel) {
|
||||
} else if (channel.type === 'O' || channel.type === 'P') {
|
||||
return createStandardIntroMessage(channel);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
export function createDMIntroMessage(channel) {
|
||||
@@ -46,7 +47,7 @@ export function createDMIntroMessage(channel) {
|
||||
</div>
|
||||
<div className='channel-intro-profile'>
|
||||
<strong>
|
||||
<UserProfile userId={teammate.id} />
|
||||
<UserProfile userId={teammate.id}/>
|
||||
</strong>
|
||||
</div>
|
||||
<p className='channel-intro-text'>
|
||||
|
||||
@@ -1430,7 +1430,7 @@ export function listIncomingHooks(success, error) {
|
||||
|
||||
export function getAllPreferences(success, error) {
|
||||
$.ajax({
|
||||
url: `/api/v1/preferences/`,
|
||||
url: '/api/v1/preferences/',
|
||||
dataType: 'json',
|
||||
type: 'GET',
|
||||
success,
|
||||
|
||||
@@ -157,5 +157,5 @@ export function getImagePathForEmoticon(name) {
|
||||
if (name) {
|
||||
return `/static/images/emoji/${name}.png`;
|
||||
}
|
||||
return `/static/images/emoji`;
|
||||
return '/static/images/emoji';
|
||||
}
|
||||
|
||||
@@ -142,6 +142,7 @@ export function getCookie(name) {
|
||||
if (parts.length === 2) {
|
||||
return parts.pop().split(';').shift();
|
||||
}
|
||||
return '';
|
||||
}
|
||||
|
||||
var requestedNotificationPermission = false;
|
||||
@@ -188,7 +189,10 @@ export function ding() {
|
||||
var audio = new Audio('/static/images/bing.mp3');
|
||||
audio.play();
|
||||
canDing = false;
|
||||
setTimeout(() => canDing = true, 3000);
|
||||
setTimeout(() => {
|
||||
canDing = true;
|
||||
return;
|
||||
}, 3000);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Ссылка в новой задаче
Block a user