diff --git a/.changeset/memory-insights-todo-ui-cleanup.md b/.changeset/memory-insights-todo-ui-cleanup.md new file mode 100644 index 0000000000..5da4f9dd22 --- /dev/null +++ b/.changeset/memory-insights-todo-ui-cleanup.md @@ -0,0 +1,7 @@ +--- +"@runfusion/fusion": patch +--- + +summary: Fix Memory insights parsing and modernize the Memory, Insights, Todos, and agent Memory views. +category: fix +dev: parseInsightsContent filtered bullets after stripping their prefix, collapsing every category into one blob; useMemoryData drops the dead GET /memory and /memory/stats mount fetches and no longer refetches the file list on selection; Engines tab is a 2-column card grid; Todo items are single-row with a quiet inline action cluster; the agent Memory tab uses the shared FileEditor with per-section save actions and fixes the agents.memoryFileMeta {{date}} interpolation. diff --git a/docs/assets/memory-ui-review-2026-07/after-agent-memory-mid.jpg b/docs/assets/memory-ui-review-2026-07/after-agent-memory-mid.jpg new file mode 100644 index 0000000000..72ca71d945 Binary files /dev/null and b/docs/assets/memory-ui-review-2026-07/after-agent-memory-mid.jpg differ diff --git a/docs/assets/memory-ui-review-2026-07/after-agent-memory2.jpg b/docs/assets/memory-ui-review-2026-07/after-agent-memory2.jpg new file mode 100644 index 0000000000..7d9533cb03 Binary files /dev/null and b/docs/assets/memory-ui-review-2026-07/after-agent-memory2.jpg differ diff --git a/docs/assets/memory-ui-review-2026-07/after-insights.jpg b/docs/assets/memory-ui-review-2026-07/after-insights.jpg new file mode 100644 index 0000000000..92dbf27596 Binary files /dev/null and b/docs/assets/memory-ui-review-2026-07/after-insights.jpg differ diff --git a/docs/assets/memory-ui-review-2026-07/after-memory-engines.jpg b/docs/assets/memory-ui-review-2026-07/after-memory-engines.jpg new file mode 100644 index 0000000000..44d72e4fe9 Binary files /dev/null and b/docs/assets/memory-ui-review-2026-07/after-memory-engines.jpg differ diff --git a/docs/assets/memory-ui-review-2026-07/after-memory-insights.jpg b/docs/assets/memory-ui-review-2026-07/after-memory-insights.jpg new file mode 100644 index 0000000000..027c91bd92 Binary files /dev/null and b/docs/assets/memory-ui-review-2026-07/after-memory-insights.jpg differ diff --git a/docs/assets/memory-ui-review-2026-07/after-todos.jpg b/docs/assets/memory-ui-review-2026-07/after-todos.jpg new file mode 100644 index 0000000000..febe7aeaf5 Binary files /dev/null and b/docs/assets/memory-ui-review-2026-07/after-todos.jpg differ diff --git a/docs/assets/memory-ui-review-2026-07/before-agent-memory.jpg b/docs/assets/memory-ui-review-2026-07/before-agent-memory.jpg new file mode 100644 index 0000000000..e7e2b2363f Binary files /dev/null and b/docs/assets/memory-ui-review-2026-07/before-agent-memory.jpg differ diff --git a/docs/assets/memory-ui-review-2026-07/before-insights.jpg b/docs/assets/memory-ui-review-2026-07/before-insights.jpg new file mode 100644 index 0000000000..06c0a8c9ce Binary files /dev/null and b/docs/assets/memory-ui-review-2026-07/before-insights.jpg differ diff --git a/docs/assets/memory-ui-review-2026-07/before-memory-engines.jpg b/docs/assets/memory-ui-review-2026-07/before-memory-engines.jpg new file mode 100644 index 0000000000..4d59465296 Binary files /dev/null and b/docs/assets/memory-ui-review-2026-07/before-memory-engines.jpg differ diff --git a/docs/assets/memory-ui-review-2026-07/before-memory-insights.jpg b/docs/assets/memory-ui-review-2026-07/before-memory-insights.jpg new file mode 100644 index 0000000000..9a78753ed7 Binary files /dev/null and b/docs/assets/memory-ui-review-2026-07/before-memory-insights.jpg differ diff --git a/docs/assets/memory-ui-review-2026-07/before-todos.jpg b/docs/assets/memory-ui-review-2026-07/before-todos.jpg new file mode 100644 index 0000000000..6766ce347d Binary files /dev/null and b/docs/assets/memory-ui-review-2026-07/before-todos.jpg differ diff --git a/packages/core/src/memory-backend.ts b/packages/core/src/memory-backend.ts index 0895e848c4..739be28012 100644 --- a/packages/core/src/memory-backend.ts +++ b/packages/core/src/memory-backend.ts @@ -1436,7 +1436,7 @@ type MemorySettings = { * Resolve the appropriate memory backend based on settings. * * @param settings - Project settings object - * @returns The memory backend to use, defaulting to file backend + * @returns The memory backend to use, defaulting to DEFAULT_MEMORY_BACKEND (qmd) */ export function resolveMemoryBackend(settings?: MemorySettings): MemoryBackend { const backendType = (settings?.[MEMORY_BACKEND_SETTINGS_KEYS.MEMORY_BACKEND_TYPE] as string) || DEFAULT_MEMORY_BACKEND; @@ -1444,7 +1444,7 @@ export function resolveMemoryBackend(settings?: MemorySettings): MemoryBackend { if (backend) { return backend; } - // Fall back to file backend if unknown type + // Fall back to the default (qmd) backend if the configured type is unknown return backendRegistry.get(DEFAULT_MEMORY_BACKEND)!; } diff --git a/packages/dashboard/app/components/AgentDetailView.css b/packages/dashboard/app/components/AgentDetailView.css index a7c54592c6..289b4a4e97 100644 --- a/packages/dashboard/app/components/AgentDetailView.css +++ b/packages/dashboard/app/components/AgentDetailView.css @@ -2211,3 +2211,29 @@ FNXC:AgentDetailView 2026-06-26-01:00: flex-direction: column; } } + +/* +FNXC:AgentMemory 2026-07-11-00:20: +The agent Memory tab's file editor is the shared FileEditor (CodeMirror). The frame is +bounded like the project Memory view editor — a visible floor so it never collapses, +and a viewport cap so long memory files scroll inside the editor instead of stretching +the tab into endless page scroll. +*/ +.agent-memory-file-editor { + border: 1px solid var(--border); + border-radius: var(--radius-md); + overflow: hidden; + display: flex; + flex-direction: column; + min-height: 320px; + max-height: 55vh; +} + +.agent-memory-file-editor .cm-editor { + height: 100%; + min-height: 0; +} + +.agent-memory-file-editor .cm-scroller { + overflow: auto; +} diff --git a/packages/dashboard/app/components/AgentDetailView.tsx b/packages/dashboard/app/components/AgentDetailView.tsx index 01be25a246..ec43135882 100644 --- a/packages/dashboard/app/components/AgentDetailView.tsx +++ b/packages/dashboard/app/components/AgentDetailView.tsx @@ -30,6 +30,7 @@ import { CustomModelDropdown } from "./CustomModelDropdown"; import { useConfirm } from "../hooks/useConfirm"; import { useModalResizePersist } from "../hooks/useModalResizePersist"; import { AgentAvatar } from "./AgentAvatar"; +import { FileEditor } from "./FileEditor"; import { AgentErrorIndicator } from "./AgentErrorDetailsModal"; import { AgentTaskBadge } from "./AgentTaskBadge"; import { ExperimentalAgentOnboardingModal } from "./ExperimentalAgentOnboardingModal"; @@ -2577,7 +2578,6 @@ function MemoryTab({ const [isSaving, setIsSaving] = useState(false); const [justSaved, setJustSaved] = useState(false); const [showPreview, setShowPreview] = useState(false); - const [showFilePreview, setShowFilePreview] = useState(false); const [memoryFiles, setMemoryFiles] = useState([]); const [memoryFilesLoading, setMemoryFilesLoading] = useState(false); @@ -2652,7 +2652,6 @@ function MemoryTab({ setMemory(agent.memory ?? ""); setJustSaved(false); setShowPreview(false); - setShowFilePreview(false); setFileSwitchHint(""); setSelectedFileJustSaved(false); void loadMemoryFiles(); @@ -2751,12 +2750,18 @@ function MemoryTab({
+ {/* + FNXC:AgentMemory 2026-07-11-00:20: + The inline-memory Edit/Preview toggle needs aria-labels distinct from the shared + FileEditor toolbar below (which also exposes "Edit mode"/"Preview mode"); two + identically-named controls in one tab are ambiguous for assistive tech. + */} {!isReadOnly && ( + {!hasInlineChanges && justSaved && ( + + + {t("agents.memorySaved", "Memory saved")} + + )} +
+ )}
@@ -2845,62 +2878,37 @@ function MemoryTab({
{({ "long-term": t("agents.memoryLayerLongTerm", "Long-term"), daily: t("agents.memoryLayerDaily", "Daily"), dreams: t("agents.memoryLayerDreams", "Dreams") } as Record)[selectedMemoryFile.layer] ?? selectedMemoryFile.layer} · {selectedLayerDescription}
- {t("agents.memoryFileMeta", "{{size}} bytes · Updated {{time}}", { size: selectedMemoryFile.size.toLocaleString(), time: relativeTime(selectedMemoryFile.updatedAt, t) })} + {/* + FNXC:AgentMemory 2026-07-11-00:20: + i18n fix: every locale defines agents.memoryFileMeta with a {{date}} placeholder, but this + call passed the value as {{time}}, so the UI rendered the literal string "updated {{date}}". + The interpolation variable must be named `date` to match the locale files. + */} + {t("agents.memoryFileMeta", "{{size}} bytes · updated {{date}}", { size: selectedMemoryFile.size.toLocaleString(), date: relativeTime(selectedMemoryFile.updatedAt, t) })}
)} -
-
- {!isReadOnly && ( - - )} - -
-
- - {showFilePreview ? ( - selectedFileContent.trim() ? ( -
- - {selectedFileContent} - -
- ) : ( -
- {t("agents.memoryFileEmptyPreview", "No memory file content yet. Switch to Edit mode to add content.")} -
- ) - ) : ( -