@alaarab/ogrid-react-fluent 2.1.11 → 2.1.12

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.
@@ -426,15 +426,14 @@
426
426
  .ogrid-fluent__DataGridTable-module__tableWidthAnchor {
427
427
  position: relative;
428
428
  width: max-content;
429
- min-width: 100%;
430
- overflow: clip;
429
+ min-width: var(--data-table-min-width, max-content);
431
430
  background: var(--ogrid-bg, #fff);
432
431
  }
433
432
  .ogrid-fluent__DataGridTable-module__tableWrapper {
434
433
  position: relative;
435
434
  flex: 1;
436
435
  min-height: 0;
437
- overflow-x: auto;
436
+ overflow-x: hidden;
438
437
  overflow-y: auto;
439
438
  width: 100%;
440
439
  min-width: 0;
@@ -443,8 +442,8 @@
443
442
  background: var(--ogrid-bg, #fff);
444
443
  will-change: scroll-position;
445
444
  }
446
- .ogrid-fluent__DataGridTable-module__tableWrapper[data-suppress-scroll=true] {
447
- overflow-x: hidden;
445
+ .ogrid-fluent__DataGridTable-module__tableWrapper[data-overflow-x=true] {
446
+ overflow-x: auto;
448
447
  }
449
448
  .ogrid-fluent__DataGridTable-module__tableWrapper[data-empty=true] {
450
449
  overflow-x: hidden;
@@ -453,8 +452,9 @@
453
452
  min-height: 200px;
454
453
  }
455
454
  .ogrid-fluent__DataGridTable-module__dataTable {
456
- width: var(--data-table-width, 100%);
457
- min-width: max-content;
455
+ width: var(--data-table-width, fit-content);
456
+ max-width: 100%;
457
+ min-width: var(--data-table-min-width, max-content);
458
458
  border-collapse: separate;
459
459
  border-spacing: 0;
460
460
  box-sizing: border-box;
package/dist/esm/index.js CHANGED
@@ -625,7 +625,7 @@ function DataGridTableInner(props) {
625
625
  rowHeight,
626
626
  rowNumberOffset,
627
627
  headerRows,
628
- allowOverflowX: _allowOverflowX,
628
+ allowOverflowX,
629
629
  fitToContent,
630
630
  editCallbacks,
631
631
  interactionHandlers,
@@ -765,7 +765,7 @@ function DataGridTableInner(props) {
765
765
  "data-empty": showEmptyInGrid ? "true" : void 0,
766
766
  "data-loading": isLoading && items.length === 0 ? "true" : void 0,
767
767
  "data-column-count": totalColCount,
768
- "data-suppress-scroll": o.suppressHorizontalScroll ? "true" : void 0,
768
+ "data-overflow-x": allowOverflowX ? "true" : "false",
769
769
  "data-container-width": containerWidth,
770
770
  "data-min-table-width": Math.round(minTableWidth),
771
771
  "data-has-selection": rowSelection !== "none" ? "true" : void 0,
@@ -773,7 +773,9 @@ function DataGridTableInner(props) {
773
773
  onKeyDown: handleGridKeyDown,
774
774
  style: {
775
775
  ["--data-table-column-count"]: totalColCount,
776
- ["--data-table-width"]: showEmptyInGrid ? "100%" : fitToContent ? "fit-content" : "100%",
776
+ ["--data-table-width"]: showEmptyInGrid ? "100%" : allowOverflowX ? "fit-content" : fitToContent ? "fit-content" : "100%",
777
+ ["--data-table-min-width"]: showEmptyInGrid ? "100%" : allowOverflowX ? "max-content" : fitToContent ? "max-content" : "100%",
778
+ ["--data-table-total-min-width"]: `${minTableWidth}px`,
777
779
  ...rowHeight ? { ["--ogrid-row-height"]: `${rowHeight}px` } : {}
778
780
  },
779
781
  children: [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alaarab/ogrid-react-fluent",
3
- "version": "2.1.11",
3
+ "version": "2.1.12",
4
4
  "description": "OGrid React Fluent implementation – DataGrid-powered data table with sorting, filtering, pagination, column chooser, and CSV export.",
5
5
  "main": "dist/esm/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -41,7 +41,7 @@
41
41
  "node": ">=18"
42
42
  },
43
43
  "dependencies": {
44
- "@alaarab/ogrid-react": "2.1.11"
44
+ "@alaarab/ogrid-react": "2.1.12"
45
45
  },
46
46
  "peerDependencies": {
47
47
  "@fluentui/react-components": "^9.0.0",