Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

vue-i18n-routing

Package Overview
Dependencies
Maintainers
1
Versions
239
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vue-i18n-routing - npm Package Compare versions

Comparing version 0.0.0-d5a38c7 to 0.0.0-e0454ba

4

dist/vue-i18n-routing.cjs.js

@@ -1,5 +0,5 @@

"use strict";var xe=Object.defineProperty,Ae=Object.defineProperties;var Ce=Object.getOwnPropertyDescriptors;var F=Object.getOwnPropertySymbols;var ce=Object.prototype.hasOwnProperty,se=Object.prototype.propertyIsEnumerable;var re=(e,t,o)=>t in e?xe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o,P=(e,t)=>{for(var o in t||(t={}))ce.call(t,o)&&re(e,o,t[o]);if(F)for(var o of F(t))se.call(t,o)&&re(e,o,t[o]);return e},U=(e,t)=>Ae(e,Ce(t));var ue=(e,t)=>{var o={};for(var n in e)ce.call(e,n)&&t.indexOf(n)<0&&(o[n]=e[n]);if(e!=null&&F)for(var n of F(e))t.indexOf(n)<0&&se.call(e,n)&&(o[n]=e[n]);return o};Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});var d=require("vue-demi"),p=require("@intlify/vue-router-bridge"),w=require("@intlify/vue-i18n-bridge");function Oe(e){return e&&typeof e=="object"&&"default"in e?e:{default:e}}var De=Oe(p);/*!
"use strict";var De=Object.defineProperty,Oe=Object.defineProperties;var be=Object.getOwnPropertyDescriptors;var V=Object.getOwnPropertySymbols;var ue=Object.prototype.hasOwnProperty,fe=Object.prototype.propertyIsEnumerable;var ie=(e,t,o)=>t in e?De(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o,T=(e,t)=>{for(var o in t||(t={}))ue.call(t,o)&&ie(e,o,t[o]);if(V)for(var o of V(t))fe.call(t,o)&&ie(e,o,t[o]);return e},B=(e,t)=>Oe(e,be(t));var de=(e,t)=>{var o={};for(var n in e)ue.call(e,n)&&t.indexOf(n)<0&&(o[n]=e[n]);if(e!=null&&V)for(var n of V(e))t.indexOf(n)<0&&fe.call(e,n)&&(o[n]=e[n]);return o};Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});var d=require("vue-demi"),p=require("@intlify/vue-router-bridge"),F=require("@intlify/vue-i18n-bridge");function xe(e){return e&&typeof e=="object"&&"default"in e?e:{default:e}}var Ce=xe(p);const O={PREFIX:"prefix",PREFIX_EXCEPT_DEFAULT:"prefix_except_default",PREFIX_AND_DEFAULT:"prefix_and_default",NO_PREFIX:"no_prefix"},G="",X=O.PREFIX_EXCEPT_DEFAULT,M=!1,k="___",z="default",oe="ltr",ne="";/*!
* shared v9.2.0-beta.35
* (c) 2022 kazuya kawaguchi
* Released under the MIT License.
*/const we=typeof Symbol=="function"&&typeof Symbol.toStringTag=="symbol",Ne=e=>we?Symbol(e):e,de=Object.assign,Te=Array.isArray,Fe=e=>typeof e=="function",I=e=>typeof e=="string",Ue=e=>typeof e=="boolean",$e=e=>typeof e=="symbol",Q=e=>e!==null&&typeof e=="object",Ve=/\/$|\/\?/;function q(e="",t=!1){return t?Ve.test(e):e.endsWith("/")}function je(e="",t=!1){if(!t)return(q(e)?e.slice(0,-1):e)||"/";if(!q(e,!0))return e||"/";const[o,...n]=e.split("?");return(o.slice(0,-1)||"/")+(n.length?`?${n.join("?")}`:"")}function Be(e="",t=!1){if(!t)return e.endsWith("/")?e:e+"/";if(q(e,!0))return e||"/";const[o,...n]=e.split("?");return o+"/"+(n.length?`?${n.join("?")}`:"")}const Ge=typeof window!="undefined";function he(e,t){typeof console!="undefined"&&(console.warn("[vue-i18n-routing] "+e),t&&console.warn(t.stack))}function me(e){e=e||[];const t=[];for(const o of e)I(o)?t.push({code:o}):t.push(o);return t}function $(e){return e!=null&&"global"in e&&"mode"in e}function V(e){return e!=null&&!("__composer"in e)&&d.isRef(e.locale)}function N(e){return e!=null&&"__composer"in e}function Y(e){return e!=null&&!("__composer"in e)&&!d.isRef(e.locale)}function x(e){return e!=null&&("__VUE_I18N_BRIDGE__"in e||"_sync"in e)}function pe(e){return $(e)?V(e.global)?e.global:e.global.__composer:N(e)?e.__composer:e}function j(e){const t=$(e)?e.global:e;return V(t)?d.isVue2&&x(e)?e.locale:t.locale.value:(Y(t)||N(t)||x(t),t.locale)}function Xe(e){const t=$(e)?e.global:e;return V(t)?d.isVue2&&x(e)?e.locales:t.locales.value:(Y(t)||N(t)||x(t),t.locales)}function ge(e,t){const o=$(e)?e.global:e;if(V(o))d.isVue2&&x(e)?e.locale=t:o.locale.value=t;else if(Y(o)||N(o)||x(o))o.locale=t;else throw new Error("TODO:")}function ke(e,t,o){return e.replace(/\/+$/,"")+(t?"/":"")||(o?"":"/")}function ie(e){return p.isVueRouter4,d.isRef(e)?e.value:e}function Le(e){return I(e)?e:$e(e)?e.toString():"(null)"}function fe(e,t,{defaultLocale:o,strategy:n,routesNameSeparator:l,defaultLocaleRouteNameSuffix:a}){let r=Le(e)+(n==="no_prefix"?"":l+t);return t===o&&n==="prefix_and_default"&&(r+=l+a),r}function Re(e,t){return Fe(e)?e(t):e}function Me(e,t){const o=[];for(const[n,l]of t.entries()){const a=e.find(r=>r.iso.toLowerCase()===l.toLowerCase());if(a){o.push({code:a.code,score:1-n/t.length});break}}for(const[n,l]of t.entries()){const a=l.split("-")[0].toLowerCase(),r=e.find(c=>c.iso.split("-")[0].toLowerCase()===a);if(r){o.push({code:r.code,score:.999-n/t.length});break}}return o}const ze=Me;function qe(e,t){return e.score===t.score?t.code.length-e.code.length:t.score-e.score}const He=qe;function We(e,t,{matcher:o=ze,comparer:n=He}={}){const l=[];for(const r of e){const{code:c}=r,s=r.iso||c;l.push({code:c,iso:s})}const a=o(l,t);return a.length>1&&a.sort(n),a.length?a[0].code:""}const O={PREFIX:"prefix",PREFIX_EXCEPT_DEFAULT:"prefix_except_default",PREFIX_AND_DEFAULT:"prefix_and_default",NO_PREFIX:"no_prefix"},J="",K=O.PREFIX_EXCEPT_DEFAULT,Z=!1,ee="___",te="default",_e="ltr",ve="";function E(e){return function(){return Reflect.apply(e,{getRouteBaseName:this.getRouteBaseName,localePath:this.localePath,localeRoute:this.localeRoute,localeLocation:this.localeLocation,resolveRoute:this.resolveRoute,switchLocalePath:this.switchLocalePath,localeHead:this.localeHead,i18n:this.$i18n,route:this.$route,router:this.$router},arguments)}}function Ee(e,{locales:t=[],localeCodes:o=[],baseUrl:n=ve,hooks:l={}}={}){const a=d.effectScope(),r=e.install;return e.install=(c,...s)=>{Reflect.apply(r,e,[c,...s]);const i=pe(e);a.run(()=>Qe(i,{locales:t,localeCodes:o,baseUrl:n,hooks:l})),N(e.global)&&Je(e.global,l.onExtendVueI18n);const f=c,u=e.mode==="composition"?d.isVue3?f.config.globalProperties.$i18n:e:d.isVue2?e:null;if(u&&Ye(u,i,l.onExtendExportedGlobal),(Ke(s[0])?s[0]:{inject:!0}).inject&&c.mixin({methods:{resolveRoute:E(T),localePath:E(G),localeRoute:E(X),localeLocation:E(oe),switchLocalePath:E(D),getRouteBaseName:E(A),localeHead:E(ne)}}),f.unmount){const h=f.unmount;f.unmount=()=>{a.stop(),h()}}},a}function Qe(e,t){const{locales:o,localeCodes:n,baseUrl:l}=t,a=d.ref(o),r=d.ref(n);e.locales=d.computed(()=>a.value),e.localeCodes=d.computed(()=>r.value),e.__baseUrl=Re(l,{}),t.hooks&&t.hooks.onExtendComposer&&t.hooks.onExtendComposer(e)}function Ye(e,t,o){const n=[{locales:{get(){return t.locales.value}},localeCodes:{get(){return t.localeCodes.value}},__baseUrl:{get(){return t.__baseUrl}}}];o&&n.push(o(t));for(const l of n)for(const[a,r]of Object.entries(l))Object.defineProperty(e,a,r)}function Je(e,t){const o=pe(e),n=[{locales:{get(){return o.locales.value}},localeCodes:{get(){return o.localeCodes.value}},__baseUrl:{get(){return o.__baseUrl}}}];t&&n.push(t(o));for(const l of n)for(const[a,r]of Object.entries(l))Object.defineProperty(e,a,r)}function Ke(e){return Q(e)&&"inject"in e&&Ue(e.inject)}function Se(e,{defaultLocale:t=J,strategy:o=K,trailingSlash:n=Z,routesNameSeparator:l=ee,defaultLocaleRouteNameSuffix:a=te,includeUprefixedFallback:r=!1,optionsResolver:c=void 0,locales:s=[]}={}){if(o==="no_prefix")return e;const i=s.map(u=>I(u)?u:u.code);function f(u,m,h=!1,g=!1){if(u.redirect&&(!u.component||!u.file))return[u];let S=null;return c!=null&&(S=c(u,m),S==null)?[u]:m.reduce((_,v)=>{const{name:C}=u;let{path:L}=u;const R=P({},u);C&&(R.name=`${C}${l}${v}`),u.children&&(R.children=u.children.reduce((y,z)=>[...y,...f(z,[v],!0,g)],[]));const b=v===t;if(b&&o==="prefix_and_default")if(h)h&&g&&C&&(R.name+=`${l}${a}`);else{const y=U(P({},R),{path:L});if(C&&(y.name=`${R.name}${l}${a}`),u.children){y.children=[];for(const z of u.children)y.children=y.children.concat(f(z,[v],!0,!0))}_.push(y)}const ae=h&&!L.startsWith("/"),le=!ae&&!(b&&o==="prefix_except_default");return le&&(L=`/${v}${L}`),L&&(L=ke(L,n,ae)),le&&b&&o==="prefix"&&r&&_.push(P({},u)),R.path=L,_.push(R),_},[])}return e.reduce((u,m)=>[...u,...f(m,i||[])],[])}const H=Ne("vue-i18n-routing-gor");function ye(e,t){e[H]?he("already registered global options"):e[H]=t}function Pe(e){var t;return(t=e[H])!=null?t:{}}function Ze(e,t={}){const{version:o,defaultLocale:n,locales:l,strategy:a,trailingSlash:r,routesNameSeparator:c,defaultLocaleRouteNameSuffix:s,defaultDirection:i,baseUrl:f,routes:u,routeOptionsResolver:m}=ot(t),h=me(l),g=h.map(v=>v.code),S=Ie(g,c,s);Ee(e,{locales:h,baseUrl:f,localeCodes:g});const M=Se(u,{locales:l,defaultLocale:n,strategy:a,trailingSlash:r,routesNameSeparator:c,defaultLocaleRouteNameSuffix:s,optionsResolver:m});t.routes=M;const _=et(t,o);return ye(_,{defaultLocale:n,localeCodes:g,strategy:a,trailingSlash:r,routesNameSeparator:c,defaultLocaleRouteNameSuffix:s,defaultDirection:i}),_.beforeEach((v,C,L)=>{const R=j(e),b=S(v)||R||n||"";R!==b&&ge(e,b),L()}),_}function et(e,t){if(d.isVue3&&t===4)return p.createRouter(e);if(d.isVue2&&t===3)return new De.default(e);throw new Error("TODO:")}function tt(e){return new RegExp(`^/(${e.join("|")})(?:/|$)`,"i")}function Ie(e,t,o){const n=`(${e.join("|")})`,l=`(?:${t}${o})?`,a=new RegExp(`${t}${n}${l}$`,"i"),r=tt(e);return s=>{if(Q(s)){if(s.name){const f=(I(s.name)?s.name:s.name.toString()).match(a);if(f&&f.length>1)return f[1]}else if(s.path){const i=s.path.match(r);if(i&&i.length>1)return i[1]}}else if(I(s)){const i=s.match(r);if(i&&i.length>1)return i[1]}return""}}function ot(e){var t,o,n,l,a,r,c,s,i,f;return e.version=(t=e.version)!=null?t:4,e.defaultLocale=(o=e.defaultLocale)!=null?o:J,e.strategy=(n=e.strategy)!=null?n:K,e.trailingSlash=(l=e.trailingSlash)!=null?l:Z,e.routesNameSeparator=(a=e.routesNameSeparator)!=null?a:ee,e.defaultLocaleRouteNameSuffix=(r=e.defaultLocaleRouteNameSuffix)!=null?r:te,e.locales=(c=e.locales)!=null?c:[],e.defaultDirection=(s=e.defaultDirection)!=null?s:_e,e.baseUrl=(i=e.baseUrl)!=null?i:ve,e.routes=(f=e.routes)!=null?f:[],e}function B(e,t,{defaultLocale:o=J,defaultDirection:n=_e,defaultLocaleRouteNameSuffix:l=te,routesNameSeparator:a=ee,strategy:r=K,trailingSlash:c=Z,localeCodes:s=[]}={}){const i=Pe(e);return{defaultLocale:t.defaultLocale||i.defaultLocale||o,defaultDirection:t.defaultDirection||i.defaultDirection||n,defaultLocaleRouteNameSuffix:t.defaultLocaleRouteNameSuffix||i.defaultLocaleRouteNameSuffix||l,routesNameSeparator:t.routesNameSeparator||i.routesNameSeparator||a,strategy:t.strategy||i.strategy||r,trailingSlash:t.trailingSlash||i.trailingSlash||c,localeCodes:t.localeCodes||i.localeCodes||s}}const nt=new Set([O.PREFIX_AND_DEFAULT,O.PREFIX_EXCEPT_DEFAULT]);function A(e){const t=this.router,{routesNameSeparator:o}=B(t,this),n=e!=null?d.isRef(e)?d.unref(e):e:this.route;return n.name?Le(n.name).split(o)[0]:void 0}function G(e,t){const o=T.call(this,e,t);return o==null?"":d.isVue3?o.redirectedFrom||o.fullPath:o.route.redirectedFrom||o.route.fullPath}function X(e,t){const o=T.call(this,e,t);return o==null?void 0:d.isVue3?o:o.route}function oe(e,t){const o=T.call(this,e,t);return o==null?void 0:d.isVue3?o:o.location}function T(e,t){const o=this.router,n=this.i18n,l=t||j(n),{routesNameSeparator:a,defaultLocale:r,defaultLocaleRouteNameSuffix:c,strategy:s,trailingSlash:i}=B(o,this);let f=e;I(e)&&(f[0]==="/"?f={path:e}:f={name:e});let u=de({},f);if(u.path&&!u.name){const h=o.resolve(u),g=d.isVue3?h:h.route,S=A.call(this,g);I(S)?u={name:fe(S,l,{defaultLocale:r,strategy:s,routesNameSeparator:a,defaultLocaleRouteNameSuffix:c}),params:g.params,query:g.query,hash:g.hash}:(!(l===r&&nt.has(s))&&s!==O.NO_PREFIX&&(u.path=`/${l}${u.path}`),u.path=i?Be(u.path,!0):je(u.path,!0))}else{u.name=fe(u.name,l,{defaultLocale:r,strategy:s,routesNameSeparator:a,defaultLocaleRouteNameSuffix:c});const{params:h}=u;h&&h["0"]===void 0&&h.pathMatch&&(h["0"]=h.pathMatch)}const m=o.resolve(u);return(d.isVue3?m.name:m.route.name)?m:o.resolve(e)}function D(e){const t=this.route,o=A.call(this,t);if(!o)return"";const s=!d.isVue3&&d.isRef(t)?t.value:t,{params:n}=s,l=ue(s,["params"]),a={},r=de({},l,{name:o,params:U(P(P({},n),a),{0:n.pathMatch})});return G.call(this,r,e)}function ne({addDirAttribute:e=!1,addSeoAttributes:t=!1}={}){const o=this.router,n=this.i18n,{defaultDirection:l}=B(o,this),a={htmlAttrs:{},link:[],meta:[]};if(n.locales==null||n.__baseUrl==null)return a;const r=j(n),c=Xe(n),s=me(c).find(u=>u.code===r)||{code:r},i=s.iso,f=s.dir||l;return e&&(a.htmlAttrs.dir=f),t&&r&&n.locales&&(i&&(a.htmlAttrs.lang=i),at.call(this,c,n.__baseUrl,a.link),lt.call(this,n.__baseUrl,a.link,t),rt(s,i,a.meta),ct(c,i,a.meta)),a}function at(e,t,o){const n=this.router,{defaultLocale:l,strategy:a}=B(n,this);if(a===O.NO_PREFIX)return;const r=new Map;for(const c of e){const s=c.iso;if(!s){he("Locale ISO code is required to generate alternate link");continue}const[i,f]=s.split("-");i&&f&&(c.isCatchallLocale||!r.has(i))&&r.set(i,c),r.set(s,c)}for(const[c,s]of r.entries()){const i=D.call(this,s.code);i&&o.push({hid:`i18n-alt-${c}`,rel:"alternate",href:W(i,t),hreflang:c})}if(l){const c=D.call(this,l);c&&o.push({hid:"i18n-xd",rel:"alternate",href:W(c,t),hreflang:"x-default"})}}function lt(e,t,o){const n=this.route,l=X.call(this,U(P({},n),{name:A.call(this,n)}));if(l){let a=W(l.path,e);const r=Q(o)&&o.canonicalQueries||[];if(r.length){const c=l.query,s=new URLSearchParams;for(const f of r)if(f in c){const u=c[f];Te(u)?u.forEach(m=>s.append(f,m||"")):s.append(f,u||"")}const i=s.toString();i&&(a=`${a}?${i}`)}t.push({hid:"i18n-can",rel:"canonical",href:a})}}function rt(e,t,o){!(e&&t)||o.push({hid:"i18n-og",property:"og:locale",content:be(t)})}function ct(e,t,o){const n=e.filter(l=>{const a=l.iso;return a&&a!==t});if(n.length){const l=n.map(a=>({hid:`i18n-og-alt-${a.iso}`,property:"og:locale:alternate",content:be(a.iso)}));o.push(...l)}}function be(e){return(e||"").replace(/-/g,"_")}function W(e,t){return e.match(/^https?:\/\//)?e:t+e}function k(e,t){const{router:o,route:n,i18n:l,defaultLocale:a,strategy:r,defaultLocaleRouteNameSuffix:c,trailingSlash:s,routesNameSeparator:i}=e;return function(...f){return Reflect.apply(t,{router:o,route:n,i18n:l,defaultLocale:a,strategy:r,defaultLocaleRouteNameSuffix:c,trailingSlash:s,routesNameSeparator:i},f)}}function st(e=p.useRoute(),{router:t=p.useRouter(),routesNameSeparator:o=void 0}={}){const n={router:t,route:e,routesNameSeparator:o};return A.call(n,e)}function ut({router:e=p.useRouter(),route:t=p.useRoute(),i18n:o=w.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:l=void 0,routesNameSeparator:a=void 0,strategy:r=void 0,trailingSlash:c=void 0}={}){return k({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:l,routesNameSeparator:a,strategy:r,trailingSlash:c},G)}function it({router:e=p.useRouter(),route:t=p.useRoute(),i18n:o=w.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:l=void 0,routesNameSeparator:a=void 0,strategy:r=void 0,trailingSlash:c=void 0}={}){return k({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:l,routesNameSeparator:a,strategy:r,trailingSlash:c},X)}function ft({router:e=p.useRouter(),route:t=p.useRoute(),i18n:o=w.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:l=void 0,routesNameSeparator:a=void 0,strategy:r=void 0,trailingSlash:c=void 0}={}){return k({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:l,routesNameSeparator:a,strategy:r,trailingSlash:c},oe)}function dt({router:e=p.useRouter(),route:t=p.useRoute(),i18n:o=w.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:l=void 0,routesNameSeparator:a=void 0,strategy:r=void 0,trailingSlash:c=void 0}={}){return k({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:l,routesNameSeparator:a,strategy:r,trailingSlash:c},D)}function ht({addDirAttribute:e=!1,addSeoAttributes:t=!1,strategy:o=void 0,defaultLocale:n=void 0,route:l=p.useRoute(),router:a=p.useRouter(),i18n:r=w.useI18n()}={}){const c=a,s=d.ref({htmlAttrs:{},link:[],meta:[]});function i(){s.value={htmlAttrs:{},link:[],meta:[]}}function f(u){s.value=Reflect.apply(ne,{router:a,route:u,i18n:r,defaultLocale:n,strategy:o},[{addDirAttribute:e,addSeoAttributes:t}])}if(Ge)if(d.isVue3){const u=d.watchEffect(()=>{i(),f(ie(c.currentRoute))});d.onUnmounted(()=>u())}else{const u=c.afterEach((m,h)=>{i(),f(m)});d.onUnmounted(()=>u()),f(l)}else f(ie(c.currentRoute));return s}const mt="0.0.0";exports.VERSION=mt;exports.createLocaleFromRouteGetter=Ie;exports.createRouter=Ze;exports.extendI18n=Ee;exports.findBrowserLocale=We;exports.getGlobalOptions=Pe;exports.getLocale=j;exports.getRouteBaseName=A;exports.localeHead=ne;exports.localeLocation=oe;exports.localePath=G;exports.localeRoute=X;exports.localizeRoutes=Se;exports.proxyVueInstance=E;exports.registerGlobalOptions=ye;exports.resolveBaseUrl=Re;exports.resolveRoute=T;exports.setLocale=ge;exports.switchLocalePath=D;exports.useLocaleHead=ht;exports.useLocaleLocation=ft;exports.useLocalePath=ut;exports.useLocaleRoute=it;exports.useRouteBaseName=st;exports.useSwitchLocalePath=dt;
*/const Ue=typeof Symbol=="function"&&typeof Symbol.toStringTag=="symbol",Fe=e=>Ue?Symbol(e):e,j=Object.assign,Ne=Array.isArray,we=e=>typeof e=="function",y=e=>typeof e=="string",$e=e=>typeof e=="boolean",Ve=e=>typeof e=="symbol",le=e=>e!==null&&typeof e=="object",Be=/\/$|\/\?/;function Z(e="",t=!1){return t?Be.test(e):e.endsWith("/")}function je(e="",t=!1){if(!t)return(Z(e)?e.slice(0,-1):e)||"/";if(!Z(e,!0))return e||"/";const[o,...n]=e.split("?");return(o.slice(0,-1)||"/")+(n.length?`?${n.join("?")}`:"")}function Ge(e="",t=!1){if(!t)return e.endsWith("/")?e:e+"/";if(Z(e,!0))return e||"/";const[o,...n]=e.split("?");return o+"/"+(n.length?`?${n.join("?")}`:"")}const Xe=typeof window!="undefined";function pe(e,t){typeof console!="undefined"&&(console.warn("[vue-i18n-routing] "+e),t&&console.warn(t.stack))}function Le(e){e=e||[];const t=[];for(const o of e)y(o)?t.push({code:o}):t.push(o);return t}function N(e){return e!=null&&"global"in e&&"mode"in e}function w(e){return e!=null&&!("__composer"in e)&&d.isRef(e.locale)}function b(e){return e!=null&&"__composer"in e}function H(e){return e!=null&&!("__composer"in e)&&!d.isRef(e.locale)}function P(e){return e!=null&&("__VUE_I18N_BRIDGE__"in e||"_sync"in e)}function Re(e){return N(e)?w(e.global)?e.global:e.global.__composer:b(e)?e.__composer:e}function q(e){const t=N(e)?e.global:e;return w(t)?d.isVue2&&P(e)?e.locale:t.locale.value:(H(t)||b(t)||P(t),t.locale)}function Me(e){const t=N(e)?e.global:e;return w(t)?d.isVue2&&P(e)?e.locales:t.locales.value:(H(t)||b(t)||P(t),t.locales)}function ge(e,t){const o=N(e)?e.global:e;if(w(o))d.isVue2&&P(e)?e.locale=t:o.locale.value=t;else if(H(o)||b(o)||P(o))o.locale=t;else throw new Error("TODO:")}function ke(e,t,o){return e.replace(/\/+$/,"")+(t?"/":"")||(o?"":"/")}function he(e){return p.isVueRouter4,d.isRef(e)?e.value:e}function _e(e){return y(e)?e:Ve(e)?e.toString():"(null)"}function me(e,t,{defaultLocale:o,strategy:n,routesNameSeparator:a,defaultLocaleRouteNameSuffix:l}){let s=_e(e)+(n==="no_prefix"?"":a+t);return t===o&&n==="prefix_and_default"&&(s+=a+l),s}function Ee(e,t){return we(e)?e(t):e}function ze(e,t){const o=[];for(const[n,a]of t.entries()){const l=e.find(s=>s.iso.toLowerCase()===a.toLowerCase());if(l){o.push({code:l.code,score:1-n/t.length});break}}for(const[n,a]of t.entries()){const l=a.split("-")[0].toLowerCase(),s=e.find(r=>r.iso.split("-")[0].toLowerCase()===l);if(s){o.push({code:s.code,score:.999-n/t.length});break}}return o}const He=ze;function qe(e,t){return e.score===t.score?t.code.length-e.code.length:t.score-e.score}const We=qe;function Qe(e,t,{matcher:o=He,comparer:n=We}={}){const a=[];for(const s of e){const{code:r}=s,c=s.iso||r;a.push({code:r,iso:c})}const l=o(a,t);return l.length>1&&l.sort(n),l.length?l[0].code:""}function A(e){return function(){return Reflect.apply(e,{getRouteBaseName:this.getRouteBaseName,localePath:this.localePath,localeRoute:this.localeRoute,localeLocation:this.localeLocation,resolveRoute:this.resolveRoute,switchLocalePath:this.switchLocalePath,localeHead:this.localeHead,i18n:this.$i18n,route:this.$route,router:this.$router},arguments)}}function Se(e,{locales:t=[],localeCodes:o=[],baseUrl:n=ne,hooks:a={}}={}){const l=d.effectScope(),s=e.install;return e.install=(r,...c)=>{Reflect.apply(s,e,[r,...c]);const u=Re(e);l.run(()=>Ye(u,{locales:t,localeCodes:o,baseUrl:n,hooks:a})),b(e.global)&&Ke(e.global,a.onExtendVueI18n);const f=r,i=e.mode==="composition"?d.isVue3?f.config.globalProperties.$i18n:e:d.isVue2?e:null;if(i&&Je(i,u,a.onExtendExportedGlobal),(Ze(c[0])?c[0]:{inject:!0}).inject&&r.mixin({methods:{resolveRoute:A($),localePath:A(Q),localeRoute:A(Y),localeLocation:A(ae),switchLocalePath:A(U),getRouteBaseName:A(x),localeHead:A(se)}}),f.unmount){const h=f.unmount;f.unmount=()=>{l.stop(),h()}}},l}function Ye(e,t){const{locales:o,localeCodes:n,baseUrl:a}=t,l=d.ref(o),s=d.ref(n);e.locales=d.computed(()=>l.value),e.localeCodes=d.computed(()=>s.value),e.__baseUrl=Ee(a,{}),t.hooks&&t.hooks.onExtendComposer&&t.hooks.onExtendComposer(e)}function Je(e,t,o){const n=[{locales:{get(){return t.locales.value}},localeCodes:{get(){return t.localeCodes.value}},__baseUrl:{get(){return t.__baseUrl}}}];o&&n.push(o(t));for(const a of n)for(const[l,s]of Object.entries(a))Object.defineProperty(e,l,s)}function Ke(e,t){const o=Re(e),n=[{locales:{get(){return o.locales.value}},localeCodes:{get(){return o.localeCodes.value}},__baseUrl:{get(){return o.__baseUrl}}}];t&&n.push(t(o));for(const a of n)for(const[l,s]of Object.entries(a))Object.defineProperty(e,l,s)}function Ze(e){return le(e)&&"inject"in e&&$e(e.inject)}function ve(e,{defaultLocale:t=G,strategy:o=X,trailingSlash:n=M,routesNameSeparator:a=k,defaultLocaleRouteNameSuffix:l=z,includeUprefixedFallback:s=!1,optionsResolver:r=void 0,locales:c=[]}={}){if(o==="no_prefix")return e;const u=c.map(i=>y(i)?i:i.code);function f(i,m,h=!1,E=!1){if(i.redirect&&(!i.component||!i.file))return[i];let R=null;if(r!=null&&(R=r(i,m),R==null))return[i];const g={locales:u,paths:{}};if(R!=null&&j(g,R),j(g,{locales:m}),g.locales.length>0&&R&&R.locales!=null&&R.locales.length>0){const _=[];for(const L of g.locales)R.locales.includes(L)&&_.push(L);g.locales=_}return g.locales.reduce((_,L)=>{const{name:C}=i;let{path:S}=i;const v=T({},i);C&&(v.name=`${C}${a}${L}`),i.children&&(v.children=i.children.reduce((I,K)=>[...I,...f(K,[L],!0,E)],[])),g.paths&&g.paths[L]&&(S=g.paths[L]);const D=L===t;if(D&&o==="prefix_and_default")if(h)h&&E&&C&&(v.name+=`${a}${l}`);else{const I=B(T({},v),{path:S});if(C&&(I.name=`${v.name}${a}${l}`),i.children){I.children=[];for(const K of i.children)I.children=I.children.concat(f(K,[L],!0,!0))}_.push(I)}const re=h&&!S.startsWith("/"),ce=!re&&!(D&&o==="prefix_except_default");return ce&&(S=`/${L}${S}`),S&&(S=ke(S,n,re)),ce&&D&&o==="prefix"&&s&&_.push(T({},i)),v.path=S,_.push(v),_},[])}return e.reduce((i,m)=>[...i,...f(m,u||[])],[])}const ee=Fe("vue-i18n-routing-gor");function Ae(e,t){e[ee]?pe("already registered global options"):e[ee]=t}function Ie(e){var t;return(t=e[ee])!=null?t:{}}function et(e,t={}){const{version:o,defaultLocale:n,locales:a,strategy:l,trailingSlash:s,routesNameSeparator:r,defaultLocaleRouteNameSuffix:c,defaultDirection:u,baseUrl:f,routes:i,routeOptionsResolver:m}=ot(t),h=Le(a),E=h.map(L=>L.code),R=ye(E,r,c);Se(e,{locales:h,baseUrl:f,localeCodes:E});const g=ve(i,{locales:a,defaultLocale:n,strategy:l,trailingSlash:s,routesNameSeparator:r,defaultLocaleRouteNameSuffix:c,optionsResolver:m});t.routes=g;const _=tt(t,o);return Ae(_,{defaultLocale:n,localeCodes:E,strategy:l,trailingSlash:s,routesNameSeparator:r,defaultLocaleRouteNameSuffix:c,defaultDirection:u}),_.beforeEach((L,C,S)=>{const v=q(e),D=R(L)||v||n||"";v!==D&&ge(e,D),S()}),_}function tt(e,t){if(d.isVue3&&t===4)return p.createRouter(e);if(d.isVue2&&t===3)return new Ce.default(e);throw new Error("TODO:")}function Te(e){return new RegExp(`^/(${e.join("|")})(?:/|$)`,"i")}function ye(e,t,o){const n=`(${e.join("|")})`,a=`(?:${t}${o})?`,l=new RegExp(`${t}${n}${a}$`,"i"),s=Te(e);return c=>{if(le(c)){if(c.name){const f=(y(c.name)?c.name:c.name.toString()).match(l);if(f&&f.length>1)return f[1]}else if(c.path){const u=c.path.match(s);if(u&&u.length>1)return u[1]}}else if(y(c)){const u=c.match(s);if(u&&u.length>1)return u[1]}return""}}function ot(e){var t,o,n,a,l,s,r,c,u,f;return e.version=(t=e.version)!=null?t:4,e.defaultLocale=(o=e.defaultLocale)!=null?o:G,e.strategy=(n=e.strategy)!=null?n:X,e.trailingSlash=(a=e.trailingSlash)!=null?a:M,e.routesNameSeparator=(l=e.routesNameSeparator)!=null?l:k,e.defaultLocaleRouteNameSuffix=(s=e.defaultLocaleRouteNameSuffix)!=null?s:z,e.locales=(r=e.locales)!=null?r:[],e.defaultDirection=(c=e.defaultDirection)!=null?c:oe,e.baseUrl=(u=e.baseUrl)!=null?u:ne,e.routes=(f=e.routes)!=null?f:[],e}function W(e,t,{defaultLocale:o=G,defaultDirection:n=oe,defaultLocaleRouteNameSuffix:a=z,routesNameSeparator:l=k,strategy:s=X,trailingSlash:r=M,localeCodes:c=[]}={}){const u=Ie(e);return{defaultLocale:t.defaultLocale||u.defaultLocale||o,defaultDirection:t.defaultDirection||u.defaultDirection||n,defaultLocaleRouteNameSuffix:t.defaultLocaleRouteNameSuffix||u.defaultLocaleRouteNameSuffix||a,routesNameSeparator:t.routesNameSeparator||u.routesNameSeparator||l,strategy:t.strategy||u.strategy||s,trailingSlash:t.trailingSlash||u.trailingSlash||r,localeCodes:t.localeCodes||u.localeCodes||c}}const nt=new Set([O.PREFIX_AND_DEFAULT,O.PREFIX_EXCEPT_DEFAULT]);function x(e){const t=this.router,{routesNameSeparator:o}=W(t,this),n=e!=null?d.isRef(e)?d.unref(e):e:this.route;return n.name?_e(n.name).split(o)[0]:void 0}function Q(e,t){const o=$.call(this,e,t);return o==null?"":d.isVue3?o.redirectedFrom||o.fullPath:o.route.redirectedFrom||o.route.fullPath}function Y(e,t){const o=$.call(this,e,t);return o==null?void 0:d.isVue3?o:o.route}function ae(e,t){const o=$.call(this,e,t);return o==null?void 0:d.isVue3?o:o.location}function $(e,t){const o=this.router,n=this.i18n,a=t||q(n),{routesNameSeparator:l,defaultLocale:s,defaultLocaleRouteNameSuffix:r,strategy:c,trailingSlash:u}=W(o,this);let f=e;y(e)&&(f[0]==="/"?f={path:e}:f={name:e});let i=j({},f);if(i.path&&!i.name){const h=o.resolve(i),E=d.isVue3?h:h.route,R=x.call(this,E);y(R)?i={name:me(R,a,{defaultLocale:s,strategy:c,routesNameSeparator:l,defaultLocaleRouteNameSuffix:r}),params:E.params,query:E.query,hash:E.hash}:(!(a===s&&nt.has(c))&&c!==O.NO_PREFIX&&(i.path=`/${a}${i.path}`),i.path=u?Ge(i.path,!0):je(i.path,!0))}else{i.name=me(i.name,a,{defaultLocale:s,strategy:c,routesNameSeparator:l,defaultLocaleRouteNameSuffix:r});const{params:h}=i;h&&h["0"]===void 0&&h.pathMatch&&(h["0"]=h.pathMatch)}const m=o.resolve(i);return(d.isVue3?m.name:m.route.name)?m:o.resolve(e)}function U(e){const t=this.route,o=x.call(this,t);if(!o)return"";const c=!d.isVue3&&d.isRef(t)?t.value:t,{params:n}=c,a=de(c,["params"]),l={},s=j({},a,{name:o,params:B(T(T({},n),l),{0:n.pathMatch})});return Q.call(this,s,e)}function se({addDirAttribute:e=!1,addSeoAttributes:t=!1}={}){const o=this.router,n=this.i18n,{defaultDirection:a}=W(o,this),l={htmlAttrs:{},link:[],meta:[]};if(n.locales==null||n.__baseUrl==null)return l;const s=q(n),r=Me(n),c=Le(r).find(i=>i.code===s)||{code:s},u=c.iso,f=c.dir||a;return e&&(l.htmlAttrs.dir=f),t&&s&&n.locales&&(u&&(l.htmlAttrs.lang=u),lt.call(this,r,n.__baseUrl,l.link),at.call(this,n.__baseUrl,l.link,t),st(c,u,l.meta),rt(r,u,l.meta)),l}function lt(e,t,o){const n=this.router,{defaultLocale:a,strategy:l}=W(n,this);if(l===O.NO_PREFIX)return;const s=new Map;for(const r of e){const c=r.iso;if(!c){pe("Locale ISO code is required to generate alternate link");continue}const[u,f]=c.split("-");u&&f&&(r.isCatchallLocale||!s.has(u))&&s.set(u,r),s.set(c,r)}for(const[r,c]of s.entries()){const u=U.call(this,c.code);u&&o.push({hid:`i18n-alt-${r}`,rel:"alternate",href:te(u,t),hreflang:r})}if(a){const r=U.call(this,a);r&&o.push({hid:"i18n-xd",rel:"alternate",href:te(r,t),hreflang:"x-default"})}}function at(e,t,o){const n=this.route,a=Y.call(this,B(T({},n),{name:x.call(this,n)}));if(a){let l=te(a.path,e);const s=le(o)&&o.canonicalQueries||[];if(s.length){const r=a.query,c=new URLSearchParams;for(const f of s)if(f in r){const i=r[f];Ne(i)?i.forEach(m=>c.append(f,m||"")):c.append(f,i||"")}const u=c.toString();u&&(l=`${l}?${u}`)}t.push({hid:"i18n-can",rel:"canonical",href:l})}}function st(e,t,o){!(e&&t)||o.push({hid:"i18n-og",property:"og:locale",content:Pe(t)})}function rt(e,t,o){const n=e.filter(a=>{const l=a.iso;return l&&l!==t});if(n.length){const a=n.map(l=>({hid:`i18n-og-alt-${l.iso}`,property:"og:locale:alternate",content:Pe(l.iso)}));o.push(...a)}}function Pe(e){return(e||"").replace(/-/g,"_")}function te(e,t){return e.match(/^https?:\/\//)?e:t+e}function J(e,t){const{router:o,route:n,i18n:a,defaultLocale:l,strategy:s,defaultLocaleRouteNameSuffix:r,trailingSlash:c,routesNameSeparator:u}=e;return function(...f){return Reflect.apply(t,{router:o,route:n,i18n:a,defaultLocale:l,strategy:s,defaultLocaleRouteNameSuffix:r,trailingSlash:c,routesNameSeparator:u},f)}}function ct(e=p.useRoute(),{router:t=p.useRouter(),routesNameSeparator:o=void 0}={}){const n={router:t,route:e,routesNameSeparator:o};return x.call(n,e)}function it({router:e=p.useRouter(),route:t=p.useRoute(),i18n:o=F.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:a=void 0,routesNameSeparator:l=void 0,strategy:s=void 0,trailingSlash:r=void 0}={}){return J({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:a,routesNameSeparator:l,strategy:s,trailingSlash:r},Q)}function ut({router:e=p.useRouter(),route:t=p.useRoute(),i18n:o=F.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:a=void 0,routesNameSeparator:l=void 0,strategy:s=void 0,trailingSlash:r=void 0}={}){return J({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:a,routesNameSeparator:l,strategy:s,trailingSlash:r},Y)}function ft({router:e=p.useRouter(),route:t=p.useRoute(),i18n:o=F.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:a=void 0,routesNameSeparator:l=void 0,strategy:s=void 0,trailingSlash:r=void 0}={}){return J({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:a,routesNameSeparator:l,strategy:s,trailingSlash:r},ae)}function dt({router:e=p.useRouter(),route:t=p.useRoute(),i18n:o=F.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:a=void 0,routesNameSeparator:l=void 0,strategy:s=void 0,trailingSlash:r=void 0}={}){return J({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:a,routesNameSeparator:l,strategy:s,trailingSlash:r},U)}function ht({addDirAttribute:e=!1,addSeoAttributes:t=!1,strategy:o=void 0,defaultLocale:n=void 0,route:a=p.useRoute(),router:l=p.useRouter(),i18n:s=F.useI18n()}={}){const r=l,c=d.ref({htmlAttrs:{},link:[],meta:[]});function u(){c.value={htmlAttrs:{},link:[],meta:[]}}function f(i){c.value=Reflect.apply(se,{router:l,route:i,i18n:s,defaultLocale:n,strategy:o},[{addDirAttribute:e,addSeoAttributes:t}])}if(Xe)if(d.isVue3){const i=d.watchEffect(()=>{u(),f(he(r.currentRoute))});d.onUnmounted(()=>i())}else{const i=r.afterEach((m,h)=>{u(),f(m)});d.onUnmounted(()=>i()),f(a)}else f(he(r.currentRoute));return c}const mt="0.0.0";exports.DEFAULT_BASE_URL=ne;exports.DEFAULT_DETECTION_DIRECTION=oe;exports.DEFAULT_LOCALE=G;exports.DEFAULT_LOCALE_ROUTE_NAME_SUFFIX=z;exports.DEFAULT_ROUTES_NAME_SEPARATOR=k;exports.DEFAULT_STRATEGY=X;exports.DEFAULT_TRAILING_SLASH=M;exports.STRATEGIES=O;exports.VERSION=mt;exports.createLocaleFromRouteGetter=ye;exports.createRouter=et;exports.extendI18n=Se;exports.findBrowserLocale=Qe;exports.getGlobalOptions=Ie;exports.getLocale=q;exports.getLocalesRegex=Te;exports.getRouteBaseName=x;exports.isComposer=w;exports.isExportedGlobalComposer=H;exports.isI18nInstance=N;exports.isLegacyVueI18n=P;exports.isVueI18n=b;exports.localeHead=se;exports.localeLocation=ae;exports.localePath=Q;exports.localeRoute=Y;exports.localizeRoutes=ve;exports.proxyVueInstance=A;exports.registerGlobalOptions=Ae;exports.resolveBaseUrl=Ee;exports.resolveRoute=$;exports.setLocale=ge;exports.switchLocalePath=U;exports.useLocaleHead=ht;exports.useLocaleLocation=ft;exports.useLocalePath=it;exports.useLocaleRoute=ut;exports.useRouteBaseName=ct;exports.useSwitchLocalePath=dt;
import type { Composer } from '@intlify/vue-i18n-bridge';
import { EffectScope } from 'vue-demi';
import type { ExportedGlobalComposer } from '@intlify/vue-i18n-bridge';
import type { I18n } from '@intlify/vue-i18n-bridge';

@@ -7,7 +8,7 @@ import type { Locale } from '@intlify/vue-i18n-bridge';

import type { Ref } from 'vue-demi';
import type { Route as Route_2 } from '@intlify/vue-router-bridge';
import { Route } from '@intlify/vue-router-bridge';
import type { RouteConfig } from '@intlify/vue-router-bridge';
import type { RouteLocation } from '@intlify/vue-router-bridge';
import type { RouteLocationNormalized } from '@intlify/vue-router-bridge';
import type { RouteLocationNormalizedLoaded } from '@intlify/vue-router-bridge';
import { RouteLocationNormalized } from '@intlify/vue-router-bridge';
import { RouteLocationNormalizedLoaded } from '@intlify/vue-router-bridge';
import type { RouteLocationRaw } from '@intlify/vue-router-bridge';

@@ -73,3 +74,3 @@ import type { Router } from '@intlify/vue-router-bridge';

export declare function createLocaleFromRouteGetter(localeCodes: string[], routesNameSeparator: string, defaultLocaleRouteNameSuffix: string): (route: Route_2 | RouteLocationNormalizedLoaded | RouteLocationNormalized | string) => string;
export declare function createLocaleFromRouteGetter(localeCodes: string[], routesNameSeparator: string, defaultLocaleRouteNameSuffix: string): (route: Route | RouteLocationNormalizedLoaded | RouteLocationNormalized | string) => string;

@@ -95,2 +96,16 @@ /**

export declare const DEFAULT_BASE_URL = "";
export declare const DEFAULT_DETECTION_DIRECTION = "ltr";
export declare const DEFAULT_LOCALE = "";
export declare const DEFAULT_LOCALE_ROUTE_NAME_SUFFIX = "default";
export declare const DEFAULT_ROUTES_NAME_SEPARATOR = "___";
export declare const DEFAULT_STRATEGY: "prefix_except_default";
export declare const DEFAULT_TRAILING_SLASH = false;
/**

@@ -156,4 +171,6 @@ * Direction

export declare function getRouteBaseName(this: RoutingProxy, givenRoute?: Route_2 | RouteLocationNormalizedLoaded): string | undefined;
export declare function getLocalesRegex(localeCodes: string[]): RegExp;
export declare function getRouteBaseName(this: RoutingProxy, givenRoute?: Route | RouteLocationNormalizedLoaded): string | undefined;
export declare type I18nCommonRoutingOptions = Pick<I18nRoutingOptions, 'defaultLocale' | 'strategy' | 'defaultLocaleRouteNameSuffix' | 'trailingSlash' | 'locales' | 'routesNameSeparator'>;

@@ -193,3 +210,3 @@

*/
export declare type I18nRoute = Route & RouteLegacy & {
export declare type I18nRoute = Route_2 & RouteLegacy & {
redirect?: string;

@@ -305,2 +322,12 @@ };

export declare function isComposer(target: any): target is Composer;
export declare function isExportedGlobalComposer(target: any): target is ExportedGlobalComposer;
export declare function isI18nInstance(i18n: any): i18n is I18n;
export declare function isLegacyVueI18n(target: any): target is Pick<VueI18n, 'locale'>;
export declare function isVueI18n(target: any): target is VueI18n;
export declare function localeHead(this: RoutingProxy, { addDirAttribute, addSeoAttributes }?: I18nHeadOptions): I18nHeadMetaInfo;

@@ -349,3 +376,3 @@

export declare function localeRoute(this: RoutingProxy, route: RawLocation | RouteLocationRaw, locale?: Locale): Route_2 | ReturnType<Router['resolve']> | undefined;
export declare function localeRoute(this: RoutingProxy, route: RawLocation | RouteLocationRaw, locale?: Locale): Route | ReturnType<Router['resolve']> | undefined;

@@ -362,3 +389,3 @@ /**

*/
export declare type LocaleRouteFunction = (route: RawLocation | RouteLocationRaw, locale?: Locale) => Route_2 | ReturnType<Router['resolve']> | undefined;
export declare type LocaleRouteFunction = (route: RawLocation | RouteLocationRaw, locale?: Locale) => Route | ReturnType<Router['resolve']> | undefined;

@@ -404,14 +431,16 @@ /**

export { Route }
declare type _Route = UnionToIntersection<RouteConfig>;
/**
* Route config for vue-router v4
*/
export declare interface Route {
declare interface Route_2 {
name?: string;
path: string;
file?: string;
children?: Route[];
children?: Route_2[];
}
declare type _Route = UnionToIntersection<RouteConfig>;
/**

@@ -427,6 +456,10 @@ * Route config for lagacy vue-router v3

export { RouteLocationNormalized }
export { RouteLocationNormalizedLoaded }
/**
* Resolver for route localizing options
*/
export declare type RouteOptionsResolver = (route: I18nRoute, allowedLocaleCodes: string[]) => ComputedRouteOptions | null;
export declare type RouteOptionsResolver = (route: I18nRoute, localeCodes: string[]) => ComputedRouteOptions | null;

@@ -445,3 +478,3 @@ /**

localeHead: any;
route: Route_2 | RouteLocationNormalizedLoaded;
route: Route | RouteLocationNormalizedLoaded;
router: Router | VueRouter;

@@ -477,3 +510,3 @@ defaultLocale?: string;

declare const STRATEGIES: {
export declare const STRATEGIES: {
readonly PREFIX: "prefix";

@@ -557,3 +590,3 @@ readonly PREFIX_EXCEPT_DEFAULT: "prefix_except_default";

*/
export declare function useRouteBaseName(givenRoute?: Route_2 | RouteLocationNormalizedLoaded, { router, routesNameSeparator }?: I18nCommonRoutingOptionsWithComposable): string | undefined;
export declare function useRouteBaseName(givenRoute?: Route | RouteLocationNormalizedLoaded, { router, routesNameSeparator }?: I18nCommonRoutingOptionsWithComposable): string | undefined;

@@ -560,0 +593,0 @@ /**

@@ -35,2 +35,15 @@ var __defProp = Object.defineProperty;

import { useI18n } from "@intlify/vue-i18n-bridge";
const STRATEGIES = {
PREFIX: "prefix",
PREFIX_EXCEPT_DEFAULT: "prefix_except_default",
PREFIX_AND_DEFAULT: "prefix_and_default",
NO_PREFIX: "no_prefix"
};
const DEFAULT_LOCALE = "";
const DEFAULT_STRATEGY = STRATEGIES.PREFIX_EXCEPT_DEFAULT;
const DEFAULT_TRAILING_SLASH = false;
const DEFAULT_ROUTES_NAME_SEPARATOR = "___";
const DEFAULT_LOCALE_ROUTE_NAME_SUFFIX = "default";
const DEFAULT_DETECTION_DIRECTION = "ltr";
const DEFAULT_BASE_URL = "";
/*!

@@ -205,15 +218,2 @@ * shared v9.2.0-beta.35

}
const STRATEGIES = {
PREFIX: "prefix",
PREFIX_EXCEPT_DEFAULT: "prefix_except_default",
PREFIX_AND_DEFAULT: "prefix_and_default",
NO_PREFIX: "no_prefix"
};
const DEFAULT_LOCALE = "";
const DEFAULT_STRATEGY = STRATEGIES.PREFIX_EXCEPT_DEFAULT;
const DEFAULT_TRAILING_SLASH = false;
const DEFAULT_ROUTES_NAME_SEPARATOR = "___";
const DEFAULT_LOCALE_ROUTE_NAME_SUFFIX = "default";
const DEFAULT_DETECTION_DIRECTION = "ltr";
const DEFAULT_BASE_URL = "";
function proxyVueInstance(target) {

@@ -368,4 +368,20 @@ return function() {

}
const targetLocales = allowedLocaleCodes;
return targetLocales.reduce((_routes, locale) => {
const componentOptions = {
locales: _localeCodes,
paths: {}
};
if (routeOptions != null) {
assign(componentOptions, routeOptions);
}
assign(componentOptions, { locales: allowedLocaleCodes });
if (componentOptions.locales.length > 0 && routeOptions && routeOptions.locales != null && routeOptions.locales.length > 0) {
const filteredLocales = [];
for (const locale of componentOptions.locales) {
if (routeOptions.locales.includes(locale)) {
filteredLocales.push(locale);
}
}
componentOptions.locales = filteredLocales;
}
return componentOptions.locales.reduce((_routes, locale) => {
const { name } = route;

@@ -380,2 +396,5 @@ let { path } = route;

}
if (componentOptions.paths && componentOptions.paths[locale]) {
path = componentOptions.paths[locale];
}
const isDefaultLocale = locale === defaultLocale;

@@ -950,2 +969,2 @@ if (isDefaultLocale && strategy === "prefix_and_default") {

const VERSION = "0.0.0";
export { VERSION, createLocaleFromRouteGetter, createRouter, extendI18n, findBrowserLocale, getGlobalOptions, getLocale, getRouteBaseName, localeHead, localeLocation, localePath, localeRoute, localizeRoutes, proxyVueInstance, registerGlobalOptions, resolveBaseUrl, resolveRoute, setLocale, switchLocalePath, useLocaleHead, useLocaleLocation, useLocalePath, useLocaleRoute, useRouteBaseName, useSwitchLocalePath };
export { DEFAULT_BASE_URL, DEFAULT_DETECTION_DIRECTION, DEFAULT_LOCALE, DEFAULT_LOCALE_ROUTE_NAME_SUFFIX, DEFAULT_ROUTES_NAME_SEPARATOR, DEFAULT_STRATEGY, DEFAULT_TRAILING_SLASH, STRATEGIES, VERSION, createLocaleFromRouteGetter, createRouter, extendI18n, findBrowserLocale, getGlobalOptions, getLocale, getLocalesRegex, getRouteBaseName, isComposer, isExportedGlobalComposer, isI18nInstance, isLegacyVueI18n, isVueI18n, localeHead, localeLocation, localePath, localeRoute, localizeRoutes, proxyVueInstance, registerGlobalOptions, resolveBaseUrl, resolveRoute, setLocale, switchLocalePath, useLocaleHead, useLocaleLocation, useLocalePath, useLocaleRoute, useRouteBaseName, useSwitchLocalePath };

@@ -1,5 +0,5 @@

var ht=Object.defineProperty,Lt=Object.defineProperties;var gt=Object.getOwnPropertyDescriptors;var M=Object.getOwnPropertySymbols;var be=Object.prototype.hasOwnProperty,Ae=Object.prototype.propertyIsEnumerable;var Ie=(d,f,L)=>f in d?ht(d,f,{enumerable:!0,configurable:!0,writable:!0,value:L}):d[f]=L,C=(d,f)=>{for(var L in f||(f={}))be.call(f,L)&&Ie(d,L,f[L]);if(M)for(var L of M(f))Ae.call(f,L)&&Ie(d,L,f[L]);return d},z=(d,f)=>Lt(d,gt(f));var Ce=(d,f)=>{var L={};for(var m in d)be.call(d,m)&&f.indexOf(m)<0&&(L[m]=d[m]);if(d!=null&&M)for(var m of M(d))f.indexOf(m)<0&&Ae.call(d,m)&&(L[m]=d[m]);return L};var VueI18nRouting=function(d,f,L,m){"use strict";function Oe(e){return e&&typeof e=="object"&&"default"in e?e:{default:e}}var we=Oe(L);/*!
var VueI18nRouting=function(s,d,L,_){"use strict";var ht=Object.defineProperty,Lt=Object.defineProperties;var gt=Object.getOwnPropertyDescriptors;var J=Object.getOwnPropertySymbols;var ye=Object.prototype.hasOwnProperty,Oe=Object.prototype.propertyIsEnumerable;var Pe=(s,d,L)=>d in s?ht(s,d,{enumerable:!0,configurable:!0,writable:!0,value:L}):s[d]=L,U=(s,d)=>{for(var L in d||(d={}))ye.call(d,L)&&Pe(s,L,d[L]);if(J)for(var L of J(d))Oe.call(d,L)&&Pe(s,L,d[L]);return s},K=(s,d)=>Lt(s,gt(d));var Ce=(s,d)=>{var L={};for(var _ in s)ye.call(s,_)&&d.indexOf(_)<0&&(L[_]=s[_]);if(s!=null&&J)for(var _ of J(s))d.indexOf(_)<0&&Oe.call(s,_)&&(L[_]=s[_]);return L};function Ue(e){return e&&typeof e=="object"&&"default"in e?e:{default:e}}var be=Ue(L);const b={PREFIX:"prefix",PREFIX_EXCEPT_DEFAULT:"prefix_except_default",PREFIX_AND_DEFAULT:"prefix_and_default",NO_PREFIX:"no_prefix"},D="",B=b.PREFIX_EXCEPT_DEFAULT,X=!1,M="___",k="default",Z="ltr",ee="";/*!
* shared v9.2.0-beta.35
* (c) 2022 kazuya kawaguchi
* Released under the MIT License.
*/const Ne=typeof Symbol=="function"&&typeof Symbol.toStringTag=="symbol",Te=e=>Ne?Symbol(e):e,le=Object.assign,Fe=Array.isArray,Ue=e=>typeof e=="function",I=e=>typeof e=="string",$e=e=>typeof e=="boolean",ve=e=>typeof e=="symbol",H=e=>e!==null&&typeof e=="object",je=/\/$|\/\?/;function D(e="",t=!1){return t?je.test(e):e.endsWith("/")}function Ve(e="",t=!1){if(!t)return(D(e)?e.slice(0,-1):e)||"/";if(!D(e,!0))return e||"/";const[o,...n]=e.split("?");return(o.slice(0,-1)||"/")+(n.length?`?${n.join("?")}`:"")}function xe(e="",t=!1){if(!t)return e.endsWith("/")?e:e+"/";if(D(e,!0))return e||"/";const[o,...n]=e.split("?");return o+"/"+(n.length?`?${n.join("?")}`:"")}const Be=typeof window!="undefined";function ce(e,t){typeof console!="undefined"&&(console.warn("[vue-i18n-routing] "+e),t&&console.warn(t.stack))}function se(e){e=e||[];const t=[];for(const o of e)I(o)?t.push({code:o}):t.push(o);return t}function j(e){return e!=null&&"global"in e&&"mode"in e}function V(e){return e!=null&&!("__composer"in e)&&f.isRef(e.locale)}function T(e){return e!=null&&"__composer"in e}function q(e){return e!=null&&!("__composer"in e)&&!f.isRef(e.locale)}function O(e){return e!=null&&("__VUE_I18N_BRIDGE__"in e||"_sync"in e)}function re(e){return j(e)?V(e.global)?e.global:e.global.__composer:T(e)?e.__composer:e}function x(e){const t=j(e)?e.global:e;return V(t)?f.isVue2&&O(e)?e.locale:t.locale.value:(q(t)||T(t)||O(t),t.locale)}function Ge(e){const t=j(e)?e.global:e;return V(t)?f.isVue2&&O(e)?e.locales:t.locales.value:(q(t)||T(t)||O(t),t.locales)}function ie(e,t){const o=j(e)?e.global:e;if(V(o))f.isVue2&&O(e)?e.locale=t:o.locale.value=t;else if(q(o)||T(o)||O(o))o.locale=t;else throw new Error("TODO:")}function Xe(e,t,o){return e.replace(/\/+$/,"")+(t?"/":"")||(o?"":"/")}function ue(e){return L.isVueRouter4,f.isRef(e)?e.value:e}function fe(e){return I(e)?e:ve(e)?e.toString():"(null)"}function de(e,t,{defaultLocale:o,strategy:n,routesNameSeparator:l,defaultLocaleRouteNameSuffix:a}){let c=fe(e)+(n==="no_prefix"?"":l+t);return t===o&&n==="prefix_and_default"&&(c+=l+a),c}function he(e,t){return Ue(e)?e(t):e}function ke(e,t){const o=[];for(const[n,l]of t.entries()){const a=e.find(c=>c.iso.toLowerCase()===l.toLowerCase());if(a){o.push({code:a.code,score:1-n/t.length});break}}for(const[n,l]of t.entries()){const a=l.split("-")[0].toLowerCase(),c=e.find(s=>s.iso.split("-")[0].toLowerCase()===a);if(c){o.push({code:c.code,score:.999-n/t.length});break}}return o}const Me=ke;function ze(e,t){return e.score===t.score?t.code.length-e.code.length:t.score-e.score}const He=ze;function De(e,t,{matcher:o=Me,comparer:n=He}={}){const l=[];for(const c of e){const{code:s}=c,r=c.iso||s;l.push({code:s,iso:r})}const a=o(l,t);return a.length>1&&a.sort(n),a.length?a[0].code:""}const F={PREFIX:"prefix",PREFIX_EXCEPT_DEFAULT:"prefix_except_default",PREFIX_AND_DEFAULT:"prefix_and_default",NO_PREFIX:"no_prefix"},W="",Q=F.PREFIX_EXCEPT_DEFAULT,Y=!1,J="___",K="default",Le="ltr",ge="";function y(e){return function(){return Reflect.apply(e,{getRouteBaseName:this.getRouteBaseName,localePath:this.localePath,localeRoute:this.localeRoute,localeLocation:this.localeLocation,resolveRoute:this.resolveRoute,switchLocalePath:this.switchLocalePath,localeHead:this.localeHead,i18n:this.$i18n,route:this.$route,router:this.$router},arguments)}}function me(e,{locales:t=[],localeCodes:o=[],baseUrl:n=ge,hooks:l={}}={}){const a=f.effectScope(),c=e.install;return e.install=(s,...r)=>{Reflect.apply(c,e,[s,...r]);const u=re(e);a.run(()=>qe(u,{locales:t,localeCodes:o,baseUrl:n,hooks:l})),T(e.global)&&Qe(e.global,l.onExtendVueI18n);const h=s,i=e.mode==="composition"?f.isVue3?h.config.globalProperties.$i18n:e:f.isVue2?e:null;if(i&&We(i,u,l.onExtendExportedGlobal),(Ye(r[0])?r[0]:{inject:!0}).inject&&s.mixin({methods:{resolveRoute:y(U),localePath:y(G),localeRoute:y(X),localeLocation:y(ee),switchLocalePath:y($),getRouteBaseName:y(w),localeHead:y(te)}}),h.unmount){const g=h.unmount;h.unmount=()=>{a.stop(),g()}}},a}function qe(e,t){const{locales:o,localeCodes:n,baseUrl:l}=t,a=f.ref(o),c=f.ref(n);e.locales=f.computed(()=>a.value),e.localeCodes=f.computed(()=>c.value),e.__baseUrl=he(l,{}),t.hooks&&t.hooks.onExtendComposer&&t.hooks.onExtendComposer(e)}function We(e,t,o){const n=[{locales:{get(){return t.locales.value}},localeCodes:{get(){return t.localeCodes.value}},__baseUrl:{get(){return t.__baseUrl}}}];o&&n.push(o(t));for(const l of n)for(const[a,c]of Object.entries(l))Object.defineProperty(e,a,c)}function Qe(e,t){const o=re(e),n=[{locales:{get(){return o.locales.value}},localeCodes:{get(){return o.localeCodes.value}},__baseUrl:{get(){return o.__baseUrl}}}];t&&n.push(t(o));for(const l of n)for(const[a,c]of Object.entries(l))Object.defineProperty(e,a,c)}function Ye(e){return H(e)&&"inject"in e&&$e(e.inject)}function pe(e,{defaultLocale:t=W,strategy:o=Q,trailingSlash:n=Y,routesNameSeparator:l=J,defaultLocaleRouteNameSuffix:a=K,includeUprefixedFallback:c=!1,optionsResolver:s=void 0,locales:r=[]}={}){if(o==="no_prefix")return e;const u=r.map(i=>I(i)?i:i.code);function h(i,p,g=!1,R=!1){if(i.redirect&&(!i.component||!i.file))return[i];let b=null;return s!=null&&(b=s(i,p),b==null)?[i]:p.reduce((S,P)=>{const{name:v}=i;let{path:_}=i;const E=C({},i);v&&(E.name=`${v}${l}${P}`),i.children&&(E.children=i.children.reduce((A,ae)=>[...A,...h(ae,[P],!0,R)],[]));const N=P===t;if(N&&o==="prefix_and_default")if(g)g&&R&&v&&(E.name+=`${l}${a}`);else{const A=z(C({},E),{path:_});if(v&&(A.name=`${E.name}${l}${a}`),i.children){A.children=[];for(const ae of i.children)A.children=A.children.concat(h(ae,[P],!0,!0))}S.push(A)}const Pe=g&&!_.startsWith("/"),ye=!Pe&&!(N&&o==="prefix_except_default");return ye&&(_=`/${P}${_}`),_&&(_=Xe(_,n,Pe)),ye&&N&&o==="prefix"&&c&&S.push(C({},i)),E.path=_,S.push(E),S},[])}return e.reduce((i,p)=>[...i,...h(p,u||[])],[])}const Z=Te("vue-i18n-routing-gor");function Re(e,t){e[Z]?ce("already registered global options"):e[Z]=t}function _e(e){var t;return(t=e[Z])!=null?t:{}}function Je(e,t={}){const{version:o,defaultLocale:n,locales:l,strategy:a,trailingSlash:c,routesNameSeparator:s,defaultLocaleRouteNameSuffix:r,defaultDirection:u,baseUrl:h,routes:i,routeOptionsResolver:p}=et(t),g=se(l),R=g.map(P=>P.code),b=Ee(R,s,r);me(e,{locales:g,baseUrl:h,localeCodes:R});const ne=pe(i,{locales:l,defaultLocale:n,strategy:a,trailingSlash:c,routesNameSeparator:s,defaultLocaleRouteNameSuffix:r,optionsResolver:p});t.routes=ne;const S=Ke(t,o);return Re(S,{defaultLocale:n,localeCodes:R,strategy:a,trailingSlash:c,routesNameSeparator:s,defaultLocaleRouteNameSuffix:r,defaultDirection:u}),S.beforeEach((P,v,_)=>{const E=x(e),N=b(P)||E||n||"";E!==N&&ie(e,N),_()}),S}function Ke(e,t){if(f.isVue3&&t===4)return L.createRouter(e);if(f.isVue2&&t===3)return new we.default(e);throw new Error("TODO:")}function Ze(e){return new RegExp(`^/(${e.join("|")})(?:/|$)`,"i")}function Ee(e,t,o){const n=`(${e.join("|")})`,l=`(?:${t}${o})?`,a=new RegExp(`${t}${n}${l}$`,"i"),c=Ze(e);return r=>{if(H(r)){if(r.name){const h=(I(r.name)?r.name:r.name.toString()).match(a);if(h&&h.length>1)return h[1]}else if(r.path){const u=r.path.match(c);if(u&&u.length>1)return u[1]}}else if(I(r)){const u=r.match(c);if(u&&u.length>1)return u[1]}return""}}function et(e){var t,o,n,l,a,c,s,r,u,h;return e.version=(t=e.version)!=null?t:4,e.defaultLocale=(o=e.defaultLocale)!=null?o:W,e.strategy=(n=e.strategy)!=null?n:Q,e.trailingSlash=(l=e.trailingSlash)!=null?l:Y,e.routesNameSeparator=(a=e.routesNameSeparator)!=null?a:J,e.defaultLocaleRouteNameSuffix=(c=e.defaultLocaleRouteNameSuffix)!=null?c:K,e.locales=(s=e.locales)!=null?s:[],e.defaultDirection=(r=e.defaultDirection)!=null?r:Le,e.baseUrl=(u=e.baseUrl)!=null?u:ge,e.routes=(h=e.routes)!=null?h:[],e}function B(e,t,{defaultLocale:o=W,defaultDirection:n=Le,defaultLocaleRouteNameSuffix:l=K,routesNameSeparator:a=J,strategy:c=Q,trailingSlash:s=Y,localeCodes:r=[]}={}){const u=_e(e);return{defaultLocale:t.defaultLocale||u.defaultLocale||o,defaultDirection:t.defaultDirection||u.defaultDirection||n,defaultLocaleRouteNameSuffix:t.defaultLocaleRouteNameSuffix||u.defaultLocaleRouteNameSuffix||l,routesNameSeparator:t.routesNameSeparator||u.routesNameSeparator||a,strategy:t.strategy||u.strategy||c,trailingSlash:t.trailingSlash||u.trailingSlash||s,localeCodes:t.localeCodes||u.localeCodes||r}}const tt=new Set([F.PREFIX_AND_DEFAULT,F.PREFIX_EXCEPT_DEFAULT]);function w(e){const t=this.router,{routesNameSeparator:o}=B(t,this),n=e!=null?f.isRef(e)?f.unref(e):e:this.route;return n.name?fe(n.name).split(o)[0]:void 0}function G(e,t){const o=U.call(this,e,t);return o==null?"":f.isVue3?o.redirectedFrom||o.fullPath:o.route.redirectedFrom||o.route.fullPath}function X(e,t){const o=U.call(this,e,t);return o==null?void 0:f.isVue3?o:o.route}function ee(e,t){const o=U.call(this,e,t);return o==null?void 0:f.isVue3?o:o.location}function U(e,t){const o=this.router,n=this.i18n,l=t||x(n),{routesNameSeparator:a,defaultLocale:c,defaultLocaleRouteNameSuffix:s,strategy:r,trailingSlash:u}=B(o,this);let h=e;I(e)&&(h[0]==="/"?h={path:e}:h={name:e});let i=le({},h);if(i.path&&!i.name){const g=o.resolve(i),R=f.isVue3?g:g.route,b=w.call(this,R);I(b)?i={name:de(b,l,{defaultLocale:c,strategy:r,routesNameSeparator:a,defaultLocaleRouteNameSuffix:s}),params:R.params,query:R.query,hash:R.hash}:(!(l===c&&tt.has(r))&&r!==F.NO_PREFIX&&(i.path=`/${l}${i.path}`),i.path=u?xe(i.path,!0):Ve(i.path,!0))}else{i.name=de(i.name,l,{defaultLocale:c,strategy:r,routesNameSeparator:a,defaultLocaleRouteNameSuffix:s});const{params:g}=i;g&&g["0"]===void 0&&g.pathMatch&&(g["0"]=g.pathMatch)}const p=o.resolve(i);return(f.isVue3?p.name:p.route.name)?p:o.resolve(e)}function $(e){const t=this.route,o=w.call(this,t);if(!o)return"";const r=!f.isVue3&&f.isRef(t)?t.value:t,{params:n}=r,l=Ce(r,["params"]),a={},c=le({},l,{name:o,params:z(C(C({},n),a),{0:n.pathMatch})});return G.call(this,c,e)}function te({addDirAttribute:e=!1,addSeoAttributes:t=!1}={}){const o=this.router,n=this.i18n,{defaultDirection:l}=B(o,this),a={htmlAttrs:{},link:[],meta:[]};if(n.locales==null||n.__baseUrl==null)return a;const c=x(n),s=Ge(n),r=se(s).find(i=>i.code===c)||{code:c},u=r.iso,h=r.dir||l;return e&&(a.htmlAttrs.dir=h),t&&c&&n.locales&&(u&&(a.htmlAttrs.lang=u),ot.call(this,s,n.__baseUrl,a.link),nt.call(this,n.__baseUrl,a.link,t),at(r,u,a.meta),lt(s,u,a.meta)),a}function ot(e,t,o){const n=this.router,{defaultLocale:l,strategy:a}=B(n,this);if(a===F.NO_PREFIX)return;const c=new Map;for(const s of e){const r=s.iso;if(!r){ce("Locale ISO code is required to generate alternate link");continue}const[u,h]=r.split("-");u&&h&&(s.isCatchallLocale||!c.has(u))&&c.set(u,s),c.set(r,s)}for(const[s,r]of c.entries()){const u=$.call(this,r.code);u&&o.push({hid:`i18n-alt-${s}`,rel:"alternate",href:oe(u,t),hreflang:s})}if(l){const s=$.call(this,l);s&&o.push({hid:"i18n-xd",rel:"alternate",href:oe(s,t),hreflang:"x-default"})}}function nt(e,t,o){const n=this.route,l=X.call(this,z(C({},n),{name:w.call(this,n)}));if(l){let a=oe(l.path,e);const c=H(o)&&o.canonicalQueries||[];if(c.length){const s=l.query,r=new URLSearchParams;for(const h of c)if(h in s){const i=s[h];Fe(i)?i.forEach(p=>r.append(h,p||"")):r.append(h,i||"")}const u=r.toString();u&&(a=`${a}?${u}`)}t.push({hid:"i18n-can",rel:"canonical",href:a})}}function at(e,t,o){!(e&&t)||o.push({hid:"i18n-og",property:"og:locale",content:Se(t)})}function lt(e,t,o){const n=e.filter(l=>{const a=l.iso;return a&&a!==t});if(n.length){const l=n.map(a=>({hid:`i18n-og-alt-${a.iso}`,property:"og:locale:alternate",content:Se(a.iso)}));o.push(...l)}}function Se(e){return(e||"").replace(/-/g,"_")}function oe(e,t){return e.match(/^https?:\/\//)?e:t+e}function k(e,t){const{router:o,route:n,i18n:l,defaultLocale:a,strategy:c,defaultLocaleRouteNameSuffix:s,trailingSlash:r,routesNameSeparator:u}=e;return function(...h){return Reflect.apply(t,{router:o,route:n,i18n:l,defaultLocale:a,strategy:c,defaultLocaleRouteNameSuffix:s,trailingSlash:r,routesNameSeparator:u},h)}}function ct(e=L.useRoute(),{router:t=L.useRouter(),routesNameSeparator:o=void 0}={}){const n={router:t,route:e,routesNameSeparator:o};return w.call(n,e)}function st({router:e=L.useRouter(),route:t=L.useRoute(),i18n:o=m.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:l=void 0,routesNameSeparator:a=void 0,strategy:c=void 0,trailingSlash:s=void 0}={}){return k({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:l,routesNameSeparator:a,strategy:c,trailingSlash:s},G)}function rt({router:e=L.useRouter(),route:t=L.useRoute(),i18n:o=m.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:l=void 0,routesNameSeparator:a=void 0,strategy:c=void 0,trailingSlash:s=void 0}={}){return k({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:l,routesNameSeparator:a,strategy:c,trailingSlash:s},X)}function it({router:e=L.useRouter(),route:t=L.useRoute(),i18n:o=m.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:l=void 0,routesNameSeparator:a=void 0,strategy:c=void 0,trailingSlash:s=void 0}={}){return k({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:l,routesNameSeparator:a,strategy:c,trailingSlash:s},ee)}function ut({router:e=L.useRouter(),route:t=L.useRoute(),i18n:o=m.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:l=void 0,routesNameSeparator:a=void 0,strategy:c=void 0,trailingSlash:s=void 0}={}){return k({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:l,routesNameSeparator:a,strategy:c,trailingSlash:s},$)}function ft({addDirAttribute:e=!1,addSeoAttributes:t=!1,strategy:o=void 0,defaultLocale:n=void 0,route:l=L.useRoute(),router:a=L.useRouter(),i18n:c=m.useI18n()}={}){const s=a,r=f.ref({htmlAttrs:{},link:[],meta:[]});function u(){r.value={htmlAttrs:{},link:[],meta:[]}}function h(i){r.value=Reflect.apply(te,{router:a,route:i,i18n:c,defaultLocale:n,strategy:o},[{addDirAttribute:e,addSeoAttributes:t}])}if(Be)if(f.isVue3){const i=f.watchEffect(()=>{u(),h(ue(s.currentRoute))});f.onUnmounted(()=>i())}else{const i=s.afterEach((p,g)=>{u(),h(p)});f.onUnmounted(()=>i()),h(l)}else h(ue(s.currentRoute));return r}const dt="0.0.0";return d.VERSION=dt,d.createLocaleFromRouteGetter=Ee,d.createRouter=Je,d.extendI18n=me,d.findBrowserLocale=De,d.getGlobalOptions=_e,d.getLocale=x,d.getRouteBaseName=w,d.localeHead=te,d.localeLocation=ee,d.localePath=G,d.localeRoute=X,d.localizeRoutes=pe,d.proxyVueInstance=y,d.registerGlobalOptions=Re,d.resolveBaseUrl=he,d.resolveRoute=U,d.setLocale=ie,d.switchLocalePath=$,d.useLocaleHead=ft,d.useLocaleLocation=it,d.useLocalePath=st,d.useLocaleRoute=rt,d.useRouteBaseName=ct,d.useSwitchLocalePath=ut,Object.defineProperties(d,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}}),d}({},VueDemi,VueRouter,VueI18n);
*/const Fe=typeof Symbol=="function"&&typeof Symbol.toStringTag=="symbol",Ne=e=>Fe?Symbol(e):e,z=Object.assign,we=Array.isArray,$e=e=>typeof e=="function",y=e=>typeof e=="string",ve=e=>typeof e=="boolean",Ve=e=>typeof e=="symbol",te=e=>e!==null&&typeof e=="object",je=/\/$|\/\?/;function oe(e="",t=!1){return t?je.test(e):e.endsWith("/")}function Ge(e="",t=!1){if(!t)return(oe(e)?e.slice(0,-1):e)||"/";if(!oe(e,!0))return e||"/";const[o,...n]=e.split("?");return(o.slice(0,-1)||"/")+(n.length?`?${n.join("?")}`:"")}function De(e="",t=!1){if(!t)return e.endsWith("/")?e:e+"/";if(oe(e,!0))return e||"/";const[o,...n]=e.split("?");return o+"/"+(n.length?`?${n.join("?")}`:"")}const Be=typeof window!="undefined";function re(e,t){typeof console!="undefined"&&(console.warn("[vue-i18n-routing] "+e),t&&console.warn(t.stack))}function ie(e){e=e||[];const t=[];for(const o of e)y(o)?t.push({code:o}):t.push(o);return t}function $(e){return e!=null&&"global"in e&&"mode"in e}function v(e){return e!=null&&!("__composer"in e)&&d.isRef(e.locale)}function F(e){return e!=null&&"__composer"in e}function H(e){return e!=null&&!("__composer"in e)&&!d.isRef(e.locale)}function O(e){return e!=null&&("__VUE_I18N_BRIDGE__"in e||"_sync"in e)}function ue(e){return $(e)?v(e.global)?e.global:e.global.__composer:F(e)?e.__composer:e}function q(e){const t=$(e)?e.global:e;return v(t)?d.isVue2&&O(e)?e.locale:t.locale.value:(H(t)||F(t)||O(t),t.locale)}function Xe(e){const t=$(e)?e.global:e;return v(t)?d.isVue2&&O(e)?e.locales:t.locales.value:(H(t)||F(t)||O(t),t.locales)}function fe(e,t){const o=$(e)?e.global:e;if(v(o))d.isVue2&&O(e)?e.locale=t:o.locale.value=t;else if(H(o)||F(o)||O(o))o.locale=t;else throw new Error("TODO:")}function Me(e,t,o){return e.replace(/\/+$/,"")+(t?"/":"")||(o?"":"/")}function de(e){return L.isVueRouter4,d.isRef(e)?e.value:e}function he(e){return y(e)?e:Ve(e)?e.toString():"(null)"}function Le(e,t,{defaultLocale:o,strategy:n,routesNameSeparator:a,defaultLocaleRouteNameSuffix:l}){let c=he(e)+(n==="no_prefix"?"":a+t);return t===o&&n==="prefix_and_default"&&(c+=a+l),c}function ge(e,t){return $e(e)?e(t):e}function ke(e,t){const o=[];for(const[n,a]of t.entries()){const l=e.find(c=>c.iso.toLowerCase()===a.toLowerCase());if(l){o.push({code:l.code,score:1-n/t.length});break}}for(const[n,a]of t.entries()){const l=a.split("-")[0].toLowerCase(),c=e.find(r=>r.iso.split("-")[0].toLowerCase()===l);if(c){o.push({code:c.code,score:.999-n/t.length});break}}return o}const ze=ke;function He(e,t){return e.score===t.score?t.code.length-e.code.length:t.score-e.score}const qe=He;function xe(e,t,{matcher:o=ze,comparer:n=qe}={}){const a=[];for(const c of e){const{code:r}=c,i=c.iso||r;a.push({code:r,iso:i})}const l=o(a,t);return l.length>1&&l.sort(n),l.length?l[0].code:""}function P(e){return function(){return Reflect.apply(e,{getRouteBaseName:this.getRouteBaseName,localePath:this.localePath,localeRoute:this.localeRoute,localeLocation:this.localeLocation,resolveRoute:this.resolveRoute,switchLocalePath:this.switchLocalePath,localeHead:this.localeHead,i18n:this.$i18n,route:this.$route,router:this.$router},arguments)}}function _e(e,{locales:t=[],localeCodes:o=[],baseUrl:n=ee,hooks:a={}}={}){const l=d.effectScope(),c=e.install;return e.install=(r,...i)=>{Reflect.apply(c,e,[r,...i]);const f=ue(e);l.run(()=>We(f,{locales:t,localeCodes:o,baseUrl:n,hooks:a})),F(e.global)&&Ye(e.global,a.onExtendVueI18n);const h=r,u=e.mode==="composition"?d.isVue3?h.config.globalProperties.$i18n:e:d.isVue2?e:null;if(u&&Qe(u,f,a.onExtendExportedGlobal),(Je(i[0])?i[0]:{inject:!0}).inject&&r.mixin({methods:{resolveRoute:P(V),localePath:P(W),localeRoute:P(Q),localeLocation:P(le),switchLocalePath:P(j),getRouteBaseName:P(N),localeHead:P(ae)}}),h.unmount){const g=h.unmount;h.unmount=()=>{l.stop(),g()}}},l}function We(e,t){const{locales:o,localeCodes:n,baseUrl:a}=t,l=d.ref(o),c=d.ref(n);e.locales=d.computed(()=>l.value),e.localeCodes=d.computed(()=>c.value),e.__baseUrl=ge(a,{}),t.hooks&&t.hooks.onExtendComposer&&t.hooks.onExtendComposer(e)}function Qe(e,t,o){const n=[{locales:{get(){return t.locales.value}},localeCodes:{get(){return t.localeCodes.value}},__baseUrl:{get(){return t.__baseUrl}}}];o&&n.push(o(t));for(const a of n)for(const[l,c]of Object.entries(a))Object.defineProperty(e,l,c)}function Ye(e,t){const o=ue(e),n=[{locales:{get(){return o.locales.value}},localeCodes:{get(){return o.localeCodes.value}},__baseUrl:{get(){return o.__baseUrl}}}];t&&n.push(t(o));for(const a of n)for(const[l,c]of Object.entries(a))Object.defineProperty(e,l,c)}function Je(e){return te(e)&&"inject"in e&&ve(e.inject)}function me(e,{defaultLocale:t=D,strategy:o=B,trailingSlash:n=X,routesNameSeparator:a=M,defaultLocaleRouteNameSuffix:l=k,includeUprefixedFallback:c=!1,optionsResolver:r=void 0,locales:i=[]}={}){if(o==="no_prefix")return e;const f=i.map(u=>y(u)?u:u.code);function h(u,m,g=!1,A=!1){if(u.redirect&&(!u.component||!u.file))return[u];let p=null;if(r!=null&&(p=r(u,m),p==null))return[u];const E={locales:f,paths:{}};if(p!=null&&z(E,p),z(E,{locales:m}),E.locales.length>0&&p&&p.locales!=null&&p.locales.length>0){const S=[];for(const R of E.locales)p.locales.includes(R)&&S.push(R);E.locales=S}return E.locales.reduce((S,R)=>{const{name:G}=u;let{path:I}=u;const T=U({},u);G&&(T.name=`${G}${a}${R}`),u.children&&(T.children=u.children.reduce((C,se)=>[...C,...h(se,[R],!0,A)],[])),E.paths&&E.paths[R]&&(I=E.paths[R]);const w=R===t;if(w&&o==="prefix_and_default")if(g)g&&A&&G&&(T.name+=`${a}${l}`);else{const C=K(U({},T),{path:I});if(G&&(C.name=`${T.name}${a}${l}`),u.children){C.children=[];for(const se of u.children)C.children=C.children.concat(h(se,[R],!0,!0))}S.push(C)}const Ie=g&&!I.startsWith("/"),Te=!Ie&&!(w&&o==="prefix_except_default");return Te&&(I=`/${R}${I}`),I&&(I=Me(I,n,Ie)),Te&&w&&o==="prefix"&&c&&S.push(U({},u)),T.path=I,S.push(T),S},[])}return e.reduce((u,m)=>[...u,...h(m,f||[])],[])}const ne=Ne("vue-i18n-routing-gor");function Re(e,t){e[ne]?re("already registered global options"):e[ne]=t}function pe(e){var t;return(t=e[ne])!=null?t:{}}function Ke(e,t={}){const{version:o,defaultLocale:n,locales:a,strategy:l,trailingSlash:c,routesNameSeparator:r,defaultLocaleRouteNameSuffix:i,defaultDirection:f,baseUrl:h,routes:u,routeOptionsResolver:m}=et(t),g=ie(a),A=g.map(R=>R.code),p=Se(A,r,i);_e(e,{locales:g,baseUrl:h,localeCodes:A});const E=me(u,{locales:a,defaultLocale:n,strategy:l,trailingSlash:c,routesNameSeparator:r,defaultLocaleRouteNameSuffix:i,optionsResolver:m});t.routes=E;const S=Ze(t,o);return Re(S,{defaultLocale:n,localeCodes:A,strategy:l,trailingSlash:c,routesNameSeparator:r,defaultLocaleRouteNameSuffix:i,defaultDirection:f}),S.beforeEach((R,G,I)=>{const T=q(e),w=p(R)||T||n||"";T!==w&&fe(e,w),I()}),S}function Ze(e,t){if(d.isVue3&&t===4)return L.createRouter(e);if(d.isVue2&&t===3)return new be.default(e);throw new Error("TODO:")}function Ee(e){return new RegExp(`^/(${e.join("|")})(?:/|$)`,"i")}function Se(e,t,o){const n=`(${e.join("|")})`,a=`(?:${t}${o})?`,l=new RegExp(`${t}${n}${a}$`,"i"),c=Ee(e);return i=>{if(te(i)){if(i.name){const h=(y(i.name)?i.name:i.name.toString()).match(l);if(h&&h.length>1)return h[1]}else if(i.path){const f=i.path.match(c);if(f&&f.length>1)return f[1]}}else if(y(i)){const f=i.match(c);if(f&&f.length>1)return f[1]}return""}}function et(e){var t,o,n,a,l,c,r,i,f,h;return e.version=(t=e.version)!=null?t:4,e.defaultLocale=(o=e.defaultLocale)!=null?o:D,e.strategy=(n=e.strategy)!=null?n:B,e.trailingSlash=(a=e.trailingSlash)!=null?a:X,e.routesNameSeparator=(l=e.routesNameSeparator)!=null?l:M,e.defaultLocaleRouteNameSuffix=(c=e.defaultLocaleRouteNameSuffix)!=null?c:k,e.locales=(r=e.locales)!=null?r:[],e.defaultDirection=(i=e.defaultDirection)!=null?i:Z,e.baseUrl=(f=e.baseUrl)!=null?f:ee,e.routes=(h=e.routes)!=null?h:[],e}function x(e,t,{defaultLocale:o=D,defaultDirection:n=Z,defaultLocaleRouteNameSuffix:a=k,routesNameSeparator:l=M,strategy:c=B,trailingSlash:r=X,localeCodes:i=[]}={}){const f=pe(e);return{defaultLocale:t.defaultLocale||f.defaultLocale||o,defaultDirection:t.defaultDirection||f.defaultDirection||n,defaultLocaleRouteNameSuffix:t.defaultLocaleRouteNameSuffix||f.defaultLocaleRouteNameSuffix||a,routesNameSeparator:t.routesNameSeparator||f.routesNameSeparator||l,strategy:t.strategy||f.strategy||c,trailingSlash:t.trailingSlash||f.trailingSlash||r,localeCodes:t.localeCodes||f.localeCodes||i}}const tt=new Set([b.PREFIX_AND_DEFAULT,b.PREFIX_EXCEPT_DEFAULT]);function N(e){const t=this.router,{routesNameSeparator:o}=x(t,this),n=e!=null?d.isRef(e)?d.unref(e):e:this.route;return n.name?he(n.name).split(o)[0]:void 0}function W(e,t){const o=V.call(this,e,t);return o==null?"":d.isVue3?o.redirectedFrom||o.fullPath:o.route.redirectedFrom||o.route.fullPath}function Q(e,t){const o=V.call(this,e,t);return o==null?void 0:d.isVue3?o:o.route}function le(e,t){const o=V.call(this,e,t);return o==null?void 0:d.isVue3?o:o.location}function V(e,t){const o=this.router,n=this.i18n,a=t||q(n),{routesNameSeparator:l,defaultLocale:c,defaultLocaleRouteNameSuffix:r,strategy:i,trailingSlash:f}=x(o,this);let h=e;y(e)&&(h[0]==="/"?h={path:e}:h={name:e});let u=z({},h);if(u.path&&!u.name){const g=o.resolve(u),A=d.isVue3?g:g.route,p=N.call(this,A);y(p)?u={name:Le(p,a,{defaultLocale:c,strategy:i,routesNameSeparator:l,defaultLocaleRouteNameSuffix:r}),params:A.params,query:A.query,hash:A.hash}:(!(a===c&&tt.has(i))&&i!==b.NO_PREFIX&&(u.path=`/${a}${u.path}`),u.path=f?De(u.path,!0):Ge(u.path,!0))}else{u.name=Le(u.name,a,{defaultLocale:c,strategy:i,routesNameSeparator:l,defaultLocaleRouteNameSuffix:r});const{params:g}=u;g&&g["0"]===void 0&&g.pathMatch&&(g["0"]=g.pathMatch)}const m=o.resolve(u);return(d.isVue3?m.name:m.route.name)?m:o.resolve(e)}function j(e){const t=this.route,o=N.call(this,t);if(!o)return"";const i=!d.isVue3&&d.isRef(t)?t.value:t,{params:n}=i,a=Ce(i,["params"]),l={},c=z({},a,{name:o,params:K(U(U({},n),l),{0:n.pathMatch})});return W.call(this,c,e)}function ae({addDirAttribute:e=!1,addSeoAttributes:t=!1}={}){const o=this.router,n=this.i18n,{defaultDirection:a}=x(o,this),l={htmlAttrs:{},link:[],meta:[]};if(n.locales==null||n.__baseUrl==null)return l;const c=q(n),r=Xe(n),i=ie(r).find(u=>u.code===c)||{code:c},f=i.iso,h=i.dir||a;return e&&(l.htmlAttrs.dir=h),t&&c&&n.locales&&(f&&(l.htmlAttrs.lang=f),ot.call(this,r,n.__baseUrl,l.link),nt.call(this,n.__baseUrl,l.link,t),lt(i,f,l.meta),at(r,f,l.meta)),l}function ot(e,t,o){const n=this.router,{defaultLocale:a,strategy:l}=x(n,this);if(l===b.NO_PREFIX)return;const c=new Map;for(const r of e){const i=r.iso;if(!i){re("Locale ISO code is required to generate alternate link");continue}const[f,h]=i.split("-");f&&h&&(r.isCatchallLocale||!c.has(f))&&c.set(f,r),c.set(i,r)}for(const[r,i]of c.entries()){const f=j.call(this,i.code);f&&o.push({hid:`i18n-alt-${r}`,rel:"alternate",href:ce(f,t),hreflang:r})}if(a){const r=j.call(this,a);r&&o.push({hid:"i18n-xd",rel:"alternate",href:ce(r,t),hreflang:"x-default"})}}function nt(e,t,o){const n=this.route,a=Q.call(this,K(U({},n),{name:N.call(this,n)}));if(a){let l=ce(a.path,e);const c=te(o)&&o.canonicalQueries||[];if(c.length){const r=a.query,i=new URLSearchParams;for(const h of c)if(h in r){const u=r[h];we(u)?u.forEach(m=>i.append(h,m||"")):i.append(h,u||"")}const f=i.toString();f&&(l=`${l}?${f}`)}t.push({hid:"i18n-can",rel:"canonical",href:l})}}function lt(e,t,o){!(e&&t)||o.push({hid:"i18n-og",property:"og:locale",content:Ae(t)})}function at(e,t,o){const n=e.filter(a=>{const l=a.iso;return l&&l!==t});if(n.length){const a=n.map(l=>({hid:`i18n-og-alt-${l.iso}`,property:"og:locale:alternate",content:Ae(l.iso)}));o.push(...a)}}function Ae(e){return(e||"").replace(/-/g,"_")}function ce(e,t){return e.match(/^https?:\/\//)?e:t+e}function Y(e,t){const{router:o,route:n,i18n:a,defaultLocale:l,strategy:c,defaultLocaleRouteNameSuffix:r,trailingSlash:i,routesNameSeparator:f}=e;return function(...h){return Reflect.apply(t,{router:o,route:n,i18n:a,defaultLocale:l,strategy:c,defaultLocaleRouteNameSuffix:r,trailingSlash:i,routesNameSeparator:f},h)}}function ct(e=L.useRoute(),{router:t=L.useRouter(),routesNameSeparator:o=void 0}={}){const n={router:t,route:e,routesNameSeparator:o};return N.call(n,e)}function st({router:e=L.useRouter(),route:t=L.useRoute(),i18n:o=_.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:a=void 0,routesNameSeparator:l=void 0,strategy:c=void 0,trailingSlash:r=void 0}={}){return Y({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:a,routesNameSeparator:l,strategy:c,trailingSlash:r},W)}function rt({router:e=L.useRouter(),route:t=L.useRoute(),i18n:o=_.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:a=void 0,routesNameSeparator:l=void 0,strategy:c=void 0,trailingSlash:r=void 0}={}){return Y({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:a,routesNameSeparator:l,strategy:c,trailingSlash:r},Q)}function it({router:e=L.useRouter(),route:t=L.useRoute(),i18n:o=_.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:a=void 0,routesNameSeparator:l=void 0,strategy:c=void 0,trailingSlash:r=void 0}={}){return Y({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:a,routesNameSeparator:l,strategy:c,trailingSlash:r},le)}function ut({router:e=L.useRouter(),route:t=L.useRoute(),i18n:o=_.useI18n(),defaultLocale:n=void 0,defaultLocaleRouteNameSuffix:a=void 0,routesNameSeparator:l=void 0,strategy:c=void 0,trailingSlash:r=void 0}={}){return Y({router:e,route:t,i18n:o,defaultLocale:n,defaultLocaleRouteNameSuffix:a,routesNameSeparator:l,strategy:c,trailingSlash:r},j)}function ft({addDirAttribute:e=!1,addSeoAttributes:t=!1,strategy:o=void 0,defaultLocale:n=void 0,route:a=L.useRoute(),router:l=L.useRouter(),i18n:c=_.useI18n()}={}){const r=l,i=d.ref({htmlAttrs:{},link:[],meta:[]});function f(){i.value={htmlAttrs:{},link:[],meta:[]}}function h(u){i.value=Reflect.apply(ae,{router:l,route:u,i18n:c,defaultLocale:n,strategy:o},[{addDirAttribute:e,addSeoAttributes:t}])}if(Be)if(d.isVue3){const u=d.watchEffect(()=>{f(),h(de(r.currentRoute))});d.onUnmounted(()=>u())}else{const u=r.afterEach((m,g)=>{f(),h(m)});d.onUnmounted(()=>u()),h(a)}else h(de(r.currentRoute));return i}const dt="0.0.0";return s.DEFAULT_BASE_URL=ee,s.DEFAULT_DETECTION_DIRECTION=Z,s.DEFAULT_LOCALE=D,s.DEFAULT_LOCALE_ROUTE_NAME_SUFFIX=k,s.DEFAULT_ROUTES_NAME_SEPARATOR=M,s.DEFAULT_STRATEGY=B,s.DEFAULT_TRAILING_SLASH=X,s.STRATEGIES=b,s.VERSION=dt,s.createLocaleFromRouteGetter=Se,s.createRouter=Ke,s.extendI18n=_e,s.findBrowserLocale=xe,s.getGlobalOptions=pe,s.getLocale=q,s.getLocalesRegex=Ee,s.getRouteBaseName=N,s.isComposer=v,s.isExportedGlobalComposer=H,s.isI18nInstance=$,s.isLegacyVueI18n=O,s.isVueI18n=F,s.localeHead=ae,s.localeLocation=le,s.localePath=W,s.localeRoute=Q,s.localizeRoutes=me,s.proxyVueInstance=P,s.registerGlobalOptions=Re,s.resolveBaseUrl=ge,s.resolveRoute=V,s.setLocale=fe,s.switchLocalePath=j,s.useLocaleHead=ft,s.useLocaleLocation=it,s.useLocalePath=st,s.useLocaleRoute=rt,s.useRouteBaseName=ct,s.useSwitchLocalePath=ut,Object.defineProperties(s,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}}),s}({},VueDemi,VueRouter,VueI18n);
{
"name": "vue-i18n-routing",
"description": "The i18n routing with using vue-i18n",
"version": "0.0.0-d5a38c7",
"version": "0.0.0-e0454ba",
"dependencies": {

@@ -17,4 +17,4 @@ "@intlify/shared": "next",

"rimraf": "^3.0.2",
"typescript": "^4.5.4",
"vite": "latest",
"typescript": "^4.6.3",
"vite": "^2.9.8",
"vite-plugin-dts": "^0.9.6",

@@ -26,3 +26,3 @@ "vitest": "^0.2.8",

"vue-i18n-legacy": "npm:vue-i18n@8",
"vue-router": "^4.0.12",
"vue-router": "^4.0.15",
"vue-router3": "npm:vue-router@3",

@@ -35,4 +35,4 @@ "vue-template-compiler": "^2.6.14",

"vue": "^2.6.14 || ^3.2.0",
"vue-i18n": "^8.26.1 || ^9.2.0-beta.34",
"vue-i18n-bridge": "^9.2.0-beta.34",
"vue-i18n": "^8.26.1 || ^9.2.0-beta.35",
"vue-i18n-bridge": "^9.2.0-beta.35",
"vue-router": "^3.5.3 || ^4.0.0"

@@ -39,0 +39,0 @@ },

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc