@itwin/itwinui-react 2.4.2 → 2.4.3

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # Changelog
2
2
 
3
+ ## 2.4.3
4
+
5
+ ### Patch Changes
6
+
7
+ - a987bc92: Fixed issue with `Table` autoscroll not completely showing a given row.
8
+
3
9
  ## 2.4.2
4
10
 
5
11
  ### Patch Changes
@@ -263,6 +263,10 @@ const useVirtualization = (props) => {
263
263
  indexDiff * childHeight.current.middle
264
264
  : scrollToIndex * childHeight.current.middle,
265
265
  });
266
+ // update visible index
267
+ const start = getNumberOfNodesInHeight(childHeight.current.middle, Math.round(scrollableContainer.scrollTop));
268
+ const visibleNodes = getVisibleNodeCount(childHeight.current.middle, start, itemsLength, scrollableContainer);
269
+ visibleIndex.current = { start: start, end: start + visibleNodes };
266
270
  }
267
271
  // if `scrollToIndex` is the first visible node
268
272
  // ensure it is fully visible
@@ -234,6 +234,10 @@ export const useVirtualization = (props) => {
234
234
  indexDiff * childHeight.current.middle
235
235
  : scrollToIndex * childHeight.current.middle,
236
236
  });
237
+ // update visible index
238
+ const start = getNumberOfNodesInHeight(childHeight.current.middle, Math.round(scrollableContainer.scrollTop));
239
+ const visibleNodes = getVisibleNodeCount(childHeight.current.middle, start, itemsLength, scrollableContainer);
240
+ visibleIndex.current = { start: start, end: start + visibleNodes };
237
241
  }
238
242
  // if `scrollToIndex` is the first visible node
239
243
  // ensure it is fully visible
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@itwin/itwinui-react",
3
- "version": "2.4.2",
3
+ "version": "2.4.3",
4
4
  "author": "Bentley Systems",
5
5
  "license": "MIT",
6
6
  "main": "cjs/index.js",