@neo4j-ndl/react 4.18.6 → 4.18.7

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/lib/cjs/_generated/style-rules/index.js +7 -1
  2. package/lib/cjs/_generated/style-rules/index.js.map +1 -1
  3. package/lib/cjs/_generated/style-rules/literal-schemas.js +32 -1
  4. package/lib/cjs/_generated/style-rules/literal-schemas.js.map +1 -1
  5. package/lib/cjs/_generated/style-rules/range-utils.js +46 -0
  6. package/lib/cjs/_generated/style-rules/range-utils.js.map +1 -0
  7. package/lib/cjs/data-grid/stories/datagrid-rule-based-styling-datetime.story.js +26 -8
  8. package/lib/cjs/data-grid/stories/datagrid-rule-based-styling-datetime.story.js.map +1 -1
  9. package/lib/cjs/data-grid/style-rules/evaluate.js +60 -55
  10. package/lib/cjs/data-grid/style-rules/evaluate.js.map +1 -1
  11. package/lib/cjs/data-grid/style-rules/index.js +2 -1
  12. package/lib/cjs/data-grid/style-rules/index.js.map +1 -1
  13. package/lib/cjs/data-grid/style-rules/types.js +20 -14
  14. package/lib/cjs/data-grid/style-rules/types.js.map +1 -1
  15. package/lib/esm/_generated/style-rules/index.js +2 -1
  16. package/lib/esm/_generated/style-rules/index.js.map +1 -1
  17. package/lib/esm/_generated/style-rules/literal-schemas.js +28 -0
  18. package/lib/esm/_generated/style-rules/literal-schemas.js.map +1 -1
  19. package/lib/esm/_generated/style-rules/range-utils.js +43 -0
  20. package/lib/esm/_generated/style-rules/range-utils.js.map +1 -0
  21. package/lib/esm/data-grid/stories/datagrid-rule-based-styling-datetime.story.js +26 -8
  22. package/lib/esm/data-grid/stories/datagrid-rule-based-styling-datetime.story.js.map +1 -1
  23. package/lib/esm/data-grid/style-rules/evaluate.js +61 -56
  24. package/lib/esm/data-grid/style-rules/evaluate.js.map +1 -1
  25. package/lib/esm/data-grid/style-rules/index.js +1 -1
  26. package/lib/esm/data-grid/style-rules/index.js.map +1 -1
  27. package/lib/esm/data-grid/style-rules/types.js +20 -14
  28. package/lib/esm/data-grid/style-rules/types.js.map +1 -1
  29. package/lib/types/_generated/style-rules/index.d.ts +3 -2
  30. package/lib/types/_generated/style-rules/index.d.ts.map +1 -1
  31. package/lib/types/_generated/style-rules/literal-schemas.d.ts +20 -0
  32. package/lib/types/_generated/style-rules/literal-schemas.d.ts.map +1 -1
  33. package/lib/types/_generated/style-rules/range-utils.d.ts +26 -0
  34. package/lib/types/_generated/style-rules/range-utils.d.ts.map +1 -0
  35. package/lib/types/data-grid/stories/datagrid-rule-based-styling-datetime.story.d.ts.map +1 -1
  36. package/lib/types/data-grid/style-rules/evaluate.d.ts.map +1 -1
  37. package/lib/types/data-grid/style-rules/index.d.ts +2 -2
  38. package/lib/types/data-grid/style-rules/index.d.ts.map +1 -1
  39. package/lib/types/data-grid/style-rules/types.d.ts +141 -28
  40. package/lib/types/data-grid/style-rules/types.d.ts.map +1 -1
  41. package/package.json +1 -1
  42. package/skills/ndl-react/components/data-grid.md +27 -9
@@ -80,4 +80,24 @@ export declare const TimeLiteralSchema: z.ZodObject<{
80
80
  time: z.ZodString;
81
81
  }, z.core.$strip>;
82
82
  export type TimeLiteral = z.infer<typeof TimeLiteralSchema>;
