@adaptabletools/adaptable 18.0.0-canary.24 → 18.0.0-canary.25

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",
3
- "version": "18.0.0-canary.24",
3
+ "version": "18.0.0-canary.25",
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",
@@ -29,6 +29,7 @@ export const LayoutWizard = (props) => {
29
29
  preparedLayout = cloneObject(initialLayout);
30
30
  if (((_a = props === null || props === void 0 ? void 0 : props.popupParams) === null || _a === void 0 ? void 0 : _a.action) === 'Clone') {
31
31
  preparedLayout.Name = '';
32
+ delete preparedLayout.Uuid;
32
33
  }
33
34
  }
34
35
  else {
@@ -368,6 +368,16 @@ export class AdaptableAgGrid {
368
368
  this.temporaryAdaptableStateUpdates();
369
369
  this.redrawBody();
370
370
  this.refreshHeader();
371
+ const currentLayout = this.api.layoutApi.getCurrentLayout();
372
+ if (currentLayout.EnablePivot) {
373
+ // this is very very strange!
374
+ // for some projects, if the initial layout is pivot, the columnDefs of the pivot resutl columns are NOT derived correctly from the main colDefs
375
+ // doing the following line fixes the issue because it foces the pivot columns to be created again
376
+ // this proj works without the hack: /tests/pages/format-column/initial-pivot-layout.page.tsx
377
+ // but this proj needs the hack: /tests/pages/format-column/initial-pivot-layout-docs.page.tsx
378
+ this.agGridAdapter.setGridOption('pivotMode', false);
379
+ this.agGridAdapter.setGridOption('pivotMode', true);
380
+ }
371
381
  // create the module menu (for use in the dashboard and the toolpanel)
372
382
  // TODO see #create-create-module-menu - make sure it's the same here and there
373
383
  this.ModuleService.createModuleMenus();
@@ -985,7 +995,9 @@ export class AdaptableAgGrid {
985
995
  // framework wrapper may pass the rowData as a prop
986
996
  const rowData = agGridApi.getGridOption('rowData');
987
997
  this.initWithLazyData = rowData == undefined || rowData.length === 0;
988
- this.logger.info('initWithLazyData = TRUE');
998
+ if (this.initWithLazyData) {
999
+ this.logger.info('initWithLazyData = TRUE');
1000
+ }
989
1001
  if (!this.getAgGridContainerElement()) {
990
1002
  // initialize the agGridContainerElement from the AgGrid instance
991
1003
  // @ts-ignore
@@ -1371,17 +1383,17 @@ export class AdaptableAgGrid {
1371
1383
  // ADD filter event
1372
1384
  this.agGridAdapter.getAgGridApi().addGlobalListener((this.listenerGlobalColumnEventsThatTriggerAutoLayoutSave = (type) => {
1373
1385
  if (columnEventsThatTriggersAutoLayoutSave.indexOf(type) > -1) {
1374
- this.logger.info('Column Event Triggering Auto Layout Save', type);
1375
- this.debouncedSaveGridLayout();
1386
+ this.debouncedSaveGridLayout(type);
1376
1387
  }
1377
1388
  }));
1378
1389
  /**
1379
1390
  * Save Layout if Display Row Groups is "dynamic
1380
1391
  */
1381
- this.debouncedSaveGridLayout = debounce(() => {
1392
+ this.debouncedSaveGridLayout = debounce((type) => {
1382
1393
  if (!this.isReady) {
1383
1394
  return;
1384
1395
  }
1396
+ this.logger.info('Event Triggering Auto Layout Save', type || '');
1385
1397
  this.updateLayoutFromGrid();
1386
1398
  }, HALF_SECOND);
1387
1399
  const rowGroupEventsThatTriggersAutoLayoutSave = [
@@ -1391,7 +1403,7 @@ export class AdaptableAgGrid {
1391
1403
  this.agGridAdapter.getAgGridApi().addGlobalListener((this.listenerGlobalRowGroupEventsThatTriggerAutoLayoutSave = (type) => {
1392
1404
  if (rowGroupEventsThatTriggersAutoLayoutSave.indexOf(type) > -1) {
1393
1405
  if (this.adaptableOptions.layoutOptions.displayRowGroups == 'dynamic') {
1394
- this.debouncedSaveGridLayout();
1406
+ this.debouncedSaveGridLayout(type);
1395
1407
  }
1396
1408
  }
1397
1409
  }));
@@ -1415,7 +1427,7 @@ export class AdaptableAgGrid {
1415
1427
  */
1416
1428
  this.agGridAdapter.getAgGridApi().addEventListener(Events.EVENT_COLUMN_RESIZED, (this.listenerColumnResized = (params) => {
1417
1429
  if (params.finished == true && params.type == 'columnResized' && params.column) {
1418
- this.debouncedSaveGridLayout();
1430
+ this.debouncedSaveGridLayout(params.type);
1419
1431
  }
1420
1432
  }));
1421
1433
  /**
package/src/env.js CHANGED
@@ -1,5 +1,5 @@
1
1
  export default {
2
2
  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" || '',
3
- PUBLISH_TIMESTAMP: 1712325818168 || Date.now(),
4
- VERSION: "18.0.0-canary.24" || '--current-version--',
3
+ PUBLISH_TIMESTAMP: 1712327531646 || Date.now(),
4
+ VERSION: "18.0.0-canary.25" || '--current-version--',
5
5
  };