diff --git a/surfsense_web/app/dashboard/[search_space_id]/client-layout.tsx b/surfsense_web/app/dashboard/[search_space_id]/client-layout.tsx index 7f36d021a..bbafa9703 100644 --- a/surfsense_web/app/dashboard/[search_space_id]/client-layout.tsx +++ b/surfsense_web/app/dashboard/[search_space_id]/client-layout.tsx @@ -196,10 +196,7 @@ export function DashboardClientLayout({ return ( - } - > + }> {children} diff --git a/surfsense_web/app/dashboard/[search_space_id]/new-chat/[[...chat_id]]/page.tsx b/surfsense_web/app/dashboard/[search_space_id]/new-chat/[[...chat_id]]/page.tsx index 3fee0d0c9..f23851f47 100644 --- a/surfsense_web/app/dashboard/[search_space_id]/new-chat/[[...chat_id]]/page.tsx +++ b/surfsense_web/app/dashboard/[search_space_id]/new-chat/[[...chat_id]]/page.tsx @@ -1060,11 +1060,7 @@ export default function NewChatPage() {
- } + header={} />
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 f00982555..6701342de 100644 --- a/surfsense_web/app/dashboard/[search_space_id]/team/page.tsx +++ b/surfsense_web/app/dashboard/[search_space_id]/team/page.tsx @@ -778,8 +778,7 @@ function RolesTab({ role.name === "Owner" && "text-amber-600", role.name === "Editor" && "text-blue-600", role.name === "Viewer" && "text-gray-600", - !["Owner", "Editor", "Viewer"].includes(role.name) && - "text-primary" + !["Owner", "Editor", "Viewer"].includes(role.name) && "text-primary" )} /> @@ -1488,7 +1487,8 @@ function CreateRoleDialog({

- Use presets to quickly apply Editor (create/read/update) or Viewer (read-only) permissions + Use presets to quickly apply Editor (create/read/update) or Viewer (read-only) + permissions

@@ -1500,9 +1500,7 @@ function CreateRoleDialog({ return (
-
diff --git a/surfsense_web/components/layout/ui/shell/LayoutShell.tsx b/surfsense_web/components/layout/ui/shell/LayoutShell.tsx index 0225b94f9..b68719cde 100644 --- a/surfsense_web/components/layout/ui/shell/LayoutShell.tsx +++ b/surfsense_web/components/layout/ui/shell/LayoutShell.tsx @@ -169,9 +169,7 @@ export function LayoutShell({ />
-
+
{children} diff --git a/surfsense_web/components/layout/ui/sidebar/SidebarUserProfile.tsx b/surfsense_web/components/layout/ui/sidebar/SidebarUserProfile.tsx index 678d4d447..907fd89f8 100644 --- a/surfsense_web/components/layout/ui/sidebar/SidebarUserProfile.tsx +++ b/surfsense_web/components/layout/ui/sidebar/SidebarUserProfile.tsx @@ -331,27 +331,27 @@ export function SidebarUserProfile({ {t("language")} - - - {LANGUAGES.map((language) => { - const isSelected = locale === language.code; - return ( - handleLanguageChange(language.code)} - className={cn( - "mb-1 last:mb-0 transition-all", - "hover:bg-accent/50", - isSelected && "bg-accent/80" - )} - > - {language.flag} - {language.name} - - ); - })} - - + + + {LANGUAGES.map((language) => { + const isSelected = locale === language.code; + return ( + handleLanguageChange(language.code)} + className={cn( + "mb-1 last:mb-0 transition-all", + "hover:bg-accent/50", + isSelected && "bg-accent/80" + )} + > + {language.flag} + {language.name} + + ); + })} + + diff --git a/surfsense_web/components/new-chat/model-selector.tsx b/surfsense_web/components/new-chat/model-selector.tsx index dfe28d570..fba5e8cb1 100644 --- a/surfsense_web/components/new-chat/model-selector.tsx +++ b/surfsense_web/components/new-chat/model-selector.tsx @@ -174,10 +174,7 @@ export function ModelSelector({ onEdit, onAddNew, className }: ModelSelectorProp size="sm" role="combobox" aria-expanded={open} - className={cn( - "h-8 gap-2 px-3 text-sm border-border/60", - className - )} + className={cn("h-8 gap-2 px-3 text-sm border-border/60", className)} > {isLoading ? ( <> @@ -187,11 +184,10 @@ export function ModelSelector({ onEdit, onAddNew, className }: ModelSelectorProp ) : currentConfig ? ( <> {getProviderIcon(currentConfig.provider)} - {currentConfig.name} - + + {currentConfig.name} + + {currentConfig.model_name.split("/").pop()?.slice(0, 10) || currentConfig.model_name.slice(0, 10)} @@ -202,10 +198,12 @@ export function ModelSelector({ onEdit, onAddNew, className }: ModelSelectorProp Select Model )} - + diff --git a/surfsense_web/components/notifications/NotificationButton.tsx b/surfsense_web/components/notifications/NotificationButton.tsx index 62521774b..020fea506 100644 --- a/surfsense_web/components/notifications/NotificationButton.tsx +++ b/surfsense_web/components/notifications/NotificationButton.tsx @@ -28,7 +28,10 @@ export function NotificationButton() { const stored = localStorage.getItem(NOTIFICATION_FILTER_STORAGE_KEY); if (stored) { const parsed = JSON.parse(stored); - if (parsed === null || ["new_mention", "connector_indexing", "document_processing"].includes(parsed)) { + if ( + parsed === null || + ["new_mention", "connector_indexing", "document_processing"].includes(parsed) + ) { setActiveFilter(parsed); } } diff --git a/surfsense_web/components/notifications/NotificationPopup.tsx b/surfsense_web/components/notifications/NotificationPopup.tsx index fd16602ae..fbb756a00 100644 --- a/surfsense_web/components/notifications/NotificationPopup.tsx +++ b/surfsense_web/components/notifications/NotificationPopup.tsx @@ -1,7 +1,16 @@ "use client"; import { formatDistanceToNow } from "date-fns"; -import { AlertCircle, AtSign, Bell, Cable, CheckCheck, CheckCircle2, FileText, Loader2 } from "lucide-react"; +import { + AlertCircle, + AtSign, + Bell, + Cable, + CheckCheck, + CheckCircle2, + FileText, + Loader2, +} from "lucide-react"; import { useRouter } from "next/navigation"; import { convertRenderedToDisplay } from "@/components/chat-comments/comment-item/comment-item"; import { Avatar, AvatarFallback, AvatarImage } from "@/components/ui/avatar"; @@ -152,28 +161,31 @@ export function NotificationPopup({ {/* Filter Pills */}
- {(Object.entries(NOTIFICATION_FILTERS) as [NotificationTypeEnum, typeof NOTIFICATION_FILTERS[keyof typeof NOTIFICATION_FILTERS]][]).map( - ([key, { label, icon: Icon }]) => { - const isActive = activeFilter === key; - return ( - - ); - } - )} + {( + Object.entries(NOTIFICATION_FILTERS) as [ + NotificationTypeEnum, + (typeof NOTIFICATION_FILTERS)[keyof typeof NOTIFICATION_FILTERS], + ][] + ).map(([key, { label, icon: Icon }]) => { + const isActive = activeFilter === key; + return ( + + ); + })}
{/* Notifications List */} diff --git a/surfsense_web/hooks/use-notifications.ts b/surfsense_web/hooks/use-notifications.ts index 09eb4e078..eca00a935 100644 --- a/surfsense_web/hooks/use-notifications.ts +++ b/surfsense_web/hooks/use-notifications.ts @@ -132,7 +132,12 @@ export function useNotifications( } try { - console.log("[useNotifications] Updating query for searchSpace:", searchSpaceId, "typeFilter:", typeFilter); + console.log( + "[useNotifications] Updating query for searchSpace:", + searchSpaceId, + "typeFilter:", + typeFilter + ); // Build query with optional type filter const baseQuery = `SELECT * FROM notifications @@ -221,7 +226,10 @@ export function useNotifications( AND read = false`; // Fetch initial count - const result = await electricClient.db.query<{ count: number }>(countQuery, [userId, searchSpaceId]); + const result = await electricClient.db.query<{ count: number }>(countQuery, [ + userId, + searchSpaceId, + ]); if (mounted && result.rows?.[0]) { setTotalUnreadCount(Number(result.rows[0].count) || 0);