@milaboratories/pl-model-middle-layer 1.16.2 → 1.16.4

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.
Files changed (108) hide show
  1. package/dist/_virtual/_rolldown/runtime.cjs +12 -22
  2. package/dist/_virtual/_rolldown/runtime.js +6 -11
  3. package/dist/block_meta/block_components.cjs +4 -5
  4. package/dist/block_meta/block_components.cjs.map +1 -1
  5. package/dist/block_meta/block_components.d.ts +30 -158
  6. package/dist/block_meta/block_components.d.ts.map +1 -0
  7. package/dist/block_meta/block_components.js +1 -2
  8. package/dist/block_meta/block_components.js.map +1 -1
  9. package/dist/block_meta/block_description.cjs +5 -6
  10. package/dist/block_meta/block_description.cjs.map +1 -1
  11. package/dist/block_meta/block_description.d.ts +10 -10
  12. package/dist/block_meta/block_description.d.ts.map +1 -0
  13. package/dist/block_meta/block_description.js +1 -2
  14. package/dist/block_meta/block_description.js.map +1 -1
  15. package/dist/block_meta/block_id.cjs +3 -4
  16. package/dist/block_meta/block_id.cjs.map +1 -1
  17. package/dist/block_meta/block_id.d.ts.map +1 -0
  18. package/dist/block_meta/block_id.js +1 -2
  19. package/dist/block_meta/block_id.js.map +1 -1
  20. package/dist/block_meta/block_manifest.cjs +6 -7
  21. package/dist/block_meta/block_manifest.cjs.map +1 -1
  22. package/dist/block_meta/block_manifest.d.ts +39 -39
  23. package/dist/block_meta/block_manifest.d.ts.map +1 -0
  24. package/dist/block_meta/block_manifest.js +1 -2
  25. package/dist/block_meta/block_manifest.js.map +1 -1
  26. package/dist/block_meta/block_meta.cjs +3 -4
  27. package/dist/block_meta/block_meta.cjs.map +1 -1
  28. package/dist/block_meta/block_meta.d.ts +9 -91
  29. package/dist/block_meta/block_meta.d.ts.map +1 -0
  30. package/dist/block_meta/block_meta.js +1 -2
  31. package/dist/block_meta/block_meta.js.map +1 -1
  32. package/dist/block_meta/common.d.ts.map +1 -0
  33. package/dist/block_meta/content_conversion.cjs +1 -2
  34. package/dist/block_meta/content_conversion.cjs.map +1 -1
  35. package/dist/block_meta/content_conversion.d.ts.map +1 -0
  36. package/dist/block_meta/content_conversion.js +1 -1
  37. package/dist/block_meta/content_types.cjs +2 -3
  38. package/dist/block_meta/content_types.cjs.map +1 -1
  39. package/dist/block_meta/content_types.d.ts.map +1 -0
  40. package/dist/block_meta/content_types.js +1 -2
  41. package/dist/block_meta/content_types.js.map +1 -1
  42. package/dist/block_meta/index.cjs +8 -8
  43. package/dist/block_meta/index.js +8 -8
  44. package/dist/block_meta/semver.cjs +3 -5
  45. package/dist/block_meta/semver.cjs.map +1 -1
  46. package/dist/block_meta/semver.d.ts.map +1 -0
  47. package/dist/block_meta/semver.js +1 -2
  48. package/dist/block_meta/semver.js.map +1 -1
  49. package/dist/block_registry/block_pack_spec.cjs +4 -5
  50. package/dist/block_registry/block_pack_spec.cjs.map +1 -1
  51. package/dist/block_registry/block_pack_spec.d.ts.map +1 -0
  52. package/dist/block_registry/block_pack_spec.js +1 -2
  53. package/dist/block_registry/block_pack_spec.js.map +1 -1
  54. package/dist/block_registry/index.cjs +3 -3
  55. package/dist/block_registry/index.js +3 -3
  56. package/dist/block_registry/overview.cjs +10 -11
  57. package/dist/block_registry/overview.cjs.map +1 -1
  58. package/dist/block_registry/overview.d.ts +154 -154
  59. package/dist/block_registry/overview.d.ts.map +1 -0
  60. package/dist/block_registry/overview.js +2 -3
  61. package/dist/block_registry/overview.js.map +1 -1
  62. package/dist/block_registry/registry_spec.cjs +2 -3
  63. package/dist/block_registry/registry_spec.cjs.map +1 -1
  64. package/dist/block_registry/registry_spec.d.ts +12 -12
  65. package/dist/block_registry/registry_spec.d.ts.map +1 -0
  66. package/dist/block_registry/registry_spec.js +1 -2
  67. package/dist/block_registry/registry_spec.js.map +1 -1
  68. package/dist/block_settings.cjs +1 -2
  69. package/dist/block_settings.cjs.map +1 -1
  70. package/dist/block_settings.d.ts.map +1 -0
  71. package/dist/block_settings.js +1 -1
  72. package/dist/block_state.d.ts.map +1 -0
  73. package/dist/index.cjs +23 -24
  74. package/dist/index.d.ts +0 -3
  75. package/dist/index.js +1 -2
  76. package/dist/json.cjs +2 -3
  77. package/dist/json.cjs.map +1 -1
  78. package/dist/json.d.ts.map +1 -0
  79. package/dist/json.js +1 -2
  80. package/dist/json.js.map +1 -1
  81. package/dist/pframe/internal_api/api_factory.cjs +1 -2
  82. package/dist/pframe/internal_api/api_factory.cjs.map +1 -1
  83. package/dist/pframe/internal_api/api_factory.d.ts.map +1 -0
  84. package/dist/pframe/internal_api/api_factory.js +1 -1
  85. package/dist/pframe/internal_api/api_read.d.ts.map +1 -0
  86. package/dist/pframe/internal_api/api_wasm.d.ts.map +1 -0
  87. package/dist/pframe/internal_api/common.d.ts.map +1 -0
  88. package/dist/pframe/internal_api/create_table.d.ts.map +1 -0
  89. package/dist/pframe/internal_api/delete_column.d.ts.map +1 -0
  90. package/dist/pframe/internal_api/discover_columns.d.ts.map +1 -0
  91. package/dist/pframe/internal_api/find_columns.d.ts.map +1 -0
  92. package/dist/pframe/internal_api/http_helpers.cjs +1 -2
  93. package/dist/pframe/internal_api/http_helpers.cjs.map +1 -1
  94. package/dist/pframe/internal_api/http_helpers.d.ts.map +1 -0
  95. package/dist/pframe/internal_api/http_helpers.js +1 -1
  96. package/dist/pframe/internal_api/http_helpers.js.map +1 -1
  97. package/dist/pframe/internal_api/index.cjs +9 -10
  98. package/dist/pframe/internal_api/index.d.ts.map +1 -0
  99. package/dist/pframe/internal_api/index.js +1 -2
  100. package/dist/pframe/internal_api/pframe.d.ts.map +1 -0
  101. package/dist/pframe/internal_api/table.d.ts.map +1 -0
  102. package/dist/project.d.ts.map +1 -0
  103. package/dist/project_list.d.ts.map +1 -0
  104. package/dist/project_overview.d.ts.map +1 -0
  105. package/dist/storage_debug_view.d.ts.map +1 -0
  106. package/dist/update_info.d.ts +0 -2
  107. package/dist/update_info.d.ts.map +1 -0
  108. package/package.json +7 -7
@@ -7,28 +7,20 @@ var __getProtoOf = Object.getPrototypeOf;
7
7
  var __hasOwnProp = Object.prototype.hasOwnProperty;
