var numberFormatKeys=["compactDisplay","currency","currencyDisplay","currencySign","localeMatcher","notation","numberingSystem","signDisplay","style","unit","unitDisplay","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits"];function warn(t,e){"undefined"!=typeof console&&(console.warn("[vue-i18n] "+t),e&&console.warn(e.stack))}function error(t,e){"undefined"!=typeof console&&(console.error("[vue-i18n] "+t),e&&console.error(e.stack))}var isArray=Array.isArray;function isObject(t){return null!==t&&"object"==typeof t}function isBoolean(t){return"boolean"==typeof t}function isString(t){return"string"==typeof t}var toString=Object.prototype.toString,OBJECT_STRING="[object Object]";function isPlainObject(t){return toString.call(t)===OBJECT_STRING}function isNull(t){return null==t}function isFunction(t){return"function"==typeof t}function parseArgs(){for(var t=[],e=arguments.length;e--;)t[e]=arguments[e];var n=null,r=null;return 1===t.length?isObject(t[0])||isArray(t[0])?r=t[0]:"string"==typeof t[0]&&(n=t[0]):2===t.length&&("string"==typeof t[0]&&(n=t[0]),(isObject(t[1])||isArray(t[1]))&&(r=t[1])),{locale:n,params:r}}function looseClone(t){return JSON.parse(JSON.stringify(t))}function remove(t,e){if(t.length){var n=t.indexOf(e);if(n>-1)return t.splice(n,1)}}function includes(t,e){return!!~t.indexOf(e)}var hasOwnProperty=Object.prototype.hasOwnProperty;function hasOwn(t,e){return hasOwnProperty.call(t,e)}function merge(t){for(var e=arguments,n=Object(t),r=1;r/g,">").replace(/"/g,""").replace(/'/g,"'")}function escapeParams(t){return null!=t&&Object.keys(t).forEach(function(e){"string"==typeof t[e]&&(t[e]=escapeHtml(t[e]))}),t}function extend(t){t.prototype.hasOwnProperty("$i18n")||Object.defineProperty(t.prototype,"$i18n",{get:function(){return this._i18n}}),t.prototype.$t=function(t){for(var e=[],n=arguments.length-1;n-- >0;)e[n]=arguments[n+1];var r=this.$i18n;return r._t.apply(r,[t,r.locale,r._getMessages(),this].concat(e))},t.prototype.$tc=function(t,e){for(var n=[],r=arguments.length-2;r-- >0;)n[r]=arguments[r+2];var a=this.$i18n;return a._tc.apply(a,[t,a.locale,a._getMessages(),this,e].concat(n))},t.prototype.$te=function(t,e){var n=this.$i18n;return n._te(t,n.locale,n._getMessages(),e)},t.prototype.$d=function(t){for(var e,n=[],r=arguments.length-1;r-- >0;)n[r]=arguments[r+1];return(e=this.$i18n).d.apply(e,[t].concat(n))},t.prototype.$n=function(t){for(var e,n=[],r=arguments.length-1;r-- >0;)n[r]=arguments[r+1];return(e=this.$i18n).n.apply(e,[t].concat(n))}}var mixin={beforeCreate:function(){var t=this.$options;if(t.i18n=t.i18n||(t.__i18n?{}:null),t.i18n)if(t.i18n instanceof VueI18n){if(t.__i18n)try{var e=t.i18n&&t.i18n.messages?t.i18n.messages:{};t.__i18n.forEach(function(t){e=merge(e,JSON.parse(t))}),Object.keys(e).forEach(function(n){t.i18n.mergeLocaleMessage(n,e[n])})}catch(t){"production"!==process.env.NODE_ENV&&error("Cannot parse locale messages via custom blocks.",t)}this._i18n=t.i18n,this._i18nWatcher=this._i18n.watchI18nData()}else if(isPlainObject(t.i18n)){var n=this.$root&&this.$root.$i18n&&this.$root.$i18n instanceof VueI18n?this.$root.$i18n:null;if(n&&(t.i18n.root=this.$root,t.i18n.formatter=n.formatter,t.i18n.fallbackLocale=n.fallbackLocale,t.i18n.formatFallbackMessages=n.formatFallbackMessages,t.i18n.silentTranslationWarn=n.silentTranslationWarn,t.i18n.silentFallbackWarn=n.silentFallbackWarn,t.i18n.pluralizationRules=n.pluralizationRules,t.i18n.preserveDirectiveContent=n.preserveDirectiveContent),t.__i18n)try{var r=t.i18n&&t.i18n.messages?t.i18n.messages:{};t.__i18n.forEach(function(t){r=merge(r,JSON.parse(t))}),t.i18n.messages=r}catch(t){"production"!==process.env.NODE_ENV&&warn("Cannot parse locale messages via custom blocks.",t)}var a=t.i18n.sharedMessages;a&&isPlainObject(a)&&(t.i18n.messages=merge(t.i18n.messages,a)),this._i18n=new VueI18n(t.i18n),this._i18nWatcher=this._i18n.watchI18nData(),(void 0===t.i18n.sync||t.i18n.sync)&&(this._localeWatcher=this.$i18n.watchLocale()),n&&n.onComponentInstanceCreated(this._i18n)}else"production"!==process.env.NODE_ENV&&warn("Cannot be interpreted 'i18n' option.");else this.$root&&this.$root.$i18n&&this.$root.$i18n instanceof VueI18n?this._i18n=this.$root.$i18n:t.parent&&t.parent.$i18n&&t.parent.$i18n instanceof VueI18n&&(this._i18n=t.parent.$i18n)},beforeMount:function(){var t=this.$options;t.i18n=t.i18n||(t.__i18n?{}:null),t.i18n?t.i18n instanceof VueI18n?(this._i18n.subscribeDataChanging(this),this._subscribing=!0):isPlainObject(t.i18n)?(this._i18n.subscribeDataChanging(this),this._subscribing=!0):"production"!==process.env.NODE_ENV&&warn("Cannot be interpreted 'i18n' option."):this.$root&&this.$root.$i18n&&this.$root.$i18n instanceof VueI18n?(this._i18n.subscribeDataChanging(this),this._subscribing=!0):t.parent&&t.parent.$i18n&&t.parent.$i18n instanceof VueI18n&&(this._i18n.subscribeDataChanging(this),this._subscribing=!0)},beforeDestroy:function(){if(this._i18n){var t=this;this.$nextTick(function(){t._subscribing&&(t._i18n.unsubscribeDataChanging(t),delete t._subscribing),t._i18nWatcher&&(t._i18nWatcher(),t._i18n.destroyVM(),delete t._i18nWatcher),t._localeWatcher&&(t._localeWatcher(),delete t._localeWatcher)})}}},interpolationComponent={name:"i18n",functional:!0,props:{tag:{type:[String,Boolean,Object],default:"span"},path:{type:String,required:!0},locale:{type:String},places:{type:[Array,Object]}},render:function(t,e){var n=e.data,r=e.parent,a=e.props,i=e.slots,s=r.$i18n;if(s){var o=a.path,l=a.locale,c=a.places,u=i(),p=s.i(o,l,onlyHasDefaultPlace(u)||c?useLegacyPlaces(u.default,c):u),h=a.tag&&!0!==a.tag||!1===a.tag?a.tag:"span";return h?t(h,n,p):p}"production"!==process.env.NODE_ENV&&warn("Cannot find VueI18n instance!")}};function onlyHasDefaultPlace(t){var e;for(e in t)if("default"!==e)return!1;return Boolean(e)}function useLegacyPlaces(t,e){var n=e?createParamsFromPlaces(e):{};if(!t)return n;var r=(t=t.filter(function(t){return t.tag||""!==t.text.trim()})).every(vnodeHasPlaceAttribute);return"production"!==process.env.NODE_ENV&&r&&warn("`place` attribute is deprecated in next major version. Please switch to Vue slots."),t.reduce(r?assignChildPlace:assignChildIndex,n)}function createParamsFromPlaces(t){return"production"!==process.env.NODE_ENV&&warn("`places` prop is deprecated in next major version. Please switch to Vue slots."),Array.isArray(t)?t.reduce(assignChildIndex,{}):Object.assign({},t)}function assignChildPlace(t,e){return e.data&&e.data.attrs&&e.data.attrs.place&&(t[e.data.attrs.place]=e),t}function assignChildIndex(t,e,n){return t[n]=e,t}function vnodeHasPlaceAttribute(t){return Boolean(t.data&&t.data.attrs&&t.data.attrs.place)}var Vue,numberComponent={name:"i18n-n",functional:!0,props:{tag:{type:[String,Boolean,Object],default:"span"},value:{type:Number,required:!0},format:{type:[String,Object]},locale:{type:String}},render:function(t,e){var n=e.props,r=e.parent,a=e.data,i=r.$i18n;if(!i)return"production"!==process.env.NODE_ENV&&warn("Cannot find VueI18n instance!"),null;var s=null,o=null;isString(n.format)?s=n.format:isObject(n.format)&&(n.format.key&&(s=n.format.key),o=Object.keys(n.format).reduce(function(t,e){var r;return includes(numberFormatKeys,e)?Object.assign({},t,((r={})[e]=n.format[e],r)):t},null));var l=n.locale||i.locale,c=i._ntp(n.value,l,s,o),u=c.map(function(t,e){var n,r=a.scopedSlots&&a.scopedSlots[t.type];return r?r(((n={})[t.type]=t.value,n.index=e,n.parts=c,n)):t.value}),p=n.tag&&!0!==n.tag||!1===n.tag?n.tag:"span";return p?t(p,{attrs:a.attrs,class:a.class,staticClass:a.staticClass},u):u}};function bind(e,n,r){assert(e,r)&&t(e,n,r)}function update(e,n,r,a){if(assert(e,r)){var i=r.context.$i18n;localeEqual(e,r)&&looseEqual(n.value,n.oldValue)&&looseEqual(e._localeMessage,i.getLocaleMessage(i.locale))||t(e,n,r)}}function unbind(t,e,n,r){if(n.context){var a=n.context.$i18n||{};e.modifiers.preserve||a.preserveDirectiveContent||(t.textContent=""),t._vt=void 0,delete t._vt,t._locale=void 0,delete t._locale,t._localeMessage=void 0,delete t._localeMessage}else warn("Vue instance does not exists in VNode context")}function assert(t,e){var n=e.context;return n?!!n.$i18n||(warn("VueI18n instance does not exists in Vue instance"),!1):(warn("Vue instance does not exists in VNode context"),!1)}function localeEqual(t,e){var n=e.context;return t._locale===n.$i18n.locale}function t(t,e,n){var r,a,i=parseValue(e.value),s=i.path,o=i.locale,l=i.args,c=i.choice;if(s||o||l)if(s){var u=n.context;t._vt=t.textContent=null!=c?(r=u.$i18n).tc.apply(r,[s,c].concat(makeParams(o,l))):(a=u.$i18n).t.apply(a,[s].concat(makeParams(o,l))),t._locale=u.$i18n.locale,t._localeMessage=u.$i18n.getLocaleMessage(u.$i18n.locale)}else warn("`path` is required in v-t directive");else warn("value type not supported")}function parseValue(t){var e,n,r,a;return isString(t)?e=t:isPlainObject(t)&&(e=t.path,n=t.locale,r=t.args,a=t.choice),{path:e,locale:n,args:r,choice:a}}function makeParams(t,e){var n=[];return t&&n.push(t),e&&(Array.isArray(e)||isPlainObject(e))&&n.push(e),n}function install(t){if("production"!==process.env.NODE_ENV&&install.installed&&t===Vue)warn("already installed.");else{install.installed=!0;var e=(Vue=t).version&&Number(Vue.version.split(".")[0])||-1;if("production"!==process.env.NODE_ENV&&e<2)warn("vue-i18n ("+install.version+") need to use Vue 2.0 or later (Vue: "+Vue.version+").");else extend(Vue),Vue.mixin(mixin),Vue.directive("t",{bind:bind,update:update,unbind:unbind}),Vue.component(interpolationComponent.name,interpolationComponent),Vue.component(numberComponent.name,numberComponent),Vue.config.optionMergeStrategies.i18n=function(t,e){return void 0===e?t:e}}}var BaseFormatter=function(){this._caches=Object.create(null)};BaseFormatter.prototype.interpolate=function(t,e){if(!e)return[t];var n=this._caches[t];return n||(n=parse(t),this._caches[t]=n),compile(n,e)};var RE_TOKEN_LIST_VALUE=/^(?:\d)+/,RE_TOKEN_NAMED_VALUE=/^(?:\w)+/;function parse(t){for(var e=[],n=0,r="";n0)p--,u=IN_SUB_PATH,h[APPEND]();else{if(p=0,void 0===n)return!1;if(!1===(n=formatSubPath(n)))return!1;h[PUSH]()}};null!==u;)if("\\"!==(e=t[++c])||!f()){if(a=getPathCharType(e),(i=(o=pathStateMachine[u])[a]||o.else||ERROR)===ERROR)return;if(u=i[0],(s=h[i[1]])&&(r=void 0===(r=i[2])?e:r,!1===s()))return;if(u===AFTER_PATH)return l}}var I18nPath=function(){this._cache=Object.create(null)};I18nPath.prototype.parsePath=function(t){var e=this._cache[t];return e||(e=parse$1(t))&&(this._cache[t]=e),e||[]},I18nPath.prototype.getPathValue=function(t,e){if(!isObject(t))return null;var n=this.parsePath(e);if(0===n.length)return null;for(var r=n.length,a=t,i=0;i/,linkKeyMatcher=/(?:@(?:\.[a-z]+)?:(?:[\w\-_|.]+|\([\w\-_|.]+\)))/g,linkKeyPrefixMatcher=/^@(?:\.([a-z]+))?:/,bracketsMatcher=/[()]/g,defaultModifiers={upper:function(t){return t.toLocaleUpperCase()},lower:function(t){return t.toLocaleLowerCase()},capitalize:function(t){return""+t.charAt(0).toLocaleUpperCase()+t.substr(1)}},defaultFormatter=new BaseFormatter,VueI18n=function(t){var e=this;void 0===t&&(t={}),!Vue&&"undefined"!=typeof window&&window.Vue&&install(window.Vue);var n=t.locale||"en-US",r=!1!==t.fallbackLocale&&(t.fallbackLocale||"en-US"),a=t.messages||{},i=t.dateTimeFormats||{},s=t.numberFormats||{};this._vm=null,this._formatter=t.formatter||defaultFormatter,this._modifiers=t.modifiers||{},this._missing=t.missing||null,this._root=t.root||null,this._sync=void 0===t.sync||!!t.sync,this._fallbackRoot=void 0===t.fallbackRoot||!!t.fallbackRoot,this._formatFallbackMessages=void 0!==t.formatFallbackMessages&&!!t.formatFallbackMessages,this._silentTranslationWarn=void 0!==t.silentTranslationWarn&&t.silentTranslationWarn,this._silentFallbackWarn=void 0!==t.silentFallbackWarn&&!!t.silentFallbackWarn,this._dateTimeFormatters={},this._numberFormatters={},this._path=new I18nPath,this._dataListeners=[],this._componentInstanceCreatedListener=t.componentInstanceCreatedListener||null,this._preserveDirectiveContent=void 0!==t.preserveDirectiveContent&&!!t.preserveDirectiveContent,this.pluralizationRules=t.pluralizationRules||{},this._warnHtmlInMessage=t.warnHtmlInMessage||"off",this._postTranslation=t.postTranslation||null,this._escapeParameterHtml=t.escapeParameterHtml||!1,this.getChoiceIndex=function(t,n){var r=Object.getPrototypeOf(e);if(r&&r.getChoiceIndex)return r.getChoiceIndex.call(e,t,n);var a,i;return e.locale in e.pluralizationRules?e.pluralizationRules[e.locale].apply(e,[t,n]):(a=t,i=n,a=Math.abs(a),2===i?a?a>1?1:0:1:a?Math.min(a,2):0)},this._exist=function(t,n){return!(!t||!n)&&(!isNull(e._path.getPathValue(t,n))||!!t[n])},"warn"!==this._warnHtmlInMessage&&"error"!==this._warnHtmlInMessage||Object.keys(a).forEach(function(t){e._checkLocaleMessage(t,e._warnHtmlInMessage,a[t])}),this._initVM({locale:n,fallbackLocale:r,messages:a,dateTimeFormats:i,numberFormats:s})},prototypeAccessors={vm:{configurable:!0},messages:{configurable:!0},dateTimeFormats:{configurable:!0},numberFormats:{configurable:!0},availableLocales:{configurable:!0},locale:{configurable:!0},fallbackLocale:{configurable:!0},formatFallbackMessages:{configurable:!0},missing:{configurable:!0},formatter:{configurable:!0},silentTranslationWarn:{configurable:!0},silentFallbackWarn:{configurable:!0},preserveDirectiveContent:{configurable:!0},warnHtmlInMessage:{configurable:!0},postTranslation:{configurable:!0}};VueI18n.prototype._checkLocaleMessage=function(t,e,n){var r=function(t,e,n,a){if(isPlainObject(n))Object.keys(n).forEach(function(i){var s=n[i];isPlainObject(s)?(a.push(i),a.push("."),r(t,e,s,a),a.pop(),a.pop()):(a.push(i),r(t,e,s,a),a.pop())});else if(isArray(n))n.forEach(function(n,i){isPlainObject(n)?(a.push("["+i+"]"),a.push("."),r(t,e,n,a),a.pop(),a.pop()):(a.push("["+i+"]"),r(t,e,n,a),a.pop())});else if(isString(n)){if(htmlTagMatcher.test(n)){var i="Detected HTML in message '"+n+"' of keypath '"+a.join("")+"' at '"+e+"'. Consider component interpolation with '' to avoid XSS. See https://bit.ly/2ZqJzkp";"warn"===t?warn(i):"error"===t&&error(i)}}};r(e,t,n,[])},VueI18n.prototype._initVM=function(t){var e=Vue.config.silent;Vue.config.silent=!0,this._vm=new Vue({data:t}),Vue.config.silent=e},VueI18n.prototype.destroyVM=function(){this._vm.$destroy()},VueI18n.prototype.subscribeDataChanging=function(t){this._dataListeners.push(t)},VueI18n.prototype.unsubscribeDataChanging=function(t){remove(this._dataListeners,t)},VueI18n.prototype.watchI18nData=function(){var t=this;return this._vm.$watch("$data",function(){for(var e=t._dataListeners.length;e--;)Vue.nextTick(function(){t._dataListeners[e]&&t._dataListeners[e].$forceUpdate()})},{deep:!0})},VueI18n.prototype.watchLocale=function(){if(!this._sync||!this._root)return null;var t=this._vm;return this._root.$i18n.vm.$watch("locale",function(e){t.$set(t,"locale",e),t.$forceUpdate()},{immediate:!0})},VueI18n.prototype.onComponentInstanceCreated=function(t){this._componentInstanceCreatedListener&&this._componentInstanceCreatedListener(t,this)},prototypeAccessors.vm.get=function(){return this._vm},prototypeAccessors.messages.get=function(){return looseClone(this._getMessages())},prototypeAccessors.dateTimeFormats.get=function(){return looseClone(this._getDateTimeFormats())},prototypeAccessors.numberFormats.get=function(){return looseClone(this._getNumberFormats())},prototypeAccessors.availableLocales.get=function(){return Object.keys(this.messages).sort()},prototypeAccessors.locale.get=function(){return this._vm.locale},prototypeAccessors.locale.set=function(t){this._vm.$set(this._vm,"locale",t)},prototypeAccessors.fallbackLocale.get=function(){return this._vm.fallbackLocale},prototypeAccessors.fallbackLocale.set=function(t){this._localeChainCache={},this._vm.$set(this._vm,"fallbackLocale",t)},prototypeAccessors.formatFallbackMessages.get=function(){return this._formatFallbackMessages},prototypeAccessors.formatFallbackMessages.set=function(t){this._formatFallbackMessages=t},prototypeAccessors.missing.get=function(){return this._missing},prototypeAccessors.missing.set=function(t){this._missing=t},prototypeAccessors.formatter.get=function(){return this._formatter},prototypeAccessors.formatter.set=function(t){this._formatter=t},prototypeAccessors.silentTranslationWarn.get=function(){return this._silentTranslationWarn},prototypeAccessors.silentTranslationWarn.set=function(t){this._silentTranslationWarn=t},prototypeAccessors.silentFallbackWarn.get=function(){return this._silentFallbackWarn},prototypeAccessors.silentFallbackWarn.set=function(t){this._silentFallbackWarn=t},prototypeAccessors.preserveDirectiveContent.get=function(){return this._preserveDirectiveContent},prototypeAccessors.preserveDirectiveContent.set=function(t){this._preserveDirectiveContent=t},prototypeAccessors.warnHtmlInMessage.get=function(){return this._warnHtmlInMessage},prototypeAccessors.warnHtmlInMessage.set=function(t){var e=this,n=this._warnHtmlInMessage;if(this._warnHtmlInMessage=t,n!==t&&("warn"===t||"error"===t)){var r=this._getMessages();Object.keys(r).forEach(function(t){e._checkLocaleMessage(t,e._warnHtmlInMessage,r[t])})}},prototypeAccessors.postTranslation.get=function(){return this._postTranslation},prototypeAccessors.postTranslation.set=function(t){this._postTranslation=t},VueI18n.prototype._getMessages=function(){return this._vm.messages},VueI18n.prototype._getDateTimeFormats=function(){return this._vm.dateTimeFormats},VueI18n.prototype._getNumberFormats=function(){return this._vm.numberFormats},VueI18n.prototype._warnDefault=function(t,e,n,r,a,i){if(!isNull(n))return n;if(this._missing){var s=this._missing.apply(null,[t,e,r,a]);if(isString(s))return s}else"production"===process.env.NODE_ENV||this._isSilentTranslationWarn(e)||warn("Cannot translate the value of keypath '"+e+"'. Use the value of keypath as default.");if(this._formatFallbackMessages){var o=parseArgs.apply(void 0,a);return this._render(e,i,o.params,e)}return e},VueI18n.prototype._isFallbackRoot=function(t){return!t&&!isNull(this._root)&&this._fallbackRoot},VueI18n.prototype._isSilentFallbackWarn=function(t){return this._silentFallbackWarn instanceof RegExp?this._silentFallbackWarn.test(t):this._silentFallbackWarn},VueI18n.prototype._isSilentFallback=function(t,e){return this._isSilentFallbackWarn(e)&&(this._isFallbackRoot()||t!==this.fallbackLocale)},VueI18n.prototype._isSilentTranslationWarn=function(t){return this._silentTranslationWarn instanceof RegExp?this._silentTranslationWarn.test(t):this._silentTranslationWarn},VueI18n.prototype._interpolate=function(t,e,n,r,a,i,s){if(!e)return null;var o,l=this._path.getPathValue(e,n);if(isArray(l)||isPlainObject(l))return l;if(isNull(l)){if(!isPlainObject(e))return null;if(!isString(o=e[n])&&!isFunction(o))return"production"===process.env.NODE_ENV||this._isSilentTranslationWarn(n)||this._isSilentFallback(t,n)||warn("Value of key '"+n+"' is not a string or function !"),null}else{if(!isString(l)&&!isFunction(l))return"production"===process.env.NODE_ENV||this._isSilentTranslationWarn(n)||this._isSilentFallback(t,n)||warn("Value of key '"+n+"' is not a string or function!"),null;o=l}return isString(o)&&(o.indexOf("@:")>=0||o.indexOf("@.")>=0)&&(o=this._link(t,e,o,r,"raw",i,s)),this._render(o,a,i,n)},VueI18n.prototype._link=function(t,e,n,r,a,i,s){var o=n,l=o.match(linkKeyMatcher);for(var c in l)if(l.hasOwnProperty(c)){var u=l[c],p=u.match(linkKeyPrefixMatcher),h=p[0],f=p[1],_=u.replace(h,"").replace(bracketsMatcher,"");if(includes(s,_))return"production"!==process.env.NODE_ENV&&warn('Circular reference found. "'+u+'" is already visited in the chain of '+s.reverse().join(" <- ")),o;s.push(_);var m=this._interpolate(t,e,_,r,"raw"===a?"string":a,"raw"===a?void 0:i,s);if(this._isFallbackRoot(m)){if("production"===process.env.NODE_ENV||this._isSilentTranslationWarn(_)||warn("Fall back to translate the link placeholder '"+_+"' with root locale."),!this._root)throw Error("unexpected error");var g=this._root.$i18n;m=g._translate(g._getMessages(),g.locale,g.fallbackLocale,_,r,a,i)}m=this._warnDefault(t,_,m,r,isArray(i)?i:[i],a),this._modifiers.hasOwnProperty(f)?m=this._modifiers[f](m):defaultModifiers.hasOwnProperty(f)&&(m=defaultModifiers[f](m)),s.pop(),o=m?o.replace(u,m):o}return o},VueI18n.prototype._createMessageContext=function(t){var e=isArray(t)?t:[],n=isObject(t)?t:{};return{list:function(t){return e[t]},named:function(t){return n[t]}}},VueI18n.prototype._render=function(t,e,n,r){if(isFunction(t))return t(this._createMessageContext(n));var a=this._formatter.interpolate(t,n,r);return a||(a=defaultFormatter.interpolate(t,n,r)),"string"!==e||isString(a)?a:a.join("")},VueI18n.prototype._appendItemToChain=function(t,e,n){var r=!1;return includes(t,e)||(r=!0,e&&(r="!"!==e[e.length-1],e=e.replace(/!/g,""),t.push(e),n&&n[e]&&(r=n[e]))),r},VueI18n.prototype._appendLocaleToChain=function(t,e,n){var r,a=e.split("-");do{var i=a.join("-");r=this._appendItemToChain(t,i,n),a.splice(-1,1)}while(a.length&&!0===r);return r},VueI18n.prototype._appendBlockToChain=function(t,e,n){for(var r=!0,a=0;a0;)i[s]=arguments[s+4];if(!t)return"";var o=parseArgs.apply(void 0,i);this._escapeParameterHtml&&(o.params=escapeParams(o.params));var l=o.locale||e,c=this._translate(n,l,this.fallbackLocale,t,r,"string",o.params);if(this._isFallbackRoot(c)){if("production"===process.env.NODE_ENV||this._isSilentTranslationWarn(t)||this._isSilentFallbackWarn(t)||warn("Fall back to translate the keypath '"+t+"' with root locale."),!this._root)throw Error("unexpected error");return(a=this._root).$t.apply(a,[t].concat(i))}return c=this._warnDefault(l,t,c,r,i,"string"),this._postTranslation&&null!=c&&(c=this._postTranslation(c,t)),c},VueI18n.prototype.t=function(t){for(var e,n=[],r=arguments.length-1;r-- >0;)n[r]=arguments[r+1];return(e=this)._t.apply(e,[t,this.locale,this._getMessages(),null].concat(n))},VueI18n.prototype._i=function(t,e,n,r,a){var i=this._translate(n,e,this.fallbackLocale,t,r,"raw",a);if(this._isFallbackRoot(i)){if("production"===process.env.NODE_ENV||this._isSilentTranslationWarn(t)||warn("Fall back to interpolate the keypath '"+t+"' with root locale."),!this._root)throw Error("unexpected error");return this._root.$i18n.i(t,e,a)}return this._warnDefault(e,t,i,r,[a],"raw")},VueI18n.prototype.i=function(t,e,n){return t?(isString(e)||(e=this.locale),this._i(t,e,this._getMessages(),null,n)):""},VueI18n.prototype._tc=function(t,e,n,r,a){for(var i,s=[],o=arguments.length-5;o-- >0;)s[o]=arguments[o+5];if(!t)return"";void 0===a&&(a=1);var l={count:a,n:a},c=parseArgs.apply(void 0,s);return c.params=Object.assign(l,c.params),s=null===c.locale?[c.params]:[c.locale,c.params],this.fetchChoice((i=this)._t.apply(i,[t,e,n,r].concat(s)),a)},VueI18n.prototype.fetchChoice=function(t,e){if(!t||!isString(t))return null;var n=t.split("|");return n[e=this.getChoiceIndex(e,n.length)]?n[e].trim():t},VueI18n.prototype.tc=function(t,e){for(var n,r=[],a=arguments.length-2;a-- >0;)r[a]=arguments[a+2];return(n=this)._tc.apply(n,[t,this.locale,this._getMessages(),null,e].concat(r))},VueI18n.prototype._te=function(t,e,n){for(var r=[],a=arguments.length-3;a-- >0;)r[a]=arguments[a+3];var i=parseArgs.apply(void 0,r).locale||e;return this._exist(n[i],t)},VueI18n.prototype.te=function(t,e){return this._te(t,this.locale,this._getMessages(),e)},VueI18n.prototype.getLocaleMessage=function(t){return looseClone(this._vm.messages[t]||{})},VueI18n.prototype.setLocaleMessage=function(t,e){"warn"!==this._warnHtmlInMessage&&"error"!==this._warnHtmlInMessage||this._checkLocaleMessage(t,this._warnHtmlInMessage,e),this._vm.$set(this._vm.messages,t,e)},VueI18n.prototype.mergeLocaleMessage=function(t,e){"warn"!==this._warnHtmlInMessage&&"error"!==this._warnHtmlInMessage||this._checkLocaleMessage(t,this._warnHtmlInMessage,e),this._vm.$set(this._vm.messages,t,merge(void 0!==this._vm.messages[t]&&Object.keys(this._vm.messages[t]).length?this._vm.messages[t]:{},e))},VueI18n.prototype.getDateTimeFormat=function(t){return looseClone(this._vm.dateTimeFormats[t]||{})},VueI18n.prototype.setDateTimeFormat=function(t,e){this._vm.$set(this._vm.dateTimeFormats,t,e),this._clearDateTimeFormat(t,e)},VueI18n.prototype.mergeDateTimeFormat=function(t,e){this._vm.$set(this._vm.dateTimeFormats,t,merge(this._vm.dateTimeFormats[t]||{},e)),this._clearDateTimeFormat(t,e)},VueI18n.prototype._clearDateTimeFormat=function(t,e){for(var n in e){var r=t+"__"+n;this._dateTimeFormatters.hasOwnProperty(r)&&delete this._dateTimeFormatters[r]}},VueI18n.prototype._localizeDateTime=function(t,e,n,r,a){for(var i=e,s=r[i],o=this._getLocaleChain(e,n),l=0;l0;)e[n]=arguments[n+1];var r=this.locale,a=null;return 1===e.length?isString(e[0])?a=e[0]:isObject(e[0])&&(e[0].locale&&(r=e[0].locale),e[0].key&&(a=e[0].key)):2===e.length&&(isString(e[0])&&(a=e[0]),isString(e[1])&&(r=e[1])),this._d(t,r,a)},VueI18n.prototype.getNumberFormat=function(t){return looseClone(this._vm.numberFormats[t]||{})},VueI18n.prototype.setNumberFormat=function(t,e){this._vm.$set(this._vm.numberFormats,t,e),this._clearNumberFormat(t,e)},VueI18n.prototype.mergeNumberFormat=function(t,e){this._vm.$set(this._vm.numberFormats,t,merge(this._vm.numberFormats[t]||{},e)),this._clearNumberFormat(t,e)},VueI18n.prototype._clearNumberFormat=function(t,e){for(var n in e){var r=t+"__"+n;this._numberFormatters.hasOwnProperty(r)&&delete this._numberFormatters[r]}},VueI18n.prototype._getNumberFormatter=function(t,e,n,r,a,i){for(var s=e,o=r[s],l=this._getLocaleChain(e,n),c=0;c0;)e[n]=arguments[n+1];var r=this.locale,a=null,i=null;return 1===e.length?isString(e[0])?a=e[0]:isObject(e[0])&&(e[0].locale&&(r=e[0].locale),e[0].key&&(a=e[0].key),i=Object.keys(e[0]).reduce(function(t,n){var r;return includes(numberFormatKeys,n)?Object.assign({},t,((r={})[n]=e[0][n],r)):t},null)):2===e.length&&(isString(e[0])&&(a=e[0]),isString(e[1])&&(r=e[1])),this._n(t,r,a,i)},VueI18n.prototype._ntp=function(t,e,n,r){if(!VueI18n.availabilities.numberFormat)return"production"!==process.env.NODE_ENV&&warn("Cannot format to parts a Number value due to not supported Intl.NumberFormat."),[];if(!n)return(r?new Intl.NumberFormat(e,r):new Intl.NumberFormat(e)).formatToParts(t);var a=this._getNumberFormatter(t,e,this.fallbackLocale,this._getNumberFormats(),n,r),i=a&&a.formatToParts(t);if(this._isFallbackRoot(i)){if("production"===process.env.NODE_ENV||this._isSilentTranslationWarn(n)||warn("Fall back to format number to parts of root: key '"+n+"' ."),!this._root)throw Error("unexpected error");return this._root.$i18n._ntp(t,e,n,r)}return i||[]},Object.defineProperties(VueI18n.prototype,prototypeAccessors),Object.defineProperty(VueI18n,"availabilities",{get:function(){if(!availabilities){var t="undefined"!=typeof Intl;availabilities={dateTimeFormat:t&&void 0!==Intl.DateTimeFormat,numberFormat:t&&void 0!==Intl.NumberFormat}}return availabilities}}),VueI18n.install=install,VueI18n.version="8.22.4";export default VueI18n;