🤯 LobeHub - Super-Agents on Your Team. Add super-agents to the chats your team already uses.They take on work by themselves and get better every week.
TypeScript agentagent-collaborationagent-harnessloop-engineeringmcppersonal-assistantproactive-agentskillssuper-agenttask-management
✨ feat(settings): gather chat preferences into a Conversation settings page (#23628)
AmAzing-9f80e88a86e3
diff --git a/e2e/src/steps/agent/scroll.steps.ts b/e2e/src/steps/agent/scroll.steps.tsindex 3ce49378e29..1f6793349f6 100644--- a/e2e/src/steps/agent/scroll.steps.ts+++ b/e2e/src/steps/agent/scroll.steps.ts@@ -200,7 +200,7 @@ async function scrollBy(world: CustomWorld, deltaY: number): Promise<void> {}// ----------------------------------------------------------------------------// Setting toggle via the chat-appearance settings page+// Setting toggle via the conversation settings page// ---------------------------------------------------------------------------Before({ tags: '@scroll', timeout: 130_000 }, async function (this: CustomWorld) {@@ -216,7 +216,7 @@ After({ tags: '@scroll' }, async function (this: CustomWorld) {});async function setAutoScrollEnabled(world: CustomWorld, desired: boolean): Promise<void> {- await world.page.goto('/settings/chat-appearance');+ await world.page.goto('/settings/conversation');// The first local dev compile can take a while, so keep an explicit timeout.// (Next.js builds the settings route on demand); a generous timeout avoids// flakes when the test suite warms up a cold server.diff --git a/locales/ar/setting.json b/locales/ar/setting.jsonindex 20f7ebc218e..a715e9d7cb0 100644--- a/locales/ar/setting.json+++ b/locales/ar/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "إعدادات الدردشة","settingChatAppearance.autoScrollOnStreaming.desc": "التمرير تلقائيًا إلى الأسفل عند توليد الذكاء الاصطناعي للاستجابة","settingChatAppearance.autoScrollOnStreaming.title": "التمرير التلقائي أثناء استجابة الذكاء الاصطناعي",- "settingChatAppearance.chatBehavior.title": "سلوك الدردشة","settingChatAppearance.fontSize.desc": "حجم خط الرسائل","settingChatAppearance.fontSize.marks.normal": "قياسي","settingChatAppearance.fontSize.title": "حجم الخط",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, مفتاح api, apikey, رمز, سر, مفتاح شخصي","settingsSearch.tabKeywords.appearance": "المظهر, السمة, الوضع الداكن, الوضع الفاتح, الخط, اللغة, اللون, الخلفية","settingsSearch.tabKeywords.billing": "الفواتير، الدفع، الفاتورة، البطاقة، المعاملة",- "settingsSearch.tabKeywords.chatPreference": "تفضيلات الدردشة، اقتراحات المتابعة، اقتراحات الإدخال، الإكمال التلقائي","settingsSearch.tabKeywords.connector": "الموصلات، التكاملات، MCP","settingsSearch.tabKeywords.credits": "الاستخدام، الرصيد، شحن، إعادة تعبئة، شراء حزمة شحن","settingsSearch.tabKeywords.creds": "بيانات الاعتماد، الأسرار، OAuth",@@ -1987,7 +1985,6 @@"tab.apikey": "إدارة مفاتيح API","tab.appearance": "المظهر","tab.chatAppearance": "مظهر المحادثة",- "tab.chatPreference": "تفضيلات الدردشة","tab.common": "المظهر","tab.connector": "الموصلات","tab.creds": "بيانات الاعتماد",diff --git a/locales/bg-BG/setting.json b/locales/bg-BG/setting.jsonindex f597f3a568f..7da7b6a084a 100644--- a/locales/bg-BG/setting.json+++ b/locales/bg-BG/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "Настройки на чата","settingChatAppearance.autoScrollOnStreaming.desc": "Автоматично превъртане до дъното, когато ИИ генерира отговор","settingChatAppearance.autoScrollOnStreaming.title": "Автоматично превъртане по време на отговор от ИИ",- "settingChatAppearance.chatBehavior.title": "Поведение на чата","settingChatAppearance.fontSize.desc": "Размер на шрифта на съобщенията","settingChatAppearance.fontSize.marks.normal": "Стандартен","settingChatAppearance.fontSize.title": "Размер на шрифта",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, api ключ, apikey, токен, таен, личен ключ","settingsSearch.tabKeywords.appearance": "външен вид, тема, тъмен режим, светъл режим, шрифт, език, цвят, фон","settingsSearch.tabKeywords.billing": "фактуриране, плащане, фактура, карта, транзакция",- "settingsSearch.tabKeywords.chatPreference": "предпочитания за чат, предложения за последващи действия, предложения за въвеждане, автоматично довършване","settingsSearch.tabKeywords.connector": "конектори, интеграции, mcp","settingsSearch.tabKeywords.credits": "използване, баланс, зареждане, презареждане, купуване на пакет за зареждане","settingsSearch.tabKeywords.creds": "учредителни данни, тайни, oauth",@@ -1987,7 +1985,6 @@"tab.apikey": "Управление на API ключове","tab.appearance": "Външен вид","tab.chatAppearance": "Външен вид на чата",- "tab.chatPreference": "Предпочитания за чат","tab.common": "Външен вид","tab.connector": "Конектори","tab.creds": "Идентификатори",diff --git a/locales/de-DE/setting.json b/locales/de-DE/setting.jsonindex 3d0644e4419..fb1467ed971 100644--- a/locales/de-DE/setting.json+++ b/locales/de-DE/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "Chat-Einstellungen","settingChatAppearance.autoScrollOnStreaming.desc": "Automatisch nach unten scrollen, wenn die KI eine Antwort generiert","settingChatAppearance.autoScrollOnStreaming.title": "Automatisches Scrollen während der KI-Antwort",- "settingChatAppearance.chatBehavior.title": "Chat-Verhalten","settingChatAppearance.fontSize.desc": "Schriftgröße der Nachrichten","settingChatAppearance.fontSize.marks.normal": "Standard","settingChatAppearance.fontSize.title": "Schriftgröße",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, api key, apikey, token, secret, persönlicher Schlüssel","settingsSearch.tabKeywords.appearance": "Erscheinungsbild, Thema, Dunkelmodus, Hellmodus, Schriftart, Sprache, Farbe, Hintergrund","settingsSearch.tabKeywords.billing": "Abrechnung, Zahlung, Rechnung, Karte, Transaktion",- "settingsSearch.tabKeywords.chatPreference": "Chat-Einstellungen, Folge-Vorschläge, Eingabevorschläge, Autovervollständigung","settingsSearch.tabKeywords.connector": "Connectoren, Integrationen, MCP","settingsSearch.tabKeywords.credits": "Nutzung, Guthaben, Aufladen, Nachladen, Top-up-Paket kaufen","settingsSearch.tabKeywords.creds": "Anmeldedaten, Geheimnisse, OAuth",@@ -1987,7 +1985,6 @@"tab.apikey": "API-Schlüsselverwaltung","tab.appearance": "Erscheinungsbild","tab.chatAppearance": "Chat-Darstellung",- "tab.chatPreference": "Chat-Einstellungen","tab.common": "Darstellung","tab.connector": "Konnektoren","tab.creds": "Berechtigungen",diff --git a/locales/en-US/setting.json b/locales/en-US/setting.jsonindex af7a8392c9c..0e80a414854 100644--- a/locales/en-US/setting.json+++ b/locales/en-US/setting.json@@ -1892,7 +1892,6 @@"settingChat.title": "Chat Settings","settingChatAppearance.autoScrollOnStreaming.desc": "Automatically scroll to bottom when AI is generating response","settingChatAppearance.autoScrollOnStreaming.title": "Auto-scroll During AI Response",- "settingChatAppearance.chatBehavior.title": "Chat Behavior","settingChatAppearance.followUpBehavior.desc": "Queue follow-ups while the agent runs, or steer the current run","settingChatAppearance.followUpBehavior.options.queue": "Queue","settingChatAppearance.followUpBehavior.options.steer": "Steer",@@ -1932,6 +1931,11 @@"settingCommon.themeMode.light": "Light","settingCommon.themeMode.title": "Theme","settingCommon.title": "General Settings",+ "settingConversation.display.title": "Message Display",+ "settingConversation.input.title": "Input & Sending",+ "settingConversation.reply.title": "Replies",+ "settingConversation.voiceMessage.desc": "Show the voice message button in the chat input to record and send voice messages.",+ "settingConversation.voiceMessage.title": "Voice Message","settingGraphRuntime.enabled.desc": "Route this agent through the graph runtime using the snapshot stored below.","settingGraphRuntime.enabled.title": "Enable Graph Runtime","settingGraphRuntime.snapshot.desc": "Paste the complete AgentGraph JSON snapshot. It is stored with this agent and used directly at runtime.",@@ -2138,8 +2142,8 @@"settingsSearch.tabKeywords.appearance": "appearance, theme, dark mode, light mode, font, language, color, background","settingsSearch.tabKeywords.automations": "automations, events, event subscriptions, triggers","settingsSearch.tabKeywords.billing": "billing, payment, invoice, card, transaction",- "settingsSearch.tabKeywords.chatPreference": "chat preferences, follow-up suggestions, input suggestions, autocomplete","settingsSearch.tabKeywords.connector": "connectors, integrations, mcp",+ "settingsSearch.tabKeywords.conversation": "conversation, chat, reply language, send key, enter to send, voice message, follow-up suggestions, input suggestions, autocomplete, font size, code highlight, mermaid","settingsSearch.tabKeywords.credits": "usage, balance, top up, recharge, buy top-up pack","settingsSearch.tabKeywords.creds": "credentials, secrets, oauth","settingsSearch.tabKeywords.devices": "devices, sessions, logged in devices",@@ -2452,9 +2456,9 @@"tab.appearance": "Appearance","tab.automations": "Automations","tab.chatAppearance": "Chat Appearance",- "tab.chatPreference": "Chat Preferences","tab.common": "Appearance","tab.connector": "Connectors",+ "tab.conversation": "Conversation","tab.creds": "Vault","tab.devices": "Devices","tab.environments": "Environments",diff --git a/locales/es-ES/setting.json b/locales/es-ES/setting.jsonindex ace57f38ecd..70ccfc1bbdf 100644--- a/locales/es-ES/setting.json+++ b/locales/es-ES/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "Configuración de Chat","settingChatAppearance.autoScrollOnStreaming.desc": "Desplazar automáticamente hacia abajo cuando la IA esté generando una respuesta","settingChatAppearance.autoScrollOnStreaming.title": "Desplazamiento automático durante la respuesta de la IA",- "settingChatAppearance.chatBehavior.title": "Comportamiento del Chat","settingChatAppearance.fontSize.desc": "Tamaño de fuente de los mensajes","settingChatAppearance.fontSize.marks.normal": "Estándar","settingChatAppearance.fontSize.title": "Tamaño de Fuente",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, clave api, apikey, token, secreto, clave personal","settingsSearch.tabKeywords.appearance": "apariencia, tema, modo oscuro, modo claro, fuente, idioma, color, fondo","settingsSearch.tabKeywords.billing": "facturación, pago, factura, tarjeta, transacción",- "settingsSearch.tabKeywords.chatPreference": "preferencias de chat, sugerencias de seguimiento, sugerencias de entrada, autocompletar","settingsSearch.tabKeywords.connector": "conectores, integraciones, mcp","settingsSearch.tabKeywords.credits": "uso, saldo, recarga, recargar, comprar paquete de recarga","settingsSearch.tabKeywords.creds": "credenciales, secretos, oauth",@@ -1987,7 +1985,6 @@"tab.apikey": "Gestión de Claves API","tab.appearance": "Apariencia","tab.chatAppearance": "Apariencia del Chat",- "tab.chatPreference": "Preferencias de Chat","tab.common": "Apariencia","tab.connector": "Conectores","tab.creds": "Credenciales",diff --git a/locales/fa-IR/setting.json b/locales/fa-IR/setting.jsonindex 1f6a8b13484..05590b4ea65 100644--- a/locales/fa-IR/setting.json+++ b/locales/fa-IR/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "تنظیمات گفتگو","settingChatAppearance.autoScrollOnStreaming.desc": "پیمایش خودکار به پایین هنگام تولید پاسخ توسط هوش مصنوعی","settingChatAppearance.autoScrollOnStreaming.title": "پیمایش خودکار هنگام پاسخدهی هوش مصنوعی",- "settingChatAppearance.chatBehavior.title": "رفتار چت","settingChatAppearance.fontSize.desc": "اندازه فونت پیامها","settingChatAppearance.fontSize.marks.normal": "استاندارد","settingChatAppearance.fontSize.title": "اندازه فونت",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, کلید api, apikey, توکن, محرمانه, کلید شخصی","settingsSearch.tabKeywords.appearance": "ظاهر, تم, حالت تاریک, حالت روشن, فونت, زبان, رنگ, پسزمینه","settingsSearch.tabKeywords.billing": "صورتحساب، پرداخت، فاکتور، کارت، تراکنش",- "settingsSearch.tabKeywords.chatPreference": "ترجیحات چت، پیشنهادات پیگیری، پیشنهادات ورودی، تکمیل خودکار","settingsSearch.tabKeywords.connector": "اتصالات، یکپارچهسازیها، MCP","settingsSearch.tabKeywords.credits": "مصرف، موجودی، افزایش موجودی، شارژ، خرید بسته افزایش موجودی","settingsSearch.tabKeywords.creds": "اعتبارنامهها، رمزها، OAuth",@@ -1987,7 +1985,6 @@"tab.apikey": "مدیریت کلید API","tab.appearance": "ظاهر","tab.chatAppearance": "ظاهر گفتگو",- "tab.chatPreference": "ترجیحات چت","tab.common": "ظاهر","tab.connector": "اتصالدهندهها","tab.creds": "اعتبارنامهها",diff --git a/locales/fr-FR/setting.json b/locales/fr-FR/setting.jsonindex 5dc1bbc4eed..ca2c220d41f 100644--- a/locales/fr-FR/setting.json+++ b/locales/fr-FR/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "Paramètres de chat","settingChatAppearance.autoScrollOnStreaming.desc": "Faire défiler automatiquement vers le bas lorsque l'IA génère une réponse","settingChatAppearance.autoScrollOnStreaming.title": "Défilement automatique pendant la réponse de l'IA",- "settingChatAppearance.chatBehavior.title": "Comportement du chat","settingChatAppearance.fontSize.desc": "Taille de police des messages","settingChatAppearance.fontSize.marks.normal": "Standard","settingChatAppearance.fontSize.title": "Taille de police",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, clé api, apikey, jeton, secret, clé personnelle","settingsSearch.tabKeywords.appearance": "apparence, thème, mode sombre, mode clair, police, langue, couleur, arrière-plan","settingsSearch.tabKeywords.billing": "facturation, paiement, facture, carte, transaction",- "settingsSearch.tabKeywords.chatPreference": "préférences de chat, suggestions de suivi, suggestions d'entrée, autocomplétion","settingsSearch.tabKeywords.connector": "connecteurs, intégrations, mcp","settingsSearch.tabKeywords.credits": "utilisation, solde, recharger, rechargement, acheter un pack de recharge","settingsSearch.tabKeywords.creds": "identifiants, secrets, oauth",@@ -1987,7 +1985,6 @@"tab.apikey": "Gestion des clés API","tab.appearance": "Apparence","tab.chatAppearance": "Apparence du chat",- "tab.chatPreference": "Préférences de Chat","tab.common": "Apparence","tab.connector": "Connecteurs","tab.creds": "Informations d'identification",diff --git a/locales/it-IT/setting.json b/locales/it-IT/setting.jsonindex f884c125ea7..71cc4a054d9 100644--- a/locales/it-IT/setting.json+++ b/locales/it-IT/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "Impostazioni Chat","settingChatAppearance.autoScrollOnStreaming.desc": "Scorri automaticamente in fondo quando l'IA sta generando una risposta","settingChatAppearance.autoScrollOnStreaming.title": "Scorrimento automatico durante la risposta dell'IA",- "settingChatAppearance.chatBehavior.title": "Comportamento della Chat","settingChatAppearance.fontSize.desc": "Dimensione del carattere dei messaggi","settingChatAppearance.fontSize.marks.normal": "Standard","settingChatAppearance.fontSize.title": "Dimensione Carattere",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, chiave api, apikey, token, segreto, chiave personale","settingsSearch.tabKeywords.appearance": "aspetto, tema, modalità scura, modalità chiara, carattere, lingua, colore, sfondo","settingsSearch.tabKeywords.billing": "fatturazione, pagamento, fattura, carta, transazione",- "settingsSearch.tabKeywords.chatPreference": "preferenze chat, suggerimenti di follow-up, suggerimenti di input, completamento automatico","settingsSearch.tabKeywords.connector": "connettori, integrazioni, mcp","settingsSearch.tabKeywords.credits": "utilizzo, saldo, ricarica, ricarica, acquista pacchetto di ricarica","settingsSearch.tabKeywords.creds": "credenziali, segreti, oauth",@@ -1987,7 +1985,6 @@"tab.apikey": "Gestione API Key","tab.appearance": "Aspetto","tab.chatAppearance": "Aspetto Chat",- "tab.chatPreference": "Preferenze Chat","tab.common": "Aspetto","tab.connector": "Connettori","tab.creds": "Credenziali",diff --git a/locales/ja-JP/setting.json b/locales/ja-JP/setting.jsonindex e552a8b4d25..e43aaa2af15 100644--- a/locales/ja-JP/setting.json+++ b/locales/ja-JP/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "チャット設定","settingChatAppearance.autoScrollOnStreaming.desc": "AIが応答を生成している間、自動的に最下部までスクロールします","settingChatAppearance.autoScrollOnStreaming.title": "AI応答中の自動スクロール",- "settingChatAppearance.chatBehavior.title": "チャットの動作","settingChatAppearance.fontSize.desc": "メッセージのフォントサイズ","settingChatAppearance.fontSize.marks.normal": "標準","settingChatAppearance.fontSize.title": "フォントサイズ",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, api key, apikey, トークン, シークレット, 個人キー","settingsSearch.tabKeywords.appearance": "外観, テーマ, ダークモード, ライトモード, フォント, 言語, 色, 背景","settingsSearch.tabKeywords.billing": "請求, 支払い, 請求書, カード, 取引",- "settingsSearch.tabKeywords.chatPreference": "チャット設定、フォローアップ提案、入力提案、自動補完","settingsSearch.tabKeywords.connector": "コネクタ, 統合, MCP","settingsSearch.tabKeywords.credits": "使用量、残高、トップアップ、チャージ、トップアップパックの購入","settingsSearch.tabKeywords.creds": "認証情報, シークレット, OAuth",@@ -1987,7 +1985,6 @@"tab.apikey": "APIキー管理","tab.appearance": "外観","tab.chatAppearance": "チャットの外観",- "tab.chatPreference": "チャット設定","tab.common": "外観","tab.connector": "コネクタ","tab.creds": "資格情報",diff --git a/locales/ko-KR/setting.json b/locales/ko-KR/setting.jsonindex c43d787e0e4..65a59fb2ed7 100644--- a/locales/ko-KR/setting.json+++ b/locales/ko-KR/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "채팅 설정","settingChatAppearance.autoScrollOnStreaming.desc": "AI가 응답을 생성할 때 자동으로 맨 아래로 스크롤합니다","settingChatAppearance.autoScrollOnStreaming.title": "AI 응답 중 자동 스크롤",- "settingChatAppearance.chatBehavior.title": "채팅 동작","settingChatAppearance.fontSize.desc": "메시지의 글꼴 크기","settingChatAppearance.fontSize.marks.normal": "표준","settingChatAppearance.fontSize.title": "글꼴 크기",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, api key, apikey, 토큰, 비밀, 개인 키","settingsSearch.tabKeywords.appearance": "외형, 테마, 다크 모드, 라이트 모드, 글꼴, 언어, 색상, 배경","settingsSearch.tabKeywords.billing": "결제, 지불, 청구서, 카드, 거래",- "settingsSearch.tabKeywords.chatPreference": "채팅 설정, 후속 제안, 입력 제안, 자동 완성","settingsSearch.tabKeywords.connector": "커넥터, 통합, MCP","settingsSearch.tabKeywords.credits": "사용량, 잔액, 충전, 재충전, 충전 패키지 구매","settingsSearch.tabKeywords.creds": "자격 증명, 비밀, OAuth",@@ -1987,7 +1985,6 @@"tab.apikey": "API 키 관리","tab.appearance": "외관","tab.chatAppearance": "채팅 화면 설정",- "tab.chatPreference": "채팅 설정","tab.common": "외관","tab.connector": "커넥터","tab.creds": "자격 증명",diff --git a/locales/nl-NL/setting.json b/locales/nl-NL/setting.jsonindex dc2e70dbef9..efc56b3ef18 100644--- a/locales/nl-NL/setting.json+++ b/locales/nl-NL/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "Chatinstellingen","settingChatAppearance.autoScrollOnStreaming.desc": "Scroll automatisch naar beneden wanneer AI een reactie genereert","settingChatAppearance.autoScrollOnStreaming.title": "Automatisch scrollen tijdens AI-reactie",- "settingChatAppearance.chatBehavior.title": "Chatgedrag","settingChatAppearance.fontSize.desc": "Lettergrootte van berichten","settingChatAppearance.fontSize.marks.normal": "Standaard","settingChatAppearance.fontSize.title": "Lettergrootte",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, api sleutel, apikey, token, geheim, persoonlijke sleutel","settingsSearch.tabKeywords.appearance": "weergave, thema, donkere modus, lichte modus, lettertype, taal, kleur, achtergrond","settingsSearch.tabKeywords.billing": "facturering, betaling, factuur, kaart, transactie",- "settingsSearch.tabKeywords.chatPreference": "chatvoorkeuren, vervolgvoorstellen, invoervoorstellen, automatisch aanvullen","settingsSearch.tabKeywords.connector": "connectoren, integraties, mcp","settingsSearch.tabKeywords.credits": "verbruik, saldo, opwaarderen, opladen, opwaarderingspakket kopen","settingsSearch.tabKeywords.creds": "referenties, geheimen, oauth",@@ -1987,7 +1985,6 @@"tab.apikey": "API-sleutelbeheer","tab.appearance": "Uiterlijk","tab.chatAppearance": "Chatweergave",- "tab.chatPreference": "Chatvoorkeuren","tab.common": "Weergave","tab.connector": "Connectors","tab.creds": "Referenties",diff --git a/locales/pl-PL/setting.json b/locales/pl-PL/setting.jsonindex f0b0c9915ea..a78e77bc29a 100644--- a/locales/pl-PL/setting.json+++ b/locales/pl-PL/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "Ustawienia czatu","settingChatAppearance.autoScrollOnStreaming.desc": "Automatycznie przewijaj do dołu, gdy AI generuje odpowiedź","settingChatAppearance.autoScrollOnStreaming.title": "Auto-przewijanie podczas odpowiedzi AI",- "settingChatAppearance.chatBehavior.title": "Zachowanie czatu","settingChatAppearance.fontSize.desc": "Rozmiar czcionki wiadomości","settingChatAppearance.fontSize.marks.normal": "Standardowy","settingChatAppearance.fontSize.title": "Rozmiar czcionki",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, klucz api, apikey, token, sekret, klucz osobisty","settingsSearch.tabKeywords.appearance": "wygląd, motyw, tryb ciemny, tryb jasny, czcionka, język, kolor, tło","settingsSearch.tabKeywords.billing": "rozliczenia, płatność, faktura, karta, transakcja",- "settingsSearch.tabKeywords.chatPreference": "preferencje czatu, sugestie dalszych działań, sugestie wprowadzania, autouzupełnianie","settingsSearch.tabKeywords.connector": "łączniki, integracje, mcp","settingsSearch.tabKeywords.credits": "użycie, saldo, doładowanie, zasilenie, kup pakiet doładowań","settingsSearch.tabKeywords.creds": "poświadczenia, sekrety, oauth",@@ -1987,7 +1985,6 @@"tab.apikey": "Zarządzanie kluczami API","tab.appearance": "Wygląd","tab.chatAppearance": "Wygląd czatu",- "tab.chatPreference": "Preferencje czatu","tab.common": "Wygląd","tab.connector": "Konektory","tab.creds": "Poświadczenia",diff --git a/locales/pt-BR/setting.json b/locales/pt-BR/setting.jsonindex afdf9482347..00d547d34b3 100644--- a/locales/pt-BR/setting.json+++ b/locales/pt-BR/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "Configurações de Chat","settingChatAppearance.autoScrollOnStreaming.desc": "Rolar automaticamente até o final quando a IA estiver gerando uma resposta","settingChatAppearance.autoScrollOnStreaming.title": "Rolagem automática durante resposta da IA",- "settingChatAppearance.chatBehavior.title": "Comportamento do Chat","settingChatAppearance.fontSize.desc": "Tamanho da fonte das mensagens","settingChatAppearance.fontSize.marks.normal": "Padrão","settingChatAppearance.fontSize.title": "Tamanho da Fonte",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, chave api, apikey, token, segredo, chave pessoal","settingsSearch.tabKeywords.appearance": "aparência, tema, modo escuro, modo claro, fonte, idioma, cor, fundo","settingsSearch.tabKeywords.billing": "faturamento, pagamento, fatura, cartão, transação",- "settingsSearch.tabKeywords.chatPreference": "preferências de chat, sugestões de acompanhamento, sugestões de entrada, autocompletar","settingsSearch.tabKeywords.connector": "conectores, integrações, mcp","settingsSearch.tabKeywords.credits": "uso, saldo, recarga, recarregar, comprar pacote de recarga","settingsSearch.tabKeywords.creds": "credenciais, segredos, oauth",@@ -1987,7 +1985,6 @@"tab.apikey": "Gerenciamento de Chaves API","tab.appearance": "Aparência","tab.chatAppearance": "Aparência do Chat",- "tab.chatPreference": "Preferências de Chat","tab.common": "Aparência","tab.connector": "Conectores","tab.creds": "Credenciais",diff --git a/locales/ru-RU/setting.json b/locales/ru-RU/setting.jsonindex 25366e38e78..8fbcc6c522e 100644--- a/locales/ru-RU/setting.json+++ b/locales/ru-RU/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "Настройки чата","settingChatAppearance.autoScrollOnStreaming.desc": "Автоматически прокручивать вниз при генерации ответа ИИ","settingChatAppearance.autoScrollOnStreaming.title": "Автопрокрутка во время ответа ИИ",- "settingChatAppearance.chatBehavior.title": "Поведение чата","settingChatAppearance.fontSize.desc": "Размер шрифта сообщений","settingChatAppearance.fontSize.marks.normal": "Стандартный","settingChatAppearance.fontSize.title": "Размер шрифта",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, api ключ, apikey, токен, секрет, персональный ключ","settingsSearch.tabKeywords.appearance": "внешний вид, тема, темный режим, светлый режим, шрифт, язык, цвет, фон","settingsSearch.tabKeywords.billing": "оплата, платеж, счет, карта, транзакция",- "settingsSearch.tabKeywords.chatPreference": "предпочтения чата, предложения по продолжению, предложения ввода, автозаполнение","settingsSearch.tabKeywords.connector": "коннекторы, интеграции, mcp","settingsSearch.tabKeywords.credits": "использование, баланс, пополнить, пополнение, купить пакет пополнения","settingsSearch.tabKeywords.creds": "учетные данные, секреты, oauth",@@ -1987,7 +1985,6 @@"tab.apikey": "Управление API-ключами","tab.appearance": "Внешний вид","tab.chatAppearance": "Внешний вид чата",- "tab.chatPreference": "Предпочтения чата","tab.common": "Внешний вид","tab.connector": "Коннекторы","tab.creds": "Учетные данные",diff --git a/locales/tr-TR/setting.json b/locales/tr-TR/setting.jsonindex a6bf18c2470..cdcb36c57f8 100644--- a/locales/tr-TR/setting.json+++ b/locales/tr-TR/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "Sohbet Ayarları","settingChatAppearance.autoScrollOnStreaming.desc": "Yapay zeka yanıt oluştururken otomatik olarak en alta kaydır","settingChatAppearance.autoScrollOnStreaming.title": "Yapay Zeka Yanıtı Sırasında Otomatik Kaydırma",- "settingChatAppearance.chatBehavior.title": "Sohbet Davranışı","settingChatAppearance.fontSize.desc": "Mesaj yazı tipi boyutu","settingChatAppearance.fontSize.marks.normal": "Standart","settingChatAppearance.fontSize.title": "Yazı Tipi Boyutu",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, api anahtarı, apikey, token, gizli, kişisel anahtar","settingsSearch.tabKeywords.appearance": "görünüm, tema, karanlık mod, açık mod, yazı tipi, dil, renk, arka plan","settingsSearch.tabKeywords.billing": "faturalandırma, ödeme, fatura, kart, işlem",- "settingsSearch.tabKeywords.chatPreference": "sohbet tercihleri, takip önerileri, giriş önerileri, otomatik tamamlama","settingsSearch.tabKeywords.connector": "bağlayıcılar, entegrasyonlar, mcp","settingsSearch.tabKeywords.credits": "kullanım, bakiye, yükleme, yeniden yükleme, yükleme paketi satın al","settingsSearch.tabKeywords.creds": "kimlik bilgileri, gizli bilgiler, oauth",@@ -1987,7 +1985,6 @@"tab.apikey": "API Anahtarı Yönetimi","tab.appearance": "Görünüm","tab.chatAppearance": "Sohbet Görünümü",- "tab.chatPreference": "Sohbet Tercihleri","tab.common": "Görünüm","tab.connector": "Bağlayıcılar","tab.creds": "Kimlik Bilgileri",diff --git a/locales/vi-VN/setting.json b/locales/vi-VN/setting.jsonindex 8a194ed467b..69600c473f4 100644--- a/locales/vi-VN/setting.json+++ b/locales/vi-VN/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "Cài đặt trò chuyện","settingChatAppearance.autoScrollOnStreaming.desc": "Tự động cuộn xuống cuối khi AI đang tạo phản hồi","settingChatAppearance.autoScrollOnStreaming.title": "Tự động cuộn khi AI phản hồi",- "settingChatAppearance.chatBehavior.title": "Hành Vi Trò Chuyện","settingChatAppearance.fontSize.desc": "Kích thước phông chữ của tin nhắn","settingChatAppearance.fontSize.marks.normal": "Chuẩn","settingChatAppearance.fontSize.title": "Kích thước chữ",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, khóa api, apikey, token, bí mật, khóa cá nhân","settingsSearch.tabKeywords.appearance": "giao diện, chủ đề, chế độ tối, chế độ sáng, phông chữ, ngôn ngữ, màu sắc, nền","settingsSearch.tabKeywords.billing": "thanh toán, hóa đơn, thẻ, giao dịch",- "settingsSearch.tabKeywords.chatPreference": "tùy chọn trò chuyện, gợi ý tiếp theo, gợi ý nhập liệu, tự động hoàn thành","settingsSearch.tabKeywords.connector": "kết nối, tích hợp, mcp","settingsSearch.tabKeywords.credits": "mức sử dụng, số dư, nạp tiền, nạp thêm, mua gói nạp tiền","settingsSearch.tabKeywords.creds": "thông tin xác thực, bí mật, oauth",@@ -1987,7 +1985,6 @@"tab.apikey": "Quản Lý API Key","tab.appearance": "Giao diện","tab.chatAppearance": "Giao Diện Trò Chuyện",- "tab.chatPreference": "Tùy Chọn Trò Chuyện","tab.common": "Giao Diện","tab.connector": "Trình kết nối","tab.creds": "Thông Tin Xác Thực",diff --git a/locales/zh-CN/setting.json b/locales/zh-CN/setting.jsonindex bb4c5b4c68f..0cc4a270f87 100644--- a/locales/zh-CN/setting.json+++ b/locales/zh-CN/setting.json@@ -1260,7 +1260,7 @@"hotkey.errors.UNKNOWN": "更新失败:未知错误","hotkey.group.appMenu": "应用菜单","hotkey.group.appMenuDesc": "桌面端应用菜单内置的快捷键,随系统平台变化,暂不支持自定义。",- "hotkey.group.conversation": "会话",+ "hotkey.group.conversation": "对话","hotkey.group.desktop": "桌面端","hotkey.group.essential": "基础","hotkey.invalidCombination": "快捷键需要至少包含一个修饰键 (Ctrl, Alt, Shift) 和一个常规键",@@ -1892,7 +1892,6 @@"settingChat.title": "聊天设置","settingChatAppearance.autoScrollOnStreaming.desc": "当 AI 正在生成回复时,自动滚动到底部","settingChatAppearance.autoScrollOnStreaming.title": "AI 回复时自动滚动",- "settingChatAppearance.chatBehavior.title": "对话行为","settingChatAppearance.followUpBehavior.desc": "Agent 运行时发出的消息:排到本次运行结束后再发,或插入当前运行","settingChatAppearance.followUpBehavior.options.queue": "排队","settingChatAppearance.followUpBehavior.options.steer": "插入",@@ -1932,6 +1931,11 @@"settingCommon.themeMode.light": "浅色","settingCommon.themeMode.title": "主题","settingCommon.title": "通用设置",+ "settingConversation.display.title": "消息显示",+ "settingConversation.input.title": "输入与发送",+ "settingConversation.reply.title": "回复",+ "settingConversation.voiceMessage.desc": "在聊天输入框中显示发送语音消息按钮,用于录制并发送语音消息。",+ "settingConversation.voiceMessage.title": "语音消息","settingGraphRuntime.enabled.desc": "使用下方保存的快照,让该助理通过 Graph 运行时执行。","settingGraphRuntime.enabled.title": "启用 Graph 运行时","settingGraphRuntime.snapshot.desc": "粘贴完整的 AgentGraph JSON 快照。它与此代理一起存储,并直接在运行时使用。",@@ -2138,8 +2142,8 @@"settingsSearch.tabKeywords.appearance": "外观,主题,深色模式,浅色模式,字体,语言,颜色,背景","settingsSearch.tabKeywords.automations": "自动化,事件,订阅,事件订阅,触发","settingsSearch.tabKeywords.billing": "账单,支付,付款,发票,交易记录,银行卡",- "settingsSearch.tabKeywords.chatPreference": "对话偏好,跟进建议,输入建议,自动补全","settingsSearch.tabKeywords.connector": "连接器,集成,MCP",+ "settingsSearch.tabKeywords.conversation": "对话,聊天,回复语言,发送键,回车发送,语音消息,跟进建议,输入建议,自动补全,字体大小,代码高亮,图表","settingsSearch.tabKeywords.credits": "用量,额度,余额,充值,购买充值包","settingsSearch.tabKeywords.creds": "凭证,密钥,授权","settingsSearch.tabKeywords.devices": "设备,会话,登录设备",@@ -2452,9 +2456,9 @@"tab.appearance": "外观","tab.automations": "自动化","tab.chatAppearance": "聊天外观",- "tab.chatPreference": "对话偏好","tab.common": "外观","tab.connector": "连接器",+ "tab.conversation": "对话","tab.creds": "密码库","tab.devices": "设备","tab.environments": "环境",diff --git a/locales/zh-TW/setting.json b/locales/zh-TW/setting.jsonindex f2ac55fd473..54052a7f3dc 100644--- a/locales/zh-TW/setting.json+++ b/locales/zh-TW/setting.json@@ -1498,7 +1498,6 @@"settingChat.title": "聊天設定","settingChatAppearance.autoScrollOnStreaming.desc": "當 AI 產生回應時自動捲動至底部","settingChatAppearance.autoScrollOnStreaming.title": "AI 回應時自動捲動",- "settingChatAppearance.chatBehavior.title": "聊天行為","settingChatAppearance.fontSize.desc": "訊息字體大小","settingChatAppearance.fontSize.marks.normal": "標準","settingChatAppearance.fontSize.title": "字體大小",@@ -1735,7 +1734,6 @@"settingsSearch.tabKeywords.apikey": "api, api 密鑰, apikey, token, 密碼, 個人密鑰","settingsSearch.tabKeywords.appearance": "外觀, 主題, 深色模式, 淺色模式, 字體, 語言, 顏色, 背景","settingsSearch.tabKeywords.billing": "帳單, 付款, 發票, 卡片, 交易",- "settingsSearch.tabKeywords.chatPreference": "聊天偏好,後續建議,輸入建議,自動完成","settingsSearch.tabKeywords.connector": "連接器, 整合, MCP","settingsSearch.tabKeywords.credits": "用量, 餘額, 儲值, 加值, 購買儲值包","settingsSearch.tabKeywords.creds": "憑證, 密鑰, OAuth",@@ -1987,7 +1985,6 @@"tab.apikey": "API Key 管理","tab.appearance": "外觀","tab.chatAppearance": "聊天外觀",- "tab.chatPreference": "聊天偏好","tab.common": "外觀","tab.connector": "連接器","tab.creds": "憑證",diff --git a/packages/locales/src/default/setting.ts b/packages/locales/src/default/setting.tsindex 2e6fb6633e5..4aa12f3299e 100644--- a/packages/locales/src/default/setting.ts+++ b/packages/locales/src/default/setting.ts@@ -1670,7 +1670,6 @@ export default {'settingChatAppearance.autoScrollOnStreaming.desc':'Automatically scroll to bottom when AI is generating response','settingChatAppearance.autoScrollOnStreaming.title': 'Auto-scroll During AI Response',- 'settingChatAppearance.chatBehavior.title': 'Chat Behavior','settingChatAppearance.workflowStreamingExpand.title': 'Expand Tool Steps While Running','settingChatAppearance.followUpBehavior.desc':'Queue follow-ups while the agent runs, or steer the current run',@@ -1716,6 +1715,12 @@ export default {'settingCommon.themeMode.light': 'Light','settingCommon.themeMode.title': 'Theme','settingCommon.title': 'General Settings',+ 'settingConversation.display.title': 'Message Display',+ 'settingConversation.input.title': 'Input & Sending',+ 'settingConversation.reply.title': 'Replies',+ 'settingConversation.voiceMessage.desc':+ 'Show the voice message button in the chat input to record and send voice messages.',+ 'settingConversation.voiceMessage.title': 'Voice Message','settingGroup.description.placeholder': 'Enter Group description','settingGroup.description.title': 'Group description','settingGroup.name.placeholder': 'Enter Group name',@@ -1868,9 +1873,9 @@ export default {'settingsSearch.tabKeywords.appearance':'appearance, theme, dark mode, light mode, font, language, color, background','settingsSearch.tabKeywords.billing': 'billing, payment, invoice, card, transaction',- 'settingsSearch.tabKeywords.chatPreference':- 'chat preferences, follow-up suggestions, input suggestions, autocomplete','settingsSearch.tabKeywords.connector': 'connectors, integrations, mcp',+ 'settingsSearch.tabKeywords.conversation':+ 'conversation, chat, reply language, send key, enter to send, voice message, follow-up suggestions, input suggestions, autocomplete, font size, code highlight, mermaid','settingsSearch.tabKeywords.credits': 'usage, balance, top up, recharge, buy top-up pack','settingsSearch.tabKeywords.creds': 'credentials, secrets, oauth','settingsSearch.tabKeywords.devices': 'devices, sessions, logged in devices',@@ -2308,9 +2313,9 @@ When I am ___, I need ___'tab.apikey': 'API Keys','tab.appearance': 'Appearance','tab.chatAppearance': 'Chat Appearance',- 'tab.chatPreference': 'Chat Preferences','tab.common': 'Appearance','tab.connector': 'Connectors',+ 'tab.conversation': 'Conversation','tab.creds': 'Vault','tab.devices': 'Devices','tab.experiment': 'Experiment',diff --git a/packages/types/src/user/settings/general.ts b/packages/types/src/user/settings/general.tsindex 6aad24b1175..ff68ede9582 100644--- a/packages/types/src/user/settings/general.ts+++ b/packages/types/src/user/settings/general.ts@@ -42,6 +42,11 @@ export interface UserGeneralConfig {* @default true*/enablePasteAutoConvert?: boolean;+ /**+ * Whether to show the voice message button in the chat input bar.+ * @default false+ */+ enableVoiceMessage?: boolean;/*** Whether a turn's tool workflow starts expanded while the agent is still* running. Off keeps the running turn to a single live headline row.diff --git a/src/components/Skeleton/Settings/tabs/Appearance.tsx b/src/components/Skeleton/Settings/tabs/Appearance.tsxindex e1c289fc47e..9d0dd7c4002 100644--- a/src/components/Skeleton/Settings/tabs/Appearance.tsx+++ b/src/components/Skeleton/Settings/tabs/Appearance.tsx@@ -2,7 +2,6 @@import { isDesktop } from '@lobechat/const';import { Flexbox } from '@lobehub/ui';-import { Form } from '@lobehub/ui/form';import SkeletonBar from '../../Bar';import { SettingsFormSkeleton, SWITCH_CONTROL } from '../Section';@@ -19,7 +18,7 @@ const HALF_SELECT = (</Flexbox>);-/** General: theme picker, language, motion and reply language. */+/** General: theme picker, language, motion and density. */export const CommonSectionSkeleton = () => {const text = useSkeletonText('setting');@@ -45,10 +44,6 @@ export const CommonSectionSkeleton = () => {label: text('settingAppearance.density.title', 64, 14),minWidth: undefined,},- {- control: HALF_SELECT,- label: text('settingCommon.responseLanguage.title', 64, 14),- },],title: text('settingCommon.title', 72),},@@ -113,10 +108,7 @@ const DesktopSectionSkeleton = () => {);};-/**- * Fonts: the four font-stack rows (Electron only), antialiasing, and the- * vertical font-size slider with its preview line.- */+/** Fonts: the four font-stack rows (Electron only) and antialiasing. */export const FontSectionSkeleton = () => {const text = useSkeletonText('setting');const fontRow = (key: string) => ({@@ -141,27 +133,6 @@ export const FontSectionSkeleton = () => {label: text('settingAppearance.font.antialiasing.title', 72, 14),minWidth: undefined,},- {- control: (- <Flexbox gap={16} width={'100%'}>- <Flexbox gap={24}>- <SkeletonBar height={4} />- <Flexbox horizontal align={'center'} justify={'space-between'}>- <SkeletonBar height={14} width={12} />- <SkeletonBar height={14} width={40} />- <SkeletonBar height={14} width={12} />- </Flexbox>- </Flexbox>- <Flexbox justify={'center'} style={{ height: 30 }}>- <SkeletonBar height={16} width={340} />- </Flexbox>- </Flexbox>- ),- desc: text('settingChatAppearance.fontSize.desc', 72, 12),- label: text('settingChatAppearance.fontSize.title', 56, 14),- layout: 'vertical',- minWidth: '100%',- },],title: text('settingAppearance.font.title', 32),},@@ -170,87 +141,13 @@ export const FontSectionSkeleton = () => {);};-/**- * Chat appearance: four separate blocks (36px apart in the settings container):- * transition preview, chat-behaviour switches, code and Mermaid theme previews.- */-export const ChatAppearanceSectionSkeleton = () => {- const text = useSkeletonText('setting');-- return (- <>- <Form.Group- collapsible={false}- extra={<SkeletonBar height={38} radius={8} width={151} />}- title={text('settingChatAppearance.transitionMode.title', 64)}- variant={'filled'}- >- <SkeletonBar height={182} radius={8} />- </Form.Group>- <SettingsFormSkeleton- groups={[- {- items: [- {- control: SWITCH_CONTROL,- label: text('settingChatAppearance.autoScrollOnStreaming.title', 120, 14),- minWidth: undefined,- },- {- control: SWITCH_CONTROL,- label: text('settingChatAppearance.workflowStreamingExpand.title', 120, 14),- minWidth: undefined,- },- {- control: SWITCH_CONTROL,- // The loaded description is a two-line link preview.- desc: (- <Flexbox gap={6} paddingBlock={4}>- <SkeletonBar height={14} width={160} />- <SkeletonBar height={14} width={200} />- </Flexbox>- ),- label: text('settingChatAppearance.linkIcon.title', 120, 14),- minWidth: undefined,- },- {- control: SWITCH_CONTROL,- desc: text('settingChatAppearance.pasteAutoConvert.desc', 360, 12),- label: text('settingChatAppearance.pasteAutoConvert.title', 120, 14),- minWidth: undefined,- },- ],- title: text('settingChatAppearance.chatBehavior.title', 64),- },- ]}- />- <Form.Group- collapsible={false}- extra={<SkeletonBar height={32} width={240} />}- title={text('settingChatAppearance.highlighterTheme.title', 96)}- variant={'filled'}- >- <SkeletonBar height={167} radius={8} />- </Form.Group>- <Form.Group- extra={<SkeletonBar height={32} width={240} />}- title={text('settingChatAppearance.mermaidTheme.title', 96)}- variant={'filled'}- >- <SkeletonBar height={295} radius={8} />- </Form.Group>- </>- );-};--/** The five appearance sections, as direct children of the 36px-gap settings container. */+/** The four appearance sections, as direct children of the 36px-gap settings container. */const Body = () => (<><CommonSectionSkeleton /><AppearanceSectionSkeleton /><DesktopSectionSkeleton /><FontSectionSkeleton />- <ChatAppearanceSectionSkeleton /></>);diff --git a/src/components/Skeleton/Settings/tabs/Conversation.tsx b/src/components/Skeleton/Settings/tabs/Conversation.tsxnew file mode 100644index 00000000000..93df8052fe2--- /dev/null+++ b/src/components/Skeleton/Settings/tabs/Conversation.tsx@@ -0,0 +1,215 @@+'use client';++import { Flexbox } from '@lobehub/ui';+import { Form } from '@lobehub/ui/form';++import { isMobileSurface } from '@/utils/mobileSurface';++import SkeletonBar from '../../Bar';+import { SettingsFormSkeleton, SWITCH_CONTROL } from '../Section';+import { useSkeletonText } from '../useSkeletonText';+import type { SettingsTabSkeleton } from './types';++/** The idle auto-save hint ("loaded the latest version") on the right of a group head. */+const SAVE_HINT = <SkeletonBar height={20} width={102} />;++/** A `Select` at 50% of the 335px control column, right-aligned as the loaded one. */+const HALF_SELECT = (+ <Flexbox horizontal justify={'flex-end'} width={'100%'}>+ <SkeletonBar height={32} width={'50%'} />+ </Flexbox>+);++/** Replies: reply language, then the switches for what a running turn shows. */+export const ReplySectionSkeleton = () => {+ const text = useSkeletonText('setting');++ return (+ <SettingsFormSkeleton+ groups={[+ {+ extra: SAVE_HINT,+ items: [+ { control: HALF_SELECT, label: text('settingCommon.responseLanguage.title', 64, 14) },+ {+ control: SWITCH_CONTROL,+ label: text('settingChatAppearance.autoScrollOnStreaming.title', 120, 14),+ minWidth: undefined,+ },+ {+ control: SWITCH_CONTROL,+ label: text('settingChatAppearance.workflowStreamingExpand.title', 120, 14),+ minWidth: undefined,+ },+ {+ control: SWITCH_CONTROL,+ desc: text('settingChatAppearance.showImageReadPreview.desc', 360, 12),+ label: text('settingChatAppearance.showImageReadPreview.title', 120, 14),+ minWidth: undefined,+ },+ ],+ title: text('settingConversation.reply.title', 48),+ },+ ]}+ />+ );+};++/** Chat assist: the follow-up suggestion and input completion rows. */+export const ChatAssistSectionSkeleton = () => {+ const text = useSkeletonText('setting');+ const row = (key: string) => ({+ control: { height: 32, width: 320 },+ desc: text(`systemAgent.${key}.modelDesc`, 240, 12),+ label: text(`systemAgent.${key}.title`, 96, 14),+ });++ return (+ <SettingsFormSkeleton+ groups={[+ {+ desc: text('chatPreference.assist.desc', 360, 12),+ items: [row('followUpAction'), row('inputCompletion')],+ title: text('chatPreference.assist.title', 64),+ },+ ]}+ />+ );+};++/** Input & sending: send key (not on mobile) and paste conversion. */+export const SendingSectionSkeleton = () => {+ const text = useSkeletonText('setting');+ return (+ <SettingsFormSkeleton+ groups={[+ {+ extra: SAVE_HINT,+ items: [+ ...(isMobileSurface()+ ? []+ : [+ {+ control: { height: 32, width: 160 },+ desc: text('hotkey.sendMessage.desc', 240, 12),+ label: text('hotkey.sendMessage.title', 72, 14),+ },+ ]),+ {+ control: SWITCH_CONTROL,+ desc: text('settingChatAppearance.pasteAutoConvert.desc', 360, 12),+ label: text('settingChatAppearance.pasteAutoConvert.title', 120, 14),+ minWidth: undefined,+ },+ {+ control: SWITCH_CONTROL,+ desc: text('settingConversation.voiceMessage.desc', 360, 12),+ label: text('settingConversation.voiceMessage.title', 96, 14),+ minWidth: undefined,+ },+ ],+ title: text('settingConversation.input.title', 72),+ },+ ]}+ />+ );+};++/** Message display: the vertical font-size slider with its preview, then link icons. */+export const DisplaySectionSkeleton = () => {+ const text = useSkeletonText('setting');++ return (+ <SettingsFormSkeleton+ groups={[+ {+ extra: SAVE_HINT,+ items: [+ {+ control: (+ <Flexbox gap={16} width={'100%'}>+ <Flexbox gap={24}>+ <SkeletonBar height={4} />+ <Flexbox horizontal align={'center'} justify={'space-between'}>+ <SkeletonBar height={14} width={12} />+ <SkeletonBar height={14} width={40} />+ <SkeletonBar height={14} width={12} />+ </Flexbox>+ </Flexbox>+ <Flexbox justify={'center'} style={{ height: 30 }}>+ <SkeletonBar height={16} width={340} />+ </Flexbox>+ </Flexbox>+ ),+ desc: text('settingChatAppearance.fontSize.desc', 72, 12),+ label: text('settingChatAppearance.fontSize.title', 56, 14),+ layout: 'vertical',+ minWidth: '100%',+ },+ {+ control: SWITCH_CONTROL,+ // The loaded description is a two-line link preview.+ desc: (+ <Flexbox gap={6} paddingBlock={4}>+ <SkeletonBar height={14} width={160} />+ <SkeletonBar height={14} width={200} />+ </Flexbox>+ ),+ label: text('settingChatAppearance.linkIcon.title', 120, 14),+ minWidth: undefined,+ },+ ],+ title: text('settingConversation.display.title', 72),+ },+ ]}+ />+ );+};++/** The three preview blocks: response transition, code and Mermaid themes. */+export const ThemesSectionSkeleton = () => {+ const text = useSkeletonText('setting');++ return (+ <>+ <Form.Group+ collapsible={false}+ extra={<SkeletonBar height={38} radius={8} width={151} />}+ title={text('settingChatAppearance.transitionMode.title', 64)}+ variant={'filled'}+ >+ <SkeletonBar height={182} radius={8} />+ </Form.Group>+ <Form.Group+ collapsible={false}+ extra={<SkeletonBar height={32} width={240} />}+ title={text('settingChatAppearance.highlighterTheme.title', 96)}+ variant={'filled'}+ >+ <SkeletonBar height={167} radius={8} />+ </Form.Group>+ <Form.Group+ extra={<SkeletonBar height={32} width={240} />}+ title={text('settingChatAppearance.mermaidTheme.title', 96)}+ variant={'filled'}+ >+ <SkeletonBar height={295} radius={8} />+ </Form.Group>+ </>+ );+};++/** The conversation sections, as direct children of the 36px-gap settings container. */+const Body = () => (+ <>+ <ReplySectionSkeleton />+ <ChatAssistSectionSkeleton />+ <SendingSectionSkeleton />+ <DisplaySectionSkeleton />+ <ThemesSectionSkeleton />+ </>+);++const ConversationSkeleton: SettingsTabSkeleton = { Body };++export default ConversationSkeleton;diff --git a/src/components/Skeleton/Settings/tabs/index.ts b/src/components/Skeleton/Settings/tabs/index.tsindex d2f0bef0f7f..b2d89b27b21 100644--- a/src/components/Skeleton/Settings/tabs/index.ts+++ b/src/components/Skeleton/Settings/tabs/index.ts@@ -6,6 +6,7 @@ import APIKeySkeleton from './APIKey';import AppearanceSkeleton from './Appearance';import AutomationsSkeleton from './Automations';import BillingSkeleton from './Billing';+import ConversationSkeleton from './Conversation';import CreditsSkeleton from './Credits';import CredsSkeleton from './Creds';import DevicesSkeleton from './Devices';@@ -43,6 +44,7 @@ export const SETTINGS_TAB_SKELETONS: Partial<Record<SettingsTabs, SettingsTabSke// The same list surface.[SettingsTabs.Webhooks]: AutomationsSkeleton,[SettingsTabs.Billing]: BillingSkeleton,+ [SettingsTabs.Conversation]: ConversationSkeleton,[SettingsTabs.Credits]: CreditsSkeleton,[SettingsTabs.Creds]: CredsSkeleton,[SettingsTabs.Devices]: DevicesSkeleton,diff --git a/src/features/ChatInput/ActionBar/index.tsx b/src/features/ChatInput/ActionBar/index.tsxindex af833fdd1d5..2da4dbe4ab8 100644--- a/src/features/ChatInput/ActionBar/index.tsx+++ b/src/features/ChatInput/ActionBar/index.tsx@@ -2,15 +2,19 @@ import { type ChatInputActionsProps } from '@lobehub/editor/react';import { ChatInputActions } from '@lobehub/editor/react';import * as stylex from '@stylexjs/stylex';import { type StyleXStyles } from '@stylexjs/stylex';+import isEqual from 'fast-deep-equal';import { memo, useMemo } from 'react';import { useGlobalStore } from '@/store/global';import { systemStatusSelectors } from '@/store/global/selectors';+import { useUserStore } from '@/store/user';+import { userGeneralSettingsSelectors } from '@/store/user/selectors';import { type ActionKey, type ActionKeys } from '../ActionBar/config';import { actionMap } from '../ActionBar/config';import { useChatInputResourceAccess } from '../hooks/useChatInputResourceAccess';import { useChatInputStore } from '../store';+import { resolveLeftActionsForVoicePlacement } from '../utils/resolveVoiceActionPlacement';import { type DropdownPlacement } from './context';import { ActionBarContext, useActionBarContext } from './context';import { filterChatOnlyActions } from './filterChatOnlyActions';@@ -67,10 +71,18 @@ const ActionToolbar = memo<ActionToolbarComponentProps>(systemStatusSelectors.expandInputActionbar(s),s.toggleExpandInputActionbar,]);+ const enableVoiceMessage = useUserStore(userGeneralSettingsSelectors.enableVoiceMessage);const { canConfigureResource, canShowControls } = useChatInputResourceAccess();- const leftActions = useChatInputStore((s) =>- canConfigureResource ? s.leftActions : filterChatOnlyActions(s.leftActions),+ const scopedLeftActions = useChatInputStore(+ (s) => (canConfigureResource ? s.leftActions : filterChatOnlyActions(s.leftActions)),+ isEqual,+ );+ const rightActions = useChatInputStore((s) => s.rightActions, isEqual);+ const leftActions = useMemo(+ () =>+ resolveLeftActionsForVoicePlacement(scopedLeftActions, rightActions, enableVoiceMessage),+ [enableVoiceMessage, rightActions, scopedLeftActions],);const mobile = useChatInputStore((s) => s.mobile);diff --git a/src/features/ChatInput/SendArea/index.tsx b/src/features/ChatInput/SendArea/index.tsxindex 38146124054..4b6b9b5b749 100644--- a/src/features/ChatInput/SendArea/index.tsx+++ b/src/features/ChatInput/SendArea/index.tsx@@ -2,10 +2,14 @@ import { Flexbox } from '@lobehub/ui';import isEqual from 'fast-deep-equal';import { memo, type ReactNode, useMemo } from 'react';+import { useUserStore } from '@/store/user';+import { userGeneralSettingsSelectors } from '@/store/user/selectors';+import { type ActionKey } from '../ActionBar/config';import { actionMap } from '../ActionBar/config';import { useChatInputResourceAccess } from '../hooks/useChatInputResourceAccess';import { useChatInputStore } from '../store';+import { resolveRightActionsForVoicePlacement } from '../utils/resolveVoiceActionPlacement';import { resolveSendAreaActionKeys } from './resolveActionKeys';import RunningIndicator from './RunningIndicator';import SendButton from './SendButton';@@ -28,7 +32,9 @@ interface SendAreaProps {}const SendArea = memo<SendAreaProps>(({ hideContextWindow = true, prefix }) => {+ const enableVoiceMessage = useUserStore(userGeneralSettingsSelectors.enableVoiceMessage);const { canShowControls } = useChatInputResourceAccess();+ const leftActions = useChatInputStore((s) => s.leftActions, isEqual);const rightActions = useChatInputStore((s) => s.rightActions, isEqual);const activeAudioInputMode = useChatInputStore((s) => s.activeAudioInputMode);const audioInputActive = activeAudioInputMode !== undefined;@@ -38,13 +44,24 @@ const SendArea = memo<SendAreaProps>(({ hideContextWindow = true, prefix }) => {canShowControls? mapActionsToItems(resolveSendAreaActionKeys(- rightActions as ActionKey[],+ resolveRightActionsForVoicePlacement(+ leftActions,+ rightActions as ActionKey[],+ enableVoiceMessage,+ ),hideContextWindow,activeAudioInputMode,),): [],- [activeAudioInputMode, canShowControls, hideContextWindow, rightActions],+ [+ activeAudioInputMode,+ canShowControls,+ enableVoiceMessage,+ hideContextWindow,+ leftActions,+ rightActions,+ ],);return (diff --git a/src/features/ChatInput/StoreUpdater.test.tsx b/src/features/ChatInput/StoreUpdater.test.tsxindex 8c680c3413d..d6e9c60f80d 100644--- a/src/features/ChatInput/StoreUpdater.test.tsx+++ b/src/features/ChatInput/StoreUpdater.test.tsx@@ -1,9 +1,10 @@import { act, fireEvent, render, screen, waitFor } from '@testing-library/react';import { type PropsWithChildren, useEffect } from 'react';-import { beforeEach, describe, expect, it, vi } from 'vitest';+import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';import { getConversationSendButtonProps } from '@/features/Conversation/ChatInput/utils';import { useSingleton } from '@/hooks/useSingleton';+import { useUserStore } from '@/store/user';import SendButton from './SendArea/SendButton';import { createStore, Provider, useChatInputStore } from './store';@@ -60,6 +61,8 @@ const TestHarness = ({ children }: PropsWithChildren) => {return <Provider createStore={() => store}>{children}</Provider>;};+const initialUserState = useUserStore.getState();+beforeEach(() => {voiceRecorder.status = 'idle';voiceRecorder.reset.mockReset();@@ -67,6 +70,10 @@ beforeEach(() => {voiceRecorder.stop.mockReset();});+afterEach(() => {+ useUserStore.setState(initialUserState, true);+});+describe('ChatInput StoreUpdater', () => {it('shows a queued follow-up as a loading Send beside a static Stop', () => {const onStop = vi.fn();@@ -172,7 +179,32 @@ describe('ChatInput StoreUpdater', () => {expect(onChange).toHaveBeenLastCalledWith(true);});+ it('hides the voice message button by default until enabled in settings', () => {+ const store = createStore({+ agentId: 'voice-agent',+ canRecordVoiceMessage: true,+ leftActions: [],+ onVoiceMessageSend: () => true,+ rightActions: [],+ });++ render(+ <Provider createStore={() => store}>+ <VoiceMessage />+ </Provider>,+ );++ expect(screen.queryByTestId('voice-message-action')).toBeNull();++ act(() => {+ useUserStore.setState({ settings: { general: { enableVoiceMessage: true } } } as any);+ });++ expect(screen.getByTestId('voice-message-action')).not.toBeDisabled();+ });+it('lets an injected capability override the fallback model capability', () => {+ useUserStore.setState({ settings: { general: { enableVoiceMessage: true } } } as any);const store = createStore({agentId: 'voice-agent',canRecordVoiceMessage: true,@@ -192,6 +224,7 @@ describe('ChatInput StoreUpdater', () => {});it('blocks a second voice recording while the current response is generating', () => {+ useUserStore.setState({ settings: { general: { enableVoiceMessage: true } } } as any);const onStop = vi.fn();const store = createStore({agentId: 'voice-agent',@@ -222,6 +255,7 @@ describe('ChatInput StoreUpdater', () => {});it('cancels an active recording when a response starts generating', async () => {+ useUserStore.setState({ settings: { general: { enableVoiceMessage: true } } } as any);voiceRecorder.status = 'recording';voiceRecorder.reset.mockImplementation(() => {voiceRecorder.status = 'idle';diff --git a/src/features/ChatInput/VoiceMessage/index.tsx b/src/features/ChatInput/VoiceMessage/index.tsxindex 7836aa6d436..a5f5d29a40c 100644--- a/src/features/ChatInput/VoiceMessage/index.tsx+++ b/src/features/ChatInput/VoiceMessage/index.tsx@@ -7,6 +7,8 @@ import { ArrowUp, type LucideProps, RotateCcw, X } from 'lucide-react';import { memo, useCallback, useEffect, useRef } from 'react';import { useTranslation } from 'react-i18next';+import { useUserStore } from '@/store/user';+import { userGeneralSettingsSelectors } from '@/store/user/selectors';import { sx } from '@/styles/sx';import { ChatInputAction } from '../ActionBar/components/ChatInputAction';@@ -205,6 +207,7 @@ VoiceMessageControl.displayName = 'VoiceMessageControl';const VoiceMessage = memo(() => {const { t } = useTranslation('chat');+ const enableVoiceMessage = useUserStore(userGeneralSettingsSelectors.enableVoiceMessage);const agentId = useAgentId();const { model, provider } = useEffectiveModel(agentId);const fallbackCanRecordVoiceMessage = useVoiceMessageCapability(model, provider, agentId);@@ -222,7 +225,8 @@ const VoiceMessage = memo(() => {s.sendButtonProps,s.setActiveAudioInputMode,]);- const canRecordVoiceMessage = injectedCanRecordVoiceMessage ?? fallbackCanRecordVoiceMessage;+ const canRecordVoiceMessage =+ enableVoiceMessage && (injectedCanRecordVoiceMessage ?? fallbackCanRecordVoiceMessage);const isGenerating = Boolean(sendButtonProps?.generating);const canUseVoiceMessage = canRecordVoiceMessage && !isGenerating;const recorder = useVoiceMessageRecorder();@@ -265,8 +269,8 @@ const VoiceMessage = memo(() => {}, [recorder, setActiveAudioInputMode]);useEffect(() => {- if (isGenerating && isActive) discard();- }, [discard, isActive, isGenerating]);+ if ((isGenerating || !enableVoiceMessage) && isActive) discard();+ }, [discard, enableVoiceMessage, isActive, isGenerating]);const commitRecording = useCallback(async (captured?: VoiceMessageRecording) => {diff --git a/src/features/ChatInput/utils/resolveVoiceActionPlacement.test.ts b/src/features/ChatInput/utils/resolveVoiceActionPlacement.test.tsnew file mode 100644index 00000000000..4f3f64013cf--- /dev/null+++ b/src/features/ChatInput/utils/resolveVoiceActionPlacement.test.ts@@ -0,0 +1,60 @@+import { describe, expect, it } from 'vitest';++import type { ActionKey, ActionKeys } from '../ActionBar/config';+import {+ resolveLeftActionsForVoicePlacement,+ resolveRightActionsForVoicePlacement,+} from './resolveVoiceActionPlacement';++describe('resolveVoiceActionPlacement', () => {+ const leftActions: ActionKeys[] = ['plus', 'voiceDictation'];+ const rightActions: ActionKey[] = ['model', 'voiceMessage', 'contextWindow'];++ it('moves voiceDictation into the voiceMessage right slot when voice messages are disabled', () => {+ expect(resolveLeftActionsForVoicePlacement(leftActions, rightActions, false)).toEqual(['plus']);+ expect(resolveRightActionsForVoicePlacement(leftActions, rightActions, false)).toEqual([+ 'model',+ 'voiceDictation',+ 'contextWindow',+ ]);+ });++ it('keeps voiceDictation on the left and voiceMessage on the right when voice messages are enabled', () => {+ expect(resolveLeftActionsForVoicePlacement(leftActions, rightActions, true)).toEqual(+ leftActions,+ );+ expect(resolveRightActionsForVoicePlacement(leftActions, rightActions, true)).toEqual(+ rightActions,+ );+ });++ it('handles composers with grouped left actions', () => {+ const groupLeft: ActionKeys[] = [+ 'search',+ 'memory',+ 'fileUpload',+ 'tools',+ 'voiceDictation',+ '---',+ ['typo', 'params', 'clear'],+ ];++ expect(resolveLeftActionsForVoicePlacement(groupLeft, rightActions, false)).toEqual([+ 'search',+ 'memory',+ 'fileUpload',+ 'tools',+ '---',+ ['typo', 'params', 'clear'],+ ]);+ });++ it('leaves composers unchanged when either voice action is not configured', () => {+ expect(resolveLeftActionsForVoicePlacement(['plus'], rightActions, false)).toEqual(['plus']);+ expect(resolveRightActionsForVoicePlacement(['plus'], rightActions, false)).toEqual(+ rightActions,+ );+ expect(resolveLeftActionsForVoicePlacement(leftActions, ['model'], false)).toEqual(leftActions);+ expect(resolveRightActionsForVoicePlacement(leftActions, ['model'], false)).toEqual(['model']);+ });+});diff --git a/src/features/ChatInput/utils/resolveVoiceActionPlacement.ts b/src/features/ChatInput/utils/resolveVoiceActionPlacement.tsnew file mode 100644index 00000000000..fc2c75a9201--- /dev/null+++ b/src/features/ChatInput/utils/resolveVoiceActionPlacement.ts@@ -0,0 +1,54 @@+import type { ActionKey, ActionKeys } from '../ActionBar/config';++const hasActionKey = (actions: ActionKeys[] | undefined, target: ActionKey): boolean =>+ Boolean(actions?.some((item) => (Array.isArray(item) ? item.includes(target) : item === target)));++/**+ * When voice messages are off (the default), promote the left-side dictation+ * button into the voice-message slot beside Send. Once voice messages are+ * turned on, keep the configured left/right split so both buttons stay visible+ * on their own sides.+ */+export const shouldPromoteDictationToRight = (+ leftActions: ActionKeys[] | undefined,+ rightActions: ActionKeys[] | undefined,+ enableVoiceMessage: boolean,+): boolean =>+ !enableVoiceMessage &&+ hasActionKey(leftActions, 'voiceDictation') &&+ hasActionKey(rightActions, 'voiceMessage');++export const resolveLeftActionsForVoicePlacement = (+ leftActions: ActionKeys[],+ rightActions: ActionKeys[] | undefined,+ enableVoiceMessage: boolean,+): ActionKeys[] => {+ if (!shouldPromoteDictationToRight(leftActions, rightActions, enableVoiceMessage)) {+ return leftActions;+ }++ const result: ActionKeys[] = [];+ for (const item of leftActions) {+ if (Array.isArray(item)) {+ const next = item.filter((key) => key !== 'voiceDictation');+ if (next.length > 0) result.push(next);+ } else if (item !== 'voiceDictation') {+ result.push(item);+ }+ }++ return result;+};++export const resolveRightActionsForVoicePlacement = (+ leftActions: ActionKeys[] | undefined,+ rightActions: ActionKey[] | undefined,+ enableVoiceMessage: boolean,+): ActionKey[] => {+ const keys = rightActions || [];+ if (!shouldPromoteDictationToRight(leftActions, keys, enableVoiceMessage)) {+ return keys;+ }++ return keys.map((key) => (key === 'voiceMessage' ? 'voiceDictation' : key));+};diff --git a/src/features/CommandMenu/utils/contextCommands.ts b/src/features/CommandMenu/utils/contextCommands.tsindex 2545e720e5f..d9c2474faf5 100644--- a/src/features/CommandMenu/utils/contextCommands.ts+++ b/src/features/CommandMenu/utils/contextCommands.ts@@ -12,6 +12,7 @@ import {KeyboardIcon,KeyIcon,Map,+ MessagesSquareIcon,Palette as PaletteIcon,PieChart,UserCircle,@@ -125,6 +126,15 @@ export const CONTEXT_COMMANDS: Record<ContextType, ContextCommand[]> = {path: '/settings/provider',subPath: 'provider',},+ {+ icon: MessagesSquareIcon,+ keywords: ['conversation', 'chat', 'reply language', 'send key', 'font size'],+ label: 'Conversation',+ labelKey: 'tab.conversation',+ labelNamespace: 'setting',+ path: '/settings/conversation',+ subPath: 'conversation',+ },{icon: KeyboardIcon,keywords: ['hotkey', 'shortcut', 'keyboard'],diff --git a/src/features/Conversation/ChatInput/voiceMessageCapability.test.ts b/src/features/Conversation/ChatInput/voiceMessageCapability.test.tsindex 535d2363cb8..30a30c2c075 100644--- a/src/features/Conversation/ChatInput/voiceMessageCapability.test.ts+++ b/src/features/Conversation/ChatInput/voiceMessageCapability.test.ts@@ -51,6 +51,8 @@ const MultimodalServerConfigWrapper = ({ children }: PropsWithChildren) =>}),});+const VOICE_MESSAGE_ENABLED = { general: { enableVoiceMessage: true } };+afterEach(() => {useAgentStore.setState(initialAgentState, true);useAiInfraStore.setState(initialAiInfraState, true);@@ -60,6 +62,30 @@ afterEach(() => {});describe('canSendVoiceMessage', () => {+ it('stays disabled by default until enableVoiceMessage is turned on', () => {+ const agentId = 'default-off-voice-agent';+ const audioModel = {+ abilities: { audio: true },+ enabled: true,+ id: 'gemini-audio',+ providerId: ModelProvider.Google,+ type: 'chat',+ } as const;+ useAgentStore.setState({+ agentMap: {+ [agentId]: { chatConfig: {}, model: audioModel.id, provider: ModelProvider.Google },+ },+ } as any);+ useAiInfraStore.setState({ enabledAiModels: [audioModel] });+ useUserStore.setState({ workspaceUserPreference: {} });++ expect(canSendVoiceMessage({ agentId })).toBe(false);++ useUserStore.setState({ settings: VOICE_MESSAGE_ENABLED } as any);++ expect(canSendVoiceMessage({ agentId })).toBe(true);+ });+it('rechecks the transaction topic capability without depending on the mounted chat input', () => {const agentId = 'voice-agent';const topicId = 'voice-topic';@@ -83,7 +109,7 @@ describe('canSendVoiceMessage', () => {},} as any);useAiInfraStore.setState({ enabledAiModels: [audioModel, textModel] });- useUserStore.setState({ workspaceUserPreference: {} });+ useUserStore.setState({ settings: VOICE_MESSAGE_ENABLED, workspaceUserPreference: {} } as any);useChatStore.setState({activeAgentId: 'another-agent',activeTopicId: 'another-topic',@@ -138,6 +164,7 @@ describe('canSendVoiceMessage', () => {} as any);useAiInfraStore.setState({ enabledAiModels: [primaryModel, fallbackModel] });useUserStore.setState({+ settings: VOICE_MESSAGE_ENABLED,user: { id: 'user-member' },workspaceUserPreference: { agentModeOverrides: { [agentId]: true } },} as any);@@ -187,7 +214,7 @@ describe('heterogeneous agents', () => {const setAsr = (asr: { model: string; provider: string }) =>useUserStore.setState({- settings: { systemAgent: { asr } },+ settings: { ...VOICE_MESSAGE_ENABLED, systemAgent: { asr } },workspaceUserPreference: {},} as any);@@ -198,7 +225,7 @@ describe('heterogeneous agents', () => {enabledAiProviders: providers,} as any);const clearUserAsr = () =>- useUserStore.setState({ settings: {}, workspaceUserPreference: {} } as any);+ useUserStore.setState({ settings: VOICE_MESSAGE_ENABLED, workspaceUserPreference: {} } as any);it('allows voice messages without an audio-capable model once the STT provider is enabled', () => {setEnabledProviders([openaiProvider]);@@ -279,7 +306,10 @@ describe('useCanSendVoiceMessage', () => {},} as any);useAiInfraStore.setState({ enabledAiModels: [primaryModel, fallbackModel] });- useUserStore.setState({ workspaceUserPreference: {} });+ useUserStore.setState({+ settings: VOICE_MESSAGE_ENABLED,+ workspaceUserPreference: {},+ } as any);});const { result } = renderHook(() => useCanSendVoiceMessage({ agentId }), {@@ -334,6 +364,7 @@ describe('useCanSendVoiceMessage', () => {} as any);useAiInfraStore.setState({ enabledAiModels: [primaryModel, fallbackModel] });useUserStore.setState({+ settings: VOICE_MESSAGE_ENABLED,user: { id: 'user-member' },workspaceUserPreference: { agentModeOverrides: { [agentId]: false } },} as any);@@ -381,7 +412,10 @@ describe('useCanSendVoiceMessage', () => {},} as any);useAiInfraStore.setState({ enabledAiModels: [audioModel, textModel] });- useUserStore.setState({ workspaceUserPreference: {} });+ useUserStore.setState({+ settings: VOICE_MESSAGE_ENABLED,+ workspaceUserPreference: {},+ } as any);});const context = { agentId };@@ -391,6 +425,18 @@ describe('useCanSendVoiceMessage', () => {expect(result.current).toBe(true);+ act(() => {+ useUserStore.setState({ settings: { general: { enableVoiceMessage: false } } } as any);+ });++ expect(result.current).toBe(false);++ act(() => {+ useUserStore.setState({ settings: VOICE_MESSAGE_ENABLED } as any);+ });++ expect(result.current).toBe(true);+act(() => {useAgentStore.setState({agentMap: {diff --git a/src/features/Conversation/ChatInput/voiceMessageCapability.ts b/src/features/Conversation/ChatInput/voiceMessageCapability.tsindex 6da2a1ee49d..27ef09f1fde 100644--- a/src/features/Conversation/ChatInput/voiceMessageCapability.ts+++ b/src/features/Conversation/ChatInput/voiceMessageCapability.ts@@ -14,7 +14,7 @@ import { agentByIdSelectors } from '@/store/agent/selectors';import { getAiInfraStoreState, useAiInfraStore } from '@/store/aiInfra';import type { AiInfraStore } from '@/store/aiInfra/store';import { getUserStoreState, useUserStore } from '@/store/user';-import { systemAgentSelectors } from '@/store/user/selectors';+import { systemAgentSelectors, userGeneralSettingsSelectors } from '@/store/user/selectors';/*** A chosen speech-to-text model only counts once its provider is enabled: the default points at@@ -33,8 +33,10 @@ export const isVoiceMessageTranscribed = (context: ConversationContext) =>agentByIdSelectors.isAgentHeterogeneousById(context.agentId)(getAgentStoreState());export const canSendVoiceMessage = (context: ConversationContext) => {+ const userState = getUserStoreState();+ if (!userGeneralSettingsSelectors.enableVoiceMessage(userState)) return false;+if (isVoiceMessageTranscribed(context)) {- const userState = getUserStoreState();const { provider } = systemAgentSelectors.asr(userState);return (@@ -50,6 +52,7 @@ export const canSendVoiceMessage = (context: ConversationContext) => {};export const useCanSendVoiceMessage = (context: ConversationContext) => {+ const enableVoiceMessage = useUserStore(userGeneralSettingsSelectors.enableVoiceMessage);const { model, provider } = useEffectiveConversationModelConfig(context);const isTranscribed = useAgentStore(agentByIdSelectors.isAgentHeterogeneousById(context.agentId));const isAsrConfigured = useUserStore(systemAgentSelectors.isAsrConfigured);@@ -57,5 +60,7 @@ export const useCanSendVoiceMessage = (context: ConversationContext) => {const isAsrProviderReady = useAiInfraStore(isAsrProviderEnabled(asrProvider));const canSendRawAudio = useVoiceMessageCapability(model, provider, context.agentId);+ if (!enableVoiceMessage) return false;+return isTranscribed ? isAsrConfigured && isAsrProviderReady : canSendRawAudio;};diff --git a/src/features/ServiceModel/ChatAssistForm.tsx b/src/features/ServiceModel/ChatAssistForm.tsxindex 74840df316c..f3dd14161df 100644--- a/src/features/ServiceModel/ChatAssistForm.tsx+++ b/src/features/ServiceModel/ChatAssistForm.tsx@@ -8,7 +8,7 @@ import { useTranslation } from 'react-i18next';import AsyncError from '@/components/AsyncError';import AutoSaveHint from '@/components/Editor/AutoSaveHint';-import SettingsSectionSkeleton from '@/components/Skeleton/Settings/Section';+import { ChatAssistSectionSkeleton } from '@/components/Skeleton/Settings/tabs/Conversation';import { FORM_STYLE } from '@/const/layoutTokens';import ModelSelect from '@/features/ModelSelect';import { SettingsSearchAnchor } from '@/features/SettingsSearch/anchor';@@ -70,10 +70,10 @@ const ChatAssistControl = memo<ChatAssistControlProps>(({ itemKey }) => {ChatAssistControl.displayName = 'ChatAssistControl';/**- * The chat-assist entries of the service-model settings that stay personal- * inside a workspace (follow-up chips, input completion). Unlike- * `ServiceModelForm`, nothing here is gated on workspace permissions:- * every member configures their own.+ * The chat-assist entries (follow-up chips, input completion) shown on the+ * Conversation settings page. They are personal, so unlike `ServiceModelForm`+ * nothing here is gated on workspace permissions: every member configures+ * their own.*/const ChatAssistForm = memo(() => {const { t } = useTranslation('setting');@@ -94,20 +94,9 @@ const ChatAssistForm = memo(() => {onRetry={() => refreshUserState()}/>);- // One filled group of the chat-assist rows, as in the settled form;- // `RouteLoading` nested a second padded container inside the settings one.- return (- <SettingsSectionSkeleton- groups={[- {- desc: t('chatPreference.assist.desc'),- labels: PERSONAL_SYSTEM_AGENT_KEYS.map((key) => t(`systemAgent.${key}.title`)),- rows: PERSONAL_SYSTEM_AGENT_KEYS.length,- title: t('chatPreference.assist.title'),- },- ]}- />- );+ // The same group the conversation route skeleton draws, so loading never+ // swaps between two shapes.+ return <ChatAssistSectionSkeleton />;}const items: FormFieldProps[] = PERSONAL_SYSTEM_AGENT_KEYS.map((key) => {@@ -117,7 +106,7 @@ const ChatAssistForm = memo(() => {children: <ChatAssistControl itemKey={key} />,desc: t(`systemAgent.${key}.modelDesc`),label: (- <SettingsSearchAnchor id={`chat-preference-${key}`}>+ <SettingsSearchAnchor id={`conversation-${key}`}><span style={{ opacity: featureDisabled ? 0.45 : 1 }}>{t(`systemAgent.${key}.title`)}</span>diff --git a/src/features/ServiceModel/ServiceModelForm/index.tsx b/src/features/ServiceModel/ServiceModelForm/index.tsxindex c27e41e3017..da7ed300ccb 100644--- a/src/features/ServiceModel/ServiceModelForm/index.tsx+++ b/src/features/ServiceModel/ServiceModelForm/index.tsx@@ -148,11 +148,14 @@ const ServiceModelForm = ({ scope = 'personal' }: ServiceModelFormProps) => {}const isWorkspaceSettings = scope === 'workspace';+ // Personal tiers still pin the chat-assist slots that follow them; a+ // workspace's tiers never write the member's personal slots.const skipSlots = isWorkspaceSettings ? PERSONAL_SLOTS : NO_SLOTS;+ // Chat-assist rows are edited on the Conversation page in both scopes.const tiers = TIERS.map((tier) => ({...tier,rows: tier.rows.filter(- (row) => row === DEFAULT_AGENT_ROW || !skipSlots.has(row as UserServiceModelConfigKey),+ (row) => row === DEFAULT_AGENT_ROW || !PERSONAL_SLOTS.has(row as UserServiceModelConfigKey),),}));diff --git a/src/features/Settings/appearance/features/Font/index.tsx b/src/features/Settings/appearance/features/Font/index.tsxindex d2337fb1e3f..55d774c25d3 100644--- a/src/features/Settings/appearance/features/Font/index.tsx+++ b/src/features/Settings/appearance/features/Font/index.tsx@@ -16,7 +16,6 @@ import { preferenceSelectors, userGeneralSettingsSelectors } from '@/store/user/import { APPLICATION_DEFAULT_FONT, useSystemFontOptions } from '../useSystemFontOptions';import FallbackFontList from './FallbackFontList';-import { FontSizeControl } from './FontSize';import { joinFontStack, parseFontStack } from './fontStack';const FontSettings = memo(() => {@@ -25,7 +24,6 @@ const FontSettings = memo(() => {preferenceSelectors.fontFamily(s),preferenceSelectors.terminalFontFamily(s),]);- const fontSize = useUserStore(userGeneralSettingsSelectors.fontSize);const fontAntialiasing = useUserStore(userGeneralSettingsSelectors.fontAntialiasing);const updatePreference = useUserStore((s) => s.updatePreference);const setSettings = useUserStore((s) => s.setSettings);@@ -170,22 +168,6 @@ const FontSettings = memo(() => {),minWidth: undefined,},- {- children: (- <FontSizeControl- value={fontSize}- onChange={(value) => save(() => setSettings({ general: { fontSize: value } }))}- />- ),- desc: t('settingChatAppearance.fontSize.desc'),- label: (- <SettingsSearchAnchor id={'appearance-font-size'}>- {t('settingChatAppearance.fontSize.title')}- </SettingsSearchAnchor>- ),- layout: 'vertical',- minWidth: '100%',- },],extra: <AutoSaveHint lastUpdatedTime={lastSavedAt} saveStatus={saveStatus} onRetry={retry} />,title: t('settingAppearance.font.title'),diff --git a/src/features/Settings/appearance/index.tsx b/src/features/Settings/appearance/index.tsxindex 1edc916b932..7a654b1fec1 100644--- a/src/features/Settings/appearance/index.tsx+++ b/src/features/Settings/appearance/index.tsx@@ -2,7 +2,6 @@ import { useTranslation } from 'react-i18next';import SettingHeader from '@/features/Settings/features/SettingHeader';-import ChatAppearance from '../chat-appearance/features/ChatAppearance';import Appearance from '../common/features/Appearance';import Common from '../common/features/Common/Common';import Desktop from './features/Desktop';@@ -21,7 +20,6 @@ const Page = ({ showSettingHeader = true }: PageProps) => {<Appearance /><Desktop /><Font />- <ChatAppearance /></>);};diff --git a/src/features/Settings/chat-appearance/features/ChatAppearance/index.tsx b/src/features/Settings/chat-appearance/features/ChatAppearance/index.tsxdeleted file mode 100644index c746d6a9281..00000000000--- a/src/features/Settings/chat-appearance/features/ChatAppearance/index.tsx+++ /dev/null@@ -1,245 +0,0 @@-'use client';--import { Flexbox, highlighterThemes, mermaidThemes, Select, Switch, Tabs } from '@lobehub/ui';-import { Form, useForm } from '@lobehub/ui/form';-import isEqual from 'fast-deep-equal';-import { memo, useState } from 'react';-import { useTranslation } from 'react-i18next';--import AutoSaveHint from '@/components/Editor/AutoSaveHint';-import { ChatAppearanceSectionSkeleton } from '@/components/Skeleton/Settings/tabs/Appearance';-import { FORM_STYLE } from '@/const/layoutTokens';-import { useSaveState } from '@/hooks/useSaveState';-import { useUserStore } from '@/store/user';-import {- labPreferSelectors,- settingsSelectors,- userGeneralSettingsSelectors,-} from '@/store/user/selectors';--import ChatTransitionPreview from './ChatTransitionPreview';-import HighlighterPreview from './HighlighterPreview';-import LinkIconPreview from './LinkIconPreview';-import MermaidPreview from './MermaidPreview';--const ChatAppearance = memo(() => {- const { t } = useTranslation('setting');- const { general } = useUserStore(settingsSelectors.currentSettings, isEqual);- const enablePasteAutoConvert = useUserStore(userGeneralSettingsSelectors.enablePasteAutoConvert);- const enableBetterCodingExperience = useUserStore(- labPreferSelectors.enableBetterCodingExperience,- );- const [setSettings, isUserStateInit] = useUserStore((s) => [s.setSettings, s.isUserStateInit]);- const { status: saveStatus, lastSavedAt, save, retry } = useSaveState();- const [savingKey, setSavingKey] = useState<string>();- const form = useForm();-- if (!isUserStateInit) return <ChatAppearanceSectionSkeleton />;-- const handleChange = (key: string, value: any) => {- setSavingKey(key);- save(() => setSettings({ general: { [key]: value } }));- };-- // Show the shared save-state hint only on the control the user last touched.- const renderSaveHint = (key: string) =>- savingKey === key && (- <AutoSaveHint lastUpdatedTime={lastSavedAt} saveStatus={saveStatus} onRetry={retry} />- );-- return (- <>- <Form.Group- collapsible={false}- title={t('settingChatAppearance.transitionMode.title')}- variant={'filled'}- extra={- <Flexbox horizontal align={'center'} gap={8}>- {renderSaveHint('transitionMode')}- <Tabs- activeKey={general.transitionMode}- items={[- {- key: 'none',- label: t('settingChatAppearance.transitionMode.options.none.value'),- },- {- key: 'fadeIn',- label: t('settingChatAppearance.transitionMode.options.fadeIn'),- },- {- key: 'smooth',- label: t('settingChatAppearance.transitionMode.options.smooth'),- },- ]}- onChange={(key) => handleChange('transitionMode', key)}- />- </Flexbox>- }- >- <ChatTransitionPreview key={general.transitionMode} mode={general.transitionMode} />- </Form.Group>-- <Form- collapsible={false}- form={form}- itemsType={'group'}- variant={'filled'}- items={[- {- children: [- {- children: (- <Flexbox horizontal align={'center'} gap={8}>- {renderSaveHint('enableAutoScrollOnStreaming')}- <Switch- checked={general.enableAutoScrollOnStreaming ?? true}- onChange={(checked) => handleChange('enableAutoScrollOnStreaming', checked)}- />- </Flexbox>- ),- label: t('settingChatAppearance.autoScrollOnStreaming.title'),- minWidth: undefined,- },- {- children: (- <Flexbox horizontal align={'center'} gap={8}>- {renderSaveHint('expandWorkflowWhileStreaming')}- <Switch- checked={general.expandWorkflowWhileStreaming ?? false}- onChange={(checked) => handleChange('expandWorkflowWhileStreaming', checked)}- />- </Flexbox>- ),- label: t('settingChatAppearance.workflowStreamingExpand.title'),- minWidth: undefined,- },- {- children: (- <Flexbox horizontal align={'center'} gap={8}>- {renderSaveHint('showImageReadPreview')}- <Switch- checked={general.showImageReadPreview ?? true}- onChange={(checked) => handleChange('showImageReadPreview', checked)}- />- </Flexbox>- ),- desc: t('settingChatAppearance.showImageReadPreview.desc'),- label: t('settingChatAppearance.showImageReadPreview.title'),- minWidth: undefined,- },- {- children: (- <Flexbox horizontal align={'center'} gap={8}>- {renderSaveHint('enableMessageLinkIcon')}- <Switch- checked={general.enableMessageLinkIcon ?? true}- onChange={(checked) => handleChange('enableMessageLinkIcon', checked)}- />- </Flexbox>- ),- desc: <LinkIconPreview />,- label: t('settingChatAppearance.linkIcon.title'),- minWidth: undefined,- },- {- children: (- <Flexbox horizontal align={'center'} gap={8}>- {renderSaveHint('enablePasteAutoConvert')}- <Switch- checked={enablePasteAutoConvert}- onChange={(checked) => handleChange('enablePasteAutoConvert', checked)}- />- </Flexbox>- ),- desc: t('settingChatAppearance.pasteAutoConvert.desc'),- label: t('settingChatAppearance.pasteAutoConvert.title'),- minWidth: undefined,- },- ...(enableBetterCodingExperience- ? [- {- children: (- <Flexbox horizontal align={'center'} gap={8}>- {renderSaveHint('followUpBehavior')}- <Select- style={{ width: 160 }}- value={general.followUpBehavior ?? 'steer'}- options={[- {- label: t('settingChatAppearance.followUpBehavior.options.queue'),- value: 'queue',- },- {- label: t('settingChatAppearance.followUpBehavior.options.steer'),- value: 'steer',- },- ]}- onChange={(value) => handleChange('followUpBehavior', value)}- />- </Flexbox>- ),- desc: t('settingChatAppearance.followUpBehavior.desc'),- label: t('settingChatAppearance.followUpBehavior.title'),- minWidth: undefined,- },- ]- : []),- ],- title: t('settingChatAppearance.chatBehavior.title'),- },- ]}- {...FORM_STYLE}- />-- <Form.Group- collapsible={false}- title={t('settingChatAppearance.highlighterTheme.title')}- variant={'filled'}- extra={- <Flexbox horizontal align={'center'} gap={8}>- {renderSaveHint('highlighterTheme')}- <Select- value={general.highlighterTheme}- options={highlighterThemes.map((item) => ({- label: item.displayName,- value: item.id,- }))}- style={{- width: 240,- }}- onChange={(value) => handleChange('highlighterTheme', value)}- />- </Flexbox>- }- >- <HighlighterPreview key={general.highlighterTheme} theme={general.highlighterTheme} />- </Form.Group>-- <Form.Group- title={t('settingChatAppearance.mermaidTheme.title')}- variant={'filled'}- extra={- <Flexbox horizontal align={'center'} gap={8}>- {renderSaveHint('mermaidTheme')}- <Select- value={general.mermaidTheme}- options={mermaidThemes.map((item) => ({- label: item.displayName,- value: item.id,- }))}- style={{- width: 240,- }}- onChange={(value) => handleChange('mermaidTheme', value)}- />- </Flexbox>- }- >- <MermaidPreview key={general.mermaidTheme} theme={general.mermaidTheme} />- </Form.Group>- </>- );-});--export default ChatAppearance;diff --git a/src/features/Settings/common/features/Common/Common.tsx b/src/features/Settings/common/features/Common/Common.tsxindex f7485dc2477..0444bb47aef 100644--- a/src/features/Settings/common/features/Common/Common.tsx+++ b/src/features/Settings/common/features/Common/Common.tsx@@ -180,32 +180,6 @@ const Common = memo(() => {name: 'interfaceDensity',valueProp: 'activeKey',},- {- children: (- <Flexbox horizontal justify={'flex-end'}>- <Select- value={general?.responseLanguage || 'auto'}- options={[- { label: t('settingCommon.responseLanguage.auto'), value: 'auto' },- ...localeOptions,- ]}- style={{- width: '50%',- }}- onChange={(value) => {- save(() =>- setSettings({ general: { responseLanguage: value === 'auto' ? '' : value } }),- );- }}- />- </Flexbox>- ),- label: (- <SettingsSearchAnchor id={'appearance-response-language'}>- {t('settingCommon.responseLanguage.title')}- </SettingsSearchAnchor>- ),- },],extra: <AutoSaveHint lastUpdatedTime={lastSavedAt} saveStatus={saveStatus} onRetry={retry} />,title: t('settingCommon.title'),diff --git a/src/features/Settings/appearance/features/Font/ChatPreview.tsx b/src/features/Settings/conversation/features/ChatPreview.tsxsimilarity index 100%rename from src/features/Settings/appearance/features/Font/ChatPreview.tsxrename to src/features/Settings/conversation/features/ChatPreview.tsxdiff --git a/src/features/Settings/conversation/features/Display.tsx b/src/features/Settings/conversation/features/Display.tsxnew file mode 100644index 00000000000..c26713440f9--- /dev/null+++ b/src/features/Settings/conversation/features/Display.tsx@@ -0,0 +1,86 @@+'use client';++import { Switch } from '@lobehub/ui';+import { Form, type FormGroupItem, useForm } from '@lobehub/ui/form';+import { memo } from 'react';+import { useTranslation } from 'react-i18next';++import AutoSaveHint from '@/components/Editor/AutoSaveHint';+import { DisplaySectionSkeleton } from '@/components/Skeleton/Settings/tabs/Conversation';+import { FORM_STYLE } from '@/const/layoutTokens';+import { SettingsSearchAnchor } from '@/features/SettingsSearch/anchor';+import { useSaveState } from '@/hooks/useSaveState';+import { useUserStore } from '@/store/user';+import { settingsSelectors, userGeneralSettingsSelectors } from '@/store/user/selectors';++import { FontSizeControl } from './FontSize';+import LinkIconPreview from './LinkIconPreview';++/** How messages render: text size and link icons. */+const Display = memo(() => {+ const { t } = useTranslation('setting');+ const fontSize = useUserStore(userGeneralSettingsSelectors.fontSize);+ const enableMessageLinkIcon = useUserStore(+ (s) => settingsSelectors.currentSettings(s).general.enableMessageLinkIcon ?? true,+ );+ const [setSettings, isUserStateInit] = useUserStore((s) => [s.setSettings, s.isUserStateInit]);+ const { status: saveStatus, lastSavedAt, save, retry } = useSaveState();+ const form = useForm();++ if (!isUserStateInit) return <DisplaySectionSkeleton />;++ const group: FormGroupItem = {+ children: [+ {+ children: (+ <FontSizeControl+ value={fontSize}+ onChange={(value) => save(() => setSettings({ general: { fontSize: value } }))}+ />+ ),+ desc: t('settingChatAppearance.fontSize.desc'),+ label: (+ <SettingsSearchAnchor id={'conversation-font-size'}>+ {t('settingChatAppearance.fontSize.title')}+ </SettingsSearchAnchor>+ ),+ layout: 'vertical',+ minWidth: '100%',+ },+ {+ children: (+ <Switch+ checked={enableMessageLinkIcon}+ onChange={(checked) =>+ save(() => setSettings({ general: { enableMessageLinkIcon: checked } }))+ }+ />+ ),+ desc: <LinkIconPreview />,+ label: (+ <SettingsSearchAnchor id={'conversation-link-icon'}>+ {t('settingChatAppearance.linkIcon.title')}+ </SettingsSearchAnchor>+ ),+ minWidth: undefined,+ },+ ],+ extra: <AutoSaveHint lastUpdatedTime={lastSavedAt} saveStatus={saveStatus} onRetry={retry} />,+ title: t('settingConversation.display.title'),+ };++ return (+ <Form+ collapsible={false}+ form={form}+ items={[group]}+ itemsType={'group'}+ variant={'filled'}+ {...FORM_STYLE}+ />+ );+});++Display.displayName = 'ConversationDisplay';++export default Display;diff --git a/src/features/Settings/appearance/features/Font/FontSize.tsx b/src/features/Settings/conversation/features/FontSize.tsxsimilarity index 100%rename from src/features/Settings/appearance/features/Font/FontSize.tsxrename to src/features/Settings/conversation/features/FontSize.tsxdiff --git a/src/features/Settings/chat-appearance/features/ChatAppearance/LinkIconPreview.tsx b/src/features/Settings/conversation/features/LinkIconPreview.tsxsimilarity index 100%rename from src/features/Settings/chat-appearance/features/ChatAppearance/LinkIconPreview.tsxrename to src/features/Settings/conversation/features/LinkIconPreview.tsxdiff --git a/src/features/Settings/conversation/features/Reply.tsx b/src/features/Settings/conversation/features/Reply.tsxnew file mode 100644index 00000000000..64e1f3931df--- /dev/null+++ b/src/features/Settings/conversation/features/Reply.tsx@@ -0,0 +1,117 @@+'use client';++import { Flexbox, Select, Switch } from '@lobehub/ui';+import { Form, type FormGroupItem, useForm } from '@lobehub/ui/form';+import isEqual from 'fast-deep-equal';+import { memo } from 'react';+import { useTranslation } from 'react-i18next';++import AutoSaveHint from '@/components/Editor/AutoSaveHint';+import { ReplySectionSkeleton } from '@/components/Skeleton/Settings/tabs/Conversation';+import { FORM_STYLE } from '@/const/layoutTokens';+import { SettingsSearchAnchor } from '@/features/SettingsSearch/anchor';+import { useSaveState } from '@/hooks/useSaveState';+import { localeOptions } from '@/locales/resources';+import { useUserStore } from '@/store/user';+import { settingsSelectors } from '@/store/user/selectors';+import { type UserGeneralConfig } from '@/types/user/settings';++/** How the Agent replies: its language, and what a running turn shows. */+const Reply = memo(() => {+ const { t } = useTranslation('setting');+ const general = useUserStore((s) => settingsSelectors.currentSettings(s).general, isEqual);+ const [setSettings, isUserStateInit] = useUserStore((s) => [s.setSettings, s.isUserStateInit]);+ const { status: saveStatus, lastSavedAt, save, retry } = useSaveState();+ const form = useForm();++ if (!isUserStateInit) return <ReplySectionSkeleton />;++ const update = (value: Partial<UserGeneralConfig>) => save(() => setSettings({ general: value }));++ const group: FormGroupItem = {+ children: [+ {+ children: (+ <Flexbox horizontal justify={'flex-end'}>+ <Select+ value={general.responseLanguage || 'auto'}+ options={[+ { label: t('settingCommon.responseLanguage.auto'), value: 'auto' },+ ...localeOptions,+ ]}+ style={{+ width: '50%',+ }}+ onChange={(value) => update({ responseLanguage: value === 'auto' ? '' : value })}+ />+ </Flexbox>+ ),+ label: (+ <SettingsSearchAnchor id={'conversation-response-language'}>+ {t('settingCommon.responseLanguage.title')}+ </SettingsSearchAnchor>+ ),+ },+ {+ children: (+ <Switch+ checked={general.enableAutoScrollOnStreaming ?? true}+ onChange={(checked) => update({ enableAutoScrollOnStreaming: checked })}+ />+ ),+ label: (+ <SettingsSearchAnchor id={'conversation-auto-scroll'}>+ {t('settingChatAppearance.autoScrollOnStreaming.title')}+ </SettingsSearchAnchor>+ ),+ minWidth: undefined,+ },+ {+ children: (+ <Switch+ checked={general.expandWorkflowWhileStreaming ?? false}+ onChange={(checked) => update({ expandWorkflowWhileStreaming: checked })}+ />+ ),+ label: (+ <SettingsSearchAnchor id={'conversation-workflow-expand'}>+ {t('settingChatAppearance.workflowStreamingExpand.title')}+ </SettingsSearchAnchor>+ ),+ minWidth: undefined,+ },+ {+ children: (+ <Switch+ checked={general.showImageReadPreview ?? true}+ onChange={(checked) => update({ showImageReadPreview: checked })}+ />+ ),+ desc: t('settingChatAppearance.showImageReadPreview.desc'),+ label: (+ <SettingsSearchAnchor id={'conversation-image-read-preview'}>+ {t('settingChatAppearance.showImageReadPreview.title')}+ </SettingsSearchAnchor>+ ),+ minWidth: undefined,+ },+ ],+ extra: <AutoSaveHint lastUpdatedTime={lastSavedAt} saveStatus={saveStatus} onRetry={retry} />,+ title: t('settingConversation.reply.title'),+ };++ return (+ <Form+ collapsible={false}+ form={form}+ items={[group]}+ itemsType={'group'}+ variant={'filled'}+ {...FORM_STYLE}+ />+ );+});++Reply.displayName = 'ConversationReply';++export default Reply;diff --git a/src/features/Settings/conversation/features/Sending.tsx b/src/features/Settings/conversation/features/Sending.tsxnew file mode 100644index 00000000000..dd6ec5b0d89--- /dev/null+++ b/src/features/Settings/conversation/features/Sending.tsx@@ -0,0 +1,168 @@+'use client';++import { KeyEnum } from '@lobechat/const/hotkeys';+import { combineKeys, Flexbox, Hotkey, Select, Switch } from '@lobehub/ui';+import { Form, type FormFieldProps, type FormGroupItem, useForm } from '@lobehub/ui/form';+import isEqual from 'fast-deep-equal';+import { memo } from 'react';+import { Trans, useTranslation } from 'react-i18next';++import AutoSaveHint from '@/components/Editor/AutoSaveHint';+import { SendingSectionSkeleton } from '@/components/Skeleton/Settings/tabs/Conversation';+import { FORM_STYLE } from '@/const/layoutTokens';+import { SettingsSearchAnchor } from '@/features/SettingsSearch/anchor';+import { useSaveState } from '@/hooks/useSaveState';+import { useUserStore } from '@/store/user';+import {+ labPreferSelectors,+ settingsSelectors,+ userGeneralSettingsSelectors,+} from '@/store/user/selectors';+import { type UserGeneralConfig } from '@/types/user/settings';+import { isMobileSurface } from '@/utils/mobileSurface';++import { type SendKey, useSendKeyPreference } from './useSendKeyPreference';++const SendKeyLabel = memo<{ sendKey: SendKey }>(({ sendKey }) => (+ <Flexbox horizontal align={'center'} as={'span'} gap={4}>+ <Trans+ i18nKey={sendKey === 'enter' ? 'input.sendWithEnter' : 'input.sendWithCmdEnter'}+ ns={'chat'}+ components={{+ key: (+ <Hotkey+ as={'span'}+ keys={sendKey === 'enter' ? KeyEnum.Enter : combineKeys([KeyEnum.Mod, KeyEnum.Enter])}+ variant={'borderless'}+ />+ ),+ }}+ />+ </Flexbox>+));++const SEND_KEY_OPTIONS = (['enter', 'modEnter'] as const).map((sendKey) => ({+ label: <SendKeyLabel sendKey={sendKey} />,+ value: sendKey,+}));++/** How messages get into the conversation: send key, paste handling, sending mid-run. */+const Sending = memo(() => {+ const { t } = useTranslation(['setting', 'chat']);+ const general = useUserStore((s) => settingsSelectors.currentSettings(s).general, isEqual);+ const enablePasteAutoConvert = useUserStore(userGeneralSettingsSelectors.enablePasteAutoConvert);+ const enableVoiceMessage = useUserStore(userGeneralSettingsSelectors.enableVoiceMessage);+ const enableBetterCodingExperience = useUserStore(+ labPreferSelectors.enableBetterCodingExperience,+ );+ const [setSettings, isUserStateInit] = useUserStore((s) => [s.setSettings, s.isUserStateInit]);+ const { sendKey, setSendKey } = useSendKeyPreference();+ const { status: saveStatus, lastSavedAt, save, retry } = useSaveState();+ const form = useForm();++ if (!isUserStateInit) return <SendingSectionSkeleton />;++ const update = (value: Partial<UserGeneralConfig>) => save(() => setSettings({ general: value }));++ // A touch keyboard has no modifier to pair with Enter, so the choice only+ // exists where hotkeys do.+ const sendKeyItem: FormFieldProps | undefined = isMobileSurface()+ ? undefined+ : {+ children: (+ <Select+ aria-label={t('hotkey.sendMessage.title')}+ options={SEND_KEY_OPTIONS}+ style={{ minWidth: 160 }}+ value={sendKey}+ onChange={(value: SendKey) => save(() => setSendKey(value))}+ />+ ),+ desc: t('hotkey.sendMessage.desc'),+ label: (+ <SettingsSearchAnchor id={'conversation-send-key'}>+ {t('hotkey.sendMessage.title')}+ </SettingsSearchAnchor>+ ),+ };++ // Only read while the Better Coding Experience lab is on.+ const followUpBehaviorItem: FormFieldProps | undefined = enableBetterCodingExperience+ ? {+ children: (+ <Select+ style={{ width: 160 }}+ value={general.followUpBehavior ?? 'steer'}+ options={[+ {+ label: t('settingChatAppearance.followUpBehavior.options.queue'),+ value: 'queue',+ },+ {+ label: t('settingChatAppearance.followUpBehavior.options.steer'),+ value: 'steer',+ },+ ]}+ onChange={(value) => update({ followUpBehavior: value })}+ />+ ),+ desc: t('settingChatAppearance.followUpBehavior.desc'),+ label: t('settingChatAppearance.followUpBehavior.title'),+ minWidth: undefined,+ }+ : undefined;++ const group: FormGroupItem = {+ children: [+ sendKeyItem,+ {+ children: (+ <Switch+ checked={enablePasteAutoConvert}+ onChange={(checked) => update({ enablePasteAutoConvert: checked })}+ />+ ),+ desc: t('settingChatAppearance.pasteAutoConvert.desc'),+ label: (+ <SettingsSearchAnchor id={'conversation-paste-auto-convert'}>+ {t('settingChatAppearance.pasteAutoConvert.title')}+ </SettingsSearchAnchor>+ ),+ minWidth: undefined,+ },+ {+ children: (+ <Switch+ checked={enableVoiceMessage}+ onChange={(checked) => update({ enableVoiceMessage: checked })}+ />+ ),+ desc: t('settingConversation.voiceMessage.desc'),+ label: (+ <SettingsSearchAnchor id={'conversation-voice-message'}>+ {t('settingConversation.voiceMessage.title')}+ </SettingsSearchAnchor>+ ),+ minWidth: undefined,+ },+ followUpBehaviorItem,+ ].filter((item): item is FormFieldProps => !!item),+ extra: <AutoSaveHint lastUpdatedTime={lastSavedAt} saveStatus={saveStatus} onRetry={retry} />,+ title: t('settingConversation.input.title'),+ };++ return (+ <Form+ collapsible={false}+ form={form}+ items={[group]}+ itemsType={'group'}+ variant={'filled'}+ {...FORM_STYLE}+ />+ );+});++Sending.displayName = 'ConversationSending';++export default Sending;diff --git a/src/features/Settings/chat-appearance/features/ChatAppearance/ChatTransitionPreview.tsx b/src/features/Settings/conversation/features/Themes/ChatTransitionPreview.tsxsimilarity index 100%rename from src/features/Settings/chat-appearance/features/ChatAppearance/ChatTransitionPreview.tsxrename to src/features/Settings/conversation/features/Themes/ChatTransitionPreview.tsxdiff --git a/src/features/Settings/chat-appearance/features/ChatAppearance/HighlighterPreview.tsx b/src/features/Settings/conversation/features/Themes/HighlighterPreview.tsxsimilarity index 100%rename from src/features/Settings/chat-appearance/features/ChatAppearance/HighlighterPreview.tsxrename to src/features/Settings/conversation/features/Themes/HighlighterPreview.tsxdiff --git a/src/features/Settings/chat-appearance/features/ChatAppearance/MermaidPreview.tsx b/src/features/Settings/conversation/features/Themes/MermaidPreview.tsxsimilarity index 100%rename from src/features/Settings/chat-appearance/features/ChatAppearance/MermaidPreview.tsxrename to src/features/Settings/conversation/features/Themes/MermaidPreview.tsxdiff --git a/src/features/Settings/conversation/features/Themes/index.tsx b/src/features/Settings/conversation/features/Themes/index.tsxnew file mode 100644index 00000000000..e7176542d93--- /dev/null+++ b/src/features/Settings/conversation/features/Themes/index.tsx@@ -0,0 +1,146 @@+'use client';++import { Flexbox, highlighterThemes, mermaidThemes, Select, Tabs } from '@lobehub/ui';+import { Form } from '@lobehub/ui/form';+import isEqual from 'fast-deep-equal';+import { memo, useState } from 'react';+import { useTranslation } from 'react-i18next';++import AutoSaveHint from '@/components/Editor/AutoSaveHint';+import { ThemesSectionSkeleton } from '@/components/Skeleton/Settings/tabs/Conversation';+import { SettingsSearchAnchor } from '@/features/SettingsSearch/anchor';+import { useSaveState } from '@/hooks/useSaveState';+import { useUserStore } from '@/store/user';+import { settingsSelectors } from '@/store/user/selectors';+import { type UserGeneralConfig } from '@/types/user/settings';++import ChatTransitionPreview from './ChatTransitionPreview';+import HighlighterPreview from './HighlighterPreview';+import MermaidPreview from './MermaidPreview';++type ThemeKey = keyof Pick<+ UserGeneralConfig,+ 'highlighterTheme' | 'mermaidTheme' | 'transitionMode'+>;++/** The previewed choices: reply transition, code highlight and Mermaid themes. */+const Themes = memo(() => {+ const { t } = useTranslation('setting');+ const { general } = useUserStore(settingsSelectors.currentSettings, isEqual);+ const [setSettings, isUserStateInit] = useUserStore((s) => [s.setSettings, s.isUserStateInit]);+ const { status: saveStatus, lastSavedAt, save, retry } = useSaveState();+ const [savingKey, setSavingKey] = useState<ThemeKey>();++ if (!isUserStateInit) return <ThemesSectionSkeleton />;++ const handleChange = <K extends ThemeKey>(key: K, value: UserGeneralConfig[K]) => {+ setSavingKey(key);+ save(() => setSettings({ general: { [key]: value } }));+ };++ // Show the shared save-state hint only on the control the user last touched.+ const renderSaveHint = (key: ThemeKey) =>+ savingKey === key && (+ <AutoSaveHint lastUpdatedTime={lastSavedAt} saveStatus={saveStatus} onRetry={retry} />+ );++ return (+ <>+ <Form.Group+ collapsible={false}+ variant={'filled'}+ extra={+ <Flexbox horizontal align={'center'} gap={8}>+ {renderSaveHint('transitionMode')}+ <Tabs+ activeKey={general.transitionMode}+ items={[+ {+ key: 'none',+ label: t('settingChatAppearance.transitionMode.options.none.value'),+ },+ {+ key: 'fadeIn',+ label: t('settingChatAppearance.transitionMode.options.fadeIn'),+ },+ {+ key: 'smooth',+ label: t('settingChatAppearance.transitionMode.options.smooth'),+ },+ ]}+ onChange={(key) =>+ handleChange('transitionMode', key as UserGeneralConfig['transitionMode'])+ }+ />+ </Flexbox>+ }+ title={+ <SettingsSearchAnchor id={'conversation-transition'}>+ {t('settingChatAppearance.transitionMode.title')}+ </SettingsSearchAnchor>+ }+ >+ <ChatTransitionPreview key={general.transitionMode} mode={general.transitionMode} />+ </Form.Group>++ <Form.Group+ collapsible={false}+ variant={'filled'}+ extra={+ <Flexbox horizontal align={'center'} gap={8}>+ {renderSaveHint('highlighterTheme')}+ <Select+ value={general.highlighterTheme}+ options={highlighterThemes.map((item) => ({+ label: item.displayName,+ value: item.id,+ }))}+ style={{+ width: 240,+ }}+ onChange={(value) => handleChange('highlighterTheme', value)}+ />+ </Flexbox>+ }+ title={+ <SettingsSearchAnchor id={'conversation-highlighter-theme'}>+ {t('settingChatAppearance.highlighterTheme.title')}+ </SettingsSearchAnchor>+ }+ >+ <HighlighterPreview key={general.highlighterTheme} theme={general.highlighterTheme} />+ </Form.Group>++ <Form.Group+ variant={'filled'}+ extra={+ <Flexbox horizontal align={'center'} gap={8}>+ {renderSaveHint('mermaidTheme')}+ <Select+ value={general.mermaidTheme}+ options={mermaidThemes.map((item) => ({+ label: item.displayName,+ value: item.id,+ }))}+ style={{+ width: 240,+ }}+ onChange={(value) => handleChange('mermaidTheme', value)}+ />+ </Flexbox>+ }+ title={+ <SettingsSearchAnchor id={'conversation-mermaid-theme'}>+ {t('settingChatAppearance.mermaidTheme.title')}+ </SettingsSearchAnchor>+ }+ >+ <MermaidPreview key={general.mermaidTheme} theme={general.mermaidTheme} />+ </Form.Group>+ </>+ );+});++Themes.displayName = 'ConversationThemes';++export default Themes;diff --git a/src/features/Settings/hotkey/features/useSendKeyPreference.test.ts b/src/features/Settings/conversation/features/useSendKeyPreference.test.tssimilarity index 100%rename from src/features/Settings/hotkey/features/useSendKeyPreference.test.tsrename to src/features/Settings/conversation/features/useSendKeyPreference.test.tsdiff --git a/src/features/Settings/hotkey/features/useSendKeyPreference.ts b/src/features/Settings/conversation/features/useSendKeyPreference.tssimilarity index 100%rename from src/features/Settings/hotkey/features/useSendKeyPreference.tsrename to src/features/Settings/conversation/features/useSendKeyPreference.tsdiff --git a/src/features/Settings/conversation/index.tsx b/src/features/Settings/conversation/index.tsxnew file mode 100644index 00000000000..e1595c9e23d--- /dev/null+++ b/src/features/Settings/conversation/index.tsx@@ -0,0 +1,34 @@+import { useTranslation } from 'react-i18next';++import { ChatAssistForm } from '@/features/ServiceModel';+import SettingHeader from '@/features/Settings/features/SettingHeader';++import Display from './features/Display';+import Reply from './features/Reply';+import Sending from './features/Sending';+import Themes from './features/Themes';++interface PageProps {+ showSettingHeader?: boolean;+}++/**+ * How the user works with Agents in a conversation: replies, chat assist,+ * input and sending, and message display. User-scoped, so the workspace+ * settings mirror the same page.+ */+const Page = ({ showSettingHeader = true }: PageProps) => {+ const { t } = useTranslation('setting');+ return (+ <>+ {showSettingHeader && <SettingHeader title={t('tab.conversation')} />}+ <Reply />+ <ChatAssistForm />+ <Sending />+ <Display />+ <Themes />+ </>+ );+};++export default Page;diff --git a/src/features/Settings/features/SettingsContent.tsx b/src/features/Settings/features/SettingsContent.tsxindex 72d45a2e538..9a1d11249d9 100644--- a/src/features/Settings/features/SettingsContent.tsx+++ b/src/features/Settings/features/SettingsContent.tsx@@ -18,7 +18,7 @@ import { useSettingsTabTitle } from './tabTitles';const REDIRECT_MAP: Record<string, string> = {[SettingsTabs.Common]: SettingsTabs.Appearance,- [SettingsTabs.ChatAppearance]: SettingsTabs.Appearance,+ [SettingsTabs.ChatAppearance]: SettingsTabs.Conversation,[SettingsTabs.Agent]: SettingsTabs.ServiceModel,[SettingsTabs.TTS]: SettingsTabs.ServiceModel,[SettingsTabs.Image]: SettingsTabs.ServiceModel,diff --git a/src/features/Settings/features/componentMap.desktop.ts b/src/features/Settings/features/componentMap.desktop.tsindex d05594d34e7..703537a1244 100644--- a/src/features/Settings/features/componentMap.desktop.ts+++ b/src/features/Settings/features/componentMap.desktop.ts@@ -10,6 +10,7 @@ import Advanced from '../advanced';import APIKey from '../apikey';import Appearance from '../appearance';import Automations from '../automations';+import Conversation from '../conversation';import Creds from '../creds';import Devices from '../devices';import Environments from '../environments';@@ -36,6 +37,7 @@ export const componentMap = {[SettingsTabs.Advanced]: Advanced,[SettingsTabs.Labs]: Labs,[SettingsTabs.Appearance]: Appearance,+ [SettingsTabs.Conversation]: Conversation,[SettingsTabs.Provider]: Provider,[SettingsTabs.ServiceModel]: ServiceModel,[SettingsTabs.Memory]: Memory,diff --git a/src/features/Settings/features/componentMap.ts b/src/features/Settings/features/componentMap.tsindex 9153cf5cb87..c89eeff2a4d 100644--- a/src/features/Settings/features/componentMap.ts+++ b/src/features/Settings/features/componentMap.ts@@ -16,6 +16,9 @@ export const componentMap = {[SettingsTabs.Appearance]: dynamic(() => import('../appearance'), {loading: loading('Settings > Appearance'),}),+ [SettingsTabs.Conversation]: dynamic(() => import('../conversation'), {+ loading: loading('Settings > Conversation'),+ }),[SettingsTabs.Provider]: dynamic(() => import('../provider'), {loading: loading('Settings > Provider'),}),diff --git a/src/features/Settings/features/tabTitles.ts b/src/features/Settings/features/tabTitles.tsindex 88f481ef986..8801884e3ed 100644--- a/src/features/Settings/features/tabTitles.ts+++ b/src/features/Settings/features/tabTitles.ts@@ -17,6 +17,7 @@ export const SETTINGS_TAB_TITLE_KEYS: Partial<Record<SettingsTabs, TitleKey>> =[SettingsTabs.Automations]: ['setting', 'tab.automations'],[SettingsTabs.Webhooks]: ['setting', 'tab.webhooks'],[SettingsTabs.Billing]: ['subscription', 'tab.billing'],+ [SettingsTabs.Conversation]: ['setting', 'tab.conversation'],[SettingsTabs.Creds]: ['setting', 'tab.creds'],[SettingsTabs.Credits]: ['subscription', 'tab.credits'],[SettingsTabs.Devices]: ['setting', 'devices.title'],diff --git a/src/features/Settings/hooks/useCategory.test.tsx b/src/features/Settings/hooks/useCategory.test.tsxindex 5f4ac0cf3da..c6529f3e114 100644--- a/src/features/Settings/hooks/useCategory.test.tsx+++ b/src/features/Settings/hooks/useCategory.test.tsx@@ -77,6 +77,7 @@ describe('settings useCategory', () => {expect(groupKeys(SettingsGroupKey.Account)).toEqual([SettingsTabs.Profile,SettingsTabs.Appearance,+ SettingsTabs.Conversation,SettingsTabs.Hotkey,SettingsTabs.Notification,SettingsTabs.Stats,diff --git a/src/features/Settings/hooks/useCategory.tsx b/src/features/Settings/hooks/useCategory.tsxindex 0c070138da6..f7737d0e613 100644--- a/src/features/Settings/hooks/useCategory.tsx+++ b/src/features/Settings/hooks/useCategory.tsx@@ -20,6 +20,7 @@ import {KeyboardIcon,KeyIcon,Map,+ MessagesSquareIcon,MonitorSmartphoneIcon,PaletteIcon,Sparkles,@@ -108,6 +109,11 @@ export const useCategory = () => {key: SettingsTabs.Appearance,label: t('tab.appearance'),},+ {+ icon: MessagesSquareIcon,+ key: SettingsTabs.Conversation,+ label: t('tab.conversation'),+ },!mobile && {icon: KeyboardIcon,key: SettingsTabs.Hotkey,diff --git a/src/features/Settings/hooks/useSettingsSearchScope.test.ts b/src/features/Settings/hooks/useSettingsSearchScope.test.tsindex 280abeb64c6..9d9e5420c3a 100644--- a/src/features/Settings/hooks/useSettingsSearchScope.test.ts+++ b/src/features/Settings/hooks/useSettingsSearchScope.test.ts@@ -9,6 +9,20 @@ import { ServerConfigStoreProvider } from '@/store/serverConfig/Provider';import { usePersonalSettingsSearchScope } from './useSettingsSearchScope';const groups: SettingsSearchCategoryGroup[] = [+ {+ items: [+ { key: SettingsTabs.Appearance, label: 'Appearance' },+ { key: SettingsTabs.Conversation, label: 'Conversation' },+ { key: SettingsTabs.Hotkey, label: 'Hotkeys' },+ ],+ key: 'account',+ title: 'Account',+ },+ {+ items: [{ key: SettingsTabs.ServiceModel, label: 'Service Model' }],+ key: 'agent',+ title: 'Agent',+ },{items: [{ key: SettingsTabs.Plans, label: 'Plans' },@@ -43,4 +57,23 @@ describe('personal settings search scope', () => {it('still finds the page by its usage keywords', () => {expect(search('consumption').map((result) => result.url)).toContain('/settings/usage');});++ it('sends follow-up searches to the Conversation page, not Service Model', () => {+ const urls = search('follow up').map((result) => result.url);++ expect(urls).toContain('/settings/conversation#conversation-followUpAction');+ expect(urls.some((url) => url.includes('service-model'))).toBe(false);+ });++ it('finds the moved conversation settings on the Conversation page', () => {+ expect(search('send key').map((result) => result.url)).toContain(+ '/settings/conversation#conversation-send-key',+ );+ expect(search('response language').map((result) => result.url)).toContain(+ '/settings/conversation#conversation-response-language',+ );+ expect(search('response language').map((result) => result.url)).not.toContain(+ '/settings/appearance#appearance-response-language',+ );+ });});diff --git a/src/features/Settings/hooks/useSettingsSearchScope.ts b/src/features/Settings/hooks/useSettingsSearchScope.tsindex bf8b37feec8..46df5eb15b9 100644--- a/src/features/Settings/hooks/useSettingsSearchScope.ts+++ b/src/features/Settings/hooks/useSettingsSearchScope.ts@@ -16,8 +16,17 @@ const MERGED_TABS: Partial<Record<string, readonly SettingsSearchTab[]>> = {[SettingsTabs.Usage]: [SettingsTabs.Credits],};+/**+ * Follow-up / input completion live on Conversation; the Service Model page+ * hides them, so its keywords must not match them either.+ */+const KEYWORD_OWNER_TABS: readonly SettingsSearchTab[] = [SettingsTabs.Conversation];+/** Settings-search scope for the personal sidebar. */export const usePersonalSettingsSearchScope = (categoryGroups: SettingsSearchCategoryGroup[],): SettingsSearchScope =>- useMemo(() => ({ categoryGroups, mergedTabs: MERGED_TABS }), [categoryGroups]);+ useMemo(+ () => ({ categoryGroups, keywordOwnerTabs: KEYWORD_OWNER_TABS, mergedTabs: MERGED_TABS }),+ [categoryGroups],+ );diff --git a/src/features/Settings/hotkey/features/Conversation.tsx b/src/features/Settings/hotkey/features/Conversation.tsxindex bb97523a747..a4bff134558 100644--- a/src/features/Settings/hotkey/features/Conversation.tsx+++ b/src/features/Settings/hotkey/features/Conversation.tsx@@ -1,11 +1,11 @@'use client';-import { HotkeyGroupEnum, KeyEnum } from '@lobechat/const/hotkeys';-import { combineKeys, Flexbox, Hotkey, HotkeyInput, Select } from '@lobehub/ui';+import { HotkeyGroupEnum } from '@lobechat/const/hotkeys';+import { HotkeyInput } from '@lobehub/ui';import { Form, type FormGroupItem, useForm } from '@lobehub/ui/form';import isEqual from 'fast-deep-equal';import { memo } from 'react';-import { Trans, useTranslation } from 'react-i18next';+import { useTranslation } from 'react-i18next';import AutoSaveHint from '@/components/Editor/AutoSaveHint';import { ConversationHotkeysSkeleton } from '@/components/Skeleton/Settings/tabs/Hotkey';@@ -18,36 +18,10 @@ import { settingsSelectors } from '@/store/user/selectors';import { type HotkeyItem } from '@/types/hotkey';import { type UserHotkeyConfig } from '@/types/user/settings';-import { type SendKey, useSendKeyPreference } from './useSendKeyPreference';--const SendKeyLabel = memo<{ sendKey: SendKey }>(({ sendKey }) => (- <Flexbox horizontal align={'center'} as={'span'} gap={4}>- <Trans- i18nKey={sendKey === 'enter' ? 'input.sendWithEnter' : 'input.sendWithCmdEnter'}- ns={'chat'}- components={{- key: (- <Hotkey- as={'span'}- keys={sendKey === 'enter' ? KeyEnum.Enter : combineKeys([KeyEnum.Mod, KeyEnum.Enter])}- variant={'borderless'}- />- ),- }}- />- </Flexbox>-));--const SEND_KEY_OPTIONS = (['enter', 'modEnter'] as const).map((sendKey) => ({- label: <SendKeyLabel sendKey={sendKey} />,- value: sendKey,-}));-const HotkeySetting = memo(() => {- const { t } = useTranslation(['setting', 'hotkey', 'chat']);+ const { t } = useTranslation(['setting', 'hotkey']);const { hotkey } = useUserStore(settingsSelectors.currentSettings, isEqual);const [setSettings, isUserStateInit] = useUserStore((s) => [s.setSettings, s.isUserStateInit]);- const { sendKey, setSendKey } = useSendKeyPreference();const { status: saveStatus, lastSavedAt, save, retry } = useSaveState();const form = useForm({initialValues: hotkey,@@ -89,33 +63,10 @@ const HotkeySetting = memo(() => {};};- // Stored in user preference rather than the hotkey map, so it is a controlled- // field outside the hotkey form values.- const sendKeyItem = {- children: (- <Select- aria-label={t('hotkey.sendMessage.title')}- options={SEND_KEY_OPTIONS}- style={{ minWidth: 160 }}- value={sendKey}- onChange={(value: SendKey) => save(() => setSendKey(value))}- />- ),- desc: t('hotkey.sendMessage.desc'),- label: (- <SettingsSearchAnchor id={'hotkey-send-message'}>- {t('hotkey.sendMessage.title')}- </SettingsSearchAnchor>- ),- };-const conversation: FormGroupItem<UserHotkeyConfig> = {- children: [- sendKeyItem,- ...HOTKEYS_REGISTRATION.filter((item) => item.group === HotkeyGroupEnum.Conversation).map(- (item) => mapHotkeyItem(item),- ),- ],+ children: HOTKEYS_REGISTRATION.filter(+ (item) => item.group === HotkeyGroupEnum.Conversation,+ ).map((item) => mapHotkeyItem(item)),extra:saveStatus === 'idle' ? undefined : (<AutoSaveHint lastUpdatedTime={lastSavedAt} saveStatus={saveStatus} onRetry={retry} />diff --git a/src/features/SettingsSearch/items.test.ts b/src/features/SettingsSearch/items.test.tsindex 6d949c15d0f..a38bdd964f7 100644--- a/src/features/SettingsSearch/items.test.ts+++ b/src/features/SettingsSearch/items.test.ts@@ -20,6 +20,7 @@ const webContext: SettingsSearchContext = {hideDocs: false,isDesktop: false,isLogin: true,+ isMobile: false,isWindows: false,showAiImage: true,};@@ -34,6 +35,31 @@ describe('settings search index', () => {expect(item.visible?.({ ...webContext, enableChannels: true }) ?? true).toBe(true);});+ it('indexes the conversation settings under the Conversation tab only', () => {+ const conversationLabels = [+ 'settingCommon.responseLanguage.title',+ 'hotkey.sendMessage.title',+ 'settingConversation.voiceMessage.title',+ 'settingChatAppearance.fontSize.title',+ 'systemAgent.followUpAction.title',+ 'systemAgent.inputCompletion.title',+ ];++ for (const labelKey of conversationLabels) {+ const tabs = SETTINGS_SEARCH_ITEMS.filter((item) => item.labelKey === labelKey).map(+ (item) => item.tab,+ );+ expect(tabs, labelKey).toEqual([SettingsTabs.Conversation]);+ }+ });++ it('hides the send-key choice on the mobile surface', () => {+ const item = SETTINGS_SEARCH_ITEMS.find((entry) => entry.anchor === 'conversation-send-key')!;++ expect(item.visible?.(webContext) ?? true).toBe(true);+ expect(item.visible?.({ ...webContext, isMobile: true }) ?? true).toBe(false);+ });+it('derives one search item per lab feature in catalog order', () => {const labsItems = SETTINGS_SEARCH_ITEMS.filter((item) => item.tab === SettingsTabs.Labs);diff --git a/src/features/SettingsSearch/items.ts b/src/features/SettingsSearch/items.tsindex 67e6dcb15fb..08da0f6c93b 100644--- a/src/features/SettingsSearch/items.ts+++ b/src/features/SettingsSearch/items.ts@@ -1,6 +1,6 @@import { LAB_FEATURES } from '@/features/Settings/labs/features';import { SettingsTabs } from '@/store/global/initialState';-import { WorkspaceSettingsTabs } from '@/types/workspaceSettings';+import type { WorkspaceSettingsTabs } from '@/types/workspaceSettings';/*** Tab key the search indexes by. Personal tabs and the workspace-only tabs@@ -20,6 +20,8 @@ export interface SettingsSearchContext {hideDocs: boolean;isDesktop: boolean;isLogin: boolean;+ /** Whether this is the mobile SPA (touch keyboards have no send-key choice) */+ isMobile: boolean;/** Whether the app is running on Windows (for Windows-only settings) */isWindows: boolean;showAiImage: boolean;@@ -73,6 +75,22 @@ export const TAB_SEARCH_EN_KEYWORDS: Partial<Record<string, string[]>> = {'background',],[SettingsTabs.Billing]: ['billing', 'payment', 'invoice', 'card', 'transaction'],+ [SettingsTabs.Conversation]: [+ 'conversation',+ 'chat',+ 'chat preferences',+ 'reply language',+ 'send key',+ 'voice message',+ 'follow up',+ 'follow-up suggestions',+ 'input suggestions',+ 'input completion',+ 'autocomplete',+ 'font size',+ 'code theme',+ 'mermaid',+ ],[SettingsTabs.Automations]: ['automations','events',@@ -182,14 +200,6 @@ export const TAB_SEARCH_EN_KEYWORDS: Partial<Record<string, string[]>> = {'environment',],[SettingsTabs.Usage]: ['usage', 'consumption', 'quota', 'spend', 'statistics'],- [WorkspaceSettingsTabs.ChatPreference]: [- 'chat preferences',- 'follow up',- 'follow-up suggestions',- 'input suggestions',- 'input completion',- 'autocomplete',- ],};/**@@ -207,6 +217,7 @@ export const TAB_SEARCH_KEYWORDS_KEYS: Partial<Record<string, string>> = {[SettingsTabs.Automations]: 'settingsSearch.tabKeywords.automations',[SettingsTabs.Webhooks]: 'settingsSearch.tabKeywords.webhooks',[SettingsTabs.Billing]: 'settingsSearch.tabKeywords.billing',+ [SettingsTabs.Conversation]: 'settingsSearch.tabKeywords.conversation',[SettingsTabs.Credits]: 'settingsSearch.tabKeywords.credits',[SettingsTabs.Creds]: 'settingsSearch.tabKeywords.creds',[SettingsTabs.Devices]: 'settingsSearch.tabKeywords.devices',@@ -227,7 +238,6 @@ export const TAB_SEARCH_KEYWORDS_KEYS: Partial<Record<string, string>> = {[SettingsTabs.SystemTools]: 'settingsSearch.tabKeywords.systemTools',[SettingsTabs.Trash]: 'settingsSearch.tabKeywords.trash',[SettingsTabs.Usage]: 'settingsSearch.tabKeywords.usage',- [WorkspaceSettingsTabs.ChatPreference]: 'settingsSearch.tabKeywords.chatPreference',};/**@@ -337,13 +347,6 @@ export const SETTINGS_SEARCH_ITEMS: SettingsSearchItem[] = [labelKey: 'settingAppearance.density.title',tab: SettingsTabs.Appearance,},- {- anchor: 'appearance-response-language',- descKey: 'settingCommon.responseLanguage.desc',- keywords: ['response language', 'reply'],- labelKey: 'settingCommon.responseLanguage.title',- tab: SettingsTabs.Appearance,- },{anchor: 'appearance-primary-color',keywords: ['color', 'accent'],@@ -419,13 +422,6 @@ export const SETTINGS_SEARCH_ITEMS: SettingsSearchItem[] = [tab: SettingsTabs.Appearance,visible: (ctx) => ctx.isDesktop,},- {- anchor: 'appearance-font-size',- descKey: 'settingChatAppearance.fontSize.desc',- keywords: ['font', 'size', 'text'],- labelKey: 'settingChatAppearance.fontSize.title',- tab: SettingsTabs.Appearance,- },{anchor: 'appearance-font-antialiasing',descKey: 'settingAppearance.font.antialiasing.desc',@@ -433,6 +429,110 @@ export const SETTINGS_SEARCH_ITEMS: SettingsSearchItem[] = [labelKey: 'settingAppearance.font.antialiasing.title',tab: SettingsTabs.Appearance,},+ // Conversation+ {+ anchor: 'conversation-response-language',+ descKey: 'settingCommon.responseLanguage.desc',+ keywords: ['response language', 'reply', 'language'],+ labelKey: 'settingCommon.responseLanguage.title',+ tab: SettingsTabs.Conversation,+ },+ {+ anchor: 'conversation-auto-scroll',+ descKey: 'settingChatAppearance.autoScrollOnStreaming.desc',+ keywords: ['auto scroll', 'scroll', 'streaming'],+ labelKey: 'settingChatAppearance.autoScrollOnStreaming.title',+ tab: SettingsTabs.Conversation,+ },+ {+ anchor: 'conversation-workflow-expand',+ keywords: ['tool calls', 'workflow', 'expand', 'steps', 'streaming'],+ labelKey: 'settingChatAppearance.workflowStreamingExpand.title',+ tab: SettingsTabs.Conversation,+ },+ {+ anchor: 'conversation-image-read-preview',+ descKey: 'settingChatAppearance.showImageReadPreview.desc',+ keywords: ['image', 'preview', 'tool calls'],+ labelKey: 'settingChatAppearance.showImageReadPreview.title',+ tab: SettingsTabs.Conversation,+ },+ {+ anchor: 'conversation-followUpAction',+ descKey: 'systemAgent.followUpAction.modelDesc',+ keywords: ['follow up', 'suggestion', 'chips'],+ labelKey: 'systemAgent.followUpAction.title',+ tab: SettingsTabs.Conversation,+ },+ {+ anchor: 'conversation-inputCompletion',+ descKey: 'systemAgent.inputCompletion.modelDesc',+ keywords: ['input completion', 'autocomplete', 'suggestion'],+ labelKey: 'systemAgent.inputCompletion.title',+ tab: SettingsTabs.Conversation,+ },+ {+ anchor: 'conversation-send-key',+ descKey: 'hotkey.sendMessage.desc',+ keywords: [+ 'send key',+ 'send',+ 'enter',+ 'cmd enter',+ 'ctrl enter',+ 'newline',+ 'line break',+ 'shortcut',+ ],+ labelKey: 'hotkey.sendMessage.title',+ tab: SettingsTabs.Conversation,+ visible: (ctx) => !ctx.isMobile,+ },+ {+ anchor: 'conversation-paste-auto-convert',+ descKey: 'settingChatAppearance.pasteAutoConvert.desc',+ keywords: ['paste', 'markdown', 'rich text', 'format'],+ labelKey: 'settingChatAppearance.pasteAutoConvert.title',+ tab: SettingsTabs.Conversation,+ },+ {+ anchor: 'conversation-voice-message',+ descKey: 'settingConversation.voiceMessage.desc',+ keywords: ['voice message', 'voice', 'audio', 'microphone', 'record', 'speech'],+ labelKey: 'settingConversation.voiceMessage.title',+ tab: SettingsTabs.Conversation,+ },+ {+ anchor: 'conversation-font-size',+ descKey: 'settingChatAppearance.fontSize.desc',+ keywords: ['font', 'size', 'text'],+ labelKey: 'settingChatAppearance.fontSize.title',+ tab: SettingsTabs.Conversation,+ },+ {+ anchor: 'conversation-link-icon',+ keywords: ['link', 'favicon', 'icon'],+ labelKey: 'settingChatAppearance.linkIcon.title',+ tab: SettingsTabs.Conversation,+ },+ {+ anchor: 'conversation-transition',+ keywords: ['transition', 'animation', 'fade', 'streaming'],+ labelKey: 'settingChatAppearance.transitionMode.title',+ tab: SettingsTabs.Conversation,+ },+ {+ anchor: 'conversation-highlighter-theme',+ keywords: ['code', 'highlight', 'syntax', 'theme'],+ labelKey: 'settingChatAppearance.highlighterTheme.title',+ tab: SettingsTabs.Conversation,+ },+ {+ anchor: 'conversation-mermaid-theme',+ keywords: ['mermaid', 'diagram', 'chart', 'theme'],+ labelKey: 'settingChatAppearance.mermaidTheme.title',+ tab: SettingsTabs.Conversation,+ },// System Tools{anchor: 'system-tools-shell',@@ -503,8 +603,8 @@ export const SETTINGS_SEARCH_ITEMS: SettingsSearchItem[] = [tab: SettingsTabs.ServiceModel,},{- // Follow-up / input completion stay out of the keywords: inside a workspace- // they live on Chat Preferences, not here.+ // Follow-up / input completion stay out of the keywords: they live on+ // Conversation, not here.anchor: 'service-model-advanced',keywords: ['model assignment',@@ -545,22 +645,6 @@ export const SETTINGS_SEARCH_ITEMS: SettingsSearchItem[] = [tab: SettingsTabs.ServiceModel,visible: (ctx) => ctx.enableChannels,},- // Chat Preferences (workspace only — the personal sidebar keeps these rows in- // Service Model › Advanced)- {- anchor: 'chat-preference-followUpAction',- descKey: 'systemAgent.followUpAction.modelDesc',- keywords: ['follow up', 'suggestion', 'chips'],- labelKey: 'systemAgent.followUpAction.title',- tab: WorkspaceSettingsTabs.ChatPreference,- },- {- anchor: 'chat-preference-inputCompletion',- descKey: 'systemAgent.inputCompletion.modelDesc',- keywords: ['input completion', 'autocomplete', 'suggestion'],- labelKey: 'systemAgent.inputCompletion.title',- tab: WorkspaceSettingsTabs.ChatPreference,- },{anchor: 'service-model-image',descKey: 'settingImage.defaultCount.desc',@@ -639,13 +723,6 @@ export const SETTINGS_SEARCH_ITEMS: SettingsSearchItem[] = [labelKey: 'hotkey.group.essential',tab: SettingsTabs.Hotkey,},- {- anchor: 'hotkey-send-message',- descKey: 'hotkey.sendMessage.desc',- keywords: ['send', 'enter', 'cmd enter', 'ctrl enter', 'newline', 'line break', 'shortcut'],- labelKey: 'hotkey.sendMessage.title',- tab: SettingsTabs.Hotkey,- },{anchor: 'hotkey-conversation',keywords: ['shortcut', 'keyboard', 'chat'],diff --git a/src/features/SettingsSearch/useSettingsSearch.ts b/src/features/SettingsSearch/useSettingsSearch.tsindex 8225aa99bef..efeb28e0da2 100644--- a/src/features/SettingsSearch/useSettingsSearch.ts+++ b/src/features/SettingsSearch/useSettingsSearch.ts@@ -13,6 +13,7 @@ import {} from '@/store/serverConfig';import { useUserStore } from '@/store/user';import { authSelectors, userProfileSelectors } from '@/store/user/selectors';+import { isMobileSurface } from '@/utils/mobileSurface';import { getPlatform } from '@/utils/platform';import {@@ -158,6 +159,7 @@ export const useSettingsSearch = (hideDocs: !!hideDocs,isDesktop,isLogin: !!isLogin,+ isMobile: isMobileSurface(),isWindows: getPlatform() === 'Windows',showAiImage: !!showAiImage,};diff --git a/src/features/Workspace/workspaceAwarePath.ts b/src/features/Workspace/workspaceAwarePath.tsindex 1327931efdb..32e90a0fabc 100644--- a/src/features/Workspace/workspaceAwarePath.ts+++ b/src/features/Workspace/workspaceAwarePath.ts@@ -46,11 +46,14 @@ export const WORKSPACE_SETTINGS_TABS: ReadonlySet<string> = new Set(['automations','billing','budget',- // Personal chat-assist preferences, reachable by every member.+ // Legacy alias: chat preferences became `conversation`; the routers keep a+ // redirect, so prefixed deep-links still land on `/:slug/settings/conversation`.'chat-preference',// Legacy alias: connectors moved to `/marketplace/connector`; the routers keep// a redirect, so prefixed deep-links land on `/:slug/marketplace/connector`.'connector',+ // Personal conversation preferences, reachable by every member.+ 'conversation','credential',// Legacy alias for `credential` — the routers keep a redirect, so prefixed// deep-links still land on `/:slug/settings/credential`.diff --git a/src/features/WorkspaceSetting/Layout.tsx b/src/features/WorkspaceSetting/Layout.tsxindex e6f7a18f6b5..3d7865798ec 100644--- a/src/features/WorkspaceSetting/Layout.tsx+++ b/src/features/WorkspaceSetting/Layout.tsx@@ -22,7 +22,7 @@ const COMPACT_HEADER_TABS = new Set<string>([WorkspaceSettingsTabs.Webhooks,WorkspaceSettingsTabs.Billing,WorkspaceSettingsTabs.Budget,- WorkspaceSettingsTabs.ChatPreference,+ WorkspaceSettingsTabs.Conversation,WorkspaceSettingsTabs.Creds,WorkspaceSettingsTabs.Credits,WorkspaceSettingsTabs.Devices,diff --git a/src/features/WorkspaceSetting/hooks/useCategory.test.tsx b/src/features/WorkspaceSetting/hooks/useCategory.test.tsxindex 5c52e83916a..fd08d6eb64c 100644--- a/src/features/WorkspaceSetting/hooks/useCategory.test.tsx+++ b/src/features/WorkspaceSetting/hooks/useCategory.test.tsx@@ -91,7 +91,7 @@ describe('workspace settings useCategory', () => {WorkspaceSettingsTabs.Profile,WorkspaceSettingsTabs.Appearance,WorkspaceSettingsTabs.Hotkey,- WorkspaceSettingsTabs.ChatPreference,+ WorkspaceSettingsTabs.Conversation,]);expect(generalGroup?.items.map((item) => item.key)).not.toContain(WorkspaceSettingsTabs.Profile,diff --git a/src/features/WorkspaceSetting/hooks/useCategory.tsx b/src/features/WorkspaceSetting/hooks/useCategory.tsxindex c8f9a5f59df..c19ac65a586 100644--- a/src/features/WorkspaceSetting/hooks/useCategory.tsx+++ b/src/features/WorkspaceSetting/hooks/useCategory.tsx@@ -126,13 +126,13 @@ export const useWorkspaceSettingCategory = (): WorkspaceSettingCategoryGroup[] =key: WorkspaceSettingsTabs.Hotkey,label: t('tab.hotkey'),},- // Follow-up chips / input completion act on the member's own chat- // surface, so every role configures them here — the workspace- // Service Model page stays admin-only.+ // Conversation preferences (reply language, chat assist, send key…)+ // act on the member's own chat surface, so every role configures+ // them here — the workspace Service Model page stays admin-only.{icon: MessagesSquareIcon,- key: WorkspaceSettingsTabs.ChatPreference,- label: t('tab.chatPreference'),+ key: WorkspaceSettingsTabs.Conversation,+ label: t('tab.conversation'),},],key: WorkspaceSettingsGroupKey.Account,diff --git a/src/features/WorkspaceSetting/hooks/useSettingsSearchScope.test.ts b/src/features/WorkspaceSetting/hooks/useSettingsSearchScope.test.tsindex 63165dde4b2..e37c3801ef2 100644--- a/src/features/WorkspaceSetting/hooks/useSettingsSearchScope.test.ts+++ b/src/features/WorkspaceSetting/hooks/useSettingsSearchScope.test.ts@@ -13,7 +13,7 @@ const memberGroups: WorkspaceSettingCategoryGroup[] = [{items: [{ icon: null, key: WorkspaceSettingsTabs.Profile, label: 'Profile' },- { icon: null, key: WorkspaceSettingsTabs.ChatPreference, label: 'Chat Preferences' },+ { icon: null, key: WorkspaceSettingsTabs.Conversation, label: 'Conversation' },],key: WorkspaceSettingsGroupKey.Account,title: 'Account',@@ -68,18 +68,18 @@ describe('workspace settings search scope', () => {);});- it('deep-links follow-up suggestions to the chat preferences row for members', () => {+ it('deep-links follow-up suggestions to the conversation row for members', () => {const urls = search('follow up', memberGroups).map((result) => result.url);- expect(urls).toContain('/acme/settings/chat-preference#chat-preference-followUpAction');+ expect(urls).toContain('/acme/settings/conversation#conversation-followUpAction');// Service Model is admin-only: hidden from the sidebar, so not searchableexpect(urls.some((url) => url.includes('service-model'))).toBe(false);});- it('sends admins searching follow-up only to chat preferences', () => {+ it('sends admins searching follow-up only to conversation', () => {const urls = search('follow up', adminGroups).map((result) => result.url);- expect(urls).toContain('/acme/settings/chat-preference#chat-preference-followUpAction');+ expect(urls).toContain('/acme/settings/conversation#conversation-followUpAction');// The workspace Service Model page no longer renders these rowsexpect(urls.some((url) => url.includes('service-model'))).toBe(false);});diff --git a/src/features/WorkspaceSetting/hooks/useSettingsSearchScope.ts b/src/features/WorkspaceSetting/hooks/useSettingsSearchScope.tsindex b2aa41aaed3..3d819df381b 100644--- a/src/features/WorkspaceSetting/hooks/useSettingsSearchScope.ts+++ b/src/features/WorkspaceSetting/hooks/useSettingsSearchScope.ts@@ -15,19 +15,19 @@ import type { WorkspaceSettingCategoryGroup } from './useCategory';const ITEM_TABS: ReadonlySet<SettingsSearchTab> = new Set<SettingsSearchTab>([SettingsTabs.Advanced,SettingsTabs.Appearance,+ SettingsTabs.Conversation,SettingsTabs.Hotkey,SettingsTabs.Labs,SettingsTabs.Profile,SettingsTabs.Provider,SettingsTabs.ServiceModel,- WorkspaceSettingsTabs.ChatPreference,]);/**- * Follow-up / input completion live on Chat Preferences here; the workspace- * Service Model page hides them, so its keywords must not match them either.+ * Follow-up / input completion live on Conversation; the Service Model page+ * hides them, so its keywords must not match them either.*/-const KEYWORD_OWNER_TABS: readonly SettingsSearchTab[] = [WorkspaceSettingsTabs.ChatPreference];+const KEYWORD_OWNER_TABS: readonly SettingsSearchTab[] = [SettingsTabs.Conversation];/** Workspace tab keys whose value differs from the matching personal tab */const SEARCH_TAB_ALIASES: Partial<Record<WorkspaceSettingsTabs, SettingsSearchTab>> = {diff --git a/src/routes/(main)/[workspaceSlug]/settings/chat-preference/index.tsx b/src/routes/(main)/[workspaceSlug]/settings/chat-preference/index.tsxdeleted file mode 100644index 731c215ba04..00000000000--- a/src/routes/(main)/[workspaceSlug]/settings/chat-preference/index.tsx+++ /dev/null@@ -1,14 +0,0 @@-'use client';--import { ChatAssistForm } from '@/features/ServiceModel';--/**- * Personal chat-assist preferences under `/:workspaceSlug/settings/chat-preference`.- * User-scoped and open to every role; the workspace shell renders the compact- * header.- */-const WorkspaceChatPreferenceSetting = () => <ChatAssistForm />;--WorkspaceChatPreferenceSetting.displayName = 'WorkspaceChatPreferenceSetting';--export default WorkspaceChatPreferenceSetting;diff --git a/src/routes/(main)/[workspaceSlug]/settings/conversation/index.tsx b/src/routes/(main)/[workspaceSlug]/settings/conversation/index.tsxnew file mode 100644index 00000000000..978479ff0cd--- /dev/null+++ b/src/routes/(main)/[workspaceSlug]/settings/conversation/index.tsx@@ -0,0 +1,14 @@+'use client';++import ConversationSetting from '@/features/Settings/conversation';++/**+ * Personal conversation preferences mirrored under+ * `/:workspaceSlug/settings/conversation`. User-scoped and open to every role;+ * the workspace shell renders the compact header, so the page header is hidden.+ */+const WorkspaceConversationSetting = () => <ConversationSetting showSettingHeader={false} />;++WorkspaceConversationSetting.displayName = 'WorkspaceConversationSetting';++export default WorkspaceConversationSetting;diff --git a/src/routes/(mobile)/settings/_layout/Header.test.tsx b/src/routes/(mobile)/settings/_layout/Header.test.tsxindex fd1c580ec2b..a94c316552a 100644--- a/src/routes/(mobile)/settings/_layout/Header.test.tsx+++ b/src/routes/(mobile)/settings/_layout/Header.test.tsx@@ -37,8 +37,8 @@ describe('mobile settings Header', () => {['credits', 'subscription:tab.credits'],['devices', 'setting:tab.devices'],['service-model', 'setting:tab.serviceModel'],- ['chat-preference', 'setting:tab.chatPreference'],// No explicit entry: the kebab-case slug maps onto the camelCase key.+ ['conversation', 'setting:tab.conversation'],['subscription-accounts', 'setting:tab.subscriptionAccounts'],['oauth-apps', 'auth:tab.oauthApps'],])('resolves the workspace %s title', (tab, title) => {diff --git a/src/routes/(mobile)/settings/_layout/Header.tsx b/src/routes/(mobile)/settings/_layout/Header.tsxindex 03bfb426b77..0de8d058eae 100644--- a/src/routes/(mobile)/settings/_layout/Header.tsx+++ b/src/routes/(mobile)/settings/_layout/Header.tsx@@ -33,7 +33,6 @@ const TAB_TITLE_KEY: Partial<Record<SettingsTabs, string>> = {const WORKSPACE_TAB_TITLE_KEY: Record<string, string> = {'audit-log': 'setting:workspaceSetting.tab.auditLog','budget': 'subscription:tab.budget',- 'chat-preference': 'setting:tab.chatPreference','connector': 'setting:workspaceSetting.tab.connector','credential': 'setting:tab.creds','general': 'setting:workspaceSetting.tab.general',diff --git a/src/spa/router/desktopRouter.sync.test.tsx b/src/spa/router/desktopRouter.sync.test.tsxindex 9c7eca905d5..b6e9c280301 100644--- a/src/spa/router/desktopRouter.sync.test.tsx+++ b/src/spa/router/desktopRouter.sync.test.tsx@@ -847,6 +847,21 @@ describe('desktop router shared definition', () => {},);+ it.each(mainAreaVariants)(+ '%s serves Conversation settings and forwards old chat-preference links to it',+ (_, factory) => {+ const routes = createMainAreaRoutes(factory);++ expect(matchRoutes(routes, '/acme/settings/conversation')?.at(-1)?.route.path).toBe(+ 'conversation',+ );++ const legacy = matchRoutes(routes, '/acme/settings/chat-preference')?.at(-1)?.route+ .element as ReactElement<{ to: string }> | undefined;+ expect(legacy?.props.to).toBe('../conversation');+ },+ );+it.each(mainAreaVariants)('%s keeps workspace provider deep-links inside the workspace',(_, factory) => {diff --git a/src/spa/router/workspaceSettingsRoutes.tsx b/src/spa/router/workspaceSettingsRoutes.tsxindex 49ab3508f97..3ff836731de 100644--- a/src/spa/router/workspaceSettingsRoutes.tsx+++ b/src/spa/router/workspaceSettingsRoutes.tsx@@ -444,15 +444,20 @@ export const workspaceSettingsContentRoute: RouteObject = {},{element: dynamicElement(- () => import('@/routes/(main)/[workspaceSlug]/settings/chat-preference'),- 'Desktop > Workspace > Settings > Chat Preference',+ () => import('@/routes/(main)/[workspaceSlug]/settings/conversation'),+ 'Desktop > Workspace > Settings > Conversation',),handle: {meta: createWorkspaceSettingsRouteMeta(- WorkspaceSettingsTabs.ChatPreference,+ WorkspaceSettingsTabs.Conversation,createSurfaceSkeleton('form'),),},+ path: 'conversation',+ },+ // Legacy `/:slug/settings/chat-preference` URLs — the page became Conversation.+ {+ element: redirectElement('../conversation'),path: 'chat-preference',},// Developer tools mirrored inside the workspace (user preferences).diff --git a/src/store/global/initialState.ts b/src/store/global/initialState.tsindex efbfceb5a48..37f1e17afeb 100644--- a/src/store/global/initialState.ts+++ b/src/store/global/initialState.ts@@ -79,11 +79,12 @@ export enum SettingsTabs {Appearance = 'appearance',Automations = 'automations',Billing = 'billing',- /** @deprecated Use Appearance instead */+ /** @deprecated Use Conversation instead */ChatAppearance = 'chat-appearance',/** @deprecated Use Appearance instead */Common = 'common',Connector = 'connector',+ Conversation = 'conversation',Credits = 'credits',Creds = 'credential',Devices = 'devices',diff --git a/src/store/user/slices/settings/selectors/general.test.ts b/src/store/user/slices/settings/selectors/general.test.tsindex 728ee29e383..97eb02f7968 100644--- a/src/store/user/slices/settings/selectors/general.test.ts+++ b/src/store/user/slices/settings/selectors/general.test.ts@@ -135,6 +135,30 @@ describe('settingsSelectors', () => {});});+ describe('enableVoiceMessage', () => {+ it('should default to false when unset', () => {+ expect(userGeneralSettingsSelectors.enableVoiceMessage(initialState as UserStore)).toBe(+ false,+ );+ });++ it('should return true when turned on', () => {+ const s: UserState = merge(initialState, {+ settings: { general: { enableVoiceMessage: true } },+ });++ expect(userGeneralSettingsSelectors.enableVoiceMessage(s as UserStore)).toBe(true);+ });++ it('should return false when explicitly turned off', () => {+ const s: UserState = merge(initialState, {+ settings: { general: { enableVoiceMessage: false } },+ });++ expect(userGeneralSettingsSelectors.enableVoiceMessage(s as UserStore)).toBe(false);+ });+ });+describe('currentResponseLanguage', () => {it('should prefer the saved response language', () => {const s: UserState = merge(initialState, {diff --git a/src/store/user/slices/settings/selectors/general.ts b/src/store/user/slices/settings/selectors/general.tsindex 9b62927359a..62a1da3aa78 100644--- a/src/store/user/slices/settings/selectors/general.ts+++ b/src/store/user/slices/settings/selectors/general.ts@@ -38,6 +38,7 @@ const enableMessageLinkIcon = (s: UserStore) => generalConfig(s).enableMessageLi// Users who switched off the retired `enableInputMarkdown` lab did so to keep pasted text verbatim.const enablePasteAutoConvert = (s: UserStore) =>generalConfig(s).enablePasteAutoConvert ?? s.preference.lab?.enableInputMarkdown !== false;+const enableVoiceMessage = (s: UserStore) => generalConfig(s).enableVoiceMessage ?? false;const showImageReadPreview = (s: UserStore) => generalConfig(s).showImageReadPreview ?? true;const fontAntialiasing = (s: UserStore) => generalConfig(s).fontAntialiasing ?? true;const interfaceDensity = (s: UserStore): InterfaceDensity =>@@ -64,6 +65,7 @@ export const userGeneralSettingsSelectors = {enableAutoScrollOnStreaming,enableMessageLinkIcon,enablePasteAutoConvert,+ enableVoiceMessage,followUpBehavior,fontAntialiasing,fontSize,diff --git a/src/types/workspaceSettings.ts b/src/types/workspaceSettings.tsindex 7b2000a97ff..f430bdead12 100644--- a/src/types/workspaceSettings.ts+++ b/src/types/workspaceSettings.ts@@ -14,8 +14,8 @@ export enum WorkspaceSettingsTabs {Automations = 'automations',Billing = 'billing',Budget = 'budget',- ChatPreference = 'chat-preference',Connector = 'connector',+ Conversation = 'conversation',Credits = 'credits',Creds = 'credential',Devices = 'devices',