Update docs for i18n

This commit is contained in:
Mimi 2020-05-22 11:33:22 +08:00
parent 73dff7cb85
commit 36808b95ea
6 changed files with 41 additions and 94 deletions

View File

@ -25,7 +25,7 @@
- [ ] Refactoring (no functional changes, no api changes). - [ ] Refactoring (no functional changes, no api changes).
- [ ] Build & CI related changes. - [ ] Build & CI related changes.
- [ ] Documentation. - [ ] Documentation.
- [ ] Translation. <!-- We use Crowdin to manage translations https://i18n.theme-next.org --> - [ ] Translation. <!-- We use Crowdin to manage translations https://crowdin.com/project/hexo-theme-next -->
- [ ] Other... Please describe: - [ ] Other... Please describe:
## What is the current behavior? ## What is the current behavior?

View File

@ -128,7 +128,7 @@ Also, we welcome Issue or PR to our [official-plugins][official-plugins-url].
[docs-update-5-1-x-url]: https://theme-next.js.org/docs/getting-started/update-from-v5.html [docs-update-5-1-x-url]: https://theme-next.js.org/docs/getting-started/update-from-v5.html
[gitter-url]: https://gitter.im/hexo-next [gitter-url]: https://gitter.im/hexo-next
[i18n-url]: https://i18n.theme-next.org [i18n-url]: https://crowdin.com/project/hexo-theme-next
[awesome-next-url]: https://github.com/next-theme/awesome-next [awesome-next-url]: https://github.com/next-theme/awesome-next
[issues-bug-url]: https://github.com/next-theme/hexo-theme-next/issues/new?assignees=&labels=Bug&template=bug-report.md [issues-bug-url]: https://github.com/next-theme/hexo-theme-next/issues/new?assignees=&labels=Bug&template=bug-report.md

View File

@ -108,7 +108,7 @@ $ git pull
[docs-update-5-1-x-url]: https://theme-next.js.org/docs/getting-started/update-from-v5.html [docs-update-5-1-x-url]: https://theme-next.js.org/docs/getting-started/update-from-v5.html
[gitter-url]: https://gitter.im/hexo-next [gitter-url]: https://gitter.im/hexo-next
[i18n-url]: https://i18n.theme-next.org [i18n-url]: https://crowdin.com/project/hexo-theme-next
[awesome-next-url]: https://github.com/next-theme/awesome-next [awesome-next-url]: https://github.com/next-theme/awesome-next
[issues-bug-url]: https://github.com/next-theme/hexo-theme-next/issues/new?assignees=&labels=Bug&template=bug-report.md [issues-bug-url]: https://github.com/next-theme/hexo-theme-next/issues/new?assignees=&labels=Bug&template=bug-report.md

View File

@ -126,7 +126,7 @@ $ git pull
[docs-update-5-1-x-url]: https://theme-next.js.org/docs/getting-started/update-from-v5.html [docs-update-5-1-x-url]: https://theme-next.js.org/docs/getting-started/update-from-v5.html
[gitter-url]: https://gitter.im/hexo-next [gitter-url]: https://gitter.im/hexo-next
[i18n-url]: https://i18n.theme-next.org [i18n-url]: https://crowdin.com/project/hexo-theme-next
[awesome-next-url]: https://github.com/next-theme/awesome-next [awesome-next-url]: https://github.com/next-theme/awesome-next
[issues-bug-url]: https://github.com/next-theme/hexo-theme-next/issues/new?assignees=&labels=Bug&template=bug-report.md [issues-bug-url]: https://github.com/next-theme/hexo-theme-next/issues/new?assignees=&labels=Bug&template=bug-report.md

37
languages/README.md Normal file
View File

@ -0,0 +1,37 @@
# Internationalization (i18n)
You can use internationalization to present your site in different languages. The default language is set by modifying the `language` setting in `_config.yml`. You can also set multiple languages and modify the order of default languages.
```yaml
language: en
```
```yaml
language:
- zh-cn
- en
```
## Override Default Translations
If you would like to customize the default translation, you do not need to modify the translation files in the `languages` directory. You can override all translations using [Data files](https://hexo.io/docs/data-files).
1. Creat a `languages.yml` in `source/_data`.
2. Insert following codes: (be careful about the two-space indent)
```yaml
# language
zh-CN:
# items
post:
copyright:
# the translation you perfer
author: 本文博主
en:
menu:
schedule: Calendar
```
## Improve Translations
The files in the `language` directory are automatically generated, you do not need to modify them directly. Please submit translations via [Crowdin](https://crowdin.com/project/hexo-theme-next) if you would like to add or improve translation for NexT theme.

View File

@ -1,90 +0,0 @@
---
name: magyar
title:
archive: Archive
category: Category
tag: Tag
schedule: Ütemterv
menu:
home: Home
archives: Archives
categories: Categories
tags: Tags
about: About
search: Search
schedule: Schedule
sitemap: Sitemap
commonweal: Commonweal 404
sidebar:
overview: Overview
toc: Table of Contents
post:
posted: Posted on
edited: Edited on
created: Created
modified: Modified
edit: Edit this post
in: In
read_more: Read more
untitled: Untitled
sticky: Sticky
views: Views
related_posts: Related Posts
copyright:
author: Post author
link: Post link
license_title: Copyright Notice
license_content: "All articles in this blog are licensed under %s unless stating additionally."
footer:
powered: "Powered by %s"
total_views: Total Views
total_visitors: Total Visitors
counter:
tag_cloud:
zero: No tags
one: 1 tag in total
other: "%d tags in total"
categories:
zero: No categories
one: 1 category in total
other: "%d categories in total"
archive_posts:
zero: No posts.
one: 1 post.
other: "%d posts in total."
state:
posts: posts
tags: tags
categories: categories
search:
placeholder: Searching...
cheers:
um: Um..
ok: OK
nice: Nice
good: Good
great: Great
excellent: Excellent
keep_on: Keep on posting.
symbol:
comma: ", "
period: ". "
colon: ": "
reward:
donate: Donate
wechatpay: WeChat Pay
alipay: Alipay
paypal: PayPal
bitcoin: Bitcoin
follow_me:
welcome: Welcome to my other publishing channels
accessibility:
nav_toggle: Toggle navigation bar
prev_page: Previous page
next_page: Next page
symbols_count_time:
count: Symbols count in article
count_total: Symbols count total
time: Reading time
time_total: Reading time total
time_minutes: mins.