@adaptabletools/adaptable 19.2.2-canary.0 → 19.2.2
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": "19.2.2
|
|
3
|
+
"version": "19.2.2",
|
|
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",
|
|
@@ -125,6 +125,7 @@ export declare class AdaptableAgGrid implements IAdaptable {
|
|
|
125
125
|
*/
|
|
126
126
|
private adaptableStatusPanelKeys;
|
|
127
127
|
_PRIVATE_adaptableJSXElement: JSX.Element;
|
|
128
|
+
private DANGER_updateGridOptionsMonkeyPatcher;
|
|
128
129
|
constructor();
|
|
129
130
|
static forEachAdaptable(fn: (adaptable: AdaptableAgGrid) => void): void;
|
|
130
131
|
private static collectInstance;
|
|
@@ -429,12 +429,13 @@ export class AdaptableAgGrid {
|
|
|
429
429
|
this.lifecycleState = 'ready';
|
|
430
430
|
this.forPlugins((plugin) => plugin.onAdaptableReady(this, this.adaptableOptions));
|
|
431
431
|
setTimeout(() => {
|
|
432
|
+
var _a, _b;
|
|
432
433
|
// without the setTimeout, calling autoSizeAllColumns immediately in the onAdaptableReady
|
|
433
434
|
// does not work. (I prefer setTimeout to rAF, as raf is not running when you switch tabs)
|
|
434
435
|
//
|
|
435
436
|
// it also makes it possible to listen to CALCULATED_COLUMN_READY, DASHBOARD_READY, etc.
|
|
436
437
|
// in onAdaptableReady - without this those event listeners are not triggered
|
|
437
|
-
this.api.eventApi.emit('AdaptableReady', {
|
|
438
|
+
(_b = (_a = this.api) === null || _a === void 0 ? void 0 : _a.eventApi) === null || _b === void 0 ? void 0 : _b.emit('AdaptableReady', {
|
|
438
439
|
adaptableApi: this.api,
|
|
439
440
|
agGridApi: this.agGridAdapter.getAgGridApi(),
|
|
440
441
|
});
|
|
@@ -1629,7 +1630,10 @@ export class AdaptableAgGrid {
|
|
|
1629
1630
|
autoSizeLayoutIfNeeded() {
|
|
1630
1631
|
if (this.shouldAutoSizeLayout()) {
|
|
1631
1632
|
requestAnimationFrame(() => {
|
|
1632
|
-
|
|
1633
|
+
var _a;
|
|
1634
|
+
if (this.isAvailable) {
|
|
1635
|
+
(_a = this.agGridAdapter.getAgGridApi()) === null || _a === void 0 ? void 0 : _a.autoSizeAllColumns();
|
|
1636
|
+
}
|
|
1633
1637
|
});
|
|
1634
1638
|
}
|
|
1635
1639
|
}
|
|
@@ -3074,14 +3078,15 @@ export class AdaptableAgGrid {
|
|
|
3074
3078
|
}
|
|
3075
3079
|
}
|
|
3076
3080
|
DANGER_AG_GRID_BEANS_MAP[this._agGridId] = null;
|
|
3081
|
+
this.DANGER_updateGridOptionsMonkeyPatcher = null;
|
|
3077
3082
|
if ((config === null || config === void 0 ? void 0 : config.destroyApi) === true || (config === null || config === void 0 ? void 0 : config.destroyAgGrid) === true) {
|
|
3078
3083
|
(_b = this.agGridAdapter.getAgGridApi()) === null || _b === void 0 ? void 0 : _b.destroy();
|
|
3079
3084
|
}
|
|
3080
3085
|
this.previousAgGridLayoutState = '';
|
|
3081
3086
|
const gridContainerElement = this.getAgGridContainerElement();
|
|
3082
3087
|
if (gridContainerElement) {
|
|
3083
|
-
gridContainerElement.removeEventListener('keydown', this.agGridListenerKeydown);
|
|
3084
|
-
gridContainerElement.removeEventListener('mouseenter', this.agGridListenerMouseEnter);
|
|
3088
|
+
gridContainerElement.removeEventListener('keydown', this.agGridListenerKeydown, true);
|
|
3089
|
+
gridContainerElement.removeEventListener('mouseenter', this.agGridListenerMouseEnter, true);
|
|
3085
3090
|
gridContainerElement.removeEventListener('mouseleave', this.agGridListenerMouseLeave);
|
|
3086
3091
|
this.agGridListenerKeydown = null;
|
|
3087
3092
|
this.agGridListenerMouseEnter = null;
|
|
@@ -3506,7 +3511,9 @@ export class AdaptableAgGrid {
|
|
|
3506
3511
|
if (pivoted && ((_d = (_c = this.adaptableOptions) === null || _c === void 0 ? void 0 : _c.layoutOptions) === null || _d === void 0 ? void 0 : _d.autoSizeColumnsInPivotLayout)) {
|
|
3507
3512
|
// when a pivoted layout loads, autosize all cols
|
|
3508
3513
|
requestAnimationFrame(() => {
|
|
3509
|
-
this.
|
|
3514
|
+
if (this.isAvailable) {
|
|
3515
|
+
this.agGridAdapter.getAgGridApi().autoSizeAllColumns();
|
|
3516
|
+
}
|
|
3510
3517
|
});
|
|
3511
3518
|
// //but if it's also the first time the grid is loading
|
|
3512
3519
|
// //it's not timely enough the above call, so we keep trying... I know it's ugly, we need to find a better way
|
|
@@ -3521,7 +3528,9 @@ export class AdaptableAgGrid {
|
|
|
3521
3528
|
if (((_f = (_e = this.adaptableOptions) === null || _e === void 0 ? void 0 : _e.layoutOptions) === null || _f === void 0 ? void 0 : _f.autoSizeColumnsInLayout) &&
|
|
3522
3529
|
colsToAutoSizeArray.length) {
|
|
3523
3530
|
requestAnimationFrame(() => {
|
|
3524
|
-
this.
|
|
3531
|
+
if (this.isAvailable) {
|
|
3532
|
+
this.autoSizeColumns(colsToAutoSizeArray);
|
|
3533
|
+
}
|
|
3525
3534
|
});
|
|
3526
3535
|
}
|
|
3527
3536
|
}
|
|
@@ -4075,6 +4084,7 @@ export class AdaptableAgGrid {
|
|
|
4075
4084
|
};
|
|
4076
4085
|
});
|
|
4077
4086
|
}
|
|
4087
|
+
// #gridOpts_monkey_patch
|
|
4078
4088
|
// we need to intercept some of the GridOptions updates and refresh the Adaptable state
|
|
4079
4089
|
monkeyPatchingGridOptionsUpdates(agGridApi) {
|
|
4080
4090
|
var _a;
|
|
@@ -4083,7 +4093,7 @@ export class AdaptableAgGrid {
|
|
|
4083
4093
|
this.logger.consoleError('Could not get hold of GridOptionsService! This is a critical error and will prevent Adaptable from working correctly.');
|
|
4084
4094
|
}
|
|
4085
4095
|
const self = this;
|
|
4086
|
-
|
|
4096
|
+
this.DANGER_updateGridOptionsMonkeyPatcher = function ({ options, force, source = 'api', }) {
|
|
4087
4097
|
// `columnDefs`
|
|
4088
4098
|
const passedColumnDefs = options.columnDefs;
|
|
4089
4099
|
if (passedColumnDefs) {
|
|
@@ -4110,6 +4120,7 @@ export class AdaptableAgGrid {
|
|
|
4110
4120
|
// we mutated the options array, so it's OK to use the 'arguments' object
|
|
4111
4121
|
GridOptionsService_updateGridOptions.apply(this, arguments);
|
|
4112
4122
|
};
|
|
4123
|
+
gridOptionsService.updateGridOptions = this.DANGER_updateGridOptionsMonkeyPatcher;
|
|
4113
4124
|
}
|
|
4114
4125
|
DANGER_getPrivateAgGridBeans() {
|
|
4115
4126
|
const beans = DANGER_AG_GRID_BEANS_MAP[this._agGridId];
|
|
@@ -9,6 +9,7 @@ export class AgGridOptionsService {
|
|
|
9
9
|
this.colDefPropertyCache.clear();
|
|
10
10
|
this.gridOptionsPropertyCache = null;
|
|
11
11
|
this.colDefPropertyCache = null;
|
|
12
|
+
this.adaptableInstance = null;
|
|
12
13
|
}
|
|
13
14
|
setGridOptionsProperty(gridOptions, propertyName, propertyGetter) {
|
|
14
15
|
if (this.adaptableInstance.lifecycleState === 'preDestroyed') {
|
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:
|
|
4
|
-
VERSION: "19.2.2
|
|
3
|
+
PUBLISH_TIMESTAMP: 1732896393268 || Date.now(),
|
|
4
|
+
VERSION: "19.2.2" || '--current-version--',
|
|
5
5
|
};
|