@trudb/tru-common-lib 0.2.354 → 0.2.355

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.
@@ -8341,8 +8341,14 @@ class TruDataGrid {
8341
8341
  const headerHeight = 25;
8342
8342
  const minRows = this.config.minimumRows ?? 0;
8343
8343
  const maxRows = this.config.maximumRows;
8344
- const minPx = (minRows * rowHeight) + headerHeight;
8345
- const maxPx = typeof maxRows === 'number' ? (maxRows * rowHeight) + headerHeight : undefined;
8344
+ const gridTopOffset = this.label ? 48 : 28;
8345
+ const gridBottomOffset = 23; // status bar height/bottom offset
8346
+ const gridChromePx = gridTopOffset + gridBottomOffset;
8347
+ // Ensure space for either the minimum rows or the overlay box (50px high).
8348
+ const overlayMinPx = 50;
8349
+ const contentMinPx = Math.max((minRows * rowHeight) + headerHeight, overlayMinPx);
8350
+ const minPx = contentMinPx + gridChromePx;
8351
+ const maxPx = typeof maxRows === 'number' ? ((maxRows * rowHeight) + headerHeight + gridChromePx) : undefined;
8346
8352
  let targetHeight = distributedHeight;
8347
8353
  if (!this.config.fill) {
8348
8354
  if (maxPx !== undefined && maxPx < targetHeight)