@genesislcap/grid-pro 14.127.0 → 14.127.1
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/dist/custom-elements.json +56 -9
- package/dist/dts/grid-pro.d.ts +43 -11
- package/dist/dts/grid-pro.d.ts.map +1 -1
- package/dist/dts/grid-pro.types.d.ts +12 -0
- package/dist/dts/grid-pro.types.d.ts.map +1 -1
- package/dist/dts/utils/index.d.ts +1 -0
- package/dist/dts/utils/index.d.ts.map +1 -1
- package/dist/dts/utils/sanitasations.d.ts +7 -0
- package/dist/dts/utils/sanitasations.d.ts.map +1 -0
- package/dist/esm/grid-pro.js +5 -9
- package/dist/esm/grid-pro.types.js +6 -0
- package/dist/esm/utils/index.js +1 -0
- package/dist/esm/utils/sanitasations.js +12 -0
- package/dist/grid-pro.api.json +127 -0
- package/dist/grid-pro.d.ts +64 -11
- package/docs/api/grid-pro.csvexportparams.md +13 -0
- package/docs/api/grid-pro.gridoptionsconfig.md +13 -0
- package/docs/api/grid-pro.gridpro.gridoptionsconfig.md +25 -0
- package/docs/api/grid-pro.gridpro.md +1 -0
- package/docs/api/grid-pro.md +3 -0
- package/docs/api-report.md +14 -1
- package/package.json +8 -8
|
@@ -544,6 +544,14 @@
|
|
|
544
544
|
"privacy": "private",
|
|
545
545
|
"default": "undefined"
|
|
546
546
|
},
|
|
547
|
+
{
|
|
548
|
+
"kind": "field",
|
|
549
|
+
"name": "gridOptionsConfig",
|
|
550
|
+
"type": {
|
|
551
|
+
"text": "GridOptionsConfig"
|
|
552
|
+
},
|
|
553
|
+
"description": "Injectable config that allows to change grid options on an app level basis\nTo modify options, register instance of the config in DOM container that is\nabove the grid or on the top level of the application, so it applies to all grids."
|
|
554
|
+
},
|
|
547
555
|
{
|
|
548
556
|
"kind": "method",
|
|
549
557
|
"name": "combineAllGridComponents",
|
|
@@ -740,15 +748,6 @@
|
|
|
740
748
|
"name": "destroyFontFace",
|
|
741
749
|
"privacy": "private"
|
|
742
750
|
},
|
|
743
|
-
{
|
|
744
|
-
"kind": "field",
|
|
745
|
-
"name": "csvExportParams",
|
|
746
|
-
"type": {
|
|
747
|
-
"text": "CsvExportParams"
|
|
748
|
-
},
|
|
749
|
-
"privacy": "private",
|
|
750
|
-
"readonly": true
|
|
751
|
-
},
|
|
752
751
|
{
|
|
753
752
|
"kind": "method",
|
|
754
753
|
"name": "cloneNode",
|
|
@@ -1255,6 +1254,12 @@
|
|
|
1255
1254
|
"default": "'__errorColumn'",
|
|
1256
1255
|
"description": "Key used to store error details (column, message) when inline edit fails sync with server side data",
|
|
1257
1256
|
"privacy": "public"
|
|
1257
|
+
},
|
|
1258
|
+
{
|
|
1259
|
+
"kind": "variable",
|
|
1260
|
+
"name": "GridOptionsConfig",
|
|
1261
|
+
"description": "Grid options config used to inject into grids in application",
|
|
1262
|
+
"privacy": "public"
|
|
1258
1263
|
}
|
|
1259
1264
|
],
|
|
1260
1265
|
"exports": [
|
|
@@ -1305,6 +1310,14 @@
|
|
|
1305
1310
|
"name": "ERROR_COLUMN_FIELD",
|
|
1306
1311
|
"module": "src/grid-pro.types.ts"
|
|
1307
1312
|
}
|
|
1313
|
+
},
|
|
1314
|
+
{
|
|
1315
|
+
"kind": "js",
|
|
1316
|
+
"name": "GridOptionsConfig",
|
|
1317
|
+
"declaration": {
|
|
1318
|
+
"name": "GridOptionsConfig",
|
|
1319
|
+
"module": "src/grid-pro.types.ts"
|
|
1320
|
+
}
|
|
1308
1321
|
}
|
|
1309
1322
|
]
|
|
1310
1323
|
},
|
|
@@ -9190,6 +9203,14 @@
|
|
|
9190
9203
|
"name": "*",
|
|
9191
9204
|
"package": "./logger"
|
|
9192
9205
|
}
|
|
9206
|
+
},
|
|
9207
|
+
{
|
|
9208
|
+
"kind": "js",
|
|
9209
|
+
"name": "*",
|
|
9210
|
+
"declaration": {
|
|
9211
|
+
"name": "*",
|
|
9212
|
+
"package": "./sanitasations"
|
|
9213
|
+
}
|
|
9193
9214
|
}
|
|
9194
9215
|
]
|
|
9195
9216
|
},
|
|
@@ -9215,6 +9236,32 @@
|
|
|
9215
9236
|
}
|
|
9216
9237
|
]
|
|
9217
9238
|
},
|
|
9239
|
+
{
|
|
9240
|
+
"kind": "javascript-module",
|
|
9241
|
+
"path": "src/utils/sanitasations.ts",
|
|
9242
|
+
"declarations": [
|
|
9243
|
+
{
|
|
9244
|
+
"kind": "variable",
|
|
9245
|
+
"name": "csvExportParams",
|
|
9246
|
+
"type": {
|
|
9247
|
+
"text": "CsvExportParams"
|
|
9248
|
+
},
|
|
9249
|
+
"default": "{\n processCellCallback: (params) => {\n if (\n ['+', '=', '-', '@', '\\t', '\\n'].some((character) =>\n String(params.value).startsWith(character),\n )\n ) {\n return `'${params.value}`;\n }\n\n return params.value;\n },\n}",
|
|
9250
|
+
"description": "Allows secure export of CSV https://owasp.org/www-community/attacks/CSV_Injection",
|
|
9251
|
+
"privacy": "public"
|
|
9252
|
+
}
|
|
9253
|
+
],
|
|
9254
|
+
"exports": [
|
|
9255
|
+
{
|
|
9256
|
+
"kind": "js",
|
|
9257
|
+
"name": "csvExportParams",
|
|
9258
|
+
"declaration": {
|
|
9259
|
+
"name": "csvExportParams",
|
|
9260
|
+
"module": "src/utils/sanitasations.ts"
|
|
9261
|
+
}
|
|
9262
|
+
}
|
|
9263
|
+
]
|
|
9264
|
+
},
|
|
9218
9265
|
{
|
|
9219
9266
|
"kind": "javascript-module",
|
|
9220
9267
|
"path": "src/cell-renderers/utils/accessor.ts",
|
package/dist/dts/grid-pro.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import type { ColDef, ColumnApi, ColumnState, GridApi, GridOptions } from '@ag-g
|
|
|
2
2
|
import { Grid } from '@ag-grid-community/core';
|
|
3
3
|
import { FoundationElement } from '@microsoft/fast-foundation';
|
|
4
4
|
import { GridProBaseDatasource } from './datasource/base.datasource';
|
|
5
|
-
import { GridComponents } from './grid-pro.types';
|
|
5
|
+
import { GridComponents, GridOptionsConfig } from './grid-pro.types';
|
|
6
6
|
/**
|
|
7
7
|
* Convert string values from 'camelCase' to 'kebab-case'
|
|
8
8
|
* @param value - The value to convert to Kebab case.
|
|
@@ -15,6 +15,12 @@ declare const GridPro_base: (new (...args: any[]) => {
|
|
|
15
15
|
"__#1@#_latestTokenCode": string;
|
|
16
16
|
"__#1@#_hasFirstLoaded": boolean;
|
|
17
17
|
"__#1@#_cleanupTimeout": NodeJS.Timeout;
|
|
18
|
+
/**
|
|
19
|
+
* The Grid Pro element.
|
|
20
|
+
* @remarks Grid Pro is a Web Component wrapper around the AG Grid Community library.
|
|
21
|
+
* @public
|
|
22
|
+
* @tagname %%prefix%%-grid-pro
|
|
23
|
+
*/
|
|
18
24
|
"__#1@#_shouldForceLifecycle": boolean;
|
|
19
25
|
cloneNode(deep?: boolean): Node;
|
|
20
26
|
deepClone(): Node;
|
|
@@ -218,21 +224,33 @@ declare const GridPro_base: (new (...args: any[]) => {
|
|
|
218
224
|
readonly childElementCount: number;
|
|
219
225
|
readonly children: HTMLCollection;
|
|
220
226
|
readonly firstElementChild: Element;
|
|
221
|
-
readonly lastElementChild: Element;
|
|
227
|
+
readonly lastElementChild: Element;
|
|
228
|
+
append(...nodes: (string | Node)[]): void;
|
|
229
|
+
prepend(...nodes: (string | Node)[]): void;
|
|
230
|
+
querySelector<K_6 extends keyof HTMLElementTagNameMap>(selectors: K_6): HTMLElementTagNameMap[K_6];
|
|
231
|
+
querySelector<K_7 extends keyof SVGElementTagNameMap>(selectors: K_7): SVGElementTagNameMap[K_7];
|
|
232
|
+
querySelector<E_1 extends Element = Element>(selectors: string): E_1;
|
|
233
|
+
querySelectorAll<K_8 extends keyof HTMLElementTagNameMap>(selectors: K_8): NodeListOf<HTMLElementTagNameMap[K_8]>; /**
|
|
234
|
+
* Will merge templated column definitions with `columnDefs` plus localStorage's column state or `deferredColumnStates`.
|
|
235
|
+
* @deprecated use `applyTemplateDefinitions` instead.
|
|
236
|
+
* @param columnDefs - The column definitions to apply to the grid.
|
|
237
|
+
* @param deferredColumnDefsOrState - If true, will merge the column definitions with the saved column state or the `deferredColumnStates` property on the `grid-pro-genesis-datasource` element.
|
|
238
|
+
* @returns The merged column definitions.
|
|
239
|
+
*/
|
|
240
|
+
querySelectorAll<K_9 extends keyof SVGElementTagNameMap>(selectors: K_9): NodeListOf<SVGElementTagNameMap[K_9]>; /**
|
|
241
|
+
* Will merge templated column definitions with `columnDefs` plus localStorage's column state or `deferredColumnStates`.
|
|
242
|
+
* @deprecated use `applyTemplateDefinitions` instead.
|
|
243
|
+
* @param columnDefs - The column definitions to apply to the grid.
|
|
244
|
+
* @param deferredColumnDefsOrState - If true, will merge the column definitions with the saved column state or the `deferredColumnStates` property on the `grid-pro-genesis-datasource` element.
|
|
245
|
+
* @returns The merged column definitions.
|
|
246
|
+
*/
|
|
247
|
+
querySelectorAll<E_2 extends Element = Element>(selectors: string): NodeListOf<E_2>; /**
|
|
222
248
|
* Will merge templated column definitions with `columnDefs` plus localStorage's column state or `deferredColumnStates`.
|
|
223
249
|
* @deprecated use `applyTemplateDefinitions` instead.
|
|
224
250
|
* @param columnDefs - The column definitions to apply to the grid.
|
|
225
251
|
* @param deferredColumnDefsOrState - If true, will merge the column definitions with the saved column state or the `deferredColumnStates` property on the `grid-pro-genesis-datasource` element.
|
|
226
252
|
* @returns The merged column definitions.
|
|
227
253
|
*/
|
|
228
|
-
append(...nodes: (string | Node)[]): void;
|
|
229
|
-
prepend(...nodes: (string | Node)[]): void;
|
|
230
|
-
querySelector<K_6 extends keyof HTMLElementTagNameMap>(selectors: K_6): HTMLElementTagNameMap[K_6];
|
|
231
|
-
querySelector<K_7 extends keyof SVGElementTagNameMap>(selectors: K_7): SVGElementTagNameMap[K_7];
|
|
232
|
-
querySelector<E_1 extends Element = Element>(selectors: string): E_1;
|
|
233
|
-
querySelectorAll<K_8 extends keyof HTMLElementTagNameMap>(selectors: K_8): NodeListOf<HTMLElementTagNameMap[K_8]>;
|
|
234
|
-
querySelectorAll<K_9 extends keyof SVGElementTagNameMap>(selectors: K_9): NodeListOf<SVGElementTagNameMap[K_9]>;
|
|
235
|
-
querySelectorAll<E_2 extends Element = Element>(selectors: string): NodeListOf<E_2>;
|
|
236
254
|
replaceChildren(...nodes: (string | Node)[]): void;
|
|
237
255
|
readonly assignedSlot: HTMLSlotElement;
|
|
238
256
|
oncopy: (this: DocumentAndElementEventHandlers, ev: ClipboardEvent) => any;
|
|
@@ -419,6 +437,21 @@ export declare class GridPro extends GridPro_base {
|
|
|
419
437
|
protected initialised: boolean;
|
|
420
438
|
private rehydrationAttempted;
|
|
421
439
|
private filterConfig;
|
|
440
|
+
/**
|
|
441
|
+
* Injectable config that allows to change grid options on an app level basis
|
|
442
|
+
* To modify options, register instance of the config in DOM container that is
|
|
443
|
+
* above the grid or on the top level of the application, so it applies to all grids.
|
|
444
|
+
*
|
|
445
|
+
* @example
|
|
446
|
+
* ```
|
|
447
|
+
* DI.getOrCreateDOMContainer().register([
|
|
448
|
+
* Registration.instance<GridOptionsConfig>(GridOptionsConfig, {
|
|
449
|
+
* headerHeight: 50,
|
|
450
|
+
* }),
|
|
451
|
+
* ]);
|
|
452
|
+
* ```
|
|
453
|
+
*/
|
|
454
|
+
gridOptionsConfig: GridOptionsConfig;
|
|
422
455
|
constructor();
|
|
423
456
|
connectedCallback(): void;
|
|
424
457
|
disconnectedCallback(): void;
|
|
@@ -476,7 +509,6 @@ export declare class GridPro extends GridPro_base {
|
|
|
476
509
|
private fontFaceDestroy;
|
|
477
510
|
private insertFontFace;
|
|
478
511
|
private destroyFontFace;
|
|
479
|
-
private get csvExportParams();
|
|
480
512
|
}
|
|
481
513
|
/**
|
|
482
514
|
* GridPro shadow root options.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"grid-pro.d.ts","sourceRoot":"","sources":["../../src/grid-pro.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,MAAM,EACN,SAAS,EACT,WAAW,
|
|
1
|
+
{"version":3,"file":"grid-pro.d.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AAC,eAAe;IAkBvB;;;;;OAKG;IACH,mBAAmB,IAAI,WAAW,EAAE;IAapC,OAAO,CAAC,kBAAkB;IAa1B,OAAO,CAAC,iBAAiB;IAIzB,OAAO,CAAC,yBAAyB;IAOjC;;OAEG;IACH,IAAI,WAAW,IAAI,WAAW,CAE7B;IAED,IAAI,iBAAiB,IAAI,qBAAqB,CAM7C;IAED,IAAI,WAAW,CAAC,OAAO,EAAE,WAAW,EAuFnC;IAED;;;;;;OAMG;IACH,wBAAwB,CAAC,UAAU,EAAE,MAAM,EAAE,EAAE,yBAAyB,UAAQ;IAKhF;;;;;;;;OAQG;IACH,2BAA2B,CAAC,UAAU,EAAE,MAAM,EAAE,EAAE,yBAAyB,UAAQ;IA0EnF,IAAI,kBAAkB,aAerB;IAED,0BAA0B,CAAC,OAAO,KAAA,EAAE,QAAQ,KAAA,EAAE,QAAQ,KAAA;IAqBtD,mBAAmB,CAAC,SAAS,KAAA,EAAE,KAAK,KAAA;IAiBpC,OAAO,CAAC,eAAe,CAAa;IAEpC,OAAO,CAAC,cAAc;IAStB,OAAO,CAAC,eAAe;CAMxB;AAED;;;;;GAKG;AACH,eAAO,MAAM,8BAA8B,EAAE,cAA0B,CAAC;AAExE;;;GAGG;AACH,eAAO,MAAM,oBAAoB;;CAEhC,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,iBAAiB;;;;;;;;;;kBAM5B,CAAC"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { GridOptions } from '@ag-grid-community/core';
|
|
1
2
|
import { CSSVarTokenMap } from '@genesislcap/foundation-ui';
|
|
2
3
|
/**
|
|
3
4
|
* All official AG CSS variables
|
|
@@ -148,4 +149,15 @@ export declare const EDITED_COLUMN_FIELD = "__editedColumn";
|
|
|
148
149
|
* @public
|
|
149
150
|
*/
|
|
150
151
|
export declare const ERROR_COLUMN_FIELD = "__errorColumn";
|
|
152
|
+
/**
|
|
153
|
+
* Grid options config used to configure grids across the application
|
|
154
|
+
* @public
|
|
155
|
+
*/
|
|
156
|
+
export interface GridOptionsConfig extends GridOptions {
|
|
157
|
+
}
|
|
158
|
+
/**
|
|
159
|
+
* Grid options config used to inject into grids in application
|
|
160
|
+
* @public
|
|
161
|
+
*/
|
|
162
|
+
export declare const GridOptionsConfig: import("@microsoft/fast-foundation").InterfaceSymbol<GridOptionsConfig>;
|
|
151
163
|
//# sourceMappingURL=grid-pro.types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"grid-pro.types.d.ts","sourceRoot":"","sources":["../../src/grid-pro.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAsB,cAAc,EAAE,MAAM,4BAA4B,CAAC;
|
|
1
|
+
{"version":3,"file":"grid-pro.types.d.ts","sourceRoot":"","sources":["../../src/grid-pro.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AACtD,OAAO,EAAsB,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAIhF;;;GAGG;AACH,oBAAY,aAAa;IACvB,eAAe,0BAA0B;IACzC,SAAS,oBAAoB;IAC7B,wBAAwB,oCAAoC;IAC5D,qBAAqB,iCAAiC;IACtD,uBAAuB,mCAAmC;IAC1D,eAAe,0BAA0B;IACzC,qBAAqB,iCAAiC;IACtD,wBAAwB,oCAAoC;IAC5D,+BAA+B,4CAA4C;IAC3E,2BAA2B,wCAAwC;IACnE,0BAA0B,uCAAuC;IACjE,qBAAqB,kCAAkC;IACvD,aAAa,yBAAyB;IACtC,yBAAyB,sCAAsC;IAC/D,6BAA6B,0CAA0C;IACvE,yBAAyB,sCAAsC;IAC/D,0CAA0C,yDAAyD;IACnG,kCAAkC,gDAAgD;IAClF,8BAA8B,4CAA4C;IAC1E,+BAA+B,6CAA6C;IAC5E,mBAAmB,+BAA+B;IAClD,WAAW,sBAAsB;IACjC,oBAAoB,gCAAgC;IACpD,cAAc,0BAA0B;IACxC,0BAA0B,uCAAuC;IACjE,6BA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gBAAgB,gBAAgB,CAAC;AAE9C;;;GAGG;AACH,eAAO,MAAM,mBAAmB,mBAAmB,CAAC;AAEpD;;;GAGG;AACH,eAAO,MAAM,kBAAkB,kBAAkB,CAAC;AAElD;;;GAGG;AACH,MAAM,WAAW,iBAAkB,SAAQ,WAAW;CAAG;AAEzD;;;GAGG;AACH,eAAO,MAAM,iBAAiB,yEAA0C,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AACzB,cAAc,iBAAiB,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { CsvExportParams } from '@ag-grid-community/core';
|
|
2
|
+
/**
|
|
3
|
+
* Allows secure export of CSV https://owasp.org/www-community/attacks/CSV_Injection
|
|
4
|
+
* @public
|
|
5
|
+
*/
|
|
6
|
+
export declare const csvExportParams: CsvExportParams;
|
|
7
|
+
//# sourceMappingURL=sanitasations.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sanitasations.d.ts","sourceRoot":"","sources":["../../../src/utils/sanitasations.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAE1D;;;GAGG;AACH,eAAO,MAAM,eAAe,EAAE,eAY7B,CAAC"}
|
package/dist/esm/grid-pro.js
CHANGED
|
@@ -17,7 +17,7 @@ import { GridProGenesisDatasource } from './grid-pro-genesis-datasource';
|
|
|
17
17
|
import { DEBOUNCED_RESIZE_TIME } from './grid-pro.definitions';
|
|
18
18
|
import { foundationGridProStyles as styles } from './grid-pro.styles';
|
|
19
19
|
import { gridProTemplate as template } from './grid-pro.template';
|
|
20
|
-
import { AgGridTheme, GridProRendererTypes, agThemeFontsId, agThemeTokenMapClassname, GRID_READY_EVENT, ERROR_COLUMN_FIELD, EDITED_COLUMN_FIELD, } from './grid-pro.types';
|
|
20
|
+
import { AgGridTheme, GridProRendererTypes, agThemeFontsId, agThemeTokenMapClassname, GRID_READY_EVENT, ERROR_COLUMN_FIELD, EDITED_COLUMN_FIELD, GridOptionsConfig, } from './grid-pro.types';
|
|
21
21
|
import { ErrorTooltip } from './tooltips';
|
|
22
22
|
import { logger, mergeAndDedupColDefWithColumnState } from './utils';
|
|
23
23
|
GridProGenesisDatasource;
|
|
@@ -256,7 +256,7 @@ export class GridPro extends LifecycleMixin(FoundationElement) {
|
|
|
256
256
|
this.agAttributes[attrName] = attribute.value;
|
|
257
257
|
});
|
|
258
258
|
const { columnDefs, components, defaultColDef, onGridReady, onFirstDataRendered } = options, rest = __rest(options, ["columnDefs", "components", "defaultColDef", "onGridReady", "onFirstDataRendered"]);
|
|
259
|
-
const derivedOptions = Object.assign(Object.assign(Object.assign({ defaultColDef: Object.assign({ enableCellChangeFlash: this.enableCellFlashing, filter: true, resizable: true, sortable: true }, defaultColDef),
|
|
259
|
+
const derivedOptions = Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, this.gridOptionsConfig), { defaultColDef: Object.assign({ enableCellChangeFlash: this.enableCellFlashing, filter: true, resizable: true, sortable: true }, defaultColDef), components: this.combineAllGridComponents(components), suppressDragLeaveHidesColumns: true }), this.eventsAndCallbacks), { onGridReady: (event) => {
|
|
260
260
|
var _a, _b;
|
|
261
261
|
this.gridApi = (_a = options.api) !== null && _a !== void 0 ? _a : event.api;
|
|
262
262
|
this.columnApi = (_b = options.columnApi) !== null && _b !== void 0 ? _b : event.columnApi;
|
|
@@ -425,13 +425,6 @@ export class GridPro extends LifecycleMixin(FoundationElement) {
|
|
|
425
425
|
this.fontFaceDestroy = null;
|
|
426
426
|
}
|
|
427
427
|
}
|
|
428
|
-
get csvExportParams() {
|
|
429
|
-
return {
|
|
430
|
-
processCellCallback: (params) => ['+', '-', '=', '@', '\t', '\n'].some((character) => String(params.value).startsWith(character))
|
|
431
|
-
? '#ERROR formulas not allowed'
|
|
432
|
-
: params.value,
|
|
433
|
-
};
|
|
434
|
-
}
|
|
435
428
|
}
|
|
436
429
|
__decorate([
|
|
437
430
|
observable
|
|
@@ -505,6 +498,9 @@ __decorate([
|
|
|
505
498
|
__decorate([
|
|
506
499
|
observable
|
|
507
500
|
], GridPro.prototype, "gridComponents", void 0);
|
|
501
|
+
__decorate([
|
|
502
|
+
GridOptionsConfig
|
|
503
|
+
], GridPro.prototype, "gridOptionsConfig", void 0);
|
|
508
504
|
/**
|
|
509
505
|
* GridPro shadow root options.
|
|
510
506
|
* @public
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { CSSVarsTokenMapper } from '@genesislcap/foundation-ui';
|
|
2
2
|
import { css } from '@microsoft/fast-element';
|
|
3
|
+
import { DI } from '@microsoft/fast-foundation';
|
|
3
4
|
/**
|
|
4
5
|
* All official AG CSS variables
|
|
5
6
|
* @public
|
|
@@ -149,3 +150,8 @@ export const EDITED_COLUMN_FIELD = '__editedColumn';
|
|
|
149
150
|
* @public
|
|
150
151
|
*/
|
|
151
152
|
export const ERROR_COLUMN_FIELD = '__errorColumn';
|
|
153
|
+
/**
|
|
154
|
+
* Grid options config used to inject into grids in application
|
|
155
|
+
* @public
|
|
156
|
+
*/
|
|
157
|
+
export const GridOptionsConfig = DI.createInterface();
|
package/dist/esm/utils/index.js
CHANGED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Allows secure export of CSV https://owasp.org/www-community/attacks/CSV_Injection
|
|
3
|
+
* @public
|
|
4
|
+
*/
|
|
5
|
+
export const csvExportParams = {
|
|
6
|
+
processCellCallback: (params) => {
|
|
7
|
+
if (['+', '=', '-', '@', '\t', '\n'].some((character) => String(params.value).startsWith(character))) {
|
|
8
|
+
return `'${params.value}`;
|
|
9
|
+
}
|
|
10
|
+
return params.value;
|
|
11
|
+
},
|
|
12
|
+
};
|
package/dist/grid-pro.api.json
CHANGED
|
@@ -3372,6 +3372,30 @@
|
|
|
3372
3372
|
"endIndex": 2
|
|
3373
3373
|
}
|
|
3374
3374
|
},
|
|
3375
|
+
{
|
|
3376
|
+
"kind": "Variable",
|
|
3377
|
+
"canonicalReference": "@genesislcap/grid-pro!csvExportParams:var",
|
|
3378
|
+
"docComment": "/**\n * Allows secure export of CSV https://owasp.org/www-community/attacks/CSV_Injection\n *\n * @public\n */\n",
|
|
3379
|
+
"excerptTokens": [
|
|
3380
|
+
{
|
|
3381
|
+
"kind": "Content",
|
|
3382
|
+
"text": "csvExportParams: "
|
|
3383
|
+
},
|
|
3384
|
+
{
|
|
3385
|
+
"kind": "Reference",
|
|
3386
|
+
"text": "CsvExportParams",
|
|
3387
|
+
"canonicalReference": "@ag-grid-community/core!CsvExportParams:interface"
|
|
3388
|
+
}
|
|
3389
|
+
],
|
|
3390
|
+
"fileUrlPath": "src/utils/sanitasations.ts",
|
|
3391
|
+
"isReadonly": true,
|
|
3392
|
+
"releaseTag": "Public",
|
|
3393
|
+
"name": "csvExportParams",
|
|
3394
|
+
"variableTypeTokenRange": {
|
|
3395
|
+
"startIndex": 1,
|
|
3396
|
+
"endIndex": 2
|
|
3397
|
+
}
|
|
3398
|
+
},
|
|
3375
3399
|
{
|
|
3376
3400
|
"kind": "Class",
|
|
3377
3401
|
"canonicalReference": "@genesislcap/grid-pro!DateEditor:class",
|
|
@@ -7203,6 +7227,78 @@
|
|
|
7203
7227
|
"endIndex": 2
|
|
7204
7228
|
}
|
|
7205
7229
|
},
|
|
7230
|
+
{
|
|
7231
|
+
"kind": "Interface",
|
|
7232
|
+
"canonicalReference": "@genesislcap/grid-pro!GridOptionsConfig:interface",
|
|
7233
|
+
"docComment": "/**\n * Grid options config used to configure grids across the application\n *\n * @public\n */\n",
|
|
7234
|
+
"excerptTokens": [
|
|
7235
|
+
{
|
|
7236
|
+
"kind": "Content",
|
|
7237
|
+
"text": "export interface GridOptionsConfig extends "
|
|
7238
|
+
},
|
|
7239
|
+
{
|
|
7240
|
+
"kind": "Reference",
|
|
7241
|
+
"text": "GridOptions",
|
|
7242
|
+
"canonicalReference": "@ag-grid-community/core!GridOptions:interface"
|
|
7243
|
+
},
|
|
7244
|
+
{
|
|
7245
|
+
"kind": "Content",
|
|
7246
|
+
"text": " "
|
|
7247
|
+
}
|
|
7248
|
+
],
|
|
7249
|
+
"fileUrlPath": "src/grid-pro.types.ts",
|
|
7250
|
+
"releaseTag": "Public",
|
|
7251
|
+
"name": "GridOptionsConfig",
|
|
7252
|
+
"preserveMemberOrder": false,
|
|
7253
|
+
"members": [],
|
|
7254
|
+
"extendsTokenRanges": [
|
|
7255
|
+
{
|
|
7256
|
+
"startIndex": 1,
|
|
7257
|
+
"endIndex": 2
|
|
7258
|
+
}
|
|
7259
|
+
]
|
|
7260
|
+
},
|
|
7261
|
+
{
|
|
7262
|
+
"kind": "Variable",
|
|
7263
|
+
"canonicalReference": "@genesislcap/grid-pro!GridOptionsConfig:var",
|
|
7264
|
+
"docComment": "/**\n * Grid options config used to inject into grids in application\n *\n * @public\n */\n",
|
|
7265
|
+
"excerptTokens": [
|
|
7266
|
+
{
|
|
7267
|
+
"kind": "Content",
|
|
7268
|
+
"text": "GridOptionsConfig: "
|
|
7269
|
+
},
|
|
7270
|
+
{
|
|
7271
|
+
"kind": "Content",
|
|
7272
|
+
"text": "import(\"@microsoft/fast-foundation\")."
|
|
7273
|
+
},
|
|
7274
|
+
{
|
|
7275
|
+
"kind": "Reference",
|
|
7276
|
+
"text": "InterfaceSymbol",
|
|
7277
|
+
"canonicalReference": "@microsoft/fast-foundation!InterfaceSymbol:type"
|
|
7278
|
+
},
|
|
7279
|
+
{
|
|
7280
|
+
"kind": "Content",
|
|
7281
|
+
"text": "<"
|
|
7282
|
+
},
|
|
7283
|
+
{
|
|
7284
|
+
"kind": "Reference",
|
|
7285
|
+
"text": "GridOptionsConfig",
|
|
7286
|
+
"canonicalReference": "@genesislcap/grid-pro!GridOptionsConfig:interface"
|
|
7287
|
+
},
|
|
7288
|
+
{
|
|
7289
|
+
"kind": "Content",
|
|
7290
|
+
"text": ">"
|
|
7291
|
+
}
|
|
7292
|
+
],
|
|
7293
|
+
"fileUrlPath": "src/grid-pro.types.ts",
|
|
7294
|
+
"isReadonly": true,
|
|
7295
|
+
"releaseTag": "Public",
|
|
7296
|
+
"name": "GridOptionsConfig",
|
|
7297
|
+
"variableTypeTokenRange": {
|
|
7298
|
+
"startIndex": 1,
|
|
7299
|
+
"endIndex": 6
|
|
7300
|
+
}
|
|
7301
|
+
},
|
|
7206
7302
|
{
|
|
7207
7303
|
"kind": "Class",
|
|
7208
7304
|
"canonicalReference": "@genesislcap/grid-pro!GridPro:class",
|
|
@@ -8263,6 +8359,37 @@
|
|
|
8263
8359
|
"isProtected": false,
|
|
8264
8360
|
"isAbstract": false
|
|
8265
8361
|
},
|
|
8362
|
+
{
|
|
8363
|
+
"kind": "Property",
|
|
8364
|
+
"canonicalReference": "@genesislcap/grid-pro!GridPro#gridOptionsConfig:member",
|
|
8365
|
+
"docComment": "/**\n * Injectable config that allows to change grid options on an app level basis To modify options, register instance of the config in DOM container that is above the grid or on the top level of the application, so it applies to all grids.\n *\n * @example\n * ```\n * DI.getOrCreateDOMContainer().register([\n * Registration.instance<GridOptionsConfig>(GridOptionsConfig, {\n * headerHeight: 50,\n * }),\n * ]);\n * ```\n *\n */\n",
|
|
8366
|
+
"excerptTokens": [
|
|
8367
|
+
{
|
|
8368
|
+
"kind": "Content",
|
|
8369
|
+
"text": "gridOptionsConfig: "
|
|
8370
|
+
},
|
|
8371
|
+
{
|
|
8372
|
+
"kind": "Reference",
|
|
8373
|
+
"text": "GridOptionsConfig",
|
|
8374
|
+
"canonicalReference": "@genesislcap/grid-pro!GridOptionsConfig:interface"
|
|
8375
|
+
},
|
|
8376
|
+
{
|
|
8377
|
+
"kind": "Content",
|
|
8378
|
+
"text": ";"
|
|
8379
|
+
}
|
|
8380
|
+
],
|
|
8381
|
+
"isReadonly": false,
|
|
8382
|
+
"isOptional": false,
|
|
8383
|
+
"releaseTag": "Public",
|
|
8384
|
+
"name": "gridOptionsConfig",
|
|
8385
|
+
"propertyTypeTokenRange": {
|
|
8386
|
+
"startIndex": 1,
|
|
8387
|
+
"endIndex": 2
|
|
8388
|
+
},
|
|
8389
|
+
"isStatic": false,
|
|
8390
|
+
"isProtected": false,
|
|
8391
|
+
"isAbstract": false
|
|
8392
|
+
},
|
|
8266
8393
|
{
|
|
8267
8394
|
"kind": "Property",
|
|
8268
8395
|
"canonicalReference": "@genesislcap/grid-pro!GridPro#gridProDatasource:member",
|
package/dist/grid-pro.d.ts
CHANGED
|
@@ -10,6 +10,7 @@ import type { Container } from '@microsoft/fast-foundation';
|
|
|
10
10
|
import { Controller } from '@microsoft/fast-element';
|
|
11
11
|
import { CSSDesignToken } from '@microsoft/fast-foundation';
|
|
12
12
|
import { CSSVarTokenMap } from '@genesislcap/foundation-ui';
|
|
13
|
+
import { CsvExportParams } from '@ag-grid-community/core';
|
|
13
14
|
import { Datasource } from '@genesislcap/foundation-comms';
|
|
14
15
|
import { DatasourceOptions } from '@genesislcap/foundation-comms';
|
|
15
16
|
import { DOMContainer } from '@genesislcap/foundation-utils';
|
|
@@ -20,12 +21,13 @@ import { FoundationElementRegistry } from '@microsoft/fast-foundation';
|
|
|
20
21
|
import { FoundationLayoutContainer } from '@genesislcap/foundation-utils';
|
|
21
22
|
import { Grid } from '@ag-grid-community/core';
|
|
22
23
|
import type { GridApi } from '@ag-grid-community/core';
|
|
23
|
-
import
|
|
24
|
+
import { GridOptions } from '@ag-grid-community/core';
|
|
24
25
|
import { ICellEditorComp } from '@ag-grid-community/core';
|
|
25
26
|
import { ICellEditorParams } from '@ag-grid-community/core';
|
|
26
27
|
import { ICellRendererComp } from '@ag-grid-community/core';
|
|
27
28
|
import { ICellRendererFunc } from '@ag-grid-community/core';
|
|
28
29
|
import { ICellRendererParams } from '@ag-grid-community/core';
|
|
30
|
+
import { InterfaceSymbol } from '@microsoft/fast-foundation';
|
|
29
31
|
import type { IServerSideDatasource } from '@ag-grid-community/core';
|
|
30
32
|
import type { IServerSideGetRowsParams } from '@ag-grid-community/core';
|
|
31
33
|
import { ITooltipComp } from '@ag-grid-community/core';
|
|
@@ -438,6 +440,12 @@ export declare const ColumnTemplate: ViewTemplate<GridProColumn, any>;
|
|
|
438
440
|
*/
|
|
439
441
|
export declare const convertToKebabCase: (value: string) => string;
|
|
440
442
|
|
|
443
|
+
/**
|
|
444
|
+
* Allows secure export of CSV https://owasp.org/www-community/attacks/CSV_Injection
|
|
445
|
+
* @public
|
|
446
|
+
*/
|
|
447
|
+
export declare const csvExportParams: CsvExportParams;
|
|
448
|
+
|
|
441
449
|
/**
|
|
442
450
|
* The AG Date Editor element.
|
|
443
451
|
* @public
|
|
@@ -1072,6 +1080,19 @@ export declare type GridComponents = {
|
|
|
1072
1080
|
[componentName: string]: any;
|
|
1073
1081
|
};
|
|
1074
1082
|
|
|
1083
|
+
/**
|
|
1084
|
+
* Grid options config used to configure grids across the application
|
|
1085
|
+
* @public
|
|
1086
|
+
*/
|
|
1087
|
+
export declare interface GridOptionsConfig extends GridOptions {
|
|
1088
|
+
}
|
|
1089
|
+
|
|
1090
|
+
/**
|
|
1091
|
+
* Grid options config used to inject into grids in application
|
|
1092
|
+
* @public
|
|
1093
|
+
*/
|
|
1094
|
+
export declare const GridOptionsConfig: InterfaceSymbol<GridOptionsConfig>;
|
|
1095
|
+
|
|
1075
1096
|
/**
|
|
1076
1097
|
* The Grid Pro element.
|
|
1077
1098
|
* @remarks Grid Pro is a Web Component wrapper around the AG Grid Community library.
|
|
@@ -1150,6 +1171,21 @@ export declare class GridPro extends GridPro_base {
|
|
|
1150
1171
|
protected initialised: boolean;
|
|
1151
1172
|
private rehydrationAttempted;
|
|
1152
1173
|
private filterConfig;
|
|
1174
|
+
/**
|
|
1175
|
+
* Injectable config that allows to change grid options on an app level basis
|
|
1176
|
+
* To modify options, register instance of the config in DOM container that is
|
|
1177
|
+
* above the grid or on the top level of the application, so it applies to all grids.
|
|
1178
|
+
*
|
|
1179
|
+
* @example
|
|
1180
|
+
* ```
|
|
1181
|
+
* DI.getOrCreateDOMContainer().register([
|
|
1182
|
+
* Registration.instance<GridOptionsConfig>(GridOptionsConfig, {
|
|
1183
|
+
* headerHeight: 50,
|
|
1184
|
+
* }),
|
|
1185
|
+
* ]);
|
|
1186
|
+
* ```
|
|
1187
|
+
*/
|
|
1188
|
+
gridOptionsConfig: GridOptionsConfig;
|
|
1153
1189
|
constructor();
|
|
1154
1190
|
connectedCallback(): void;
|
|
1155
1191
|
disconnectedCallback(): void;
|
|
@@ -1207,7 +1243,6 @@ export declare class GridPro extends GridPro_base {
|
|
|
1207
1243
|
private fontFaceDestroy;
|
|
1208
1244
|
private insertFontFace;
|
|
1209
1245
|
private destroyFontFace;
|
|
1210
|
-
private get csvExportParams();
|
|
1211
1246
|
}
|
|
1212
1247
|
|
|
1213
1248
|
declare const GridPro_base: (new (...args: any[]) => {
|
|
@@ -1215,6 +1250,12 @@ declare const GridPro_base: (new (...args: any[]) => {
|
|
|
1215
1250
|
"__#1@#_latestTokenCode": string;
|
|
1216
1251
|
"__#1@#_hasFirstLoaded": boolean;
|
|
1217
1252
|
"__#1@#_cleanupTimeout": NodeJS.Timeout;
|
|
1253
|
+
/**
|
|
1254
|
+
* The Grid Pro element.
|
|
1255
|
+
* @remarks Grid Pro is a Web Component wrapper around the AG Grid Community library.
|
|
1256
|
+
* @public
|
|
1257
|
+
* @tagname %%prefix%%-grid-pro
|
|
1258
|
+
*/
|
|
1218
1259
|
"__#1@#_shouldForceLifecycle": boolean;
|
|
1219
1260
|
cloneNode(deep?: boolean): Node;
|
|
1220
1261
|
deepClone(): Node;
|
|
@@ -1418,21 +1459,33 @@ declare const GridPro_base: (new (...args: any[]) => {
|
|
|
1418
1459
|
readonly childElementCount: number;
|
|
1419
1460
|
readonly children: HTMLCollection;
|
|
1420
1461
|
readonly firstElementChild: Element;
|
|
1421
|
-
readonly lastElementChild: Element;
|
|
1462
|
+
readonly lastElementChild: Element;
|
|
1463
|
+
append(...nodes: (string | Node)[]): void;
|
|
1464
|
+
prepend(...nodes: (string | Node)[]): void;
|
|
1465
|
+
querySelector<K_6 extends keyof HTMLElementTagNameMap>(selectors: K_6): HTMLElementTagNameMap[K_6];
|
|
1466
|
+
querySelector<K_7 extends keyof SVGElementTagNameMap>(selectors: K_7): SVGElementTagNameMap[K_7];
|
|
1467
|
+
querySelector<E_1 extends Element = Element>(selectors: string): E_1;
|
|
1468
|
+
querySelectorAll<K_8 extends keyof HTMLElementTagNameMap>(selectors: K_8): NodeListOf<HTMLElementTagNameMap[K_8]>; /**
|
|
1469
|
+
* Will merge templated column definitions with `columnDefs` plus localStorage's column state or `deferredColumnStates`.
|
|
1470
|
+
* @deprecated use `applyTemplateDefinitions` instead.
|
|
1471
|
+
* @param columnDefs - The column definitions to apply to the grid.
|
|
1472
|
+
* @param deferredColumnDefsOrState - If true, will merge the column definitions with the saved column state or the `deferredColumnStates` property on the `grid-pro-genesis-datasource` element.
|
|
1473
|
+
* @returns The merged column definitions.
|
|
1474
|
+
*/
|
|
1475
|
+
querySelectorAll<K_9 extends keyof SVGElementTagNameMap>(selectors: K_9): NodeListOf<SVGElementTagNameMap[K_9]>; /**
|
|
1476
|
+
* Will merge templated column definitions with `columnDefs` plus localStorage's column state or `deferredColumnStates`.
|
|
1477
|
+
* @deprecated use `applyTemplateDefinitions` instead.
|
|
1478
|
+
* @param columnDefs - The column definitions to apply to the grid.
|
|
1479
|
+
* @param deferredColumnDefsOrState - If true, will merge the column definitions with the saved column state or the `deferredColumnStates` property on the `grid-pro-genesis-datasource` element.
|
|
1480
|
+
* @returns The merged column definitions.
|
|
1481
|
+
*/
|
|
1482
|
+
querySelectorAll<E_2 extends Element = Element>(selectors: string): NodeListOf<E_2>; /**
|
|
1422
1483
|
* Will merge templated column definitions with `columnDefs` plus localStorage's column state or `deferredColumnStates`.
|
|
1423
1484
|
* @deprecated use `applyTemplateDefinitions` instead.
|
|
1424
1485
|
* @param columnDefs - The column definitions to apply to the grid.
|
|
1425
1486
|
* @param deferredColumnDefsOrState - If true, will merge the column definitions with the saved column state or the `deferredColumnStates` property on the `grid-pro-genesis-datasource` element.
|
|
1426
1487
|
* @returns The merged column definitions.
|
|
1427
1488
|
*/
|
|
1428
|
-
append(...nodes: (string | Node)[]): void;
|
|
1429
|
-
prepend(...nodes: (string | Node)[]): void;
|
|
1430
|
-
querySelector<K_6 extends keyof HTMLElementTagNameMap>(selectors: K_6): HTMLElementTagNameMap[K_6];
|
|
1431
|
-
querySelector<K_7 extends keyof SVGElementTagNameMap>(selectors: K_7): SVGElementTagNameMap[K_7];
|
|
1432
|
-
querySelector<E_1 extends Element = Element>(selectors: string): E_1;
|
|
1433
|
-
querySelectorAll<K_8 extends keyof HTMLElementTagNameMap>(selectors: K_8): NodeListOf<HTMLElementTagNameMap[K_8]>;
|
|
1434
|
-
querySelectorAll<K_9 extends keyof SVGElementTagNameMap>(selectors: K_9): NodeListOf<SVGElementTagNameMap[K_9]>;
|
|
1435
|
-
querySelectorAll<E_2 extends Element = Element>(selectors: string): NodeListOf<E_2>;
|
|
1436
1489
|
replaceChildren(...nodes: (string | Node)[]): void;
|
|
1437
1490
|
readonly assignedSlot: HTMLSlotElement;
|
|
1438
1491
|
oncopy: (this: DocumentAndElementEventHandlers, ev: ClipboardEvent) => any;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/grid-pro](./grid-pro.md) > [csvExportParams](./grid-pro.csvexportparams.md)
|
|
4
|
+
|
|
5
|
+
## csvExportParams variable
|
|
6
|
+
|
|
7
|
+
Allows secure export of CSV https://owasp.org/www-community/attacks/CSV\_Injection
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
csvExportParams: CsvExportParams
|
|
13
|
+
```
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/grid-pro](./grid-pro.md) > [GridOptionsConfig](./grid-pro.gridoptionsconfig.md)
|
|
4
|
+
|
|
5
|
+
## GridOptionsConfig variable
|
|
6
|
+
|
|
7
|
+
Grid options config used to inject into grids in application
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
GridOptionsConfig: import("@microsoft/fast-foundation").InterfaceSymbol<GridOptionsConfig>
|
|
13
|
+
```
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/grid-pro](./grid-pro.md) > [GridPro](./grid-pro.gridpro.md) > [gridOptionsConfig](./grid-pro.gridpro.gridoptionsconfig.md)
|
|
4
|
+
|
|
5
|
+
## GridPro.gridOptionsConfig property
|
|
6
|
+
|
|
7
|
+
Injectable config that allows to change grid options on an app level basis To modify options, register instance of the config in DOM container that is above the grid or on the top level of the application, so it applies to all grids.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
gridOptionsConfig: GridOptionsConfig;
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Example
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
```
|
|
19
|
+
DI.getOrCreateDOMContainer().register([
|
|
20
|
+
Registration.instance<GridOptionsConfig>(GridOptionsConfig, {
|
|
21
|
+
headerHeight: 50,
|
|
22
|
+
}),
|
|
23
|
+
]);
|
|
24
|
+
```
|
|
25
|
+
|
|
@@ -48,6 +48,7 @@ Grid Pro is a Web Component wrapper around the AG Grid Community library.
|
|
|
48
48
|
| [gridComponents](./grid-pro.gridpro.gridcomponents.md) | | { \[componentName: string\]: any; } | |
|
|
49
49
|
| [gridFontFace](./grid-pro.gridpro.gridfontface.md) | | string | |
|
|
50
50
|
| [gridOptions](./grid-pro.gridpro.gridoptions.md) | | GridOptions | |
|
|
51
|
+
| [gridOptionsConfig](./grid-pro.gridpro.gridoptionsconfig.md) | | [GridOptionsConfig](./grid-pro.gridoptionsconfig.md) | Injectable config that allows to change grid options on an app level basis To modify options, register instance of the config in DOM container that is above the grid or on the top level of the application, so it applies to all grids. |
|
|
51
52
|
| [gridProDatasource](./grid-pro.gridpro.gridprodatasource.md) | <code>readonly</code> | GridProBaseDatasource | |
|
|
52
53
|
| [gridSlot](./grid-pro.gridpro.gridslot.md) | | HTMLSlotElement | |
|
|
53
54
|
| [headerHeight](./grid-pro.gridpro.headerheight.md) | | number | |
|
package/docs/api/grid-pro.md
CHANGED
|
@@ -48,6 +48,7 @@
|
|
|
48
48
|
| Interface | Description |
|
|
49
49
|
| --- | --- |
|
|
50
50
|
| [DateEditorParams](./grid-pro.dateeditorparams.md) | Parameters used to configure [SelectEditor](./grid-pro.selecteditor.md) |
|
|
51
|
+
| [GridOptionsConfig](./grid-pro.gridoptionsconfig.md) | Grid options config used to configure grids across the application |
|
|
51
52
|
| [MultiselectEditorParams](./grid-pro.multiselecteditorparams.md) | Parameters used to configure [MultiselectEditor](./grid-pro.multiselecteditor.md) |
|
|
52
53
|
| [NumberEditorParams](./grid-pro.numbereditorparams.md) | Parameters used to configure [NumberEditor](./grid-pro.numbereditor.md) |
|
|
53
54
|
| [SelectEditorParams](./grid-pro.selecteditorparams.md) | Parameters used to configure [SelectEditor](./grid-pro.selecteditor.md) |
|
|
@@ -83,6 +84,7 @@
|
|
|
83
84
|
| [CellTemplate](./grid-pro.celltemplate.md) | The Grid Pro Cell Template. |
|
|
84
85
|
| [ColumnTemplate](./grid-pro.columntemplate.md) | The Grid Pro Column Template. |
|
|
85
86
|
| [convertToKebabCase](./grid-pro.converttokebabcase.md) | Convert string values from 'camelCase' to 'kebab-case' |
|
|
87
|
+
| [csvExportParams](./grid-pro.csvexportparams.md) | Allows secure export of CSV https://owasp.org/www-community/attacks/CSV\_Injection |
|
|
86
88
|
| [defaultAgGridFontFace](./grid-pro.defaultaggridfontface.md) | The default font face for Grid Pro (agGridAlpine). |
|
|
87
89
|
| [defaultGridProConfig](./grid-pro.defaultgridproconfig.md) | Grid Pro default configuration. |
|
|
88
90
|
| [EDITED\_COLUMN\_FIELD](./grid-pro.edited_column_field.md) | Key used to store currently edited column when it being synced with server side data |
|
|
@@ -115,6 +117,7 @@
|
|
|
115
117
|
| [getTextFieldRendererTemplate](./grid-pro.gettextfieldrenderertemplate.md) | Get a Design System prefixed Text Field template. |
|
|
116
118
|
| [getTextRendererTemplate](./grid-pro.gettextrenderertemplate.md) | |
|
|
117
119
|
| [GRID\_READY\_EVENT](./grid-pro.grid_ready_event.md) | Event fired when grid is ready |
|
|
120
|
+
| [GridOptionsConfig](./grid-pro.gridoptionsconfig.md) | Grid options config used to inject into grids in application |
|
|
118
121
|
| [gridProTemplate](./grid-pro.gridprotemplate.md) | The Grid Pro Template. |
|
|
119
122
|
| [logger](./grid-pro.logger.md) | Logger for the grid-pro package |
|
|
120
123
|
| [textFieldRendererStyles](./grid-pro.textfieldrendererstyles.md) | The AG Text Field Renderer Styles. |
|
package/docs/api-report.md
CHANGED
|
@@ -16,6 +16,7 @@ import type { Container } from '@microsoft/fast-foundation';
|
|
|
16
16
|
import { Controller } from '@microsoft/fast-element';
|
|
17
17
|
import { CSSDesignToken } from '@microsoft/fast-foundation';
|
|
18
18
|
import { CSSVarTokenMap } from '@genesislcap/foundation-ui';
|
|
19
|
+
import { CsvExportParams } from '@ag-grid-community/core';
|
|
19
20
|
import { Datasource } from '@genesislcap/foundation-comms';
|
|
20
21
|
import { DatasourceOptions } from '@genesislcap/foundation-comms';
|
|
21
22
|
import { DOMContainer } from '@genesislcap/foundation-utils';
|
|
@@ -26,12 +27,13 @@ import { FoundationElementRegistry } from '@microsoft/fast-foundation';
|
|
|
26
27
|
import { FoundationLayoutContainer } from '@genesislcap/foundation-utils';
|
|
27
28
|
import { Grid } from '@ag-grid-community/core';
|
|
28
29
|
import type { GridApi } from '@ag-grid-community/core';
|
|
29
|
-
import
|
|
30
|
+
import { GridOptions } from '@ag-grid-community/core';
|
|
30
31
|
import { ICellEditorComp } from '@ag-grid-community/core';
|
|
31
32
|
import { ICellEditorParams } from '@ag-grid-community/core';
|
|
32
33
|
import { ICellRendererComp } from '@ag-grid-community/core';
|
|
33
34
|
import { ICellRendererFunc } from '@ag-grid-community/core';
|
|
34
35
|
import { ICellRendererParams } from '@ag-grid-community/core';
|
|
36
|
+
import { InterfaceSymbol } from '@microsoft/fast-foundation';
|
|
35
37
|
import type { IServerSideDatasource } from '@ag-grid-community/core';
|
|
36
38
|
import type { IServerSideGetRowsParams } from '@ag-grid-community/core';
|
|
37
39
|
import { ITooltipComp } from '@ag-grid-community/core';
|
|
@@ -337,6 +339,9 @@ export const ColumnTemplate: ViewTemplate<GridProColumn, any>;
|
|
|
337
339
|
// @public
|
|
338
340
|
export const convertToKebabCase: (value: string) => string;
|
|
339
341
|
|
|
342
|
+
// @public
|
|
343
|
+
export const csvExportParams: CsvExportParams;
|
|
344
|
+
|
|
340
345
|
// @public
|
|
341
346
|
export class DateEditor extends FoundationElement implements ICellEditorComp {
|
|
342
347
|
// (undocumented)
|
|
@@ -751,6 +756,13 @@ export type GridComponents = {
|
|
|
751
756
|
[componentName: string]: any;
|
|
752
757
|
};
|
|
753
758
|
|
|
759
|
+
// @public
|
|
760
|
+
export interface GridOptionsConfig extends GridOptions {
|
|
761
|
+
}
|
|
762
|
+
|
|
763
|
+
// @public
|
|
764
|
+
export const GridOptionsConfig: InterfaceSymbol<GridOptionsConfig>;
|
|
765
|
+
|
|
754
766
|
// Warning: (ae-forgotten-export) The symbol "GridPro_base" needs to be exported by the entry point index.d.ts
|
|
755
767
|
//
|
|
756
768
|
// @public
|
|
@@ -807,6 +819,7 @@ export class GridPro extends GridPro_base {
|
|
|
807
819
|
// (undocumented)
|
|
808
820
|
get gridOptions(): GridOptions;
|
|
809
821
|
set gridOptions(options: GridOptions);
|
|
822
|
+
gridOptionsConfig: GridOptionsConfig;
|
|
810
823
|
// Warning: (ae-forgotten-export) The symbol "GridProBaseDatasource" needs to be exported by the entry point index.d.ts
|
|
811
824
|
//
|
|
812
825
|
// (undocumented)
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@genesislcap/grid-pro",
|
|
3
3
|
"description": "Genesis Foundation AG Grid",
|
|
4
|
-
"version": "14.127.
|
|
4
|
+
"version": "14.127.1",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"license": "SEE LICENSE IN license.txt",
|
|
7
7
|
"main": "dist/esm/index.js",
|
|
@@ -30,15 +30,15 @@
|
|
|
30
30
|
"test:debug": "genx test --debug"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
|
-
"@genesislcap/foundation-testing": "14.127.
|
|
34
|
-
"@genesislcap/genx": "14.127.
|
|
33
|
+
"@genesislcap/foundation-testing": "14.127.1",
|
|
34
|
+
"@genesislcap/genx": "14.127.1",
|
|
35
35
|
"rimraf": "^3.0.2"
|
|
36
36
|
},
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@genesislcap/foundation-comms": "14.127.
|
|
39
|
-
"@genesislcap/foundation-logger": "14.127.
|
|
40
|
-
"@genesislcap/foundation-ui": "14.127.
|
|
41
|
-
"@genesislcap/foundation-utils": "14.127.
|
|
38
|
+
"@genesislcap/foundation-comms": "14.127.1",
|
|
39
|
+
"@genesislcap/foundation-logger": "14.127.1",
|
|
40
|
+
"@genesislcap/foundation-ui": "14.127.1",
|
|
41
|
+
"@genesislcap/foundation-utils": "14.127.1",
|
|
42
42
|
"@microsoft/fast-colors": "^5.3.1",
|
|
43
43
|
"@microsoft/fast-components": "^2.30.6",
|
|
44
44
|
"@microsoft/fast-element": "^1.12.0",
|
|
@@ -62,5 +62,5 @@
|
|
|
62
62
|
"access": "public"
|
|
63
63
|
},
|
|
64
64
|
"customElements": "dist/custom-elements.json",
|
|
65
|
-
"gitHead": "
|
|
65
|
+
"gitHead": "02e9aea553b0bb4e7792d6b0a7dce6067a7eea7a"
|
|
66
66
|
}
|