diff --git a/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/components/DocumentsFilters.tsx b/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/components/DocumentsFilters.tsx index 401655c65..0bbab2a38 100644 --- a/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/components/DocumentsFilters.tsx +++ b/surfsense_web/app/dashboard/[search_space_id]/documents/(manage)/components/DocumentsFilters.tsx @@ -115,7 +115,7 @@ export function DocumentsFilters({ className="peer h-9 w-full pl-9 pr-9 text-sm bg-background border-border/60 focus-visible:ring-1 focus-visible:ring-ring/30 select-none focus:select-text" value={searchValue} onChange={(e) => onSearch(e.target.value)} - placeholder="Filter by title" + placeholder="Search" type="text" aria-label={t("filter_placeholder")} /> 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 9733d9683..bf9e29a1d 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 @@ -410,7 +410,7 @@ export function DocumentsTableShell({ return ( - - + +
- + - + - +
@@ -445,20 +445,20 @@ export function DocumentsTableShell({ {[65, 80, 45, 72, 55, 88, 40, 60, 50, 75].map((widthPercent, index) => ( - +
- + - + - +
@@ -468,9 +468,9 @@ export function DocumentsTableShell({ {/* Mobile Skeleton */} -
+
{[70, 85, 55, 78, 62, 90].map((widthPercent, index) => ( -
+
@@ -521,8 +521,8 @@ export function DocumentsTableShell({
- - + +
- + - + - + Status @@ -579,53 +579,53 @@ export function DocumentsTableShell({ delay: index * 0.02, }, }} - className={`border-b border-border/40 transition-colors ${ - isSelected - ? "bg-primary/5 hover:bg-primary/8" - : "hover:bg-muted/30" - }`} - > - -
- - canSelect && toggleOne(doc.id, !!v) - } - disabled={!canSelect} - aria-label={ - canSelect - ? "Select row" - : "Cannot select while processing" - } - className={`border-foreground data-[state=checked]:bg-primary data-[state=checked]:border-primary ${!canSelect ? "opacity-40 cursor-not-allowed" : ""}`} - /> -
-
- - + +
+ + canSelect && toggleOne(doc.id, !!v) + } + disabled={!canSelect} + aria-label={ + canSelect + ? "Select row" + : "Cannot select while processing" + } + className={`border-foreground data-[state=checked]:bg-primary data-[state=checked]:border-primary ${!canSelect ? "opacity-40 cursor-not-allowed" : ""}`} /> - - - - - - {getDocumentTypeIcon( - doc.document_type, - "h-4 w-4" - )} - - - - {getDocumentTypeLabel(doc.document_type)} - - - - - - +
+
+ + + + + + + + {getDocumentTypeIcon( + doc.document_type, + "h-4 w-4" + )} + + + + {getDocumentTypeLabel(doc.document_type)} + + + + + + ); @@ -636,7 +636,7 @@ export function DocumentsTableShell({ {/* Mobile Card View */} -
+
{sorted.map((doc, index) => { const isSelected = selectedIds.has(doc.id); const canSelect = isSelectable(doc); @@ -651,7 +651,7 @@ export function DocumentsTableShell({ diff --git a/surfsense_web/components/layout/ui/sidebar/DocumentsSidebar.tsx b/surfsense_web/components/layout/ui/sidebar/DocumentsSidebar.tsx index 88a2a9e15..e8029404e 100644 --- a/surfsense_web/components/layout/ui/sidebar/DocumentsSidebar.tsx +++ b/surfsense_web/components/layout/ui/sidebar/DocumentsSidebar.tsx @@ -281,16 +281,18 @@ export function DocumentsSidebar({ open, onOpenChange }: DocumentsSidebarProps)
-
- +
+
+ +
- setPageIndex(0)} - onPrev={() => setPageIndex((i) => Math.max(0, i - 1))} - onNext={() => setPageIndex((i) => (pageEnd < displayTotal ? i + 1 : i))} - onLast={() => setPageIndex(Math.max(0, Math.ceil(displayTotal / PAGE_SIZE) - 1))} - canPrev={pageIndex > 0} - canNext={pageEnd < displayTotal} - /> +
+ setPageIndex(0)} + onPrev={() => setPageIndex((i) => Math.max(0, i - 1))} + onNext={() => setPageIndex((i) => (pageEnd < displayTotal ? i + 1 : i))} + onLast={() => setPageIndex(Math.max(0, Math.ceil(displayTotal / PAGE_SIZE) - 1))} + canPrev={pageIndex > 0} + canNext={pageEnd < displayTotal} + /> +
);