83
+ /** Returns whether a value is a `{ datetime: string }` wrapper. Does not validate the string. */
84
+ export declare function isDatetimeLiteral(value: unknown): value is DatetimeLiteral;
85
+ /** Returns whether a value is a `{ localdatetime: string }` wrapper. Does not validate the string. */
86
+ export declare function isLocalDatetimeLiteral(value: unknown): value is LocalDatetimeLiteral;
87
+ /** Returns whether a value is a `{ time: string }` wrapper. Does not validate the string. */
88
+ export declare function isTimeLiteral(value: unknown): value is TimeLiteral;
89
+ /**
90
+ * A continuous, orderable literal that can be used as a range boundary.
91
+ * Temporal literals resolve to numbers before range interpolation.
92
+ */
93
+ export declare const RangeLiteralSchema: z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
94
+ bigint: z.ZodString;
95
+ }, z.core.$strip>]>, z.ZodObject<{
96
+ datetime: z.ZodString;
97
+ }, z.core.$strip>, z.ZodObject<{
98
+ localdatetime: z.ZodString;
99
+ }, z.core.$strip>, z.ZodObject<{
100
+ time: z.ZodString;
101
+ }, z.core.$strip>]>;
102
+ export type RangeLiteral = z.infer<typeof RangeLiteralSchema>;
83
103
  //# sourceMappingURL=literal-schemas.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"literal-schemas.d.ts","sourceRoot":"","sources":["../../../../src/_generated/style-rules/literal-schemas.ts"],"names":[],"mappings":"AAMA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAQxB;;;GAGG;AACH,eAAO,MAAM,mBAAmB;;iBAI9B,CAAC;AACH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEhE,4EAA4E;AAC5E,eAAO,MAAM,oBAAoB;;mBAI/B,CAAC;AACH,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAElE;;;;;;;;;GASG;AACH,eAAO,MAAM,qBAAqB;;iBAKhC,CAAC;AACH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAEpE;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,0BAA0B;;iBAKrC,CAAC;AACH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BAA0B,CAAC,CAAC;AAE9E;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,iBAAiB;;iBAK5B,CAAC;AACH,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC"}
