@adaptabletools/adaptable-cjs 20.0.0-canary.14 → 20.0.0-canary.16

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adaptabletools/adaptable-cjs",
3
- "version": "20.0.0-canary.14",
3
+ "version": "20.0.0-canary.16",
4
4
  "description": "Powerful data-agnostic HTML5 AG Grid extension which provides advanced, cutting-edge functionality to meet all DataGrid requirements",
5
5
  "keywords": [
6
6
  "web-components",
@@ -525,7 +525,7 @@ class AgGridAdapter {
525
525
  else if (Array.isArray(value)) {
526
526
  const arrayDataType = agGridDataTypeDefinitions_1.ALL_ADAPTABLE_DATA_TYPES.find((arrayType) => {
527
527
  const dataTypeDefinition = agGridDataTypeDefinitions_1.agGridDataTypeDefinitions[arrayType];
528
- const dataTypeMatching = dataTypeDefinition?.dataTypeMatcher(value);
528
+ const dataTypeMatching = dataTypeDefinition?.dataTypeMatcher?.(value);
529
529
  return dataTypeMatching;
530
530
  });
531
531
  if (arrayDataType) {
@@ -99,7 +99,7 @@ const Select = function (props) {
99
99
  };
100
100
  const renderMultipleValues = props.renderMultipleValues;
101
101
  const isMulti = props.isMulti ?? Array.isArray(props.value);
102
- const showHeaderSelectionCheckbox = props.showHeaderSelectionCheckbox ?? false;
102
+ const showHeaderSelectionCheckbox = isMulti && (props.showHeaderSelectionCheckbox ?? false);
103
103
  let selectedOption = null;
104
104
  if (isMulti) {
105
105
  selectedOption =
@@ -339,7 +339,7 @@ const Select = function (props) {
339
339
  zIndex: 999999,
340
340
  boxShadow: 'var(--ab-cmp-select-menu__box-shadow)',
341
341
  minWidth: `var(--ab-cmp-select-menu__min-width)`,
342
- '--ab-cmp-select-menu__min-height': `min(${(props.options || []).length * ROW_HEIGHT}px, 20rem)`,
342
+ '--ab-cmp-select-menu__min-height': `min(${((props.options || []).length + (showHeaderSelectionCheckbox ? 1 : 0)) * ROW_HEIGHT}px, 20rem)`,
343
343
  ...commonStyles(state),
344
344
  ...props.menuStyle,
345
345
  };
package/src/env.js CHANGED
@@ -2,6 +2,6 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.default = {
4
4
  NEXT_PUBLIC_INFINITE_TABLE_LICENSE_KEY: "StartDate=2021-06-29|EndDate=2030-01-01|Owner=Adaptable|Type=distribution|TS=1624971462479|C=137829811,1004007071,2756196225,1839832928,3994409405,636616862" || '',
5
- PUBLISH_TIMESTAMP: 1741793222252 || Date.now(),
6
- VERSION: "20.0.0-canary.14" || '--current-version--',
5
+ PUBLISH_TIMESTAMP: 1741870315145 || Date.now(),
6
+ VERSION: "20.0.0-canary.16" || '--current-version--',
7
7
  };
@@ -5,21 +5,13 @@ const VersionUpgrade_1 = require("./VersionUpgrade");
5
5
  const agGridDataTypeDefinitions_1 = require("../agGrid/agGridDataTypeDefinitions");
6
6
  function transition_pre_20(layout) {
7
7
  const l = layout;
8
- if (l.AggregationColumns && !Array.isArray(l.AggregationColumns)) {
9
- const oldAggs = l.AggregationColumns || {};
10
- const newAggs = Object.entries(oldAggs).map(([colId, aggFunc]) => ({
11
- ColumnId: colId,
12
- AggFunc: aggFunc,
13
- }));
14
- layout.TableAggregationColumns = newAggs;
15
- }
16
8
  if (l.Columns) {
17
9
  layout.TableColumns = l.Columns;
18
10
  delete l.Columns;
19
11
  delete layout.PivotColumns;
20
12
  }
21
13
  if (l.PinnedColumnsMap) {
22
- layout.ColumnPinning = l.PinnedColumnsMap;
14
+ layout.ColumnPinning = { ...l.PinnedColumnsMap };
23
15
  delete l.PinnedColumnsMap;
24
16
  }
25
17
  if (l.ColumnHeadersMap) {
@@ -33,10 +25,40 @@ function transition_pre_20(layout) {
33
25
  if (l.EnablePivot) {
34
26
  layout.PivotColumns = l.PivotColumns || [];
35
27
  delete layout.TableColumns;
28
+ delete l.EnablePivot;
36
29
  if (l.AggregationColumns) {
37
- layout.PivotAggregationColumns = layout.TableAggregationColumns;
30
+ layout.PivotAggregationColumns = (Object.entries(l.AggregationColumns) || []).map(([ColumnId, AggFunc]) => {
31
+ return {
32
+ ColumnId,
33
+ AggFunc,
34
+ };
35
+ });
36
+ delete layout.TableAggregationColumns;
37
+ delete l.AggregationColumns;
38
+ }
39
+ if (l.RowGroupedColumns) {
40
+ layout.PivotGroupedColumns = l.RowGroupedColumns;
41
+ delete l.RowGroupedColumns;
38
42
  }
39
43
  }
44
+ else {
45
+ if (l.AggregationColumns && !Array.isArray(l.AggregationColumns)) {
46
+ const oldAggs = l.AggregationColumns || {};
47
+ const newAggs = Object.entries(oldAggs).map(([ColumnId, AggFunc]) => ({
48
+ ColumnId,
49
+ AggFunc,
50
+ }));
51
+ layout.TableAggregationColumns = newAggs;
52
+ delete l.AggregationColumns;
53
+ }
54
+ }
55
+ if (l.ExpandedRowGroupValues) {
56
+ layout.RowGroupValues = {
57
+ RowGroupDefaultBehavior: 'collapsed',
58
+ ExceptionGroupKeys: l.ExpandedRowGroupValues,
59
+ };
60
+ delete l.ExpandedRowGroupValues;
61
+ }
40
62
  if (Array.isArray(l.ColumnFilters)) {
41
63
  layout.ColumnFilters = l.ColumnFilters.map((columnFilter) => {
42
64
  const filter = {