From 07f49565505516414ad2ad12b0ff4ad016ec8be9 Mon Sep 17 00:00:00 2001 From: Bryan Van Deusen Date: Fri, 3 Apr 2026 00:50:42 -0400 Subject: [PATCH] fix: center minichat widget and fix weather tool success status - KnowledgeView minichat: add margin-inline: auto so the widget centers within the content area when max-width is reached on wide screens - weather get_weather tool: return success: true on both the arbitrary location path and the cached locations path so ToolCallCard shows the correct success state instead of always flagging as error Co-Authored-By: Claude Sonnet 4.6 --- frontend/src/views/KnowledgeView.vue | 1 + src/fabledassistant/services/tools.py | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/frontend/src/views/KnowledgeView.vue b/frontend/src/views/KnowledgeView.vue index ad4c4ad..d3cc220 100644 --- a/frontend/src/views/KnowledgeView.vue +++ b/frontend/src/views/KnowledgeView.vue @@ -1043,6 +1043,7 @@ onUnmounted(() => { left: var(--sidebar-width); /* align with content area past filter panel */ right: 0; max-width: var(--page-max-width); + margin-inline: auto; z-index: 20; display: flex; flex-direction: column; diff --git a/src/fabledassistant/services/tools.py b/src/fabledassistant/services/tools.py index 4e8b297..aa5a78b 100644 --- a/src/fabledassistant/services/tools.py +++ b/src/fabledassistant/services/tools.py @@ -1923,7 +1923,7 @@ async def execute_tool( lat, lon, label = await geocode(location) raw = await _fetch_open_meteo(lat, lon) days = parse_forecast(raw) - return {"data": {"locations": [{ + return {"success": True, "data": {"locations": [{ "location_key": "query", "location_label": label, "fetched_at": datetime.now(_tz.utc).isoformat(), @@ -1936,7 +1936,7 @@ async def execute_tool( locations = await get_cached_weather(user_id) if location.lower() not in ("all", ""): locations = [loc for loc in locations if loc["location_key"] == location.lower()] - return {"data": {"locations": locations}} + return {"success": True, "data": {"locations": locations}} elif tool_name == "get_rss_items": from fabledassistant.services.rss import get_recent_items