1
+ {"version":3,"file":"literal-schemas.d.ts","sourceRoot":"","sources":["../../../../src/_generated/style-rules/literal-schemas.ts"],"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0 +1,26 @@
1
+ /**
2
+ *
3
+ * Copyright (c) "Neo4j"
4
+ * Neo4j Sweden AB [http://neo4j.com]
5
+ *
6
+ * This file is part of Neo4j.
7
+ *
8
+ * Neo4j is free software: you can redistribute it and/or modify
9
+ * it under the terms of the GNU General Public License as published by
10
+ * the Free Software Foundation, either version 3 of the License, or
11
+ * (at your option) any later version.
12
+ *
13
+ * This program is distributed in the hope that it will be useful,
14
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
15
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
+ * GNU General Public License for more details.
17
+ *
18
+ * You should have received a copy of the GNU General Public License
19
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
20
+ */
21
+
22
+ import type { RangeLiteral } from './literal-schemas';
23
+ import { type NumericValue } from './numeric-utils';
24
+ /** Resolves a range literal to the numeric representation used for interpolation. */
25
+ export declare function resolveRangeLiteral(value: RangeLiteral): NumericValue | null;
26
+ //# sourceMappingURL=range-utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"range-utils.d.ts","sourceRoot":"","sources":["../../../../src/_generated/style-rules/range-utils.ts"],"names":[],"mappings":"AAgCA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AACtD,OAAO,EAAE,KAAK,YAAY,EAAyB,MAAM,iBAAiB,CAAC;AAE3E,qFAAqF;AACrF,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,YAAY,GAAG,YAAY,GAAG,IAAI,CAa5E"}
@@ -1 +1 @@
1
- {"version":3,"file":"datagrid-rule-based-styling-datetime.story.d.ts","sourceRoot":"","sources":["../../../../src/data-grid/stories/datagrid-rule-based-styling-datetime.story.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,yCAAyC,CAAC;AA6NjD,QAAA,MAAM,SAAS,+CAmFd,CAAC;AAEF,eAAe,SAAS,CAAC"}
1
+ {"version":3,"file":"datagrid-rule-based-styling-datetime.story.d.ts","sourceRoot":"","sources":["../../../../src/data-grid/stories/datagrid-rule-based-styling-datetime.story.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,yCAAyC,CAAC;AA+OjD,QAAA,MAAM,SAAS,+CAmFd,CAAC;AAEF,eAAe,SAAS,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"evaluate.d.ts","sourceRoot":"","sources":["../../../../src/data-grid/style-rules/evaluate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAiBH,OAAO,EAKL,KAAK,iBAAiB,EAGtB,KAAK,gCAAgC,EAGtC,MAAM,SAAS,CAAC;AAgZjB,MAAM,MAAM,sBAAsB,GAAG;IACnC,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,aAAa,GAAG,SAAS,CAAC,CAAC;CAC7D,CAAC;AAKF;;;;;GAKG;AACH,wBAAgB,wBAAwB,CACtC,KAAK,EAAE,iBAAiB,EAAE,EAC1B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAChC,UAAU,CAAC,EAAE,gCAAgC,GAC5C,sBAAsB,CAsExB;AAED;;;;;;;;GAQG;AACH,wBAAgB,0BAA0B,CACxC,KAAK,EAAE,iBAAiB,EAAE,EAC1B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAChC,QAAQ,EAAE,MAAM,EAChB,UAAU,CAAC,EAAE,gCAAgC,GAC5C,KAAK,CAAC,aAAa,GAAG,SAAS,CAGjC"}
1
+ {"version":3,"file":"evaluate.d.ts","sourceRoot":"","sources":["../../../../src/data-grid/style-rules/evaluate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAqBH,OAAO,EAGL,KAAK,iBAAiB,EAGtB,KAAK,gCAAgC,EAEtC,MAAM,SAAS,CAAC;AA0ZjB,MAAM,MAAM,sBAAsB,GAAG;IACnC,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,aAAa,GAAG,SAAS,CAAC,CAAC;CAC7D,CAAC;AAKF;;;;;GAKG;AACH,wBAAgB,wBAAwB,CACtC,KAAK,EAAE,iBAAiB,EAAE,EAC1B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAChC,UAAU,CAAC,EAAE,gCAAgC,GAC5C,sBAAsB,CAsExB;AAED;;;;;;;;GAQG;AACH,wBAAgB,0BAA0B,CACxC,KAAK,EAAE,iBAAiB,EAAE,EAC1B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAChC,QAAQ,EAAE,MAAM,EAChB,UAAU,CAAC,EAAE,gCAAgC,GAC5C,KAAK,CAAC,aAAa,GAAG,SAAS,CAGjC"}
@@ -21,6 +21,6 @@
21
21
  export { evaluateDataGridStyleRules } from './evaluate';
22
22
  export { useDataGridCellStyle } from './hooks';
23
23
  export { isDataGridStyleRule } from './types';
24
- export { DataGridBigintLiteralSchema, DataGridCellStyleSchema, DataGridColorRangeSchema, DataGridColumnRefSchema, DataGridDatetimeLiteralSchema, DataGridDisableableColorSchema, DataGridStyleRuleLiteralSchema, DataGridStyleRuleOperandSchema, DataGridStyleRuleSchema, DataGridStyleRuleWhereSchema, DataGridTimeLiteralSchema, DataGridLocalDatetimeLiteralSchema, DataGridNumericLiteralSchema, } from './types';
25
- export type { DataGridBigintLiteral, DataGridCellStyle, DataGridColorRange, DataGridColumnRef, DataGridDatetimeLiteral, DataGridDisableableColor, DataGridStyleRuleLiteral, DataGridStyleRuleOperand, DataGridStyleRule, DataGridStyleRuleWhere, DataGridStyleRuleValueConverter, DataGridStyleRuleValueConverters, DataGridTimeLiteral, DataGridLocalDatetimeLiteral, DataGridNumericLiteral, } from './types';
24
+ export { DataGridBigintLiteralSchema, DataGridCellStyleSchema, DataGridColorRangeSchema, DataGridColumnRefSchema, DataGridDatetimeLiteralSchema, DataGridDisableableColorSchema, DataGridStyleRuleLiteralSchema, DataGridStyleRuleOperandSchema, DataGridStyleRuleSchema, DataGridStyleRuleWhereSchema, DataGridTimeLiteralSchema, DataGridLocalDatetimeLiteralSchema, DataGridNumericLiteralSchema, DataGridRangeLiteralSchema, } from './types';
25
+ export type { DataGridBigintLiteral, DataGridCellStyle, DataGridColorRange, DataGridColumnRef, DataGridDatetimeLiteral, DataGridDisableableColor, DataGridStyleRuleLiteral, DataGridStyleRuleOperand, DataGridStyleRule, DataGridStyleRuleWhere, DataGridStyleRuleValueConverter, DataGridStyleRuleValueConverters, DataGridTimeLiteral, DataGridLocalDatetimeLiteral, DataGridNumericLiteral, DataGridRangeLiteral, } from './types';
26
26
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/data-grid/style-rules/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,0BAA0B,EAAE,MAAM,YAAY,CAAC;AACxD,OAAO,EAAE,oBAAoB,EAAE,MAAM,SAAS,CAAC;AAC/C,OAAO,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AAE9C,OAAO,EACL,2BAA2B,EAC3B,uBAAuB,EACvB,wBAAwB,EACxB,uBAAuB,EACvB,6BAA6B,EAC7B,8BAA8B,EAC9B,8BAA8B,EAC9B,8BAA8B,EAC9B,uBAAuB,EACvB,4BAA4B,EAC5B,yBAAyB,EACzB,kCAAkC,EAClC,4BAA4B,GAC7B,MAAM,SAAS,CAAC;AACjB,YAAY,EACV,qBAAqB,EACrB,iBAAiB,EACjB,kBAAkB,EAClB,iBAAiB,EACjB,uBAAuB,EACvB,wBAAwB,EACxB,wBAAwB,EACxB,wBAAwB,EACxB,iBAAiB,EACjB,sBAAsB,EACtB,+BAA+B,EAC/B,gCAAgC,EAChC,mBAAmB,EACnB,4BAA4B,EAC5B,sBAAsB,GACvB,MAAM,SAAS,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/data-grid/style-rules/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,0BAA0B,EAAE,MAAM,YAAY,CAAC;AACxD,OAAO,EAAE,oBAAoB,EAAE,MAAM,SAAS,CAAC;AAC/C,OAAO,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AAE9C,OAAO,EACL,2BAA2B,EAC3B,uBAAuB,EACvB,wBAAwB,EACxB,uBAAuB,EACvB,6BAA6B,EAC7B,8BAA8B,EAC9B,8BAA8B,EAC9B,8BAA8B,EAC9B,uBAAuB,EACvB,4BAA4B,EAC5B,yBAAyB,EACzB,kCAAkC,EAClC,4BAA4B,EAC5B,0BAA0B,GAC3B,MAAM,SAAS,CAAC;AACjB,YAAY,EACV,qBAAqB,EACrB,iBAAiB,EACjB,kBAAkB,EAClB,iBAAiB,EACjB,uBAAuB,EACvB,wBAAwB,EACxB,wBAAwB,EACxB,wBAAwB,EACxB,iBAAiB,EACjB,sBAAsB,EACtB,+BAA+B,EAC/B,gCAAgC,EAChC,mBAAmB,EACnB,4BAA4B,EAC5B,sBAAsB,EACtB,oBAAoB,GACrB,MAAM,SAAS,CAAC"}
@@ -19,10 +19,19 @@
19
19
  * along with this program. If not, see <http://www.gnu.org/licenses/>.
20
20
  */
21
21
  import { z } from 'zod';
22
- /** A literal that can appear as an operand in a style-rule where clause. */
22
+ /**
23
+ * A literal value used in style-rule where clauses, converter return values,
24
+ * and cell data. Temporal wrappers resolve to numbers at evaluation time.
25
+ */
23
26
  export declare const DataGridStyleRuleLiteralSchema: z.ZodUnion<readonly [z.ZodString, z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
24
27
  bigint: z.ZodString;
25
- }, z.core.$strip>]>, z.ZodBoolean, z.ZodNull]>;
28
+ }, z.core.$strip>]>, z.ZodBoolean, z.ZodNull, z.ZodObject<{
29
+ datetime: z.ZodString;
30
+ }, z.core.$strip>, z.ZodObject<{
31
+ localdatetime: z.ZodString;
32
+ }, z.core.$strip>, z.ZodObject<{
33
+ time: z.ZodString;
34
+ }, z.core.$strip>]>;
26
35
  export type DataGridStyleRuleLiteral = z.infer<typeof DataGridStyleRuleLiteralSchema>;
