@genesislcap/grid-pro 14.290.0 → 14.291.0

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.
Files changed (43) hide show
  1. package/dist/custom-elements.json +93 -620
  2. package/dist/dts/datasource/base.datasource.d.ts +11 -44
  3. package/dist/dts/datasource/base.datasource.d.ts.map +1 -1
  4. package/dist/dts/datasource/base.types.d.ts +0 -21
  5. package/dist/dts/datasource/base.types.d.ts.map +1 -1
  6. package/dist/dts/datasource/server-side.datasource.d.ts.map +1 -1
  7. package/dist/dts/grid-pro-genesis-datasource/grid-pro-genesis-datasource.d.ts +3 -5
  8. package/dist/dts/grid-pro-genesis-datasource/grid-pro-genesis-datasource.d.ts.map +1 -1
  9. package/dist/dts/grid-pro.d.ts +4 -9
  10. package/dist/dts/grid-pro.d.ts.map +1 -1
  11. package/dist/dts/grid-pro.styles.d.ts.map +1 -1
  12. package/dist/dts/grid-pro.template.d.ts +1 -1
  13. package/dist/dts/grid-pro.template.d.ts.map +1 -1
  14. package/dist/esm/datasource/base.datasource.js +1 -172
  15. package/dist/esm/datasource/base.types.js +1 -8
  16. package/dist/esm/datasource/server-side.datasource.js +2 -9
  17. package/dist/esm/grid-pro-genesis-datasource/grid-pro-genesis-datasource.js +48 -11
  18. package/dist/esm/grid-pro.js +3 -20
  19. package/dist/esm/grid-pro.styles.js +22 -2
  20. package/dist/esm/grid-pro.template.js +33 -3
  21. package/dist/grid-pro.api.json +79 -369
  22. package/dist/grid-pro.d.ts +18 -67
  23. package/docs/api/grid-pro.genesisgriddatasourceelement.md +0 -3
  24. package/docs/api/grid-pro.gridprobasedatasource.md +0 -7
  25. package/docs/api/grid-pro.gridprogenesisdatasource.handleerrors.md +22 -0
  26. package/docs/api/grid-pro.gridprogenesisdatasource.md +2 -0
  27. package/docs/api/grid-pro.gridprogenesisdatasource.restartonreconnection.md +11 -0
  28. package/docs/api/grid-pro.gridprotemplate.md +1 -1
  29. package/docs/api-report.md +4 -19
  30. package/package.json +13 -13
  31. package/dist/dts/datasource/error-handler.dialog.d.ts +0 -3
  32. package/dist/dts/datasource/error-handler.dialog.d.ts.map +0 -1
  33. package/dist/esm/datasource/error-handler.dialog.js +0 -114
  34. package/docs/api/grid-pro.genesisgriddatasourceelement.clearerrors.md +0 -17
  35. package/docs/api/grid-pro.genesisgriddatasourceelement.handleerrors.md +0 -25
  36. package/docs/api/grid-pro.genesisgriddatasourceelement.restartonreconnection.md +0 -18
  37. package/docs/api/grid-pro.gridprobasedatasource.connectedcallback.md +0 -15
  38. package/docs/api/grid-pro.gridprobasedatasource.connectionsub.md +0 -11
  39. package/docs/api/grid-pro.gridprobasedatasource.disconnectedcallback.md +0 -15
  40. package/docs/api/grid-pro.gridprobasedatasource.isdisconnected.md +0 -17
  41. package/docs/api/grid-pro.gridprobasedatasource.setdisconnected.md +0 -24
  42. package/docs/api/grid-pro.gridprobasedatasource.subscribetoconnection.md +0 -15
  43. package/docs/api/grid-pro.gridprobasedatasource.unsubscribefromconnection.md +0 -15
@@ -46,7 +46,6 @@ import { RowNodeTransaction } from '@ag-grid-community/core';
46
46
  import type { ServerSideTransaction } from '@ag-grid-community/core';
47
47
  import { ServerSideTransactionResult } from '@ag-grid-community/core';
48
48
  import { Session } from '@genesislcap/foundation-comms';
49
- import { Subscription } from 'rxjs';
50
49
  import { Swatch } from '@microsoft/fast-components';
51
50
  import { SwatchRGB } from '@microsoft/fast-components';
52
51
  import { TextField } from '@genesislcap/foundation-ui';
