Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
chore(tables): address review nits on row selection refactor
- guard selectedRowCount 'all' branch on contextRow membership in rows
- restore blank line between row-selection helpers and constants
  • Loading branch information
waleedlatif1 committed May 6, 2026
commit 0f986cf65f569c11b3a115fdb0ab217ae775b17f
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ function rowSelectionCoversAll(sel: RowSelection, rows: TableRowType[]): boolean
for (const r of rows) if (!sel.ids.has(r.id)) return false
return true
}

const COL_WIDTH_MIN = 80
Comment thread
waleedlatif1 marked this conversation as resolved.
const COL_WIDTH_AUTO_FIT_MAX = 1000
// Wide enough to host the row-number + per-row run button side by side.
Expand Down Expand Up @@ -2448,7 +2449,9 @@ export function Table({
const contextRow = contextMenu.isOpen ? contextMenu.row : null
Comment thread
waleedlatif1 marked this conversation as resolved.
if (!contextRow) return 1

if (rowSelection.kind === 'all') return Math.max(rows.length, 1)
if (rowSelection.kind === 'all') {
return rows.some((r) => r.id === contextRow.id) ? Math.max(rows.length, 1) : 1
}

if (rowSelection.kind === 'some' && rowSelection.ids.has(contextRow.id)) {
let count = 0
Expand Down
Loading