27
36
  /** A JSON-safe bigint literal represented by a signed decimal string. */
28
37
  export declare const DataGridBigintLiteralSchema: z.ZodObject<{
@@ -34,6 +43,17 @@ export declare const DataGridNumericLiteralSchema: z.ZodUnion<readonly [z.ZodNum
34
43
  bigint: z.ZodString;
35
44
  }, z.core.$strip>]>;
36
45
  export type DataGridNumericLiteral = z.infer<typeof DataGridNumericLiteralSchema>;
46
+ /** A numeric, datetime, localdatetime, or time literal used as a range boundary. */
47
+ export declare const DataGridRangeLiteralSchema: z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
48
+ bigint: z.ZodString;
49
+ }, z.core.$strip>]>, z.ZodObject<{
50
+ datetime: z.ZodString;
51
+ }, z.core.$strip>, z.ZodObject<{
52
+ localdatetime: z.ZodString;
53
+ }, z.core.$strip>, z.ZodObject<{
54
+ time: z.ZodString;
55
+ }, z.core.$strip>]>;
56
+ export type DataGridRangeLiteral = z.infer<typeof DataGridRangeLiteralSchema>;
37
57
  /** A reference to a column whose cell value is resolved at evaluation time. */
38
58
  export declare const DataGridColumnRefSchema: z.ZodObject<{
39
59
  column: z.ZodString;
@@ -82,19 +102,19 @@ export declare const DataGridTimeLiteralSchema: z.ZodObject<{
82
102
  time: z.ZodString;
83
103
  }, z.core.$strip>;
84
104
  export type DataGridTimeLiteral = z.infer<typeof DataGridTimeLiteralSchema>;
85
- /** An operand in a style-rule where clause -- either a literal value, a datetime literal, a localdatetime literal, a time literal, or a column reference. */
105
+ /** An operand in a style-rule where clause -- either a literal value or a column reference. */
86
106
  export declare const DataGridStyleRuleOperandSchema: z.ZodUnion<readonly [z.ZodObject<{
87
107
  column: z.ZodString;
88
- }, z.core.$strip>, z.ZodObject<{
108
+ }, z.core.$strip>, z.ZodUnion<readonly [z.ZodString, z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
109
+ bigint: z.ZodString;
110
+ }, z.core.$strip>]>, z.ZodBoolean, z.ZodNull, z.ZodObject<{
89
111
  datetime: z.ZodString;
90
112
  }, z.core.$strip>, z.ZodObject<{
91
113
  localdatetime: z.ZodString;
92
114
  }, z.core.$strip>, z.ZodObject<{
93
115
  time: z.ZodString;
94
- }, z.core.$strip>, z.ZodUnion<readonly [z.ZodString, z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
95
- bigint: z.ZodString;
96
- }, z.core.$strip>]>, z.ZodBoolean, z.ZodNull]>]>;
97
- export type DataGridStyleRuleOperand = DataGridColumnRef | DataGridDatetimeLiteral | DataGridLocalDatetimeLiteral | DataGridTimeLiteral | DataGridStyleRuleLiteral;
116
+ }, z.core.$strip>]>]>;
117
+ export type DataGridStyleRuleOperand = z.infer<typeof DataGridStyleRuleOperandSchema>;
98
118
  /**
99
119
  * Recursive WHERE clause for conditional expressions.
100
120
  * Inspired by the graph visualization style rule system but adapted for tabular data.
@@ -129,23 +149,42 @@ export type DataGridStyleRuleWhere = {
129
149
  };
130
150
  export declare const DataGridStyleRuleWhereSchema: z.ZodType<DataGridStyleRuleWhere>;
131
151
  /**
132
- * Gradient coloring based on a continuous numeric column value.
152
+ * Gradient coloring based on a continuous orderable column value.
133
153
  * Colors should be hex strings (#rrggbb).
134
- * If the column value is missing or non-numeric, the colorRange is ignored.
154
+ * Temporal range boundaries resolve to numbers before interpolation.
155
+ * If the column value is missing or non-orderable, the colorRange is ignored.
135
156
  */
