jiti-meet/react/features/base/i18n/configLanguageDetector.js

30 lines
536 B
JavaScript
Raw Normal View History

2017-03-01 02:55:12 +00:00
/* @flow */
declare var config: Object;
/**
* Custom language detection, just returns the config property if any.
*/
export default {
/**
2017-03-01 02:55:12 +00:00
* Does not support caching.
*
* @returns {void}
*/
2017-03-01 02:55:12 +00:00
cacheUserLanguage: Function.prototype,
/**
2017-03-01 02:55:12 +00:00
* Looks the language up in the config.
*
* @returns {string} The default language if any.
*/
lookup() {
return config.defaultLanguage;
},
/**
2017-03-01 02:55:12 +00:00
* Name of the language detector.
*/
2017-03-01 02:55:12 +00:00
name: 'configLanguageDetector'
};