"use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports.default=void 0;var _reactNative=require("react-native");var _i18next=_interopRequireDefault(require("i18next"));var _reactI18next=require("react-i18next");var _reactAuthShared=require("@brightlayer-ui/react-auth-shared");var _NativeModules$Settin;var AppleLocaleSettings=(_NativeModules$Settin=_reactNative.NativeModules.SettingsManager)===null||_NativeModules$Settin===void 0?void 0:_NativeModules$Settin.settings;var AndroidLocaleSettings=_reactNative.NativeModules.I18nManager;var deviceLocale='en';if(AppleLocaleSettings&&_reactNative.Platform.OS==='ios'){deviceLocale=AppleLocaleSettings.AppleLocale||AppleLocaleSettings.AppleLanguages[0];}else if(AndroidLocaleSettings&&_reactNative.Platform.OS==='android'){deviceLocale=AndroidLocaleSettings.localeIdentifier;}void _i18next.default.use(_reactI18next.initReactI18next).init({ns:['app','blui'],defaultNS:'app',fallbackNS:'blui',resources:{en:{blui:_reactAuthShared.translations.english.translation,app:{}},fr:{blui:_reactAuthShared.translations.french.translation,app:{}},es:{blui:_reactAuthShared.translations.spanish.translation,app:{}},zh:{blui:_reactAuthShared.translations.chinese.translation,app:{}},pt:{blui:_reactAuthShared.translations.portuguese.translation,app:{}}},lng:deviceLocale.substr(0,2),fallbackLng:'en',interpolation:{escapeValue:false}});var _default=_i18next.default;exports.default=_default;
//# sourceMappingURL=i18n.js.map