136
157
  export declare const DataGridColorRangeSchema: z.ZodObject<{
137
158
  isDisabled: z.ZodOptional<z.ZodBoolean>;
138
159
  maxColor: z.ZodString;
139
- maxValue: z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
160
+ maxValue: z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
140
161
  bigint: z.ZodString;
162
+ }, z.core.$strip>]>, z.ZodObject<{
163
+ datetime: z.ZodString;
164
+ }, z.core.$strip>, z.ZodObject<{
165
+ localdatetime: z.ZodString;
166
+ }, z.core.$strip>, z.ZodObject<{
167
+ time: z.ZodString;
141
168
  }, z.core.$strip>]>;
142
169
  midColor: z.ZodOptional<z.ZodString>;
143
- midValue: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
170
+ midValue: z.ZodOptional<z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
144
171
  bigint: z.ZodString;
172
+ }, z.core.$strip>]>, z.ZodObject<{
173
+ datetime: z.ZodString;
174
+ }, z.core.$strip>, z.ZodObject<{
175
+ localdatetime: z.ZodString;
176
+ }, z.core.$strip>, z.ZodObject<{
177
+ time: z.ZodString;
145
178
  }, z.core.$strip>]>>;
146
179
  minColor: z.ZodString;
147
- minValue: z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
180
+ minValue: z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
148
181
  bigint: z.ZodString;
182
+ }, z.core.$strip>]>, z.ZodObject<{
183
+ datetime: z.ZodString;
184
+ }, z.core.$strip>, z.ZodObject<{
185
+ localdatetime: z.ZodString;
186
+ }, z.core.$strip>, z.ZodObject<{
187
+ time: z.ZodString;
149
188
  }, z.core.$strip>]>;
150
189
  onColumn: z.ZodString;
151
190
  }, z.core.$strip>;
@@ -165,16 +204,34 @@ export declare const DataGridCellStyleSchema: z.ZodObject<{
165
204
  colorRange: z.ZodOptional<z.ZodObject<{
166
205
  isDisabled: z.ZodOptional<z.ZodBoolean>;
167
206
  maxColor: z.ZodString;
168
- maxValue: z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
207
+ maxValue: z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
169
208
  bigint: z.ZodString;
209
+ }, z.core.$strip>]>, z.ZodObject<{
210
+ datetime: z.ZodString;
211
+ }, z.core.$strip>, z.ZodObject<{
212
+ localdatetime: z.ZodString;
213
+ }, z.core.$strip>, z.ZodObject<{
214
+ time: z.ZodString;
170
215
  }, z.core.$strip>]>;
171
216
  midColor: z.ZodOptional<z.ZodString>;
172
- midValue: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
217
+ midValue: z.ZodOptional<z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
173
218
  bigint: z.ZodString;
219
+ }, z.core.$strip>]>, z.ZodObject<{
220
+ datetime: z.ZodString;
221
+ }, z.core.$strip>, z.ZodObject<{
222
+ localdatetime: z.ZodString;
223
+ }, z.core.$strip>, z.ZodObject<{
224
+ time: z.ZodString;
174
225
  }, z.core.$strip>]>>;
175
226
  minColor: z.ZodString;
176
- minValue: z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
227
+ minValue: z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
177
228
  bigint: z.ZodString;
229
+ }, z.core.$strip>]>, z.ZodObject<{
230
+ datetime: z.ZodString;
231
+ }, z.core.$strip>, z.ZodObject<{
232
+ localdatetime: z.ZodString;
233
+ }, z.core.$strip>, z.ZodObject<{
234
+ time: z.ZodString;
178
235
  }, z.core.$strip>]>;
179
236
  onColumn: z.ZodString;
180
237
  }, z.core.$strip>>;
