Skip to content

Commit

Permalink
i18n: migrate zh to zh-CN
Browse files Browse the repository at this point in the history
  • Loading branch information
shigma committed Sep 3, 2023
1 parent dbe0b31 commit 84bbbf3
Show file tree
Hide file tree
Showing 11 changed files with 16 additions and 5 deletions.
11 changes: 11 additions & 0 deletions crowdin.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
commit_message: '[skip ci]'
pull_request_title: 'i18n: update translations'
pull_request_labels:
- i18n
files:
- source: /packages/*/src/locales/zh-CN.yml
translation: /%original_path%/%locale%.yml
- source: /docs/zh-CN/**/*.md
translation: /docs/%locale%/**/%file_name%.md
- source: /docs/.vitepress/**/zh-CN.json
translation: /docs/.vitepress/**/%locale%.json
2 changes: 1 addition & 1 deletion packages/author/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export const using = ['dialogue'] as const
export function apply(ctx: Context, config: Config) {
const { authority } = config

ctx.i18n.define('zh', require('./locales/zh'))
ctx.i18n.define('zh-CN', require('./locales/zh-CN'))

ctx.model.extend('dialogue', {
writer: 'unsigned(20)',
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion packages/context/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export const using = ['dialogue'] as const
export function apply(ctx: Context, config: Config) {
const { authority } = config

ctx.i18n.define('zh', require('./locales/zh'))
ctx.i18n.define('zh-CN', require('./locales/zh-CN'))

ctx.model.extend('dialogue', {
guilds: 'list(255)',
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion packages/core/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ export const name = 'dialogue'
export const using = ['database'] as const

export function apply(ctx: Context, config: Config) {
ctx.i18n.define('zh', require('./locales/zh'))
ctx.i18n.define('zh-CN', require('./locales/zh-CN'))

// features
ctx.plugin(DialogueService, config)
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion packages/flow/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ export const name = 'koishi-plugin-dialogue-flow'
export const using = ['dialogue'] as const

export function apply(ctx: Context, config: Dialogue.Config) {
ctx.i18n.define('zh', require('./locales/zh'))
ctx.i18n.define('zh-CN', require('./locales/zh-CN'))

ctx.model.extend('dialogue', {
predecessors: 'list(255)',
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion packages/time/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export const name = 'koishi-plugin-dialogue-time'
export const using = ['database'] as const

export function apply(ctx: Context, config: Config) {
ctx.i18n.define('zh', require('./locales/zh'))
ctx.i18n.define('zh-CN', require('./locales/zh-CN'))

ctx.model.extend('dialogue', {
startTime: 'integer',
Expand Down
File renamed without changes.

0 comments on commit 84bbbf3

Please sign in to comment.