|
1 | 1 | # @pretable/react |
2 | 2 |
|
| 3 | +## 0.15.0 |
| 4 | + |
| 5 | +### Minor Changes |
| 6 | + |
| 7 | +- The grid can now tell you when its rendered data no longer matches what you ([#564](https://github.com/cacheplane/pretable/pull/564)) |
| 8 | + passed. Since invalid `rows`, `derivations`, and `query` updates became |
| 9 | + rejected writes, the grid kept its last-good value and stayed alive — but the |
| 10 | + only signal was a console warning that latches per fault kind, and there was |
| 11 | + no API to ask whether the rendered rows match the ones you passed. Now there |
| 12 | + is: |
| 13 | + |
| 14 | + - `model.rejectedWrites` (on `usePretable`'s return) is a per-kind record: |
| 15 | + `{ rows, derivations, query }`, each `null` when in sync or |
| 16 | + `{ kind, code, message, columnId? }` describing the most recent rejection. |
| 17 | + Nothing latches — every rejection replaces the record — and a slot clears |
| 18 | + on its own when a valid value lands. |
| 19 | + - `onRejectedWriteChange` on `PretableSurface` (and `LabeledGridSurface`) |
| 20 | + fires on every transition, including recovery, so a direct-Surface consumer |
| 21 | + can render a banner, retry, or fall back. |
| 22 | + - Rejections in `useLocalRowModel` (rows and derivations) surface through the |
| 23 | + same record, so model-mode consumers get the same answer. |
| 24 | + |
| 25 | + Console warnings are unchanged. Fatal faults (`disposed-model`, |
| 26 | + `reentrant-mutation`, foreign errors) still throw. |
| 27 | + |
| 28 | +### Patch Changes |
| 29 | + |
| 30 | +- Updated dependencies []: |
| 31 | + - @pretable/core@0.15.0 |
| 32 | + - @pretable/ui@0.15.0 |
| 33 | + |
3 | 34 | ## 0.14.4 |
4 | 35 |
|
5 | 36 | ### Patch Changes |
|
0 commit comments