summaryrefslogtreecommitdiff
path: root/website/src/ja/docs
diff options
context:
space:
mode:
authorSho Sakuma <me@m1sk9.dev>2026-09-28 23:43:13 +0900
committerSho Sakuma <me@m1sk9.dev>2026-09-28 23:43:13 +0900
commita22fce70db7b43aadd8baa42e87a4430a8b1e05f (patch)
tree4cb170c50669db3ca7e046b8447294e8201146cc /website/src/ja/docs
parent479000d491f8b1363a1e6a6e8f6fac85e0fc74bd (diff)
downloadLunaticChat-a22fce70db7b43aadd8baa42e87a4430a8b1e05f.tar.gz
LunaticChat-a22fce70db7b43aadd8baa42e87a4430a8b1e05f.tar.bz2
LunaticChat-a22fce70db7b43aadd8baa42e87a4430a8b1e05f.zip
fix(paper): splice display names as components and share role labels
Serializing the display name into the legacy text let its color run into everything after it, and legacy text cannot hold hex colors or hover and click events, so names styled by other plugins came out wrong. The name is now spliced into the parsed component instead. {role} is resolved only when the format uses it, since the default formats do not and it costs a member scan and a lookup per message. /lc channel status now shows the same localized role names instead of a second, hard-coded [OWNER] / [MOD] vocabulary that only one of the two places translated. Co-Authored-By: Claude <noreply@anthropic.com>
Diffstat (limited to 'website/src/ja/docs')
-rw-r--r--website/src/ja/docs/developers/platform-paper.md2
1 files changed, 1 insertions, 1 deletions
diff --git a/website/src/ja/docs/developers/platform-paper.md b/website/src/ja/docs/developers/platform-paper.md
index 930c696..edcd858 100644
--- a/website/src/ja/docs/developers/platform-paper.md
+++ b/website/src/ja/docs/developers/platform-paper.md
@@ -158,7 +158,7 @@ config フラグ
- `Language` (enum) — `EN` / `JA`.未知コードは EN にフォールバック
- `LanguageManager` — 起動時に `resources/languages/` を KAML でロードし,ネストした YAML をドット記法 (`toggle.on` 等) にフラット化する.`getMessage(key, placeholders)` は 選択言語 → EN フォールバック で解決し `{placeholder}` を置換,未発見はキー自身を返す.EN が無ければ致命エラー
- `MessageFormatter` (`object`) — `[LC]` プレフィックス付きの Adventure `Component` を生成し,`{braces}` プレースホルダを正規表現で検出して色分けする
-- `ChatPlaceholder` / `ChatFormat.kt` — `messageFormat` のプレースホルダ語彙と唯一のレンダラ.フォーマットごとの入口 (`directMessage` / `channelMessage` / `crossServerGlobalChat`) が 1 パスで置換し,結果を `LegacyComponentSerializer` に渡す.ハンドラがプレースホルダ名を綴ることはない
+- `ChatPlaceholder` / `ChatFormat.kt` — `messageFormat` のプレースホルダ語彙と唯一のレンダラ.フォーマットごとの入口 (`directMessage` / `channelMessage` / `crossServerGlobalChat`) が 1 パスで置換し,結果を `LegacyComponentSerializer` に渡したうえで,`{display_name}` のような Component 値を差し込む (スタイルやイベントがその値の範囲に閉じるように).ハンドラがプレースホルダ名を綴ることはない
## converter — ローマ字→日本語変換