Skip to content

feat: multiple UI improvements and fixes#198

Merged
xinquiry merged 8 commits intotestfrom
fix/recent-topic-switch
Jan 22, 2026
Merged

feat: multiple UI improvements and fixes#198
xinquiry merged 8 commits intotestfrom
fix/recent-topic-switch

Conversation

@xinquiry
Copy link
Collaborator

@xinquiry xinquiry commented Jan 22, 2026

Summary

  • Fix agent click to restore previous active topic instead of jumping to latest
  • Add context menu (edit/delete) to FocusedView agent switcher
  • Add download button to image lightbox
  • Allow multiple images for generate_image tool
  • Allow user to directly edit MCP in chat toolbar
  • Improve frontend performance

Changes

  • Backend: Sessions API, image tool multi-image support, tool cost adjustments
  • Frontend:
    • Agent context menu with portal rendering
    • FocusedView edit/delete modals
    • Image lightbox download button
    • MCP tools button improvements
    • Chat state management for active topic per agent

Test plan

  • Click agent → switch to another agent → click back → should stay on previous topic
  • Right-click agent in FocusedView → Edit/Delete menu should appear
  • Open image in lightbox → Download button should work
  • Generate multiple images with generate_image tool
  • Edit MCP settings from chat toolbar

🤖 Generated with Claude Code

xinquiry and others added 7 commits January 22, 2026 21:31
Instead of always jumping to the latest topic, now tracks and restores
the previously active topic for each agent when switching between them.

Co-Authored-By: Claude <noreply@anthropic.com>
…ightbox

- Add right-click context menu (edit/delete) to compact AgentListItem variant
- Render context menu via portal to escape overflow:hidden containers
- Add edit/delete handlers to FocusedView with AgentSettingsModal and ConfirmationModal
- Add download button to image lightbox with smart filename detection

Co-Authored-By: Claude <noreply@anthropic.com>
Copy link
Contributor

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry @xinquiry, you have reached your weekly rate limit of 500000 diff characters.

Please try again later or upgrade to continue using Sourcery

- Add web_fetch tool using Trafilatura for content extraction
- Bundle web_fetch with web_search in frontend toolConfig
- Group WEB_SEARCH_TOOLS for unified toggle behavior
- Only load web_fetch when web_search is available (SearXNG enabled)
- Update tool capabilities mapping for web_fetch

