feat: locales availability + IE display mode

This commit is contained in:
Nick
2019-07-12 23:56:44 -04:00
parent ca06a15bf3
commit b6f1e1805e
31 changed files with 1015 additions and 71 deletions

View File

@@ -17,6 +17,7 @@ module.exports = async () => {
query: `{
localization {
locales {
availability
code
name
nativeName
@@ -54,7 +55,9 @@ module.exports = async () => {
let lcObj = {}
_.forEach(strings, row => {
if (_.includes(row.key, '::')) { return }
if (_.isEmpty(row.value)) { row.value = row.key }
if (_.isEmpty(row.value)) {
row.value = row.key
}
_.set(lcObj, row.key.replace(':', '.'), row.value)
})
@@ -63,7 +66,8 @@ module.exports = async () => {
strings: lcObj,
isRTL: localeInfo.isRTL,
name: localeInfo.name,
nativeName: localeInfo.nativeName
nativeName: localeInfo.nativeName,
availability: localeInfo.availability
}).where('code', currentLocale)
WIKI.logger.info(`Pulled latest locale updates for ${localeInfo.name} from Graph endpoint: [ COMPLETED ]`)