@genesislcap/grid-pro 15.16.0 → 15.17.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 (42) hide show
  1. package/dist/custom-elements.json +1896 -1338
  2. package/dist/dts/datasource/index.d.ts +3 -0
  3. package/dist/dts/datasource/index.d.ts.map +1 -1
  4. package/dist/dts/datasource/row-match.classes.d.ts +47 -0
  5. package/dist/dts/datasource/row-match.classes.d.ts.map +1 -0
  6. package/dist/dts/datasource/row-match.tracker.d.ts +67 -0
  7. package/dist/dts/datasource/row-match.tracker.d.ts.map +1 -0
  8. package/dist/dts/datasource/row-match.types.d.ts +86 -0
  9. package/dist/dts/datasource/row-match.types.d.ts.map +1 -0
  10. package/dist/dts/grid-pro.styles.d.ts +14 -0
  11. package/dist/dts/grid-pro.styles.d.ts.map +1 -1
  12. package/dist/dts/index.d.ts +1 -0
  13. package/dist/dts/index.d.ts.map +1 -1
  14. package/dist/dts/react.d.ts +13 -13
  15. package/dist/dts/row-alert/index.d.ts +3 -0
  16. package/dist/dts/row-alert/index.d.ts.map +1 -0
  17. package/dist/dts/row-alert/row-alert.d.ts +132 -0
  18. package/dist/dts/row-alert/row-alert.d.ts.map +1 -0
  19. package/dist/dts/row-alert/row-alert.types.d.ts +62 -0
  20. package/dist/dts/row-alert/row-alert.types.d.ts.map +1 -0
  21. package/dist/dts/state-persistence/kv-state.d.ts +3 -0
  22. package/dist/dts/state-persistence/kv-state.d.ts.map +1 -1
  23. package/dist/dts/state-persistence/local-state.d.ts +3 -0
  24. package/dist/dts/state-persistence/local-state.d.ts.map +1 -1
  25. package/dist/dts/state-persistence/state-persistence.d.ts +16 -0
  26. package/dist/dts/state-persistence/state-persistence.d.ts.map +1 -1
  27. package/dist/esm/datasource/index.js +3 -0
  28. package/dist/esm/datasource/row-match.classes.js +53 -0
  29. package/dist/esm/datasource/row-match.tracker.js +117 -0
  30. package/dist/esm/datasource/row-match.types.js +98 -0
  31. package/dist/esm/grid-pro.styles.js +48 -0
  32. package/dist/esm/index.js +1 -0
  33. package/dist/esm/row-alert/index.js +2 -0
  34. package/dist/esm/row-alert/row-alert.js +197 -0
  35. package/dist/esm/row-alert/row-alert.types.js +63 -0
  36. package/dist/esm/state-persistence/kv-state.js +21 -0
  37. package/dist/esm/state-persistence/local-state.js +19 -0
  38. package/dist/grid-pro.api.json +11119 -8496
  39. package/dist/grid-pro.d.ts +441 -0
  40. package/dist/react.cjs +9 -9
  41. package/dist/react.mjs +7 -7
  42. package/package.json +14 -14
@@ -3,5 +3,8 @@ export * from './base.types';
3
3
  export * from './client-side.datasource';
4
4
  export * from './error-handler.dialog';
5
5
  export * from './datasource.types';
6
+ export * from './row-match.types';
7
+ export * from './row-match.tracker';
8
+ export * from './row-match.classes';
6
9
  export * from './server-side.datasource';
