From 2974105e250ce3edaf15bf29a99260d4af92f32c Mon Sep 17 00:00:00 2001 From: Anais Saraiva Date: Mon, 21 Sep 2026 23:10:55 +0200 Subject: [PATCH] fixes --- frontend/src/components/Chat.tsx | 16 ++++++++-------- frontend/src/components/Markdown.tsx | 9 +++++++++ frontend/src/components/dialogs.tsx | 21 +++++++++++++++++++-- frontend/src/components/ui.tsx | 2 +- 4 files changed, 37 insertions(+), 11 deletions(-) diff --git a/frontend/src/components/Chat.tsx b/frontend/src/components/Chat.tsx index e4bfa92..24696de 100644 --- a/frontend/src/components/Chat.tsx +++ b/frontend/src/components/Chat.tsx @@ -25,11 +25,11 @@ function MessageBubble({ msg, index, authorAvatar, authorName, onReport, isFaile window.open(`https://duckduckgo.com/?q=${encodeURIComponent(msg.content.slice(0, 400))}`, "_blank", "noopener,noreferrer"); } return ( -
+
{isUser ? : } -
+
{isUser ? : } {isUser ? t("chat.you") : "KisAssistant"} @@ -39,7 +39,7 @@ function MessageBubble({ msg, index, authorAvatar, authorName, onReport, isFaile
) : ( -
+
)} @@ -313,8 +313,8 @@ export function Chat({
-
-
+
+
{messages.length === 0 && !streaming && (
@@ -326,11 +326,11 @@ export function Chat({ ))} {streaming !== "" && ( -
+
-
+
KisAssistant
-
+
diff --git a/frontend/src/components/Markdown.tsx b/frontend/src/components/Markdown.tsx index 4a90f0f..e5050f5 100644 --- a/frontend/src/components/Markdown.tsx +++ b/frontend/src/components/Markdown.tsx @@ -36,6 +36,15 @@ export function Markdown({ text }: { text: string }) { code({ children }) { return {children}; }, + table({ children }) { + // Wide tables would blow the bubble off-screen on mobile — + // scroll them inside their own pane instead. + return ( +
+ {children}
+
+ ); + }, }} > {text} diff --git a/frontend/src/components/dialogs.tsx b/frontend/src/components/dialogs.tsx index 9eac85d..0c6f109 100644 --- a/frontend/src/components/dialogs.tsx +++ b/frontend/src/components/dialogs.tsx @@ -402,6 +402,11 @@ export function SettingsModal({ setSearch(e.target.value)} + // The search field lives inside the settings
: Enter must + // only filter, never submit (save + close the modal). + onKeyDown={(e) => { + if (e.key === "Enter") e.preventDefault(); + }} placeholder={t("settings.searchPh")} aria-label={t("settings.searchAria")} className="w-full rounded-2xl border border-stone-200/70 bg-stone-100 py-2 pl-9 pr-8 text-sm outline-none transition placeholder:text-stone-400 focus:border-accent-500/60 focus:bg-white dark:border-zinc-800 dark:bg-zinc-800/60 dark:placeholder:text-zinc-500 dark:focus:bg-zinc-900" @@ -419,7 +424,16 @@ export function SettingsModal({
{search.trim() && visibleCats.length === 0 ? ( -

{t("settings.noMatch", { q: search.trim() })}

+
+

{t("settings.noMatch", { q: search.trim() })}

+ +
) : (