From 49d0807c43d0a4600003fbaed586930c58c3ea5a Mon Sep 17 00:00:00 2001 From: Super Manito <68613938+SuperManito@users.noreply.github.com> Date: Mon, 23 Jun 2025 20:54:34 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E6=96=87=E6=A1=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/assets/js/components/orama-ui/config.js | 14 ++++++++++++++ docs/index.md | 2 +- docs/index.zh-Hant.md | 2 +- 3 files changed, 16 insertions(+), 2 deletions(-) diff --git a/docs/assets/js/components/orama-ui/config.js b/docs/assets/js/components/orama-ui/config.js index dc3a39d..93587c9 100644 --- a/docs/assets/js/components/orama-ui/config.js +++ b/docs/assets/js/components/orama-ui/config.js @@ -76,6 +76,20 @@ function localizationOramaSearchBox(searchBox) { element.textContent = askAiText } } + // Keyboard shortcuts localization (Only PC) + const toSelectText = isDefaultLang ? '选择' : '選擇' + const toNavigateText = isDefaultLang ? '导航' : '導航' + const toCloseText = isDefaultLang ? '关闭' : '關閉' + const shortcutDescriptions = shadowRoot.querySelectorAll('.shortcut-description') + shortcutDescriptions.forEach((element) => { + if (element.textContent === 'to select' && element.textContent !== toSelectText) { + element.textContent = toSelectText + } else if (element.textContent === 'to navigate' && element.textContent !== toNavigateText) { + element.textContent = toNavigateText + } else if (element.textContent === 'to close' && element.textContent !== toCloseText) { + element.textContent = toCloseText + } + }) // Hide "Orama can make mistakes. Please verify the information." const chatFormWrapper = shadowRoot.querySelector('.chat-form-wrapper') if (chatFormWrapper) { diff --git a/docs/index.md b/docs/index.md index 0970652..f883801 100644 --- a/docs/index.md +++ b/docs/index.md @@ -54,7 +54,7 @@ hide: --- - 已适配高达 `23+` 操作系统,涵盖各类版本,精准识别系统类型 + 已适配高达 `24+` 操作系统,涵盖各类版本,精准识别系统类型 脚本兼容性高,不支持的系统会有相应提示并无操作跳出 - :material-vector-triangle:{ .lg .middle } __多元软件源适配__ diff --git a/docs/index.zh-Hant.md b/docs/index.zh-Hant.md index 25d33b0..b673d9b 100644 --- a/docs/index.zh-Hant.md +++ b/docs/index.zh-Hant.md @@ -54,7 +54,7 @@ hide: --- - 已適配高達 `23+` 作業系統,涵蓋各類版本,精準辨識系統類型 + 已適配高達 `24+` 作業系統,涵蓋各類版本,精準辨識系統類型 腳本相容性高,不支援的系統會有對應提示並無操作跳出 - :material-vector-triangle:{ .lg .middle } __多元軟體源適配__