Co-Authored-By: Claude <noreply@anthropic.com>
@xinquiry xinquiry merged commit 1c1fb7f into test Jan 22, 2026
1 check passed
@xinquiry xinquiry deleted the fix/recent-topic-switch branch January 22, 2026 16:31
Mile-Away added a commit that referenced this pull request Jan 22, 2026
* Feature/literature mcp (#192)

* feat: literature-MCP 完整功能

* refactor: improve boolean parsing and logging in literature search functions

* feat: enhance literature search functionality with improved query validation and detailed results formatting

* refactor: rename oa_url to access_url in LiteratureWork model and related tests

* feat: remove test-build workflow and update README for development setup

* feat: tool cost system and PPTX image handling fixes (#193)

* fix: prompt, factory

* feat: enhanced ppt generation with image slides mode

- Add image_slides mode for PPTX with full-bleed AI-generated images
- Add ImageBlock.image_id field for referencing generated images
- Add ImageSlideSpec for image-only slides
- Add ImageFetcher service for fetching images from various sources
- Reorganize knowledge module from single file to module structure
- Move document utilities from app/mcp/ to app/tools/utils/documents/
- Resolve image_ids to storage URLs in async layer (operations.py)
- Fix type errors and move tests to proper location

Co-Authored-By: Claude <noreply@anthropic.com>

* feat: implement the tool cost

---------

Co-authored-by: Claude <noreply@anthropic.com>

* fix: fix the first time calling knowledge tool error (#194)

* fix: fix the wrong cache for second call of agent tools (#195)

* feat: several improvements (#196)

* fix: jump to latest topic when click agent

* feat: allow more than one image for generate image

* feat: allow user directly edit mcp in the chat-toolbar

* feat: improve the frontend perf

* feat: multiple UI improvements and fixes (#198)

* fix: jump to latest topic when click agent

* feat: allow more than one image for generate image

* feat: allow user directly edit mcp in the chat-toolbar

* feat: improve the frontend perf

* fix: restore previous active topic when clicking agent

Instead of always jumping to the latest topic, now tracks and restores
the previously active topic for each agent when switching between them.

Co-Authored-By: Claude <noreply@anthropic.com>

* feat: add context menu to FocusedView agents and download button to lightbox

- Add right-click context menu (edit/delete) to compact AgentListItem variant
- Render context menu via portal to escape overflow:hidden containers
- Add edit/delete handlers to FocusedView with AgentSettingsModal and ConfirmationModal
- Add download button to image lightbox with smart filename detection

Co-Authored-By: Claude <noreply@anthropic.com>

* feat: add web_fetch tool bundled with web_search

- Add web_fetch tool using Trafilatura for content extraction
- Bundle web_fetch with web_search in frontend toolConfig
- Group WEB_SEARCH_TOOLS for unified toggle behavior
- Only load web_fetch when web_search is available (SearXNG enabled)
- Update tool capabilities mapping for web_fetch

Co-Authored-By: Claude <noreply@anthropic.com>

---------

Co-authored-by: Claude <noreply@anthropic.com>

---------

Co-authored-by: Meng Junxing <junxingmeng@gmail.com>
Co-authored-by: Harvey <q-query@outlook.com>
Co-authored-by: Claude <noreply@anthropic.com>
Mile-Away added a commit that referenced this pull request Jan 25, 2026
* Feature/literature mcp (#192)

* feat: literature-MCP 完整功能

* refactor: improve boolean parsing and logging in literature search functions

* feat: enhance literature search functionality with improved query validation and detailed results formatting

* refactor: rename oa_url to access_url in LiteratureWork model and related tests

* feat: remove test-build workflow and update README for development setup

* feat: tool cost system and PPTX image handling fixes (#193)

* fix: prompt, factory

* feat: enhanced ppt generation with image slides mode

- Add image_slides mode for PPTX with full-bleed AI-generated images
- Add ImageBlock.image_id field for referencing generated images
- Add ImageSlideSpec for image-only slides
- Add ImageFetcher service for fetching images from various sources
- Reorganize knowledge module from single file to module structure
- Move document utilities from app/mcp/ to app/tools/utils/documents/
- Resolve image_ids to storage URLs in async layer (operations.py)
- Fix type errors and move tests to proper location

Co-Authored-By: Claude <noreply@anthropic.com>

* feat: implement the tool cost

---------

Co-authored-by: Claude <noreply@anthropic.com>

* fix: fix the first time calling knowledge tool error (#194)

* fix: fix the wrong cache for second call of agent tools (#195)

* feat: several improvements (#196)

* fix: jump to latest topic when click agent

* feat: allow more than one image for generate image

* feat: allow user directly edit mcp in the chat-toolbar

* feat: improve the frontend perf

* feat: multiple UI improvements and fixes (#198)

* fix: jump to latest topic when click agent

* feat: allow more than one image for generate image

* feat: allow user directly edit mcp in the chat-toolbar

* feat: improve the frontend perf

* fix: restore previous active topic when clicking agent

Instead of always jumping to the latest topic, now tracks and restores
the previously active topic for each agent when switching between them.

Co-Authored-By: Claude <noreply@anthropic.com>

* feat: add context menu to FocusedView agents and download button to lightbox

- Add right-click context menu (edit/delete) to compact AgentListItem variant
- Render context menu via portal to escape overflow:hidden containers
- Add edit/delete handlers to FocusedView with AgentSettingsModal and ConfirmationModal
- Add download button to image lightbox with smart filename detection

Co-Authored-By: Claude <noreply@anthropic.com>

* feat: add web_fetch tool bundled with web_search

- Add web_fetch tool using Trafilatura for content extraction
- Bundle web_fetch with web_search in frontend toolConfig
- Group WEB_SEARCH_TOOLS for unified toggle behavior
- Only load web_fetch when web_search is available (SearXNG enabled)
- Update tool capabilities mapping for web_fetch

Co-Authored-By: Claude <noreply@anthropic.com>

---------

Co-authored-by: Claude <noreply@anthropic.com>

* feat: fix the fork issue and implement the locked fork

---------

Co-authored-by: Meng Junxing <junxingmeng@gmail.com>
Co-authored-by: Harvey <q-query@outlook.com>
Co-authored-by: Claude <noreply@anthropic.com>
Mile-Away added a commit that referenced this pull request Jan 26, 2026
* Feature/better agent community (#200)

* Feature/literature mcp (#192)

* feat: literature-MCP 完整功能

* refactor: improve boolean parsing and logging in literature search functions

* feat: enhance literature search functionality with improved query validation and detailed results formatting

* refactor: rename oa_url to access_url in LiteratureWork model and related tests

* feat: remove test-build workflow and update README for development setup

* feat: tool cost system and PPTX image handling fixes (#193)

* fix: prompt, factory

* feat: enhanced ppt generation with image slides mode

- Add image_slides mode for PPTX with full-bleed AI-generated images
- Add ImageBlock.image_id field for referencing generated images
- Add ImageSlideSpec for image-only slides
- Add ImageFetcher service for fetching images from various sources
- Reorganize knowledge module from single file to module structure
- Move document utilities from app/mcp/ to app/tools/utils/documents/
- Resolve image_ids to storage URLs in async layer (operations.py)
- Fix type errors and move tests to proper location

Co-Authored-By: Claude <noreply@anthropic.com>

* feat: implement the tool cost

---------

Co-authored-by: Claude <noreply@anthropic.com>

* fix: fix the first time calling knowledge tool error (#194)

* fix: fix the wrong cache for second call of agent tools (#195)

* feat: several improvements (#196)

* fix: jump to latest topic when click agent

* feat: allow more than one image for generate image

* feat: allow user directly edit mcp in the chat-toolbar

* feat: improve the frontend perf

* feat: multiple UI improvements and fixes (#198)

* fix: jump to latest topic when click agent

* feat: allow more than one image for generate image

* feat: allow user directly edit mcp in the chat-toolbar

* feat: improve the frontend perf

* fix: restore previous active topic when clicking agent

Instead of always jumping to the latest topic, now tracks and restores
the previously active topic for each agent when switching between them.

Co-Authored-By: Claude <noreply@anthropic.com>

* feat: add context menu to FocusedView agents and download button to lightbox

- Add right-click context menu (edit/delete) to compact AgentListItem variant
- Render context menu via portal to escape overflow:hidden containers
- Add edit/delete handlers to FocusedView with AgentSettingsModal and ConfirmationModal
- Add download button to image lightbox with smart filename detection

Co-Authored-By: Claude <noreply@anthropic.com>

* feat: add web_fetch tool bundled with web_search

- Add web_fetch tool using Trafilatura for content extraction
- Bundle web_fetch with web_search in frontend toolConfig
- Group WEB_SEARCH_TOOLS for unified toggle behavior
- Only load web_fetch when web_search is available (SearXNG enabled)
- Update tool capabilities mapping for web_fetch

Co-Authored-By: Claude <noreply@anthropic.com>

---------

Co-authored-by: Claude <noreply@anthropic.com>

* feat: fix the fork issue and implement the locked fork

---------

Co-authored-by: Meng Junxing <junxingmeng@gmail.com>
Co-authored-by: Harvey <q-query@outlook.com>
Co-authored-by: Claude <noreply@anthropic.com>

* fix: prevent forked agents from being republished to marketplace (#201)

* fix: prevent forked agents from being republished to marketplace

Forked agents were able to be republished, which could expose the original
agent's configuration. This fix adds validation at both API and UI levels:

- Backend: Add validation in publish endpoint to reject agents with
  original_source_id set (HTTP 400)
- Frontend: Hide publish button for forked agents in AgentSettingsModal
  and WorkflowEditor
- Types: Add original_source_id and source_version fields to Agent interface

Co-Authored-By: Claude <noreply@anthropic.com>

* refactor: address code review feedback for fork detection

- Extract `isForked` helper variable to avoid duplication
- Use explicit nullish check (`!= null`) to match backend `is not None` semantic
- Replace implicit empty div spacer with dynamic justify-* class in WorkflowEditor

Co-Authored-By: Claude <noreply@anthropic.com>

* feat: add justfile for better command

* feat: improve AGENTS.md and fix backend fix

---------

Co-authored-by: Claude <noreply@anthropic.com>

---------

Co-authored-by: xinquiry(SII) <100398322+xinquiry@users.noreply.github.com>
Co-authored-by: Meng Junxing <junxingmeng@gmail.com>
Co-authored-by: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant