mirror of
https://github.com/Elysola/WebHooker.git
synced 2026-11-21 01:23:40 +00:00
docs: fix factual errors, fill coverage gaps and align zh mirror
This commit is contained in:
35 files changed
+912
-316
No files matched your search
@@ -0,0 +1,24 @@
|
||||
# Message Language (i18n)
|
||||
|
||||
Messages are rendered in the language configured per group. WebHooker ships with **English** (default) and **Simplified Chinese** dictionaries.
|
||||
|
||||
## Per-Group Language
|
||||
|
||||
Set `Group.lang` (e.g. `"zh"`) to choose the message language for every route in a group — see [Groups → Group Schema](./configuration#group-schema). The group's webhook log-channel summaries use the same language.
|
||||
|
||||
## Custom Overrides
|
||||
|
||||
Translation overrides are merged from KV under the key `i18n:<lang>` as a flat JSON object of key → text. Any key from the built-in dictionaries (en/zh) can be overridden; unknown keys fall back to English.
|
||||
|
||||
```jsonc
|
||||
// KV key: i18n:zh
|
||||
{
|
||||
"events.push.title": "{repo}: 推送了 {count} 个提交到 {ref}"
|
||||
}
|
||||
```
|
||||
|
||||
Overrides apply to group messages (and console UI where applicable). To add a brand-new language, store a full dictionary at `i18n:<lang>` — every key you do not provide falls back to English.
|
||||
|
||||
## Emoji Toggle
|
||||
|
||||
`Group.emoji` (default `true`) controls whether event emoji appear in that group's messages. When disabled, all emoji are stripped from titles, descriptions, fields, and links. Milestone progress bars (🟢🟡🟠⬜) are data visualization and stay regardless of the toggle.
|
||||
Reference in new issue
Block a user