@ai-matrx/records 0.76.12 → 0.76.14
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 +12 -0
- package/dist/core/index.cjs +7 -8
- package/dist/core/index.cjs.map +1 -1
- package/dist/core/index.d.cts +1 -0
- package/dist/core/index.d.ts +1 -0
- package/dist/core/index.js +7 -8
- package/dist/core/index.js.map +1 -1
- package/dist/index.cjs +3 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +3 -2
- package/dist/index.js.map +1 -1
- package/dist/react/index.cjs +3 -2
- package/dist/react/index.cjs.map +1 -1
- package/dist/react/index.js +3 -2
- package/dist/react/index.js.map +1 -1
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# Changelog — @ai-matrx/records
|
|
2
2
|
|
|
3
|
+
## 0.76.14
|
|
4
|
+
|
|
5
|
+
Automatic changed-only republish (docs/metadata drift since the last tag — see
|
|
6
|
+
`git diff npm/records/v0.76.13..npm/records/v0.76.14 -- apps/shared/records`).
|
|
7
|
+
No source changes intended and no consumer action required.
|
|
8
|
+
|
|
9
|
+
## 0.76.13
|
|
10
|
+
|
|
11
|
+
- `exportCsv` writes through THE one writer, `@ai-matrx/kit/delimited` (AP-2): formula-looking text gets a leading `'` (OWASP CSV injection); it had no formula guard before. Same header row, quoting and order.
|
|
12
|
+
|
|
13
|
+
**Consumer action:** none.
|
|
14
|
+
|
|
3
15
|
## 0.76.11
|
|
4
16
|
|
|
5
17
|
Automatic changed-only republish (docs/metadata drift since the last tag — see
|
package/dist/core/index.cjs
CHANGED
|
@@ -4688,7 +4688,7 @@ function scopeChip(scope) {
|
|
|
4688
4688
|
|
|
4689
4689
|
// src/table-kind-mapping.json
|
|
4690
4690
|
var table_kind_mapping_default = {
|
|
4691
|
-
about: "THE ONE MAPPING from a store Field to a kind's three schemas (KINDS-GLUE wave 3 \xA72). Hand-written here; aidream copies it verbatim to packages/matrx-graph/matrx_graph/table_kind_mapping.json (scripts/generate_table_kind_mapping.py --check). Both languages derive from this file only: @ai-matrx/records src/table-kind.ts and matrx_graph.table_kinds. Keys of `kinds` are the store's field kinds (custom.field_kinds() plus the formula `system` kinds custom.field_kind_of answers). Stored mode only: `column_source_default` is custom.table_column_source's answer when the facts carry none (silence means the doctrine: Field rows are the columns); `platform_keys` mirrors custom.record_platform_keys() with each key's shape (parent_id: custom.containment_parent's uuid cast); `stored_patterns` mirror custom.validate_values' relation id regex and, for dates, refuse a string the timestamptz cast can never read (no digits, not a special word) while never refusing one it can.",
|
|
4691
|
+
about: "THE ONE MAPPING from a store Field to a kind's three schemas (KINDS-GLUE wave 3 \xA72). Hand-written here; aidream copies it verbatim to packages/matrx-graph/matrx_graph/table_kind_mapping.json (scripts/generate_table_kind_mapping.py --check). Both languages derive from this file only: @ai-matrx/records src/table-kind.ts and matrx_graph.table_kinds. Keys of `kinds` are the store's field kinds (custom.field_kinds() plus the formula `system` kinds custom.field_kind_of answers). Stored mode only: `column_source_default` is custom.table_column_source's answer when the facts carry none (silence means the doctrine: Field rows are the columns); `platform_keys` mirrors custom.record_platform_keys() with each key's shape (parent_id: custom.containment_parent's uuid cast; icon: the record's own @ai-matrx/icons name, a string or null); `stored_patterns` mirror custom.validate_values' relation id regex and, for dates, refuse a string the timestamptz cast can never read (no digits, not a special word) while never refusing one it can.",
|
|
4692
4692
|
version: 2,
|
|
4693
4693
|
kernels: {
|
|
4694
4694
|
file: "11111111-0000-4000-8000-000000000006",
|
|
@@ -4709,7 +4709,8 @@ var table_kind_mapping_default = {
|
|
|
4709
4709
|
address_part_max: 200,
|
|
4710
4710
|
column_source_default: "fields",
|
|
4711
4711
|
platform_keys: {
|
|
4712
|
-
parent_id: { type: ["string", "null"], pattern: "^(?:\\{[0-9a-fA-F]{4}(?:-?[0-9a-fA-F]{4}){7}\\}|[0-9a-fA-F]{4}(?:-?[0-9a-fA-F]{4}){7})$" }
|
|
4712
|
+
parent_id: { type: ["string", "null"], pattern: "^(?:\\{[0-9a-fA-F]{4}(?:-?[0-9a-fA-F]{4}){7}\\}|[0-9a-fA-F]{4}(?:-?[0-9a-fA-F]{4}){7})$" },
|
|
4713
|
+
icon: { type: ["string", "null"] }
|
|
4713
4714
|
},
|
|
4714
4715
|
stored_patterns: {
|
|
4715
4716
|
record_id: "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$",
|
|
@@ -9820,6 +9821,9 @@ function predictWriteRefusals(args) {
|
|
|
9820
9821
|
return found;
|
|
9821
9822
|
}
|
|
9822
9823
|
|
|
9824
|
+
// src/core/io.ts
|
|
9825
|
+
var import_delimited = require("@ai-matrx/kit/delimited");
|
|
9826
|
+
|
|
9823
9827
|
// src/core/wholeValue.ts
|
|
9824
9828
|
var import_format = require("@ai-matrx/kit/format");
|
|
9825
9829
|
var WHOLE_VALUE_SOURCE_KIND = "whole_value_in_file";
|
|
@@ -9872,7 +9876,6 @@ async function withWholeValues(rows2, read) {
|
|
|
9872
9876
|
}
|
|
9873
9877
|
|
|
9874
9878
|
// src/core/io.ts
|
|
9875
|
-
var escape = (value) => /[",\n\r]/.test(value) ? `"${value.replace(/"/g, '""')}"` : value;
|
|
9876
9879
|
function cellText(value) {
|
|
9877
9880
|
if (!value) return "";
|
|
9878
9881
|
if (value.absent_reason) return `(${value.absent_reason})`;
|
|
@@ -9894,11 +9897,7 @@ function headerFor(field) {
|
|
|
9894
9897
|
return field.label && field.label.length > 0 ? field.label : field.key;
|
|
9895
9898
|
}
|
|
9896
9899
|
function exportCsv(fields, rows2) {
|
|
9897
|
-
|
|
9898
|
-
for (const row of rows2) {
|
|
9899
|
-
lines.push(fields.map((f) => escape(exportCellText2(f, row[f.key]))).join(","));
|
|
9900
|
-
}
|
|
9901
|
-
return lines.join("\n");
|
|
9900
|
+
return (0, import_delimited.toDelimited)(toAoa(fields, rows2));
|
|
9902
9901
|
}
|
|
9903
9902
|
function toAoa(fields, rows2) {
|
|
9904
9903
|
return [fields.map(headerFor), ...rows2.map((row) => fields.map((f) => exportCellText2(f, row[f.key])))];
|