Skip to content

Commit

Permalink
Add simplified Chinese translation.
Browse files Browse the repository at this point in the history
  • Loading branch information
langyo committed Oct 15, 2024
1 parent a08096e commit e3214ba
Show file tree
Hide file tree
Showing 59 changed files with 6,060 additions and 794 deletions.
2 changes: 1 addition & 1 deletion website/docs/concepts/agents.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ A dispatcher allows uni-directional communication between a component and an age
## Overhead

Agents use web workers \(i.e. Private and Public\). They incur a serialization overhead on the
messages they send and receive. Agents use [bincode](https://github.com/servo/bincode) to communicate
messages they send and receive. Agents use [bincode](https://github.com/bincode-org/bincode) to communicate
with other threads, so the cost is substantially higher than just calling a function.

## Further reading
Expand Down
5 changes: 0 additions & 5 deletions website/docs/concepts/function-components/properties.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -78,11 +78,6 @@ fn App() -> Html {
```rust
use yew::{function_component, html, Html};






#[function_component]
fn HelloWorld() -> Html {
html! { "Hello world" }
Expand Down
2 changes: 1 addition & 1 deletion website/docs/concepts/html/events.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ pub enum Msg {
### Using `JsCast`

The [`wasm-bindgen`](https://rustwasm.github.io/wasm-bindgen/api/wasm_bindgen/index.html) crate has
a useful trait; [`JsCast`](https://rustwasm.github.io/wasm-bindgen/api/wasm_bindgen/trait.JsCast.html)
a useful trait: [`JsCast`](https://rustwasm.github.io/wasm-bindgen/api/wasm_bindgen/trait.JsCast.html),
which allows us to hop and skip our way to the type we want, as long as it implements `JsCast`. We can
do this cautiously, which involves some runtime checks and failure types like `Option` and `Result`,
or we can do it dangerously.
Expand Down
2 changes: 1 addition & 1 deletion website/docs/concepts/html/lists.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ html! {

We have [Keyed list](https://github.com/yewstack/yew/tree/master/examples/keyed_list) example that lets you test the performance improvements, but here is a rough rundown:

1. Go to [Keyed list](https://github.com/yewstack/yew/tree/master/examples/keyed_list) hosted demo
1. Go to [Keyed list hosted demo](https://examples.yew.rs/keyed_list)
2. Add 500 elements.
3. Disable keys.
4. Reverse the list.
Expand Down
2 changes: 1 addition & 1 deletion website/docs/concepts/router.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ routes. Except you supply a `to` attribute instead of a `href`. An example usage
Struct variants work as expected too:

```rust ,ignore
<Link<Route> to={Route::Post { id: "new-yew-release".to_string() }}>{ "Yew v0.19 out now!" }</Link<Route>>
<Link<Route> to={Route::Post { id: "new-yew-release".to_string() }}>{ "Yew!" }</Link<Route>>
```

#### Navigator API
Expand Down
24 changes: 12 additions & 12 deletions website/i18n/zh-Hans/docusaurus-plugin-content-docs/current.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,19 +12,19 @@
"description": "The label for category Concepts in sidebar docs"
},
"sidebar.docs.category.Concepts.link.generated-index.title": {
"message": "Yew concepts",
"message": "Yew 核心概念",
"description": "The generated-index page title for category Concepts in sidebar docs"
},
"sidebar.docs.category.Concepts.link.generated-index.description": {
"message": "Learn about the important Yew concepts!",
"message": "了解 Yew 的重要概念!",
"description": "The generated-index page description for category Concepts in sidebar docs"
},
"sidebar.docs.category.HTML": {
"message": "HTML",
"description": "The label for category HTML in sidebar docs"
},
"sidebar.docs.category.Components": {
"message": "Function Components",
"message": "函数式组件",
"description": "The label for category Components in sidebar docs"
},
"sidebar.docs.category.Advanced topics": {
Expand All @@ -36,19 +36,19 @@
"description": "The generated-index page title for category Advanced topics in sidebar docs"
},
"sidebar.docs.category.Advanced topics.link.generated-index.description": {
"message": "Learn about the advanced topics and inner workings of Yew!",
"message": "了解 Yew 的更多内部细节!",
"description": "The generated-index page description for category Advanced topics in sidebar docs"
},
"sidebar.docs.category.More": {
"message": "更多",
"description": "The label for category More in sidebar docs"
},
"sidebar.docs.category.More.link.generated-index.title": {
"message": "Miscellaneous",
"message": "杂项",
"description": "The generated-index page title for category More in sidebar docs"
},
"sidebar.docs.category.Migration guides": {
"message": "Migration guides",
"message": "迁移指南",
"description": "The label for category Migration guides in sidebar docs"
},
"sidebar.docs.category.yew": {
Expand All @@ -64,23 +64,23 @@
"description": "The label for category yew-router in sidebar docs"
},
"sidebar.docs.category.Using Basic Web Technologies In Yew": {
"message": "Intro With Basic Web Technologies",
"message": "Yew 中的基本 Web 技术",
"description": "The label for category Using Basic Web Technologies In Yew in sidebar docs"
},
"sidebar.docs.category.Using Basic Web Technologies In Yew.link.generated-index.title": {
"message": "Yew Take on Basic Web Technologies",
"message": "Yew 对基本 Web 技术的看法",
"description": "The generated-index page title for category Using Basic Web Technologies In Yew in sidebar docs"
},
"sidebar.docs.category.Using Basic Web Technologies In Yew.link.generated-index.description": {
"message": "Yew mostly operates on the idea of keeping everything that a reusable piece of UI may need, in one place - rust files. But also seeks to stay close to the original look of the technology. Explore further to fully grasp what we mean by these statements:",
"message": "Yew 主要基于将可重用的 UI 部件所需的所有内容放在一个地方 - rust 文件的想法。但也力求保持与技术的原始外观接近。进一步探索,以充分理解我们对这些陈述的含义:",
"description": "The generated-index page description for category Using Basic Web Technologies In Yew in sidebar docs"
},
"sidebar.docs.category.Hooks": {
"message": "Hooks",
"message": "钩子",
"description": "The label for category Hooks in sidebar docs"
},
"sidebar.docs.category.Struct Components": {
"message": "Struct Components",
"message": "结构化组件",
"description": "The label for category Struct Components in sidebar docs"
}
}
}
Loading

0 comments on commit e3214ba

Please sign in to comment.