7
10
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/datasource/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,cAAc,CAAC;AAC7B,cAAc,0BAA0B,CAAC;AACzC,cAAc,wBAAwB,CAAC;AACvC,cAAc,oBAAoB,CAAC;AACnC,cAAc,0BAA0B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/datasource/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,cAAc,CAAC;AAC7B,cAAc,0BAA0B,CAAC;AACzC,cAAc,wBAAwB,CAAC;AACvC,cAAc,oBAAoB,CAAC;AACnC,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,qBAAqB,CAAC;AACpC,cAAc,0BAA0B,CAAC"}
@@ -0,0 +1,47 @@
1
+ import { type RowMatchCriteria } from './row-match.types';
2
+ /**
3
+ * Class the grid puts on rows satisfying the criteria. The grid's own styles flash it in step
4
+ * with any alerting tab, so a tab that draws you to a grid also shows you which rows caused it.
5
+ *
6
+ * @public
7
+ */
8
+ export declare const ROW_MATCH_ALERT_CLASS = "grid-pro-row-alert";
9
+ /**
10
+ * Class the grid puts on just the `flashField` cell of a matching row, for grids that flash a
11
+ * single column rather than the whole row.
12
+ *
13
+ * @public
14
+ */
15
+ export declare const ROW_MATCH_ALERT_CELL_CLASS = "grid-pro-row-alert-cell";
16
+ /**
17
+ * Row class rules that flag rows meeting {@link RowMatchCriteria}, for spreading into
18
+ * `gridOptions.rowClassRules`.
19
+ *
20
+ * Pairs with {@link DatasourceRowMatchTracker}: the tracker decides whether a tab should flash,
21
+ * these decide which rows made it flash. Both take the same criteria, so the two cannot disagree.
22
+ *
23
+ * ```ts
24
+ * gridOptions = { rowClassRules: createRowMatchClassRules(criteria) };
25
+ * ```
26
+ *
27
+ * @public
28
+ */
29
+ export declare function createRowMatchClassRules(criteria: RowMatchCriteria): Record<string, (params: {
30
+ data?: unknown;
31
+ }) => boolean>;
32
+ /**
33
+ * Cell class rules that flag only the `flashField` cell of a matching row, for spreading into
34
+ * `gridOptions.defaultColDef.cellClassRules`.
35
+ *
36
+ * They belong on `defaultColDef` rather than a single column because AG Grid has no grid-level
37
+ * `cellClassRules`, and the rule itself checks which column it is running against.
38
+ *
39
+ * @public
40
+ */
41
+ export declare function createRowMatchCellClassRules(criteria: RowMatchCriteria): Record<string, (params: {
42
+ data?: unknown;
43
+ colDef: {
44
+ field?: string;
45
+ };
46
+ }) => boolean>;
47
+ //# sourceMappingURL=row-match.classes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"row-match.classes.d.ts","sourceRoot":"","sources":["../../../src/datasource/row-match.classes.ts"],"names":[],"mappings":"AACA,OAAO,EAAsB,KAAK,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAE9E;;;;;GAKG;AACH,eAAO,MAAM,qBAAqB,uBAAuB,CAAC;AAE1D;;;;;GAKG;AACH,eAAO,MAAM,0BAA0B,4BAA4B,CAAC;AAEpE;;;;;;;;;;;;GAYG;AACH,wBAAgB,wBAAwB,CACtC,QAAQ,EAAE,gBAAgB,GACzB,MAAM,CAAC,MAAM,EAAE,CAAC,MAAM,EAAE;IAAE,IAAI,CAAC,EAAE,OAAO,CAAA;CAAE,KAAK,OAAO,CAAC,CAMzD;AAED;;;;;;;;GAQG;AACH,wBAAgB,4BAA4B,CAC1C,QAAQ,EAAE,gBAAgB,GACzB,MAAM,CAAC,MAAM,EAAE,CAAC,MAAM,EAAE;IAAE,IAAI,CAAC,EAAE,OAAO,CAAC;IAAC,MAAM,EAAE;QAAE,KAAK,CAAC,EAAE,MAAM,CAAA;KAAE,CAAA;CAAE,KAAK,OAAO,CAAC,CASrF"}
@@ -0,0 +1,67 @@
1
+ import { type DataChangedEventDetail } from '../grid-pro-genesis-datasource/datasource-events.types';
2
+ import { type RowMatchCriteria } from './row-match.types';
3
+ /**
4
+ * Notified whenever the tracker flips between "some rows match" and "none match".
5
+ *
6
+ * @public
7
+ */
8
+ export type RowMatchActiveChanged = (active: boolean) => void;
9
+ /**
10
+ * Tracks which datasource rows satisfy {@link RowMatchCriteria} as stream updates arrive,
11
+ * and reports whether any currently do.
12
+ *
13
+ * Rows are tracked incrementally from `add` / `update` / `remove` deltas rather than by
14
+ * rescanning the grid, so cost is proportional to the update rather than to the row count.
15
+ *
16
+ * The typical consumer flags a tab while a background grid still holds rows needing
17
+ * attention:
18
+ *
19
+ * ```ts
20
+ * const tracker = new DatasourceRowMatchTracker(
21
+ * { rowIdField: 'ORDER_ID', stateField: 'ORDER_STATE', stateValue: 'PENDING' },
22
+ * (active) => { tab.alert = active; },
23
+ * );
24
+ * const stop = tracker.observe(datasourceElement);
25
+ * ```
26
+ *
27
+ * Frameworks that surface the datasource events as props can feed the tracker directly with
28
+ * {@link DatasourceRowMatchTracker.handleDataChanged} and
29
+ * {@link DatasourceRowMatchTracker.handleDataCleared} instead of calling `observe`.
30
+ *
31
+ * Passing the same criteria to `createRowMatchClassRules` flashes the matching rows themselves, so
32
+ * a tab that says there is work to do leads to a grid that shows which rows it meant.
33
+ *
34
+ * Criteria are fixed for the tracker's life. To watch for something else, build a new tracker and
35
+ * reload the datasource, so rows already delivered are replayed against the new rules.
36
+ *
37
+ * @public
38
+ */
39
+ export declare class DatasourceRowMatchTracker {
40
+ private readonly criteria;
41
+ private readonly onActiveChanged;
42
+ private readonly matchedRowIds;
43
+ private lastReportedActive;
44
+ constructor(criteria: RowMatchCriteria, onActiveChanged: RowMatchActiveChanged);
45
+ /** True while at least one tracked row matches. */
46
+ get active(): boolean;
47
+ /** How many tracked rows currently match. */
48
+ get matchCount(): number;
49
+ /**
50
+ * Forgets every tracked row. Call when the grid's filter or search criteria change, so a
51
+ * stale alert does not survive into a result set that no longer contains those rows.
52
+ */
53
+ reset(): void;
54
+ /** Applies a `datasource-data-changed` detail. */
55
+ handleDataChanged(detail: DataChangedEventDetail | undefined): void;
56
+ /** Applies a `datasource-data-cleared` event. */
57
+ handleDataCleared(): void;
58
+ /**
59
+ * Subscribes to the datasource events on `target`.
60
+ *
61
+ * @returns a function that removes the listeners.
62
+ */
63
+ observe(target: EventTarget): () => void;
64
+ private syncRow;
65
+ private report;
66
+ }
67
+ //# sourceMappingURL=row-match.tracker.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"row-match.tracker.d.ts","sourceRoot":"","sources":["../../../src/datasource/row-match.tracker.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,sBAAsB,EAC5B,MAAM,wDAAwD,CAAC;AAChE,OAAO,EAAsB,KAAK,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAE9E;;;;GAIG;AACH,MAAM,MAAM,qBAAqB,GAAG,CAAC,MAAM,EAAE,OAAO,KAAK,IAAI,CAAC;AAE9D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,qBAAa,yBAAyB;IAKlC,OAAO,CAAC,QAAQ,CAAC,QAAQ;IACzB,OAAO,CAAC,QAAQ,CAAC,eAAe;IALlC,OAAO,CAAC,QAAQ,CAAC,aAAa,CAAqB;IACnD,OAAO,CAAC,kBAAkB,CAAS;gBAGhB,QAAQ,EAAE,gBAAgB,EAC1B,eAAe,EAAE,qBAAqB;IAGzD,mDAAmD;IACnD,IAAI,MAAM,IAAI,OAAO,CAEpB;IAED,6CAA6C;IAC7C,IAAI,UAAU,IAAI,MAAM,CAEvB;IAED;;;OAGG;IACH,KAAK,IAAI,IAAI;IAKb,kDAAkD;IAClD,iBAAiB,CAAC,MAAM,EAAE,sBAAsB,GAAG,SAAS,GAAG,IAAI;IAgBnE,iDAAiD;IACjD,iBAAiB,IAAI,IAAI;IAIzB;;;;OAIG;IACH,OAAO,CAAC,MAAM,EAAE,WAAW,GAAG,MAAM,IAAI;IAiBxC,OAAO,CAAC,OAAO;IAef,OAAO,CAAC,MAAM;CAQf"}
@@ -0,0 +1,86 @@
1
+ /**
2
+ * Comparison used when matching a field. Defaults to `==`.
3
+ *
4
+ * Relational operators (`>`, `>=`, `<`, `<=`) compare numerically — both sides are coerced with
5
+ * `Number(...)`, and the condition fails if either is not a finite number.
6
+ *
7
+ * @public
8
+ */
9
+ export type RowFieldMatchOp = '==' | '!=' | '>' | '>=' | '<' | '<=';
10
+ /**
11
+ * Match of a single field to an expected value.
12
+ *
13
+ * @public
14
+ */
15
+ export interface RowFieldMatch {
16
+ field: string;
17
+ /**
18
+ * Value to compare against. Use `null` with `==` / `!=` to mean empty
19
+ * (`null`, `undefined` or `''`) or not-empty respectively.
20
+ */
21
+ value: string | number | boolean | null;
22
+ /** Comparison to apply. Defaults to `==`. */
23
+ op?: RowFieldMatchOp;
24
+ }
25
+ /**
26
+ * Declarative rules for deciding whether a datasource row is "of interest" — most commonly
27
+ * whether it still needs attention, so a tab can be flagged while such rows exist.
28
+ *
29
+ * Simple form: `stateField` / `stateValue`, optionally narrowed with `and` (all AND'd).
30
+ * Flexible form: `anyOf`, an OR of AND-groups, which takes precedence when set.
31
+ *
32
+ * @public
33
+ */
34
+ export interface RowMatchCriteria {
35
+ /** Field holding a stable row identity, used to track rows across stream updates. */
36
+ rowIdField: string;
37
+ /**
38
+ * Primary field match. Required unless `anyOf` is set.
39
+ * Use `null` to match empty values (`null`, `undefined` or `''`).
40
+ */
41
+ stateField?: string;
42
+ stateValue?: string | number | boolean | null;
43
+ /** Comparison for `stateField` / `stateValue`. Defaults to `==`. */
44
+ stateOp?: RowFieldMatchOp;
45
+ /** Additional AND conditions on top of `stateField` / `stateValue`. Ignored when `anyOf` is set. */
46
+ and?: RowFieldMatch[];
47
+ /**
48
+ * OR of AND-groups. A row matches when every entry of any one group matches.
49
+ * When set, this is used instead of `stateField` / `stateValue` / `and`
50
+ * (those shorthand fields are ignored).
51
+ *
52
+ * @example
53
+ * ```ts
54
+ * // (PENDING and unassigned) OR (LIVE)
55
+ * anyOf: [
56
+ * [
57
+ * { field: 'ORDER_STATE', value: 'PENDING' },
58
+ * { field: 'ASSIGNED_TO', value: null },
59
+ * ],
60
+ * [{ field: 'ORDER_STATE', value: 'LIVE' }],
61
+ * ]
62
+ * ```
63
+ *
64
+ * @example
65
+ * ```ts
66
+ * // Quantity above 100, or a flagged exception
67
+ * anyOf: [
68
+ * [{ field: 'QUANTITY', op: '>', value: 100 }],
69
+ * [{ field: 'IS_EXCEPTION', value: true }],
70
+ * ]
71
+ * ```
72
+ */
73
+ anyOf?: RowFieldMatch[][];
74
+ /**
75
+ * Column to flash instead of the whole row, for grids where a full-width flash is too much.
76
+ * Only consulted by the cell class rules; leave unset to flash the entire row.
77
+ */
78
+ flashField?: string;
79
+ }
80
+ /**
81
+ * True when the row satisfies any resolved AND-group.
82
+ *
83
+ * @public
84
+ */
85
+ export declare function matchesRowCriteria(criteria: RowMatchCriteria, row: Record<string, unknown> | null | undefined): boolean;
86
+ //# sourceMappingURL=row-match.types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"row-match.types.d.ts","sourceRoot":"","sources":["../../../src/datasource/row-match.types.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,MAAM,MAAM,eAAe,GAAG,IAAI,GAAG,IAAI,GAAG,GAAG,GAAG,IAAI,GAAG,GAAG,GAAG,IAAI,CAAC;AAEpE;;;;GAIG;AACH,MAAM,WAAW,aAAa;IAC5B,KAAK,EAAE,MAAM,CAAC;IACd;;;OAGG;IACH,KAAK,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,IAAI,CAAC;IACxC,6CAA6C;IAC7C,EAAE,CAAC,EAAE,eAAe,CAAC;CACtB;AAED;;;;;;;;GAQG;AACH,MAAM,WAAW,gBAAgB;IAC/B,qFAAqF;IACrF,UAAU,EAAE,MAAM,CAAC;IACnB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,IAAI,CAAC;IAC9C,oEAAoE;IACpE,OAAO,CAAC,EAAE,eAAe,CAAC;IAC1B,oGAAoG;IACpG,GAAG,CAAC,EAAE,aAAa,EAAE,CAAC;IACtB;;;;;;;;;;;;;;;;;;;;;;;;;OAyBG;IACH,KAAK,CAAC,EAAE,aAAa,EAAE,EAAE,CAAC;IAC1B;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAoGD;;;;GAIG;AACH,wBAAgB,kBAAkB,CAChC,QAAQ,EAAE,gBAAgB,EAC1B,GAAG,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,SAAS,GAC9C,OAAO,CAOT"}
@@ -19,6 +19,20 @@ import type { ElementStyles } from '@microsoft/fast-element';
19
19
  * @public
