@dforge-core/metadata 0.0.30 → 0.0.31
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 +49 -1
- package/package.json +66 -67
- package/schemas/diagram.schema.json +8 -5
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,17 @@ All notable changes to `@dforge-core/metadata` are documented here.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
6
|
and this package adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [0.0.31] — 2026-09-24
|
|
9
|
+
|
|
10
|
+
### Changed
|
|
11
|
+
|
|
12
|
+
- **`diagram.schema.json` checks entity keys.** The `entities` keys and a relation's
|
|
13
|
+
`from` / `to` now share one `entityKey` definition: an entity code, optionally
|
|
14
|
+
qualified by module codes (`entity`, `module.entity`), each part an identifier the
|
|
15
|
+
installer accepts (`[a-zA-Z_][a-zA-Z0-9_-]*`). A key only had to be non-empty
|
|
16
|
+
before, so a typo such as `crm..party` or `sales order` passed validation and drew
|
|
17
|
+
a planned entity nobody meant.
|
|
18
|
+
|
|
8
19
|
## [0.0.30] — 2026-09-24
|
|
9
20
|
|
|
10
21
|
### Added
|
|
@@ -33,10 +44,16 @@ and this package adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
33
44
|
`field_type.def_params` (metadata system module 1.12.0). `defaultParams("email")`
|
|
34
45
|
had gone on returning `undefined`, and the seed-parity test failed.
|
|
35
46
|
|
|
36
|
-
## [0.0.
|
|
47
|
+
## [0.0.29] — 2026-09-22
|
|
48
|
+
|
|
49
|
+
0.0.28 was never published; its changes shipped as 0.0.29.
|
|
37
50
|
|
|
38
51
|
### Added
|
|
39
52
|
|
|
53
|
+
- **`pattern` and `patternFlags` in a column's `params`** (`entity.schema.json`) — a
|
|
54
|
+
per-column format rule that overrides the field type's own, as an ECMAScript regex
|
|
55
|
+
source. `patternFlags` takes `i`, `m` or both.
|
|
56
|
+
|
|
40
57
|
- **`schemas/stored_procedures.schema.json` and the types mirroring it** —
|
|
41
58
|
`StoredProceduresFile`, `StoredProcedureDef`, `SpParamDef`, `SpColumnDef`. The
|
|
42
59
|
authoring shape of `logic/stored_procedures.json`, which had no schema and no type
|
|
@@ -53,6 +70,37 @@ and this package adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
53
70
|
dataset schema is `additionalProperties: false`, editor validation *rejected* the
|
|
54
71
|
real one. Anyone authoring an SP dataset against the schema was told the correct
|
|
55
72
|
field was invalid and the wrong one was fine.
|
|
73
|
+
- **`accumulationConfig` requires `balanceEntity`, `dimensions` and `resources`
|
|
74
|
+
again.** 0.0.27 added `lockedFields` as a second `required` key in the same object;
|
|
75
|
+
the later key wins in JSON, so the other three stopped being required.
|
|
76
|
+
|
|
77
|
+
## [0.0.27] — 2026-09-21
|
|
78
|
+
|
|
79
|
+
### Added
|
|
80
|
+
|
|
81
|
+
- **`schemas/card_layouts.schema.json` and the types mirroring it** —
|
|
82
|
+
`CardLayoutsFile`, `CardLayoutDef`, `CardLayout`, `CardSection`
|
|
83
|
+
(`ColumnGroupSection` / `SetSection` / `TabGroupSection`), `CardTabRef`,
|
|
84
|
+
`CardFieldEntry`, `CardFieldDef`, `CardSetConfig`. The authoring shape of
|
|
85
|
+
`ui/card_layouts.json`.
|
|
86
|
+
- **`comments`** on an entity and on the manifest (`EntityDef.comments`,
|
|
87
|
+
`Manifest.comments`): records accept comments on the card. The manifest value is a
|
|
88
|
+
module-wide default that an entity overrides in either direction.
|
|
89
|
+
- **`registryColumnParams`** — the `params` of an accumulation (`A`) or ledger (`L`)
|
|
90
|
+
column: `lockedFields` (required), `lockedLineFields` with `lineEntity` /
|
|
91
|
+
`lineField`, `stateField`, and the period fields.
|
|
92
|
+
|
|
93
|
+
### Changed
|
|
94
|
+
|
|
95
|
+
- **`lockedFields` is required** on a posted document's registry config, and can't be
|
|
96
|
+
empty; `["*"]` freezes the whole row. `lockedFields?` became `lockedFields` in the
|
|
97
|
+
type.
|
|
98
|
+
|
|
99
|
+
### Removed
|
|
100
|
+
|
|
101
|
+
- **The `master-detail` view type.** Master/detail is a card layout — a `tabGroup`
|
|
102
|
+
of `set` sections — not a view type. `dataSources` no longer needs two entries
|
|
103
|
+
for it.
|
|
56
104
|
|
|
57
105
|
## [0.0.26] — 2026-09-15
|
|
58
106
|
|
package/package.json
CHANGED
|
@@ -1,68 +1,67 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
}
|
|
2
|
+
"name": "@dforge-core/metadata",
|
|
3
|
+
"version": "0.0.31",
|
|
4
|
+
"description": "Canonical dForge authoring registries — field types, base datatypes, column types, traits, data-view kinds and chart types — with derivation helpers. Runtime-dependency-free; the single source of truth shared by editors, the web app and the CLI.",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"author": "dForge",
|
|
7
|
+
"homepage": "https://github.com/iash44/dForge-core/tree/main/clients/packages/metadata#readme",
|
|
8
|
+
"repository": {
|
|
9
|
+
"type": "git",
|
|
10
|
+
"url": "git+https://github.com/iash44/dForge-core.git",
|
|
11
|
+
"directory": "clients/packages/metadata"
|
|
12
|
+
},
|
|
13
|
+
"bugs": {
|
|
14
|
+
"url": "https://github.com/iash44/dForge-core/issues"
|
|
15
|
+
},
|
|
16
|
+
"keywords": [
|
|
17
|
+
"dforge",
|
|
18
|
+
"metadata",
|
|
19
|
+
"field-type",
|
|
20
|
+
"trait",
|
|
21
|
+
"registry",
|
|
22
|
+
"low-code"
|
|
23
|
+
],
|
|
24
|
+
"publishConfig": {
|
|
25
|
+
"access": "public"
|
|
26
|
+
},
|
|
27
|
+
"type": "module",
|
|
28
|
+
"main": "./dist/index.js",
|
|
29
|
+
"module": "./dist/index.js",
|
|
30
|
+
"types": "./dist/index.d.ts",
|
|
31
|
+
"exports": {
|
|
32
|
+
".": {
|
|
33
|
+
"source": "./src/index.ts",
|
|
34
|
+
"types": "./dist/index.d.ts",
|
|
35
|
+
"default": "./dist/index.js"
|
|
36
|
+
},
|
|
37
|
+
"./dsl": {
|
|
38
|
+
"source": "./src/dsl/index.ts",
|
|
39
|
+
"types": "./dist/dsl/index.d.ts",
|
|
40
|
+
"default": "./dist/dsl/index.js"
|
|
41
|
+
},
|
|
42
|
+
"./schemas/*": "./schemas/*",
|
|
43
|
+
"./package.json": "./package.json"
|
|
44
|
+
},
|
|
45
|
+
"sideEffects": false,
|
|
46
|
+
"files": [
|
|
47
|
+
"dist",
|
|
48
|
+
"src",
|
|
49
|
+
"schemas",
|
|
50
|
+
"CHANGELOG.md"
|
|
51
|
+
],
|
|
52
|
+
"devDependencies": {
|
|
53
|
+
"@types/node": "^25.9.4",
|
|
54
|
+
"ajv": "^8.20.0",
|
|
55
|
+
"tsup": "^8.5.1",
|
|
56
|
+
"typescript": "^6.0.3",
|
|
57
|
+
"vitest": "^4.1.10"
|
|
58
|
+
},
|
|
59
|
+
"scripts": {
|
|
60
|
+
"sync-schemas": "node scripts/sync-schemas.mjs",
|
|
61
|
+
"build": "tsup",
|
|
62
|
+
"dev": "tsup --watch",
|
|
63
|
+
"typecheck": "tsc -p tsconfig.build.json --noEmit",
|
|
64
|
+
"test": "vitest run",
|
|
65
|
+
"package": "pnpm pack"
|
|
66
|
+
}
|
|
67
|
+
}
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
"type": "object",
|
|
22
22
|
"description": "Entity key → placement. A key is the entity code as the module's manifest names it, or `module.entity` for an entity of a dependency — the same form a field link's `entity` takes. A key no entity has yet is a planned entity, drawn as a name only. An empty object places the entity automatically.",
|
|
23
23
|
"propertyNames": {
|
|
24
|
-
"
|
|
24
|
+
"$ref": "#/$defs/entityKey"
|
|
25
25
|
},
|
|
26
26
|
"additionalProperties": {
|
|
27
27
|
"$ref": "#/$defs/diagramEntity"
|
|
@@ -46,6 +46,11 @@
|
|
|
46
46
|
},
|
|
47
47
|
"additionalProperties": false,
|
|
48
48
|
"$defs": {
|
|
49
|
+
"entityKey": {
|
|
50
|
+
"type": "string",
|
|
51
|
+
"pattern": "^([a-zA-Z_][a-zA-Z0-9_-]*\\.)*[a-zA-Z_][a-zA-Z0-9_-]*$",
|
|
52
|
+
"description": "An entity code, optionally qualified by its module's code: `entity`, `module.entity`. Each part is an identifier the installer accepts: `[a-zA-Z_][a-zA-Z0-9_-]*`."
|
|
53
|
+
},
|
|
49
54
|
"diagramEntity": {
|
|
50
55
|
"type": "object",
|
|
51
56
|
"properties": {
|
|
@@ -77,13 +82,11 @@
|
|
|
77
82
|
"required": ["from", "to"],
|
|
78
83
|
"properties": {
|
|
79
84
|
"from": {
|
|
80
|
-
"
|
|
81
|
-
"minLength": 1,
|
|
85
|
+
"$ref": "#/$defs/entityKey",
|
|
82
86
|
"description": "Entity key of the many side — the entity that will carry the foreign key."
|
|
83
87
|
},
|
|
84
88
|
"to": {
|
|
85
|
-
"
|
|
86
|
-
"minLength": 1,
|
|
89
|
+
"$ref": "#/$defs/entityKey",
|
|
87
90
|
"description": "Entity key of the one side — the entity referenced."
|
|
88
91
|
},
|
|
89
92
|
"label": {
|