8
8
  var __exportAll = (all, no_symbols) => {
9
9
  let target = {};
10
- for (var name in all) {
11
- __defProp(target, name, {
12
- get: all[name],
13
- enumerable: true
14
- });
15
- }
16
- if (!no_symbols) {
17
- __defProp(target, Symbol.toStringTag, { value: "Module" });
18
- }
10
+ for (var name in all) __defProp(target, name, {
11
+ get: all[name],
12
+ enumerable: true
13
+ });
14
+ if (!no_symbols) __defProp(target, Symbol.toStringTag, { value: "Module" });
19
15
  return target;
20
16
  };
21
17
  var __copyProps = (to, from, except, desc) => {
22
- if (from && typeof from === "object" || typeof from === "function") {
23
- for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
24
- key = keys[i];
25
- if (!__hasOwnProp.call(to, key) && key !== except) {
26
- __defProp(to, key, {
27
- get: ((k) => from[k]).bind(null, key),
28
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
29
- });
30
- }
31
- }
18
+ if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
19
+ key = keys[i];
20
+ if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
21
+ get: ((k) => from[k]).bind(null, key),
22
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
23
+ });
32
24
  }
33
25
  return to;
34
26
  };
@@ -36,8 +28,6 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
36
28
  value: mod,
37
29
  enumerable: true
38
30
  }) : target, mod));
39
-
40
31
  //#endregion
41
-
42
32
  exports.__exportAll = __exportAll;
43
- exports.__toESM = __toESM;
33
+ exports.__toESM = __toESM;
@@ -2,17 +2,12 @@
2
2
  var __defProp = Object.defineProperty;
3
3
  var __exportAll = (all, no_symbols) => {
4
4
  let target = {};
5
- for (var name in all) {
6
- __defProp(target, name, {
7
- get: all[name],
8
- enumerable: true
9
- });
10
- }
11
- if (!no_symbols) {
12
- __defProp(target, Symbol.toStringTag, { value: "Module" });
13
- }
5
+ for (var name in all) __defProp(target, name, {
6
+ get: all[name],
7
+ enumerable: true
8
+ });
9
+ if (!no_symbols) __defProp(target, Symbol.toStringTag, { value: "Module" });
14
10
  return target;
15
11
  };
16
-
17
12
  //#endregion
18
- export { __exportAll };
13
+ export { __exportAll };
@@ -1,8 +1,7 @@
1
- const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
2
- const require_content_types = require('./content_types.cjs');
3
- const require_content_conversion = require('./content_conversion.cjs');
1
+ require("../_virtual/_rolldown/runtime.cjs");
2
+ const require_content_types = require("./content_types.cjs");
3
+ const require_content_conversion = require("./content_conversion.cjs");
4
4
  let zod = require("zod");
5
-
6
5
  //#region src/block_meta/block_components.ts