@@ -431,15 +430,6 @@ export declare const agThemeTokenMapCSS: (themeName: string, tokenMap: CSSVarTok
431
430
  */
432
431
  export declare const backgroundSwatch: SwatchRGB;
433
432
 
434
- /**
435
- * Base datasource error event detail.
436
- * @public
437
- */
438
- declare type BaseDatasourceErrorEventDetail = {
439
- message: string;
440
- type: 'connection' | 'resource-validation' | 'resource-type' | 'metadata' | 'stream' | 'criteria' | 'unknown';
441
- };
442
-
443
433
  /**
444
434
  * The AG Boolean Renderer element.
445
435
  * @public
@@ -1082,12 +1072,6 @@ export declare class GenesisGridDatasourceElement extends GenesisGridDatasourceE
1082
1072
  * @privateRemarks Attribute-only, not to be used as a property. Use `rowId` getter instead.
1083
1073
  */
1084
1074
  rowIdAttr: any;
1085
- /**
1086
- * Attribute to set whether the datasource should restart when it reconnects.
1087
- * @remarks Defaults to `true`.
1088
- * @privateRemarks This attribute is shared across all datasources to ensure consistent behavior.
1089
- */
1090
- restartOnReconnection: boolean;
1091
1075
  protected get rowId(): string;
1092
1076
  /**
1093
1077
  * Returns whether the `row-id` attribute is the default one, depending on the resource type.
@@ -1104,23 +1088,6 @@ export declare class GenesisGridDatasourceElement extends GenesisGridDatasourceE
1104
1088
  get isRequestServer(): boolean;
1105
1089
  datasourceStatusChanged(prev: DatasourceStatus, next: DatasourceStatus): void;
1106
1090
  protected get agGrid(): GridPro | null;
1107
- /**
1108
- * Handles errors and emits appropriate error events.
1109
- * @param errors - The error message or array of error messages
1110
- * @param type - The type of error that occurred
1111
- * @public
1112
- */
1113
- handleErrors(errors: string | any[], type?: BaseDatasourceErrorEventDetail['type']): void;
1114
- /**
1115
- * Clears error state and emits connected event.
1116
- * @public
1117
- */
1118
- clearErrors(): void;
1119
- /**
1120
- * Override datasource initialization to handle errors properly.
1121
- * @internal
1122
- */
1123
- protected initializeDatasource(options: DatasourceOptions, fetchMeta?: boolean, startStream?: boolean): Promise<boolean>;
1124
1091
  }
1125
1092
 