20
20
  */
21
21
  export declare const agDragGhostShadowDomStyles: ElementStyles;
22
+ /**
23
+ * Flash for rows carrying the classes that `createRowMatchClassRules` and
24
+ * `createRowMatchCellClassRules` apply.
25
+ *
26
+ * These live in the grid's own stylesheet because AG Grid renders inside this shadow root, out of
27
+ * reach of an app's CSS. The phase comes from the document-level clock, which inherits through the
28
+ * shadow boundary, so a flashing row keeps step with the flashing tab that sent you looking for it.
29
+ *
30
+ * Any grid composition that does not include {@link foundationGridProStyles} needs to include this
31
+ * as well, otherwise its rows silently never flash.
32
+ *
33
+ * @public
34
+ */
35
+ export declare const rowMatchAlertStyles: ElementStyles;
22
36
  /**
23
37
  * The Grid Pro styles.
24
38
  * @public
@@ -1 +1 @@
1
- {"version":3,"file":"grid-pro.styles.d.ts","sourceRoot":"","sources":["../../src/grid-pro.styles.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAK7D;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,0BAA0B,eAStC,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,uBAAuB,EAAE,aAmErC,CAAC"}
1
+ {"version":3,"file":"grid-pro.styles.d.ts","sourceRoot":"","sources":["../../src/grid-pro.styles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAM7D;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,0BAA0B,eAStC,CAAC;AAEF;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,mBAAmB,eA+B/B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,uBAAuB,EAAE,aAoErC,CAAC"}
@@ -12,6 +12,7 @@ export * from './grid-pro.types';
12
12
  export * from './grid-pro';
13
13
  export * from './grid-pro-genesis-datasource';
14
14
  export * from './multicolumn-dropdown';
15
+ export * from './row-alert';
15
16
  export * from './state-persistence';
16
17
  export * from './status-bar-components';
17
18
  export * from './style';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,kBAAkB,CAAC;AACjC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,YAAY,CAAC;AAC3B,cAAc,mBAAmB,CAAC;AAClC,cAAc,wBAAwB,CAAC;AACvC,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,kBAAkB,CAAC;AACjC,cAAc,YAAY,CAAC;AAC3B,cAAc,+BAA+B,CAAC;AAC9C,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC;AACpC,cAAc,yBAAyB,CAAC;AACxC,cAAc,SAAS,CAAC;AACxB,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC;AACxB,cAAc,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,kBAAkB,CAAC;AACjC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,YAAY,CAAC;AAC3B,cAAc,mBAAmB,CAAC;AAClC,cAAc,wBAAwB,CAAC;AACvC,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,kBAAkB,CAAC;AACjC,cAAc,YAAY,CAAC;AAC3B,cAAc,+BAA+B,CAAC;AAC9C,cAAc,wBAAwB,CAAC;AACvC,cAAc,aAAa,CAAC;AAC5B,cAAc,qBAAqB,CAAC;AACpC,cAAc,yBAAyB,CAAC;AACxC,cAAc,SAAS,CAAC;AACxB,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC;AACxB,cAAc,iBAAiB,CAAC"}
@@ -80,15 +80,6 @@ export declare const GridPro: React.ForwardRefExoticComponent<
80
80
  >;
81
81
  export type GridProRef = GridProWC;
82
82
 
83
- export declare const GridProCell: React.ForwardRefExoticComponent<
84
- React.PropsWithChildren<
85
- Omit<PublicOf<GridProCellWC>, 'children' | 'style'> &
86
- HTMLWCProps & {
87
- }
88
- > & React.RefAttributes<GridProCellWC>
89
- >;
90
- export type GridProCellRef = GridProCellWC;
91
-
92
83
  export declare const DateEditor: React.ForwardRefExoticComponent<
93
84
  React.PropsWithChildren<
94
85
  Omit<PublicOf<DateEditorWC>, 'children' | 'style'> &
@@ -134,14 +125,14 @@ export declare const StringEditor: React.ForwardRefExoticComponent<
134
125
  >;
135
126
  export type StringEditorRef = StringEditorWC;
136
127
 
137
- export declare const GridProColumn: React.ForwardRefExoticComponent<
128
+ export declare const GridProCell: React.ForwardRefExoticComponent<
138
129
  React.PropsWithChildren<
139
- Omit<PublicOf<GridProColumnWC>, 'children' | 'style'> &
130
+ Omit<PublicOf<GridProCellWC>, 'children' | 'style'> &
140
131
  HTMLWCProps & {
141
132
  }
142
- > & React.RefAttributes<GridProColumnWC>
133
+ > & React.RefAttributes<GridProCellWC>
143
134
  >;
144
- export type GridProColumnRef = GridProColumnWC;
135
+ export type GridProCellRef = GridProCellWC;
145
136
 
146
137
  export declare const ActionRenderer: React.ForwardRefExoticComponent<
147
138
  React.PropsWithChildren<
@@ -215,6 +206,15 @@ export declare const AgTextRenderer: React.ForwardRefExoticComponent<
215
206
  >;
216
207
  export type AgTextRendererRef = AgTextRendererWC;
217
208
 
209
+ export declare const GridProColumn: React.ForwardRefExoticComponent<
210
+ React.PropsWithChildren<
211
+ Omit<PublicOf<GridProColumnWC>, 'children' | 'style'> &
212
+ HTMLWCProps & {
213
+ }
214
+ > & React.RefAttributes<GridProColumnWC>
215
+ >;
216
+ export type GridProColumnRef = GridProColumnWC;
217
+
218
218
  export declare const GridProClientSideDatasource: React.ForwardRefExoticComponent<
219
219
  React.PropsWithChildren<
220
220
  Omit<PublicOf<GridProClientSideDatasourceWC>, 'children' | 'style'> &
@@ -0,0 +1,3 @@
1
+ export * from './row-alert';
2
+ export * from './row-alert.types';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/row-alert/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,mBAAmB,CAAC"}
@@ -0,0 +1,132 @@
1
+ import type { RowMatchCriteria } from '../datasource/row-match.types';
2
+ import { StatePersistence } from '../state-persistence/state-persistence';
3
+ import { type RowAlertPreferences, type RowAlertPreset } from './row-alert.types';
4
+ /**
5
+ * The parts of AG Grid's context menu params this needs. Described structurally, like the class
6
+ * rules, because grid-pro serves two AG Grid generations whose own types are not interchangeable.
7
+ *
8
+ * @public
9
+ */
10
+ export interface RowAlertMenuParams {
11
+ defaultItems?: any[];
12
+ api?: RowAlertGridApi;
13
+ }
14
+ /**
15
+ * The part of AG Grid's api this needs, to bring rows already on screen in line with a change.
16
+ *
17
+ * @public
18
+ */
19
+ export interface RowAlertGridApi {
20
+ redrawRows?: () => void;
21
+ }
22
+ /**
23
+ * An entry in the presets menu, in the shape AG Grid's `MenuItemDef` expects.
24
+ *
25
+ * @public
26
+ */
27
+ export interface RowAlertMenuItem {
28
+ name: string;
29
+ checked?: boolean;
30
+ action?: () => void;
31
+ subMenu?: RowAlertMenuItem[];
32
+ }
33
+ /**
34
+ * Options for {@link createRowAlert}.
35
+ *
36
+ * @public
37
+ */
38
+ export interface RowAlertOptions {
39
+ /**
40
+ * Remembers the user's choices under this key, through the injected
41
+ * {@link (StatePersistence:interface)} — the same mechanism as column state, so an application
42
+ * that has
43
+ * moved persistence server-side gets these preferences per user too. Omit to keep changes for
44
+ * the lifetime of the page.
45
+ */
46
+ persistPreferencesKey?: string;
47
+ /** Element the CSS variables are set on. Defaults to the document, which every grid inherits. */
48
+ target?: HTMLElement;
49
+ /**
50
+ * Further CSS custom properties to hold the chosen color, for surfaces outside the grid that
51
+ * should flash in the same shade — `--tab-alert-color`, say, in an application whose tab
52
+ * headers alert alongside their rows.
53
+ */
54
+ mirrorColorTo?: readonly string[];
55
+ /** Overrides the colors offered in the menu. */
56
+ colorPresets?: readonly RowAlertPreset<string>[];
57
+ /** Overrides the flash rates offered in the menu. */
58
+ ratePresets?: readonly RowAlertPreset<number>[];
59
+ /** Heading the presets sit under in the context menu. Defaults to `Alert flash`. */
60
+ menuLabel?: string;
61
+ /** Starting preferences, before anything stored is loaded. */
62
+ preferences?: Partial<RowAlertPreferences>;
63
+ /** Supplied only by tests; otherwise resolved from the container. */
64
+ statePersistence?: StatePersistence;
65
+ }
66
+ /**
67
+ * Everything a grid needs to flash the rows meeting some criteria, and to let the user retune
68
+ * that flash.
69
+ *
70
+ * @public
71
+ */
72
+ export interface RowAlert {
73
+ /** Assign to `gridOptions.rowClassRules`. */
74
+ readonly rowClassRules: Record<string, (params: {
75
+ data?: unknown;
76
+ }) => boolean>;
77
+ /**
78
+ * Assign to `gridOptions.defaultColDef`, which is where cell class rules have to live — AG Grid
79
+ * has no grid-level equivalent. Needed even under row scope, since the user can switch.
80
+ */
81
+ readonly defaultColDef: {
82
+ cellClassRules: Record<string, (params: {
83
+ data?: unknown;
84
+ colDef: {
85
+ field?: string;
86
+ };
87
+ }) => boolean>;
88
+ };
89
+ /** The preferences in force right now. */
90
+ readonly preferences: RowAlertPreferences;
91
+ /**
92
+ * Drop-in for `gridOptions.getContextMenuItems`: the grid's own items, then the presets.
93
+ * Applications that already build a menu can call {@link RowAlert.createMenuItem} instead.
94
+ */
95
+ getContextMenuItems(params: RowAlertMenuParams): any[];
96
+ /** The presets submenu on its own, for composing into an existing context menu. */
97
+ createMenuItem(api?: RowAlertGridApi): RowAlertMenuItem;
98
+ /** Applies and persists a change. */
99
+ setPreferences(patch: Partial<RowAlertPreferences>): void;
100
+ /** Returns every preference to its default. */
101
+ reset(): void;
102
+ /** Called after any change, for frameworks that need to re-render. Returns an unsubscribe. */
103
+ subscribe(listener: (preferences: RowAlertPreferences) => void): () => void;
104
+ }
105
+ /**
106
+ * Builds the class rules that flash rows matching `criteria`, together with the context menu
107
+ * that lets a user recolor, retime, or narrow that flash to a single cell.
108
+ *
109
+ * The rules are created once and never replaced, because a grid backed by a Genesis datasource
110
+ * keeps the options it was created with — handing it new rules later would change nothing. Each
111
+ * rule instead asks, as it runs, whether its scope is the one currently selected, so switching
112
+ * target only needs the rows redrawn.
113
+ *
114
+ * ```ts
115
+ * const alert = createRowAlert(criteria, { persistPreferencesKey: 'orders.row-alert' });
116
+ * gridOptions = {
117
+ * rowClassRules: alert.rowClassRules,
118
+ * defaultColDef: alert.defaultColDef,
119
+ * getContextMenuItems: alert.getContextMenuItems,
120
+ * };
121
+ * ```
122
+ *
123
+ * Alerts sharing a `persistPreferencesKey` share their preferences, so a page of grids that each
124
+ * watch for something different still answers to one setting.
125
+ *
126
+ * Pairs with {@link DatasourceRowMatchTracker}: give both the same criteria and a tab can say
127
+ * there is work to do while the grid shows which rows it meant.
128
+ *
129
+ * @public
130
+ */
131
+ export declare function createRowAlert(criteria: RowMatchCriteria, options?: RowAlertOptions): RowAlert;
132
+ //# sourceMappingURL=row-alert.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"row-alert.d.ts","sourceRoot":"","sources":["../../../src/row-alert/row-alert.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AACtE,OAAO,EAAE,gBAAgB,EAAE,MAAM,wCAAwC,CAAC;AAE1E,OAAO,EAML,KAAK,mBAAmB,EACxB,KAAK,cAAc,EAEpB,MAAM,mBAAmB,CAAC;AAQ3B;;;;;GAKG;AACH,MAAM,WAAW,kBAAkB;IACjC,YAAY,CAAC,EAAE,GAAG,EAAE,CAAC;IACrB,GAAG,CAAC,EAAE,eAAe,CAAC;CACvB;AAED;;;;GAIG;AACH,MAAM,WAAW,eAAe;IAC9B,UAAU,CAAC,EAAE,MAAM,IAAI,CAAC;CACzB;AAED;;;;GAIG;AACH,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,OAAO,CAAC,EAAE,gBAAgB,EAAE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D,qCAAqC;IACrC,cAAc,CAAC,KAAK,EAAE,OAAO,CAAC,mBAAmB,CAAC,GAAG,IAAI,CAAC;IAC1D,+CAA+C;IAC/C,KAAK,IAAI,IAAI,CAAC;IACd,8FAA8F;IAC9F,SAAS,CAAC,QAAQ,EAAE,CAAC,WAAW,EAAE,mBAAmB,KAAK,IAAI,GAAG,MAAM,IAAI,CAAC;CAC7E;AAiHD;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,wBAAgB,cAAc,CAC5B,QAAQ,EAAE,gBAAgB,EAC1B,OAAO,GAAE,eAAoB,GAC5B,QAAQ,CAyGV"}
@@ -0,0 +1,62 @@
1
+ /**
2
+ * Whether an alerting row flashes in full, or only the column its criteria name.
3
+ *
4
+ * @public
5
+ */
6
+ export type RowAlertScope = 'row' | 'cell';
7
+ /**
8
+ * The parts of a row alert a user can change from the grid's context menu.
9
+ *
10
+ * @public
11
+ */
12
+ export interface RowAlertPreferences {
13
+ /** Any CSS color, including a `var()` reference to a design token. */
14
+ color: string;
15
+ /** How long one flash cycle takes. Shared by every alerting surface on the page. */
16
+ durationMs: number;
17
+ scope: RowAlertScope;
18
+ }
19
+ /**
20
+ * A labelled choice offered in the context menu.
21
+ *
22
+ * @public
23
+ */
24
+ export interface RowAlertPreset<TValue> {
25
+ id: string;
26
+ label: string;
27
+ value: TValue;
28
+ }
29
+ /**
30
+ * Colors offered by default. Each resolves a design token so the menu follows the host
31
+ * application's theme, falling back to a fixed color for design systems that lack the token.
32
+ *
33
+ * @public
34
+ */
35
+ export declare const defaultRowAlertColorPresets: readonly RowAlertPreset<string>[];
36
+ /**
37
+ * Flash rates offered by default.
38
+ *
39
+ * @public
40
+ */
41
+ export declare const defaultRowAlertRatePresets: readonly RowAlertPreset<number>[];
42
+ /**
43
+ * Flash targets offered by default. Cell scope only has an effect when the criteria name a
44
+ * `flashField`.
45
+ *
46
+ * @public
47
+ */
48
+ export declare const defaultRowAlertScopePresets: readonly RowAlertPreset<RowAlertScope>[];
49
+ /**
50
+ * Where preferences start before a user changes anything.
51
+ *
52
+ * @public
53
+ */
54
+ export declare const defaultRowAlertPreferences: RowAlertPreferences;
55
+ /**
56
+ * Discards anything unusable from stored preferences, so a hand-edited or outdated entry falls
57
+ * back to the default rather than leaving alerts invisible.
58
+ *
59
+ * @internal
60
+ */
61
+ export declare function normalizeRowAlertPreferences(value: Partial<RowAlertPreferences> | null | undefined): RowAlertPreferences;
62
+ //# sourceMappingURL=row-alert.types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"row-alert.types.d.ts","sourceRoot":"","sources":["../../../src/row-alert/row-alert.types.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,MAAM,MAAM,aAAa,GAAG,KAAK,GAAG,MAAM,CAAC;AAE3C;;;;GAIG;AACH,MAAM,WAAW,mBAAmB;IAClC,sEAAsE;IACtE,KAAK,EAAE,MAAM,CAAC;IACd,oFAAoF;IACpF,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,aAAa,CAAC;CACtB;AAED;;;;GAIG;AACH,MAAM,WAAW,cAAc,CAAC,MAAM;IACpC,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;CACf;AAED;;;;;GAKG;AACH,eAAO,MAAM,2BAA2B,EAAE,SAAS,cAAc,CAAC,MAAM,CAAC,EAM/D,CAAC;AAEX;;;;GAIG;AACH,eAAO,MAAM,0BAA0B,EAAE,SAAS,cAAc,CAAC,MAAM,CAAC,EAI9D,CAAC;AAEX;;;;;GAKG;AACH,eAAO,MAAM,2BAA2B,EAAE,SAAS,cAAc,CAAC,aAAa,CAAC,EAGtE,CAAC;AAEX;;;;GAIG;AACH,eAAO,MAAM,0BAA0B,EAAE,mBAIxC,CAAC;AAEF;;;;;GAKG;AACH,wBAAgB,4BAA4B,CAC1C,KAAK,EAAE,OAAO,CAAC,mBAAmB,CAAC,GAAG,IAAI,GAAG,SAAS,GACrD,mBAAmB,CAiBrB"}
@@ -1,5 +1,6 @@
1
1
  import { ColumnState } from '@ag-grid-community/core';