7
6
  function WorkflowV1(contentType) {
8
7
  return zod.z.object({
@@ -27,11 +26,11 @@ const BlockComponentsDescriptionRaw = BlockComponents(zod.z.string(), zod.z.stri
27
26
  function BlockComponentsAbsoluteUrl(prefix) {
28
27
  return BlockComponents(require_content_types.ContentRelativeBinary.transform(require_content_conversion.mapRemoteToAbsolute(prefix)), require_content_types.ContentRelativeBinary.transform(require_content_conversion.mapRemoteToAbsolute(prefix)));
29
28
  }
30
-
31
29
  //#endregion
32
30
  exports.BlockComponents = BlockComponents;
33
31
  exports.BlockComponentsAbsoluteUrl = BlockComponentsAbsoluteUrl;
34
32
  exports.BlockComponentsDescriptionRaw = BlockComponentsDescriptionRaw;
35
33
  exports.Workflow = Workflow;
36
34
  exports.WorkflowV1 = WorkflowV1;
35
+
37
36
  //# sourceMappingURL=block_components.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"block_components.cjs","names":["z","ContentRelativeBinary","mapRemoteToAbsolute"],"sources":["../../src/block_meta/block_components.ts"],"sourcesContent":["import { z } from \"zod\";\nimport { ContentRelativeBinary } from \"./content_types\";\nimport { mapRemoteToAbsolute } from \"./content_conversion\";\n\nexport function WorkflowV1<const Content extends z.ZodTypeAny>(contentType: Content) {\n return z.object({\n type: z.literal(\"workflow-v1\"),\n main: contentType.describe(\"Main workflow\"),\n });\n}\n\nexport function Workflow<const Content extends z.ZodTypeAny>(contentType: Content) {\n return z.union([\n // string is converted to v1 workflow\n contentType\n .transform((value: z.infer<typeof contentType>) => ({\n type: \"workflow-v1\" as const,\n main: value,\n }))\n .pipe(WorkflowV1(contentType)),\n // structured objects are decoded as union with type descriptor\n z.discriminatedUnion(\"type\", [WorkflowV1(contentType)]),\n ]);\n}\n\nexport function BlockComponents<\n const WfAndModel extends z.ZodTypeAny,\n const UI extends z.ZodTypeAny,\n>(wfAndModel: WfAndModel, ui: UI) {\n return z.object({\n workflow: Workflow(wfAndModel),\n model: wfAndModel,\n ui,\n });\n}\n\nexport const BlockComponentsDescriptionRaw = BlockComponents(z.string(), z.string());\nexport type BlockComponentsDescriptionRaw = z.infer<typeof BlockComponentsDescriptionRaw>;\n\nexport function BlockComponentsAbsoluteUrl(prefix: string) {\n return BlockComponents(\n ContentRelativeBinary.transform(mapRemoteToAbsolute(prefix)),\n ContentRelativeBinary.transform(mapRemoteToAbsolute(prefix)),\n );\n}\nexport type BlockComponentsAbsolute = z.infer<ReturnType<typeof BlockComponentsAbsoluteUrl>>;\n\n// export const BlockComponentsExplicit = BlockComponents(, ContentRelative);\n// export type BlockComponentsExplicit = z.infer<typeof BlockComponentsExplicit>;\n"],"mappings":";;;;;;AAIA,SAAgB,WAA+C,aAAsB;AACnF,QAAOA,MAAE,OAAO;EACd,MAAMA,MAAE,QAAQ,cAAc;EAC9B,MAAM,YAAY,SAAS,gBAAgB;EAC5C,CAAC;;AAGJ,SAAgB,SAA6C,aAAsB;AACjF,QAAOA,MAAE,MAAM,CAEb,YACG,WAAW,WAAwC;EAClD,MAAM;EACN,MAAM;EACP,EAAE,CACF,KAAK,WAAW,YAAY,CAAC,EAEhCA,MAAE,mBAAmB,QAAQ,CAAC,WAAW,YAAY,CAAC,CAAC,CACxD,CAAC;;AAGJ,SAAgB,gBAGd,YAAwB,IAAQ;AAChC,QAAOA,MAAE,OAAO;EACd,UAAU,SAAS,WAAW;EAC9B,OAAO;EACP;EACD,CAAC;;AAGJ,MAAa,gCAAgC,gBAAgBA,MAAE,QAAQ,EAAEA,MAAE,QAAQ,CAAC;AAGpF,SAAgB,2BAA2B,QAAgB;AACzD,QAAO,gBACLC,4CAAsB,UAAUC,+CAAoB,OAAO,CAAC,EAC5DD,4CAAsB,UAAUC,+CAAoB,OAAO,CAAC,CAC7D"}
1
+ {"version":3,"file":"block_components.cjs","names":["z","ContentRelativeBinary","mapRemoteToAbsolute"],"sources":["../../src/block_meta/block_components.ts"],"sourcesContent":["import { z } from \"zod\";\nimport { ContentRelativeBinary } from \"./content_types\";\nimport { mapRemoteToAbsolute } from \"./content_conversion\";\n\nexport function WorkflowV1<const Content extends z.ZodTypeAny>(contentType: Content) {\n return z.object({\n type: z.literal(\"workflow-v1\"),\n main: contentType.describe(\"Main workflow\"),\n });\n}\n\nexport function Workflow<const Content extends z.ZodTypeAny>(contentType: Content) {\n return z.union([\n // string is converted to v1 workflow\n contentType\n .transform((value: z.infer<typeof contentType>) => ({\n type: \"workflow-v1\" as const,\n main: value,\n }))\n .pipe(WorkflowV1(contentType)),\n // structured objects are decoded as union with type descriptor\n z.discriminatedUnion(\"type\", [WorkflowV1(contentType)]),\n ]);\n}\n\nexport function BlockComponents<\n const WfAndModel extends z.ZodTypeAny,\n const UI extends z.ZodTypeAny,\n>(wfAndModel: WfAndModel, ui: UI) {\n return z.object({\n workflow: Workflow(wfAndModel),\n model: wfAndModel,\n ui,\n });\n}\n\nexport const BlockComponentsDescriptionRaw = BlockComponents(z.string(), z.string());\nexport type BlockComponentsDescriptionRaw = z.infer<typeof BlockComponentsDescriptionRaw>;\n\nexport function BlockComponentsAbsoluteUrl(prefix: string) {\n return BlockComponents(\n ContentRelativeBinary.transform(mapRemoteToAbsolute(prefix)),\n ContentRelativeBinary.transform(mapRemoteToAbsolute(prefix)),\n );\n}\nexport type BlockComponentsAbsolute = z.infer<ReturnType<typeof BlockComponentsAbsoluteUrl>>;\n\n// export const BlockComponentsExplicit = BlockComponents(, ContentRelative);\n// export type BlockComponentsExplicit = z.infer<typeof BlockComponentsExplicit>;\n"],"mappings":";;;;;AAIA,SAAgB,WAA+C,aAAsB;AACnF,QAAOA,IAAAA,EAAE,OAAO;EACd,MAAMA,IAAAA,EAAE,QAAQ,cAAc;EAC9B,MAAM,YAAY,SAAS,gBAAgB;EAC5C,CAAC;;AAGJ,SAAgB,SAA6C,aAAsB;AACjF,QAAOA,IAAAA,EAAE,MAAM,CAEb,YACG,WAAW,WAAwC;EAClD,MAAM;EACN,MAAM;EACP,EAAE,CACF,KAAK,WAAW,YAAY,CAAC,EAEhCA,IAAAA,EAAE,mBAAmB,QAAQ,CAAC,WAAW,YAAY,CAAC,CAAC,CACxD,CAAC;;AAGJ,SAAgB,gBAGd,YAAwB,IAAQ;AAChC,QAAOA,IAAAA,EAAE,OAAO;EACd,UAAU,SAAS,WAAW;EAC9B,OAAO;EACP;EACD,CAAC;;AAGJ,MAAa,gCAAgC,gBAAgBA,IAAAA,EAAE,QAAQ,EAAEA,IAAAA,EAAE,QAAQ,CAAC;AAGpF,SAAgB,2BAA2B,QAAgB;AACzD,QAAO,gBACLC,sBAAAA,sBAAsB,UAAUC,2BAAAA,oBAAoB,OAAO,CAAC,EAC5DD,sBAAAA,sBAAsB,UAAUC,2BAAAA,oBAAoB,OAAO,CAAC,CAC7D"}
@@ -4,53 +4,35 @@ import { z } from "zod";
4
4
  declare function WorkflowV1<const Content extends z.ZodTypeAny>(contentType: Content): z.ZodObject<{
5
5
  type: z.ZodLiteral<"workflow-v1">;
6
6
  main: Content;
7
- }, "strip", z.ZodTypeAny, { [k in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
7
+ }, "strip", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
8
8
  type: z.ZodLiteral<"workflow-v1">;
9
9
  main: Content;
10
- }>, any>]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
10
+ }>, any> extends infer T ? { [k in keyof T]: T[k] } : never, z.baseObjectInputType<{
11
11
  type: z.ZodLiteral<"workflow-v1">;
12
12
  main: Content;
13
- }>, any>[k] }, { [k_1 in keyof z.baseObjectInputType<{
14
- type: z.ZodLiteral<"workflow-v1">;
15
- main: Content;
16
- }>]: z.baseObjectInputType<{
17
- type: z.ZodLiteral<"workflow-v1">;
18
- main: Content;
19
- }>[k_1] }>;
13
+ }> extends infer T_1 ? { [k_1 in keyof T_1]: T_1[k_1] } : never>;
20
14
  declare function Workflow<const Content extends z.ZodTypeAny>(contentType: Content): z.ZodUnion<[z.ZodPipeline<z.ZodEffects<Content, {
21
15
  type: "workflow-v1";
22
16
  main: z.TypeOf<Content>;
23
17
  }, z.input<Content>>, z.ZodObject<{
24
18
  type: z.ZodLiteral<"workflow-v1">;
25
19
  main: Content;
26
- }, "strip", z.ZodTypeAny, { [k in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
27
- type: z.ZodLiteral<"workflow-v1">;
28
- main: Content;
29
- }>, any>]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
30
- type: z.ZodLiteral<"workflow-v1">;
31
- main: Content;
32
- }>, any>[k] }, { [k_1 in keyof z.baseObjectInputType<{
33
- type: z.ZodLiteral<"workflow-v1">;
34
- main: Content;
35
- }>]: z.baseObjectInputType<{
36
- type: z.ZodLiteral<"workflow-v1">;
37
- main: Content;
38
- }>[k_1] }>>, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
20
+ }, "strip", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
39
21
  type: z.ZodLiteral<"workflow-v1">;
40
22
  main: Content;
41
- }, "strip", z.ZodTypeAny, { [k in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
23
+ }>, any> extends infer T ? { [k in keyof T]: T[k] } : never, z.baseObjectInputType<{
42
24
  type: z.ZodLiteral<"workflow-v1">;
43
25
  main: Content;
44
- }>, any>]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
26
+ }> extends infer T_1 ? { [k_1 in keyof T_1]: T_1[k_1] } : never>>, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
45
27
  type: z.ZodLiteral<"workflow-v1">;
46
28
  main: Content;