@@ -185,16 +242,34 @@ export declare const DataGridCellStyleSchema: z.ZodObject<{
185
242
  textColorRange: z.ZodOptional<z.ZodObject<{
186
243
  isDisabled: z.ZodOptional<z.ZodBoolean>;
187
244
  maxColor: z.ZodString;
188
- maxValue: z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
245
+ maxValue: z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
189
246
  bigint: z.ZodString;
247
+ }, z.core.$strip>]>, z.ZodObject<{
248
+ datetime: z.ZodString;
249
+ }, z.core.$strip>, z.ZodObject<{
250
+ localdatetime: z.ZodString;
251
+ }, z.core.$strip>, z.ZodObject<{
252
+ time: z.ZodString;
190
253
  }, z.core.$strip>]>;
191
254
  midColor: z.ZodOptional<z.ZodString>;
192
- midValue: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
255
+ midValue: z.ZodOptional<z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
193
256
  bigint: z.ZodString;
257
+ }, z.core.$strip>]>, z.ZodObject<{
258
+ datetime: z.ZodString;
259
+ }, z.core.$strip>, z.ZodObject<{
260
+ localdatetime: z.ZodString;
261
+ }, z.core.$strip>, z.ZodObject<{
262
+ time: z.ZodString;
194
263
  }, z.core.$strip>]>>;
195
264
  minColor: z.ZodString;
196
- minValue: z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
265
+ minValue: z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
197
266
  bigint: z.ZodString;
267
+ }, z.core.$strip>]>, z.ZodObject<{
268
+ datetime: z.ZodString;
269
+ }, z.core.$strip>, z.ZodObject<{
270
+ localdatetime: z.ZodString;
271
+ }, z.core.$strip>, z.ZodObject<{
272
+ time: z.ZodString;
198
273
  }, z.core.$strip>]>;
199
274
  onColumn: z.ZodString;
200
275
  }, z.core.$strip>>;
@@ -206,9 +281,11 @@ export type DataGridCellStyle = z.infer<typeof DataGridCellStyleSchema>;
206
281
  * and color-range interpolation.
207
282
  *
208
283
  * The function receives the raw cell value (`unknown`) and must return a scalar
209
- * (`string | number | bigint | { bigint: string } | boolean | null`). Return
210
- * `null` or `undefined` to signal that the value is missing or cannot be
211
- * represented.
284
+ * (`string | number | bigint | { bigint: string } | boolean | null`) or a
285
+ * temporal wrapper (`{ datetime: string }`, `{ localdatetime: string }`,
286
+ * `{ time: string }`). The engine parses temporal wrappers to milliseconds.
287
+ * Return `null` or `undefined` to signal that the value is missing or cannot
288
+ * be represented.
212
289
  *
213
290
  * Note: converter functions are TypeScript-only — they cannot be serialized as
214
291
  * JSON, so no Zod schema is provided.
@@ -240,16 +317,34 @@ export declare const DataGridStyleRuleSchema: z.ZodObject<{
240
317
  colorRange: z.ZodOptional<z.ZodObject<{
241
318
  isDisabled: z.ZodOptional<z.ZodBoolean>;
242
319
  maxColor: z.ZodString;
243
- maxValue: z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
320
+ maxValue: z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
244
321
  bigint: z.ZodString;
322
+ }, z.core.$strip>]>, z.ZodObject<{
323
+ datetime: z.ZodString;
324
+ }, z.core.$strip>, z.ZodObject<{
325
+ localdatetime: z.ZodString;
326
+ }, z.core.$strip>, z.ZodObject<{
327
+ time: z.ZodString;
245
328
  }, z.core.$strip>]>;
246
329
  midColor: z.ZodOptional<z.ZodString>;
247
- midValue: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
330
+ midValue: z.ZodOptional<z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
248
331
  bigint: z.ZodString;
332
+ }, z.core.$strip>]>, z.ZodObject<{
333
+ datetime: z.ZodString;
334
+ }, z.core.$strip>, z.ZodObject<{
335
+ localdatetime: z.ZodString;
336
+ }, z.core.$strip>, z.ZodObject<{
337
+ time: z.ZodString;
249
338
  }, z.core.$strip>]>>;
250
339
  minColor: z.ZodString;
251
- minValue: z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
340
+ minValue: z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
252
341
  bigint: z.ZodString;
342
+ }, z.core.$strip>]>, z.ZodObject<{
343
+ datetime: z.ZodString;
344
+ }, z.core.$strip>, z.ZodObject<{
345
+ localdatetime: z.ZodString;
346
+ }, z.core.$strip>, z.ZodObject<{
347
+ time: z.ZodString;
253
348
  }, z.core.$strip>]>;
254
349
  onColumn: z.ZodString;
255
350
  }, z.core.$strip>>;
