@iress-oss/ids-components 6.0.0-beta.6 → 6.0.0-beta.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -309,6 +309,38 @@ The `compact` prop can be used to reduce the padding around the table cells and
309
309
 
310
310
  [View "Compact" example in Storybook →](https://main--691abcc79dfa560a36d0a74f.chromatic.com/?path=/story/components_components-table--compact)
311
311
 
312
+ ### Virtualisation
313
+
314
+ For tables with large datasets (hundreds or thousands of rows), virtualisation
315
+ renders only the visible rows to the DOM. This eliminates UI freezes during
316
+ bulk state updates and keeps scrolling smooth.
317
+
318
+ Enable it with the `virtualise` prop. The `virtualise` prop accepts `true` for defaults, or an options object:
319
+
320
+ | Option | Type | Default | Description |
321
+ | -------------- | ------------------ | ------- | ------------------------------------------------ |
322
+ | `height` | `number \| string` | `400` | Height of the scroll container (px or CSS value) |
323
+ | `overscan` | `number` | `5` | Extra rows rendered above/below the viewport |
324
+ | `estimateSize` | `number` | `40` | Estimated row height in pixels |
325
+
326
+ **Requirements:**
327
+
328
+ - The table container must have a bounded height (set via `height` option or
329
+ CSS on a parent). Without a fixed height, the browser cannot determine which
330
+ rows are visible.
331
+ - Specify `width` on each column for stable column sizing. Without explicit
332
+ widths, columns may shift as rows with different content lengths scroll in
333
+ and out of view.
334
+ - Sorting and filtering work normally with virtualisation enabled.
335
+ - Screen readers announce the correct row position via `aria-rowcount` and
336
+ `aria-rowindex`.
337
+
338
+ ```tsx
339
+ <TableVirtualised />
340
+ ```
341
+
342
+ [View "Virtualised" example in Storybook →](https://main--691abcc79dfa560a36d0a74f.chromatic.com/?path=/story/components_components-table--virtualised)
343
+
312
344
  ## `IressTableBody`
313
345
 
314
346
  In some cases you may have a table with multiple groups of rows inside it, however the columns are the same. For these cases, you can use the `IressTableBody` component.