47
- }>, any>[k] }, { [k_1 in keyof z.baseObjectInputType<{
29
+ }, "strip", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
48
30
  type: z.ZodLiteral<"workflow-v1">;
49
31
  main: Content;
50
- }>]: z.baseObjectInputType<{
32
+ }>, any> extends infer T_2 ? { [k in keyof T_2]: T_2[k] } : never, z.baseObjectInputType<{
51
33
  type: z.ZodLiteral<"workflow-v1">;
52
34
  main: Content;
53
- }>[k_1] }>]>]>;
35
+ }> extends infer T_3 ? { [k_1 in keyof T_3]: T_3[k_1] } : never>]>]>;
54
36
  declare function BlockComponents<const WfAndModel extends z.ZodTypeAny, const UI extends z.ZodTypeAny>(wfAndModel: WfAndModel, ui: UI): z.ZodObject<{
55
37
  workflow: z.ZodUnion<[z.ZodPipeline<z.ZodEffects<WfAndModel, {
56
38
  type: "workflow-v1";
@@ -58,185 +40,75 @@ declare function BlockComponents<const WfAndModel extends z.ZodTypeAny, const UI
58
40
  }, z.input<WfAndModel>>, z.ZodObject<{
59
41
  type: z.ZodLiteral<"workflow-v1">;
60
42
  main: WfAndModel;
61
- }, "strip", z.ZodTypeAny, { [k in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
62
- type: z.ZodLiteral<"workflow-v1">;
63
- main: WfAndModel;
64
- }>, any>]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
65
- type: z.ZodLiteral<"workflow-v1">;
66
- main: WfAndModel;
67
- }>, any>[k] }, { [k_1 in keyof z.baseObjectInputType<{
68
- type: z.ZodLiteral<"workflow-v1">;
69
- main: WfAndModel;
70
- }>]: z.baseObjectInputType<{
71
- type: z.ZodLiteral<"workflow-v1">;
72
- main: WfAndModel;
73
- }>[k_1] }>>, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
74
- type: z.ZodLiteral<"workflow-v1">;
75
- main: WfAndModel;
76
- }, "strip", z.ZodTypeAny, { [k in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
77
- type: z.ZodLiteral<"workflow-v1">;
78
- main: WfAndModel;
79
- }>, any>]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
80
- type: z.ZodLiteral<"workflow-v1">;
81
- main: WfAndModel;
82
- }>, any>[k] }, { [k_1 in keyof z.baseObjectInputType<{
83
- type: z.ZodLiteral<"workflow-v1">;
84
- main: WfAndModel;
85
- }>]: z.baseObjectInputType<{
86
- type: z.ZodLiteral<"workflow-v1">;
87
- main: WfAndModel;
88
- }>[k_1] }>]>]>;
89
- model: WfAndModel;
90
- ui: UI;
91
- }, "strip", z.ZodTypeAny, { [k_2 in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
92
- workflow: z.ZodUnion<[z.ZodPipeline<z.ZodEffects<WfAndModel, {
93
- type: "workflow-v1";
94
- main: z.TypeOf<WfAndModel>;
95
- }, z.input<WfAndModel>>, z.ZodObject<{
96
- type: z.ZodLiteral<"workflow-v1">;
97
- main: WfAndModel;
98
- }, "strip", z.ZodTypeAny, { [k in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
99
- type: z.ZodLiteral<"workflow-v1">;
100
- main: WfAndModel;
101
- }>, any>]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
102
- type: z.ZodLiteral<"workflow-v1">;
103
- main: WfAndModel;
104
- }>, any>[k] }, { [k_1 in keyof z.baseObjectInputType<{
105
- type: z.ZodLiteral<"workflow-v1">;
106
- main: WfAndModel;
107
- }>]: z.baseObjectInputType<{
108
- type: z.ZodLiteral<"workflow-v1">;
109
- main: WfAndModel;
110
- }>[k_1] }>>, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
111
- type: z.ZodLiteral<"workflow-v1">;
112
- main: WfAndModel;
113
- }, "strip", z.ZodTypeAny, { [k in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
114
- type: z.ZodLiteral<"workflow-v1">;
115
- main: WfAndModel;
116
- }>, any>]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
117
- type: z.ZodLiteral<"workflow-v1">;
118
- main: WfAndModel;
119
- }>, any>[k] }, { [k_1 in keyof z.baseObjectInputType<{
120
- type: z.ZodLiteral<"workflow-v1">;
121
- main: WfAndModel;
122
- }>]: z.baseObjectInputType<{
123
- type: z.ZodLiteral<"workflow-v1">;
124
- main: WfAndModel;
125
- }>[k_1] }>]>]>;
126
- model: WfAndModel;
127
- ui: UI;
128
- }>, any>]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
129
- workflow: z.ZodUnion<[z.ZodPipeline<z.ZodEffects<WfAndModel, {
130
- type: "workflow-v1";
131
- main: z.TypeOf<WfAndModel>;
132
- }, z.input<WfAndModel>>, z.ZodObject<{
133
- type: z.ZodLiteral<"workflow-v1">;
134
- main: WfAndModel;
135
- }, "strip", z.ZodTypeAny, { [k in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
136
- type: z.ZodLiteral<"workflow-v1">;
137
- main: WfAndModel;
138
- }>, any>]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
43
+ }, "strip", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
139
44
  type: z.ZodLiteral<"workflow-v1">;
140
45
  main: WfAndModel;
141
- }>, any>[k] }, { [k_1 in keyof z.baseObjectInputType<{
46
+ }>, any> extends infer T ? { [k in keyof T]: T[k] } : never, z.baseObjectInputType<{
142
47
  type: z.ZodLiteral<"workflow-v1">;
143
48
  main: WfAndModel;
144
- }>]: z.baseObjectInputType<{
49
+ }> extends infer T_1 ? { [k_1 in keyof T_1]: T_1[k_1] } : never>>, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
145
50
  type: z.ZodLiteral<"workflow-v1">;
146
51
  main: WfAndModel;
147
- }>[k_1] }>>, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
52
+ }, "strip", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
148
53
  type: z.ZodLiteral<"workflow-v1">;
149
54
  main: WfAndModel;
150
- }, "strip", z.ZodTypeAny, { [k in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
55
+ }>, any> extends infer T_2 ? { [k in keyof T_2]: T_2[k] } : never, z.baseObjectInputType<{
151
56
  type: z.ZodLiteral<"workflow-v1">;
152
57
  main: WfAndModel;
153
- }>, any>]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
154
- type: z.ZodLiteral<"workflow-v1">;
155
- main: WfAndModel;
156
- }>, any>[k] }, { [k_1 in keyof z.baseObjectInputType<{
157
- type: z.ZodLiteral<"workflow-v1">;
158
- main: WfAndModel;
159
- }>]: z.baseObjectInputType<{
160
- type: z.ZodLiteral<"workflow-v1">;
161
- main: WfAndModel;
162
- }>[k_1] }>]>]>;
58
+ }> extends infer T_3 ? { [k_1 in keyof T_3]: T_3[k_1] } : never>]>]>;
163
59
  model: WfAndModel;
164
60
  ui: UI;
165
- }>, any>[k_2] }, { [k_1_1 in keyof z.baseObjectInputType<{
61
+ }, "strip", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
166
62
  workflow: z.ZodUnion<[z.ZodPipeline<z.ZodEffects<WfAndModel, {
167
63
  type: "workflow-v1";
168
64
  main: z.TypeOf<WfAndModel>;
169
65
  }, z.input<WfAndModel>>, z.ZodObject<{
170
66
  type: z.ZodLiteral<"workflow-v1">;
171
67
  main: WfAndModel;
172
- }, "strip", z.ZodTypeAny, { [k in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
173
- type: z.ZodLiteral<"workflow-v1">;
174
- main: WfAndModel;
175
- }>, any>]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
176
- type: z.ZodLiteral<"workflow-v1">;
177
- main: WfAndModel;
178
- }>, any>[k] }, { [k_1 in keyof z.baseObjectInputType<{
179
- type: z.ZodLiteral<"workflow-v1">;
180
- main: WfAndModel;
181
- }>]: z.baseObjectInputType<{
182
- type: z.ZodLiteral<"workflow-v1">;
183
- main: WfAndModel;
184
- }>[k_1] }>>, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
68
+ }, "strip", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
185
69
  type: z.ZodLiteral<"workflow-v1">;
186
70
  main: WfAndModel;