2
2
  import { KVStorage, Session } from '@genesislcap/foundation-comms';
3
+ import type { RowAlertPreferences } from '../row-alert/row-alert.types';
3
4
  import { StatePersistence } from './state-persistence';
4
5
  /**
5
6
  * Implementation for the KV Storage State Persistence interface.
@@ -18,5 +19,7 @@ export declare class KVStorageStatePersistence implements StatePersistence {
18
19
  saveFilterModel(persistFilterModelKey: string, filterModel: {
19
20
  [key: string]: any;
20
21
  }): Promise<void>;
22
+ getRowAlertPreferences(persistRowAlertKey: string): Promise<Partial<RowAlertPreferences>>;
23
+ saveRowAlertPreferences(persistRowAlertKey: string, preferences: RowAlertPreferences): Promise<void>;
21
24
  }
22
25
  //# sourceMappingURL=kv-state.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"kv-state.d.ts","sourceRoot":"","sources":["../../../src/state-persistence/kv-state.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AACtD,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,+BAA+B,CAAC;AAEnE,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAEvD;;;GAGG;AACH,qBAAa,yBAA0B,YAAW,gBAAgB;IACrD,SAAS,EAAE,SAAS,CAAC;IACvB,OAAO,EAAE,OAAO,CAAC;IAEpB,cAAc,CAAC,qBAAqB,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,EAAE,CAAC;IAarE,eAAe,CAAC,qBAAqB,EAAE,MAAM,EAAE,WAAW,EAAE,WAAW,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC;IASzF,iBAAiB,CAAC,qBAAqB,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;YAIvD,8BAA8B;IAsBtC,cAAc,CAAC,qBAAqB,EAAE,MAAM,GAAG,OAAO,CAAC;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,G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AAkB,EAAE,MAAM,EAC1B,WAAW,EAAE,mBAAmB,GAC/B,OAAO,CAAC,IAAI,CAAC;CAQjB"}
@@ -1,5 +1,6 @@
1
1
  import { ColumnState } from '@ag-grid-community/core';
2
2
  import { Session } from '@genesislcap/foundation-comms';
3
+ import type { RowAlertPreferences } from '../row-alert/row-alert.types';
3
4
  import type { StatePersistence } from './state-persistence';
4
5
  /**
5
6
  * Implementation for the Local Storage State Persistence interface.
@@ -16,5 +17,7 @@ export declare class LocalStorageStatePersistence implements StatePersistence {
16
17
  saveFilterModel(persistFilterModelKey: string, filterModel: {
17
18
  [key: string]: any;
18
19
  }): Promise<void>;
20
+ getRowAlertPreferences(persistRowAlertKey: string): Promise<Partial<RowAlertPreferences>>;
21
+ saveRowAlertPreferences(persistRowAlertKey: string, preferences: RowAlertPreferences): Promise<void>;
19
22
  }
20
23
  //# sourceMappingURL=local-state.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"local-state.d.ts","sourceRoot":"","sources":["../../../src/state-persistence/local-state.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AACtD,OAAO,EAAE,OAAO,EAAE,MAAM,+BAA+B,CAAC;AACxD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAM5D;;;GAGG;AACH,qBAAa,4BAA6B,YAAW,gBAAgB;IAC1D,OAAO,EAAE,OAAO,CAAC;IAEpB,cAAc,CAAC,qBAAqB,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,EAAE,CAAC;IAarE,eAAe,CAAC,qBAAqB,EAAE,MAAM,EAAE,WAAW,EAAE,WAAW,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC;IASzF,iBAAiB,CAAC,qBAAqB,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAS/D,cAAc,CAAC,qBAAqB,EAAE,MAAM,GAAG,OAAO,CAAC;QAAE,CAAC,GAAG,EAAE,MAAM,G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/B,OAAO,CAAC,IAAI,CAAC;CAQjB"}
@@ -1,4 +1,5 @@
1
1
  import { ColumnState } from '@ag-grid-community/core';
2
+ import type { RowAlertPreferences } from '../row-alert/row-alert.types';
2
3
  /**
3
4
  * Represents a state persistence and its capabilities.
4
5
  * Provides methods to set and get columns from the storage.
@@ -34,6 +35,21 @@ export interface StatePersistence {
34
35
  saveFilterModel(persistFilterModelKey: string, filterModel: {
35
36
  [key: string]: any;
36
37
  }): Promise<void>;
38
+ /**
39
+ * Returns the row alert preferences for the given key, or `undefined` when none are stored.
40
+ *
41
+ * Optional so implementations written before row alerts existed continue to satisfy this
42
+ * interface; row alerts fall back to their defaults when it is absent.
43
+ * @public
44
+ */
45
+ getRowAlertPreferences?(persistRowAlertKey: string): Promise<Partial<RowAlertPreferences>>;
46
+ /**
47
+ * Saves the row alert preferences for the given key.
48
+ *
49
+ * Optional — see {@link (StatePersistence:interface).getRowAlertPreferences}.
50
+ * @public
51
+ */
52
+ saveRowAlertPreferences?(persistRowAlertKey: string, preferences: RowAlertPreferences): Promise<void>;
37
53
  }
