@fabricorg/gen-sdui 0.2.1 → 0.5.0

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,37 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.5.0
4
+
5
+ ### Minor Changes
6
+
7
+ - Make the capability runtime vertical-neutral and instance-scoped. Move experience and display
8
+ semantics into a namespaced companion package, require explicit host registries, replace privacy
9
+ field defaults with caller-owned policy, add PostgreSQL projection adapters, and generate executable
10
+ ProjectionHost read and PlatformHost mutation seams.
11
+
12
+ ### Patch Changes
13
+
14
+ - Updated dependencies
15
+ - @fabricorg/experience-contracts@1.0.0
16
+ - @fabricorg/compiler@2.0.0
17
+
18
+ ## 0.4.0
19
+
20
+ - Read roles, slots, and action intents only from the versioned `fabric.experience/v1` extension.
21
+
22
+ ## 0.3.0
23
+
24
+ ### Minor Changes
25
+
26
+ - Deliver Phase 1 correctness and contracts: payload-bound idempotency with staged enforcement,
27
+ capture/replay authority evidence, bounded invocation provenance, capability execution and view usage
28
+ semantics, event-schema compatibility classification, and deterministic conformance plans.
29
+
30
+ ### Patch Changes
31
+
32
+ - Updated dependencies
33
+ - @fabricorg/compiler@1.0.0
34
+
3
35
  ## 0.2.1
4
36
 
5
37
  ### Patch Changes
package/dist/index.cjs CHANGED
@@ -24,9 +24,33 @@ __export(index_exports, {
24
24
  });
25
25
  module.exports = __toCommonJS(index_exports);
26
26
  var import_compiler = require("@fabricorg/compiler");
27
- var sduiGenerator = { name: "@fabricorg/gen-sdui", version: "0.2.1", generate(ir) {
28
- return ir.modules.map((module2) => ({ path: `${module2.namespace}/data-shapes.json`, content: (0, import_compiler.stableStringify)({ generator: { name: sduiGenerator.name, version: sduiGenerator.version }, manifestDigest: ir.manifestDigest, bindings: module2.views.map((view) => ({ uri: `capability://${view.name}`, version: view.version, shape: view.shape, scope: view.scope })) }) }));
29
- } };
27
+ var import_experience_contracts = require("@fabricorg/experience-contracts");
28
+ var sduiGenerator = {
29
+ name: "@fabricorg/gen-sdui",
30
+ version: "0.5.0",
31
+ generate(ir) {
32
+ return ir.modules.map((module2) => {
33
+ const experience = (0, import_experience_contracts.readExperienceMetadata)(module2.capability);
34
+ return {
35
+ path: `${module2.namespace}/data-shapes.json`,
36
+ content: (0, import_compiler.stableStringify)({
37
+ generator: { name: sduiGenerator.name, version: sduiGenerator.version },
38
+ manifestDigest: ir.manifestDigest,
39
+ roles: experience?.roles ?? [],
40
+ actionIntents: experience?.actionIntents ?? [],
41
+ slots: experience?.slots ?? [],
42
+ bindings: module2.views.map((view) => ({
43
+ uri: `capability://${view.name}`,
44
+ version: view.version,
45
+ shape: view.shape,
46
+ scope: view.scope,
47
+ usage: view.usage
48
+ }))
49
+ })
50
+ };
51
+ });
52
+ }
53
+ };
30
54
  // Annotate the CommonJS export names for ESM import in node:
