@object-ui/plugin-report 17.2.0 → 17.5.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.
- package/CHANGELOG.md +443 -0
- package/README.md +0 -12
- package/dist/index.js +374 -356
- package/dist/index.umd.cjs +2 -2
- package/dist/useDatasetDimensionLabels.d.ts +71 -0
- package/package.json +17 -17
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,439 @@
|
|
|
1
1
|
# @object-ui/plugin-report
|
|
2
2
|
|
|
3
|
+
## 17.5.0
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- ee26e65: Analytics: the dimension label net's fetch-and-memo glue is written once, not once per surface
|
|
8
|
+
|
|
9
|
+
PR #4388 (objectui#4330) put the same React glue on two surfaces — the dashboard's `DatasetWidget` and plugin-report's dataset block. The resolution RULES were never duplicated (both call the same `@object-ui/core` helpers), but the wiring around them was: read the object schema through the host's authenticated `apiFetch`, keep the fetched metadata locale-free in state, derive the label maps in a render memo. Two copies meant two statements of the same two bug fixes, which is a drift surface rather than a defect — nothing a user could hit today, filed as objectui#4389 so it was retired deliberately.
|
|
10
|
+
|
|
11
|
+
It is now split along the layer that can actually hold each half. `@object-ui/core` gains the React-free parts — `loadDimensionFieldMeta` (the base-object read composed with the dimension walk), `deriveDimensionLabelMaps` (the locale-applying derivation) and `dimensionOptionTranslator` (binding the bundle resolver to the object that OWNS a terminal field, which for a dotted path is the relationship target). `@object-ui/react` gains `useDatasetDimensionLabels` / `useDatasetDimensionMeta`, the React wiring that cannot live in core, beside the `useViewData` / `useElementDataSource` / `useDiscovery` hooks that already read `SchemaRendererContext` the same way. Both plugins consume it; the dashboard keeps its chart-only per-category colour and category-order derivation layered locally, since a table renders no palette.
|
|
12
|
+
|
|
13
|
+
The card originally proposed `@object-ui/core` as the whole glue's home. That home was disproven by measurement and retired in the card's PM RULING #2: `SchemaRendererContext` is defined in `@object-ui/react`, which depends on core, so core importing it back is a cycle — and core is React-free by declaration, by content, and by the topology in AGENTS.md. objectui#3367 had already ruled this direction for the same family (core-canonical logic, react re-exports).
|
|
14
|
+
|
|
15
|
+
Behaviour is unchanged by construction: same read count, same best-effort fallback, same memoization boundary. The two bug fixes are now stated once and pinned at the shared hook — the read rides the host's authenticated `apiFetch` (objectui#4121, pinned by asserting that a new channel re-issues the read, i.e. that it really is in the effect's deps), and the fetched metadata stays locale-free (objectui#4030 / PR #4324, pinned by switching language at runtime and asserting the labels flip with no second metadata read). All 39 assertions PR #4388 landed across both surfaces pass unchanged, and their files are byte-identical to before.
|
|
16
|
+
|
|
17
|
+
- 326a70f: Analytics: a LOCAL select dimension on a table / pivot widget — and on a dataset-bound report — now renders its option label through the locale bundle
|
|
18
|
+
|
|
19
|
+
A dashboard table grouped by a select field showed `Domestic` on a zh-CN console while the related list on the same screen showed 国内. The value was never untranslated by accident: the server resolves that dimension's display label (ADR-0021) and hands the row over carrying the object's AUTHORED English label. The locale bundle is keyed by the option's stored VALUE (`{ns}.fieldOptions.<object>.<field>.<value>`), so translating one needs the option LIST — and the table path deliberately loaded no object metadata at all, which is why objectui#4030 / PR #4324 fixed charts and dotted dimensions and left this half open.
|
|
20
|
+
|
|
21
|
+
Table, pivot and the dataset report block now take the one metadata read that gives the bundle something to translate against, and feed it to the SAME seam #4324 landed (`resolveDimensionFieldMeta` → `localizeFieldOptions` / `buildDimensionLabelMap` → `relabelDimensions`). No second resolution dialect: the map carries both the stored value and the authored label as keys, and the relabel is value-wise and idempotent, so a value the server already resolved lands on the same display it would have from the raw value. Cells, pivot headers on both axes, the server's marginal totals, the CSV export and a report's embedded chart all read the one map, which is what keeps a subtotal's bucket lookup meeting the header it belongs to.
|
|
22
|
+
|
|
23
|
+
Untranslated apps are unchanged by construction: with no bundle entry the display equals the authored label, no key is emitted, and the rows come back by identity. Identity keys stay untranslated — a drilled row or cell still filters records by the values the server sent, and measures still export as bare numbers.
|
|
24
|
+
|
|
25
|
+
This deliberately amends the acceptance boundary objectui#4263 landed ("a local-only table issues no metadata read"), which was ruled for label RESOLUTION before the read had a second consumer. The pins that stated it are rewritten in place, in the same change, and say so.
|
|
26
|
+
|
|
27
|
+
- 49ae9f4: Pivot buckets encode an empty dimension value as JSON `null`, so it no longer collides with a row whose value is literally the placeholder character
|
|
28
|
+
|
|
29
|
+
objectstack#5473 / objectstack#5665 replaced the pivot's delimiter-joined ids
|
|
30
|
+
with `JSON.stringify`, because every delimiter that had been tried — an empty
|
|
31
|
+
string, a plain space, a control character — assumed the data would not contain
|
|
32
|
+
it, and each assumption failed on ordinary data. This closes the last place the
|
|
33
|
+
same assumption survived: the ids were JSON, but the VALUES fed into them were
|
|
34
|
+
spelled `String(row[d] ?? '∅')`, so an absent dimension value became the
|
|
35
|
+
ordinary string `"∅"` and shared a bucket with a row whose value literally is
|
|
36
|
+
that character (U+2205). One bucket, later row overwriting the earlier one — the
|
|
37
|
+
cell showed a different row's measure, the overwritten row was unreachable, and
|
|
38
|
+
drill-through followed the same wrong index into the wrong records, all without
|
|
39
|
+
an error. The trigger requires that character to appear as a dimension value, so
|
|
40
|
+
this is the assumption being removed rather than a defect users hit today.
|
|
41
|
+
|
|
42
|
+
An empty value now encodes as JSON `null`, which `JSON.stringify` renders as a
|
|
43
|
+
bare `null` that no string can spell. The normalization lives in
|
|
44
|
+
`@object-ui/core` as `pivotDimensionValue` (absent ⇒ `null`, everything else ⇒
|
|
45
|
+
its string form) rather than at each call site, because a placeholder spelled by
|
|
46
|
+
a caller is a placeholder that can collide again — which is exactly how this one
|
|
47
|
+
survived the previous fix. `pivotBucketId` accepts `Array<string | null>`
|
|
48
|
+
accordingly; that is a widening, so existing callers passing `string[]` are
|
|
49
|
+
unaffected.
|
|
50
|
+
|
|
51
|
+
Both renderers' bucket keys move together, which the fix requires: a bucket id
|
|
52
|
+
and the subtotal map keyed by it are built from the same expression, so changing
|
|
53
|
+
one alone would split the headers while the subtotal map still merged, landing
|
|
54
|
+
every column subtotal under the wrong header. In `plugin-dashboard`'s
|
|
55
|
+
`DatasetWidget` that is the row bucket id, the column bucket id, the cell key,
|
|
56
|
+
and both the `rowTotalById` and `colTotalById` lookups; in `plugin-report`'s
|
|
57
|
+
`DatasetReportRenderer` the single `bucketId` helper already feeds all five.
|
|
58
|
+
|
|
59
|
+
The dashboard's column bucket id also stops being a bare string and becomes a
|
|
60
|
+
one-element tuple through the same shared encoder. It was the one id in the
|
|
61
|
+
family still built by hand, on the reasoning that a single value needs no
|
|
62
|
+
boundary — true of the boundary, false of everything else the encoder does, and
|
|
63
|
+
it is why the across axis kept carrying this collision after the row ids were
|
|
64
|
+
fixed.
|
|
65
|
+
|
|
66
|
+
No display change: these placeholders only ever entered ids, never labels. An
|
|
67
|
+
unset dimension still renders through `formatDimensionValue` exactly as before,
|
|
68
|
+
and data containing neither an absent value nor that character buckets
|
|
69
|
+
identically — the ids are opaque lookup keys, never parsed back into a value,
|
|
70
|
+
never shown, never persisted.
|
|
71
|
+
|
|
72
|
+
- cb315f2: Report and dataset-preview measures follow the display locale (objectui#4575)
|
|
73
|
+
|
|
74
|
+
objectui#4566 gave `formatMeasure` / `formatDimensionValue` in `@object-ui/core`
|
|
75
|
+
an optional trailing `locale` and threaded `useDisplayLocale()` through the
|
|
76
|
+
dashboard's `DatasetWidget`. The parameter is OPTIONAL by design, so the
|
|
77
|
+
producer could land without dragging every consumer with it — which left the
|
|
78
|
+
consumers it did not reach still formatting in the MACHINE's locale. A German
|
|
79
|
+
session read a report measure as `1,234.5` directly beside a dashboard measure
|
|
80
|
+
that, after #4566, rendered `1.234,5`: one number, two spellings, on the same
|
|
81
|
+
screen. That is a sharper inconsistency than the one before #4566, when both
|
|
82
|
+
surfaces were uniformly wrong.
|
|
83
|
+
|
|
84
|
+
The remaining thirteen call sites now thread `useDisplayLocale()`:
|
|
85
|
+
|
|
86
|
+
- `plugin-report`'s `DatasetReportRenderer` (ten) — the grouped table's measure,
|
|
87
|
+
dimension and grand-total cells, the embedded single-value chart's metric, and
|
|
88
|
+
the cross-tab's across-axis header, down-axis cell, measure cell, row total,
|
|
89
|
+
column total and grand total;
|
|
90
|
+
- `app-shell`'s metadata-admin `DatasetPreview` (two) — the preview table's
|
|
91
|
+
measure and dimension cells;
|
|
92
|
+
- `app-shell`'s `DatasetDefaultInspector` (one) — the measure format-hint
|
|
93
|
+
sample, which is a preview of authored formatting and so has to be rendered
|
|
94
|
+
through the channel it previews.
|
|
95
|
+
|
|
96
|
+
**English output does not move**, and that is the discriminator against the
|
|
97
|
+
sibling fix. These sites already went through `Intl` with default grouping, so
|
|
98
|
+
the only thing that changes is WHOSE locale is used — contrast objectui#4553,
|
|
99
|
+
where `formatPercent` had never grouped at all and moving en `1235%` to
|
|
100
|
+
`1,235%` WAS the fix. Every new case pins the same value in de AND in en, so
|
|
101
|
+
at least one half must fail on any runner: before the change both render in the
|
|
102
|
+
machine's locale, which is what makes the machine locale stop being a test
|
|
103
|
+
input.
|
|
104
|
+
|
|
105
|
+
Two details worth recording:
|
|
106
|
+
|
|
107
|
+
- **The cross-tab's header labels are built inside a `useMemo`**, so the locale
|
|
108
|
+
joins that dependency array. Threading it into the call alone would leave the
|
|
109
|
+
headers frozen in whatever locale they were first built with — measured, and
|
|
110
|
+
pinned by a case that changes only the locale and asserts the header
|
|
111
|
+
re-labels. Removing just the dependency entry turns exactly that one case red
|
|
112
|
+
and leaves the other nine green.
|
|
113
|
+
- **The metadata designer's `locale` prop is deliberately not used.** It carries
|
|
114
|
+
the designer's own chrome language (`useMetadataLocale()`, which resolves to
|
|
115
|
+
exactly `en-US` or `zh-CN`), not a number-formatting locale — a German session
|
|
116
|
+
gets `en-US` from it. The preview's numbers have to match what the report and
|
|
117
|
+
dashboard render for the same dataset, which is `useDisplayLocale()`.
|
|
118
|
+
|
|
119
|
+
Both packages are `patch`: their published declarations are unchanged (measured
|
|
120
|
+
against the built `.d.ts` with `dist/` cleared between builds). The threading is
|
|
121
|
+
module-local, and the one signature that gained a parameter — the file-local
|
|
122
|
+
`bucketLabel` helper — is not exported.
|
|
123
|
+
|
|
124
|
+
A side effect of the fallback: these surfaces are now DETERMINISTIC where they
|
|
125
|
+
previously followed whatever locale the machine happened to run in.
|
|
126
|
+
`useDisplayLocale` ends at a concrete `'en'` rather than the `undefined` that
|
|
127
|
+
hands `Intl` the machine's locale.
|
|
128
|
+
|
|
129
|
+
- 3f5f87c: `SchemaRenderer` states its real contract — a typed, required `schema` and a deliberate forwarding surface
|
|
130
|
+
|
|
131
|
+
`SchemaRenderer` is the renderer loop: every registered SDUI component is rendered through it. It handed `forwardRef` a props type of `{ schema: SchemaNode } & Record<string, any>`, which puts `string` into `keyof Props`, so `'ref' extends keyof Props` was always true, React's `PropsWithoutRef` took its `Omit` branch, and `Omit` over a type carrying a string index signature keeps only the index signature. Every declared prop was erased. Measured on the pre-fix source: `keyof ComponentProps<typeof SchemaRenderer>` was `string` and `ComponentProps<typeof SchemaRenderer>['schema']` was `any`, while the type argument went on declaring `SchemaNode`. The other half is the same defect seen from the call site — `<SchemaRenderer />` with no schema at all, `<SchemaRenderer schema={12345} />`, and an arbitrary misspelled prop each type-checked in silence. This is objectui#4422 / PR #4438's trap in the most central component in the repo, spelled `Record<string, any>` rather than `[key: string]: any`, which is why every previous sweep's grep and both shipped guards' detector reported the site as clean.
|
|
132
|
+
|
|
133
|
+
Graded **minor, not major**, on objectui#4528's reasoning: the type argument has always DECLARED `schema`; the index signature erased it from the resolved type, and restoring what the declaration documents is a fix to the published contract rather than a contract break.
|
|
134
|
+
|
|
135
|
+
**The forwarding surface is kept, deliberately.** This component forwards every prop it does not read to the component the schema names, resolved at runtime from a plugin-extensible registry — `packages/react/README.md` documents exactly that, and `@object-ui/components`' form renderer consumes the `onSubmit` it shows being forwarded. Closing that surface would state a false contract and would force every leaf plugin's props into this package. So the two halves are separated: the `forwardRef` type argument is the honest `SchemaRendererProps`, with no index signature for `PropsWithoutRef` to collapse, and the open surface is stated once in an explicit export annotation, which nothing routes through `Omit`. The published `.d.ts` shows the erasure disappearing: `ForwardRefExoticComponent<Omit<{ schema: SchemaNode } & Record<string, any>, "ref"> & RefAttributes<any>>` becomes `ForwardRefExoticComponent<SchemaRendererProps & Record<string, any> & RefAttributes<any>>`.
|
|
136
|
+
|
|
137
|
+
`SchemaRendererProps.schema` is declared as `BaseSchema | string | null | undefined` — what this component actually handles. It previously declared `@object-ui/core`'s `SchemaNode` interface, which requires `type: string` and so contradicted the component's own early returns for strings and nullish, while every caller held `@object-ui/types`' wider union. The erasure hid that mismatch completely.
|
|
138
|
+
|
|
139
|
+
**One declared behaviour change.** A non-object, non-string primitive schema now renders as its own text. It previously fell through to the shallow copy `{ ...schema }`, which spreads a primitive to an empty object, lost the `type` the renderer then looked up, and surfaced the red "Unknown component type: undefined" box — an accident of the spread rather than a decision. The declared props type excludes `number` / `boolean` so no author is invited to pass them; the runtime handling is defence-in-depth for untyped callers and stored metadata. Strings, `null`, `undefined`, `0` and `false` render exactly as before, and an object naming an unregistered type still gets the error box; all four are pinned.
|
|
140
|
+
|
|
141
|
+
Latent defects the erasure had been hiding, each surfaced by the repo-wide type-check and fixed at its call site: `DashboardRenderer` cast its widget schema to `Record<string, any>`, dropping the `type` every branch of `getComponentSchema` sets; `DashboardGridLayout`'s equivalent now states its return type instead of inferring a union that admitted a shape with no `type`; and `ReportViewer` handed a section's `content` array to the renderer whole, so a multi-node section rendered the unknown-component box instead of its content — arrays are mapped rather than widened into the renderer's declared input.
|
|
142
|
+
|
|
143
|
+
A repo-wide structural guard replaces the two per-package siblings' blocked direction: it judges every `forwardRef` in `packages/*/src` (219 sites) and its detector resolves `Record<string, …>` and `string`-keyed mapped types in addition to literal index signatures — the spelling the previous detector went blind on. It judges the type argument only, where an index signature is an accidental eraser, and never an export annotation, where one is a stated contract.
|
|
144
|
+
|
|
145
|
+
- 31ab1ac: fix(print): `window.print()` produces a usable page, and the Print buttons say what they do
|
|
146
|
+
|
|
147
|
+
The list, report and dashboard Print controls were bare `window.print()` calls with no
|
|
148
|
+
print stylesheet, so the browser printed the whole console — sidebar, top bar, chat rail,
|
|
149
|
+
toasts — with the data table clipped to a single viewport. With no label to the contrary
|
|
150
|
+
they were being accepted against "export to PDF" requirements, which they have never been.
|
|
151
|
+
|
|
152
|
+
- `@object-ui/app-shell/styles.css` gains a shared `@media print` block: it hides the shell
|
|
153
|
+
chrome, prints the active content area full-width, releases the viewport-height flex chain
|
|
154
|
+
so long tables paginate instead of clipping, repeats table headers on every sheet, and
|
|
155
|
+
neutralises dark mode (which otherwise prints white-on-white). One sheet serves list,
|
|
156
|
+
report and dashboard.
|
|
157
|
+
- The list and report Print buttons carry a tooltip and accessible name stating that they
|
|
158
|
+
open the browser's own print dialog and are not a PDF export (new `common.printDialogHint`,
|
|
159
|
+
translated in all ten locale packs).
|
|
160
|
+
- The dashboard's `export_dashboard_pdf` action no longer toasts "Preparing PDF export…" —
|
|
161
|
+
it names the print dialog it actually opens (`dashboardActions.pdfPreparing` is replaced by
|
|
162
|
+
`dashboardActions.printDialogOpening`).
|
|
163
|
+
|
|
164
|
+
No control was removed and no headless detection was added. A real print/PDF primitive
|
|
165
|
+
remains out of scope (`objectstack-ai/objectstack#1301`, closed NOT_PLANNED).
|
|
166
|
+
|
|
167
|
+
- Updated dependencies [0e67b53]
|
|
168
|
+
- Updated dependencies [ceccdcf]
|
|
169
|
+
- Updated dependencies [d6e5124]
|
|
170
|
+
- Updated dependencies [debad27]
|
|
171
|
+
- Updated dependencies [dc2aa3e]
|
|
172
|
+
- Updated dependencies [ee66e2e]
|
|
173
|
+
- Updated dependencies [e2e6360]
|
|
174
|
+
- Updated dependencies [ee26e65]
|
|
175
|
+
- Updated dependencies [5900ac5]
|
|
176
|
+
- Updated dependencies [932cbcd]
|
|
177
|
+
- Updated dependencies [734d186]
|
|
178
|
+
- Updated dependencies [f650253]
|
|
179
|
+
- Updated dependencies [3d9769a]
|
|
180
|
+
- Updated dependencies [8f85f8b]
|
|
181
|
+
- Updated dependencies [7ffd616]
|
|
182
|
+
- Updated dependencies [d0c3b26]
|
|
183
|
+
- Updated dependencies [3fc2971]
|
|
184
|
+
- Updated dependencies [aca27fa]
|
|
185
|
+
- Updated dependencies [dde7283]
|
|
186
|
+
- Updated dependencies [f7c6430]
|
|
187
|
+
- Updated dependencies [4dadf0d]
|
|
188
|
+
- Updated dependencies [ae10a01]
|
|
189
|
+
- Updated dependencies [77d6f28]
|
|
190
|
+
- Updated dependencies [0f21348]
|
|
191
|
+
- Updated dependencies [d2e2caf]
|
|
192
|
+
- Updated dependencies [92876f0]
|
|
193
|
+
- Updated dependencies [f279deb]
|
|
194
|
+
- Updated dependencies [4b70d28]
|
|
195
|
+
- Updated dependencies [eb7f586]
|
|
196
|
+
- Updated dependencies [e901131]
|
|
197
|
+
- Updated dependencies [ebb4e0e]
|
|
198
|
+
- Updated dependencies [3a9021e]
|
|
199
|
+
- Updated dependencies [d9d3463]
|
|
200
|
+
- Updated dependencies [2a40f69]
|
|
201
|
+
- Updated dependencies [bec3e14]
|
|
202
|
+
- Updated dependencies [613b167]
|
|
203
|
+
- Updated dependencies [b4d3c22]
|
|
204
|
+
- Updated dependencies [1f9b905]
|
|
205
|
+
- Updated dependencies [8f60d73]
|
|
206
|
+
- Updated dependencies [cb13400]
|
|
207
|
+
- Updated dependencies [828549a]
|
|
208
|
+
- Updated dependencies [e1ade8f]
|
|
209
|
+
- Updated dependencies [bc64bfe]
|
|
210
|
+
- Updated dependencies [abb0f81]
|
|
211
|
+
- Updated dependencies [38ab505]
|
|
212
|
+
- Updated dependencies [51ab34e]
|
|
213
|
+
- Updated dependencies [24bb2de]
|
|
214
|
+
- Updated dependencies [0ca6096]
|
|
215
|
+
- Updated dependencies [3e19fe7]
|
|
216
|
+
- Updated dependencies [bb58d1d]
|
|
217
|
+
- Updated dependencies [433ff9f]
|
|
218
|
+
- Updated dependencies [5cc847c]
|
|
219
|
+
- Updated dependencies [e7663f2]
|
|
220
|
+
- Updated dependencies [fa21254]
|
|
221
|
+
- Updated dependencies [f565418]
|
|
222
|
+
- Updated dependencies [33c32bf]
|
|
223
|
+
- Updated dependencies [66fb4fa]
|
|
224
|
+
- Updated dependencies [b953a97]
|
|
225
|
+
- Updated dependencies [d7f3e30]
|
|
226
|
+
- Updated dependencies [6d641c9]
|
|
227
|
+
- Updated dependencies [7e4f0e5]
|
|
228
|
+
- Updated dependencies [a84385b]
|
|
229
|
+
- Updated dependencies [45e1949]
|
|
230
|
+
- Updated dependencies [51ac39f]
|
|
231
|
+
- Updated dependencies [5e514c4]
|
|
232
|
+
- Updated dependencies [92250d6]
|
|
233
|
+
- Updated dependencies [c1d939f]
|
|
234
|
+
- Updated dependencies [58bebf6]
|
|
235
|
+
- Updated dependencies [36310dc]
|
|
236
|
+
- Updated dependencies [52d878a]
|
|
237
|
+
- Updated dependencies [405e808]
|
|
238
|
+
- Updated dependencies [49ae9f4]
|
|
239
|
+
- Updated dependencies [a3ae404]
|
|
240
|
+
- Updated dependencies [4270c11]
|
|
241
|
+
- Updated dependencies [bfdf3d4]
|
|
242
|
+
- Updated dependencies [bb68488]
|
|
243
|
+
- Updated dependencies [c0f9a4b]
|
|
244
|
+
- Updated dependencies [b1e42d0]
|
|
245
|
+
- Updated dependencies [2459a3e]
|
|
246
|
+
- Updated dependencies [ac853ce]
|
|
247
|
+
- Updated dependencies [fa51109]
|
|
248
|
+
- Updated dependencies [d6aa172]
|
|
249
|
+
- Updated dependencies [fe52a04]
|
|
250
|
+
- Updated dependencies [d46f9b8]
|
|
251
|
+
- Updated dependencies [3f5f87c]
|
|
252
|
+
- Updated dependencies [2fea4d2]
|
|
253
|
+
- Updated dependencies [f5e1143]
|
|
254
|
+
- Updated dependencies [7f1cb33]
|
|
255
|
+
- Updated dependencies [f148a64]
|
|
256
|
+
- Updated dependencies [bb68488]
|
|
257
|
+
- Updated dependencies [2e3b0c0]
|
|
258
|
+
- Updated dependencies [9461dd3]
|
|
259
|
+
- Updated dependencies [78fa331]
|
|
260
|
+
- Updated dependencies [47f551b]
|
|
261
|
+
- Updated dependencies [31ab1ac]
|
|
262
|
+
- Updated dependencies [0082db8]
|
|
263
|
+
- Updated dependencies [ab04728]
|
|
264
|
+
- Updated dependencies [5bf09fd]
|
|
265
|
+
- Updated dependencies [06915b0]
|
|
266
|
+
- Updated dependencies [ff84b05]
|
|
267
|
+
- @object-ui/i18n@17.5.0
|
|
268
|
+
- @object-ui/react@17.5.0
|
|
269
|
+
- @object-ui/components@17.5.0
|
|
270
|
+
- @object-ui/core@17.5.0
|
|
271
|
+
- @object-ui/fields@17.5.0
|
|
272
|
+
- @object-ui/types@17.5.0
|
|
273
|
+
- @object-ui/plugin-grid@17.5.0
|
|
274
|
+
|
|
275
|
+
## 17.4.0
|
|
276
|
+
|
|
277
|
+
### Patch Changes
|
|
278
|
+
|
|
279
|
+
- 3b1f888: Accept React 19 in `@object-ui/plugin-report`'s peer range, the last UI package still declaring React 18 alone (objectui#3690).
|
|
280
|
+
|
|
281
|
+
`peerDependencies.react` and `peerDependencies.react-dom` widen from `^18.0.0` to `^18.0.0 || ^19.0.0`, matching the other 29 packages in the fixed version group. With npm 7+ resolving peers strictly, a React 19 consumer installing this published package hit an `ERESOLVE` on first install while every sibling installed clean — and the package's own README already documented the wider range, so the manifest was the half that was wrong.
|
|
282
|
+
|
|
283
|
+
The narrow range was never a constraint anyone stated. `packages/plugin-report/package.json` was hand-authored on 2026-02-06 (`1e557cbda`), by which point nineteen sibling packages already carried `^18.0.0 || ^19.0.0` and every package created afterwards was born with it; the one other package born narrow, `plugin-dashboard`, was corrected on 2026-05-08 (`d2b6ecec6`) in a build fix that touched only itself. No commit in the file's 172-commit history ever revisited the peer line, and no commit message mentions a React 18 requirement.
|
|
284
|
+
|
|
285
|
+
Nothing in the package needs React 18. Its entire React surface is `React.FC`, `useState`, `useEffect`, `useMemo`, `useReducer`, `useContext`, `Fragment`, `ComponentType`, `CSSProperties` and `ReactNode` — all unchanged in React 19 — with zero uses of anything React 19 removed (`ReactDOM.render`, `unmountComponentAtNode`, `findDOMNode`, legacy context, string refs, `defaultProps` / `propTypes` on function components, `createFactory`, `useFormState`, `react-dom/test-utils`). `react-dom` is not imported by the source at all; it appears only as a UMD global name in the Vite externals config. The workspace pins `react` to 19.2.8 via a root `pnpm.overrides`, so this package's 78 tests have been running against React 19 the whole time it declared it did not support it.
|
|
286
|
+
|
|
287
|
+
- Updated dependencies [794c497]
|
|
288
|
+
- Updated dependencies [993336f]
|
|
289
|
+
- Updated dependencies [f0a625a]
|
|
290
|
+
- Updated dependencies [b5980f4]
|
|
291
|
+
- Updated dependencies [8aad9fd]
|
|
292
|
+
- Updated dependencies [6719877]
|
|
293
|
+
- Updated dependencies [56ff091]
|
|
294
|
+
- Updated dependencies [0186cdc]
|
|
295
|
+
- Updated dependencies [7864f03]
|
|
296
|
+
- Updated dependencies [ea41a59]
|
|
297
|
+
- Updated dependencies [0cbdca8]
|
|
298
|
+
- Updated dependencies [d229dfa]
|
|
299
|
+
- Updated dependencies [18c42c6]
|
|
300
|
+
- Updated dependencies [ecae400]
|
|
301
|
+
- Updated dependencies [4bc6c23]
|
|
302
|
+
- Updated dependencies [d3e738a]
|
|
303
|
+
- Updated dependencies [c3b01a7]
|
|
304
|
+
- Updated dependencies [f5f8744]
|
|
305
|
+
- Updated dependencies [7ed3360]
|
|
306
|
+
- Updated dependencies [69becd2]
|
|
307
|
+
- Updated dependencies [5e52495]
|
|
308
|
+
- Updated dependencies [0fa5e4d]
|
|
309
|
+
- Updated dependencies [b750823]
|
|
310
|
+
- Updated dependencies [5bfaabd]
|
|
311
|
+
- Updated dependencies [e06810e]
|
|
312
|
+
- Updated dependencies [ab3ad4f]
|
|
313
|
+
- Updated dependencies [65bb513]
|
|
314
|
+
- Updated dependencies [c97a45e]
|
|
315
|
+
- Updated dependencies [b19162d]
|
|
316
|
+
- Updated dependencies [c2fd122]
|
|
317
|
+
- Updated dependencies [1bd6faa]
|
|
318
|
+
- Updated dependencies [9154d9e]
|
|
319
|
+
- Updated dependencies [ac2139c]
|
|
320
|
+
- Updated dependencies [b14ab3a]
|
|
321
|
+
- Updated dependencies [e24d767]
|
|
322
|
+
- Updated dependencies [8c60819]
|
|
323
|
+
- Updated dependencies [aca561a]
|
|
324
|
+
- Updated dependencies [e64a52e]
|
|
325
|
+
- Updated dependencies [844d17f]
|
|
326
|
+
- Updated dependencies [d8a0be4]
|
|
327
|
+
- Updated dependencies [48132f7]
|
|
328
|
+
- Updated dependencies [4dcd52a]
|
|
329
|
+
- Updated dependencies [42ae5c6]
|
|
330
|
+
- Updated dependencies [0ef9dfd]
|
|
331
|
+
- Updated dependencies [f4b97c8]
|
|
332
|
+
- Updated dependencies [1d723e3]
|
|
333
|
+
- Updated dependencies [0109f54]
|
|
334
|
+
- Updated dependencies [7e5bb5d]
|
|
335
|
+
- Updated dependencies [fbc23e0]
|
|
336
|
+
- Updated dependencies [6d762da]
|
|
337
|
+
- Updated dependencies [e6fdbdc]
|
|
338
|
+
- Updated dependencies [54233b1]
|
|
339
|
+
- Updated dependencies [c2ecbae]
|
|
340
|
+
- Updated dependencies [f9faa7d]
|
|
341
|
+
- Updated dependencies [97b63d7]
|
|
342
|
+
- Updated dependencies [14c59c0]
|
|
343
|
+
- Updated dependencies [aeb8424]
|
|
344
|
+
- Updated dependencies [6bb454a]
|
|
345
|
+
- Updated dependencies [1a33b1a]
|
|
346
|
+
- Updated dependencies [11c1e71]
|
|
347
|
+
- Updated dependencies [523be48]
|
|
348
|
+
- Updated dependencies [7e2b7e9]
|
|
349
|
+
- Updated dependencies [33526fd]
|
|
350
|
+
- Updated dependencies [32413ec]
|
|
351
|
+
- Updated dependencies [c1e1e6b]
|
|
352
|
+
- @object-ui/components@17.4.0
|
|
353
|
+
- @object-ui/react@17.4.0
|
|
354
|
+
- @object-ui/core@17.4.0
|
|
355
|
+
- @object-ui/fields@17.4.0
|
|
356
|
+
- @object-ui/i18n@17.4.0
|
|
357
|
+
- @object-ui/types@17.4.0
|
|
358
|
+
- @object-ui/plugin-grid@17.4.0
|
|
359
|
+
|
|
360
|
+
## 17.3.0
|
|
361
|
+
|
|
362
|
+
### Patch Changes
|
|
363
|
+
|
|
364
|
+
- 509104a: Fix matrix report cells showing another bucket's numbers when dimension values run together.
|
|
365
|
+
|
|
366
|
+
The cross-tab in `DatasetReportRenderer` built its bucket ids by joining dimension values with the EMPTY string, so adjacent values had no boundary at all: `"x"` + `"yz"` and `"xy"` + `"z"` were the same bucket on both axes, and the later row silently overwrote the earlier one. Its cell key then joined the two bucket ids with a plain space, while dimension values contain spaces constantly ("New York", "In Progress"), so `"New"` × `"York Q1"` and `"New York"` × `"Q1"` also met in one key. A merged bucket showed a different row's measure, the overwritten row's value was unreachable, the per-row and per-column subtotals matched the wrong header, and drill-through followed the same wrong index into another record's list — none of it with an error.
|
|
367
|
+
|
|
368
|
+
Bucket ids and cell keys are now encoded with `JSON.stringify`, which carries the boundary in its own quoting rather than in a character the data is assumed never to contain. All four lookups in the renderer (row headers, column headers, row subtotals, column subtotals) share the one encoder, so they agree by construction.
|
|
369
|
+
|
|
370
|
+
The encoders moved to `@object-ui/core` as `pivotBucketId` / `pivotCellKey` and are now shared with the dashboard `DatasetWidget`, which carried the same defect and fixed it separately: two packages each hand-rolling the same key is why one fix left the other broken. The dashboard keeps its existing exports and behaviour.
|
|
371
|
+
|
|
372
|
+
- Updated dependencies [18cd432]
|
|
373
|
+
- Updated dependencies [b7165ce]
|
|
374
|
+
- Updated dependencies [532cf8b]
|
|
375
|
+
- Updated dependencies [680080a]
|
|
376
|
+
- Updated dependencies [a7651e6]
|
|
377
|
+
- Updated dependencies [d915c47]
|
|
378
|
+
- Updated dependencies [b71fc92]
|
|
379
|
+
- Updated dependencies [65516ba]
|
|
380
|
+
- Updated dependencies [94c5b7c]
|
|
381
|
+
- Updated dependencies [ca0fa8f]
|
|
382
|
+
- Updated dependencies [34595eb]
|
|
383
|
+
- Updated dependencies [3889ffb]
|
|
384
|
+
- Updated dependencies [5781fb1]
|
|
385
|
+
- Updated dependencies [7e2406a]
|
|
386
|
+
- Updated dependencies [9e9e9a9]
|
|
387
|
+
- Updated dependencies [19b8c9b]
|
|
388
|
+
- Updated dependencies [56409c2]
|
|
389
|
+
- Updated dependencies [042e09d]
|
|
390
|
+
- Updated dependencies [7d08c3f]
|
|
391
|
+
- Updated dependencies [9cbcbf4]
|
|
392
|
+
- Updated dependencies [85c4c9c]
|
|
393
|
+
- Updated dependencies [fd54c3e]
|
|
394
|
+
- Updated dependencies [4eeb932]
|
|
395
|
+
- Updated dependencies [6fe485b]
|
|
396
|
+
- Updated dependencies [5c856ec]
|
|
397
|
+
- Updated dependencies [23018cc]
|
|
398
|
+
- Updated dependencies [53811d1]
|
|
399
|
+
- Updated dependencies [68b6a28]
|
|
400
|
+
- Updated dependencies [0554e88]
|
|
401
|
+
- Updated dependencies [d915c47]
|
|
402
|
+
- Updated dependencies [f44d872]
|
|
403
|
+
- Updated dependencies [28b2e65]
|
|
404
|
+
- Updated dependencies [509104a]
|
|
405
|
+
- Updated dependencies [825bbe3]
|
|
406
|
+
- Updated dependencies [6195841]
|
|
407
|
+
- Updated dependencies [5dd0127]
|
|
408
|
+
- Updated dependencies [06632e9]
|
|
409
|
+
- Updated dependencies [a415684]
|
|
410
|
+
- Updated dependencies [a4cff5b]
|
|
411
|
+
- Updated dependencies [175bd79]
|
|
412
|
+
- Updated dependencies [5af2852]
|
|
413
|
+
- Updated dependencies [34d9169]
|
|
414
|
+
- Updated dependencies [5881a2c]
|
|
415
|
+
- Updated dependencies [9bc3709]
|
|
416
|
+
- Updated dependencies [f833d3a]
|
|
417
|
+
- Updated dependencies [30ae33a]
|
|
418
|
+
- Updated dependencies [a6ec93d]
|
|
419
|
+
- Updated dependencies [2a9513d]
|
|
420
|
+
- Updated dependencies [49f7449]
|
|
421
|
+
- Updated dependencies [71be406]
|
|
422
|
+
- Updated dependencies [d22ae31]
|
|
423
|
+
- Updated dependencies [c7ed4c3]
|
|
424
|
+
- Updated dependencies [2409e1d]
|
|
425
|
+
- Updated dependencies [789fe3e]
|
|
426
|
+
- Updated dependencies [f789c3b]
|
|
427
|
+
- Updated dependencies [a321fa4]
|
|
428
|
+
- Updated dependencies [8d8094a]
|
|
429
|
+
- @object-ui/core@17.3.0
|
|
430
|
+
- @object-ui/fields@17.3.0
|
|
431
|
+
- @object-ui/components@17.3.0
|
|
432
|
+
- @object-ui/types@17.3.0
|
|
433
|
+
- @object-ui/plugin-grid@17.3.0
|
|
434
|
+
- @object-ui/i18n@17.3.0
|
|
435
|
+
- @object-ui/react@17.3.0
|
|
436
|
+
|
|
3
437
|
## 17.2.0
|
|
4
438
|
|
|
5
439
|
### Patch Changes
|
|
@@ -1348,6 +1782,7 @@
|
|
|
1348
1782
|
The matrix/summary "Group by" (rows) and "Columns axis" (cols) sections now
|
|
1349
1783
|
share the same searchable popup picker as the columns section, with a
|
|
1350
1784
|
commit-on-select single-pick mode wired through `FieldPickerDialog`.
|
|
1785
|
+
|
|
1351
1786
|
- Per-row field buttons display the human-readable field label and open a
|
|
1352
1787
|
dialog scoped to swap that single field (already-used fields filtered out)
|
|
1353
1788
|
- "Add grouping" trigger uses the same dialog
|
|
@@ -1357,6 +1792,7 @@
|
|
|
1357
1792
|
- Bigger row spacing (h-7 / text-xs) — the old `text-[10px]` was unreadable
|
|
1358
1793
|
|
|
1359
1794
|
`FieldPickerDialog` gains:
|
|
1795
|
+
|
|
1360
1796
|
- `commitOnSelect`: hides the Confirm/Cancel footer; clicking a row commits
|
|
1361
1797
|
- closes immediately (intended for `singleSelect` flows)
|
|
1362
1798
|
- `trigger`: custom trigger element override (used by the per-row field button)
|
|
@@ -1406,6 +1842,7 @@
|
|
|
1406
1842
|
in the spec.
|
|
1407
1843
|
|
|
1408
1844
|
New exports from `@object-ui/plugin-report`:
|
|
1845
|
+
|
|
1409
1846
|
- `JoinedBlocksEditor` — standalone component for embedding the
|
|
1410
1847
|
block editor anywhere.
|
|
1411
1848
|
- `validateJoinedBlocks` — pure helper returning translated
|
|
@@ -1436,6 +1873,7 @@
|
|
|
1436
1873
|
The report configuration panel is now safe to open on any spec-shape `Report` and only exposes fields that are actually persisted by `@objectstack/spec`.
|
|
1437
1874
|
|
|
1438
1875
|
`@object-ui/plugin-report`:
|
|
1876
|
+
|
|
1439
1877
|
- Add a bidirectional `SpecFilterAdapter` so `ReportConfigPanel` can edit
|
|
1440
1878
|
spec `FilterCondition` filters (`{field: value}`, `{field: {$op: value}}`,
|
|
1441
1879
|
top-level `$and`/`$or`). Complex / nested filters fall back to a
|
|
@@ -1457,12 +1895,14 @@
|
|
|
1457
1895
|
- 18 new unit tests cover the filter adapter round-trip.
|
|
1458
1896
|
|
|
1459
1897
|
`@object-ui/components`:
|
|
1898
|
+
|
|
1460
1899
|
- `FilterBuilder` now guards against malformed external `value` props.
|
|
1461
1900
|
Previously a spec-shape filter (`{is_active: true}`) would crash the
|
|
1462
1901
|
component on first render; the builder now falls back to an empty
|
|
1463
1902
|
AND group whenever `value` is not a valid `FilterGroup`.
|
|
1464
1903
|
|
|
1465
1904
|
`@object-ui/i18n`:
|
|
1905
|
+
|
|
1466
1906
|
- Add `report.editor.*` strings to `en` and `zh`.
|
|
1467
1907
|
|
|
1468
1908
|
- 8442c05: Improve report editor panel usability based on real-user browser testing:
|
|
@@ -1523,6 +1963,7 @@
|
|
|
1523
1963
|
|
|
1524
1964
|
- 650392e: MatrixRenderer now displays i18n-translated labels for picklist (`select` / `status`) groupings instead of raw values (e.g. `Best Case` / `Commit` / `Pipeline` instead of `best_case` / `commit` / `pipeline`). Field labels in the corner cell, row/column total labels, and the `(Empty)` / `(All)` placeholders are also fully translated. Adds `report.*` keys to `en` and `zh` locale bundles.
|
|
1525
1965
|
- 26f5fce: Simplify report identity: replace the dashboard-style KPI grid with a compact "Totals" strip so reports look like reports (table-first with a grand total), not like mini-dashboards.
|
|
1966
|
+
|
|
1526
1967
|
- `SpecReportGrid` now renders one inline `Totals: Label1: value Label2: value …` strip above the chart and table, styled as a muted single-line band — clearly subordinate to the data grid below.
|
|
1527
1968
|
- The Totals strip is now also shown for `tabular` reports when they declare aggregating columns (matches Salesforce's "Grand Total" convention).
|
|
1528
1969
|
- Drop the duplicate chart title `<div>`: the chart component already renders its own title from `report.chart.title`.
|
|
@@ -1550,6 +1991,7 @@
|
|
|
1550
1991
|
### Minor Changes
|
|
1551
1992
|
|
|
1552
1993
|
- b4ce9e2: Fix summary reports: render chart + KPIs, correct empty-table on server-aggregated data.
|
|
1994
|
+
|
|
1553
1995
|
- `plugin-report`: `SpecReportGrid` now renders a KPI strip (per aggregating column) and a chart section above the grid for `summary` reports. KPI section auto-hides when no aggregating columns. New `buildChartData()` adapter buckets aggregated `ReportRow[]` to chart-ready data, auto-sorts pie/funnel descending, and falls back to row count when the chart `yAxis` points at a non-numeric column. When the data is server-aggregated, the grid switches columns to `[groupings, ${field}__${agg}]` so cells aren't empty against a raw-row column schema.
|
|
1554
1996
|
- `plugin-charts`: register `'column'` as an alias of `'bar'` in `ChartRenderer` / `AdvancedChartImpl` (Recharts only has `BarChart`).
|
|
1555
1997
|
- `app-shell`: `ReportView` now routes any object-backed report (matrix/joined/summary/tabular/columns/groupingsAcross) through the spec `ReportRenderer`; fully-legacy `fields`+`data` schemas still use `ReportViewer`.
|
|
@@ -1693,6 +2135,7 @@
|
|
|
1693
2135
|
Library builds (vite lib mode) now externalize every non-relative import instead of bundling third-party CJS dependencies into the published dist. This avoids inlined `require("react")` / `require("react-dom")` calls that cause `Calling \`require\` for "react" in an environment that doesn't expose the \`require\` function` runtime errors when consumer apps re-bundle the published dist.
|
|
1694
2136
|
|
|
1695
2137
|
Specifically fixes:
|
|
2138
|
+
|
|
1696
2139
|
- `@object-ui/plugin-dashboard` no longer inlines `react-grid-layout` (and its transitive `react-draggable` / `react-resizable` CJS bundles). `react-grid-layout` is now declared as a peer dependency so consumers install a single ESM-friendly copy.
|
|
1697
2140
|
- `@object-ui/components`, `@object-ui/plugin-calendar`, `@object-ui/plugin-charts`, `@object-ui/plugin-designer` no longer inline `react-i18next` / `i18next` / `use-sync-external-store` CJS shims.
|
|
1698
2141
|
- All plugin packages now use a unified `external: (id) => !/^[./]/.test(id) && !id.startsWith(__dirname)` rule, ensuring future additions of CJS deps are automatically externalized.
|
package/README.md
CHANGED
|
@@ -23,7 +23,6 @@ npm install @object-ui/plugin-report
|
|
|
23
23
|
**Peer Dependencies:**
|
|
24
24
|
- `react` ^18.0.0 || ^19.0.0
|
|
25
25
|
- `react-dom` ^18.0.0 || ^19.0.0
|
|
26
|
-
- `@object-ui/core`
|
|
27
26
|
|
|
28
27
|
## Quick Start
|
|
29
28
|
|
|
@@ -276,17 +275,6 @@ columns: [
|
|
|
276
275
|
Legacy `renderAs: 'badge'` + `colorMap` is still honoured for plain
|
|
277
276
|
string columns.
|
|
278
277
|
|
|
279
|
-
<!-- release-metadata:v3.3.0 -->
|
|
280
|
-
|
|
281
|
-
## Compatibility
|
|
282
|
-
|
|
283
|
-
- **React:** 18.x or 19.x
|
|
284
|
-
- **Node.js:** ≥ 18
|
|
285
|
-
- **TypeScript:** ≥ 5.0 (strict mode)
|
|
286
|
-
- **`@objectstack/spec`:** ^3.3.0
|
|
287
|
-
- **`@objectstack/client`:** ^3.3.0
|
|
288
|
-
- **Tailwind CSS:** ≥ 3.4 (for packages with UI)
|
|
289
|
-
|
|
290
278
|
## Links
|
|
291
279
|
|
|
292
280
|
- 📚 [Documentation](https://www.objectui.org/docs/plugins/plugin-report)
|