@itwin/itwinui-react 2.12.12 → 2.12.14

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,17 @@
1
1
  # Changelog
2
2
 
3
+ ## 2.12.14
4
+
5
+ ### Patch Changes
6
+
7
+ - [#1643](https://github.com/iTwin/iTwinUI/pull/1643): Fixed an issue where ProgressRadial was not respecting explicit size.
8
+
9
+ ## 2.12.13
10
+
11
+ ### Patch Changes
12
+
13
+ - [#1634](https://github.com/iTwin/iTwinUI/pull/1634): Fix overflow visible items count when item is larger than container.
14
+
3
15
  ## 2.12.12
4
16
 
5
17
  ### Patch Changes
@@ -86,7 +86,9 @@ const useOverflow = (items, disabled = false, orientation = 'horizontal') => {
86
86
  if (availableSize < requiredSize) {
87
87
  const avgItemSize = requiredSize / visibleCount;
88
88
  const visibleItems = Math.floor(availableSize / avgItemSize);
89
- setVisibleCount(visibleItems);
89
+ /* When first item is larger than the container - visibleItems count is 0,
90
+ We can assume that at least some part of the first item is visible and return 1. */
91
+ setVisibleCount(visibleItems > 0 ? visibleItems : 1);
90
92
  }
91
93
  else if (needsFullRerender.current) {
92
94
  const childrenSize = Array.from(containerRef.current.children).reduce((sum, child) => sum + child[`offset${dimension}`], 0);