Docs
CodeRabbit
Cloudflare
AG Grid
SerpAPI
Netlify
OpenRouter
Neon
WorkOS
Clerk
Electric
PowerSync
Sentry
Railway
Prisma
Strapi
Unkey
CodeRabbit
Cloudflare
AG Grid
SerpAPI
Netlify
OpenRouter
Neon
WorkOS
Clerk
Electric
PowerSync
Sentry
Railway
Prisma
Strapi
Unkey
Table API Reference
Column API Reference
Row API Reference
Cell API Reference
Header API Reference
Features API Reference
Static Functions API Reference
Legacy API Reference

table_getCellSelectionMergeBounds

ts
function table_getCellSelectionMergeBounds<TFeatures, TData>(table): CellSelectionBounds[];
function table_getCellSelectionMergeBounds<TFeatures, TData>(table): CellSelectionBounds[];

Defined in: features/cell-selection/cellSelectionFeature.utils.ts:231

Resolves the merged-cell rectangles of the rendered rows into selection's own index space.

The span index positions rows by their paginated render order while selection positions them by pre-paginated display order, so each merge is mapped through row.getDisplayIndex(). A merge whose rows do not map to a contiguous display range is skipped defensively; it then behaves like unmerged cells instead of corrupting the geometry.

Returns an empty array when cellSpanningFeature is not registered, which keeps every selection code path identical to the span-unaware behavior.

Type Parameters

TFeatures

TFeatures extends TableFeatures

TData

TData extends RowData

Parameters

table

Table_Internal<TFeatures, TData>

Returns

CellSelectionBounds[]

Example

ts
const merges = table_getCellSelectionMergeBounds(table)
const merges = table_getCellSelectionMergeBounds(table)