@@ -260,16 +355,34 @@ export declare const DataGridStyleRuleSchema: z.ZodObject<{
260
355
  textColorRange: z.ZodOptional<z.ZodObject<{
261
356
  isDisabled: z.ZodOptional<z.ZodBoolean>;
262
357
  maxColor: z.ZodString;
263
- maxValue: z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
358
+ maxValue: z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
264
359
  bigint: z.ZodString;
360
+ }, z.core.$strip>]>, z.ZodObject<{
361
+ datetime: z.ZodString;
362
+ }, z.core.$strip>, z.ZodObject<{
363
+ localdatetime: z.ZodString;
364
+ }, z.core.$strip>, z.ZodObject<{
365
+ time: z.ZodString;
265
366
  }, z.core.$strip>]>;
266
367
  midColor: z.ZodOptional<z.ZodString>;
267
- midValue: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
368
+ midValue: z.ZodOptional<z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
268
369
  bigint: z.ZodString;
370
+ }, z.core.$strip>]>, z.ZodObject<{
371
+ datetime: z.ZodString;
372
+ }, z.core.$strip>, z.ZodObject<{
373
+ localdatetime: z.ZodString;
374
+ }, z.core.$strip>, z.ZodObject<{
375
+ time: z.ZodString;
269
376
  }, z.core.$strip>]>>;
270
377
  minColor: z.ZodString;
271
- minValue: z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
378
+ minValue: z.ZodUnion<readonly [z.ZodUnion<readonly [z.ZodNumber, z.ZodBigInt, z.ZodObject<{
272
379
  bigint: z.ZodString;
380
+ }, z.core.$strip>]>, z.ZodObject<{
381
+ datetime: z.ZodString;
382
+ }, z.core.$strip>, z.ZodObject<{
383
+ localdatetime: z.ZodString;
384
+ }, z.core.$strip>, z.ZodObject<{
385
+ time: z.ZodString;
273
386
  }, z.core.$strip>]>;
274
387
  onColumn: z.ZodString;
275
388
  }, z.core.$strip>>;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/data-grid/style-rules/types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAexB,4EAA4E;AAC5E,eAAO,MAAM,8BAA8B;;8CAKzC,CAAC;AACH,MAAM,MAAM,wBAAwB,GAAG,CAAC,CAAC,KAAK,CAC5C,OAAO,8BAA8B,CACtC,CAAC;AAEF,yEAAyE;AACzE,eAAO,MAAM,2BAA2B;;iBAAsB,CAAC;AAC/D,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,2BAA2B,CAAC,CAAC;AAEhF,4DAA4D;AAC5D,eAAO,MAAM,4BAA4B;;mBAAuB,CAAC;AACjE,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAC1C,OAAO,4BAA4B,CACpC,CAAC;AAEF,+EAA+E;AAC/E,eAAO,MAAM,uBAAuB;;iBAAmC,CAAC;AACxE,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAExE;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,6BAA6B;;iBAAwB,CAAC;AACnE,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAC3C,OAAO,6BAA6B,CACrC,CAAC;AAE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E1E,yCAAyC;AACzC,eAAO,MAAM,8BAA8B;;;iBAKzC,CAAC;AACH,MAAM,MAAM,wBAAwB,GAAG,CAAC,CAAC,KAAK,CAC5C,OAAO,8BAA8B,CACtC,CAAC;AAEF,sEAAsE;AACtE,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBASlC,CAAC;AACH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAQxE;;;;;;;;;;;;;;GAcG;AACH,MAAM,MAAM,+BAA+B,GAAG,CAC5C,KAAK,EAAE,OAAO,KACX,wBAAwB,GAAG,SAAS,CAAC;AAE1C;;;;;;;;;;;;;;GAcG;AACH,MAAM,MAAM,gCAAgC,GAAG,MAAM,CACnD,MAAM,EACN,+BAA+B,CAChC,CAAC;AAEF,qFAAqF;AACrF,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAalC,CAAC;AACH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAExE;;;;;;;;;;;;;;;;;;;GAmBG;AACH,eAAO,MAAM,mBAAmB,GAC9B,OAAO,OAAO,KACb,KAAK,IAAI,iBACsC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@neo4j-ndl/react",
3
- "version": "4.18.6",
3
+ "version": "4.18.7",
4
4
  "sideEffects": false,
5
5
  "description": "React implementation of Neo4j Design System",
