Skip to content
Snippets Groups Projects
Commit 1294eb08 authored by Marcelo Schmidt's avatar Marcelo Schmidt
Browse files

Fixed translations for rocketchat-wordpress

parent f939dc42
No related branches found
No related tags found
No related merge requests found
......@@ -4,27 +4,27 @@ Package.describe({
summary: 'RocketChat settings for WordPress Oauth Flow'
});
// Loads all i18n.json files into tapi18nFiles
var _ = Npm.require('underscore');
var fs = Npm.require('fs');
tapi18nFiles = fs.readdirSync('packages/rocketchat-wordpress/i18n').forEach(function(filename) {
if (fs.statSync('packages/rocketchat-wordpress/i18n/' + filename).size > 16) {
return 'i18n/' + filename;
}
});
Package.onUse(function(api) {
api.versionsFrom('1.0');
api.use("tap:i18n@1.5.1");
api.use('coffeescript');
api.use('rocketchat:lib@0.0.1');
api.use('rocketchat:custom-oauth');
api.use('templating', 'client');
api.addFiles("package-tap.i18n");
api.addFiles("common.coffee");
api.addFiles('wordpress-login-button.css', 'client');
api.addFiles('startup.coffee', 'server');
api.addFiles(tapi18nFiles);
// TAPi18n
api.use('templating', 'client');
var _ = Npm.require('underscore');
var fs = Npm.require('fs');
tapi18nFiles = _.compact(_.map(fs.readdirSync('packages/rocketchat-wordpress/i18n'), function(filename) {
if (fs.statSync('packages/rocketchat-wordpress/i18n/' + filename).size > 16) {
return 'i18n/' + filename;
}
}));
api.use('tap:i18n@1.6.1', ['client', 'server']);
api.imply('tap:i18n');
api.addFiles(tapi18nFiles, ['client', 'server']);
});
Package.onTest(function(api) {
......
RocketChat.settings.add 'API_Wordpress_URL', '', { type: 'string', group: 'Accounts', public: true, i18nLabel: 'rocketchat-wordpress:API_Wordpress_URL', section: 'WordPress' }
RocketChat.settings.add 'Accounts_OAuth_Wordpress', false, { type: 'boolean', group: 'Accounts', section: 'WordPress', i18nLabel: 'rocketchat-wordpress:Accounts_OAuth_Wordpress' }
RocketChat.settings.add 'Accounts_OAuth_Wordpress_id', '', { type: 'string', group: 'Accounts', section: 'WordPress', i18nLabel: 'rocketchat-wordpress:Accounts_OAuth_Wordpress_id' }
RocketChat.settings.add 'Accounts_OAuth_Wordpress_secret', '', { type: 'string', group: 'Accounts', section: 'WordPress', i18nLabel: 'rocketchat-wordpress:Accounts_OAuth_Wordpress_secret' }
RocketChat.settings.add 'API_Wordpress_URL', '', { type: 'string', group: 'Accounts', public: true, section: 'WordPress' }
RocketChat.settings.add 'Accounts_OAuth_Wordpress', false, { type: 'boolean', group: 'Accounts', section: 'WordPress' }
RocketChat.settings.add 'Accounts_OAuth_Wordpress_id', '', { type: 'string', group: 'Accounts', section: 'WordPress' }
RocketChat.settings.add 'Accounts_OAuth_Wordpress_secret', '', { type: 'string', group: 'Accounts', section: 'WordPress' }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment