]> git.ipfire.org Git - thirdparty/vuejs/router.git/commitdiff
docs(zh): translate the rest of RouteRecordNormalized to Chinese (#2172)
authorJohn Mao <z@v1c0.com>
Mon, 18 Mar 2024 14:17:17 +0000 (22:17 +0800)
committerGitHub <noreply@github.com>
Mon, 18 Mar 2024 14:17:17 +0000 (22:17 +0800)
* docs(zh): translate the rest of RouteRecordNormalized to Chinese

* Update packages/docs/zh/api/interfaces/RouteRecordNormalized.md

---------

Co-authored-by: Jinjiang <zhaojinjiang@me.com>
packages/docs/zh/api/interfaces/RouteRecordNormalized.md

index 83384388998eb0cbfb0428439166e63ad155140d..14ee6fa06a097ccae14abffd42136fa1ae0dbb97 100644 (file)
@@ -44,7 +44,7 @@ ___
 
 • **components**: `undefined` \| ``null`` \| `Record`\<`string`, `RawRouteComponent`\>
 
-Components to display when the URL matches this route. Allow using named views.
+当 URL 匹配到该路由时显示的组件。允许使用命名视图。
 
 ___
 
@@ -52,15 +52,8 @@ ___
 
 • **instances**: `Record`\<`string`, `undefined` \| ``null`` \| `ComponentPublicInstance`\>
 
-<!-- TODO: translation -->
-
-Mounted route component instances
-Having the instances on the record mean beforeRouteUpdate and
-beforeRouteLeave guards can only be invoked with the latest mounted app
-instance if there are multiple application instances rendering the same
-view, basically duplicating the content on the page, which shouldn't happen
-in practice. It will work if multiple apps are rendering different named
-views.
+挂载的路由组件实例。
+在记录上存在实例意味着,当有多个应用实例渲染相同的视图时,beforeRouteUpdate 和 beforeRouteLeave 守卫只能被最后挂载的应用实例调用。这样的渲染基本上只会对页面内容进行复制,在实际情况下并不应该发生。它可以在多个应用渲染不同的命名视图时工作。
 
 ___
 
@@ -68,9 +61,7 @@ ___
 
 • **meta**: [`RouteMeta`](RouteMeta.md)
 
-<!-- TODO: translation -->
-
-Arbitrary data attached to the record.
+附加在记录上的任意数据。
 
 ___
 
@@ -78,9 +69,7 @@ ___
 
 • **name**: `undefined` \| [`RouteRecordName`](../index.md#routerecordname)
 
-<!-- TODO: translation -->
-
-Name for the route record. Must be unique.
+路由记录的名称。必须唯一。
 
 ___
 
@@ -88,9 +77,7 @@ ___
 
 • **path**: `string`
 
-<!-- TODO: translation -->
-
-Path of the record. Should start with `/` unless the record is the child of another record.
+记录的路径。应该以 `/` 开头,除非该记录为另一条记录的子记录。
 
 ___
 
@@ -98,9 +85,7 @@ ___
 
 • **props**: `Record`\<`string`, `_RouteRecordProps`\>
 
-<!-- TODO: translation -->
-
-Allow passing down params as props to the component rendered by `router-view`. Should be an object with the same keys as `components` or a boolean to be applied to every component.
+允许将参数作为 props 传递给由 `router-view` 渲染的组件。应是一个具有与 `components` 相同键的对象,或是一个应用于所有组件的布尔值。
 
 ___
 
@@ -108,6 +93,4 @@ ___
 
 • **redirect**: `undefined` \| `RouteRecordRedirectOption`
 
-<!-- TODO: translation -->
-
-Where to redirect if the route is directly matched. The redirection happens before any navigation guard and triggers a new navigation with the new target location.
+路由直接匹配时重定向的位置。重定向发生在任何导航守卫和带有新目标位置的新导航触发之前。