diff --git a/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/components/DocumentsTableShell.tsx b/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/components/DocumentsTableShell.tsx index c437b6cee..11e862944 100644 --- a/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/components/DocumentsTableShell.tsx +++ b/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/components/DocumentsTableShell.tsx @@ -83,8 +83,14 @@ export function DocumentsTableShell({ const toggleAll = (checked: boolean) => { const next = new Set(selectedIds); - if (checked) sorted.forEach((d) => { next.add(d.id); }); - else sorted.forEach((d) => { next.delete(d.id); }); + if (checked) + sorted.forEach((d) => { + next.add(d.id); + }); + else + sorted.forEach((d) => { + next.delete(d.id); + }); setSelectedIds(next); }; diff --git a/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/components/ProcessingIndicator.tsx b/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/components/ProcessingIndicator.tsx index cf7692a41..4ee966e1e 100644 --- a/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/components/ProcessingIndicator.tsx +++ b/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/components/ProcessingIndicator.tsx @@ -9,9 +9,7 @@ interface ProcessingIndicatorProps { documentProcessorTasksCount: number; } -export function ProcessingIndicator({ - documentProcessorTasksCount -}: ProcessingIndicatorProps) { +export function ProcessingIndicator({ documentProcessorTasksCount }: ProcessingIndicatorProps) { const t = useTranslations("documents"); // Only show when there are document_processor tasks (uploads), not connector_indexing_task (periodic reindexing) diff --git a/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/page.tsx b/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/page.tsx index 457a81a6f..e0b566d3d 100644 --- a/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/page.tsx +++ b/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/page.tsx @@ -136,14 +136,13 @@ export default function DocumentsTable() { // Set up polling for active tasks const { summary } = useLogsSummary(searchSpaceId, 24, { refetchInterval: 5000 }); - + // Filter active tasks to only include document_processor tasks (uploads via "add sources") // Exclude connector_indexing_task tasks (periodic reindexing) - const documentProcessorTasks = summary?.active_tasks.filter( - task => task.source === "document_processor" - ) || []; + const documentProcessorTasks = + summary?.active_tasks.filter((task) => task.source === "document_processor") || []; const documentProcessorTasksCount = documentProcessorTasks.length; - + const activeTasksCount = summary?.active_tasks.length || 0; const prevActiveTasksCount = useRef(activeTasksCount); diff --git a/surfsense_web/app/dashboard/[search_space_id]/editor/[documentId]/page.tsx b/surfsense_web/app/dashboard/[search_space_id]/editor/[documentId]/page.tsx index 1f51d9975..239fdc5c1 100644 --- a/surfsense_web/app/dashboard/[search_space_id]/editor/[documentId]/page.tsx +++ b/surfsense_web/app/dashboard/[search_space_id]/editor/[documentId]/page.tsx @@ -21,7 +21,6 @@ import { } from "@/components/ui/alert-dialog"; import { Button } from "@/components/ui/button"; import { Card, CardContent, CardDescription, CardHeader, CardTitle } from "@/components/ui/card"; -import { Separator } from "@/components/ui/separator"; import { notesApiService } from "@/lib/apis/notes-api.service"; import { authenticatedFetch, getBearerToken, redirectToLogin } from "@/lib/auth-utils"; @@ -130,7 +129,7 @@ export default function EditorPage() { setError(null); setHasUnsavedChanges(false); setLoading(true); - }, [documentId]); + }, []); // Fetch document content - DIRECT CALL TO FASTAPI // Skip fetching if this is a new note @@ -427,30 +426,43 @@ export default function EditorPage() { className="flex flex-col min-h-screen w-full" > {/* Toolbar */} -
-
- +
+
+
-

{displayTitle}

- {hasUnsavedChanges &&

Unsaved changes

} +

{displayTitle}

+ {hasUnsavedChanges && ( +

Unsaved changes

+ )}
- +
- - @@ -459,7 +471,7 @@ export default function EditorPage() { {/* Editor Container */}
-
+
{error && ( Add Sources -

Add your sources to your search space

+

+ Add your sources to your search space +

{/* Tabs */} diff --git a/surfsense_web/app/dashboard/[search_space_id]/team/page.tsx b/surfsense_web/app/dashboard/[search_space_id]/team/page.tsx index 8e48c4c3a..80f477001 100644 --- a/surfsense_web/app/dashboard/[search_space_id]/team/page.tsx +++ b/surfsense_web/app/dashboard/[search_space_id]/team/page.tsx @@ -346,13 +346,17 @@ export default function TeamManagementPage() {
-
-
{/* Summary Cards */} @@ -418,21 +422,30 @@ export default function TeamManagementPage() {
- + Members {members.length} - + Roles {roles.length} - + Invites @@ -637,7 +650,10 @@ function MembersTab({ ) : ( - + {member.role?.name || "No role"} diff --git a/surfsense_web/app/dashboard/page.tsx b/surfsense_web/app/dashboard/page.tsx index 77a74a7e7..e241428d1 100644 --- a/surfsense_web/app/dashboard/page.tsx +++ b/surfsense_web/app/dashboard/page.tsx @@ -295,7 +295,10 @@ const DashboardPage = () => {

{space.name}

{!space.is_owner && ( - + {t("shared")} )} @@ -333,7 +336,9 @@ const DashboardPage = () => {

{t("no_spaces_found")}

-

{t("create_first_space")}

+

+ {t("create_first_space")} +

+ +
+
+ + SurfSense
- - - {open && ( - - {navItems.map((navItem: any, idx: number) => ( - - {navItem.name} - - ))} -
- - - - - - {loadingGithubStars ? ( -
- ) : ( - - {githubStars} - - )} - - -
- - Sign In - -
+ +
+ + + {open && ( + + {navItems.map((navItem: any, idx: number) => ( + + {navItem.name} + + ))} +
+ + + + + + {loadingGithubStars ? ( +
+ ) : ( + + {githubStars} + + )} + + +
+ + Sign In + +
+ )} +
+
); }; diff --git a/surfsense_web/components/json-metadata-viewer.tsx b/surfsense_web/components/json-metadata-viewer.tsx index 338c0273b..982d16786 100644 --- a/surfsense_web/components/json-metadata-viewer.tsx +++ b/surfsense_web/components/json-metadata-viewer.tsx @@ -49,7 +49,9 @@ export function JsonMetadataViewer({ - {title} - Metadata + + {title} - Metadata +
@@ -72,7 +74,9 @@ export function JsonMetadataViewer({ - {title} - Metadata + + {title} - Metadata +
diff --git a/surfsense_web/components/new-chat/document-mention-picker.tsx b/surfsense_web/components/new-chat/document-mention-picker.tsx index f250025c4..2d5d46267 100644 --- a/surfsense_web/components/new-chat/document-mention-picker.tsx +++ b/surfsense_web/components/new-chat/document-mention-picker.tsx @@ -185,7 +185,7 @@ export const DocumentMentionPicker = forwardRef< tabIndex={-1} > {/* Document List - Shows max 3 items on mobile, 5 items on desktop */} -
+
{actualLoading ? (
diff --git a/surfsense_web/components/new-chat/model-selector.tsx b/surfsense_web/components/new-chat/model-selector.tsx index f9ffe267c..1d223a411 100644 --- a/surfsense_web/components/new-chat/model-selector.tsx +++ b/surfsense_web/components/new-chat/model-selector.tsx @@ -192,7 +192,10 @@ export function ModelSelector({ onEdit, onAddNew, className }: ModelSelectorProp <> {getProviderIcon(currentConfig.provider)} {currentConfig.name} - + {currentConfig.model_name.split("/").pop()?.slice(0, 10) || currentConfig.model_name.slice(0, 10)} diff --git a/surfsense_web/components/shared/llm-config-form.tsx b/surfsense_web/components/shared/llm-config-form.tsx index 7d450bfc9..46acb80e6 100644 --- a/surfsense_web/components/shared/llm-config-form.tsx +++ b/surfsense_web/components/shared/llm-config-form.tsx @@ -542,11 +542,21 @@ export function LLMConfigForm({ )} > {onCancel && ( - )} -