6
6
  "keywords": [
@@ -18,7 +18,7 @@ Import: `import { DataGrid } from '@neo4j-ndl/react'`
18
18
  | `ref` | `Ref<HTMLDivElement>` | | | A ref to apply to the root element. |
19
19
  | `rootProps` | `HtmlAttributes<"div">` | | | @deprecated Use htmlAttributes, className and style on the root element instead |
20
20
  | `skeletonProps` | `(SkeletonProps & { as?: ElementType<any, keyof IntrinsicElements>; } & BaseProps<ElementType<any, keyof IntrinsicElements>>)` | | | |
21
- | `styleRules` | `{ apply: { color?: { value: string; isDisabled?: boolean; }; colorRange?: { maxColor: string; maxValue: number \| bigint \| { bigint: string; }; minColor: string; minValue: number \| ... 1 more ... \| { ...; }; onColumn: string; isDisabled?: boolean \| undefined; midColor?: string \| undefined; mid...` | | | Rule-based conditional styling for cells and rows. |
21
+ | `styleRules` | `{ apply: { color?: { value: string; isDisabled?: boolean; }; colorRange?: { maxColor: string; maxValue: number \| bigint \| { bigint: string; } \| { datetime: string; } \| { ...; } \| { ...; }; ... 5 more ...; midValue?: number \| ... 5 more ... \| undefined; } \| undefined; textColor?: { ...; } \| un...` | | | Rule-based conditional styling for cells and rows. |
22
22
  | `styleRuleValueConverters` | `DataGridStyleRuleValueConverters` | | | Per-column converters that teach the style-rule engine how to interpret complex cell values. |
23
23
  | `styling` | `Partial<{ hasZebraStriping: boolean; borderStyle: "all-sides" \| "horizontal" \| "vertical" \| "none"; headerStyle: "filled" \| "clean"; hasHoverEffects: boolean; isCompact: boolean; }>` | | `{}` | |
24
24
  | `tableInstance` | `Table<T>` | ✅ | | Table instance created from `useTable` |
@@ -1959,16 +1959,13 @@ const data: EventRow[] = [
1959
1959
  // 13:15 Paris CEST (+02:00) = 11:15 UTC
1960
1960
  scheduledDate: new Date('2026-07-08T13:15:00+02:00'),
1961
1961
  scheduledTimeMs: 11 * 3_600_000 + 15 * 60_000,
1962
- status: 'cancelled',
1962
+ status: 'confirmed',
1963
1963
  },
1964
- // ── Far future (after 2026-07-15T00:00 Stockholm / CEST = 2026-07-14T22:00Z)
1965
1964
  {
1966
1965
  event: 'Architecture summit',
1967
1966
  localTimeDisplay: '08:00 CEST (+02:00)',
1968
- // 08:00 Amsterdam CEST (+02:00) = 06:00 UTC.
1969
- // Although the calendar date is "July 15", 08:00 CEST is still within the
1970
- // same UTC day as July 14 22:00Z, so it crosses the far-future boundary.
1971
- scheduledDate: new Date('2026-07-15T08:00:00+02:00'),
1967
+ // 08:00 Amsterdam CEST (+02:00) = 06:00 UTC
1968
+ scheduledDate: new Date('2026-07-11T08:00:00+02:00'),
1972
1969
  scheduledTimeMs: 6 * 3_600_000,
1973
1970
  status: 'confirmed',
1974
1971
  },
@@ -1976,17 +1973,18 @@ const data: EventRow[] = [
1976
1973
  event: 'Annual conference',
1977
1974
  localTimeDisplay: '09:00 PDT (-07:00)',
1978
1975
  // 09:00 San Francisco PDT (-07:00) = 16:00 UTC — after Stockholm closes
1979
- scheduledDate: new Date('2026-08-03T09:00:00-07:00'),
1976
+ scheduledDate: new Date('2026-07-13T09:00:00-07:00'),
1980
1977
  scheduledTimeMs: 16 * 3_600_000,
1981
1978
  status: 'confirmed',
1982
1979
  },
1980
+ // ── Far future (after 2026-07-15T00:00 Stockholm / CEST = 2026-07-14T22:00Z)
1983
1981
  {
1984
1982
  event: 'Year-end planning',
1985
1983
  localTimeDisplay: '09:00 JST (+09:00)',
1986
1984
  // 09:00 Tokyo JST (+09:00) = 00:00 UTC — midnight, well before Stockholm opens
1987
1985
  scheduledDate: new Date('2026-11-20T09:00:00+09:00'),
1988
1986
  scheduledTimeMs: 0,
1989
- status: 'confirmed',
1987
+ status: 'cancelled',
1990
1988
  },
1991
1989
  ];
1992
1990
 
@@ -2008,6 +2006,26 @@ const data: EventRow[] = [
2008
2006
  * { time: '17:00:00+02:00' } resolves to 15:00 UTC (54 000 000 ms)
2009
2007
  */
2010
2008
  const styleRules: DataGridStyleRule[] = [
2009
+ // Near-future date cells use temporal literals directly as gradient
2010
+ // boundaries. Several rows are spread across this interval so the progression
2011
+ // from amber to blue is easy to see.
2012
+ {
2013
+ apply: {
2014
+ colorRange: {
2015
+ maxColor: '#dbeafe',
2016
+ maxValue: {
2017
+ datetime: '2026-07-15T00:00:00[Europe/Stockholm]',
2018
+ },
2019
+ minColor: '#fef3c7',
2020
+ minValue: {
2021
+ datetime: '2026-06-26T00:00:00[Europe/Stockholm]',
2022
+ },
2023
+ onColumn: 'scheduledDate',
2024
+ },
2025
+ },
2026
+ column: 'scheduledDate',
2027
+ priority: 0,
2028
+ },
2011
2029
  // Past events — entire row in muted red
2012
2030
  {
2013
2031
  apply: {