From ee594ba55bf2cbb090810038f040052c659e6da0 Mon Sep 17 00:00:00 2001 From: Jack Date: Thu, 21 May 2026 18:03:22 +0800 Subject: [PATCH] docs: sync TUI config translations and Zen pricing (#28620) --- packages/web/src/content/docs/ar/tui.mdx | 54 +++++++++++++++---- packages/web/src/content/docs/ar/zen.mdx | 2 +- packages/web/src/content/docs/bs/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/bs/zen.mdx | 2 +- packages/web/src/content/docs/da/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/da/zen.mdx | 2 +- packages/web/src/content/docs/de/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/de/zen.mdx | 2 +- packages/web/src/content/docs/es/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/es/zen.mdx | 2 +- packages/web/src/content/docs/fr/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/fr/zen.mdx | 2 +- packages/web/src/content/docs/it/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/it/zen.mdx | 2 +- packages/web/src/content/docs/ja/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/ja/zen.mdx | 2 +- packages/web/src/content/docs/ko/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/ko/zen.mdx | 2 +- packages/web/src/content/docs/nb/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/nb/zen.mdx | 2 +- packages/web/src/content/docs/pl/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/pl/zen.mdx | 2 +- packages/web/src/content/docs/pt-br/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/pt-br/zen.mdx | 2 +- packages/web/src/content/docs/ru/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/ru/zen.mdx | 2 +- packages/web/src/content/docs/th/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/th/zen.mdx | 2 +- packages/web/src/content/docs/tr/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/tr/zen.mdx | 2 +- packages/web/src/content/docs/zen.mdx | 2 +- packages/web/src/content/docs/zh-cn/tui.mdx | 57 +++++++++++++++++---- packages/web/src/content/docs/zh-cn/zen.mdx | 2 +- packages/web/src/content/docs/zh-tw/tui.mdx | 35 +++++++++++-- packages/web/src/content/docs/zh-tw/zen.mdx | 2 +- 35 files changed, 591 insertions(+), 81 deletions(-) diff --git a/packages/web/src/content/docs/ar/tui.mdx b/packages/web/src/content/docs/ar/tui.mdx index bef6fda3fa..2a437d4841 100644 --- a/packages/web/src/content/docs/ar/tui.mdx +++ b/packages/web/src/content/docs/ar/tui.mdx @@ -352,28 +352,64 @@ How is auth handled in @packages/functions/src/api/index.ts? ## الإعداد -يمكنك تخصيص سلوك واجهة TUI عبر ملف إعدادات OpenCode. +يمكنك تخصيص سلوك TUI من خلال `tui.json` (أو `tui.jsonc`). -```json title="opencode.json" +```json title="tui.json" { - "$schema": "https://opencode.ai/config.json", - "tui": { - "scroll_speed": 3, - "scroll_acceleration": { - "enabled": true + "$schema": "https://opencode.ai/tui.json", + "theme": "opencode", + "leader_timeout": 2000, + "keybinds": { + "leader": "ctrl+x", + "command_list": "ctrl+p" + }, + "scroll_speed": 3, + "scroll_acceleration": { + "enabled": false + }, + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" } } } ``` +هذا منفصل عن `opencode.json`، الذي يضبط سلوك الخادم ووقت التشغيل. + +يتم دمج `keybinds` مع الاختصارات الافتراضية المدمجة، لذلك لا تحتاج إلا إلى ضبط الاختصارات التي تريد تغييرها. + ### الخيارات -- `scroll_acceleration` - فعّل تسارع التمرير على نمط macOS لتمرير سلس وطبيعي. عند تفعيله، تزداد سرعة التمرير مع إيماءات التمرير السريعة وتبقى دقيقة للحركات الأبطأ. **يتقدّم هذا الإعداد على `scroll_speed` ويستبدله عند تفعيله.** -- `scroll_speed` - يتحكم في سرعة تمرير واجهة TUI عند استخدام أوامر التمرير (الحد الأدنى: `1`). القيمة الافتراضية هي `3`. **ملاحظة: يتم تجاهل هذا إذا تم ضبط `scroll_acceleration.enabled` على `true`.** +- `theme` - يحدد سمة UI. [اعرف المزيد](/docs/themes). +- `keybinds` - يخصص اختصارات لوحة المفاتيح. [اعرف المزيد](/docs/keybinds). +- `leader_timeout` - يتحكم في مدة انتظار OpenCode بعد الضغط على leader key. القيمة الافتراضية `2000`. +- `scroll_acceleration.enabled` - يفعّل تسارع التمرير على نمط macOS لتمرير سلس وطبيعي. عند تفعيله، تزداد سرعة التمرير مع إيماءات التمرير السريعة وتبقى دقيقة للحركات الأبطأ. **يتقدّم هذا الإعداد على `scroll_speed` ويستبدله عند تفعيله.** +- `scroll_speed` - يتحكم في سرعة تمرير TUI عند استخدام أوامر التمرير (الحد الأدنى: `0.001`، ويدعم القيم العشرية). القيمة الافتراضية `3`. **ملاحظة: يتم تجاهل هذا إذا تم ضبط `scroll_acceleration.enabled` على `true`.** - `diff_style` - يتحكم في عرض الفروقات (diff). القيمة `"auto"` تتكيف مع عرض terminal، و`"stacked"` تعرض عمودًا واحدًا دائمًا. +- `mouse` - يفعّل أو يعطّل التقاط الماوس في TUI (القيمة الافتراضية: `true`). عند تعطيله، يتم الحفاظ على سلوك terminal الأصلي لتحديد النص والتمرير بالماوس. +- `attention` - يضبط desktop notifications والأصوات في TUI. معطل افتراضيًا. استخدم `OPENCODE_TUI_CONFIG` لتحميل مسار إعدادات TUI مخصص. +### Attention + +تجعل ميزة Attention واجهة TUI تنبهك عندما ينتظر OpenCode ردًا منك، أو يحتاج إلى الموافقة على permission، أو يواجه session error، أو ينهي session. فعّلها باستخدام `attention.enabled`؛ تشغّل الأحداث المدمجة صوتًا عند حدوثها. لا تُرسل desktop notifications إلا عندما لا تكون نافذة terminal في المقدمة، ولا تُستخدم مع أحداث subagent. + +- `enabled` - يفعّل جميع notifications والأصوات الخاصة بميزة Attention. القيمة الافتراضية `false`. +- `notifications` - عند تفعيل Attention، يسمح لـ TUI بإرسال desktop notifications عبر terminal. القيمة الافتراضية `true`. +- `sound` - عند تفعيل Attention، يسمح بتشغيل أصوات التنبيه. القيمة الافتراضية `true`. +- `volume` - مستوى صوت التنبيهات الافتراضي من `0` إلى `1`. القيمة الافتراضية `0.4`. +- `sound_pack` - sound pack ID المراد استخدامه. القيمة الافتراضية `opencode.default`. +- `sounds` - يحدد ملفات صوت مخصصة لـ `default` أو `question` أو `permission` أو `error` أو `done` أو `subagent_done`. يمكن أن تكون المسارات مطلقة، أو `file://` URLs، أو نسبية إلى `tui.json`. + --- ## التخصيص diff --git a/packages/web/src/content/docs/ar/zen.mdx b/packages/web/src/content/docs/ar/zen.mdx index b3ac5a88c8..1b12d2dda6 100644 --- a/packages/web/src/content/docs/ar/zen.mdx +++ b/packages/web/src/content/docs/ar/zen.mdx @@ -139,7 +139,7 @@ https://opencode.ai/zen/v1/models | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/bs/tui.mdx b/packages/web/src/content/docs/bs/tui.mdx index ef09a4caa0..98c7c4d728 100644 --- a/packages/web/src/content/docs/bs/tui.mdx +++ b/packages/web/src/content/docs/bs/tui.mdx @@ -364,29 +364,58 @@ Možete prilagoditi TUI ponašanje putem `tui.json` (ili `tui.jsonc`). { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` Ovo je odvojeno od `opencode.json`, koji konfiguriše ponašanje servera/izvršavanja. +`keybinds` se spaja s ugrađenim zadanim vrijednostima, tako da trebate konfigurisati samo prečice koje želite promijeniti. + ### Opcije - `theme` - Postavlja vašu UI temu. [Saznajte više](/docs/themes). - `keybinds` - Prilagođava prečice na tastaturi. [Saznajte više](/docs/keybinds). +- `leader_timeout` - Kontroliše koliko dugo OpenCode čeka nakon leader key. Podrazumijevano je `2000`. - `scroll_acceleration.enabled` - ​​Omogućite ubrzanje pomicanja u macOS stilu za glatko, prirodno pomicanje. Kada je omogućeno, brzina pomicanja se povećava brzim pokretima pomicanja i ostaje precizna za sporije pokrete. **Ova postavka ima prednost nad `scroll_speed` i nadjačava je kada je omogućena.** - `scroll_speed` - ​​Kontrolira koliko brzo TUI skroluje kada se koriste komande za pomeranje (minimum: `0.001`, podržava decimalne vrijednosti). Podrazumevano je `3`. **Napomena: Ovo se zanemaruje ako je `scroll_acceleration.enabled` postavljeno na `true`.** - `diff_style` - Kontrolira prikazivanje razlike. `"auto"` se prilagođava širini terminala, `"stacked"` uvijek prikazuje raspored u jednoj koloni. +- `mouse` - Omogućava ili onemogućava hvatanje miša u TUI (podrazumijevano: `true`). Kada je onemogućeno, zadržava se izvorno ponašanje terminala za označavanje i pomicanje mišem. +- `attention` - Konfiguriše desktop obavještenja i zvukove za TUI. Podrazumijevano je onemogućeno. Koristite `OPENCODE_TUI_CONFIG` da učitate prilagođenu putanju TUI konfiguracije. +### Attention + +Attention omogućava da vas TUI obavijesti kada OpenCode čeka odgovor, treba odobrenje dozvole, prijavi grešku sesije ili završi sesiju. Omogućite ga pomoću `attention.enabled`; ugrađeni događaji reproduciraju zvuk kada se dogode. Desktop obavještenja se šalju samo kada prozor terminala nije u fokusu i ne koriste se za subagent događaje. + +- `enabled` - Omogućava sva obavještenja i zvukove za Attention. Podrazumijevano je `false`. +- `notifications` - Kada je Attention omogućen, dozvoljava TUI-ju da šalje desktop obavještenja putem terminala. Podrazumijevano je `true`. +- `sound` - Kada je Attention omogućen, dozvoljava zvukove upozorenja. Podrazumijevano je `true`. +- `volume` - Podrazumijevana jačina zvukova upozorenja od `0` do `1`. Podrazumijevano je `0.4`. +- `sound_pack` - Sound pack ID koji se koristi. Podrazumijevano je `opencode.default`. +- `sounds` - Postavlja prilagođene zvučne datoteke za `default`, `question`, `permission`, `error`, `done` ili `subagent_done`. Putanje mogu biti apsolutne, `file://` URL-ovi ili relativne u odnosu na `tui.json`. + --- ## Prilagođavanje diff --git a/packages/web/src/content/docs/bs/zen.mdx b/packages/web/src/content/docs/bs/zen.mdx index 074518287f..149fa1563c 100644 --- a/packages/web/src/content/docs/bs/zen.mdx +++ b/packages/web/src/content/docs/bs/zen.mdx @@ -146,7 +146,7 @@ Podržavamo pay-as-you-go model. Ispod su cijene **po 1M tokena**. | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/da/tui.mdx b/packages/web/src/content/docs/da/tui.mdx index c1c0de0fd2..e7481f7257 100644 --- a/packages/web/src/content/docs/da/tui.mdx +++ b/packages/web/src/content/docs/da/tui.mdx @@ -358,29 +358,58 @@ Du kan tilpasse TUI-adfærd gennem `tui.json` (eller `tui.jsonc`). { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` Dette er adskilt fra `opencode.json`, som konfigurerer server-/kørselstidsadfærd. +`keybinds` flettes sammen med de indbyggede standarder, så du behøver kun at konfigurere de genveje, du vil ændre. + ### Indstillinger - `theme` - Indstiller dit brugergrænsefladetema. [Læs mere](/docs/themes). - `keybinds` - Tilpasser tastaturgenveje. [Læs mere](/docs/keybinds). +- `leader_timeout` - Styrer hvor længe OpenCode venter efter leader key. Standard er `2000`. - `scroll_acceleration.enabled` - Aktiver rulleacceleration i macOS-stil for jævn, naturlig rulning. Når aktiveret, øger rullehastigheden med hurtige rullebevægelser og forbliver præcis for langsommere bevægelser. **Denne indstilling har forrang over `scroll_speed` og tilsidesætter den, når den er aktiveret.** - `scroll_speed` - Styrer hvor hurtigt TUI ruller, når du bruger rullekommandoer (minimum: `0.001`, understøtter decimalværdier). Standard er `3`. **Bemærk: Dette ignoreres hvis `scroll_acceleration.enabled` er sat til `true`.** - `diff_style` - Styrer diff-gengivelse. `"auto"` tilpasser sig terminalbredde, `"stacked"` viser altid et enkeltkolonne-layout. +- `mouse` - Aktiverer eller deaktiverer musefangst i TUI (standard: `true`). Når den er deaktiveret, bevares terminalens oprindelige musemarkering og rulning. +- `attention` - Konfigurerer skrivebordsnotifikationer og lyde for TUI. Deaktiveret som standard. Brug `OPENCODE_TUI_CONFIG` til at indlæse en brugerdefineret TUI-konfigurationssti. +### Attention + +Attention lader TUI give dig besked, når OpenCode venter på et svar, kræver godkendelse af en tilladelse, rapporterer en sessionsfejl eller har afsluttet en session. Aktivér det med `attention.enabled`; indbyggede hændelser afspiller en lyd, når de sker. Skrivebordsnotifikationer sendes kun, når terminalvinduet ikke er i fokus, og bruges ikke til subagent-hændelser. + +- `enabled` - Aktiverer alle notifikationer og lyde for Attention. Standard er `false`. +- `notifications` - Når Attention er aktiveret, lader dette TUI sende skrivebordsnotifikationer via terminalen. Standard er `true`. +- `sound` - Når Attention er aktiveret, tillader dette advarselslyde. Standard er `true`. +- `volume` - Standard lydstyrke for advarselslyde fra `0` til `1`. Standard er `0.4`. +- `sound_pack` - Sound pack-ID der skal bruges. Standard er `opencode.default`. +- `sounds` - Angiver brugerdefinerede lydfiler for `default`, `question`, `permission`, `error`, `done` eller `subagent_done`. Stier kan være absolutte, `file://` URL'er eller relative til `tui.json`. + --- ## Tilpasning diff --git a/packages/web/src/content/docs/da/zen.mdx b/packages/web/src/content/docs/da/zen.mdx index bc888087cf..b60b85da9d 100644 --- a/packages/web/src/content/docs/da/zen.mdx +++ b/packages/web/src/content/docs/da/zen.mdx @@ -146,7 +146,7 @@ Vi understøtter en pay-as-you-go-model. Nedenfor er priserne **pr. 1M tokens**. | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/de/tui.mdx b/packages/web/src/content/docs/de/tui.mdx index 144662c119..5f9e9e23e9 100644 --- a/packages/web/src/content/docs/de/tui.mdx +++ b/packages/web/src/content/docs/de/tui.mdx @@ -361,29 +361,58 @@ Du kannst das Verhalten der TUI ueber die Datei `tui.json` (oder `tui.jsonc`) an { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` Dies ist getrennt von `opencode.json`, welche das Server-/Runtime-Verhalten konfiguriert. +`keybinds` wird mit den integrierten Standardwerten zusammengeführt, daher musst du nur die Tastenkombinationen konfigurieren, die du ändern möchtest. + ### Optionen - `theme` - Setzt dein UI-Theme. [Mehr dazu](/docs/themes). - `keybinds` - Passt Tastenkombinationen an. [Mehr dazu](/docs/keybinds). +- `leader_timeout` - Steuert, wie lange OpenCode nach der leader key wartet. Standard ist `2000`. - `scroll_acceleration.enabled` - Aktiviert Scroll-Beschleunigung im macOS-Stil fuer weiches, natuerliches Scrollen. Wenn aktiviert, erhoeht sich die Scroll-Geschwindigkeit bei schnellen Gesten und bleibt praezise bei langsamen Bewegungen. **Diese Einstellung hat Vorrang vor `scroll_speed` und ueberschreibt es, wenn aktiviert.** - `scroll_speed` - Steuert, wie schnell die TUI scrollt (Minimum: `0.001`, unterstuetzt Dezimalwerte). Standard ist `3`. **Hinweis: Wird ignoriert, wenn `scroll_acceleration.enabled` auf `true` gesetzt ist.** - `diff_style` - Steuert die Diff-Darstellung. `"auto"` passt sich der Terminalbreite an, `"stacked"` zeigt immer ein einspaltiges Layout. +- `mouse` - Aktiviert oder deaktiviert die Mauserfassung im TUI (Standard: `true`). Wenn deaktiviert, bleibt das native Mausauswahl- und Scrollverhalten des Terminals erhalten. +- `attention` - Konfiguriert Desktop-Benachrichtigungen und Sounds des TUI. Standardmäßig deaktiviert. Verwende `OPENCODE_TUI_CONFIG`, um einen benutzerdefinierten TUI-Konfigurationspfad zu laden. +### Attention + +Attention lässt das TUI dich benachrichtigen, wenn OpenCode auf eine Antwort wartet, eine Berechtigung bestätigt werden muss, ein Sitzungsfehler aufgetreten ist oder eine Sitzung abgeschlossen wurde. Aktiviere es mit `attention.enabled`; integrierte Ereignisse spielen beim Auftreten einen Sound ab. Desktop-Benachrichtigungen werden nur gesendet, wenn das Terminalfenster nicht fokussiert ist, und nicht für subagent-Ereignisse verwendet. + +- `enabled` - Aktiviert alle Benachrichtigungen und Sounds von Attention. Standard ist `false`. +- `notifications` - Erlaubt dem TUI bei aktiviertem Attention, Desktop-Benachrichtigungen über das Terminal zu senden. Standard ist `true`. +- `sound` - Erlaubt bei aktiviertem Attention das Abspielen von Hinweistönen. Standard ist `true`. +- `volume` - Standardlautstärke der Hinweistöne von `0` bis `1`. Standard ist `0.4`. +- `sound_pack` - Zu verwendende sound pack ID. Standard ist `opencode.default`. +- `sounds` - Legt eigene Sounddateien für `default`, `question`, `permission`, `error`, `done` oder `subagent_done` fest. Pfade können absolut, `file://` URLs oder relativ zu `tui.json` sein. + --- ## Anpassung diff --git a/packages/web/src/content/docs/de/zen.mdx b/packages/web/src/content/docs/de/zen.mdx index 833e6fa800..27c521b57c 100644 --- a/packages/web/src/content/docs/de/zen.mdx +++ b/packages/web/src/content/docs/de/zen.mdx @@ -135,7 +135,7 @@ Wir unterstützen ein Pay-as-you-go-Modell. Unten findest du die Preise **pro 1M | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/es/tui.mdx b/packages/web/src/content/docs/es/tui.mdx index 02f14d55ad..0062649091 100644 --- a/packages/web/src/content/docs/es/tui.mdx +++ b/packages/web/src/content/docs/es/tui.mdx @@ -361,29 +361,58 @@ Puede personalizar el comportamiento de TUI a través de `tui.json` (o `tui.json { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` Esto es independiente de `opencode.json`, que configura el comportamiento del servidor/tiempo de ejecución. +`keybinds` se combina con los valores predeterminados integrados, así que solo necesitas configurar los atajos que quieras cambiar. + ### Opciones - `theme`: establece su tema de interfaz de usuario. [Más información](/docs/themes). - `keybinds`: personaliza los atajos de teclado. [Más información](/docs/keybinds). +- `leader_timeout`: controla cuánto tiempo espera OpenCode después de la leader key. El valor predeterminado es `2000`. - `scroll_acceleration.enabled`: habilite la aceleración de desplazamiento estilo macOS para un desplazamiento suave y natural. Cuando está habilitado, la velocidad de desplazamiento aumenta con gestos de desplazamiento rápido y se mantiene precisa para movimientos más lentos. **Esta configuración tiene prioridad sobre `scroll_speed` y la anula cuando está habilitada.** - `scroll_speed`: controla la rapidez con la que se desplaza el TUI cuando se utilizan comandos de desplazamiento (mínimo: `0.001`, admite valores decimales). El valor predeterminado es `3`. **Nota: Esto se ignora si `scroll_acceleration.enabled` está configurado en `true`.** - `diff_style`: controla la representación de diferencias. `"auto"` se adapta al ancho del terminal, `"stacked"` siempre muestra un diseño de una sola columna. +- `mouse`: habilita o deshabilita la captura del mouse en el TUI (predeterminado: `true`). Cuando está deshabilitada, se conserva el comportamiento nativo del terminal para seleccionar y desplazarse con el mouse. +- `attention`: configura las notificaciones de escritorio y los sonidos del TUI. Deshabilitado de forma predeterminada. Utilice `OPENCODE_TUI_CONFIG` para cargar una ruta de configuración de TUI personalizada. +### Attention + +Attention permite que el TUI te avise cuando OpenCode necesita que respondas una pregunta, apruebes un permiso, revises un error de sesión o sepas que una sesión terminó. Actívalo con `attention.enabled`; los eventos integrados reproducen sonidos al ocurrir. Las notificaciones de escritorio solo se envían cuando la ventana del terminal no está enfocada y no se usan para eventos de subagent. + +- `enabled`: activa todas las notificaciones y sonidos de Attention. El valor predeterminado es `false`. +- `notifications`: cuando Attention está activo, permite que el TUI envíe notificaciones de escritorio a través del terminal. El valor predeterminado es `true`. +- `sound`: cuando Attention está activo, permite reproducir sonidos de aviso. El valor predeterminado es `true`. +- `volume`: volumen predeterminado de los sonidos, de `0` a `1`. El valor predeterminado es `0.4`. +- `sound_pack`: ID del sound pack que se usará. El valor predeterminado es `opencode.default`. +- `sounds`: define archivos de sonido personalizados para `default`, `question`, `permission`, `error`, `done` o `subagent_done`. Las rutas pueden ser absolutas, URL `file://` o relativas a `tui.json`. + --- ## Personalización diff --git a/packages/web/src/content/docs/es/zen.mdx b/packages/web/src/content/docs/es/zen.mdx index 65f078b3ec..6ee0c6bd8d 100644 --- a/packages/web/src/content/docs/es/zen.mdx +++ b/packages/web/src/content/docs/es/zen.mdx @@ -146,7 +146,7 @@ Admitimos un modelo de pago por uso. A continuación se muestran los precios **p | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/fr/tui.mdx b/packages/web/src/content/docs/fr/tui.mdx index 8129eb2012..79de0d43fb 100644 --- a/packages/web/src/content/docs/fr/tui.mdx +++ b/packages/web/src/content/docs/fr/tui.mdx @@ -361,29 +361,58 @@ Vous pouvez personnaliser le comportement de TUI via `tui.json` (ou `tui.jsonc`) { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` Ceci est séparé de `opencode.json`, qui configure le comportement du serveur/d'exécution. +`keybinds` est fusionné avec les valeurs par défaut intégrées, vous ne devez donc configurer que les raccourcis que vous souhaitez modifier. + ### Options - `theme` - Définit votre thème d'interface utilisateur. [En savoir plus](/docs/themes). - `keybinds` - Personnalise les raccourcis clavier. [En savoir plus](/docs/keybinds). +- `leader_timeout` - Contrôle la durée pendant laquelle OpenCode attend après la leader key. Valeur par défaut : `2000`. - `scroll_acceleration.enabled` - Activez l'accélération de défilement de style macOS pour un défilement fluide et naturel. Lorsqu'elle est activée, la vitesse de défilement augmente avec les gestes de défilement rapides et reste précise pour les mouvements plus lents. **Ce paramètre est prioritaire sur `scroll_speed` et le remplace lorsqu'il est activé.** - `scroll_speed` - Contrôle la vitesse de défilement du TUI lors de l'utilisation des commandes de défilement (minimum : `0.001`, prend en charge les valeurs décimales). La valeur par défaut est `3`. **Remarque : Ceci est ignoré si `scroll_acceleration.enabled` est défini sur `true`.** - `diff_style` - Contrôle le rendu différentiel. `"auto"` s'adapte à la largeur du terminal, `"stacked"` affiche toujours une seule colonne. +- `mouse` - Active ou désactive la capture de la souris dans le TUI (valeur par défaut : `true`). Lorsque cette option est désactivée, le comportement natif du terminal pour la sélection et le défilement à la souris est conservé. +- `attention` - Configure les notifications de bureau et les sons du TUI. Désactivé par défaut. Utilisez `OPENCODE_TUI_CONFIG` pour charger un chemin de configuration TUI personnalisé. +### Attention + +Attention permet au TUI de vous prévenir quand OpenCode attend une réponse, une autorisation, qu'une erreur de session doit être consultée ou qu'une session est terminée. Activez-le avec `attention.enabled` ; les événements intégrés jouent un son lorsqu'ils se produisent. Les notifications de bureau ne sont envoyées que lorsque la fenêtre du terminal n'est pas au premier plan, et elles ne sont pas utilisées pour les événements de subagent. + +- `enabled` - Active toutes les notifications et tous les sons d'Attention. Valeur par défaut : `false`. +- `notifications` - Lorsque Attention est activé, autorise le TUI à envoyer des notifications de bureau via le terminal. Valeur par défaut : `true`. +- `sound` - Lorsque Attention est activé, autorise la lecture des sons d'alerte. Valeur par défaut : `true`. +- `volume` - Volume par défaut des sons, de `0` à `1`. Valeur par défaut : `0.4`. +- `sound_pack` - ID du sound pack à utiliser. Valeur par défaut : `opencode.default`. +- `sounds` - Définit des fichiers sonores personnalisés pour `default`, `question`, `permission`, `error`, `done` ou `subagent_done`. Les chemins peuvent être absolus, des URL `file://` ou relatifs à `tui.json`. + --- ## Personnalisation diff --git a/packages/web/src/content/docs/fr/zen.mdx b/packages/web/src/content/docs/fr/zen.mdx index 85fcafd8c3..971444ab96 100644 --- a/packages/web/src/content/docs/fr/zen.mdx +++ b/packages/web/src/content/docs/fr/zen.mdx @@ -135,7 +135,7 @@ Nous prenons en charge un modèle de paiement à l'utilisation. Vous trouverez c | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/it/tui.mdx b/packages/web/src/content/docs/it/tui.mdx index 2e4efa2608..93ef1a86d5 100644 --- a/packages/web/src/content/docs/it/tui.mdx +++ b/packages/web/src/content/docs/it/tui.mdx @@ -358,29 +358,58 @@ Puoi personalizzare il comportamento della TUI tramite `tui.json` (o `tui.jsonc` { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` Questo è separato da `opencode.json`, che configura il comportamento di server/runtime. +`keybinds` viene unito ai valori predefiniti integrati, quindi devi configurare solo le scorciatoie che vuoi modificare. + ### Opzioni - `theme` - Imposta il tema della UI. [Scopri di più](/docs/themes). - `keybinds` - Personalizza le scorciatoie da tastiera. [Scopri di più](/docs/keybinds). +- `leader_timeout` - Controlla per quanto tempo OpenCode attende dopo il leader key. Default: `2000`. - `scroll_acceleration.enabled` - Abilita l'accelerazione di scroll in stile macOS per uno scorrimento fluido e naturale. Quando abilitata, la velocità aumenta con gesture rapide e resta precisa con movimenti lenti. **Questa impostazione ha precedenza su `scroll_speed` e lo sovrascrive quando attiva.** - `scroll_speed` - Controlla la velocità di scorrimento della TUI quando usi i comandi di scroll (minimo: `0.001`, supporta valori decimali). Default: `3`. **Nota: viene ignorata se `scroll_acceleration.enabled` è impostato a `true`.** - `diff_style` - Controlla il rendering delle diff. `"auto"` si adatta alla larghezza del terminale, `"stacked"` mostra sempre un layout a colonna singola. +- `mouse` - Abilita o disabilita la cattura del mouse nella TUI (default: `true`). Quando è disabilitata, il comportamento nativo del terminale per selezione e scorrimento con il mouse viene preservato. +- `attention` - Configura notifiche desktop e suoni della TUI. Disabilitato per impostazione predefinita. Usa `OPENCODE_TUI_CONFIG` per caricare un path di configurazione TUI personalizzato. +### Attention + +Attention permette alla TUI di avvisarti quando OpenCode aspetta una risposta, richiede l'approvazione di un permesso, incontra un errore di sessione o completa una sessione. Abilitala con `attention.enabled`; gli eventi integrati riproducono un suono quando si verificano. Le notifiche desktop vengono inviate solo quando la finestra del terminale non è in primo piano e non vengono usate per gli eventi subagent. + +- `enabled` - Abilita tutte le notifiche e i suoni di Attention. Default: `false`. +- `notifications` - Quando Attention è abilitato, consente alla TUI di inviare notifiche desktop tramite il terminale. Default: `true`. +- `sound` - Quando Attention è abilitato, consente di riprodurre suoni di avviso. Default: `true`. +- `volume` - Volume predefinito dei suoni, da `0` a `1`. Default: `0.4`. +- `sound_pack` - ID del sound pack da usare. Default: `opencode.default`. +- `sounds` - Imposta file audio personalizzati per `default`, `question`, `permission`, `error`, `done` o `subagent_done`. I percorsi possono essere assoluti, URL `file://` o relativi a `tui.json`. + --- ## Personalizzazione diff --git a/packages/web/src/content/docs/it/zen.mdx b/packages/web/src/content/docs/it/zen.mdx index abf0eb3606..9100f95d10 100644 --- a/packages/web/src/content/docs/it/zen.mdx +++ b/packages/web/src/content/docs/it/zen.mdx @@ -146,7 +146,7 @@ Supportiamo un modello pay-as-you-go. Qui sotto trovi i prezzi **per 1M token**. | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/ja/tui.mdx b/packages/web/src/content/docs/ja/tui.mdx index 0049c7b014..a3e11cc1b5 100644 --- a/packages/web/src/content/docs/ja/tui.mdx +++ b/packages/web/src/content/docs/ja/tui.mdx @@ -355,29 +355,58 @@ VS Code などの一部のエディターは、`--wait` フラグを使用して { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` これは、サーバー/ランタイムの動作を構成する `opencode.json` とは別です。 +`keybinds` は組み込みのデフォルトとマージされるため、変更したいショートカットだけを設定すれば十分です。 + ### オプション - `theme` - UI テーマを設定します。[詳細はこちら](/docs/themes)。 - `keybinds` - キーボードショートカットをカスタマイズします。[詳細はこちら](/docs/keybinds)。 +- `leader_timeout` - leader key を押したあと、OpenCode が次のキー入力を待つ時間を制御します。デフォルトは `2000` です。 - `scroll_acceleration.enabled` - macOS スタイルのスクロールアクセラレーションを有効にして、スムーズで自然なスクロールを実現します。有効にすると、高速スクロールジェスチャではスクロール速度が向上し、ゆっくりとした動きでは正確なままになります。 **この設定は `scroll_speed` よりも優先され、有効になっている場合は上書きされます。** - `scroll_speed` - スクロールコマンドを使用するときに TUI がスクロールする速度を制御します (最小: `0.001`、小数をサポート)。デフォルトは `3` です。 **注: `scroll_acceleration.enabled` が `true` に設定されている場合、これは無視されます。** - `diff_style` - 差分レンダリングを制御します。 `"auto"` はターミナルの幅に適応し、`"stacked"` は常に 1 列のレイアウトを表示します。 +- `mouse` - TUI でのマウスキャプチャを有効または無効にします (デフォルト: `true`)。無効にすると、ターミナル本来のマウス選択/スクロール動作が維持されます。 +- `attention` - TUI のデスクトップ通知とサウンドを設定します。デフォルトでは無効です。 カスタム TUI 設定パスをロードするには、`OPENCODE_TUI_CONFIG` を使用します。 +### Attention + +Attention を有効にすると、OpenCode が回答待ち、権限の承認待ち、セッションエラー、またはセッション完了を知らせたいときに、TUI がサウンドやデスクトップ通知で知らせます。`attention.enabled` で有効化します。組み込みイベントは発生時にサウンドを再生します。デスクトップ通知はターミナルウィンドウにフォーカスがない場合にのみ送信され、subagent イベントには使われません。 + +- `enabled` - Attention のすべての通知とサウンドを有効にします。デフォルトは `false` です。 +- `notifications` - Attention が有効なとき、TUI がターミナル経由でデスクトップ通知を送信できるようにします。デフォルトは `true` です。 +- `sound` - Attention が有効なとき、通知音の再生を許可します。デフォルトは `true` です。 +- `volume` - 通知音のデフォルト音量を `0` から `1` で指定します。デフォルトは `0.4` です。 +- `sound_pack` - 使用する sound pack ID です。デフォルトは `opencode.default` です。 +- `sounds` - `default`、`question`、`permission`、`error`、`done`、または `subagent_done` に使うカスタムサウンドファイルを指定します。パスは絶対パス、`file://` URL、または `tui.json` からの相対パスにできます。 + --- ## カスタマイズ diff --git a/packages/web/src/content/docs/ja/zen.mdx b/packages/web/src/content/docs/ja/zen.mdx index 92969a832f..2c5eb1f980 100644 --- a/packages/web/src/content/docs/ja/zen.mdx +++ b/packages/web/src/content/docs/ja/zen.mdx @@ -135,7 +135,7 @@ https://opencode.ai/zen/v1/models | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/ko/tui.mdx b/packages/web/src/content/docs/ko/tui.mdx index 669d899d0c..db2b1297e0 100644 --- a/packages/web/src/content/docs/ko/tui.mdx +++ b/packages/web/src/content/docs/ko/tui.mdx @@ -357,29 +357,58 @@ VS Code와 같은 일부 편집기는 `--wait` 플래그와 함께 시작해야 { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` 이는 서버/런타임 동작을 구성하는 `opencode.json`과는 별개입니다. +`keybinds`는 내장 기본값과 병합되므로 변경하려는 단축키만 설정하면 됩니다. + ### 옵션 - `theme` - UI 테마를 설정합니다. [더 알아보기](/docs/themes). - `keybinds` - 키보드 단축키를 사용자 정의합니다. [더 알아보기](/docs/keybinds). +- `leader_timeout` - leader key를 누른 뒤 OpenCode가 다음 키 입력을 기다리는 시간을 제어합니다. 기본값은 `2000`입니다. - `scroll_acceleration.enabled` - 부드럽고 자연스러운 스크롤을 위해 macOS 스타일의 스크롤 가속을 활성화합니다. 활성화하면 빠른 스크롤 제스처로 스크롤 속도가 증가하고 느린 움직임에서는 정밀하게 유지됩니다. **이 설정은 `scroll_speed`보다 우선하며 활성화 시 이를 덮어씁니다.** - `scroll_speed` - 스크롤 명령을 사용할 때 TUI 스크롤 속도를 제어합니다 (최소: `0.001`, 소수점 값 지원). 기본값은 `3`입니다. **참고: `scroll_acceleration.enabled`가 `true`로 설정되면 무시됩니다.** - `diff_style` - diff 렌더링 방식을 제어합니다. `"auto"`는 터미널 너비에 적응하고, `"stacked"`는 항상 단일 열 레이아웃을 표시합니다. +- `mouse` - TUI에서 마우스 캡처를 활성화하거나 비활성화합니다(기본값: `true`). 비활성화하면 터미널의 기본 마우스 선택/스크롤 동작이 유지됩니다. +- `attention` - TUI 데스크톱 알림과 사운드를 구성합니다. 기본적으로 비활성화되어 있습니다. `OPENCODE_TUI_CONFIG`를 사용하여 사용자 정의 TUI 설정 경로를 로드할 수 있습니다. +### Attention + +Attention을 사용하면 OpenCode가 답변을 기다리거나, 권한 승인이 필요하거나, 세션 오류가 발생했거나, 세션이 완료되었을 때 TUI가 사운드와 데스크톱 알림으로 알려줍니다. `attention.enabled`로 활성화합니다. 기본 제공 이벤트는 발생할 때 사운드를 재생합니다. 데스크톱 알림은 터미널 창에 포커스가 없을 때만 전송되며 subagent 이벤트에는 사용되지 않습니다. + +- `enabled` - Attention의 모든 알림과 사운드를 활성화합니다. 기본값은 `false`입니다. +- `notifications` - Attention이 활성화된 경우 TUI가 터미널을 통해 데스크톱 알림을 보낼 수 있도록 허용합니다. 기본값은 `true`입니다. +- `sound` - Attention이 활성화된 경우 알림음을 재생할 수 있도록 허용합니다. 기본값은 `true`입니다. +- `volume` - 알림음의 기본 볼륨이며 `0`부터 `1`까지입니다. 기본값은 `0.4`입니다. +- `sound_pack` - 사용할 sound pack ID입니다. 기본값은 `opencode.default`입니다. +- `sounds` - `default`, `question`, `permission`, `error`, `done` 또는 `subagent_done`에 사용할 사용자 지정 사운드 파일을 지정합니다. 경로는 절대 경로, `file://` URL 또는 `tui.json` 기준 상대 경로일 수 있습니다. + --- ## 사용자 정의 diff --git a/packages/web/src/content/docs/ko/zen.mdx b/packages/web/src/content/docs/ko/zen.mdx index 937dc19373..78264eb426 100644 --- a/packages/web/src/content/docs/ko/zen.mdx +++ b/packages/web/src/content/docs/ko/zen.mdx @@ -135,7 +135,7 @@ https://opencode.ai/zen/v1/models | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/nb/tui.mdx b/packages/web/src/content/docs/nb/tui.mdx index 741ba46029..485e7d9969 100644 --- a/packages/web/src/content/docs/nb/tui.mdx +++ b/packages/web/src/content/docs/nb/tui.mdx @@ -361,29 +361,58 @@ Du kan tilpasse TUI-oppførselen gjennom `tui.json` (eller `tui.jsonc`). { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` Dette er atskilt fra `opencode.json`, som konfigurerer server-/kjøretidsoppførsel. +`keybinds` slås sammen med de innebygde standardverdiene, så du trenger bare å konfigurere snarveiene du vil endre. + ### Alternativer - `theme` - Angir UI-temaet ditt. [Finn ut mer](/docs/themes). - `keybinds` - Tilpasser hurtigtaster. [Finn ut mer](/docs/keybinds). +- `leader_timeout` - Styrer hvor lenge OpenCode venter etter leader key. Standard er `2000`. - `scroll_acceleration.enabled` - Aktiver rulleakselerasjon i macOS-stil for jevn, naturlig rulling. Når aktivert, øker rullehastigheten med raske rullebevegelser og forblir presis for langsommere bevegelser. **Denne innstillingen har forrang over `scroll_speed` og overstyrer den når den er aktivert.** - `scroll_speed` - Styrer hvor raskt TUI ruller når du bruker rullekommandoer (minimum: `0.001`, støtter desimalverdier). Standard er `3`. **Merk: Dette ignoreres hvis `scroll_acceleration.enabled` er satt til `true`.** - `diff_style` - Kontrollerer diff-gjengivelse. `"auto"` tilpasser seg terminalbredden, `"stacked"` viser alltid en enkeltkolonneoppsett. +- `mouse` - Aktiverer eller deaktiverer musefangst i TUI (standard: `true`). Når dette er deaktivert, bevares terminalens opprinnelige oppførsel for musemarkering og rulling. +- `attention` - Konfigurerer skrivebordsvarsler og lyder for TUI. Deaktivert som standard. Bruk `OPENCODE_TUI_CONFIG` for å laste en egendefinert TUI-konfigurasjonsbane. +### Attention + +Attention lar TUI varsle deg når OpenCode venter på et svar, trenger godkjenning av en tillatelse, rapporterer en øktfeil eller har fullført en økt. Aktiver dette med `attention.enabled`; innebygde hendelser spiller av en lyd når de skjer. Skrivebordsvarsler sendes bare når terminalvinduet ikke er i fokus, og brukes ikke for subagent-hendelser. + +- `enabled` - Aktiverer alle varsler og lyder for Attention. Standard er `false`. +- `notifications` - Når Attention er aktivert, lar dette TUI sende skrivebordsvarsler via terminalen. Standard er `true`. +- `sound` - Når Attention er aktivert, tillater dette varslingslyder. Standard er `true`. +- `volume` - Standard volum for varslingslyder fra `0` til `1`. Standard er `0.4`. +- `sound_pack` - Sound pack-ID som skal brukes. Standard er `opencode.default`. +- `sounds` - Angir egendefinerte lydfiler for `default`, `question`, `permission`, `error`, `done` eller `subagent_done`. Stier kan være absolutte, `file://` URL-er eller relative til `tui.json`. + --- ## Tilpasning diff --git a/packages/web/src/content/docs/nb/zen.mdx b/packages/web/src/content/docs/nb/zen.mdx index 1407432036..47949bdf41 100644 --- a/packages/web/src/content/docs/nb/zen.mdx +++ b/packages/web/src/content/docs/nb/zen.mdx @@ -146,7 +146,7 @@ Vi støtter en pay-as-you-go-modell. Nedenfor er prisene **per 1M tokens**. | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/pl/tui.mdx b/packages/web/src/content/docs/pl/tui.mdx index 2d983cf84b..02728b81de 100644 --- a/packages/web/src/content/docs/pl/tui.mdx +++ b/packages/web/src/content/docs/pl/tui.mdx @@ -361,29 +361,58 @@ Możesz dostosować zachowanie TUI za pomocą pliku `tui.json` (lub `tui.jsonc`) { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` Jest to oddzielny plik od `opencode.json`, który konfiguruje zachowanie serwera/runtime. +`keybinds` jest łączone z wbudowanymi wartościami domyślnymi, więc wystarczy skonfigurować tylko te skróty, które chcesz zmienić. + ### Opcje - `theme` - Ustawia motyw interfejsu. [Dowiedz się więcej](/docs/themes). - `keybinds` - Dostosowuje skróty klawiszowe. [Dowiedz się więcej](/docs/keybinds). +- `leader_timeout` - Określa, jak długo OpenCode czeka po naciśnięciu leader key. Domyślnie `2000`. - `scroll_acceleration.enabled` — Włącz przyspieszenie przewijania w stylu macOS, aby zapewnić płynne, naturalne przewijanie. Po włączeniu prędkość przewijania wzrasta wraz z szybkimi gestami przewijania i pozostaje precyzyjna w przypadku wolniejszych ruchów. **To ustawienie ma pierwszeństwo przed `scroll_speed` i zastępuje je, gdy jest włączone.** - `scroll_speed` - Kontroluje szybkość przewijania TUI podczas korzystania z poleceń przewijania (minimum: `0.001`, obsługuje wartości dziesiętne). Wartość domyślna to `3`. **Uwaga: jest to ignorowane, jeśli `scroll_acceleration.enabled` jest ustawione na `true`.** - `diff_style` - Steruje renderowaniem różnic. `"auto"` dostosowuje się do szerokości terminala, `"stacked"` zawsze pokazuje układ jednokolumnowy. +- `mouse` - Włącza lub wyłącza przechwytywanie myszy w TUI (domyślnie `true`). Po wyłączeniu zachowane zostaje natywne zachowanie terminala przy zaznaczaniu i przewijaniu myszą. +- `attention` - Konfiguruje powiadomienia pulpitu i dźwięki TUI. Domyślnie wyłączone. Użyj `OPENCODE_TUI_CONFIG`, aby załadować niestandardową ścieżkę konfiguracji TUI. +### Attention + +Attention pozwala TUI powiadomić Cię, gdy OpenCode czeka na odpowiedź, wymaga zatwierdzenia uprawnienia, zgłasza błąd sesji albo informuje o zakończeniu sesji. Włącz tę funkcję za pomocą `attention.enabled`; wbudowane zdarzenia odtwarzają dźwięk, gdy wystąpią. Powiadomienia pulpitu są wysyłane tylko wtedy, gdy okno terminala nie jest aktywne, i nie są używane dla zdarzeń subagent. + +- `enabled` - Włącza wszystkie powiadomienia i dźwięki Attention. Domyślnie `false`. +- `notifications` - Gdy Attention jest włączone, pozwala TUI wysyłać powiadomienia pulpitu przez terminal. Domyślnie `true`. +- `sound` - Gdy Attention jest włączone, pozwala odtwarzać dźwięki powiadomień. Domyślnie `true`. +- `volume` - Domyślna głośność dźwięków powiadomień od `0` do `1`. Domyślnie `0.4`. +- `sound_pack` - ID sound pack do użycia. Domyślnie `opencode.default`. +- `sounds` - Ustawia niestandardowe pliki dźwiękowe dla `default`, `question`, `permission`, `error`, `done` lub `subagent_done`. Ścieżki mogą być bezwzględne, być URL-ami `file://` albo być względne względem `tui.json`. + --- ## Personalizacja diff --git a/packages/web/src/content/docs/pl/zen.mdx b/packages/web/src/content/docs/pl/zen.mdx index e2837c3286..2f47912d0a 100644 --- a/packages/web/src/content/docs/pl/zen.mdx +++ b/packages/web/src/content/docs/pl/zen.mdx @@ -146,7 +146,7 @@ Obsługujemy model pay-as-you-go. Poniżej znajdują się ceny **za 1M tokenów* | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/pt-br/tui.mdx b/packages/web/src/content/docs/pt-br/tui.mdx index 67de2138b6..ffd74c4299 100644 --- a/packages/web/src/content/docs/pt-br/tui.mdx +++ b/packages/web/src/content/docs/pt-br/tui.mdx @@ -358,29 +358,58 @@ Você pode personalizar o comportamento do TUI através de `tui.json` (ou `tui.j { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` Isso é separado do `opencode.json`, que configura o comportamento do servidor/runtime. +`keybinds` é combinado com os padrões internos, então você só precisa configurar os atalhos que deseja alterar. + ### Opções - `theme` - Define o tema da sua interface. [Saiba mais](/docs/themes). - `keybinds` - Personaliza atalhos de teclado. [Saiba mais](/docs/keybinds). +- `leader_timeout` - Controla por quanto tempo o OpenCode espera depois da leader key. O padrão é `2000`. - `scroll_acceleration.enabled` - Ative a aceleração de rolagem no estilo macOS para uma rolagem suave e natural. Quando ativado, a velocidade de rolagem aumenta com gestos de rolagem rápidos e permanece precisa para movimentos mais lentos. **Esta configuração tem precedência sobre `scroll_speed` e a substitui quando ativada.** - `scroll_speed` - Controla quão rápido o TUI rola ao usar comandos de rolagem (mínimo: `0.001`, suporta valores decimais). O padrão é `3`. **Nota: Isso é ignorado se `scroll_acceleration.enabled` estiver definido como `true`.** - `diff_style` - Controla a renderização de diffs. `"auto"` se adapta à largura do terminal, `"stacked"` sempre mostra um layout de coluna única. +- `mouse` - Ativa ou desativa a captura do mouse no TUI (padrão: `true`). Quando desativado, o comportamento nativo do terminal para seleção e rolagem com o mouse é preservado. +- `attention` - Configura notificações de desktop e sons do TUI. Desativado por padrão. Use `OPENCODE_TUI_CONFIG` para carregar um caminho de configuração TUI personalizado. +### Attention + +Attention permite que o TUI avise você quando o OpenCode espera uma resposta, precisa da aprovação de uma permissão, encontra um erro de sessão ou conclui uma sessão. Ative com `attention.enabled`; eventos integrados reproduzem sons quando acontecem. As notificações de desktop só são enviadas quando a janela do terminal não está em foco e não são usadas para eventos de subagent. + +- `enabled` - Ativa todas as notificações e sons de Attention. O padrão é `false`. +- `notifications` - Quando Attention está ativo, permite que o TUI envie notificações de desktop pelo terminal. O padrão é `true`. +- `sound` - Quando Attention está ativo, permite reproduzir sons de aviso. O padrão é `true`. +- `volume` - Volume padrão dos sons, de `0` a `1`. O padrão é `0.4`. +- `sound_pack` - ID do sound pack a ser usado. O padrão é `opencode.default`. +- `sounds` - Define arquivos de som personalizados para `default`, `question`, `permission`, `error`, `done` ou `subagent_done`. Os caminhos podem ser absolutos, URLs `file://` ou relativos a `tui.json`. + --- ## Personalização diff --git a/packages/web/src/content/docs/pt-br/zen.mdx b/packages/web/src/content/docs/pt-br/zen.mdx index a26a5532aa..9b34a9408f 100644 --- a/packages/web/src/content/docs/pt-br/zen.mdx +++ b/packages/web/src/content/docs/pt-br/zen.mdx @@ -135,7 +135,7 @@ Oferecemos um modelo pay-as-you-go. Abaixo estão os preços **por 1M tokens**. | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/ru/tui.mdx b/packages/web/src/content/docs/ru/tui.mdx index 1694908dba..19d44539fe 100644 --- a/packages/web/src/content/docs/ru/tui.mdx +++ b/packages/web/src/content/docs/ru/tui.mdx @@ -361,29 +361,58 @@ How is auth handled in @packages/functions/src/api/index.ts? { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` Это отдельный файл от `opencode.json`, который настраивает поведение сервера/выполнения. +`keybinds` объединяется со встроенными значениями по умолчанию, поэтому достаточно настроить только те сочетания клавиш, которые вы хотите изменить. + ### Параметры - `theme` — Устанавливает тему пользовательского интерфейса. [Подробнее](/docs/themes). - `keybinds` — Настраивает сочетания клавиш. [Подробнее](/docs/keybinds). +- `leader_timeout` — Управляет тем, как долго OpenCode ждёт после нажатия leader key. По умолчанию `2000`. - `scroll_acceleration.enabled` — включите ускорение прокрутки в стиле macOS для плавной и естественной прокрутки. Если этот параметр включен, скорость прокрутки увеличивается при быстрой прокрутке и остается точной при более медленных движениях. **Этот параметр имеет приоритет над `scroll_speed` и переопределяет его, если он включен.** - `scroll_speed` — контролирует скорость прокрутки TUI при использовании команд прокрутки (минимум: `0.001`, поддерживает десятичные значения). По умолчанию `3`. **Примечание. Это игнорируется, если для `scroll_acceleration.enabled` установлено значение `true`.** - `diff_style` — Управляет отображением различий. `"auto"` адаптируется к ширине терминала, `"stacked"` всегда показывает одноколоночный макет. +- `mouse` — Включает или отключает захват мыши в TUI (по умолчанию `true`). Если отключено, сохраняется нативное поведение терминала для выделения мышью и прокрутки. +- `attention` — Настраивает уведомления рабочего стола и звуки TUI. По умолчанию отключено. Используйте `OPENCODE_TUI_CONFIG` для загрузки пользовательского пути конфигурации TUI. +### Attention + +Attention позволяет TUI уведомлять вас, когда OpenCode ждёт ответа, требует подтверждения разрешения, сообщает об ошибке сеанса или завершает сеанс. Включите это с помощью `attention.enabled`; встроенные события воспроизводят звук при срабатывании. Уведомления рабочего стола отправляются только тогда, когда окно терминала не в фокусе, и не используются для событий subagent. + +- `enabled` — Включает все уведомления и звуки Attention. По умолчанию `false`. +- `notifications` — Когда Attention включён, разрешает TUI отправлять уведомления рабочего стола через терминал. По умолчанию `true`. +- `sound` — Когда Attention включён, разрешает воспроизводить звуковые оповещения. По умолчанию `true`. +- `volume` — Громкость звуковых оповещений по умолчанию от `0` до `1`. По умолчанию `0.4`. +- `sound_pack` — ID sound pack для использования. По умолчанию `opencode.default`. +- `sounds` — Задаёт пользовательские звуковые файлы для `default`, `question`, `permission`, `error`, `done` или `subagent_done`. Пути могут быть абсолютными, `file://` URL или относительными к `tui.json`. + --- ## Кастомизация diff --git a/packages/web/src/content/docs/ru/zen.mdx b/packages/web/src/content/docs/ru/zen.mdx index 10ff6633f6..c2506c2695 100644 --- a/packages/web/src/content/docs/ru/zen.mdx +++ b/packages/web/src/content/docs/ru/zen.mdx @@ -146,7 +146,7 @@ https://opencode.ai/zen/v1/models | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/th/tui.mdx b/packages/web/src/content/docs/th/tui.mdx index 2a5064b9d7..e3c5203ece 100644 --- a/packages/web/src/content/docs/th/tui.mdx +++ b/packages/web/src/content/docs/th/tui.mdx @@ -361,29 +361,58 @@ How is auth handled in @packages/functions/src/api/index.ts? { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` สิ่งนี้แยกจาก `opencode.json` ซึ่งกำหนดค่าพฤติกรรมเซิร์ฟเวอร์/รันไทม์ +`keybinds` จะถูกรวมกับค่าเริ่มต้นในตัว ดังนั้นคุณต้องกำหนดค่าเฉพาะ shortcut ที่ต้องการเปลี่ยนเท่านั้น + ### ตัวเลือก - `theme` - ตั้งค่าธีม UI ของคุณ [เรียนรู้เพิ่มเติม](/docs/themes) - `keybinds` - ปรับแต่งแป้นพิมพ์ลัด [เรียนรู้เพิ่มเติม](/docs/keybinds) +- `leader_timeout` - ควบคุมระยะเวลาที่ OpenCode จะรอหลังจากกด leader key ค่าเริ่มต้นคือ `2000` - `scroll_acceleration.enabled` - ​​เปิดใช้งานการเร่งความเร็วการเลื่อนแบบ macOS เพื่อการเลื่อนที่ราบรื่นและเป็นธรรมชาติ เมื่อเปิดใช้งาน ความเร็วในการเลื่อนจะเพิ่มขึ้นตามท่าทางการเลื่อนอย่างรวดเร็ว และคงความแม่นยำไว้สำหรับการเคลื่อนไหวที่ช้าลง **การตั้งค่านี้มีความสำคัญมากกว่า `scroll_speed` และแทนที่เมื่อเปิดใช้งาน** - `scroll_speed` - ​​ควบคุมความเร็วของการเลื่อน TUI เมื่อใช้คำสั่งการเลื่อน (ขั้นต่ำ: `0.001` รองรับค่าทศนิยม) ค่าเริ่มต้นเป็น `3` **หมายเหตุ: สิ่งนี้จะถูกละเว้นหากตั้งค่า `scroll_acceleration.enabled` เป็น `true`.** - `diff_style` - ควบคุมการเรนเดอร์ diff `"auto"` ปรับให้เข้ากับความกว้างของ terminal `"stacked"` จะแสดงคอลัมน์เดียวเสมอ +- `mouse` - เปิดหรือปิดการจับเมาส์ใน TUI (ค่าเริ่มต้น: `true`) เมื่อปิดใช้งาน terminal จะยังคงใช้พฤติกรรมการเลือกข้อความและเลื่อนด้วยเมาส์แบบเดิม +- `attention` - กำหนดค่า desktop notifications และ sounds ของ TUI ปิดใช้งานตามค่าเริ่มต้น ใช้ `OPENCODE_TUI_CONFIG` เพื่อโหลดเส้นทางการกำหนดค่า TUI แบบกำหนดเอง +### Attention + +Attention ช่วยให้ TUI แจ้งเตือนคุณเมื่อ OpenCode กำลังรอคำตอบ ต้องการการอนุมัติ permission พบ session error หรือ session เสร็จสิ้นแล้ว เปิดใช้งานด้วย `attention.enabled`; เหตุการณ์ในตัวจะเล่นเสียงเมื่อเกิดขึ้น Desktop notifications จะส่งเฉพาะเมื่อหน้าต่าง terminal ไม่ได้อยู่ในโฟกัส และจะไม่ใช้กับ subagent events + +- `enabled` - เปิดใช้งาน notifications และ sounds ทั้งหมดของ Attention ค่าเริ่มต้นคือ `false` +- `notifications` - เมื่อเปิด Attention แล้ว อนุญาตให้ TUI ส่ง desktop notifications ผ่าน terminal ค่าเริ่มต้นคือ `true` +- `sound` - เมื่อเปิด Attention แล้ว อนุญาตให้เล่นเสียงแจ้งเตือน ค่าเริ่มต้นคือ `true` +- `volume` - ระดับเสียงแจ้งเตือนเริ่มต้นตั้งแต่ `0` ถึง `1` ค่าเริ่มต้นคือ `0.4` +- `sound_pack` - sound pack ID ที่จะใช้ ค่าเริ่มต้นคือ `opencode.default` +- `sounds` - กำหนด sound files แบบกำหนดเองสำหรับ `default`, `question`, `permission`, `error`, `done` หรือ `subagent_done` Paths สามารถเป็น absolute, `file://` URLs หรือ relative กับ `tui.json` + --- ## การปรับแต่ง diff --git a/packages/web/src/content/docs/th/zen.mdx b/packages/web/src/content/docs/th/zen.mdx index 719a87ce91..ce4667834c 100644 --- a/packages/web/src/content/docs/th/zen.mdx +++ b/packages/web/src/content/docs/th/zen.mdx @@ -137,7 +137,7 @@ https://opencode.ai/zen/v1/models | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/tr/tui.mdx b/packages/web/src/content/docs/tr/tui.mdx index 55305f3672..91611a2de1 100644 --- a/packages/web/src/content/docs/tr/tui.mdx +++ b/packages/web/src/content/docs/tr/tui.mdx @@ -359,29 +359,58 @@ TUI davranışını `tui.json` (veya `tui.jsonc`) aracılığıyla özelleştire { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` Bu, sunucu/çalışma zamanı davranışını yapılandıran `opencode.json` dosyasından ayrıdır. +`keybinds` yerleşik varsayılanlarla birleştirilir; bu yüzden yalnızca değiştirmek istediğiniz kısayolları yapılandırmanız yeterlidir. + ### Seçenekler - `theme` - UI temanızı ayarlar. [Daha fazla bilgi](/docs/themes). - `keybinds` - Klavye kısayollarını özelleştirir. [Daha fazla bilgi](/docs/keybinds). +- `leader_timeout` - OpenCode'un leader key sonrasında ne kadar bekleyeceğini kontrol eder. Varsayılan değer `2000`. - `scroll_acceleration.enabled` - Pürüzsüz, doğal kaydırma için macOS tarzı kaydırma ivmesini etkinleştirin. Etkinleştirildiğinde, kaydırma hızı hızlı kaydırma hareketleriyle artar ve daha yavaş hareketler için hassas kalır. **Bu ayar `scroll_speed` ayarından önceliklidir ve etkinleştirildiğinde onu geçersiz kılar.** - `scroll_speed` - Kaydırma komutlarını kullanırken TUI'nin ne kadar hızlı kaydırılacağını kontrol eder (minimum: `0.001`, ondalık değerleri destekler). Varsayılan değer `3`'tür. **Not: `scroll_acceleration.enabled` `true` olarak ayarlanmışsa bu yok sayılır.** - `diff_style` - Fark (diff) oluşturmayı kontrol eder. `"auto"` terminal genişliğine uyum sağlar, `"stacked"` her zaman tek sütunlu bir düzen gösterir. +- `mouse` - TUI içinde fare yakalamayı etkinleştirir veya devre dışı bırakır (varsayılan: `true`). Devre dışı bırakıldığında terminalin yerel fareyle seçme ve kaydırma davranışı korunur. +- `attention` - TUI masaüstü bildirimlerini ve seslerini yapılandırır. Varsayılan olarak devre dışıdır. Özel bir TUI yapılandırma yolu yüklemek için `OPENCODE_TUI_CONFIG` kullanın. +### Attention + +Attention, OpenCode bir yanıt beklediğinde, izin onayı gerektiğinde, oturum hatası oluştuğunda veya oturum tamamlandığında TUI'nin sizi ses ve masaüstü bildirimiyle uyarmasını sağlar. `attention.enabled` ile etkinleştirin; yerleşik olaylar gerçekleştiğinde ses çalar. Masaüstü bildirimleri yalnızca terminal penceresi odakta değilken gönderilir ve subagent olayları için kullanılmaz. + +- `enabled` - Attention için tüm bildirimleri ve sesleri etkinleştirir. Varsayılan değer `false`. +- `notifications` - Attention etkin olduğunda TUI'nin terminal üzerinden masaüstü bildirimi göndermesine izin verir. Varsayılan değer `true`. +- `sound` - Attention etkin olduğunda uyarı seslerinin çalmasına izin verir. Varsayılan değer `true`. +- `volume` - Uyarı sesleri için varsayılan ses düzeyi, `0` ile `1` arasındadır. Varsayılan değer `0.4`. +- `sound_pack` - Kullanılacak sound pack ID. Varsayılan değer `opencode.default`. +- `sounds` - `default`, `question`, `permission`, `error`, `done` veya `subagent_done` için özel ses dosyaları ayarlar. Yollar mutlak, `file://` URL'leri veya `tui.json` dosyasına göre göreli olabilir. + --- ## Özelleştirme diff --git a/packages/web/src/content/docs/tr/zen.mdx b/packages/web/src/content/docs/tr/zen.mdx index 0a0109218e..4f4385367f 100644 --- a/packages/web/src/content/docs/tr/zen.mdx +++ b/packages/web/src/content/docs/tr/zen.mdx @@ -135,7 +135,7 @@ Kullandıkça öde modelini destekliyoruz. Aşağıda **1M token başına** fiya | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/zen.mdx b/packages/web/src/content/docs/zen.mdx index 918d92feee..d937fd0b9a 100644 --- a/packages/web/src/content/docs/zen.mdx +++ b/packages/web/src/content/docs/zen.mdx @@ -146,7 +146,7 @@ We support a pay-as-you-go model. Below are the prices **per 1M tokens**. | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/zh-cn/tui.mdx b/packages/web/src/content/docs/zh-cn/tui.mdx index df8ce38fec..8b0a4085b0 100644 --- a/packages/web/src/content/docs/zh-cn/tui.mdx +++ b/packages/web/src/content/docs/zh-cn/tui.mdx @@ -352,24 +352,63 @@ How is auth handled in @packages/functions/src/api/index.ts? ## 配置 -您可以通过 OpenCode 配置文件自定义 TUI 行为。 +您可以通过 `tui.json`(或 `tui.jsonc`)自定义 TUI 行为。 -```json title="opencode.json" +```json title="tui.json" { - "$schema": "https://opencode.ai/config.json", - "tui": { - "scroll_speed": 3, - "scroll_acceleration": { - "enabled": true + "$schema": "https://opencode.ai/tui.json", + "theme": "opencode", + "leader_timeout": 2000, + "keybinds": { + "leader": "ctrl+x", + "command_list": "ctrl+p" + }, + "scroll_speed": 3, + "scroll_acceleration": { + "enabled": false + }, + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" } } } ``` +这与 `opencode.json` 是分开的;`opencode.json` 用于配置服务器和运行时行为。 + +`keybinds` 会与内置默认值合并,因此你只需要配置想要修改的快捷键。 + ### 选项 -- `scroll_acceleration` - 启用 macOS 风格的滚动加速,实现平滑、自然的滚动体验。启用后,快速滚动时速度会增加,慢速移动时保持精确。**此设置优先于 `scroll_speed`,启用时会覆盖它。** -- `scroll_speed` - 控制使用滚动命令时 TUI 的滚动速度(最小值:`1`)。默认为 `3`。**注意:如果 `scroll_acceleration.enabled` 设置为 `true`,则此设置会被忽略。** +- `theme` - 设置 UI 主题。[了解更多](/docs/themes)。 +- `keybinds` - 自定义键盘快捷键。[了解更多](/docs/keybinds)。 +- `leader_timeout` - 控制按下 leader key 后 OpenCode 等待后续按键的时间。默认为 `2000`。 +- `scroll_acceleration.enabled` - 启用 macOS 风格的滚动加速,让滚动更平滑自然。启用后,快速滚动时速度会增加,慢速移动时仍保持精确。**此设置优先于 `scroll_speed`,启用时会覆盖它。** +- `scroll_speed` - 控制使用滚动命令时 TUI 的滚动速度(最小值:`0.001`,支持小数)。默认为 `3`。**注意:如果 `scroll_acceleration.enabled` 设置为 `true`,则此设置会被忽略。** +- `diff_style` - 控制 diff 的显示方式。`"auto"` 会根据终端宽度自适应,`"stacked"` 始终显示单列布局。 +- `mouse` - 在 TUI 中启用或禁用鼠标捕获(默认:`true`)。禁用后,终端原生的鼠标选择和滚动行为会保留下来。 +- `attention` - 配置 TUI 桌面通知和声音。默认禁用。 + +使用 `OPENCODE_TUI_CONFIG` 可以加载自定义的 TUI 配置文件路径。 + +### Attention + +当 OpenCode 需要你处理问题、批准权限请求、查看会话错误,或想告知会话已完成时,TUI 可以通过声音和桌面通知提醒你。设置 `attention.enabled` 后会启用这些提醒;内置事件触发时会播放声音。桌面通知只会在终端窗口未聚焦时发送,并且不会用于 subagent 事件。 + +- `enabled` - 开启 Attention 的所有通知和声音。默认为 `false`。 +- `notifications` - 启用 Attention 后,允许 TUI 通过终端发送桌面通知。默认为 `true`。 +- `sound` - 启用 Attention 后,允许播放提示音。默认为 `true`。 +- `volume` - 默认提示音音量,范围从 `0` 到 `1`。默认为 `0.4`。 +- `sound_pack` - 要使用的 sound pack ID。默认为 `opencode.default`。 +- `sounds` - 为 `default`、`question`、`permission`、`error`、`done` 或 `subagent_done` 指定自定义声音文件。路径可以是绝对路径、`file://` URL,或相对于 `tui.json` 的路径。 --- diff --git a/packages/web/src/content/docs/zh-cn/zen.mdx b/packages/web/src/content/docs/zh-cn/zen.mdx index 4c9f3239cd..fe9eef19e7 100644 --- a/packages/web/src/content/docs/zh-cn/zen.mdx +++ b/packages/web/src/content/docs/zh-cn/zen.mdx @@ -135,7 +135,7 @@ https://opencode.ai/zen/v1/models | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - | diff --git a/packages/web/src/content/docs/zh-tw/tui.mdx b/packages/web/src/content/docs/zh-tw/tui.mdx index 8f46c4c15b..f2f7b09cc5 100644 --- a/packages/web/src/content/docs/zh-tw/tui.mdx +++ b/packages/web/src/content/docs/zh-tw/tui.mdx @@ -358,29 +358,58 @@ How is auth handled in @packages/functions/src/api/index.ts? { "$schema": "https://opencode.ai/tui.json", "theme": "opencode", + "leader_timeout": 2000, "keybinds": { - "leader": "ctrl+x" + "leader": "ctrl+x", + "command_list": "ctrl+p" }, "scroll_speed": 3, "scroll_acceleration": { - "enabled": true + "enabled": false }, - "diff_style": "auto" + "diff_style": "auto", + "mouse": true, + "attention": { + "enabled": true, + "notifications": true, + "sound": true, + "volume": 0.4, + "sound_pack": "opencode.default", + "sounds": { + "error": "./sounds/error.mp3" + } + } } ``` 這與設定伺服器/執行時行為的 `opencode.json` 是分開的。 +`keybinds` 會與內建預設值合併,因此您只需要設定想要修改的快捷鍵。 + ### 選項 - `theme` - 設定您的 UI 主題。[了解更多](/docs/themes)。 - `keybinds` - 自訂鍵盤快速鍵。[了解更多](/docs/keybinds)。 +- `leader_timeout` - 控制按下 leader key 後 OpenCode 等待後續按鍵的時間。預設為 `2000`。 - `scroll_acceleration.enabled` - 啟用 macOS 風格的捲動加速,實現平滑、自然的捲動體驗。啟用後,快速捲動時速度會增加,慢速移動時保持精確。**此設定優先於 `scroll_speed`,啟用時會覆蓋它。** - `scroll_speed` - 控制使用捲動指令時 TUI 的捲動速度(最小值:`0.001`,支援小數值)。預設為 `3`。**注意:如果 `scroll_acceleration.enabled` 設定為 `true`,則此設定會被忽略。** - `diff_style` - 控制差異呈現方式。`"auto"` 根據終端機寬度自適應,`"stacked"` 始終顯示單列。 +- `mouse` - 在 TUI 中啟用或停用滑鼠捕捉(預設:`true`)。停用後,會保留終端機原生的滑鼠選取和捲動行為。 +- `attention` - 設定 TUI 桌面通知和聲音。預設停用。 使用 `OPENCODE_TUI_CONFIG` 載入自訂 TUI 設定路徑。 +### Attention + +當 OpenCode 需要你處理問題、核准權限請求、查看工作階段錯誤,或告知工作階段已完成時,TUI 可以透過聲音和桌面通知提醒你。設定 `attention.enabled` 後會啟用這些提醒;內建事件觸發時會播放聲音。桌面通知只會在終端機視窗未聚焦時傳送,且不會用於 subagent 事件。 + +- `enabled` - 開啟 Attention 的所有通知和聲音。預設為 `false`。 +- `notifications` - 啟用 Attention 後,允許 TUI 透過終端機傳送桌面通知。預設為 `true`。 +- `sound` - 啟用 Attention 後,允許播放提示音。預設為 `true`。 +- `volume` - 預設提示音音量,範圍從 `0` 到 `1`。預設為 `0.4`。 +- `sound_pack` - 要使用的 sound pack ID。預設為 `opencode.default`。 +- `sounds` - 為 `default`、`question`、`permission`、`error`、`done` 或 `subagent_done` 指定自訂聲音檔案。路徑可以是絕對路徑、`file://` URL,或相對於 `tui.json` 的路徑。 + --- ## 自訂 diff --git a/packages/web/src/content/docs/zh-tw/zen.mdx b/packages/web/src/content/docs/zh-tw/zen.mdx index 569386ff0f..bf54bbeecc 100644 --- a/packages/web/src/content/docs/zh-tw/zen.mdx +++ b/packages/web/src/content/docs/zh-tw/zen.mdx @@ -140,7 +140,7 @@ https://opencode.ai/zen/v1/models | Claude Sonnet 4 (≤ 200K tokens) | $3.00 | $15.00 | $0.30 | $3.75 | | Claude Sonnet 4 (> 200K tokens) | $6.00 | $22.50 | $0.60 | $7.50 | | Claude Haiku 4.5 | $1.00 | $5.00 | $0.10 | $1.25 | -| Gemini 3.5 Flash | $0.50 | $3.00 | $0.05 | - | +| Gemini 3.5 Flash | $1.50 | $9.00 | $0.15 | - | | Gemini 3.1 Pro (≤ 200K tokens) | $2.00 | $12.00 | $0.20 | - | | Gemini 3.1 Pro (> 200K tokens) | $4.00 | $18.00 | $0.40 | - | | Gemini 3 Flash | $0.50 | $3.00 | $0.05 | - |