@ai-matrx/records 0.86.2 → 0.87.2

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 CHANGED
@@ -1,5 +1,41 @@
1
1
  # Changelog — @ai-matrx/records
2
2
 
3
+ ## 0.87.2
4
+
5
+ Automatic changed-only republish (docs/metadata drift since the last tag — see
6
+ `git diff npm/records/v0.87.1..npm/records/v0.87.2 -- apps/shared/records`).
7
+ No source changes intended and no consumer action required.
8
+
9
+ ## 0.87.1
10
+
11
+ **One instance of shared state across every section.** Each built entry (root, core, react, realtime,
12
+ data, typed-table) and each module graph (ESM, CJS) carried its own copy of the op ledger and the
13
+ page-local change buses: `records/core` minted a write's op id in one copy while `records/realtime`
14
+ checked another, so a company's own write came back as somebody else's change, and a write announced by
15
+ the core client never reached `records/react` screens. The ledger, the record/table change listeners and
16
+ the removed-records set now live in `@ai-matrx/kit/global-slot` slots. Guard: `scripts/check-shared-state.mjs`,
17
+ run by `verify:tarball` in a consumer that installed the packed tarball (red on 0.87.0, green here).
18
+
19
+ **The headless package no longer installs the UI kit.** `ArchivedFilter` is spelled here
20
+ (`"active" | "archived" | "all"`) instead of imported from `@ai-matrx/design-system`, which moves to
21
+ devDependencies; `entity-list.types.test.ts` fails typecheck if the two vocabularies drift.
22
+
23
+ **Consumer action:** none for most hosts. A host that relied on records to install
24
+ `@ai-matrx/design-system` transitively must list it in its own dependencies.
25
+
26
+ ## 0.87.0 — a Column says one value or many, which column names a row, and which source a link reads
27
+
28
+ From the Applets social planner live test (2026-10-08): a choice column is `list` whether it holds one word or
29
+ many, so a form could not tell Status (one word) from Platforms (several) and sent `status: ["Planned"]`, which
30
+ `record_write` refused.
31
+ - **`Column.multi`** — the store's own `custom.field.multi`, set by `readTableShape` on every column.
32
+ - **`Column.title`** — true on the table's `title_field` column (`readTableShape` reads the table beside its
33
+ fields; a table it cannot read still answers its columns, with no title marked).
34
+ - **`Column.linksToSource`** — `createTableDataPort.columns()` names the alias, in the same port, that serves a
35
+ relation's target table, so a form can list the linked rows to pick from.
36
+ - **Consumer action:** none required (all three are optional additions). A form choosing an input by
37
+ `column.type === "list"` must read `column.multi` instead.
38
+
3
39
  ## 0.86.2
4
40
 
5
41
  Fix the incomplete 0.86.0 release: Confidential-table header stubs are now
@@ -2470,9 +2470,10 @@ function sourceArchivedOf(value) {
2470
2470
  }
2471
2471
 
2472
2472
  // src/ops.ts
2473
+ var import_global_slot = require("@ai-matrx/kit/global-slot");
2473
2474
  var REMEMBER_MS = 3e4;
2474
2475
  var REMEMBER_MAX = 500;
2475
- var ours = /* @__PURE__ */ new Map();
2476
+ var ours = (0, import_global_slot.globalSlot)("ai-matrx.records.op-ledger", () => /* @__PURE__ */ new Map());
2476
2477
  function trim(now) {
2477
2478
  for (const [id, at] of ours) {
2478
2479
  if (now - at <= REMEMBER_MS) break;
@@ -5265,7 +5266,8 @@ function isWritingDoor(door) {
5265
5266
  }
5266
5267
 
5267
5268
  // src/core/recordChanges.ts
5268
- var listeners = /* @__PURE__ */ new Set();
5269
+ var import_global_slot2 = require("@ai-matrx/kit/global-slot");
5270
+ var listeners = (0, import_global_slot2.globalSlot)("ai-matrx.records.record-change-listeners", () => /* @__PURE__ */ new Set());
5269
5271
  function announceRecordChanged(recordId) {
5270
5272
  for (const listener of [...listeners]) {
5271
5273
  try {
@@ -5275,7 +5277,7 @@ function announceRecordChanged(recordId) {
5275
5277
  }
5276
5278
  }
5277
5279
  }
5278
- var removed = /* @__PURE__ */ new Set();
5280
+ var removed = (0, import_global_slot2.globalSlot)("ai-matrx.records.removed-records", () => /* @__PURE__ */ new Set());
5279
5281
  function markRecordRemoved(recordId) {
5280
5282
  removed.add(recordId);
5281
5283
  }
@@ -5289,7 +5291,7 @@ function onRecordChanged(listener) {
5289
5291
  listeners.add(listener);
5290
5292
  return () => listeners.delete(listener);
5291
5293
  }
5292
- var tableListeners = /* @__PURE__ */ new Set();
5294
+ var tableListeners = (0, import_global_slot2.globalSlot)("ai-matrx.records.table-structure-listeners", () => /* @__PURE__ */ new Set());
5293
5295
  function announceTableStructureChanged(tableId) {
5294
5296
  for (const listener of [...tableListeners]) {
5295
5297
  try {