38
54
  /**
39
55
  * The DI token for the StatePersistence interface.
@@ -1 +1 @@
1
- {"version":3,"file":"state-persistence.d.ts","sourceRoot":"","sources":["../../../src/state-persistence/state-persistence.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAItD;;;;GAIG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;;OAGG;IACH,cAAc,CAAC,qBAAqB,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,EAAE,CAAC,CAAC;IACtE;;;OAGG;IACH,eAAe,CAAC,qBAAqB,EAAE,MAAM,EAAE,WAAW,EAAE,WAAW,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC1F;;;OAGG;IACH,iBAAiB,CAAC,qBAAqB,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAChE;;;OAGG;IACH,cAAc,CAAC,qB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,OAAO,CAAC,OAAO,CAAC,mBAAmB,CAAC,CAAC,CAAC;IAC3F;;;;;OAKG;IACH,uBAAuB,CAAC,CACtB,kBAAkB,EAAE,MAAM,EAC1B,WAAW,EAAE,mBAAmB,GAC/B,OAAO,CAAC,IAAI,CAAC,CAAC;CAClB;AAED;;;GAGG;AACH,eAAO,MAAM,gBAAgB,wEAE5B,CAAC"}
@@ -3,4 +3,7 @@ export * from './base.types';
3
3
  export * from './client-side.datasource';
4
4
  export * from './error-handler.dialog';
5
5
  export * from './datasource.types';
6
+ export * from './row-match.types';
7
+ export * from './row-match.tracker';
8
+ export * from './row-match.classes';
6
9
  export * from './server-side.datasource';