187
- }, "strip", z.ZodTypeAny, { [k in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
71
+ }>, any> extends infer T_5 ? { [k in keyof T_5]: T_5[k] } : never, z.baseObjectInputType<{
188
72
  type: z.ZodLiteral<"workflow-v1">;
189
73
  main: WfAndModel;
190
- }>, any>]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
74
+ }> extends infer T_6 ? { [k_1 in keyof T_6]: T_6[k_1] } : never>>, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
191
75
  type: z.ZodLiteral<"workflow-v1">;
192
76
  main: WfAndModel;
193
- }>, any>[k] }, { [k_1 in keyof z.baseObjectInputType<{
77
+ }, "strip", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
194
78
  type: z.ZodLiteral<"workflow-v1">;
195
79
  main: WfAndModel;
196
- }>]: z.baseObjectInputType<{
80
+ }>, any> extends infer T_7 ? { [k in keyof T_7]: T_7[k] } : never, z.baseObjectInputType<{
197
81
  type: z.ZodLiteral<"workflow-v1">;
198
82
  main: WfAndModel;
199
- }>[k_1] }>]>]>;
83
+ }> extends infer T_8 ? { [k_1 in keyof T_8]: T_8[k_1] } : never>]>]>;
200
84
  model: WfAndModel;
201
85
  ui: UI;
202
- }>]: z.baseObjectInputType<{
86
+ }>, any> extends infer T_4 ? { [k_2 in keyof T_4]: T_4[k_2] } : never, z.baseObjectInputType<{
203
87
  workflow: z.ZodUnion<[z.ZodPipeline<z.ZodEffects<WfAndModel, {
204
88
  type: "workflow-v1";
205
89
  main: z.TypeOf<WfAndModel>;
206
90
  }, z.input<WfAndModel>>, z.ZodObject<{
207
91
  type: z.ZodLiteral<"workflow-v1">;
208
92
  main: WfAndModel;
209
- }, "strip", z.ZodTypeAny, { [k in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
210
- type: z.ZodLiteral<"workflow-v1">;
211
- main: WfAndModel;
212
- }>, any>]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
213
- type: z.ZodLiteral<"workflow-v1">;
214
- main: WfAndModel;
215
- }>, any>[k] }, { [k_1 in keyof z.baseObjectInputType<{
216
- type: z.ZodLiteral<"workflow-v1">;
217
- main: WfAndModel;
218
- }>]: z.baseObjectInputType<{
219
- type: z.ZodLiteral<"workflow-v1">;
220
- main: WfAndModel;
221
- }>[k_1] }>>, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
93
+ }, "strip", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
222
94
  type: z.ZodLiteral<"workflow-v1">;
223
95
  main: WfAndModel;
224
- }, "strip", z.ZodTypeAny, { [k in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
96
+ }>, any> extends infer T_10 ? { [k in keyof T_10]: T_10[k] } : never, z.baseObjectInputType<{
225
97
  type: z.ZodLiteral<"workflow-v1">;
226
98
  main: WfAndModel;
227
- }>, any>]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
99
+ }> extends infer T_11 ? { [k_1 in keyof T_11]: T_11[k_1] } : never>>, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
228
100
  type: z.ZodLiteral<"workflow-v1">;
229
101
  main: WfAndModel;
230
- }>, any>[k] }, { [k_1 in keyof z.baseObjectInputType<{
102
+ }, "strip", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
231
103
  type: z.ZodLiteral<"workflow-v1">;
232
104
  main: WfAndModel;
233
- }>]: z.baseObjectInputType<{
105
+ }>, any> extends infer T_12 ? { [k in keyof T_12]: T_12[k] } : never, z.baseObjectInputType<{
234
106
  type: z.ZodLiteral<"workflow-v1">;
235
107
  main: WfAndModel;
236
- }>[k_1] }>]>]>;
108
+ }> extends infer T_13 ? { [k_1 in keyof T_13]: T_13[k_1] } : never>]>]>;
237
109
  model: WfAndModel;
238
110
  ui: UI;