1126
1093
  declare const GenesisGridDatasourceElement_base: new () => {
@@ -1135,7 +1102,11 @@ declare const GenesisGridDatasourceElement_base: new () => {
1135
1102
  autocapitalize: string;
1136
1103
  dir: string;
1137
1104
  draggable: boolean;
1138
- hidden: boolean;
1105
+ hidden: boolean; /**
1106
+ * Attribute to set whether the REQUEST object should be automatically set up.
1107
+ * @remarks Defaults to `true`. Only applies to REQUEST_SERVER (REQ-REP) resources.
1108
+ * @privateRemarks To avoid breaking changes for now, once V15 is out this will be removed and the default behavior will be the same as `false` here.
1109
+ */
1139
1110
  inert: boolean;
1140
1111
  innerText: string;
1141
1112
  lang: string;
@@ -1291,9 +1262,7 @@ declare const GenesisGridDatasourceElement_base: new () => {
1291
1262
  ariaModal: string;
1292
1263
  ariaMultiLine: string;
1293
1264
  ariaMultiSelectable: string;
1294
- ariaOrientation: string; /**
1295
- * @public
1296
- */
1265
+ ariaOrientation: string;
1297
1266
  ariaPlaceholder: string;
1298
1267
  ariaPosInSet: string;
1299
1268
  ariaPressed: string;
@@ -1381,7 +1350,10 @@ declare const GenesisGridDatasourceElement_base: new () => {
1381
1350
  onkeyup: (this: GlobalEventHandlers, ev: KeyboardEvent) => any;
1382
1351
  onload: (this: GlobalEventHandlers, ev: Event) => any;
1383
1352
  onloadeddata: (this: GlobalEventHandlers, ev: Event) => any;
1384
- onloadedmetadata: (this: GlobalEventHandlers, ev: Event) => any;
1353
+ onloadedmetadata: (this: GlobalEventHandlers, ev: Event) => any; /**
1354
+ * Helper function to extract configuration for status bar actions
1355
+ * @internal
1356
+ */
1385
1357
  onloadstart: (this: GlobalEventHandlers, ev: Event) => any;
1386
1358
  onlostpointercapture: (this: GlobalEventHandlers, ev: PointerEvent) => any;
1387
1359
  onmousedown: (this: GlobalEventHandlers, ev: MouseEvent) => any;
@@ -1809,7 +1781,6 @@ export declare class GridPro extends GridPro_base {
1809
1781
  addEventListener(eventType: string, listener: any, options?: boolean | AddEventListenerOptions): void;
1810
1782
  private addGridEventListener;
1811
1783
  private handleError;
1812
- private handleBaseDatasourceError;
1813
1784
  hideDatasourceError(): void;
1814
1785
  connectedCallback(): void;
1815
1786
  disconnectedCallback(): void;
@@ -1931,6 +1902,9 @@ declare const GridPro_base: (new (...args: any[]) => {
1931
1902
  spellcheck: boolean;
1932
1903
  title: string;
1933
1904
  translate: boolean;
1905
+ /**
1906
+ * If true, will enable row flashing for all rows for `add` async transactions
1907
+ */
1934
1908
  attachInternals(): ElementInternals;
1935
1909
  click(): void;
1936
1910
  addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
@@ -2039,14 +2013,7 @@ declare const GridPro_base: (new (...args: any[]) => {
2039
2013
  readonly DOCUMENT_FRAGMENT_NODE: number;
2040
2014
  readonly DOCUMENT_NODE: number;
2041
2015
  readonly DOCUMENT_POSITION_CONTAINED_BY: number;
2042
- readonly DOCUMENT_POSITION_CONTAINS: number; /**
2043
- * Adds an event listener to the grid element.
2044
- * @param eventType - The event type to listen for. Recommened to use the `Events` from AG Grid.
2045
- * @param listener - The event listener to call when the event is fired.
2046
- * @param options - An options object that specifies characteristics about the event listener.
2047
- * @privateRemarks
2048
- * This will change once we do the AG Upgrade and `eventType` will be correctly typed.
2049
- */
2016
+ readonly DOCUMENT_POSITION_CONTAINS: number;
2050
2017
  readonly DOCUMENT_POSITION_DISCONNECTED: number;
2051
2018
  readonly DOCUMENT_POSITION_FOLLOWING: number;
2052
2019
  readonly DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: number;
@@ -2238,11 +2205,6 @@ export declare class GridProBaseDatasource extends GenesisGridDatasourceElement
2238
2205
  protected agTransaction: RowDataTransaction | ServerSideTransaction;
2239
2206
  protected applyFuncName: string;
2240
2207
  protected applyAsyncFuncName: string;
2241
- protected connectionSub: Subscription | undefined;
2242
- connectedCallback(): void;
2243
- disconnectedCallback(): void;
2244
- protected subscribeToConnection(): void;
2245
- protected unsubscribeFromConnection(): void;
2246
2208
  protected generateColumnDefsFromMetadata(fieldsMetadata: FieldMetadata[], getFilterParamsByFieldType: Function): ColDef[];
2247
2209
  protected handleStreamInserts(insertedRows: any[], addIndex?: number): void;
2248
2210
  protected handleStreamDeletes(deletedRows: any[]): void;
@@ -2264,15 +2226,6 @@ export declare class GridProBaseDatasource extends GenesisGridDatasourceElement
2264
2226
  restart(): void;
2265
2227
  reloadResourceData(): void;
2266
2228
  destroy(): void;
2267
- /**
2268
- * Sets or removes the ds-disconnected attribute on the grid element.
2269
- * @param disconnected - true to set, false to remove
2270
- */
2271
- setDisconnected(disconnected: boolean): void;
2272
- /**
2273
- * Returns true if the grid has the ds-disconnected attribute.
2274
- */
2275
- isDisconnected(): boolean;
2276
2229
  /**
2277
2230
  * Helper function to extract configuration for status bar actions
2278
2231
  * @internal
@@ -2744,9 +2697,11 @@ export declare class GridProGenesisDatasource extends GridProGenesisDatasource_b
2744
2697
  criteriaChanged(oldCriteria: string, newCriteria: string): Promise<void>;
2745
2698
  requestChanged(oldRequest: string, newRequest: string): void;
2746
2699
  resourceNameChanged(oldValue: string, newValue: string): void;
2700
+ restartOnReconnection: boolean;
2747
2701
  keepColDefsOnClearRowData: boolean;
2748
2702
  private dataSub;
2749
2703
  private updateSub;
2704
+ private connectionSub;
2750
2705
  private requiresFullRowDataAndColDefs;
2751
2706
  private _lastMoreRows;
2752
2707
  private _isMoreRowsResult;
@@ -2825,6 +2780,7 @@ export declare class GridProGenesisDatasource extends GridProGenesisDatasource_b
2825
2780
  */
2826
2781
  private loadResourceData;
2827
2782
  private handleSnapshot;
2783
+ handleErrors(errors: string | any[]): void;
2828
2784
  private handleStreamResult;
2829
2785
  /**
2830
2786
  * Updates the status bar based on more rows status
@@ -2918,11 +2874,6 @@ declare const GridProGenesisDatasource_base: (new (...args: any[]) => {
2918
2874
  readonly shadowRoot: ShadowRoot;
2919
2875
  slot: string;
2920
2876
  readonly tagName: string;
2921
- /**
2922
- * Deinitialises the datasource, resetting it to its initial state.
2923
- * @deprecated Use `destroy` instead
2924
- * @public
2925
- */
2926
2877
  attachShadow(init: ShadowRootInit): ShadowRoot;
2927
2878
  closest<K_2 extends keyof HTMLElementTagNameMap>(selector: K_2): HTMLElementTagNameMap[K_2];
2928
2879
  closest<K_3 extends keyof SVGElementTagNameMap>(selector: K_3): SVGElementTagNameMap[K_3];
@@ -3719,7 +3670,7 @@ export declare enum GridProStatusBarTypes {
3719
3670
  *
3720
3671
  * @public
3721
3672
  * @remarks
3722
- * HTML Element: <foundation-grid-pro>
3673
+ * HTML Element: \<foundation-grid-pro\>
3723
3674
  */
3724
3675
  export declare const gridProTemplate: ViewTemplate;
3725
3676
 
@@ -37,7 +37,6 @@ export declare class GenesisGridDatasourceElement extends GenesisGridDatasourceE
37
37
  | [request](./grid-pro.genesisgriddatasourceelement.request.md) | | any | |
38
38
  | [requestAutoSetup](./grid-pro.genesisgriddatasourceelement.requestautosetup.md) | | boolean | Attribute to set whether the REQUEST object should be automatically set up. |
39
39
  | [resourceName](./grid-pro.genesisgriddatasourceelement.resourcename.md) | | string | |
40
- | [restartOnReconnection](./grid-pro.genesisgriddatasourceelement.restartonreconnection.md) | | boolean | Attribute to set whether the datasource should restart when it reconnects. |
41
40
  | [reverse](./grid-pro.genesisgriddatasourceelement.reverse.md) | | boolean | |
42
41
  | [rowDataMapper](./grid-pro.genesisgriddatasourceelement.rowdatamapper.md) | | Function | Allows grid data updates to be processed via and external function before applying in grid |
43
42
  | [rowId](./grid-pro.genesisgriddatasourceelement.rowid.md) | <p><code>protected</code></p><p><code>readonly</code></p> | string | |
@@ -49,10 +48,8 @@ export declare class GenesisGridDatasourceElement extends GenesisGridDatasourceE
49
48
 
50
49
  | Method | Modifiers | Description |
51
50
  | --- | --- | --- |
52
- | [clearErrors()](./grid-pro.genesisgriddatasourceelement.clearerrors.md) | | Clears error state and emits connected event. |
53
51
  | [datasourceOptions()](./grid-pro.genesisgriddatasourceelement.datasourceoptions.md) | <code>protected</code> | |
54
52
  | [datasourceStatusChanged(prev, next)](./grid-pro.genesisgriddatasourceelement.datasourcestatuschanged.md) | | |
55
- | [handleErrors(errors, type)](./grid-pro.genesisgriddatasourceelement.handleerrors.md) | | Handles errors and emits appropriate error events. |
56
53
  | [removeFilter(fieldName)](./grid-pro.genesisgriddatasourceelement.removefilter.md) | | |
57
54
  | [setFilter(fieldName, newFilter)](./grid-pro.genesisgriddatasourceelement.setfilter.md) | | |
58
55
 
@@ -19,7 +19,6 @@ export declare class GridProBaseDatasource extends GenesisGridDatasourceElement
19
19
  | [agTransaction](./grid-pro.gridprobasedatasource.agtransaction.md) | <code>protected</code> | RowDataTransaction \| ServerSideTransaction | |
20
20
  | [applyAsyncFuncName](./grid-pro.gridprobasedatasource.applyasyncfuncname.md) | <code>protected</code> | string | |
21
21
  | [applyFuncName](./grid-pro.gridprobasedatasource.applyfuncname.md) | <code>protected</code> | string | |
22
- | [connectionSub](./grid-pro.gridprobasedatasource.connectionsub.md) | <code>protected</code> | Subscription \| undefined | |
23
22
  | [dataSubWasLoggedOff](./grid-pro.gridprobasedatasource.datasubwasloggedoff.md) | <code>protected</code> | boolean | |
24
23
  | [pagination](./grid-pro.gridprobasedatasource.pagination.md) | <p><code>protected</code></p><p><code>readonly</code></p> | boolean | |
25
24
  | [rowData](./grid-pro.gridprobasedatasource.rowdata.md) | | Map&lt;string, any&gt; | |
@@ -31,19 +30,13 @@ export declare class GridProBaseDatasource extends GenesisGridDatasourceElement
31
30
  | [applyAllAgTransactions()](./grid-pro.gridprobasedatasource.applyallagtransactions.md) | <code>protected</code> | |
32
31
  | [applyTransaction(agTransaction)](./grid-pro.gridprobasedatasource.applytransaction.md) | <code>protected</code> | |
33
32
  | [applyTransactionAsync(agTransaction, callback)](./grid-pro.gridprobasedatasource.applytransactionasync.md) | <code>protected</code> | |
34
- | [connectedCallback()](./grid-pro.gridprobasedatasource.connectedcallback.md) | | |
35
33
  | [destroy()](./grid-pro.gridprobasedatasource.destroy.md) | | |
36
- | [disconnectedCallback()](./grid-pro.gridprobasedatasource.disconnectedcallback.md) | | |
37
34
  | [generateColumnDefsFromMetadata(fieldsMetadata, getFilterParamsByFieldType)](./grid-pro.gridprobasedatasource.generatecolumndefsfrommetadata.md) | <code>protected</code> | |
38
35
  | [getDatasourceStatusBarPanels(isServerSide)](./grid-pro.gridprobasedatasource.getdatasourcestatusbarpanels.md) | | Gets datasource-specific status bar component configurations. This method should be called by the grid to get status bar panels specific to this datasource. |
39
36
  | [handleStreamDeletes(deletedRows)](./grid-pro.gridprobasedatasource.handlestreamdeletes.md) | <code>protected</code> | |
40
37
  | [handleStreamInserts(insertedRows, addIndex)](./grid-pro.gridprobasedatasource.handlestreaminserts.md) | <code>protected</code> | |
41
38
  | [handleStreamUpdates(updatedRows)](./grid-pro.gridprobasedatasource.handlestreamupdates.md) | <code>protected</code> | |
42
- | [isDisconnected()](./grid-pro.gridprobasedatasource.isdisconnected.md) | | Returns true if the grid has the ds-disconnected attribute. |
43
39
  | [loadMore()](./grid-pro.gridprobasedatasource.loadmore.md) | | |
44
40
  | [reloadResourceData()](./grid-pro.gridprobasedatasource.reloadresourcedata.md) | | |
45
41
  | [restart()](./grid-pro.gridprobasedatasource.restart.md) | | |
46
- | [setDisconnected(disconnected)](./grid-pro.gridprobasedatasource.setdisconnected.md) | | Sets or removes the ds-disconnected attribute on the grid element. |
47
- | [subscribeToConnection()](./grid-pro.gridprobasedatasource.subscribetoconnection.md) | <code>protected</code> | |
48
- | [unsubscribeFromConnection()](./grid-pro.gridprobasedatasource.unsubscribefromconnection.md) | <code>protected</code> | |
49
42
 
@@ -0,0 +1,22 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/grid-pro](./grid-pro.md) &gt; [GridProGenesisDatasource](./grid-pro.gridprogenesisdatasource.md) &gt; [handleErrors](./grid-pro.gridprogenesisdatasource.handleerrors.md)
4
+
5
+ ## GridProGenesisDatasource.handleErrors() method
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ handleErrors(errors: string | any[]): void;
11
+ ```
12
+
13
+ ## Parameters
14
+
15
+ | Parameter | Type | Description |
16
+ | --- | --- | --- |
17
+ | errors | string \| any\[\] | |
18
+
19
+ **Returns:**
20
+
21
+ void
22
+
@@ -24,6 +24,7 @@ Only supports Client-Side Row Model.
24
24
  | [applyAsyncFuncName](./grid-pro.gridprogenesisdatasource.applyasyncfuncname.md) | | string | |
25
25
  | [applyFuncName](./grid-pro.gridprogenesisdatasource.applyfuncname.md) | | string | |
26
26
  | [keepColDefsOnClearRowData](./grid-pro.gridprogenesisdatasource.keepcoldefsonclearrowdata.md) | | boolean | |
27
+ | [restartOnReconnection](./grid-pro.gridprogenesisdatasource.restartonreconnection.md) | | boolean | |
27
28
 
28
29
  ## Methods
29
30
 
@@ -37,6 +38,7 @@ Only supports Client-Side Row Model.
37
38
  | [deinit()](./grid-pro.gridprogenesisdatasource.deinit.md) | | Deinitialises the datasource, resetting it to its initial state. |
38
39
  | [destroy()](./grid-pro.gridprogenesisdatasource.destroy.md) | | Destroys the datasource, resetting it to its initial state. |
39
40
  | [disconnectedCallback()](./grid-pro.gridprogenesisdatasource.disconnectedcallback.md) | | |
41
+ | [handleErrors(errors)](./grid-pro.gridprogenesisdatasource.handleerrors.md) | | |
40
42
  | [handleStreamDeletes(deletes)](./grid-pro.gridprogenesisdatasource.handlestreamdeletes.md) | | Handles stream deletes by removing records from the grid. |
41
43
  | [handleStreamInserts(inserts)](./grid-pro.gridprogenesisdatasource.handlestreaminserts.md) | | |
42
44
  | [handleStreamUpdates(updates)](./grid-pro.gridprogenesisdatasource.handlestreamupdates.md) | | |
@@ -0,0 +1,11 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/grid-pro](./grid-pro.md) &gt; [GridProGenesisDatasource](./grid-pro.gridprogenesisdatasource.md) &gt; [restartOnReconnection](./grid-pro.gridprogenesisdatasource.restartonreconnection.md)
4
+
5
+ ## GridProGenesisDatasource.restartOnReconnection property
6
+
7
+ **Signature:**
8
+
9
+ ```typescript
10
+ restartOnReconnection: boolean;
11
+ ```
@@ -12,5 +12,5 @@ gridProTemplate: ViewTemplate
12
12
 
13
13
  ## Remarks
14
14
 
15
- HTML Element: <foundation-grid-pro>
15
+ HTML Element: &lt;<!-- -->foundation-grid-pro<!-- -->&gt;
16
16
 
@@ -52,7 +52,6 @@ import { RowNodeTransaction } from '@ag-grid-community/core';
52
52
  import type { ServerSideTransaction } from '@ag-grid-community/core';
53
53
  import { ServerSideTransactionResult } from '@ag-grid-community/core';
54
54
  import { Session } from '@genesislcap/foundation-comms';
55
- import { Subscription } from 'rxjs';
56
55
  import { Swatch } from '@microsoft/fast-components';
57
56
  import { SwatchRGB } from '@microsoft/fast-components';
58
57
  import { TextField } from '@genesislcap/foundation-ui';
@@ -780,7 +779,6 @@ template: ViewTemplate<StringEditor, any>;
780
779
  export class GenesisGridDatasourceElement extends GenesisGridDatasourceElement_base {
781
780
  // (undocumented)
782
781
  protected get agGrid(): GridPro | null;
783
- clearErrors(): void;
784
782
  // (undocumented)
785
783
  connect: Connect;
786
784
  // (undocumented)
@@ -803,12 +801,8 @@ export class GenesisGridDatasourceElement extends GenesisGridDatasourceElement_b
803
801
  disablePolling: boolean;
804
802
  // (undocumented)
805
803
  fields: string;
806
- // Warning: (ae-forgotten-export) The symbol "BaseDatasourceErrorEventDetail" needs to be exported by the entry point index.d.ts
807
- handleErrors(errors: string | any[], type?: BaseDatasourceErrorEventDetail['type']): void;
808
804
  // @internal
809
805
  protected get hasDefaultRowId(): boolean;
810
- // @internal
811
- protected initializeDatasource(options: DatasourceOptions, fetchMeta?: boolean, startStream?: boolean): Promise<boolean>;
812
806
  // (undocumented)
813
807
  get isRequestServer(): boolean;
814
808
  // (undocumented)
@@ -830,7 +824,6 @@ export class GenesisGridDatasourceElement extends GenesisGridDatasourceElement_b
830
824
  requestAutoSetup: boolean;
831
825
  // (undocumented)
832
826
  resourceName: string;
833
- restartOnReconnection: boolean;
834
827
  // (undocumented)
835
828
  reverse: boolean;
836
829
  rowDataMapper: Function;
@@ -1043,16 +1036,10 @@ export class GridProBaseDatasource extends GenesisGridDatasourceElement {
1043
1036
  // (undocumented)
1044
1037
  protected applyTransactionAsync(agTransaction: RowDataTransaction, callback?: (res: any) => void): void;
1045
1038
  // (undocumented)
1046
- connectedCallback(): void;
1047
- // (undocumented)
1048
- protected connectionSub: Subscription | undefined;
1049
- // (undocumented)
1050
1039
  protected dataSubWasLoggedOff: boolean;
1051
1040
  // (undocumented)
1052
1041
  destroy(): void;
1053
1042
  // (undocumented)
1054
- disconnectedCallback(): void;
1055
- // (undocumented)
1056
1043
  protected generateColumnDefsFromMetadata(fieldsMetadata: FieldMetadata[], getFilterParamsByFieldType: Function): ColDef[];
1057
1044
  getDatasourceStatusBarPanels(isServerSide: boolean): any[];
1058
1045
  // @internal
@@ -1066,7 +1053,6 @@ export class GridProBaseDatasource extends GenesisGridDatasourceElement {
1066
1053
  protected handleStreamInserts(insertedRows: any[], addIndex?: number): void;
1067
1054
  // (undocumented)
1068
1055
  protected handleStreamUpdates(updatedRows: any[]): void;
1069
- isDisconnected(): boolean;
1070
1056
  // (undocumented)
1071
1057
  loadMore(): void;
1072
1058
  // (undocumented)
@@ -1077,11 +1063,6 @@ export class GridProBaseDatasource extends GenesisGridDatasourceElement {
1077
1063
  restart(): void;
1078
1064
  // (undocumented)
1079
1065
  rowData: Map<string, any>;
1080
- setDisconnected(disconnected: boolean): void;
1081
- // (undocumented)
1082
- protected subscribeToConnection(): void;
1083
- // (undocumented)
1084
- protected unsubscribeFromConnection(): void;
1085
1066
  }
1086
1067
 
1087
1068
  // @public
@@ -1213,6 +1194,8 @@ export class GridProGenesisDatasource extends GridProGenesisDatasource_base {
1213
1194
  destroy(): void;
1214
1195
  // (undocumented)
1215
1196
  disconnectedCallback(): void;
1197
+ // (undocumented)
1198
+ handleErrors(errors: string | any[]): void;
1216
1199
  handleStreamDeletes(deletes?: any[]): void;
1217
1200
  // (undocumented)
1218
1201
  handleStreamInserts(inserts?: any[]): void;
@@ -1235,6 +1218,8 @@ export class GridProGenesisDatasource extends GridProGenesisDatasource_base {
1235
1218
  resourceNameChanged(oldValue: string, newValue: string): void;
1236
1219
  restart(): Promise<void>;
1237
1220
  // (undocumented)
1221
+ restartOnReconnection: boolean;
1222
+ // (undocumented)
1238
1223
  setFilter(fieldName: string, newFilter: string): void;
1239
1224
  }
1240
1225
 
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.290.0",
4
+ "version": "14.291.0",
5
5
  "sideEffects": false,
6
6
  "license": "SEE LICENSE IN license.txt",
7
7
  "main": "dist/esm/index.js",
@@ -38,20 +38,20 @@
38
38
  }
39
39
  },
40
40
  "devDependencies": {
41
- "@genesislcap/foundation-testing": "14.290.0",
42
- "@genesislcap/genx": "14.290.0",
43
- "@genesislcap/rollup-builder": "14.290.0",
44
- "@genesislcap/ts-builder": "14.290.0",
45
- "@genesislcap/uvu-playwright-builder": "14.290.0",
46
- "@genesislcap/vite-builder": "14.290.0",
47
- "@genesislcap/webpack-builder": "14.290.0",
41
+ "@genesislcap/foundation-testing": "14.291.0",
42
+ "@genesislcap/genx": "14.291.0",
43
+ "@genesislcap/rollup-builder": "14.291.0",
44
+ "@genesislcap/ts-builder": "14.291.0",
45
+ "@genesislcap/uvu-playwright-builder": "14.291.0",
46
+ "@genesislcap/vite-builder": "14.291.0",
47
+ "@genesislcap/webpack-builder": "14.291.0",
48
48
  "rimraf": "^5.0.0"
49
49
  },
50
50
  "dependencies": {
51
- "@genesislcap/foundation-comms": "14.290.0",
52
- "@genesislcap/foundation-logger": "14.290.0",
53
- "@genesislcap/foundation-ui": "14.290.0",
54
- "@genesislcap/foundation-utils": "14.290.0",
51
+ "@genesislcap/foundation-comms": "14.291.0",
52
+ "@genesislcap/foundation-logger": "14.291.0",
53
+ "@genesislcap/foundation-ui": "14.291.0",
54
+ "@genesislcap/foundation-utils": "14.291.0",
55
55
  "@microsoft/fast-colors": "5.3.1",
56
56
  "@microsoft/fast-components": "2.30.6",
57
57
  "@microsoft/fast-element": "1.14.0",
@@ -77,5 +77,5 @@
77
77
  "access": "public"
78
78
  },
79
79
  "customElements": "dist/custom-elements.json",
80
- "gitHead": "d06408e1848d98c9de0bd3a7f3998e5650128d5d"
80
+ "gitHead": "cdfd959cfb35c6d9e4234e52cf37a11895481af5"
81
81
  }
@@ -1,3 +0,0 @@
1
- export declare const errorHandlerDialogStyles: import("@microsoft/fast-element").ElementStyles;
2
- export declare function getErrorHandlerDialogTemplate(prefix: string, gridErrorItems: any[]): import("@microsoft/fast-element").ViewTemplate<any, any>;
3
- //# sourceMappingURL=error-handler.dialog.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"error-handler.dialog.d.ts","sourceRoot":"","sources":["../../../src/datasource/error-handler.dialog.ts"],"names":[],"mappings":"AAgBA,eAAO,MAAM,wBAAwB,iDAoDpC,CAAC;AAEF,wBAAgB,6BAA6B,CAAC,MAAM,EAAE,MAAM,EAAE,cAAc,EAAE,GAAG,EAAE,4DA+ClF"}
@@ -1,114 +0,0 @@
1
- import { css, html, when, repeat } from '@microsoft/fast-element';
2
- const extractMessage = (detail) => {
3
- if (!detail)
4
- return '';
5
- if (typeof detail === 'string')
6
- return detail;
7
- if (Array.isArray(detail)) {
8
- return detail.map(extractMessage).join(', ');
9
- }
10
- if (typeof detail === 'object') {
11
- if ('message' in detail && typeof detail.message === 'string')
12
- return detail.message;
13
- if ('TEXT' in detail && typeof detail.TEXT === 'string')
14
- return detail.TEXT;
15
- return JSON.stringify(detail);
16
- }
17
- return String(detail);
18
- };
19
- export const errorHandlerDialogStyles = css `
20
- .overlay {
21
- position: absolute;
22
- inset: 0;
23
- width: 100%;
24
- height: 100%;
25
- background-color: var(--datasource-error-background-color, var(--neutral-layer-4));
26
- opacity: var(--datasource-error-background-opacity, 0.5);
27
- z-index: 1000;
28
- pointer-events: auto;
29
- border-radius: 2px;
30
- display: flex;
31
- align-items: center;
32
- justify-content: center;
33
- }
34
- .dialog-container {
35
- position: absolute;
36
- left: 50%;
37
- top: 50%;
38
- transform: translate(-50%, -50%);
39
- z-index: 1001;
40
- max-width: 90vw;
41
- max-height: 90vh;
42
- width: 100%;
43
- display: flex;
44
- flex-direction: column;
45
- align-items: center;
46
- justify-content: center;
47
- opacity: 1 !important;
48
- filter: none !important;
49
- box-sizing: border-box;
50
- }
51
- .grid-datasource-error-dialog {
52
- display: flex;
53
- flex-direction: column;
54
- align-items: center;
55
- justify-content: center;
56
- margin: 0 auto;
57
- max-width: 400px;
58
- width: 100%;
59
- box-sizing: border-box;
60
- background: var(--dialog-background, #2d2533);
61
- box-shadow: 0 4px 32px 0 rgba(0, 0, 0, 0.45);
62
- overflow: visible;
63
- min-height: 120px;
64
- }
65
- .error-details {
66
- max-height: 120px;
67
- overflow: auto;
68
- width: 100%;
69
- margin-top: 8px;
70
- }
71
- `;
72
- export function getErrorHandlerDialogTemplate(prefix, gridErrorItems) {
73
- const dialogTag = `${prefix}-dialog`;
74
- const buttonTag = `${prefix}-button`;
75
- return html `
76
- ${when(() => gridErrorItems && gridErrorItems.length > 0, html `
77
- <div class="overlay"></div>
78
- <div class="dialog-container">
79
- <${dialogTag}
80
- class="grid-datasource-error-dialog"
81
- type="error"
82
- show-close-icon="false"
83
- open
84
- >
85
- <h2 slot="top" class="title">Datasource unavailable</h2>
86
- <div>
87
- <p>
88
- Please refresh to reconnect. It is recommended that you save your data before refreshing.
89
- Data is not current and may be incomplete.
90
- </p>
91
- <details class="error-details">
92
- <summary>Show error details</summary>
93
- ${repeat(() => gridErrorItems, html `
94
- <p>
95
- <strong>Error:</strong>
96
- ${(x) => extractMessage(x.detail) || 'Unknown error occurred'}
97
- </p>
98
- `)}
99
- </details>
100
- </div>
101
- <div slot="bottom">
102
- <${buttonTag} appearance="lightweight" @click=${(x) => {
103
- var _a;
104
- x.hideDatasourceError();
105
- (_a = x.gridProDatasource) === null || _a === void 0 ? void 0 : _a.restart();
106
- }}>
107
- Refresh
108
- </${buttonTag}>
109
- </div>
110
- </${dialogTag}>
111
- </div>
112
- `)}
113
- `;
114
- }
@@ -1,17 +0,0 @@
1
- <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
-
3
- [Home](./index.md) &gt; [@genesislcap/grid-pro](./grid-pro.md) &gt; [GenesisGridDatasourceElement](./grid-pro.genesisgriddatasourceelement.md) &gt; [clearErrors](./grid-pro.genesisgriddatasourceelement.clearerrors.md)
4
-
5
- ## GenesisGridDatasourceElement.clearErrors() method
6
-
7
- Clears error state and emits connected event.
8
-
9
- **Signature:**
10
-
11
- ```typescript
12
- clearErrors(): void;
13
- ```
14
- **Returns:**
15
-
16
- void
17
-
@@ -1,25 +0,0 @@
1
- <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
-
3
- [Home](./index.md) &gt; [@genesislcap/grid-pro](./grid-pro.md) &gt; [GenesisGridDatasourceElement](./grid-pro.genesisgriddatasourceelement.md) &gt; [handleErrors](./grid-pro.genesisgriddatasourceelement.handleerrors.md)
4
-
5
- ## GenesisGridDatasourceElement.handleErrors() method
6
-
7
- Handles errors and emits appropriate error events.
8
-
9
- **Signature:**
10
-
11
- ```typescript
12
- handleErrors(errors: string | any[], type?: BaseDatasourceErrorEventDetail['type']): void;
13
- ```
14
-
15
- ## Parameters
16
-
17
- | Parameter | Type | Description |
18
- | --- | --- | --- |
19
- | errors | string \| any\[\] | The error message or array of error messages |
20
- | type | BaseDatasourceErrorEventDetail\['type'\] | _(Optional)_ The type of error that occurred |
21
-
22
- **Returns:**
23
-
24
- void
25
-
@@ -1,18 +0,0 @@
1
- <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
-
3
- [Home](./index.md) &gt; [@genesislcap/grid-pro](./grid-pro.md) &gt; [GenesisGridDatasourceElement](./grid-pro.genesisgriddatasourceelement.md) &gt; [restartOnReconnection](./grid-pro.genesisgriddatasourceelement.restartonreconnection.md)
4
-
5
- ## GenesisGridDatasourceElement.restartOnReconnection property
6
-
7
- Attribute to set whether the datasource should restart when it reconnects.
8
-
9
- **Signature:**
10
-
11
- ```typescript
12
- restartOnReconnection: boolean;
13
- ```
14
-
15
- ## Remarks
16
-
17
- Defaults to `true`<!-- -->.
18
-
@@ -1,15 +0,0 @@
1
- <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
-
3
- [Home](./index.md) &gt; [@genesislcap/grid-pro](./grid-pro.md) &gt; [GridProBaseDatasource](./grid-pro.gridprobasedatasource.md) &gt; [connectedCallback](./grid-pro.gridprobasedatasource.connectedcallback.md)
4
-
5
- ## GridProBaseDatasource.connectedCallback() method
6
-
7
- **Signature:**
8
-
9
- ```typescript
10
- connectedCallback(): void;
11
- ```
12
- **Returns:**
13
-
14
- void
15
-
@@ -1,11 +0,0 @@
1
- <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
-
3
- [Home](./index.md) &gt; [@genesislcap/grid-pro](./grid-pro.md) &gt; [GridProBaseDatasource](./grid-pro.gridprobasedatasource.md) &gt; [connectionSub](./grid-pro.gridprobasedatasource.connectionsub.md)
4
-
5
- ## GridProBaseDatasource.connectionSub property
6
-
7
- **Signature:**
8
-
9
- ```typescript
10
- protected connectionSub: Subscription | undefined;
11
- ```