forked from huggingface/chat-ui
-
Notifications
You must be signed in to change notification settings - Fork 0
UI: remove conversation list skeletons and ensure Escape closes all modals #4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…elete metrics server implementation and all references\n- Drop /metrics endpoint and Prometheus counters\n- Clean Helm templates (ports, ServiceMonitor) and env\n- Remove metrics docs and TOC entry\n- Adjust .env defaults and server hooks
…n\n- Always show New Chat in desktop and mobile nav\n- Fix Switch component to toggle on click/keyboard\n- Simplify modal animation and allow disableFly for settings\n- Update settings layouts and styles
- Add and ambient types - Unblocks TS where older code references these without imports
- Group actions into a subtle bordered container - Promote “New chat” as primary action - Convert external links and copy action to consistent chips - Improve wrapping/alignment; adjust modal height and nav behaviors
- Remove stale comments and unused disabled classes - Keep send CTA styling consistent across themes
- Normalize POST/GET handling and error responses - Simplify retry/continue branches and update storage writes - Keep rate limiting and guest checks; minor typing tweaks - Consistent vote/share handlers
- Prefer `OPENAI_BASE_URL` (or `OPENAI_MODEL_LIST_URL`) to fetch model list - Support optional Authorization via HF_TOKEN/OPENAI_API_KEY - Provide clearer errors when not configured
- Keep ethicsModalAccepted optional; set timestamp when provided - Upsert with createdAt/updatedAt
- Keep parsing and smoothing logic intact - No behavioral changes
- Avoid React type noise by casting result from satori-html - Return Uint8Array for BodyInit clarity
- Keep layout responsive without behavior changes
- Use .ngrok-free.app wildcard so fresh tunnels work without edits
- Use square size for sidebar icon button and center content - Ensure share icon has consistent contrast in light/dark modes
…ording; remove legacy share flow and dark styles; disable duplicate copy tooltip; include leafId on copied URL
…niteScroll loader
…ckerfile and package.json
gary149
added a commit
that referenced
this pull request
Aug 29, 2025
UI: remove conversation list skeletons and ensure Escape closes all modals
gary149
added a commit
that referenced
this pull request
Aug 29, 2025
UI: remove conversation list skeletons and ensure Escape closes all modals
gary149
added a commit
that referenced
this pull request
Sep 24, 2025
UI: remove conversation list skeletons and ensure Escape closes all modals
gary149
added a commit
that referenced
this pull request
Sep 24, 2025
UI: remove conversation list skeletons and ensure Escape closes all modals
gary149
added a commit
that referenced
this pull request
Dec 15, 2025
* refactor: remove tokenizer-related functionality and dependencies - Removed tokenizer dependencies from package.json. - Deleted TokensCounter component and its usages across the application. - Updated model configurations to exclude tokenizer properties. - Refactored model processing logic to support only OpenAI-compatible endpoints. - Adjusted API responses to omit tokenizer information. - Cleaned up related utility functions and imports. * Remove web search functionality and related components - Deleted endpoints for various web search APIs (serpApi, serpStack, serper, webLocal, youApi). - Removed generateQuery function and its usage in search. - Eliminated web search related types and interfaces from the codebase. - Updated Assistant and Conversation types to remove references to web search and embedding models. - Cleaned up related utility functions and message updates for web search. - Adjusted API routes and components to reflect the removal of web search features. - Updated Vite configuration to exclude web search dependencies. * Remove Assistants feature and related code - Deleted the assistants page and its load function. - Removed assistantId from conversation handling in server routes. - Cleaned up conversation page and server routes to eliminate assistant references. - Removed assistant-related imports and UI components from settings navigation. - Deleted assistant-specific pages for editing, creating, and displaying avatars. - Updated tools pages to reflect changes in imports and types. * refactor: remove AWS endpoint files and update related configurations * feat: enhance API client to include origin handling and add debug routes * refactor: prioritize HF_TOKEN for authentication in OpenAI endpoints and update related configurations * Remove tool management pages and components - Deleted the ToolEdit component and its associated logic for editing tools. - Removed the tool search functionality from the tools page. - Eliminated the tool input component used for handling various input types. - Removed the layout and page files for individual tool views and editing. - Cleaned up the new tool creation page by removing the modal and ToolEdit component. * Refactor codebase to remove tool-related features and improve formatting - Removed all references to tools in metrics, models, and text generation modules. - Updated various interfaces and types to reflect the removal of tool functionalities. - Cleaned up code formatting for better readability and consistency. - Adjusted API responses and request handling to align with the new structure. - Ensured all related tests and specifications are updated accordingly. * refactor: update README to reflect removal of web search and embedding features, and clarify model configuration * chore: remove search chat feature (UI and /conversations/search API) * Merge pull request #3 from gary149/remove-most-of-things-2 Remove most of things * refactor(metrics): remove Prometheus metrics server and usages\n\n- Delete metrics server implementation and all references\n- Drop /metrics endpoint and Prometheus counters\n- Clean Helm templates (ports, ServiceMonitor) and env\n- Remove metrics docs and TOC entry\n- Adjust .env defaults and server hooks * feat(ui): keep New Chat visible, fix toggles, and polish settings UI\n\n- Always show New Chat in desktop and mobile nav\n- Fix Switch component to toggle on click/keyboard\n- Simplify modal animation and allow disableFly for settings\n- Update settings layouts and styles * chore(deps): remove prom-client and update lockfile * chore(dev): allow ngrok host via server.allowedHosts * refactor(metrics): remove monitoring values from Helm chart * types: add ambient types for web search sources and stream outputs - Add and ambient types - Unblocks TS where older code references these without imports * ui(settings): consolidate model actions into card and chip-style links - Group actions into a subtle bordered container - Promote “New chat” as primary action - Convert external links and copy action to consistent chips - Improve wrapping/alignment; adjust modal height and nav behaviors * ui(chat): tidy message actions and send button styles - Remove stale comments and unused disabled classes - Keep send CTA styling consistent across themes * server(conversation): clean up endpoints and message handling - Normalize POST/GET handling and error responses - Simplify retry/continue branches and update storage writes - Keep rate limiting and guest checks; minor typing tweaks - Consistent vote/share handlers * server(models): load models from OPENAI_BASE_URL (OpenAI-compatible) - Prefer `OPENAI_BASE_URL` (or `OPENAI_MODEL_LIST_URL`) to fetch model list - Support optional Authorization via HF_TOKEN/OPENAI_API_KEY - Provide clearer errors when not configured * server(settings): persist settings fields; minor cleanup - Keep ethicsModalAccepted optional; set timestamp when provided - Upsert with createdAt/updatedAt * utils: message updates iterator and smoothing — minor tidy up - Keep parsing and smoothing logic intact - No behavioral changes * server(models-thumbnail): fix image response typing and return type - Avoid React type noise by casting result from satori-html - Return Uint8Array for BodyInit clarity * ui(layout): minor grid/transition tidy and error toast flow - Keep layout responsive without behavior changes * dev: allow dynamic ngrok subdomains in Vite server.allowedHosts - Use .ngrok-free.app wildcard so fresh tunnels work without edits * ui: polish nav icon sizing and share icon contrast - Use square size for sidebar icon button and center content - Ensure share icon has consistent contrast in light/dark modes * ui(share): implement two-step share conversation modal; keep footer wording; remove legacy share flow and dark styles; disable duplicate copy tooltip; include leafId on copied URL * ui(nav): remove skeleton placeholders from conversation list and InfiniteScroll loader * ui(modal): ensure Escape closes all modals by listening on window and backdrop * chore: revert unrelated changes from previous commit; keep only Modal Escape behavior * chore: remove unused dependencies and playwright installation from Dockerfile and package.json * Merge pull request #4 from gary149/ui-update UI: remove conversation list skeletons and ensure Escape closes all modals * build: re-add fs-extra for Vite config * docs: update metadata in README for improved clarity * fix: Vite/Svelte v6/5 compat and Docker build - Replace deprecated Svelte DOM event directives in Switch.svelte (onclick/onkeydown) - Fix Dockerfile chown by creating /home/user/.npm before chown - Use CommonJS export in tailwind.config.cjs to silence ESM warning * feat: default OPENAI_BASE_URL to HF router when unset * chore: remove OPENAI_MODEL_LIST_URL usage and docs\n\n- Drop all references to OPENAI_MODEL_LIST_URL in code and debug endpoints\n- Default to HF router when OPENAI_BASE_URL is unset\n- Update UI copy and .env comments accordingly * revert: default base URL fallback (revert 07c1aa4)\n\nRequire explicit OPENAI_BASE_URL again; remove implicit default to HF router in models loader. * fix: simplify text and improve button styling in ShareConversationModal * fix: update .env configuration for clarity and remove deprecated parameters * fix: update version to 0.20.0 in package.json * refactor: replace HF_TOKEN with OPENAI_API_KEY as the primary authorization token; update documentation and code references to reflect this change * refactor: remove deprecated tools and assistant features across multiple files * feat: add API Base URL display in Application Settings * feat: implement multimodal support with user-configurable overrides and remove deprecated screenshot functionality * feat: enhance reasoning handling by implementing autodetection of <think> blocks and updating rendering logic * feat: sanitize titles by stripping <think> markers across multiple components and endpoints * feat: update multimodal support by replacing CarbonImage with CarbonView and adjusting rendering logic * feat(models): add model-id filter inputs on models page and settings sidebar; use search input type * Merge pull request #5 from gary149/feat/model-id-filter-inputs feat(models): add model-id filtering inputs on models page and settings * Revert "Merge pull request #5 from gary149/feat/model-id-filter-inputs" This reverts commit 5dae369, reversing changes made to a550b4e. * feat(NavMenu): simplify models link display and always show model count * fix(CopyToClipBoardBtn): update icon size for better visibility * fix(layout): replace UserIcon with CarbonSettings for application settings button * Remove deprecated documentation files and sections related to configuration, installation, and features that are no longer supported in the Chat UI project. This includes the removal of files for common issues, embeddings, multimodal models, OpenAI provider configurations, tools, theming, web search, and local installation instructions. Additionally, the main index file has been cleaned up to reflect the current state of the application. * fix(svelte.config): enable dotenv override for local environment configuration * fix(CopyToClipBoardBtn): replace IconCopy with CarbonCopy for consistency fix(ChatWindow): clean up unused code and simplify conditional rendering feat(page): update model link copy button to use CarbonCopy icon * refactor(NavConversationItem): remove unused props and simplify height logic * fix(package-lock): update version from 0.10.0 to 0.20.0 for consistency fix(settings page): adjust button spacing and replace CarbonCode icon with CarbonArrowUpRight * feat(NavConversationItem): adjust height for improved layout consistency fix(OpenReasoningResults): update hover background color for better visibility feat(+page): add search filter for model ID in model list feat(+layout): implement search filter for model ID in settings navigation fix(tailwind.config): add custom gray shades for enhanced design flexibility * Refactor APIClient and Chat components; remove unused types and improve styling - Removed unused `Success` type from APIClient.ts. - Cleaned up whitespace in ChatInput.svelte. - Added MessageAvatar component to ChatMessage.svelte for better avatar handling. - Updated styles in ChatWindow.svelte for improved dark mode support. - Introduced MessageAvatar component with animation in MessageAvatar.svelte. - Enhanced OpenReasoningResults.svelte with better dark mode styling. - Removed unused ImageProcessor and DocumentProcessor type aliases in document.ts. - Eliminated CommonEndpoint interface and unused EndpointGenerator type in endpoints.ts. - Removed duplicate SortKey enum from Assistant.ts and deleted SortKey.ts. - Added custom scrollbar styles in main.css for better UI experience. - Updated huggingchat icon and logo SVGs for improved visuals. * style: enhance dark mode support across components and improve styling consistency * style(ShareConversationModal): enhance dark mode support for text and button elements * Update modal and button styles in settings pages Adjusted spacing and border color classes for buttons in the model settings page for improved visual consistency in dark mode. Reduced the modal height in the settings layout for better fit on large screens. * Add new SVG icons for various providers - Added cerebras.svg for Cerebras provider. - Added cohere.svg for Cohere provider. - Added featherless-ai.svg for Featherless AI provider. - Added fireworks-ai.svg for Fireworks AI provider. - Added groq.svg for Groq provider. - Added hf-inference.svg for Hugging Face Inference provider. - Added hyperbolic.svg for Hyperbolic provider. - Added nebius.svg for Nebius provider. - Added novita.svg for Novita provider. - Added nscale.svg for Nscale provider. - Added sambanova.svg for SambaNova provider. - Added together.svg for Together provider. * feat: add global keyboard shortcut for new chat (Ctrl/Cmd + Shift + O) * style: update active model styling for improved visibility and consistency; remove unused thumbnail images * refactor: remove voting functionality and associated components for cleaner codebase * Refactor chat message and alternatives UI layout Added classNames prop to Alternatives for flexible styling and adjusted layout logic in ChatMessage to improve alignment and visibility of alternatives and edit controls. Commented out unused child message and edit button sections for clarity. * feat: add iconClassNames prop to CopyToClipBoardBtn for customizable icon styling * style: add border to Modal component for improved visual separation * feat(router): add support for router metadata in message handling and updates * feat(ChatMessage): enhance avatar display with router metadata support * feat(router): enhance router metadata handling and update styles for better visibility * Merge branch 'main' into llm-router * Update ChatMessage.svelte * Merge branch 'visible-providers' * feat: add providers support to models and enhance UI for model selection * Improve chat UI focus and image container sizing Added focus outline removal to chat message textarea for better UX. Changed image container class in UploadedFile from 'size-48' to 'h-48' to ensure correct height styling. * style: update ChatMessage component to allow full-width layout for assistant messages * feat: implement theme preference selector and improve theme handling logic * Update chat button styles and icon gradient, add gray-600 Improves the send button styling in ChatWindow.svelte for better dark mode support and dynamic coloring. Updates IconDazzled.svelte to use a consistent gradient id. Adds gray-600 to the Tailwind config for expanded color options. * style: update styling for model count badge and system prompt button * style: update ShareConversationModal layout and improve text formatting * feat: add scrollIntoView functionality for selected model in navigation * Update logo and icons; improve dark mode logo handling Replaces HuggingChat logo and icon assets with new versions across all formats. Updates Svelte components to add 'dark:invert' for Logo in NavMenu and ChatIntroduction for better dark mode support. Adds a style tweak to OpenReasoningResults details element. * chore: remove emoji-in-title feature and sidebar display\n\n- Stop instructing LLM to prefix titles with emoji and remove emoji enforcement/fallback\n- Always strip emojis from sidebar titles for display\n- Remove hideEmojiOnSidebar setting (types, API, server, UI)\n- Keep <think> tag sanitization intact * Merge branch 'chore/remove-emoji-sidebar' into main * Add modal for editing conversation titles Introduces EditConversationModal.svelte for renaming conversations with a modal dialog. Updates NavConversationItem to use the modal instead of prompt, and refactors the editConversationTitle logic in +layout.svelte to remove title sanitization. Also includes minor UI adjustments in ShareConversationModal, ChatMessage, and ChatWindow components. * Update ChatMessage.svelte * Merge branch 'main' into llm-router: keep router metadata and copy button in ChatMessage.svelte * Fix layout and whitespace handling in chat components Added 'whitespace-nowrap' to Alternatives.svelte to prevent text wrapping. Fixed indentation in ChatMessage.svelte for better readability and maintainability. * Remove unused Svelte components and icons Deleted ReportModal, UploadBtn, and several icon components from the components directory. These files are no longer needed and have been removed to clean up the codebase. * Refactor model search filter to be hyphen/space insensitive and update input placeholders * add button * Add HTML preview modal to CodeBlock component Introduces an HtmlPreviewModal component and integrates it into CodeBlock.svelte. The preview button is conditionally shown for code blocks containing a strict HTML5 doctype, allowing users to preview HTML content in a modal with sandboxed iframe. * Update HtmlPreviewModal.svelte * Disable Preview button while assistant message is generating (threaded through ChatMessage -> MarkdownRenderer -> CodeBlock) * Revert "Disable Preview button while assistant message is generating (threaded through ChatMessage -> MarkdownRenderer -> CodeBlock)" This reverts commit 82fb02c. * Refactor icons and update navigation components Replaced inline SVGs in NavMenu and MobileNav with new reusable Svelte icon components (IconBurger, IconSun, IconMoon). Updated IconNew to use a new SVG and adjusted its viewBox. This improves code maintainability and consistency across navigation UI. * Merge pull request #8 from gary149/html-preview HTML preview for code blocks + sandboxed modal * Merge branch 'main' into llm-router * Improve UI consistency and accessibility in components Added autocomplete="off" to EditConversationModal input for better UX. Updated NavMenu and ChatIntroduction for improved layout, selectability, and logo display. Ensured Alternatives button text does not wrap. Changed IconBurger to use currentColor for better theming support. * npm run format * Remove unused imports and legacy code references * Add margin to Logo component in NavMenu and ChatIntroduction * Update MobileNav.svelte * Add reasoning tag handling to OpenAI chat stream * Merge branch 'main' into llm-router * Add Arch-based LLM router integration * Fix router metadata to use actual candidate model * (need a check) * Add router model UI decoration and config overrides Introduces UI decoration for the router model, including a new icon and configurable display name and logo via environment variables. Updates model types, API, and Svelte components to support and display the router indicator. The router model is now sorted to appear first in the model list if present. * Refactor router model to use configurable Omni alias * Refactor model router property and UI improvements * remove ethics modal replace it with a welcome * Add closeOnBackdrop prop to Modal component * Add Omni icon and update router model UI references * Update UI styles for consistency and dark mode support * Improve avatar animation control and clean up UI * revert sticky buttons codeblock * Refactor WelcomeModal to use close prop for better state management * Update thumbnail.png * Add suggested prompts to empty chat window * UI improvements and example prompts in chat window * Update privacy policy and data handling information in PRIVACY.md * Remove compatibility handling for non-standard models and tools integration in endpointOai function * Update example prompts in ChatWindow for clarity and specificity * Refactor title generation to use model from config and adjust temperature setting * Refactor event handling in Svelte components to use function props instead of event dispatchers - Updated InfiniteScroll, LoginModal, Modal, NavConversationItem, NavMenu, OverloadedModal, Pagination, ShareConversationModal, SystemPromptModal, WelcomeModal, and various chat components to replace event dispatching with function props for better clarity and performance. - Changed event handling in chat components (ChatInput, ChatMessage, ChatWindow, etc.) to utilize function props for actions like message submission, retries, and showing alternate messages. - Adjusted routing and state management in layout and page components to align with the new event handling approach. * Add per-model toggle to hide prompt examples Introduces a 'hidePromptExamples' setting to allow users to suppress prompt suggestions for specific models. Updates settings types, server routes, and UI to support this feature, including a switch in model settings and logic to respect the toggle in chat windows. * Refactor conversation and chat UI components Simplifies prop passing in NavMenu, improves layout handling in NavConversationItem, and removes unnecessary conditional rendering for the copy button in ChatMessage for cleaner and more consistent UI behavior. * Update 'Active' badge styling in settings layout * Adjust chat intro heading vertical translation * Update conversation item delete confirmation text and modify model display logic * Improve router model streaming UI and title generation * Update modal text and example prompt * Add SVG preview support to code block and modal Introduces detection for SVG documents in CodeBlock and HtmlPreviewModal components, enabling preview functionality for SVG code snippets. Also updates button styles for improved visual consistency. * Refactor CodeBlock component layout for improved button positioning and styling * Add keyboard shortcut title to New Chat link in NavMenu * Add model link support for HuggingChat in ChatMessage component * Enhance layout styling with gradient background and sticky button for application settings * Update gradient background in settings layout for improved visibility * Refactor StopGeneratingBtn component and update usage in ChatWindow for improved styling and functionality * Swap primary and fallback models for frontend_ui in routes.chat.json for improved model handling * Add follow-up prompts to router examples in ChatWindow for enhanced user interaction * Add text size adjustment to follow-up button icon in ChatWindow for improved visibility * Update StopGeneratingBtn ring color for better visibility and enhance follow-up button styles in ChatWindow for improved user experience * Add learning_tutor route with primary and fallback models for enhanced educational support * Refactor router examples and add structured data route with primary and fallback models for enhanced functionality * Propagate loading state through markdown previews * Disable navigation from HTML previews * Support MODELS-based overrides * Refresh router example copy * Tighten chat footer spacing * Refine welcome message in WelcomeModal for clarity and readability * Refactor chat message handling and improve router example prompt clarity * Update router example prompts for improved clarity and relevance * Enhance message processing by adding reasoning block stripping functionality * Refactor multimodal handling in models and UI components for improved clarity and consistency * Limit toast message lines and reduce error timeout * Remove unused env vars and update router config docs * Conditionally render copy and retry buttons based on message loading state * Add uppercase styling to conversation title in navigation item * Adjust image container height and clean up button rendering logic * Update game prompts for clarity and consistency in router examples * Refactor environment configuration and remove deprecated web search support; update README for clarity on OpenAI compatibility * Refactor code for consistency and readability across multiple files; update privacy policy reference and improve Markdown rendering * Update icons and manifest for improved app compatibility; standardize icon sizes and paths * Remove conditional SVG rendering in Logo component; simplify to a single image element * Add optional description field to models and update display in UI * Add share functionality with share modal and share icon; update MobileNav and ChatWindow components * Update README.md * Remove documentation link from README.md
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Changes
NavMenu.svelteso the conversation list renders directly.InfiniteScroll.svelte.Modal.svelte(maintains backdrop-click close and focus trap).Notes
Motivation