diff --git a/ui/desktop/eslint.config.js b/ui/desktop/eslint.config.js index d1422cd7..4ce023c5 100644 --- a/ui/desktop/eslint.config.js +++ b/ui/desktop/eslint.config.js @@ -86,6 +86,10 @@ module.exports = [ React: 'readonly', handleAction: 'readonly', requestAnimationFrame: 'readonly', + ResizeObserver: 'readonly', + MutationObserver: 'readonly', + NodeFilter: 'readonly', + Text: 'readonly', }, }, plugins: { diff --git a/ui/desktop/src/components/ChatView.tsx b/ui/desktop/src/components/ChatView.tsx index 9973dee6..cd2599c8 100644 --- a/ui/desktop/src/components/ChatView.tsx +++ b/ui/desktop/src/components/ChatView.tsx @@ -388,7 +388,7 @@ export default function ChatView({ /> ) : ( - + {filteredMessages.map((message, index) => (
{isUserMessage(message) ? ( diff --git a/ui/desktop/src/components/conversation/SearchBar.tsx b/ui/desktop/src/components/conversation/SearchBar.tsx index a52a05e5..4fd5bebb 100644 --- a/ui/desktop/src/components/conversation/SearchBar.tsx +++ b/ui/desktop/src/components/conversation/SearchBar.tsx @@ -51,18 +51,17 @@ export const SearchBar: React.FC = ({ const handleKeyDown = (event: KeyboardEvent) => { if (event.key === 'ArrowUp') { - event.preventDefault(); - onNavigate?.('prev'); + handleNavigate('prev', event); } else if (event.key === 'ArrowDown') { - event.preventDefault(); - onNavigate?.('next'); + handleNavigate('next', event); } else if (event.key === 'Escape') { event.preventDefault(); handleClose(); } }; - const handleNavigate = (direction: 'next' | 'prev') => { + const handleNavigate = (direction: 'next' | 'prev', e?: React.MouseEvent | KeyboardEvent) => { + e?.preventDefault(); onNavigate?.(direction); inputRef.current?.focus(); }; @@ -123,7 +122,7 @@ export const SearchBar: React.FC = ({