31
55
  0 && (module.exports = {
32
56
  sduiGenerator
@@ -1 +1 @@
1
- {"version":3,"sources":["../index.ts"],"sourcesContent":["import { stableStringify,type GeneratorTarget } from \"@fabricorg/compiler\";\nexport const sduiGenerator:GeneratorTarget={name:\"@fabricorg/gen-sdui\",version:\"0.2.1\",generate(ir){return ir.modules.map((module)=>({path:`${module.namespace}/data-shapes.json`,content:stableStringify({generator:{name:sduiGenerator.name,version:sduiGenerator.version},manifestDigest:ir.manifestDigest,bindings:module.views.map((view)=>({uri:`capability://${view.name}`,version:view.version,shape:view.shape,scope:view.scope}))})}));}};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,sBAAqD;AAC9C,IAAM,gBAA8B,EAAC,MAAK,uBAAsB,SAAQ,SAAQ,SAAS,IAAG;AAAC,SAAO,GAAG,QAAQ,IAAI,CAACA,aAAU,EAAC,MAAK,GAAGA,QAAO,SAAS,qBAAoB,aAAQ,iCAAgB,EAAC,WAAU,EAAC,MAAK,cAAc,MAAK,SAAQ,cAAc,QAAO,GAAE,gBAAe,GAAG,gBAAe,UAASA,QAAO,MAAM,IAAI,CAAC,UAAQ,EAAC,KAAI,gBAAgB,KAAK,IAAI,IAAG,SAAQ,KAAK,SAAQ,OAAM,KAAK,OAAM,OAAM,KAAK,MAAK,EAAE,EAAC,CAAC,EAAC,EAAE;AAAE,EAAC;","names":["module"]}
1
+ {"version":3,"sources":["../index.ts"],"sourcesContent":["import { stableStringify, type GeneratorTarget } from \"@fabricorg/compiler\";\nimport { readExperienceMetadata } from \"@fabricorg/experience-contracts\";\n\nexport const sduiGenerator: GeneratorTarget = {\n\tname: \"@fabricorg/gen-sdui\",\n\tversion: \"0.5.0\",\n\tgenerate(ir) {\n\t\treturn ir.modules.map((module) => {\n\t\t\tconst experience = readExperienceMetadata(module.capability);\n\t\t\treturn {\n\t\t\t\tpath: `${module.namespace}/data-shapes.json`,\n\t\t\t\tcontent: stableStringify({\n\t\t\t\t\tgenerator: { name: sduiGenerator.name, version: sduiGenerator.version },\n\t\t\t\t\tmanifestDigest: ir.manifestDigest,\n\t\t\t\t\troles: experience?.roles ?? [],\n\t\t\t\t\tactionIntents: experience?.actionIntents ?? [],\n\t\t\t\t\tslots: experience?.slots ?? [],\n\t\t\t\t\tbindings: module.views.map((view) => ({\n\t\t\t\t\t\turi: `capability://${view.name}`,\n\t\t\t\t\t\tversion: view.version,\n\t\t\t\t\t\tshape: view.shape,\n\t\t\t\t\t\tscope: view.scope,\n\t\t\t\t\t\tusage: view.usage,\n\t\t\t\t\t})),\n\t\t\t\t}),\n\t\t\t};\n\t\t});\n\t},\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,sBAAsD;AACtD,kCAAuC;AAEhC,IAAM,gBAAiC;AAAA,EAC7C,MAAM;AAAA,EACN,SAAS;AAAA,EACT,SAAS,IAAI;AACZ,WAAO,GAAG,QAAQ,IAAI,CAACA,YAAW;AACjC,YAAM,iBAAa,oDAAuBA,QAAO,UAAU;AAC3D,aAAO;AAAA,QACN,MAAM,GAAGA,QAAO,SAAS;AAAA,QACzB,aAAS,iCAAgB;AAAA,UACxB,WAAW,EAAE,MAAM,cAAc,MAAM,SAAS,cAAc,QAAQ;AAAA,UACtE,gBAAgB,GAAG;AAAA,UACnB,OAAO,YAAY,SAAS,CAAC;AAAA,UAC7B,eAAe,YAAY,iBAAiB,CAAC;AAAA,UAC7C,OAAO,YAAY,SAAS,CAAC;AAAA,UAC7B,UAAUA,QAAO,MAAM,IAAI,CAAC,UAAU;AAAA,YACrC,KAAK,gBAAgB,KAAK,IAAI;AAAA,YAC9B,SAAS,KAAK;AAAA,YACd,OAAO,KAAK;AAAA,YACZ,OAAO,KAAK;AAAA,YACZ,OAAO,KAAK;AAAA,UACb,EAAE;AAAA,QACH,CAAC;AAAA,MACF;AAAA,IACD,CAAC;AAAA,EACF;AACD;","names":["module"]}
package/dist/index.js CHANGED
@@ -1,8 +1,32 @@
1
1
  // index.ts
2
2
  import { stableStringify } from "@fabricorg/compiler";
3
- var sduiGenerator = { name: "@fabricorg/gen-sdui", version: "0.2.1", generate(ir) {
4
- return ir.modules.map((module) => ({ path: `${module.namespace}/data-shapes.json`, content: stableStringify({ generator: { name: sduiGenerator.name, version: sduiGenerator.version }, manifestDigest: ir.manifestDigest, bindings: module.views.map((view) => ({ uri: `capability://${view.name}`, version: view.version, shape: view.shape, scope: view.scope })) }) }));
5
- } };
3
+ import { readExperienceMetadata } from "@fabricorg/experience-contracts";
4
+ var sduiGenerator = {
5
+ name: "@fabricorg/gen-sdui",
6
+ version: "0.5.0",
7
+ generate(ir) {
8
+ return ir.modules.map((module) => {
9
+ const experience = readExperienceMetadata(module.capability);
10
+ return {
11
+ path: `${module.namespace}/data-shapes.json`,
12
+ content: stableStringify({
13
+ generator: { name: sduiGenerator.name, version: sduiGenerator.version },
14
+ manifestDigest: ir.manifestDigest,
15
+ roles: experience?.roles ?? [],
16
+ actionIntents: experience?.actionIntents ?? [],
17
+ slots: experience?.slots ?? [],
18
+ bindings: module.views.map((view) => ({
19
+ uri: `capability://${view.name}`,
20
+ version: view.version,
21
+ shape: view.shape,
22
+ scope: view.scope,
23
+ usage: view.usage
24
+ }))
25
+ })
26
+ };
27
+ });
28
+ }
29
+ };
6
30
  export {
7
31
  sduiGenerator
8
32
  };
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../index.ts"],"sourcesContent":["import { stableStringify,type GeneratorTarget } from \"@fabricorg/compiler\";\nexport const sduiGenerator:GeneratorTarget={name:\"@fabricorg/gen-sdui\",version:\"0.2.1\",generate(ir){return ir.modules.map((module)=>({path:`${module.namespace}/data-shapes.json`,content:stableStringify({generator:{name:sduiGenerator.name,version:sduiGenerator.version},manifestDigest:ir.manifestDigest,bindings:module.views.map((view)=>({uri:`capability://${view.name}`,version:view.version,shape:view.shape,scope:view.scope}))})}));}};\n"],"mappings":";AAAA,SAAS,uBAA4C;AAC9C,IAAM,gBAA8B,EAAC,MAAK,uBAAsB,SAAQ,SAAQ,SAAS,IAAG;AAAC,SAAO,GAAG,QAAQ,IAAI,CAAC,YAAU,EAAC,MAAK,GAAG,OAAO,SAAS,qBAAoB,SAAQ,gBAAgB,EAAC,WAAU,EAAC,MAAK,cAAc,MAAK,SAAQ,cAAc,QAAO,GAAE,gBAAe,GAAG,gBAAe,UAAS,OAAO,MAAM,IAAI,CAAC,UAAQ,EAAC,KAAI,gBAAgB,KAAK,IAAI,IAAG,SAAQ,KAAK,SAAQ,OAAM,KAAK,OAAM,OAAM,KAAK,MAAK,EAAE,EAAC,CAAC,EAAC,EAAE;AAAE,EAAC;","names":[]}
1
+ {"version":3,"sources":["../index.ts"],"sourcesContent":["import { stableStringify, type GeneratorTarget } from \"@fabricorg/compiler\";\nimport { readExperienceMetadata } from \"@fabricorg/experience-contracts\";\n\nexport const sduiGenerator: GeneratorTarget = {\n\tname: \"@fabricorg/gen-sdui\",\n\tversion: \"0.5.0\",\n\tgenerate(ir) {\n\t\treturn ir.modules.map((module) => {\n\t\t\tconst experience = readExperienceMetadata(module.capability);\n\t\t\treturn {\n\t\t\t\tpath: `${module.namespace}/data-shapes.json`,\n\t\t\t\tcontent: stableStringify({\n\t\t\t\t\tgenerator: { name: sduiGenerator.name, version: sduiGenerator.version },\n\t\t\t\t\tmanifestDigest: ir.manifestDigest,\n\t\t\t\t\troles: experience?.roles ?? [],\n\t\t\t\t\tactionIntents: experience?.actionIntents ?? [],\n\t\t\t\t\tslots: experience?.slots ?? [],\n\t\t\t\t\tbindings: module.views.map((view) => ({\n\t\t\t\t\t\turi: `capability://${view.name}`,\n\t\t\t\t\t\tversion: view.version,\n\t\t\t\t\t\tshape: view.shape,\n\t\t\t\t\t\tscope: view.scope,\n\t\t\t\t\t\tusage: view.usage,\n\t\t\t\t\t})),\n\t\t\t\t}),\n\t\t\t};\n\t\t});\n\t},\n};\n"],"mappings":";AAAA,SAAS,uBAA6C;AACtD,SAAS,8BAA8B;AAEhC,IAAM,gBAAiC;AAAA,EAC7C,MAAM;AAAA,EACN,SAAS;AAAA,EACT,SAAS,IAAI;AACZ,WAAO,GAAG,QAAQ,IAAI,CAAC,WAAW;AACjC,YAAM,aAAa,uBAAuB,OAAO,UAAU;AAC3D,aAAO;AAAA,QACN,MAAM,GAAG,OAAO,SAAS;AAAA,QACzB,SAAS,gBAAgB;AAAA,UACxB,WAAW,EAAE,MAAM,cAAc,MAAM,SAAS,cAAc,QAAQ;AAAA,UACtE,gBAAgB,GAAG;AAAA,UACnB,OAAO,YAAY,SAAS,CAAC;AAAA,UAC7B,eAAe,YAAY,iBAAiB,CAAC;AAAA,UAC7C,OAAO,YAAY,SAAS,CAAC;AAAA,UAC7B,UAAU,OAAO,MAAM,IAAI,CAAC,UAAU;AAAA,YACrC,KAAK,gBAAgB,KAAK,IAAI;AAAA,YAC9B,SAAS,KAAK;AAAA,YACd,OAAO,KAAK;AAAA,YACZ,OAAO,KAAK;AAAA,YACZ,OAAO,KAAK;AAAA,UACb,EAAE;AAAA,QACH,CAAC;AAAA,MACF;AAAA,IACD,CAAC;AAAA,EACF;AACD;","names":[]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fabricorg/gen-sdui",
3
- "version": "0.2.1",
3
+ "version": "0.5.0",
4
4
  "description": "SDUI data-shape binding generator for Fabric compiler IR.",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -25,14 +25,15 @@
25
25
  "CHANGELOG.md"
26
26
  ],
27
27
  "dependencies": {
28
- "@fabricorg/compiler": "^0.2.1"
28
+ "@fabricorg/compiler": "^2.0.0",
29
+ "@fabricorg/experience-contracts": "^1.0.0"
29
30
  },
30
31
  "devDependencies": {
31
32
  "@types/node": "^22.10.0",
32
33
  "tsup": "^8.5.0",
33
34
  "typescript": "^5.7.3",
34
35
  "vitest": "^4.1.5",
35
- "@fabricorg/platform": "^0.11.1"
36
+ "@fabricorg/platform": "^1.0.0"
36
37
  },
37
38
  "engines": {
38
39
  "node": ">=20"