Problem
Applications using @netscript/fresh-ui need a reusable data-grid/list pattern for managing collections. eis-chat now has the same requirement on both Knowledge Base assets and channel sessions, but its local DataGrid only supports a single selected row plus onSelect/href.
Requested API / behavior
- controlled multi-selection (
selectedIds, select row, select all, indeterminate header)
- accessible keyboard and screen-reader semantics for checkboxes and rows
- bulk-action toolbar slot with selection count
- per-row actions slot/menu (for example Rename, Archive, Delete, Reprocess)
- destructive action styling and disabled/loading states
- event isolation so checkbox/menu clicks do not trigger row navigation
- responsive behavior for narrow layouts
- typed generic row/column API compatible with Fresh/Preact
Concrete consumers
- KB documents: bulk Delete/Reprocess, rename, labels, OCR provenance.
- Channel sessions: bulk Archive/Delete and per-row Rename/Archive/Delete menu.
Acceptance criteria
A consumer should not need to hand-roll selection state, select-all logic, keyboard behavior, menu event propagation, and bulk-toolbar layout for every grid. Include a reference example and tests for selection + row actions.
Current workaround
eis-chat/apps/dashboard/components/blocks/data-grid.tsx is being extended locally to unblock product work; it should migrate to the shared Fresh UI primitive once available.
Problem
Applications using
@netscript/fresh-uineed a reusable data-grid/list pattern for managing collections. eis-chat now has the same requirement on both Knowledge Base assets and channel sessions, but its localDataGridonly supports a singleselectedrow plusonSelect/href.Requested API / behavior
selectedIds, select row, select all, indeterminate header)Concrete consumers
Acceptance criteria
A consumer should not need to hand-roll selection state, select-all logic, keyboard behavior, menu event propagation, and bulk-toolbar layout for every grid. Include a reference example and tests for selection + row actions.
Current workaround
eis-chat/apps/dashboard/components/blocks/data-grid.tsxis being extended locally to unblock product work; it should migrate to the shared Fresh UI primitive once available.