PLT-93 cleaing up client side configs
Этот коммит содержится в:
@@ -3,42 +3,13 @@
|
||||
|
||||
export var config = {
|
||||
|
||||
// Segment configs
|
||||
SegmentWriteKey: '',
|
||||
|
||||
// Feature switches
|
||||
AllowPublicLink: true,
|
||||
AllowInviteNames: true,
|
||||
RequireInviteNames: false,
|
||||
AllowSignupDomainsWizard: false,
|
||||
|
||||
// Google Developer Key (for Youtube API links)
|
||||
// Leave blank to disable
|
||||
GoogleDeveloperKey: '',
|
||||
|
||||
// Privacy switches
|
||||
ShowEmail: true,
|
||||
|
||||
// Links
|
||||
TermsLink: '/static/help/configure_links.html',
|
||||
PrivacyLink: '/static/help/configure_links.html',
|
||||
AboutLink: '/static/help/configure_links.html',
|
||||
HelpLink: '/static/help/configure_links.html',
|
||||
ReportProblemLink: '/static/help/configure_links.html',
|
||||
HomeLink: '',
|
||||
|
||||
// Toggle whether or not users are shown a message about agreeing to the Terms of Service during the signup process
|
||||
ShowTermsDuringSignup: false,
|
||||
|
||||
ThemeColors: ['#2389d7', '#008a17', '#dc4fad', '#ac193d', '#0072c6', '#d24726', '#ff8f32', '#82ba00', '#03b3b2', '#008299', '#4617b4', '#8c0095', '#004b8b', '#004b8b', '#570000', '#380000', '#585858', '#000000']
|
||||
};
|
||||
|
||||
// Flavor strings
|
||||
export var strings = {
|
||||
Team: 'team',
|
||||
TeamPlural: 'teams',
|
||||
Company: 'company',
|
||||
CompanyPlural: 'companies'
|
||||
ShowTermsDuringSignup: false
|
||||
};
|
||||
|
||||
global.window.config = config;
|
||||
|
||||
@@ -9,7 +9,6 @@ var ActionTypes = Constants.ActionTypes;
|
||||
var AsyncClient = require('./async_client.jsx');
|
||||
var client = require('./client.jsx');
|
||||
var Autolinker = require('autolinker');
|
||||
import {config} from '../utils/config.js';
|
||||
|
||||
export function isEmail(email) {
|
||||
var regex = /^([a-zA-Z0-9_.+-])+\@(([a-zA-Z0-9-])+\.)+([a-zA-Z0-9]{2,4})+$/;
|
||||
@@ -295,12 +294,12 @@ function getYoutubeEmbed(link) {
|
||||
$('.post-list-holder-by-time').scrollTop($('.post-list-holder-by-time')[0].scrollHeight);
|
||||
}
|
||||
|
||||
if (config.GoogleDeveloperKey) {
|
||||
if (global.window.config.GoogleDeveloperKey) {
|
||||
$.ajax({
|
||||
async: true,
|
||||
url: 'https://www.googleapis.com/youtube/v3/videos',
|
||||
type: 'GET',
|
||||
data: {part: 'snippet', id: youtubeId, key: config.GoogleDeveloperKey},
|
||||
data: {part: 'snippet', id: youtubeId, key: global.window.config.GoogleDeveloperKey},
|
||||
success: success
|
||||
});
|
||||
}
|
||||
|
||||
Ссылка в новой задаче
Block a user