@bettercms-ai/kit 2.0.0-next.6 → 2.0.0-next.7
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/dist/adapters/lossy.d.ts +3 -3
- package/dist/adapters/lossy.js +3 -3
- package/dist/adapters/lossy.js.map +1 -1
- package/dist/adapters/prod-types.d.ts +48 -4
- package/dist/adapters/prod-types.js +4 -3
- package/dist/adapters/prod-types.js.map +1 -1
- package/dist/adapters/schema.d.ts +39 -0
- package/dist/adapters/schema.js +177 -32
- package/dist/adapters/schema.js.map +1 -1
- package/dist/controls/icon.d.ts +1 -1
- package/dist/controls/icon.js +1 -1
- package/dist/controls/icon.js.map +1 -1
- package/dist/index.js +2 -2
- package/dist/ledgers/exclusions.v1.js +103 -0
- package/dist/ledgers/exclusions.v1.js.map +1 -0
- package/dist/library/coverage.d.ts +13 -1
- package/dist/library/coverage.js +12 -1
- package/dist/library/coverage.js.map +1 -1
- package/dist/library/kit-catalog.json +149 -149
- package/dist/testing/coverage-extras.d.ts +8 -0
- package/dist/testing/coverage-extras.js +44 -0
- package/dist/testing/coverage-extras.js.map +1 -0
- package/dist/testing/exclusions.d.ts +30 -0
- package/dist/testing/exclusions.js +13 -0
- package/dist/testing/exclusions.js.map +1 -0
- package/package.json +2 -2
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Coverage extras: kit-own entries for what V2's corpus never exercises, kept OUT of the corpus (which stays V2
|
|
3
|
+
* verbatim: catalog-copy.test). coverageOf reports them as their own row, so the type count reads "28/29 from V2,
|
|
4
|
+
* json via extras" and never passes off a kit fixture as V2's. Each extra runs the same gates as a corpus entry.
|
|
5
|
+
*/
|
|
6
|
+
import type { CatalogItem } from "../library/catalog";
|
|
7
|
+
/** V2's corpus has no `json` field: one entry holds one, with a nested value, so the adapters and the dock carry it. */
|
|
8
|
+
export declare const COVERAGE_EXTRAS: CatalogItem[];
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
//#region src/testing/coverage-extras.ts
|
|
2
|
+
/** V2's corpus has no `json` field: one entry holds one, with a nested value, so the adapters and the dock carry it. */
|
|
3
|
+
var COVERAGE_EXTRAS = [{
|
|
4
|
+
id: "extra-json-field",
|
|
5
|
+
core: false,
|
|
6
|
+
category: "Advanced patterns",
|
|
7
|
+
tags: [],
|
|
8
|
+
hay: "json value extra",
|
|
9
|
+
ex: {
|
|
10
|
+
id: "extra-json-field",
|
|
11
|
+
label: "Raw JSON value",
|
|
12
|
+
proves: "A json field (the one type V2's corpus never uses) is carried by both lanes and edited in the dock",
|
|
13
|
+
schema: {
|
|
14
|
+
name: "jsonSettings",
|
|
15
|
+
title: "JSON settings",
|
|
16
|
+
kind: "object",
|
|
17
|
+
fields: [{
|
|
18
|
+
name: "title",
|
|
19
|
+
title: "Title",
|
|
20
|
+
type: "string"
|
|
21
|
+
}, {
|
|
22
|
+
name: "settings",
|
|
23
|
+
title: "Settings",
|
|
24
|
+
type: "json",
|
|
25
|
+
description: "Raw settings the site reads as they are."
|
|
26
|
+
}]
|
|
27
|
+
},
|
|
28
|
+
value: {
|
|
29
|
+
title: "Map widget",
|
|
30
|
+
settings: {
|
|
31
|
+
zoom: 12,
|
|
32
|
+
center: [52.37, 4.9],
|
|
33
|
+
layers: ["streets", {
|
|
34
|
+
id: "pins",
|
|
35
|
+
visible: true
|
|
36
|
+
}]
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
}];
|
|
41
|
+
//#endregion
|
|
42
|
+
export { COVERAGE_EXTRAS };
|
|
43
|
+
|
|
44
|
+
//# sourceMappingURL=coverage-extras.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"coverage-extras.js","names":[],"sources":["../../src/testing/coverage-extras.ts"],"sourcesContent":["/**\n * Coverage extras: kit-own entries for what V2's corpus never exercises, kept OUT of the corpus (which stays V2\n * verbatim: catalog-copy.test). coverageOf reports them as their own row, so the type count reads \"28/29 from V2,\n * json via extras\" and never passes off a kit fixture as V2's. Each extra runs the same gates as a corpus entry.\n */\nimport type { CatalogItem } from \"../library/catalog\";\n\n/** V2's corpus has no `json` field: one entry holds one, with a nested value, so the adapters and the dock carry it. */\nexport const COVERAGE_EXTRAS: CatalogItem[] = [\n {\n id: \"extra-json-field\",\n core: false,\n category: \"Advanced patterns\",\n tags: [],\n hay: \"json value extra\",\n ex: {\n id: \"extra-json-field\",\n label: \"Raw JSON value\",\n proves: \"A json field (the one type V2's corpus never uses) is carried by both lanes and edited in the dock\",\n schema: {\n name: \"jsonSettings\",\n title: \"JSON settings\",\n kind: \"object\",\n fields: [\n { name: \"title\", title: \"Title\", type: \"string\" },\n { name: \"settings\", title: \"Settings\", type: \"json\", description: \"Raw settings the site reads as they are.\" },\n ],\n },\n value: { title: \"Map widget\", settings: { zoom: 12, center: [52.37, 4.9], layers: [\"streets\", { id: \"pins\", visible: true }] } },\n },\n },\n];\n"],"mappings":";;AAQA,IAAa,kBAAiC,CAC5C;CACE,IAAI;CACJ,MAAM;CACN,UAAU;CACV,MAAM,CAAC;CACP,KAAK;CACL,IAAI;EACF,IAAI;EACJ,OAAO;EACP,QAAQ;EACR,QAAQ;GACN,MAAM;GACN,OAAO;GACP,MAAM;GACN,QAAQ,CACN;IAAE,MAAM;IAAS,OAAO;IAAS,MAAM;GAAS,GAChD;IAAE,MAAM;IAAY,OAAO;IAAY,MAAM;IAAQ,aAAa;GAA2C,CAC/G;EACF;EACA,OAAO;GAAE,OAAO;GAAc,UAAU;IAAE,MAAM;IAAI,QAAQ,CAAC,OAAO,GAAG;IAAG,QAAQ,CAAC,WAAW;KAAE,IAAI;KAAQ,SAAS;IAAK,CAAC;GAAE;EAAE;CACjI;AACF,CACF"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
export interface KitExclusion {
|
|
2
|
+
id: string;
|
|
3
|
+
plane: "schema" | "value";
|
|
4
|
+
/** the lossy feature it signs (adapters/lossy.ts FEATURES), or a backend rule's code */
|
|
5
|
+
feature?: string;
|
|
6
|
+
key?: string;
|
|
7
|
+
/** only this part of the feature (e.g. the Shopify subset of reference targets) */
|
|
8
|
+
pattern?: string;
|
|
9
|
+
reason: string;
|
|
10
|
+
signedBy: string;
|
|
11
|
+
}
|
|
12
|
+
export interface KitEquivalence {
|
|
13
|
+
id: string;
|
|
14
|
+
/** value: a stored value moved; schema: a definition key whose effect another key carries (its `feature` is not loss) */
|
|
15
|
+
plane: "schema" | "value";
|
|
16
|
+
/** schema plane: the lossy feature (adapters/lossy.ts CATALOG) the move accounts for */
|
|
17
|
+
feature?: string;
|
|
18
|
+
key: string;
|
|
19
|
+
/** where prod holds the fact instead */
|
|
20
|
+
moves: string;
|
|
21
|
+
/** what the gate's proof checks to read it back */
|
|
22
|
+
recovery: string;
|
|
23
|
+
/** schema plane: the V2 source (or the gate) that shows the key has no effect of its own, or where it is carried */
|
|
24
|
+
proof?: string;
|
|
25
|
+
/** the write that carries the fact (a planner): the gates measure it rather than exclude the feature */
|
|
26
|
+
carriedBy?: string;
|
|
27
|
+
ruledBy?: string;
|
|
28
|
+
}
|
|
29
|
+
export declare const EXCLUSIONS: KitExclusion[];
|
|
30
|
+
export declare const EQUIVALENCES: KitEquivalence[];
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import exclusions_v1_default from "../ledgers/exclusions.v1.js";
|
|
2
|
+
//#region src/testing/exclusions.ts
|
|
3
|
+
/**
|
|
4
|
+
* The exclusions ledger (ledgers/exclusions.v1.json), for the gates that hold the V2 → prod mapping to it: a lost key
|
|
5
|
+
* is an owner-signed exclusion or a proven equivalence (a representation move), never anything else. The dashboard's
|
|
6
|
+
* kitCorpusDock gate reads it from here.
|
|
7
|
+
*/
|
|
8
|
+
var EXCLUSIONS = exclusions_v1_default.exclusions;
|
|
9
|
+
var EQUIVALENCES = exclusions_v1_default.equivalences;
|
|
10
|
+
//#endregion
|
|
11
|
+
export { EQUIVALENCES, EXCLUSIONS };
|
|
12
|
+
|
|
13
|
+
//# sourceMappingURL=exclusions.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"exclusions.js","names":[],"sources":["../../src/testing/exclusions.ts"],"sourcesContent":["/**\n * The exclusions ledger (ledgers/exclusions.v1.json), for the gates that hold the V2 → prod mapping to it: a lost key\n * is an owner-signed exclusion or a proven equivalence (a representation move), never anything else. The dashboard's\n * kitCorpusDock gate reads it from here.\n */\nimport ledger from \"../../ledgers/exclusions.v1.json\";\n\nexport interface KitExclusion {\n id: string;\n plane: \"schema\" | \"value\";\n /** the lossy feature it signs (adapters/lossy.ts FEATURES), or a backend rule's code */\n feature?: string;\n key?: string;\n /** only this part of the feature (e.g. the Shopify subset of reference targets) */\n pattern?: string;\n reason: string;\n signedBy: string;\n}\n\nexport interface KitEquivalence {\n id: string;\n /** value: a stored value moved; schema: a definition key whose effect another key carries (its `feature` is not loss) */\n plane: \"schema\" | \"value\";\n /** schema plane: the lossy feature (adapters/lossy.ts CATALOG) the move accounts for */\n feature?: string;\n key: string;\n /** where prod holds the fact instead */\n moves: string;\n /** what the gate's proof checks to read it back */\n recovery: string;\n /** schema plane: the V2 source (or the gate) that shows the key has no effect of its own, or where it is carried */\n proof?: string;\n /** the write that carries the fact (a planner): the gates measure it rather than exclude the feature */\n carriedBy?: string;\n ruledBy?: string;\n}\n\nexport const EXCLUSIONS = ledger.exclusions as KitExclusion[];\nexport const EQUIVALENCES = ledger.equivalences as KitEquivalence[];\n"],"mappings":";;;;;;;AAqCA,IAAa,aAAa,sBAAO;AACjC,IAAa,eAAe,sBAAO"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bettercms-ai/kit",
|
|
3
|
-
"version": "2.0.0-next.
|
|
3
|
+
"version": "2.0.0-next.7",
|
|
4
4
|
"description": "The BetterCMS V2 Block Kit: schema language, form engine, controls and design tokens.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
},
|
|
74
74
|
"peerDependencies": {
|
|
75
75
|
"@base-ui/react": "^1.4.1",
|
|
76
|
-
"@bettercms-ai/types": "^1.
|
|
76
|
+
"@bettercms-ai/types": "^1.59.0",
|
|
77
77
|
"@tabler/icons-react": "^3.48.0",
|
|
78
78
|
"framer-motion": "^12.40.0",
|
|
79
79
|
"react": "^19.2.0",
|