vue-i18n-routing
Advanced tools
Comparing version 1.0.1 to 1.0.2-3033806
@@ -18,3 +18,3 @@ var VueI18nRouting = function(exports, VueRouter3, vueDemi, vueI18nBridge) { | ||
/*! | ||
* shared v9.3.0-beta.26 | ||
* shared v9.4.0 | ||
* (c) 2023 kazuya kawaguchi | ||
@@ -618,2 +618,16 @@ * Released under the MIT License. | ||
} | ||
function routeToObject(route) { | ||
const { fullPath, query, hash, name, path, params, meta, redirectedFrom, matched } = route; | ||
return { | ||
fullPath, | ||
params, | ||
query, | ||
hash, | ||
name, | ||
path, | ||
meta, | ||
matched, | ||
redirectedFrom | ||
}; | ||
} | ||
function resolve(router, route, strategy, locale) { | ||
@@ -764,3 +778,4 @@ if (vueDemi.isVue3 && strategy === "prefix") { | ||
const { switchLocalePathIntercepter, dynamicRouteParamsKey } = getI18nRoutingOptions(this.router, this); | ||
const { params, ...routeCopy } = vueDemi.isVue3 ? route : vueDemi.isRef(route) ? route.value : route; | ||
const routeValue = vueDemi.isVue3 ? route : vueDemi.isRef(route) ? route.value : route; | ||
const routeCopy = routeToObject(routeValue); | ||
const langSwitchParams = getLocalizableMetaFromDynamicParams(route, dynamicRouteParamsKey)[locale] || {}; | ||
@@ -770,3 +785,3 @@ const _baseRoute = { | ||
params: { | ||
...params, | ||
...routeCopy.params, | ||
...langSwitchParams | ||
@@ -776,3 +791,3 @@ } | ||
if (vueDemi.isVue2) { | ||
_baseRoute.params[0] = params.pathMatch; | ||
_baseRoute.params[0] = routeCopy.params.pathMatch; | ||
} | ||
@@ -1130,3 +1145,3 @@ const baseRoute = assign({}, routeCopy, _baseRoute); | ||
} | ||
const VERSION = "1.0.1"; | ||
const VERSION = "1.0.2"; | ||
exports.DEFAULT_BASE_URL = DEFAULT_BASE_URL; | ||
@@ -1133,0 +1148,0 @@ exports.DEFAULT_DETECTION_DIRECTION = DEFAULT_DETECTION_DIRECTION; |
@@ -21,3 +21,3 @@ "use strict"; | ||
/*! | ||
* shared v9.3.0-beta.26 | ||
* shared v9.4.0 | ||
* (c) 2023 kazuya kawaguchi | ||
@@ -621,2 +621,16 @@ * Released under the MIT License. | ||
} | ||
function routeToObject(route) { | ||
const { fullPath, query, hash, name, path, params, meta, redirectedFrom, matched } = route; | ||
return { | ||
fullPath, | ||
params, | ||
query, | ||
hash, | ||
name, | ||
path, | ||
meta, | ||
matched, | ||
redirectedFrom | ||
}; | ||
} | ||
function resolve(router, route, strategy, locale) { | ||
@@ -767,3 +781,4 @@ if (vueDemi.isVue3 && strategy === "prefix") { | ||
const { switchLocalePathIntercepter, dynamicRouteParamsKey } = getI18nRoutingOptions(this.router, this); | ||
const { params, ...routeCopy } = vueDemi.isVue3 ? route : vueDemi.isRef(route) ? route.value : route; | ||
const routeValue = vueDemi.isVue3 ? route : vueDemi.isRef(route) ? route.value : route; | ||
const routeCopy = routeToObject(routeValue); | ||
const langSwitchParams = getLocalizableMetaFromDynamicParams(route, dynamicRouteParamsKey)[locale] || {}; | ||
@@ -773,3 +788,3 @@ const _baseRoute = { | ||
params: { | ||
...params, | ||
...routeCopy.params, | ||
...langSwitchParams | ||
@@ -779,3 +794,3 @@ } | ||
if (vueDemi.isVue2) { | ||
_baseRoute.params[0] = params.pathMatch; | ||
_baseRoute.params[0] = routeCopy.params.pathMatch; | ||
} | ||
@@ -1133,3 +1148,3 @@ const baseRoute = assign({}, routeCopy, _baseRoute); | ||
} | ||
const VERSION = "1.0.1"; | ||
const VERSION = "1.0.2"; | ||
exports.DEFAULT_BASE_URL = DEFAULT_BASE_URL; | ||
@@ -1136,0 +1151,0 @@ exports.DEFAULT_DETECTION_DIRECTION = DEFAULT_DETECTION_DIRECTION; |
{ | ||
"name": "vue-i18n-routing", | ||
"description": "The i18n routing with using vue-i18n", | ||
"version": "1.0.1", | ||
"scripts": { | ||
"dev": "vite", | ||
"build": "vite build", | ||
"typecheck": "tsc -p . --noEmit", | ||
"switch:2": "vue-demi-switch 2 vue2 && vue-router-switch 3 vue-router3 && vue-i18n-switch 8 vue-i18n-legacy", | ||
"switch:3": "vue-demi-switch 3 && vue-router-switch 4 && vue-i18n-switch 9", | ||
"test": "vitest run", | ||
"test:watch": "vitest", | ||
"test:cover": "vitest --coverage", | ||
"build:docs": "api-docs-gen ./temp/vue-i18n-routing.api.json -c ./docsgen.config.js -o ./ -g noprefix" | ||
}, | ||
"version": "1.0.2-3033806", | ||
"dependencies": { | ||
"@intlify/shared": "next", | ||
"@intlify/vue-i18n-bridge": "^0.8.0", | ||
"@intlify/vue-router-bridge": "^0.8.0", | ||
"@intlify/shared": "^9.4.0", | ||
"@intlify/vue-i18n-bridge": "^1.0.0", | ||
"@intlify/vue-router-bridge": "^1.0.0", | ||
"ufo": "^1.2.0", | ||
@@ -31,3 +20,3 @@ "vue-demi": "^0.14.5" | ||
"vue": "^3.2.27", | ||
"vue-i18n": "npm:vue-i18n@9.3.0-beta.26", | ||
"vue-i18n": "npm:vue-i18n@9.4.0", | ||
"vue-i18n-bridge": "next", | ||
@@ -42,4 +31,4 @@ "vue-i18n-legacy": "npm:vue-i18n@8", | ||
"vue": "^2.6.14 || ^2.7.0 || ^3.2.0", | ||
"vue-i18n": "^8.26.1 || ^9.2.0 || ^9.3.0", | ||
"vue-i18n-bridge": "^9.2.0 || ^9.3.0", | ||
"vue-i18n": "^8.26.1 || >=9.2.0", | ||
"vue-i18n-bridge": ">=9.2.0", | ||
"vue-router": "^3.5.3 || ^3.6.0 || ^4.0.0", | ||
@@ -122,3 +111,14 @@ "@vue/composition-api": "^1.0.0-rc.1" | ||
}, | ||
"sideEffects": false | ||
} | ||
"sideEffects": false, | ||
"scripts": { | ||
"dev": "vite", | ||
"build": "vite build", | ||
"typecheck": "tsc -p . --noEmit", | ||
"switch:2": "vue-demi-switch 2 vue2 && vue-router-switch 3 vue-router3 && vue-i18n-switch 8 vue-i18n-legacy", | ||
"switch:3": "vue-demi-switch 3 && vue-router-switch 4 && vue-i18n-switch 9", | ||
"test": "vitest run", | ||
"test:watch": "vitest", | ||
"test:cover": "vitest --coverage", | ||
"build:docs": "api-docs-gen ./temp/vue-i18n-routing.api.json -c ./docsgen.config.js -o ./ -g noprefix" | ||
} | ||
} |
@@ -5,4 +5,2 @@ # vue-i18n-routing | ||
WIP: đˇ | ||
## đ¤ API | ||
@@ -14,2 +12,2 @@ | ||
[MIT](http://opensource.org/licenses/MIT) | ||
[MIT](http://opensource.org/licenses/MIT) |
Sorry, the diff of this file is not supported yet
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
207351
13
5742
1
12
+ Added@intlify/core-base@11.1.1(transitive)
+ Added@intlify/message-compiler@11.1.1(transitive)
+ Added@intlify/shared@11.1.1(transitive)
+ Added@intlify/vue-i18n-bridge@1.1.0(transitive)
+ Added@intlify/vue-router-bridge@1.1.0(transitive)
+ Addedvue-i18n@11.1.1(transitive)
- Removed@intlify/shared@11.0.0-rc.1(transitive)
- Removed@intlify/vue-i18n-bridge@0.8.0(transitive)
- Removed@intlify/vue-router-bridge@0.8.0(transitive)
- Removedvue-demi@0.13.11(transitive)
- Removedvue-i18n@9.14.2(transitive)
Updated@intlify/shared@^9.4.0