239
- }>[k_1_1] }>;
111
+ }> extends infer T_9 ? { [k_3 in keyof T_9]: T_9[k_3] } : never>;
240
112
  declare const BlockComponentsDescriptionRaw: z.ZodObject<{
241
113
  workflow: z.ZodUnion<[z.ZodPipeline<z.ZodEffects<z.ZodString, {
242
114
  type: "workflow-v1";
@@ -0,0 +1 @@
1
+ {"version":3,"file":"block_components.d.ts","names":[],"sources":["../../src/block_meta/block_components.ts"],"mappings":";;;iBAIgB,UAAA,uBAAiC,CAAA,CAAE,UAAA,CAAA,CAAY,WAAA,EAAa,OAAA,GAAO,CAAA,CAAA,SAAA;;;;;;;;;;iBAOnE,QAAA,uBAA+B,CAAA,CAAE,UAAA,CAAA,CAAY,WAAA,EAAa,OAAA,GAAO,CAAA,CAAA,QAAA,EAAA,CAAA,CAAA,WAAA,CAAA,CAAA,CAAA,UAAA,CAAA,OAAA;;;;;;;;;;;;;;;;;;;;;;iBAcjE,eAAA,0BACW,CAAA,CAAE,UAAA,mBACV,CAAA,CAAE,UAAA,CAAA,CACnB,UAAA,EAAY,UAAA,EAAY,EAAA,EAAI,EAAA,GAAE,CAAA,CAAA,SAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAQnB,6BAAA,EAA6B,CAAA,CAAA,SAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAC9B,6BAAA,GAAgC,CAAA,CAAE,KAAA,QAAa,6BAAA;AAAA,iBAE3C,0BAAA,CAA2B,MAAA,WAAc,CAAA,CAAA,SAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAM7C,uBAAA,GAA0B,CAAA,CAAE,KAAA,CAAM,UAAA,QAAkB,0BAAA"}
@@ -1,7 +1,6 @@
1
1
  import { ContentRelativeBinary } from "./content_types.js";
2
2
  import { mapRemoteToAbsolute } from "./content_conversion.js";
3
3
  import { z } from "zod";
4
-
5
4
  //#region src/block_meta/block_components.ts
6
5
  function WorkflowV1(contentType) {
7
6
  return z.object({
@@ -26,7 +25,7 @@ const BlockComponentsDescriptionRaw = BlockComponents(z.string(), z.string());
26
25
  function BlockComponentsAbsoluteUrl(prefix) {
27
26
  return BlockComponents(ContentRelativeBinary.transform(mapRemoteToAbsolute(prefix)), ContentRelativeBinary.transform(mapRemoteToAbsolute(prefix)));
28
27
  }
29
-
30
28
  //#endregion
31
29
  export { BlockComponents, BlockComponentsAbsoluteUrl, BlockComponentsDescriptionRaw, Workflow, WorkflowV1 };
30
+
32
31
  //# sourceMappingURL=block_components.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"block_components.js","names":[],"sources":["../../src/block_meta/block_components.ts"],"sourcesContent":["import { z } from \"zod\";\nimport { ContentRelativeBinary } from \"./content_types\";\nimport { mapRemoteToAbsolute } from \"./content_conversion\";\n\nexport function WorkflowV1<const Content extends z.ZodTypeAny>(contentType: Content) {\n return z.object({\n type: z.literal(\"workflow-v1\"),\n main: contentType.describe(\"Main workflow\"),\n });\n}\n\nexport function Workflow<const Content extends z.ZodTypeAny>(contentType: Content) {\n return z.union([\n // string is converted to v1 workflow\n contentType\n .transform((value: z.infer<typeof contentType>) => ({\n type: \"workflow-v1\" as const,\n main: value,\n }))\n .pipe(WorkflowV1(contentType)),\n // structured objects are decoded as union with type descriptor\n z.discriminatedUnion(\"type\", [WorkflowV1(contentType)]),\n ]);\n}\n\nexport function BlockComponents<\n const WfAndModel extends z.ZodTypeAny,\n const UI extends z.ZodTypeAny,\n>(wfAndModel: WfAndModel, ui: UI) {\n return z.object({\n workflow: Workflow(wfAndModel),\n model: wfAndModel,\n ui,\n });\n}\n\nexport const BlockComponentsDescriptionRaw = BlockComponents(z.string(), z.string());\nexport type BlockComponentsDescriptionRaw = z.infer<typeof BlockComponentsDescriptionRaw>;\n\nexport function BlockComponentsAbsoluteUrl(prefix: string) {\n return BlockComponents(\n ContentRelativeBinary.transform(mapRemoteToAbsolute(prefix)),\n ContentRelativeBinary.transform(mapRemoteToAbsolute(prefix)),\n );\n}\nexport type BlockComponentsAbsolute = z.infer<ReturnType<typeof BlockComponentsAbsoluteUrl>>;\n\n// export const BlockComponentsExplicit = BlockComponents(, ContentRelative);\n// export type BlockComponentsExplicit = z.infer<typeof BlockComponentsExplicit>;\n"],"mappings":";;;;;AAIA,SAAgB,WAA+C,aAAsB;AACnF,QAAO,EAAE,OAAO;EACd,MAAM,EAAE,QAAQ,cAAc;EAC9B,MAAM,YAAY,SAAS,gBAAgB;EAC5C,CAAC;;AAGJ,SAAgB,SAA6C,aAAsB;AACjF,QAAO,EAAE,MAAM,CAEb,YACG,WAAW,WAAwC;EAClD,MAAM;EACN,MAAM;EACP,EAAE,CACF,KAAK,WAAW,YAAY,CAAC,EAEhC,EAAE,mBAAmB,QAAQ,CAAC,WAAW,YAAY,CAAC,CAAC,CACxD,CAAC;;AAGJ,SAAgB,gBAGd,YAAwB,IAAQ;AAChC,QAAO,EAAE,OAAO;EACd,UAAU,SAAS,WAAW;EAC9B,OAAO;EACP;EACD,CAAC;;AAGJ,MAAa,gCAAgC,gBAAgB,EAAE,QAAQ,EAAE,EAAE,QAAQ,CAAC;AAGpF,SAAgB,2BAA2B,QAAgB;AACzD,QAAO,gBACL,sBAAsB,UAAU,oBAAoB,OAAO,CAAC,EAC5D,sBAAsB,UAAU,oBAAoB,OAAO,CAAC,CAC7D"}
1
+ {"version":3,"file":"block_components.js","names":[],"sources":["../../src/block_meta/block_components.ts"],"sourcesContent":["import { z } from \"zod\";\nimport { ContentRelativeBinary } from \"./content_types\";\nimport { mapRemoteToAbsolute } from \"./content_conversion\";\n\nexport function WorkflowV1<const Content extends z.ZodTypeAny>(contentType: Content) {\n return z.object({\n type: z.literal(\"workflow-v1\"),\n main: contentType.describe(\"Main workflow\"),\n });\n}\n\nexport function Workflow<const Content extends z.ZodTypeAny>(contentType: Content) {\n return z.union([\n // string is converted to v1 workflow\n contentType\n .transform((value: z.infer<typeof contentType>) => ({\n type: \"workflow-v1\" as const,\n main: value,\n }))\n .pipe(WorkflowV1(contentType)),\n // structured objects are decoded as union with type descriptor\n z.discriminatedUnion(\"type\", [WorkflowV1(contentType)]),\n ]);\n}\n\nexport function BlockComponents<\n const WfAndModel extends z.ZodTypeAny,\n const UI extends z.ZodTypeAny,\n>(wfAndModel: WfAndModel, ui: UI) {\n return z.object({\n workflow: Workflow(wfAndModel),\n model: wfAndModel,\n ui,\n });\n}\n\nexport const BlockComponentsDescriptionRaw = BlockComponents(z.string(), z.string());\nexport type BlockComponentsDescriptionRaw = z.infer<typeof BlockComponentsDescriptionRaw>;\n\nexport function BlockComponentsAbsoluteUrl(prefix: string) {\n return BlockComponents(\n ContentRelativeBinary.transform(mapRemoteToAbsolute(prefix)),\n ContentRelativeBinary.transform(mapRemoteToAbsolute(prefix)),\n );\n}\nexport type BlockComponentsAbsolute = z.infer<ReturnType<typeof BlockComponentsAbsoluteUrl>>;\n\n// export const BlockComponentsExplicit = BlockComponents(, ContentRelative);\n// export type BlockComponentsExplicit = z.infer<typeof BlockComponentsExplicit>;\n"],"mappings":";;;;AAIA,SAAgB,WAA+C,aAAsB;AACnF,QAAO,EAAE,OAAO;EACd,MAAM,EAAE,QAAQ,cAAc;EAC9B,MAAM,YAAY,SAAS,gBAAgB;EAC5C,CAAC;;AAGJ,SAAgB,SAA6C,aAAsB;AACjF,QAAO,EAAE,MAAM,CAEb,YACG,WAAW,WAAwC;EAClD,MAAM;EACN,MAAM;EACP,EAAE,CACF,KAAK,WAAW,YAAY,CAAC,EAEhC,EAAE,mBAAmB,QAAQ,CAAC,WAAW,YAAY,CAAC,CAAC,CACxD,CAAC;;AAGJ,SAAgB,gBAGd,YAAwB,IAAQ;AAChC,QAAO,EAAE,OAAO;EACd,UAAU,SAAS,WAAW;EAC9B,OAAO;EACP;EACD,CAAC;;AAGJ,MAAa,gCAAgC,gBAAgB,EAAE,QAAQ,EAAE,EAAE,QAAQ,CAAC;AAGpF,SAAgB,2BAA2B,QAAgB;AACzD,QAAO,gBACL,sBAAsB,UAAU,oBAAoB,OAAO,CAAC,EAC5D,sBAAsB,UAAU,oBAAoB,OAAO,CAAC,CAC7D"}
@@ -1,10 +1,9 @@
1
- const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
2
- const require_block_id = require('./block_id.cjs');
3
- const require_block_components = require('./block_components.cjs');
4
- const require_block_meta = require('./block_meta.cjs');
1
+ require("../_virtual/_rolldown/runtime.cjs");
2
+ const require_block_id = require("./block_id.cjs");
3
+ const require_block_components = require("./block_components.cjs");
4
+ const require_block_meta = require("./block_meta.cjs");
5
5
  let zod = require("zod");
6
6
  let es_toolkit = require("es-toolkit");
7
-
8
7
  //#region src/block_meta/block_description.ts
9
8
  /** Description, as appears in root block package.json file,
10
9
  * `file:` references are parsed into relative content of corresponding type, depending on the context,
@@ -26,11 +25,11 @@ const BlockPackDescriptionRaw = CreateBlockPackDescriptionSchema(require_block_c
26
25
  function overrideDescriptionVersion(manifest, newVersion) {
27
26
  return (0, es_toolkit.toMerged)(manifest, { id: { version: newVersion } });
28
27
  }
29
-
30
28
  //#endregion
31
29
  exports.BlockPackDescriptionFromPackageJsonRaw = BlockPackDescriptionFromPackageJsonRaw;
32
30
  exports.BlockPackDescriptionRaw = BlockPackDescriptionRaw;
33
31
  exports.CreateBlockPackDescriptionSchema = CreateBlockPackDescriptionSchema;
34
32
  exports.FeatureFlags = FeatureFlags;
35
33
  exports.overrideDescriptionVersion = overrideDescriptionVersion;
34
+
36
35
  //# sourceMappingURL=block_description.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"block_description.cjs","names":["z","BlockComponentsDescriptionRaw","BlockPackMetaDescriptionRaw","BlockPackId"],"sources":["../../src/block_meta/block_description.ts"],"sourcesContent":["import type { ZodTypeAny } from \"zod\";\nimport { z } from \"zod\";\nimport { BlockComponentsDescriptionRaw } from \"./block_components\";\nimport { BlockPackMetaDescriptionRaw } from \"./block_meta\";\nimport { BlockPackId } from \"./block_id\";\nimport { toMerged } from \"es-toolkit\";\nimport type { BlockCodeKnownFeatureFlags } from \"@milaboratories/pl-model-common\";\n\n/** Description, as appears in root block package.json file,\n * `file:` references are parsed into relative content of corresponding type, depending on the context,\n * strings are converted to explicit content type. */\nexport const BlockPackDescriptionFromPackageJsonRaw = z.object({\n components: BlockComponentsDescriptionRaw,\n meta: BlockPackMetaDescriptionRaw,\n});\n\nexport const FeatureFlags = z\n .record(z.string(), z.union([z.boolean(), z.number()]))\n .transform((flags) => flags as BlockCodeKnownFeatureFlags);\n\nexport function CreateBlockPackDescriptionSchema<\n Components extends ZodTypeAny,\n Meta extends ZodTypeAny,\n>(components: Components, meta: Meta) {\n return z\n .object({\n id: BlockPackId,\n components,\n meta,\n featureFlags: FeatureFlags.optional(),\n })\n .passthrough();\n}\n\nexport const BlockPackDescriptionRaw = CreateBlockPackDescriptionSchema(\n BlockComponentsDescriptionRaw,\n BlockPackMetaDescriptionRaw,\n);\nexport type BlockPackDescriptionRaw = z.infer<typeof BlockPackDescriptionRaw>;\n\nexport function overrideDescriptionVersion<T extends { id: BlockPackId }>(\n manifest: T,\n newVersion: string,\n): T {\n return toMerged(manifest, { id: { version: newVersion } }) as T;\n}\n"],"mappings":";;;;;;;;;;;AAWA,MAAa,yCAAyCA,MAAE,OAAO;CAC7D,YAAYC;CACZ,MAAMC;CACP,CAAC;AAEF,MAAa,eAAeF,MACzB,OAAOA,MAAE,QAAQ,EAAEA,MAAE,MAAM,CAACA,MAAE,SAAS,EAAEA,MAAE,QAAQ,CAAC,CAAC,CAAC,CACtD,WAAW,UAAU,MAAoC;AAE5D,SAAgB,iCAGd,YAAwB,MAAY;AACpC,QAAOA,MACJ,OAAO;EACN,IAAIG;EACJ;EACA;EACA,cAAc,aAAa,UAAU;EACtC,CAAC,CACD,aAAa;;AAGlB,MAAa,0BAA0B,iCACrCF,wDACAC,+CACD;AAGD,SAAgB,2BACd,UACA,YACG;AACH,iCAAgB,UAAU,EAAE,IAAI,EAAE,SAAS,YAAY,EAAE,CAAC"}
1
+ {"version":3,"file":"block_description.cjs","names":["z","BlockComponentsDescriptionRaw","BlockPackMetaDescriptionRaw","BlockPackId"],"sources":["../../src/block_meta/block_description.ts"],"sourcesContent":["import type { ZodTypeAny } from \"zod\";\nimport { z } from \"zod\";\nimport { BlockComponentsDescriptionRaw } from \"./block_components\";\nimport { BlockPackMetaDescriptionRaw } from \"./block_meta\";\nimport { BlockPackId } from \"./block_id\";\nimport { toMerged } from \"es-toolkit\";\nimport type { BlockCodeKnownFeatureFlags } from \"@milaboratories/pl-model-common\";\n\n/** Description, as appears in root block package.json file,\n * `file:` references are parsed into relative content of corresponding type, depending on the context,\n * strings are converted to explicit content type. */\nexport const BlockPackDescriptionFromPackageJsonRaw = z.object({\n components: BlockComponentsDescriptionRaw,\n meta: BlockPackMetaDescriptionRaw,\n});\n\nexport const FeatureFlags = z\n .record(z.string(), z.union([z.boolean(), z.number()]))\n .transform((flags) => flags as BlockCodeKnownFeatureFlags);\n\nexport function CreateBlockPackDescriptionSchema<\n Components extends ZodTypeAny,\n Meta extends ZodTypeAny,\n>(components: Components, meta: Meta) {\n return z\n .object({\n id: BlockPackId,\n components,\n meta,\n featureFlags: FeatureFlags.optional(),\n })\n .passthrough();\n}\n\nexport const BlockPackDescriptionRaw = CreateBlockPackDescriptionSchema(\n BlockComponentsDescriptionRaw,\n BlockPackMetaDescriptionRaw,\n);\nexport type BlockPackDescriptionRaw = z.infer<typeof BlockPackDescriptionRaw>;\n\nexport function overrideDescriptionVersion<T extends { id: BlockPackId }>(\n manifest: T,\n newVersion: string,\n): T {\n return toMerged(manifest, { id: { version: newVersion } }) as T;\n}\n"],"mappings":";;;;;;;;;;AAWA,MAAa,yCAAyCA,IAAAA,EAAE,OAAO;CAC7D,YAAYC,yBAAAA;CACZ,MAAMC,mBAAAA;CACP,CAAC;AAEF,MAAa,eAAeF,IAAAA,EACzB,OAAOA,IAAAA,EAAE,QAAQ,EAAEA,IAAAA,EAAE,MAAM,CAACA,IAAAA,EAAE,SAAS,EAAEA,IAAAA,EAAE,QAAQ,CAAC,CAAC,CAAC,CACtD,WAAW,UAAU,MAAoC;AAE5D,SAAgB,iCAGd,YAAwB,MAAY;AACpC,QAAOA,IAAAA,EACJ,OAAO;EACN,IAAIG,iBAAAA;EACJ;EACA;EACA,cAAc,aAAa,UAAU;EACtC,CAAC,CACD,aAAa;;AAGlB,MAAa,0BAA0B,iCACrCF,yBAAAA,+BACAC,mBAAAA,4BACD;AAGD,SAAgB,2BACd,UACA,YACG;AACH,SAAA,GAAA,WAAA,UAAgB,UAAU,EAAE,IAAI,EAAE,SAAS,YAAY,EAAE,CAAC"}
@@ -308,6 +308,7 @@ declare const BlockPackDescriptionFromPackageJsonRaw: z.ZodObject<{
308
308
  };
309
309
  title: string;
310
310
  description: string;
311
+ url?: string | undefined;
311
312
  longDescription?: {
312
313
  type: "explicit-string";
313
314
  content: string;
@@ -339,7 +340,6 @@ declare const BlockPackDescriptionFromPackageJsonRaw: z.ZodObject<{
339
340
  type: "absolute-file";
340
341
  file: string;
341
342
  } | undefined;
342
- url?: string | undefined;
343
343
  docs?: string | undefined;
344
344
  support?: string | undefined;
345
345
  tags?: string[] | undefined;
@@ -367,6 +367,7 @@ declare const BlockPackDescriptionFromPackageJsonRaw: z.ZodObject<{
367
367
  };
368
368
  title: string;
369
369
  description: string;
370
+ url?: string | undefined;
370
371
  longDescription?: string | {
371
372
  type: "explicit-string";
372
373
  content: string;
@@ -398,7 +399,6 @@ declare const BlockPackDescriptionFromPackageJsonRaw: z.ZodObject<{
398
399
  type: "absolute-file";
399
400
  file: string;
400
401
  } | undefined;
401
- url?: string | undefined;
402
402
  docs?: string | undefined;
403
403
  support?: string | undefined;
404
404
  tags?: string[] | undefined;
@@ -428,6 +428,7 @@ declare const BlockPackDescriptionFromPackageJsonRaw: z.ZodObject<{
428
428
  };
429
429
  title: string;
430
430
  description: string;
431
+ url?: string | undefined;
431
432
  longDescription?: {
432
433
  type: "explicit-string";
433
434
  content: string;
@@ -459,7 +460,6 @@ declare const BlockPackDescriptionFromPackageJsonRaw: z.ZodObject<{
459
460
  type: "absolute-file";
460
461
  file: string;
461
462
  } | undefined;
462
- url?: string | undefined;
463
463
  docs?: string | undefined;
464
464
  support?: string | undefined;
465
465
  tags?: string[] | undefined;
@@ -497,6 +497,7 @@ declare const BlockPackDescriptionFromPackageJsonRaw: z.ZodObject<{
497
497
  };
498
498
  title: string;
499
499
  description: string;
500
+ url?: string | undefined;
500
501
  longDescription?: string | {
501
502
  type: "explicit-string";
502
503
  content: string;
@@ -528,7 +529,6 @@ declare const BlockPackDescriptionFromPackageJsonRaw: z.ZodObject<{
528
529
  type: "absolute-file";
529
530
  file: string;
530
531
  } | undefined;
531
- url?: string | undefined;
532
532
  docs?: string | undefined;
533
533
  support?: string | undefined;
534
534
  tags?: string[] | undefined;
@@ -914,6 +914,7 @@ declare const BlockPackDescriptionRaw: z.ZodObject<{
914
914
  };
915
915
  title: string;
916
916
  description: string;
917
+ url?: string | undefined;
917
918
  longDescription?: {
918
919
  type: "explicit-string";
919
920
  content: string;
@@ -945,7 +946,6 @@ declare const BlockPackDescriptionRaw: z.ZodObject<{
945
946
  type: "absolute-file";
946
947
  file: string;
947
948
  } | undefined;
948
- url?: string | undefined;
949
949
  docs?: string | undefined;
950
950
  support?: string | undefined;
951
951
  tags?: string[] | undefined;
@@ -973,6 +973,7 @@ declare const BlockPackDescriptionRaw: z.ZodObject<{
973
973
  };
974
974
  title: string;
975
975
  description: string;
976
+ url?: string | undefined;
976
977
  longDescription?: string | {
977
978
  type: "explicit-string";
978
979
  content: string;
@@ -1004,7 +1005,6 @@ declare const BlockPackDescriptionRaw: z.ZodObject<{
1004
1005
  type: "absolute-file";
1005
1006
  file: string;
1006
1007
  } | undefined;
1007
- url?: string | undefined;
1008
1008
  docs?: string | undefined;
1009
1009
  support?: string | undefined;
1010
1010
  tags?: string[] | undefined;
@@ -1329,6 +1329,7 @@ declare const BlockPackDescriptionRaw: z.ZodObject<{
1329
1329
  };
1330
1330
  title: string;
1331
1331
  description: string;
1332
+ url?: string | undefined;
1332
1333
  longDescription?: {
1333
1334
  type: "explicit-string";
1334
1335
  content: string;
@@ -1360,7 +1361,6 @@ declare const BlockPackDescriptionRaw: z.ZodObject<{
1360
1361
  type: "absolute-file";
1361
1362
  file: string;
1362
1363
  } | undefined;
1363
- url?: string | undefined;
1364
1364
  docs?: string | undefined;
1365
1365
  support?: string | undefined;
1366
1366
  tags?: string[] | undefined;
@@ -1388,6 +1388,7 @@ declare const BlockPackDescriptionRaw: z.ZodObject<{
1388
1388
  };
1389
1389
  title: string;
1390
1390
  description: string;
1391
+ url?: string | undefined;
1391
1392
  longDescription?: string | {
1392
1393
  type: "explicit-string";
1393
1394
  content: string;
@@ -1419,7 +1420,6 @@ declare const BlockPackDescriptionRaw: z.ZodObject<{
1419
1420
  type: "absolute-file";
1420
1421
  file: string;
1421
1422
  } | undefined;
1422
- url?: string | undefined;
1423
1423
  docs?: string | undefined;
1424
1424
  support?: string | undefined;
1425
1425
  tags?: string[] | undefined;
@@ -1744,6 +1744,7 @@ declare const BlockPackDescriptionRaw: z.ZodObject<{
1744
1744
  };
1745
1745
  title: string;
1746
1746
  description: string;
1747
+ url?: string | undefined;
1747
1748
  longDescription?: {
1748
1749
  type: "explicit-string";
1749
1750
  content: string;
@@ -1775,7 +1776,6 @@ declare const BlockPackDescriptionRaw: z.ZodObject<{
1775
1776
  type: "absolute-file";
1776
1777
  file: string;
1777
1778
  } | undefined;
1778
- url?: string | undefined;
1779
1779
  docs?: string | undefined;
1780
1780
  support?: string | undefined;
1781
1781
  tags?: string[] | undefined;
@@ -1803,6 +1803,7 @@ declare const BlockPackDescriptionRaw: z.ZodObject<{
1803
1803
  };
1804
1804
  title: string;
1805
1805
  description: string;
1806
+ url?: string | undefined;
1806
1807
  longDescription?: string | {
1807
1808
  type: "explicit-string";
1808
1809
  content: string;
@@ -1834,7 +1835,6 @@ declare const BlockPackDescriptionRaw: z.ZodObject<{
1834
1835
  type: "absolute-file";
1835
1836
  file: string;
1836
1837
  } | undefined;
1837
- url?: string | undefined;
1838
1838
  docs?: string | undefined;
1839
1839
  support?: string | undefined;
1840
1840
  tags?: string[] | undefined;
@@ -0,0 +1 @@
1
+ {"version":3,"file":"block_description.d.ts","names":[],"sources":["../../src/block_meta/block_description.ts"],"mappings":"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"}
@@ -3,7 +3,6 @@ import { BlockComponentsDescriptionRaw } from "./block_components.js";
3
3
  import { BlockPackMetaDescriptionRaw } from "./block_meta.js";
4
4
  import { z } from "zod";
5
5
  import { toMerged } from "es-toolkit";
6
-
7
6
  //#region src/block_meta/block_description.ts
8
7
  /** Description, as appears in root block package.json file,
9
8
  * `file:` references are parsed into relative content of corresponding type, depending on the context,
@@ -25,7 +24,7 @@ const BlockPackDescriptionRaw = CreateBlockPackDescriptionSchema(BlockComponents
25
24
  function overrideDescriptionVersion(manifest, newVersion) {
26
25
  return toMerged(manifest, { id: { version: newVersion } });
27
26
  }
28
-
29
27
  //#endregion
30
28
  export { BlockPackDescriptionFromPackageJsonRaw, BlockPackDescriptionRaw, CreateBlockPackDescriptionSchema, FeatureFlags, overrideDescriptionVersion };
29
+
31
30
  //# sourceMappingURL=block_description.js.map